Oil well pump fault detection method, device, computer equipment and storage medium
By obtaining the characteristic information of the oil well pump and selecting a suitable deep learning model for fault detection, the problem of insufficient accuracy of general standard detection is solved, highly targeted fault detection is achieved, and the accuracy and efficiency of oil well pump fault detection are improved.
Patent Information
- Application Number
- CN202011313334.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-20
- Publication Date
- 2025-10-03
- Estimated Expiration
- 2040-11-20
AI Technical Summary
In the prior art, a universal standard based on a wellbore pump dynamometer diagram cannot accurately detect wellbore pump failures in different oil wells, resulting in insufficient detection accuracy.
By obtaining the equipment characteristics, production characteristics, and working environment characteristics of the oil well pump, a matching deep learning model is determined for fault detection, and the target dynamometer diagram is used for fault analysis.
The accuracy of oil well pump fault detection is improved, the system is adapted to oil well pumps with different characteristics, resource waste is reduced, and detection efficiency is improved.
Smart Images

Figure CN114528895B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of oil well pump detection, and in particular to a method, device, computer equipment and storage medium for detecting faults of an oil well pump. Background Art
[0002] Due to the long-term uninterrupted movement of the oil well pump in the complex conditions of the wellbore, the oil well pump is affected by the structural components of the oil well pump itself and the environmental media in the wellbore, which can cause various faults. In order to better maintain and repair the oil well pump according to different faults, it is necessary to diagnose the oil well pump fault and determine which fault is affecting the normal operation of the oil well pump.
[0003] In the related art, a neural network dynamometer diagram grid model is used to diagnose oil well pump faults. Based on a set of universal standards, different oil well pumps are analyzed based on the dynamometer diagram to determine whether they have faults and the type of fault.
[0004] However, in actual production applications, the faults corresponding to the same type of dynamometer diagram in different oil wells may be different. Therefore, it is not possible to perform fault detection on the oil well pump based on the dynamometer diagram using a universal standard. Summary of the Invention
[0005] In order to solve the problems of the related art, the embodiments of the present application provide a method, device, computer equipment and storage medium for detecting faults in an oil well pump. The technical solution is as follows:
[0006] In one aspect, a method for detecting a fault of an oil well pump is provided, the method comprising:
[0007] Acquire target characteristic information corresponding to a target oil well pump, wherein the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information;
[0008] Determining a target fault detection model from at least two fault detection models according to the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model;
[0009] The target indicator diagram of the target oil well pump is input into the target fault detection model to obtain a fault detection result output by the target fault detection model.
[0010] In another aspect, a fault detection device for a wellbore pump is provided, the device comprising:
[0011] a first acquisition module, configured to acquire target characteristic information corresponding to a target oil well pump, wherein the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information;
[0012] a first determining module, configured to determine a target fault detection model from at least two fault detection models based on the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model;
[0013] The detection module is used to input the target indicator diagram of the target oil well pump into the target fault detection model to obtain the fault detection result output by the target fault detection model.
[0014] On the other hand, a computer device is provided, which includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the oil pump fault detection method as described in the above aspects.
[0015] On the other hand, a computer-readable storage medium is provided, in which at least one instruction, at least one program, a code set or an instruction set is stored. The at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement the oil pump fault detection method as described in the above aspects.
[0016] In another aspect, a computer program product or computer program is provided. The computer program product or computer program includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the oil well pump fault detection method provided in the above aspect or various optional implementations of the above aspect.
[0017] The beneficial effects of the technical solutions provided by the embodiments of the present application include at least:
[0018] Since there are differences in the working states of oil pumps with different equipment characteristics, production characteristics and working environment characteristics, in the embodiment of the present application, when performing fault detection on the target oil pump, first, based on the target characteristic information of the target oil pump, a target fault detection model that matches the characteristics of the target oil pump is determined, and then the target fault detection model is used to perform fault detection based on the target indicator diagram of the target oil pump to obtain a fault detection result; compared with the related art of performing fault detection on the oil pump according to general standards, the solution provided by the embodiment of the present application can perform targeted detection based on the characteristics of the oil pump, which helps to improve the detection accuracy of oil pump faults. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1is a flow chart of a method for detecting a fault of an oil well pump provided in an exemplary embodiment of the present application;
[0020] Figure 2 is a flow chart of a method for detecting a fault of an oil well pump provided in another exemplary embodiment of the present application;
[0021] Figure 3 is a schematic diagram showing a clustering process of sample oil well pumps based on sample feature vectors according to an exemplary embodiment of the present application;
[0022] Figure 4 is a dynamometer diagram provided by an illustrative embodiment of the present application;
[0023] Figure 5 1 is a schematic structural diagram of a fault detection device for an oil well pump provided in an exemplary embodiment of the present application;
[0024] Figure 6 It is a structural diagram of a computer device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0025] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0026] When the following description refers to the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Instead, they are merely examples of devices and methods consistent with certain aspects of the present application as detailed in the appended claims.
[0027] In the description of this application, it should be understood that the terms "first", "second", etc. are used for descriptive purposes only and should not be understood as indicating or implying relative importance. Unless otherwise specified, "plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship.
[0028] Please refer to Figure 1 , which shows a flow chart of a method for detecting a fault in a wellbore pump provided by an exemplary embodiment of the present application. This embodiment is described using the method applied to a computer device as an example. The method for detecting a fault in a wellbore pump includes:
[0029] Step 101: Acquire target characteristic information corresponding to a target oil well pump, where the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information.
[0030] Among them, the target oil pump is the oil pump whose fault is to be detected, and the target characteristic information is used to characterize the characteristics of the target oil pump. The purpose of obtaining the target characteristic information corresponding to the target oil pump is to determine the type of the target oil pump based on the characteristics of the target oil pump. The type is classified after comprehensive analysis of various characteristics of the oil pump. Based on the type of the target oil pump, the type of fault of the target oil pump can be more accurately determined.
[0031] In some embodiments, the equipment characteristic information includes the model and usage time of the oil pump, the production characteristic information includes the quality and physical properties of the extracted oil, and the working environment characteristic information is the geological conditions of the area where the target oil pump is located.
[0032] Step 102: Determine a target fault detection model from at least two fault detection models based on the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model.
[0033] In one possible implementation, the computer device clusters the sample oil pumps in advance according to their characteristic information, and trains the fault detection model corresponding to each type of sample oil pumps based on their historical working data (including historical dynamometer diagrams and historical fault detection records), thereby obtaining multiple fault detection models corresponding to oil pumps with different characteristics.
[0034] Since different fault detection models correspond to oil pumps with different characteristics, if the relevant data of the target oil pump is input into a fault detection model that does not correspond to it, the subsequent fault detection results will be inconsistent with the facts. Therefore, the computer equipment needs to determine the target fault detection model from at least two fault detection models based on the target characteristic information.
[0035] Deep learning is a new field in machine learning research. Its motivation is to build and simulate neural networks that analyze and learn data using the same mechanisms as the human brain. Deep learning models are the vehicle for deep learning. The fault detection model in the embodiments of this application is a deep learning model trained based on training samples.
[0036] Among them, the deep learning model here includes at least one of the Visual Geometry Group Network (VGGNet), the Google Network Model (GoogLeNet), the Residual Neural Network Model (ResNet) and the Alex Network Model (AlexNet). This embodiment does not limit the specific type of the fault detection model.
[0037] Step 103 : Input the target dynamometer diagram of the target oil well pump into the target fault detection model to obtain the fault detection result output by the target fault detection model.
[0038] The dynamometer diagram is a closed curve measured by the dynamometer during one pumping cycle of the oil pump. It is a graph that reflects the law of change of the oil pump's suspension point load with its displacement. The area enclosed by the closed curve represents the work done by the oil pump in one reciprocating motion. It can indirectly reflect the fault condition of the oil pump, such as the type of fault and the severity of the fault.
[0039] The target dynamometer diagram is a dynamometer diagram of a target oil well pump measured by a dynamometer in a certain period, and can reflect the fault conditions of the target oil well pump in a certain period.
[0040] The fault detection result includes the probability of the target well pump having different types of faults, whether the target well pump has a fault, and the fault type when the target well pump has a fault.
[0041] Optionally, the computer device uses the fault type with the highest probability as the fault type of the target oil well pump.
[0042] Optionally, the computer device uses the top n fault types with the highest probabilities as the fault types of the target oil well pump, where n is an integer greater than or equal to 1.
[0043] In one illustrative example, the computer device determines the fault type with the highest probability as the fault type of the target wellbore pump. If the fault detection results output by the target fault detection model show that the three faults with the highest probabilities are fault type 1, fault type 2, and fault type 3, and the probability of fault type 1 is 80%, the probability of fault type 2 is 10%, and the probability of fault type 3 is 5%, the computer device determines the fault type of the target wellbore pump as fault type 1.
[0044] In other possible implementations, the computer device uses the fault type with a probability higher than a probability threshold as the fault type of the target oil well pump.
[0045] To sum up, in this embodiment, since there are differences in the working conditions of the oil pumps with different equipment characteristics, production characteristics and working environment characteristics, in the embodiment of the present application, when performing fault detection on the target oil pump, first, based on the target characteristic information of the target oil pump, a target fault detection model that matches the characteristics of the target oil pump is determined, and then the target fault detection model is used to perform fault detection based on the target indicator diagram of the target oil pump to obtain a fault detection result; compared with the related art of performing fault detection on the oil pump according to general standards, the solution provided by the embodiment of the present application can perform targeted detection based on the characteristics of the oil pump, which helps to improve the detection accuracy of oil pump faults.
[0046] Please refer to Figure 2 , which shows a flow chart of a method for detecting a fault in an oil well pump provided by another exemplary embodiment of the present application. This embodiment is described by taking the method applied to a computer device as an example. The method for detecting a fault in an oil well pump includes:
[0047] Step 201 : Obtain a sample feature vector corresponding to a sample oil well pump. The sample feature vector is obtained by converting sample feature information corresponding to the sample oil well pump.
[0048] The sample oil pumps are oil pumps obtained through a large number of sampling. The characteristic information of each type of the oil pumps is not exactly the same, and generally there are many differences.
[0049] Categorizing similar sample oil well pumps based solely on their feature information is not easy, as feature information can vary greatly. Comparing similar sample information individually can only reveal the similarity of a single feature, not the overall similarity of all compared features. Therefore, by converting the sample feature information into sample feature vectors, a computer can calculate the similarity of each sample feature vector to determine the overall similarity of all sample pump information, simplifying the subsequent clustering process.
[0050] Optionally, the computer device generates feature vectors of the sample oil well pump in different dimensions based on the sample feature information of each dimension of the sample oil well pump. The feature vectors are set based on the similarity of sample information of the same type and the weights of sample information of different types.
[0051] Optionally, the computer device obtains sample feature information corresponding to the sample oil well pump, where the sample feature information includes information in k dimensions, where k is an integer greater than or equal to 2; and trains a vector conversion model based on the sample feature information, where the vector conversion model is configured to convert the input feature information into a k-dimensional feature vector. The sample feature information may include at least one of equipment feature information, production feature information, and working environment feature information.
[0052] In a possible implementation, the vector conversion model is a word to vector (w2v) model, and the purpose of training the vector conversion model is to improve the speed and accuracy of converting sample feature information into feature vectors.
[0053] Optionally, the computer device trains a vector conversion sub-model corresponding to the i-th dimension among k dimensions based on information corresponding to the i-th dimension in the sample feature information, where i is a positive integer less than or equal to k; and generates a vector conversion model based on the k vector conversion sub-models.
[0054] Since the sample feature information has multiple dimensions, that is, there are multiple types of sample feature information, the multiple types of sample feature information correspond to feature vectors of multiple dimensions, and the vectors of multiple dimensions are composed of vectors of a single dimension. Therefore, a vector conversion sub-model corresponding to the single-dimensional sample feature information is required, so that the single-dimensional sample feature information is first converted into a single-dimensional feature vector through the vector conversion sub-model, and then k single-dimensional feature vectors are combined to generate a k-dimensional feature vector.
[0055] Step 202 : Clustering the sample oil well pumps based on the sample feature vectors to obtain at least one oil well pump cluster.
[0056] Clustering is the process of dividing a collection of physical or abstract objects into multiple classes composed of similar objects. A cluster generated by clustering is a collection of data objects that are similar to objects within the same cluster and dissimilar to objects in other clusters. To identify oil well pumps with similar characteristics, a computer device uses a clustering algorithm to cluster sample oil well pumps based on their feature vectors, thereby generating at least one oil well pump cluster. The similarity of the sample feature vectors corresponding to the sample oil well pumps within the same oil well pump cluster is higher than the similarity of the sample feature vectors corresponding to the sample oil well pumps in different oil well pump clusters.
[0057] The clustering methods herein include k-means clustering, mean shift clustering, and density-based clustering. This embodiment does not limit the specific clustering algorithm used.
[0058] like Figure 3 As shown, assuming that the sample feature vector is a two-dimensional vector, the sample feature vector can be represented by a point 304 on a plane coordinate system. According to the distance between each point 304, the point can be clustered to obtain a first cluster 301, a second cluster 302 and a third cluster 303, each cluster representing a wellbore pump cluster.
[0059] Step 203 : For any oil well pump cluster, a fault detection model corresponding to the oil well pump cluster is trained based on the sample dynamometer diagrams corresponding to the sample oil well pumps in the oil well pump cluster and the fault labels corresponding to the sample dynamometer diagrams.
[0060] The fault label is a labeling of the fault type information on the sample dynamometer diagram corresponding to the sample oil well pump after the fault type of the sample oil well pump is determined. The fault label indicates the fault type corresponding to the sample dynamometer diagram.
[0061] Since the feature similarity of sample oil well pumps in the same oil well pump cluster is high, the fault types corresponding to the same sample dynamometer diagrams are basically the same. Therefore, the sample dynamometer diagrams can be accurately labeled as faults. Then, based on the sample dynamometer diagrams corresponding to the sample oil well pumps in the oil well pump cluster and the fault labels corresponding to the sample dynamometer diagrams, a fault detection model corresponding to the oil well pump cluster is trained. This fault detection model is used to detect faults of oil well pumps with high feature similarity to the sample oil well pumps in the oil well pump cluster.
[0062] Optionally, the computer device selects a part of the sample dynamometer diagram as a training set and the remaining part as a test set, inputs the training set into the deep learning network for training, obtains a fault detection model corresponding to the oil pump cluster, inputs the test set into the fault detection model to obtain the detection results, and adjusts the weight coefficients and bias items in the fault detection model according to the detection results.
[0063] Step 204 : Determine candidate feature vectors corresponding to the fault detection model based on the sample feature vectors corresponding to the sample oil well pumps in the oil well pump cluster.
[0064] In one possible implementation, in order to facilitate the subsequent determination of the oil pump cluster to which the oil pump to be detected belongs, and thereby select the fault detection model corresponding to the cluster for fault detection, the computer device needs to further determine the candidate feature vector that characterizes the characteristics of the oil pump cluster based on the sample feature vector corresponding to the sample oil pump in the oil pump cluster.
[0065] In one possible implementation, the computer device determines the vector average of the sample feature vectors corresponding to the sample well pumps in the well pump cluster as the candidate feature vector for the well pump cluster. In an illustrative example, the well pump cluster includes 100 sample well pumps, and the computer device determines the average of the sample feature vectors corresponding to the 100 sample well pumps as the candidate feature vector.
[0066] Through the above steps 201 to 204, the computer device completes the training of the fault detection models corresponding to different types of oil well pumps. Subsequently, the computer device can use the trained fault detection models to perform fault detection on the oil well pumps.
[0067] Step 205: Acquire target characteristic information corresponding to the target oil well pump.
[0068] The implementation of this step can refer to the above-mentioned step 101, and will not be repeated here in this embodiment.
[0069] Step 206: Convert the target feature information into a target feature vector.
[0070] Since it is necessary to compare the target feature information with the sample feature information to determine which type of sample oil pumps have similar features to the target oil pump, so as to determine the target fault detection model, but the sample feature information has been converted into a sample feature vector, and the candidate feature vectors representing the features of each type of oil pump are determined based on the sample feature vector. The information cannot be compared with the vector, so it is necessary to convert the target feature information into a target feature vector.
[0071] In a possible implementation, the computer device inputs the target feature information into a vector conversion model trained during the model training process to obtain a target feature vector.
[0072] Step 207 : Determine a target fault detection model from at least two fault detection models based on the target feature vector and the candidate feature vectors corresponding to each fault detection model.
[0073] Optionally, the computer device calculates the vector distance between the target feature vector and each candidate feature vector, and determines the fault detection model corresponding to the minimum vector distance as the target fault detection model.
[0074] Among them, the vector distance reflects the degree of similarity between vectors. The larger the vector distance, the smaller the similarity between vectors. Conversely, the smaller the vector distance, the greater the similarity between vectors.
[0075] When the vector distance between the target feature vector and a candidate feature vector is the smallest, it means that the characteristics of the target oil well pump are most similar to those of the sample oil well pump corresponding to the candidate feature vector. Therefore, the fault detection model corresponding to the minimum vector distance is determined as the target fault detection model.
[0076] Methods for calculating vector distance include Euclidean distance algorithm, Manhattan distance algorithm, and angle cosine algorithm, which are not limited in this embodiment.
[0077] In an illustrative example, the computer device uses the Euclidean distance algorithm to calculate the vector distance between the target feature vector and a candidate feature vector, where the target feature vector a=(x1, x2, ...x n ) A candidate feature vector b=(y1,y2,...y n ), the Euclidean distance calculation formula between the target feature vector and the candidate feature vector is:
[0078]
[0079] Step 208 : Obtain at least two candidate dynamometer diagrams corresponding to the target oil well pump, where the at least two candidate dynamometer diagrams are continuously generated.
[0080] The dynamometer diagram is a graph showing the work done by the oil well pump in one reciprocating motion. Therefore, the continuously generated dynamometer diagram can show the work done by the oil well pump in several consecutive reciprocating motions. Therefore, based on the work done by the oil well pump in several consecutive reciprocating motions shown by the dynamometer diagram, it is possible to determine when the oil well pump fails.
[0081] In a possible implementation, the computer device acquires at least two continuously generated candidate dynamometer diagrams, so as to subsequently determine a target dynamometer diagram for fault detection.
[0082] Step 209 : If the dynamometer diagram similarity between the first candidate dynamometer diagram and the second candidate dynamometer diagram is less than a similarity threshold, the second candidate dynamometer diagram is determined as the target dynamometer diagram, and the first candidate dynamometer diagram and the second candidate dynamometer diagram are adjacently generated dynamometer diagrams.
[0083] When the oil pump is in normal operation, the dynamometer diagram generated by the dynamometer will not have much difference in shape, that is, the similarity of the dynamometer diagram is high. However, once the oil pump fails, the dynamometer diagram generated at the time of the failure will be significantly different from the shape when the oil pump is in normal operation, that is, the similarity of the dynamometer diagram is low. Therefore, the computer device can compare the dynamometer diagram similarities of the candidate dynamometer diagrams and select the candidate dynamometer diagram with lower similarity for subsequent fault detection.
[0084] Optionally, if the area difference between the first candidate dynamometer diagram and the second candidate dynamometer diagram is greater than the area difference threshold, and / or the difference between the extreme value of the tangent slope at the target position on the second candidate dynamometer diagram and the target slope is greater than the tangent slope difference threshold, the computer device determines the second candidate dynamometer diagram as the target dynamometer diagram.
[0085] like Figure 4 As shown, first candidate dynamometer diagram 401 is a parallelogram-shaped diagram for a wellbore pump operating normally, while second candidate dynamometer diagram 402 is an irregularly shaped diagram for a wellbore pump experiencing a fault. First candidate dynamometer diagram 401 and second candidate dynamometer diagram 402 differ in area. While the slope of each side of first candidate dynamometer diagram 401 is constant, the slopes of the tangent lines at corresponding points on second candidate dynamometer diagram 402 are different.
[0086] Step 210: Input the target dynamometer diagram into the target fault detection model to obtain the fault detection result output by the target fault detection model.
[0087] The implementation of this step can refer to the above-mentioned step 103, and will not be repeated here in this embodiment.
[0088] To sum up, in this embodiment, by converting feature information into feature vectors and determining the target fault detection model based on the feature vectors, the efficiency of determining the target fault detection model is improved; and, based on the sample feature vectors, the sample oil pumps are clustered to obtain at least one oil pump cluster, so that model training is performed based on the sample dynamometer diagrams and fault labels of the sample oil pumps in the same oil pump cluster, thereby improving the targetedness and training quality of the model training, and thereby improving the accuracy of subsequent fault detection.
[0089] In addition, in this embodiment, the computer device selects a target dynamometer diagram for fault detection based on the similarity between consecutively generated dynamometer diagrams, thereby avoiding waste of processing resources caused by performing fault detection on each dynamometer diagram.
[0090] Please refer to Figure 5 , which shows a schematic structural diagram of a fault detection device for a well pump provided by an embodiment of the present application. The device comprises: a first acquisition module 501 , a first determination module 502 , and a detection module 503 .
[0091] A first acquisition module 501 is configured to acquire target characteristic information corresponding to a target oil well pump, wherein the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information;
[0092] a first determining module 502 for determining a target fault detection model from at least two fault detection models based on the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model;
[0093] The detection module 503 is configured to input the target dynamometer diagram of the target oil well pump into the target fault detection model to obtain a fault detection result output by the target fault detection model.
[0094] Optionally, the first determining module 502 includes:
[0095] A conversion unit, configured to convert the target feature information into a target feature vector;
[0096] The first determining unit is configured to determine the target fault detection model from at least two of the fault detection models according to the target feature vector and the candidate feature vectors corresponding to the respective fault detection models.
[0097] Optionally, the first determining unit is configured to:
[0098] Calculating the vector distance between the target feature vector and each of the candidate feature vectors;
[0099] The fault detection model corresponding to the minimum vector distance is determined as the target fault detection model.
[0100] Optionally, the device further includes:
[0101] A second acquisition module is used to acquire a sample feature vector corresponding to the sample oil well pump, wherein the sample feature vector is obtained by converting the sample feature information corresponding to the sample oil well pump;
[0102] a clustering module, configured to cluster the sample oil well pumps based on the sample feature vectors to obtain at least one oil well pump cluster;
[0103] A first training module is configured to train, for any oil well pump cluster, the fault detection model corresponding to the oil well pump cluster based on the sample dynamometer diagrams corresponding to the sample oil well pumps in the oil well pump cluster and the fault labels corresponding to the sample dynamometer diagrams;
[0104] The second determining module is configured to determine the candidate feature vector corresponding to the fault detection model according to the sample feature vector corresponding to the sample oil well pump in the oil well pump cluster.
[0105] Optionally, the device further includes:
[0106] A third acquisition module is configured to acquire sample feature information corresponding to the sample oil well pump, wherein the sample feature information includes information of k dimensions, where k is an integer greater than or equal to 2;
[0107] The second training module is used to train a vector conversion model based on the sample feature information, and the vector conversion model is used to convert the input feature information into a k-dimensional feature vector.
[0108] Optionally, the second training module includes:
[0109] a training unit, configured to train, for an i-th dimension among the k dimensions, a vector conversion sub-model corresponding to the i-th dimension according to information corresponding to the i-th dimension in the sample feature information, where i is a positive integer less than or equal to k;
[0110] A generating unit is configured to generate the vector conversion model according to the k vector conversion sub-models.
[0111] Optionally, the detection module 503 includes:
[0112] an acquiring unit, configured to acquire at least two candidate indicator diagrams corresponding to the target oil well pump, wherein the at least two candidate indicator diagrams are continuously generated indicator diagrams;
[0113] a second determining unit, configured to determine the second candidate indicator diagram as the target indicator diagram if the indicator diagram similarity between the first candidate indicator diagram and the second candidate indicator diagram is less than a similarity threshold, wherein the first candidate indicator diagram and the second candidate indicator diagram are adjacently generated indicator diagrams;
[0114] The detection unit is used to input the target dynamometer diagram into the target fault detection model to obtain the fault detection result output by the target fault detection model.
[0115] To sum up, in the embodiments of the present application, since there are differences in the working states of the oil pumps with different equipment characteristics, production characteristics and working environment characteristics, in the embodiments of the present application, when performing fault detection on the target oil pump, first, based on the target characteristic information of the target oil pump, a target fault detection model that matches the characteristics of the target oil pump is determined, and then the target fault detection model is used to perform fault detection based on the target indicator diagram of the target oil pump to obtain a fault detection result; compared with the related art of performing fault detection on the oil pump according to general standards, the solution provided in the embodiments of the present application can perform targeted detection based on the characteristics of the oil pump, which helps to improve the detection accuracy of oil pump faults.
[0116] In this embodiment, by converting feature information into feature vectors and determining the target fault detection model based on the feature vectors, the efficiency of determining the target fault detection model is improved; and, based on the sample feature vectors, the sample oil pumps are clustered to obtain at least one oil pump cluster, so that model training is performed based on the sample dynamometer diagrams and fault labels of the sample oil pumps in the same oil pump cluster, thereby improving the targetedness and training quality of the model training, and thereby improving the accuracy of subsequent fault detection.
[0117] In addition, in this embodiment, the computer device selects a target dynamometer diagram for fault detection based on the similarity between consecutively generated dynamometer diagrams, thereby avoiding waste of processing resources caused by performing fault detection on each dynamometer diagram.
[0118] It should be noted that the apparatus provided in the above embodiments, when implementing its functions, is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments are based on the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.
[0119] Please refer to Figure 6, which shows a schematic diagram of the structure of a computer device provided by an exemplary embodiment of the present application. Specifically, the computer device 600 includes a central processing unit (CPU) 601, a system memory 604 including a random access memory 602 and a read-only memory 603, and a system bus 605 connecting the system memory 604 and the CPU 601. The computer device 600 also includes a basic input / output system (I / O system) 606 that facilitates information transmission between various components within the computer, and a mass storage device 607 for storing an operating system 613, application programs 614, and other program modules 615.
[0120] The basic input / output system 606 includes a display 608 for displaying information and an input device 609 such as a mouse and keyboard for user input. The display 608 and the input device 609 are connected to the central processing unit 601 via an input / output controller 610 connected to the system bus 605. The basic input / output system 606 may also include an input / output controller 610 for receiving and processing input from a variety of other devices such as a keyboard, mouse, or electronic stylus. Similarly, the input / output controller 610 also provides output to a display screen, printer, or other types of output devices.
[0121] The mass storage device 607 is connected to the central processing unit 601 via a mass storage controller (not shown) connected to the system bus 605. The mass storage device 607 and its associated computer-readable media provide non-volatile storage for the computer device 600. In other words, the mass storage device 607 may include a computer-readable medium (not shown) such as a hard disk or drive.
[0122] Without loss of generality, the computer-readable medium may include computer storage media and communication media. Computer storage media include volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer-readable instructions, data structures, program modules or other data. Computer storage media include random access memory (RAM), read-only memory (ROM), flash memory or other solid-state storage technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, tape cassette, magnetic tape, disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that the computer storage medium is not limited to the above-mentioned ones. The above-mentioned system memory 604 and mass storage device 607 can be collectively referred to as memory.
[0123] The memory stores one or more programs, and the one or more programs are configured to be executed by one or more central processing units 601. The one or more programs contain instructions for implementing the above-mentioned methods. The central processing unit 601 executes the one or more programs to implement the methods provided by the above-mentioned various method embodiments.
[0124] According to various embodiments of the present application, the computer device 600 may also be connected to a remote computer on a network such as the Internet for operation. That is, the computer device 600 may be connected to a network 612 via a network interface unit 611 connected to the system bus 605. Alternatively, the network interface unit 611 may be used to connect to other types of networks or remote computer systems (not shown).
[0125] The memory also includes one or more programs, which are stored in the memory and include steps executed by a computer device in the method provided in the embodiment of the present application.
[0126] An embodiment of the present application also provides a computer-readable storage medium, which stores at least one instruction, at least one program, code set or instruction set. The at least one instruction, at least one program, code set or instruction set is loaded and executed by a processor to implement the oil pump fault detection method provided in the above embodiment.
[0127] The present application also provides a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the oil well pump fault detection method provided in the above aspect or various optional implementations of the above aspect.
[0128] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0129] Those skilled in the art will appreciate that all or part of the steps in the information processing method implementing the above-described embodiments may be accomplished by hardware, or by a program instructing the relevant hardware to accomplish the steps. The program may be stored in a computer-readable storage medium, such as a read-only memory, a magnetic disk, or an optical disk. The above description is merely an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included within the scope of protection of the present application.
Claims
1. A method for detecting a fault of an oil well pump, characterized in that: The method comprises: Acquire target characteristic information corresponding to a target oil well pump, wherein the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information; Determining a target fault detection model from at least two fault detection models according to the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model; inputting the target indicator diagram of the target oil well pump into the target fault detection model to obtain a fault detection result output by the target fault detection model; Determining a target fault detection model from at least two fault detection models according to the target feature information includes: Converting the target feature information into a target feature vector; Calculating the vector distance between the target feature vector and the candidate feature vectors corresponding to each of the fault detection models; The fault detection model corresponding to the minimum vector distance is determined as the target fault detection model.
2. The method according to claim 1, characterized in that The method further comprises: Obtaining a sample feature vector corresponding to a sample oil well pump, wherein the sample feature vector is obtained by converting sample feature information corresponding to the sample oil well pump; Clustering the sample oil well pumps based on the sample feature vectors to obtain at least one oil well pump cluster; For any oil well pump cluster, training the fault detection model corresponding to the oil well pump cluster according to the sample dynamometer diagrams corresponding to the sample oil well pumps in the oil well pump cluster and the fault labels corresponding to the sample dynamometer diagrams; The candidate feature vector corresponding to the fault detection model is determined according to the sample feature vector corresponding to the sample oil well pump in the oil well pump cluster.
3. The method according to any one of claims 1 to 2, characterized in that: The method further comprises: Obtaining sample feature information corresponding to the sample oil well pump, wherein the sample feature information includes information of k dimensions, where k is an integer greater than or equal to 2; A vector conversion model is trained based on the sample feature information, and the vector conversion model is used to convert the input feature information into a k-dimensional feature vector.
4. The method according to claim 3, characterized in that Training a vector conversion model based on the sample feature information includes: For the i-th dimension among the k dimensions, training a vector conversion sub-model corresponding to the i-th dimension according to the information corresponding to the i-th dimension in the sample feature information, where i is a positive integer less than or equal to k; The vector conversion model is generated according to the k vector conversion sub-models.
5. The method according to any one of claims 1 to 2, characterized in that: The step of inputting the target indicator diagram of the target oil well pump into the target fault detection model to obtain the fault detection result output by the target fault detection model includes: Obtaining at least two candidate indicator diagrams corresponding to the target oil well pump, wherein at least two of the candidate indicator diagrams are continuously generated indicator diagrams; If the indicator diagram similarity between the first candidate indicator diagram and the second candidate indicator diagram is less than a similarity threshold, determining the second candidate indicator diagram as the target indicator diagram, and the first candidate indicator diagram and the second candidate indicator diagram are adjacently generated indicator diagrams; The target dynamometer diagram is input into the target fault detection model to obtain the fault detection result output by the target fault detection model.
6. A fault detection device for an oil well pump, characterized in that: The device comprises: a first acquisition module, configured to acquire target characteristic information corresponding to a target oil well pump, wherein the target characteristic information includes at least one of equipment characteristic information, production characteristic information, and working environment characteristic information; a first determining module, configured to determine a target fault detection model from at least two fault detection models based on the target feature information, wherein different fault detection models correspond to oil well pumps with different features, and the fault detection model is a deep learning model; a detection module, configured to input a target dynamometer diagram of the target oil well pump into the target fault detection model to obtain a fault detection result output by the target fault detection model; The first determination module is used to convert the target feature information into a target feature vector; calculate the vector distance between the target feature vector and the candidate feature vectors corresponding to each of the fault detection models; and determine the fault detection model corresponding to the minimum vector distance as the target fault detection model.
7. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the fault detection method for the oil pump as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that The readable storage medium stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set are loaded and executed by the processor to implement the fault detection method of the oil pump as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Oil-well pump running condition recognition method and device
CN104361365A
A method for obtaining the failure condition of a pumping unit well
CN109255134A