A convolutional bidirectional timing dynamometer diagram prediction method based on specific data driving
Through a convolutional bidirectional timing dynamometer diagram prediction method driven by specific data, the problem of decreased accuracy of the dynamometer diagram prediction model in the existing technology under complex combination working conditions is solved, accurate prediction of multiple working conditions is achieved, model complexity is simplified and prediction accuracy is improved.
Patent Information
- Application Number
- CN202510519778.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-24
- Publication Date
- 2025-09-09
- Estimated Expiration
- 2045-04-24
AI Technical Summary
The existing dynamometer diagram prediction model cannot fully cover complex combined working conditions, resulting in a decrease in prediction accuracy and an inability to provide a reliable decision-making basis for oilfield production.
A convolutional bidirectional time series dynamometer diagram prediction method driven by specific data is adopted. By acquiring the dynamometer diagram data, performing data cleaning, alignment and normalization processing, constructing a time series sample set, and training the convolutional bidirectional time series model, accurate prediction of various working conditions can be achieved.
It achieves accurate prediction of various working conditions, especially complex combination working conditions, simplifies model complexity, improves prediction accuracy, reduces computing costs, and has fast computing capabilities.
Smart Images

Figure CN120045924B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of oil production dynamometer diagram prediction, and in particular relates to a convolution bidirectional time series dynamometer diagram prediction method based on specific data driving. Background Art
[0002] In the oil and gas industry, ensuring efficient and stable operation of pumping units and accurately understanding their operating conditions are crucial for improving extraction efficiency, reducing costs, and ensuring safe production. In actual production, pumping unit operating conditions are complex and diverse, encompassing not only single operating conditions but also a combination of multiple intertwined conditions.
[0003] Existing dynamometer prediction models cannot fully cover these operating conditions. Once complex combinations of operating conditions are encountered, prediction accuracy drops significantly, making it impossible to provide reliable decision-making for oilfield production. Therefore, leveraging oilfield big data and using deep learning methods to accurately predict multiple operating conditions is crucial for oil well production. Summary of the Invention
[0004] In order to solve the above problems, the present invention proposes a convolutional bidirectional timing indicator diagram prediction method based on specific data driving, which can accurately predict multiple working conditions and even complex combined working conditions.
[0005] The technical solutions of the present invention are as follows:
[0006] A convolutional bidirectional timing indicator diagram prediction method based on specific data driving includes the following steps:
[0007] Step 1: Obtain indicator diagram data, which records the dynamic correspondence between polished rod load and suspension point displacement;
[0008] Step 2: Clean, align, and normalize the dynamometer data. The data obtained after normalization is the dynamometer load-specific data.
[0009] Step 3: Based on the load-specific data of the dynamometer diagram, a time series sample set is constructed;
[0010] Step 4: Build and train a convolutional bidirectional time series model;
[0011] Step 5: Apply the trained convolutional bidirectional time series model to the prediction of the pumping unit indicator diagram at the oil well site.
[0012] Furthermore, the specific process of step 2 is as follows:
[0013] Step 2.1: Clean the dynamometer data. The specific process is as follows: First, perform a non-null value integrity check to remove well records with null values in the load-displacement data dimension. Then, use directional extraction to obtain a dynamometer time series data set with block affiliation, well group affiliation, acquisition time, and time series characteristics.
[0014] Step 2.2: Align the dynamometer data. The specific process is as follows:
[0015] Step 2.2.1. Divide the displacement load data points of the dynamometer diagram into upstroke data and downstroke data. Add the downstroke data in reverse order after the upstroke data. The calculation formula is as follows:
[0016] (1);
[0017] in, It is the displacement point of the downstroke after splicing; is the maximum displacement value of the dynamometer diagram; It is the displacement point of the downstroke before splicing;
[0018] Step 2.2.2: Determine the fixed difference displacement point, keeping the number of data points before and after interpolation unchanged. The formula is:
[0019] (2);
[0020] in, is the fixed difference displacement point; is the number of data points after data alignment; A function that generates a specific sequence of values;
[0021] Step 2.2.3. Use cubic spline interpolation to interpolate the original data. Fit a cubic polynomial between every two adjacent displacement load points, ensuring that the first-order and second-order derivatives of each segment of the polynomial are continuous at the connection and that the natural boundary condition of the second-order derivative being zero at the endpoints is met. This generates a smooth curve, and then obtains the load data at the fixed differential displacement points. The interpolated displacement load data replaces the original displacement load data to obtain new indicator diagram data for the same differential displacement points.
[0022] Step 2.3: Normalize the new dynamometer data. The data obtained after normalization is the dynamometer load-specific data. The specific formula is as follows:
[0023] (3);
[0024] (4);
[0025] in, is the normalized displacement; is the actual displacement; is the minimum displacement value of the dynamometer diagram; is the normalized load value; is the actual load value; 、 are the maximum load value and the minimum load value respectively.
[0026] Furthermore, the specific process of step 3 is as follows:
[0027] Step 3.1: Group the load-specific data of the dynamometer diagram by block and well group, ensuring that the data of the well group in each block is processed independently, and treat a section of time series data of a well in a block as a sample;
[0028] Step 3.2: Sort the data in each block and well group by acquisition time;
[0029] Step 3.3: Use the sliding window sampling method to extract data pairs for the past 28 days and the next 28 days from the data of each block and well group. The specific process of the sliding window sampling method is as follows: starting from the starting position of the time series data, select windows of length 56 in sequence with a step size of 1 until no complete window can be formed; for each window, the first 28 data points are used as historical data and the last 28 data points as future data, thus extracting data pairs for the past 28 days and the next 28 days;
[0030] Step 3.4: Collect the data pairs of all blocks to obtain the final time series sample set;
[0031] Step 3.5: Divide the final time series sample set into training set, validation set and test set in proportion.
[0032] Furthermore, the specific process of step 4 is as follows:
[0033] Step 4.1: Construct a convolutional bidirectional time series model for dynamometer data prediction. The convolutional bidirectional time series model consists of a one-dimensional convolutional layer, two bidirectional long short-term memory layers, and a time-distributed fully connected layer.
[0034] Step 4.2: Input the training set divided in step 3.5 into the model for model training, and then evaluate the model performance based on the test set and validation set to check the generalization ability of the model.
[0035] Furthermore, in step 4.1, the specific working process of the convolutional bidirectional time series model is as follows:
[0036] Step 4.1.1: The one-dimensional convolutional layer processes the input data and determines the initial target features.
[0037] Step 4.1.2: Input the initial target features into the first bidirectional long short-term memory network layer to confirm the first temporal target features;
[0038] Step 4.1.3: Input the first temporal target feature into the second bidirectional long short-term memory network layer to confirm the second temporal target feature;
[0039] Step 4.1.4: Input the second time series target feature into the time distribution fully connected layer to obtain the future dynamometer data prediction result.
[0040] Furthermore, in step 4.2, the prediction accuracy of the convolutional bidirectional time series model is evaluated using the mean absolute error and relative mean error, and the formulas are:
[0041] (5);
[0042] (6);
[0043] in, is the mean absolute error; is the relative average error; For the The true value of the samples; For the The predicted value of samples; is the sample size;
[0044] Calculate the mean absolute error and relative mean error of the training set, validation set, and test set respectively, and then compare them. Output the model that meets the specified conditions; otherwise, re-collect data in step 1 for model training;
[0045] The specified conditions are: when the relative average errors of the test set and the validation set are both smaller than the relative average error of the training set, or the difference between the relative average error of the test set and the relative average error of the training set is smaller than or equal to the preset threshold.
[0046] Furthermore, in step 5, the dynamometer diagram data of the oil pumping unit in the oil field is obtained in real time, and is processed according to the process of steps 1 and 2 to obtain the dynamometer diagram load specific data. The dynamometer diagram load specific data is input into the trained model to calculate the future dynamometer diagram of the oil pumping unit in real time, thereby realizing continuous prediction of the dynamometer diagram of the oil pumping unit.
[0047] The beneficial technical effects brought about by the present invention are as follows: the convolution bidirectional timing dynamometer diagram prediction method based on specific data driving is concise and practical. Compared with the existing dynamometer diagram prediction method, it has the ability to accurately predict a variety of working conditions, even complex combination working conditions, so as to gain more time for pump repair after inspection. At the same time, it has the characteristics of fast calculation speed, low economic cost and high characterization accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 The present invention is a flow chart of a convolution bidirectional timing indicator diagram prediction method based on specific data driving.
[0049] Figure 2 This is a graph showing the prediction results of the future dynamometer diagram under complex working conditions dominated by gas influence using the convolution bidirectional time series model in the experiment of the present invention.
[0050] Figure 3 This is the prediction result of the future dynamometer diagram under complex working conditions dominated by wax deposition using the convolution bidirectional time series model in the experiment of the present invention.
[0051] Figure 4 This is a line graph of the training set and validation set training rounds and the mean absolute error in the experiment of the present invention. DETAILED DESCRIPTION
[0052] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments:
[0053] This paper proposes a method for predicting a convolutional bidirectional time-series dynamometer diagram based on specific data. Before constructing a convolutional bidirectional time-series model, the differential displacement points are fixed and cubic spline interpolation is performed on the dynamometer diagram load data to simplify the prediction target to load, thereby reducing model complexity and improving prediction accuracy. First, dynamometer diagram data containing block, well group, acquisition time, and time-series characteristics is acquired. The acquired data is cleaned, aligned, and normalized. The normalized data is the dynamometer diagram load-specific data. Based on the dynamometer diagram load-specific data, a time-series sample set is constructed using features such as block and well group. A convolutional bidirectional time-series model for the dynamometer diagram is constructed and trained based on the processed time-series sample set. The dynamometer diagram is predicted based on the trained convolutional bidirectional time-series model. The present invention predicts the dynamometer diagram using a deep learning method. The model is evaluated using mean absolute error, and the generalization ability of the model is checked using test set data. Finally, the trained model is used to calculate the future dynamometer diagram of the oil well pumping unit.
[0054] A convolutional bidirectional timing indicator diagram prediction method based on specific data drive, the brief process is as shown in the attached Figure 1 As shown, the specific steps include:
[0055] Step 1: Obtain dynamometer diagram data. The dynamometer diagram fully presents the mechanical characteristics of the equipment during the complete stroke cycle by recording the dynamic correspondence between the polished rod load and the suspension point displacement. Obtaining high-quality dynamometer diagram data is key to ensuring the accuracy of the dynamometer diagram prediction.
[0056] Step 2: Clean, align, and normalize the dynamometer data. The data obtained after normalization is the dynamometer load-specific data. The specific process is as follows:
[0057] Step 2.1: Dynamometer diagram data cleaning. First, a non-null value integrity check is performed to eliminate well records with null values in the load-displacement data dimension. Then, through directional extraction, a dynamometer diagram time series data set with block affiliation, well group affiliation, acquisition time, and time series characteristics is obtained. This prepares for the subsequent construction of a dynamometer diagram sample set with spatiotemporal correlation characteristics.
[0058] Step 2.2: Align the dynamometer data with sufficient features. Since the dynamometer collects displacement and load data at time intervals within a stroke, rather than load data at displacement intervals, the displacement and load of each point in the dynamometer data at adjacent time intervals are changing. For the prediction problem of the dynamometer diagram, obtaining the displacement and its corresponding load at the same time will increase the complexity of the model. Therefore, by performing load interpolation processing on each set of dynamometer diagram data, fixing the difference displacement points, and only predicting the load, the complexity of the model is simplified. The details are as follows:
[0059] Step 2.2.1: First, divide the displacement load data points of the dynamometer diagram into upstroke data and downstroke data. To maintain the temporal continuity of each dynamometer diagram data, the downstroke data is spliced in reverse order after the upstroke data. The calculation formula is as follows:
[0060] (1);
[0061] in, It is the displacement point of the downstroke after splicing; is the maximum displacement value of the dynamometer diagram; It is the displacement point of the downstroke before splicing;
[0062] Step 2.2.2: Determine the fixed difference displacement point, keeping the number of data points before and after interpolation unchanged. The formula is:
[0063] (2);
[0064] in, is the fixed difference displacement point; is the number of data points after data alignment; is a function that generates a specific sequence of values. The starting value is , the termination value is , Represents the interval of each increase or decrease.
[0065] Step 2.2.3: Use cubic spline interpolation to interpolate the original data. By fitting a cubic polynomial between every two adjacent displacement load points, ensure that the first-order derivative and second-order derivative of each polynomial segment at the connection are continuous and meet the natural boundary condition that the second-order derivative at the endpoint is zero, thereby generating a smooth curve and obtaining the load data at the fixed differential displacement point. The displacement load data obtained by interpolation is used to replace the original displacement load data to obtain the dynamometer data of the same differential displacement point.
[0066] Step 2.3: Normalize the new dynamometer data. The data obtained after normalization is the dynamometer load-specific data. The specific formula is as follows:
[0067] (3);
[0068] (4);
[0069] For each point in the dynamometer data series, is the normalized displacement; is the actual displacement; is the minimum displacement value of the dynamometer diagram; is the normalized load value; is the actual load value; 、 are the maximum load value and the minimum load value respectively;
[0070] Since each set of displacement data is the same after normalization, only the normalized load data needs to be predicted.
[0071] Step 3: Based on the load-specific data of the dynamometer diagram, a time series sample set is constructed by using characteristics such as blocks and well groups. The specific process is as follows:
[0072] Step 3.1: Group the load-specific data of the dynamometer diagram by block and well group, ensuring that the data of the well group in each block is processed independently. The time series data of a well in a block is used as a sample.
[0073] Step 3.2: Sort the data in each block and well group by acquisition time to ensure the temporal sequence of the data;
[0074] Step 3.3: Use the sliding window sampling method to extract data pairs for the past 28 days and the next 28 days from the data of each block and well group. The specific process of the sliding window sampling method is as follows: Starting from the beginning of the time series data, select windows of length 56 in steps of 1 until no complete window can be formed. For each window, the first 28 data points are used as historical data, and the last 28 data points as future data, thus extracting data pairs for the past 28 days and the next 28 days. In this way, multiple input-output sample pairs can be extracted from the time series data to construct a time series sample set.
[0075] Step 3.4: Collect all the data pairs of the blocks to obtain the final time series sample set. The time series sample set includes the input sample set and the output sample set. The data of all blocks in the past 28 days is the input sample set, and the data of all blocks in the next 28 days is the output sample set.
[0076] Step 3.5: Divide the final time series sample set into training set, validation set, and test set in proportion; specifically, divide the input sample set and output sample set in the time series sample set into training set, validation set, and test set in a ratio of 70%:15%:15%.
[0077] Step 4: Build and train a convolutional bidirectional time series model;
[0078] Step 4.1: Construct a convolutional bidirectional time series model for dynamometer data prediction. The convolutional bidirectional time series model mainly consists of a one-dimensional convolutional layer, two bidirectional LSTM (long short-term memory) layers, and a time-distributed fully connected layer. The specific working process of the convolutional bidirectional time series model is as follows:
[0079] Step 4.1.1: The one-dimensional convolutional layer processes the input data and determines the initial target features.
[0080] Step 4.1.2: Input the initial target features into the first bidirectional LSTM layer to confirm the first temporal target features;
[0081] Step 4.1.3: Input the first time series target feature into the second bidirectional LSTM layer to confirm the second time series target feature;
[0082] Step 4.1.4: Input the second time series target feature into the time distribution fully connected layer to obtain the future dynamometer data prediction result.
[0083] The parameters and specific settings of the convolutional bidirectional time series model are as follows:
[0084] The number of convolution kernels is 128; the convolution kernel size is 3; the stride size is 1; the padding method is causal padding; the number of units in the first bidirectional LSTM layer is 128; the number of units in the second bidirectional LSTM layer is 128; the normalization method is MaxMin normalization (deviation normalization); the optimizer is Adam; the loss function is mean square error (MSE); the number of iterations is 50; and the training batch size is 16.
[0085] The input dimension of the model is ( ,28,200), where is the number of samples, 28 is the time step, 200 is the feature dimension, and the data dimension of the input layer after a layer of one-dimensional convolution becomes ( ,28,256), and then pass through two bidirectional LSTM layers in sequence. Since the load of the next 200 points needs to be output in the end, a time-distributed fully connected layer with 200 neurons is added for each time step to obtain the final output.
[0086] Step 4.2: Input the training set divided in step 3.5 into the model for model training, and then evaluate the model performance based on the test set and validation set to check the generalization ability of the model; the present invention uses the mean absolute error (MAE) and relative mean error (MRE) to evaluate the prediction accuracy of the convolutional bidirectional time series model, and the formulas are:
[0087] (5);
[0088] (6);
[0089] in, is the mean absolute error; is the relative average error; For the The true value of the samples; For the The predicted value of samples;
[0090] Calculate the mean absolute error and relative mean error for the training set, validation set, and test set, respectively, and then compare them. The smaller the mean absolute error, the better the model's prediction effect. When the relative mean errors of the test set and validation set are both less than or slightly greater than the relative mean error of the training set, it indicates that the network model can be output. When any relative mean error in the test set or validation set is much greater than the relative mean error of the training set, it indicates that the model may be overfitting and cannot generalize well to new data. Return to step 1 to collect new data for model training. The judgment standard for slightly greater than is the difference between the relative mean error of the test set and the relative mean error of the training set, is less than or equal to the preset threshold. The judgment standard for much greater than is the difference between the relative mean error of the test set and the relative mean error of the training set, is greater than the preset threshold.
[0091] Step 5: Apply the convolutional bidirectional time series model trained in Step 4 to predict the dynamometer diagram of the oil well pumping unit. The dynamometer diagram data of the oil well pumping unit is acquired in real time and processed according to Steps 1 and 2 to obtain the dynamometer load-specific data. This dynamometer load-specific data is input into the trained model to calculate the future dynamometer diagram of the pumping unit in real time, thereby achieving continuous prediction of the dynamometer diagram of the pumping unit.
[0092] In order to demonstrate the feasibility of the method of the present invention, the following experiments were conducted.
[0093] The experimental data comes from a block in a certain oil field. The formation in the block to be studied has several oil wells and contains data under several different production systems.
[0094] Through steps 2 and 3, we collated the historical production data of the oil wells in this block, yielding a total of 6,982 valid datasets. The resulting time series sample set was randomly divided into training, validation, and test sets according to a specific ratio (training set: validation set: test set = 70%:15%:15%). The training set contained 4,886 data items, the validation set 1,048 data items, and the test set 1,048 data items. Table 1 shows some of the historical displacement data for the oil wells in this block.
[0095] Table 1. Some historical displacement data of oil wells in a certain block
[0096] .
[0097] As shown in Table 1, the length of displacement data for each well is consistent, but the length of displacement data between each well is inconsistent. First, use formula (1) to splice the downstroke data in reverse order after the upstroke data.
[0098] Some historical load data of oil wells in a certain block are shown in Table 2.
[0099] Table 2 Historical load data of some oil wells in a certain block
[0100] .
[0101] As shown in Table 2, it can be seen that the length of the load data for each well is consistent with the length of the displacement data. After determining the fixed difference displacement point using formula (2), the load data at the fixed difference displacement point is interpolated, and the newly obtained displacement load data is used to replace the original displacement load data. Then, formulas (3) and (4) are used to normalize the displacement data and load data respectively. The normalized displacement data are the same, so only the normalized load data needs to be predicted. The load data of the historical 28-day indicator diagram is used as the input of the model, and the model outputs the indicator diagram for the next 28 days. The training set is input into the model, and the model is trained to obtain the trained convolutional bidirectional time series model. The training set, validation set, and test set are respectively input into the trained model, and their MAE and MRE are calculated using formulas (5) and (6), respectively. The results are shown in Table 3.
[0102] Table 3. Mean absolute error and relative mean error results of training set, validation set and test set
[0103] .
[0104] As can be seen from Table 3, the mean relative error (MRE) of the validation set and the test set is smaller than that of the training set, indicating that the network has good generalization ability. The trained convolutional bidirectional time series model can be used to predict the future dynamometer diagram of the oil well pumping unit.
[0105] Some of the results calculated based on the convolutional bidirectional timing model are as follows Figure 2 、 Figure 3 As shown, Figure 2 It is the prediction result of the future dynamometer diagram under complex working conditions dominated by gas influence using the convolution bidirectional time series model. Figure 3 The convolutional bidirectional time series model is used to predict the future dynamometer data under complex operating conditions dominated by wax deposition. Both figures show that the model's prediction of the dynamometer data for the next 28 days based on the historical 28 days of dynamometer data maintains the trend of changing operating conditions. This trend can provide reference information for judging the severity of subsequent operating conditions in the oil field.
[0106] Table 4. Partial training rounds of the training set and validation set and the corresponding mean absolute error results
[0107] .
[0108] The training rounds and the corresponding mean absolute error (MAE) obtained from the training set and validation set are calculated, as shown in Table 4 (due to the large amount of data, Table 4 only shows part of the data); draw their line graphs, as shown in Figure 4 shown.
[0109] Combined with Table 4 and Figure 4 The training set mean absolute error continued to decrease, indicating that the model was learning from the training data. The gap between the training and validation set mean absolute errors gradually narrowed, and the validation set mean absolute error eventually stabilized at a low level (0.0175), indicating that the model was ultimately stable and had potential for practical application. The load data calculated by this model was very close to the actual load data, meeting the needs of oilfield operating condition diagnosis.
[0110] Of course, the above description is not a limitation of the present invention, and the present invention is not limited to the above examples. Changes, modifications, additions or substitutions made by technicians in this technical field within the essential scope of the present invention should also fall within the scope of protection of the present invention.
Claims
1. A convolutional bidirectional timing indicator diagram prediction method based on specific data driving, characterized in that: The steps include: Step 1: Obtain indicator diagram data, which records the dynamic correspondence between polished rod load and suspension point displacement; Step 2: Clean, align, and normalize the dynamometer data. The data obtained after normalization is the dynamometer load-specific data. The specific process is as follows: Step 2.1: Clean the dynamometer data. The specific process is as follows: First, perform a non-null value integrity check to remove well records with null values in the load-displacement data dimension. Then, use directional extraction to obtain a dynamometer time series data set with block affiliation, well group affiliation, acquisition time, and time series characteristics. Step 2.2, align the dynamometer data; The specific process is: Step 2.2.
1. Divide the displacement load data points of the dynamometer diagram into upstroke data and downstroke data. Add the downstroke data in reverse order after the upstroke data. The calculation formula is as follows: (1); in, It is the displacement point of the downstroke after splicing; is the maximum displacement value of the dynamometer diagram; It is the displacement point of the downstroke before splicing; Step 2.2.2: Determine the fixed difference displacement point, keeping the number of data points before and after interpolation unchanged. The formula is: (2); in, is the fixed difference displacement point; is the number of data points after data alignment; A function that generates a specific sequence of values; Step 2.2.
3. Use cubic spline interpolation to interpolate the original data. Fit a cubic polynomial between every two adjacent displacement load points, ensuring that the first-order and second-order derivatives of each segment of the polynomial are continuous at the connection and that the natural boundary condition of the second-order derivative being zero at the endpoints is met. This generates a smooth curve, and then obtains the load data at the fixed differential displacement points. The interpolated displacement load data replaces the original displacement load data to obtain new indicator diagram data for the same differential displacement points. Step 2.3: Normalize the new dynamometer data. The data obtained after normalization is the dynamometer load-specific data. The specific formula is as follows: (3); (4); in, is the normalized displacement; is the actual displacement; is the minimum displacement value of the dynamometer diagram; is the normalized load value; is the actual load value; 、 are the maximum load value and the minimum load value respectively; Step 3: Based on the load-specific data of the dynamometer diagram, a time series sample set is constructed; Step 4: Build and train a convolutional bidirectional time series model; Step 5: Apply the trained convolutional bidirectional time series model to the prediction of the pumping unit indicator diagram at the oil well site.
2. The method for predicting a convolutional bidirectional timing dynamometer diagram based on specific data drive according to claim 1, characterized in that: The specific process of step 3 is as follows: Step 3.1: Group the load-specific data of the dynamometer diagram by block and well group, ensuring that the data of the well group in each block is processed independently. The time series data of a well in a block is used as a sample. Step 3.2: Sort the data in each block and well group by acquisition time; Step 3.3: Use the sliding window sampling method to extract data pairs for the past 28 days and the next 28 days from the data of each block and well group. The specific process of the sliding window sampling method is as follows: starting from the starting position of the time series data, select windows of length 56 in sequence with a step size of 1 until no complete window can be formed; for each window, the first 28 data points are used as historical data and the last 28 data points as future data, thus extracting data pairs for the past 28 days and the next 28 days; Step 3.4: Collect the data pairs of all blocks to obtain the final time series sample set; Step 3.5: Divide the final time series sample set into training set, validation set and test set in proportion.
3. The method for predicting a convolutional bidirectional timing dynamometer diagram based on specific data drive according to claim 2, characterized in that: The specific process of step 4 is as follows: Step 4.1: Construct a convolutional bidirectional time series model for dynamometer data prediction. The convolutional bidirectional time series model consists of a one-dimensional convolutional layer, two bidirectional long short-term memory layers, and a time-distributed fully connected layer. Step 4.2: Input the training set divided in step 3.5 into the model for model training, and then evaluate the model performance based on the test set and validation set to check the generalization ability of the model.
4. The method for predicting a convolutional bidirectional timing dynamometer diagram based on specific data drive according to claim 3, characterized in that: In step 4.1, the specific working process of the convolutional bidirectional time series model is as follows: Step 4.1.1: The one-dimensional convolutional layer processes the input data and determines the initial target features. Step 4.1.2: Input the initial target features into the first bidirectional long short-term memory network layer to confirm the first temporal target features; Step 4.1.3: Input the first temporal target feature into the second bidirectional long short-term memory network layer to confirm the second temporal target feature; Step 4.1.4: Input the second time series target feature into the time distribution fully connected layer to obtain the future dynamometer data prediction result.
5. The method for predicting a convolutional bidirectional timing dynamometer diagram based on specific data drive according to claim 4, characterized in that: In step 4.2, the prediction accuracy of the convolutional bidirectional time series model is evaluated using the mean absolute error and relative mean error. The formulas are: (5); (6); in, is the mean absolute error; is the relative average error; For the The true value of the samples; For the The predicted value of samples; is the sample size; Calculate the mean absolute error and relative mean error of the training set, validation set, and test set respectively, and then compare them. Output the model that meets the specified conditions; otherwise, re-collect data in step 1 for model training; The specified conditions are: when the relative average errors of the test set and the validation set are both smaller than the relative average error of the training set, or the difference between the relative average error of the test set and the relative average error of the training set is smaller than or equal to the preset threshold.
6. The method for predicting a convolutional bidirectional timing dynamometer diagram based on specific data drive according to claim 5, characterized in that: In step 5, the dynamometer diagram data of the oil pumping unit in the oil field is obtained in real time, and is processed according to the process of steps 1 and 2 to obtain the dynamometer diagram load specific data. The dynamometer diagram load specific data is input into the trained model to calculate the future dynamometer diagram of the oil pumping unit in real time, thereby realizing the continuous prediction of the dynamometer diagram of the oil pumping unit.
Citation Information
Patent Citations
Computing method of API RP 11L sucker-rod oil pumping system based on C # platform
CN116976025A
Fault diagnosis method, computing device and readable storage medium
CN117349726A