Electric submersible pump well yield prediction method fusing electric submersible pump mechanism and large language model
Through the method of integrating the mechanism of electric submarine pumps and large language models, the problem of predicting the production of oil well production relying on data quality and quantity in existing technology, and realizing high -precision and high -speed output prediction. Essence
Patent Information
- Application Number
- CN202411957298.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-01-28
AI Technical Summary
Existing neural network methods rely on data quality and quantity in oil well output prediction, ignoring domain knowledge, resulting in insufficient generalization capabilities of the model and improper handling of abnormal situations.
The output prediction method of submarine electric pump wells with a fusion electric submarine pump mechanism and large language model is adopted. By collecting historical production data, analyzing the attributes of electric pump wells, building the electrical pump well mechanism model, and combining large language models for training and errors Correction, eventually the output prediction results were obtained.
A high -precision, high -speed oil well output prediction, comprehensive consideration of knowledge in the fields of physics, mathematics and fluid mechanics, and improved the generalization ability of the model and the processing ability of abnormal conditions.
Smart Images

Figure CN119378767A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of oil well production prediction, and in particular to a submersible electric pump well production prediction method integrating an electric submersible pump mechanism and a large language model. Background Art
[0002] Electric submersible pump wells (electric pump wells for short) are a common artificial lift device in oil and gas extraction, with significant advantages such as large displacement, high head and operational flexibility. The system transports underground liquids (such as crude oil) to the surface through a multi-stage centrifugal pump installed in the wellbore, and is particularly suitable for oil wells with insufficient self-flow or poor liquid fluidity. With its efficient lifting capacity, electric pump wells are widely used in the development of high-yield oil wells, deep wells and old oil fields, playing a key role in improving recovery.
[0003] In oilfield production forecasting, the production fluctuation of oil wells is affected by the interweaving of many factors, including geological conditions, equipment operating status, temperature, pressure, and the interaction between different oil fields. The downhole high-pressure environment may cause the pressure in the oil well to rise, thereby affecting the performance of the pump. Especially under long-term operation, the wear and failure of oil well equipment may threaten the stability of production. In addition, the production data monitored in real time by oil well sensors usually form a long time series, and there is an obvious time dependence between these data, so historical data occupies an important position in the current production forecast. What is more complicated is that the spatial characteristics between the wellhead and the bottom of the oil well are very complex and varied. For example, the pressure difference between the high-pressure bottom of the well and the low-pressure wellhead directly affects the flow and production efficiency of oil and gas. The interaction of these geological, equipment, temperature and pressure factors, combined with time dependence and spatial characteristics, jointly determines the production performance of the oil field. Therefore, accurate prediction of oil field production is the key to improving production efficiency, optimizing resource allocation, and formulating reasonable mining strategies.
[0004] In recent years, with the rapid development of artificial intelligence, deep learning methods have gradually been used for oil well production prediction. For example, CN118365183A discloses a hybrid neural network-based oil well production prediction method and system. The neural network-based oil well production prediction method includes: step 1, obtaining oil well production data for processing; step 2, building a hybrid neural network; step 3, inputting production data as a training set into the network for training; step 4, obtaining a production prediction model; step 5, inputting production data to predict production. However, existing neural network methods are too dependent on data quality and quantity, and whether the data contains enough information to describe the complexity of the system, ignoring domain knowledge (such as expert experience and physical principles), which may lead to insufficient model generalization ability or improper handling of abnormal situations. Summary of the invention
[0005] The purpose of the present invention is to overcome the shortcomings of the prior art and to provide a high-precision and high-speed method for predicting the production of submersible electric pump wells by integrating the mechanism of electric submersible pumps and a large language model.
[0006] To achieve the above object, the present invention adopts the following technical solutions:
[0007] A method for predicting the production of submersible electric pump wells by integrating the mechanism of electric submersible pumps and a large language model, the specific steps are as follows: S1. Collect historical production data of the oil field as a sample data set, and divide the sample data set into a training set, a validation set, and a test set after preprocessing; S2. According to the attributes of all wells in the electric pump well attribute database, the correlation between the flow rate, flow velocity, pressure drop, head and power of the same well is analyzed to obtain the storage and transportation mechanism knowledge applicable to the actual electric pump well, and the storage and transportation mechanism knowledge is characterized; S3, based on the characterization results of step S2, further refine the characterization results according to the mass conservation equation and the momentum equation, and comprehensively obtain the electric pump well mechanism model; S4. Combined with the gathering and transportation pipeline network of the electric pump well, the attribute parameters of the single well in the gathering and transportation pipeline network are input into the pre-trained large language model to construct a large language model integrating mechanism knowledge; S5, setting the model parameters of the large language model integrating the mechanism knowledge obtained in step S4, and using the training set to train the network model with the set parameters. During the training process, the pressure, temperature and output of each part of the electric pump well pipe network are continuously calculated through the mechanism knowledge, and the change trend at each iteration is analyzed until the model training is completed; S6, based on the result obtained in step S5, using the coefficient of determination, mean square error and mean absolute error as evaluation indicators to evaluate the large language model integrating the mechanism knowledge; S7. Combined with the evaluation result in step S6, the data of the test set is input into the large language model integrating the mechanism knowledge for prediction, and the prediction result of the production of each electric pump well in the electric pump well network is obtained.
[0008] As a further technical solution of the present invention, the historical production data described in step S1 includes well number, collection time, pump depth, current, voltage, power consumption, electric pump power, overall efficiency, wellhead diameter, density, oil pressure, flow pressure, bottom hole flow rate, wellhead temperature, water content, and daily liquid production, wherein the daily liquid production is the total liquid production of a single well on that day, which is obtained by reading the flow meter installed at the wellhead of the oil well in the crude oil production area; current, voltage, power consumption, electric pump power, overall efficiency, density, oil pressure, flow pressure, bottom hole flow rate, wellhead temperature, and water content are obtained using sensors installed at the crude oil production site, and the ratio of the number of training sets, validation sets, and test sets is 7:1.5:1.5.
[0009] As a further technical solution of the present invention, the preprocessing of the sample data set in step S1 includes data cleaning and processing, identifying and filling missing data, and removing and correcting abnormal data. First, the Z-score method is used to detect outliers in the data, and the data is defined. The Z-score is: ,in, and are the mean and standard deviation of the data respectively. (Usually take ) The detected outliers are considered as outliers. For the detected outliers, the K nearest neighbor (KNN) algorithm is used for interpolation repair to find the K normal data points that are close to the outliers in the time series. , outliers are replaced by calculating the weighted average of these neighboring data points: ; Then use the moving average method to smooth the abnormal data, set the window size to 5, calculate the average value of the data points in the window around the abnormal point, replace the abnormal data point with the calculated value, and use the mean square error method to quantify the data difference.
[0010] As a further technical solution of the present invention, the electric pump well attributes in step S2 include wellbore pressure, fluid density, flow velocity, and flow rate; the storage and transportation mechanism knowledge includes continuity equation, head formula, power formula, and formation seepage pressure drop equation. The result of characterizing the storage and transportation mechanism knowledge is: According to the momentum equation, the pressure drop process of the fluid can be described by the movement of the wellbore fluid: ,in, Indicates the pressure in the wellbore. is the well depth direction, is the fluid density, is the acceleration due to gravity, is the friction factor, is the flow rate, is the wellbore diameter; Continuity equation Describe the relationship between flow rate and flow velocity, where It's traffic. is the cross-sectional area of the wellbore; The working performance of the electric submersible pump is described by the head formula and the power formula, where the head formula is: ,in, It is the lift. is the maximum lift, is the pump characteristic coefficient, and the power formula is: ,in, is power, is the efficiency of the pump; The flow of fluid in the formation is described by the formation seepage pressure drop equation (Darcy's law): ,in, is the flow rate, is the formation permeability, is the fluid viscosity, is the pressure gradient.
[0011] As a further technical solution of the present invention, step S3 further refines the process of characterizing the results as follows: The pressure diffusion equation is used to describe the change of pressure over time: ,in is the reservoir porosity, It's pressure. It's time. is the gradient operator; When dealing with three-phase flow containing oil, gas and water, the mass conservation equation is used to describe the mass conservation of each phase: ,in is the phase saturation, is the phase density, is the phase velocity, is the source-sink term; The momentum equation describes the flow velocity of each phase: ,in, is the phase permeability, is the phase viscosity, is the permeability tensor, is the pressure gradient, is the phase density, is the acceleration due to gravity, is the change in depth direction; The obtained electric pump well mechanism model is: , in, is the mass density of the fluid, is the mass flow rate of the fluid, is the source-sink term, is the pressure drop in the wellbore, is the additional pressure drop caused by friction, is the head of the electric submersible pump, It is the relationship between flow rate and flow velocity.
[0012] As a further technical solution of the present invention, the construction process of the large language model integrating mechanism knowledge in step S4 is as follows: S41, input patching, multivariate time series Divide into Univariate time series , firstly reversible instance normalization (RevIN) is used to normalize each input channel, and then each sequence is divided into multiple overlapping patches with a patch length of , the horizontal sliding step is , calculate the total number of patches as , each patch is embedded into a low-dimensional space and converted to ,in is the embedding dimension; S42, patch reprogramming, introduce hint prefixes, convert the time series data of the electric pump well into a representation space compatible with the large language model to align the time series parameter modality of the electric pump well with the modality of the natural language. When aligning, a set of text prototypes is learned by introducing a multi-head cross-attention layer. The text prototype From pre-trained word embeddings via linear projection To form a language description corresponding to the state of the electric pump well, the working process of the multi-head cross attention layer is: , , , , , By aggregating the output of each head , and get the overall patch representation , then Linear projection to the dimension aligned with the hidden layer of the base model forms the output representation of the reprogrammed patch ; S43, patch to be reprogrammed Used to generate the final yield forecast, discard the prompt prefix, keep only the forecast result, and obtain the final forecast result after linear projection .
[0013] As a further technical solution of the present invention, the model parameters described in step S5 include the number of text prototypes, the number of backbone model layers, input length, patch dimension, optimizer, activation function and number of iterations, wherein the number of text prototypes is 1000, the number of backbone model layers is 32, and the input length is 512, indicating the number of production data input to the model; the patch dimension is 16, representing the hidden dimension of the embedded patch before the large language model is reprogrammed; the optimizer adopts the Adam optimizer, the activation function is the RELU activation function, and the number of iterations is 100.
[0014] As a further technical solution of the present invention, the calculation formulas of the determination coefficient, mean square error and mean absolute error in step S6 are as follows: Coefficient of determination , Mean square error , Mean absolute error , in is the number of observations, It is The true value of an observation, It is The predicted value of an observation, yes The average value of the real data.
[0015] Compared with the prior art, the present invention has the following beneficial effects: (1) A new prediction method based on the dual drive of "mechanism + data" is proposed. Dynamic and static data are collected and input into the mechanism model of the electric pump well. After calculating the error, the error is corrected using the large model. Finally, the correction result is re-input into the mechanism model to obtain the production value.
[0016] (2) By integrating physics, mathematics, fluid mechanics, mechanics, etc., a universal electric pump well mechanism model is proposed, which includes all parameters in the oil production process of electric pump wells.
[0017] (3) Based on the large language model (LLM model), a reprogramming module and a text mapping module were introduced to transform the time series prediction task into a language task. The large language model was successfully applied to the field of oil well production prediction and achieved good results. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 It is a flowchart of the method for predicting the production of a submersible electric pump well according to the present invention; Figure 2 1 is a comparison chart of the predicted production value and the actual value of a certain oil field from July 2023 to June 2024 in an embodiment of the present invention, (a)-(f) are comparison charts of the predicted production value and the actual value of well 1-well 6, respectively. DETAILED DESCRIPTION
[0019] In order to make the technical problems, technical solutions and advantages to be solved by the present invention clearer, the following will be described in detail with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0020] Example: like Figure 1As shown, this embodiment provides a data-driven oilfield electric pump well production prediction method integrating mechanism knowledge, which mainly includes seven steps: data set collection and preprocessing, storage and transportation mechanism knowledge establishment and characterization, electric pump well mechanism model construction, large language model construction integrating mechanism knowledge, large language model training, large language model evaluation and production prediction, specifically: S1. Dataset collection and preprocessing: S11. Obtain the real-time dynamic data generated every minute by the entire electric pump well network of an oil field from January 2021 to June 2023, a total of 2.5 years, including well number, acquisition time, pump depth, current, voltage, power consumption, electric pump power, overall efficiency, wellhead diameter, density, oil pressure, flow pressure, bottom hole flow rate, wellhead temperature, water content, and daily liquid production, and use it as a data set ; S12. Dataset Preprocessing is performed to obtain the preprocessed data set. In offshore oil fields, due to sensor failure, unstable network signals, power supply, extreme weather and other reasons, there are missing and abnormal data in the data set. Therefore, data cleaning and processing technology is needed to identify and fill missing data, remove and correct abnormal data, and improve data quality. First, the Z-score method is used to detect outliers in the data and define the data The Z-score is: ,in, and are the mean and standard deviation of the data respectively. (This embodiment takes ) The detected outliers are considered as outliers. For the detected outliers, the K nearest neighbor (KNN) algorithm is used for interpolation repair to find the K normal data points that are close to the outliers in the time series. , outliers are replaced by calculating the weighted average of these neighboring data points: ,This method effectively utilizes the information of neighboring normal values in time series data, ensuring the smoothness and accuracy of the interpolation results; then, the moving average method is used to smooth the abnormal data. First, the window size is set to 5, and then the average value of the data points in the window around the abnormal point is calculated, and the abnormal data point is replaced with the calculated value. Finally, the mean square error method is used to quantify the data difference; S13. Divide the preprocessed data set into training set, validation set and test set in a ratio of 7:1.5:1.5. The training set is used to train the large language model, the validation set is used to adjust the model's hyperparameters and evaluate the model's capabilities, and the test set is used to test the accuracy and feasibility of the model after the model training is completed.
[0021] S2. Knowledge building and characterization of storage and transportation mechanisms: According to the attributes of all wells in the electric pump well attribute database, the correlation between the flow rate, flow velocity, pressure drop, head, and power of the same well is analyzed to obtain the storage and transportation mechanism knowledge applicable to the actual electric pump well, and the storage and transportation mechanism knowledge is characterized; the electric pump well attributes include wellbore pressure, fluid density, flow velocity, and flow rate; the storage and transportation mechanism knowledge includes the continuity equation, head formula, power formula, and formation seepage pressure drop equation, specifically: According to the momentum equation, the pressure drop process of the fluid can be described by the movement of the wellbore fluid: ,in, Indicates the pressure in the wellbore. is the well depth direction, is the fluid density, is the acceleration due to gravity, is the friction factor, is the flow rate, is the wellbore diameter; Continuity equation Describe the relationship between flow rate and flow velocity, where It's traffic. is the cross-sectional area of the wellbore; this formula helps to predict the flow state and pressure distribution of the liquid in the wellbore; The working performance of the electric submersible pump is described by the head formula and the power formula, where the head formula is: ,in, It is the lift. is the maximum lift, is the pump characteristic coefficient, and the power formula is: ,in, is power, The efficiency of the pump; by quantifying the power required by the ESP at different flow rates and heads, the pump selection and energy consumption can be optimized; The flow of fluid in the formation is described by the formation seepage pressure drop equation (Darcy's law): ,in, is the flow rate, is the formation permeability, is the fluid viscosity, is the pressure gradient. This formula facilitates understanding of the flow characteristics of fluids in formations.
[0022] S3. Construction of electric pump well mechanism model: Based on the mechanism formula obtained in step S2, the model formula is further refined according to the mass conservation equation and momentum equation, and the final electric pump well mechanism model is obtained comprehensively; specifically: The pressure diffusion equation is used to describe the change of pressure over time: ,in is the reservoir porosity, It's pressure. It's time. It is a gradient operator; the pressure diffusion equation helps to analyze the bottom hole pressure changes and predict the dynamic changes of the fluid; When dealing with three-phase flow containing oil, gas and water, the mass conservation equation is used to describe the mass conservation of each phase: ,in is the phase saturation, is the phase density, is the phase velocity, is the source-sink term; The momentum equation describes the flow velocity of each phase: ,in, is the phase permeability, is the phase viscosity, is the permeability tensor, is the pressure gradient, is the phase density, is the acceleration due to gravity, It is the change in depth direction; the flow characteristics of multiphase fluid in the reservoir are described and predicted by momentum equation; The obtained electric pump well mechanism model is: , in, is the mass density of the fluid, is the mass flow rate of the fluid, is the source-sink term, is the pressure drop in the wellbore, is the additional pressure drop caused by friction, is the head of the electric submersible pump, It is the relationship between flow rate and flow velocity.
[0023] S4. Construction of a large language model integrating mechanism knowledge: Combined with the gathering and transportation network of the electric pump well, the attribute parameters of the single well in the gathering and transportation network are input into the pre-trained large language model to build a large language model that integrates mechanism knowledge. The large language model (LLM model) is mainly used to learn patterns and laws from historical data to predict production parameters or compensate for the errors of the mechanism model. Through training, LLM can capture nonlinear relationships and complex dynamic behaviors, thereby improving the accuracy of predictions, that is, solving the following problem: given a set of variables, across Historical observation data of time steps , using large language models These time series are processed to predict the future The result of the time step is denoted as In order to ensure that the model can learn effectively, this embodiment sets the goal to minimize the predicted value and the true value The mean square error between them is calculated as: , the specific steps are as follows: S41, input patching, multivariate time series Divide into Univariate time series In order to mitigate the distribution drift of time series, reversible instance normalization (RevIN) is used to normalize each input channel, and each sequence is divided into multiple overlapping patches with a patch length of , the horizontal sliding step is , calculate the total number of patches as , each patch is embedded into a low-dimensional space and converted to ,in is the embedding dimension; S42, patch reprogramming, introduce hint prefixes, convert the time series data of the electric pump well into a representation space compatible with the large language model to align the time series parameter modality of the electric pump well with the modality of the natural language. The hint prefix not only serves as a connection tool to enhance the adaptability of the language model to specific tasks, but also guides the model to focus on key features, deeply captures complex relationships, and improves the model's time series understanding and reasoning capabilities; alignment is achieved by introducing a multi-head cross-attention layer to learn a set of text prototypes, the text prototype From pre-trained word embeddings via linear projection The multi-head cross attention layer works as follows: , , , , , By aggregating the output of each head , and get the overall patch representation , then Linear projection to the dimension aligned with the hidden layer of the base model forms the output representation of the reprogrammed patch ; S43, patch to be reprogrammed Used to generate the final yield forecast, discard the prompt prefix, keep only the forecast result, and obtain the final forecast result after linear projection .
[0024] S5. Large language model training integrating mechanism knowledge: The model parameters of the large language model integrating the mechanism knowledge obtained in step S4 are set, and the network model with the set parameters is trained using the training set. During the training process, the pressure, temperature and output of each part of the electric pump well network are continuously calculated through the mechanism knowledge, and the changing trend at each iteration is analyzed until the model training is completed. In this embodiment, the model parameters include the number of text prototypes, the number of backbone model layers, the input length, the patch dimension, the optimizer, the activation function and the number of iterations, wherein the number of text prototypes is maintained at 1000 and the number of backbone model layers is maintained at 32; the input length is 512, indicating the number of production data input to the model; the patch dimension is 16, representing the hidden dimension of the patch embedded before the LLM model is reprogrammed; the optimizer adopts the Adam optimizer, the activation function is the RELU activation function, and the number of iterations is 100.
[0025] S6. Evaluation of large language models integrating mechanistic knowledge: After the large language model integrating mechanism knowledge is trained, the determination coefficient R is used 2 , mean square error MSE, mean absolute error MAE are used as evaluation indicators to evaluate the model, and the determination coefficient , mean square error , mean absolute error ,in is the number of observations, It is The true value of an observation, It is The predicted value of an observation, yes The average value of the real data.
[0026] S7. Output forecast: The production data of the electric pump well network from July 2023 to June 2024 is used for prediction, so as to obtain the prediction results of the production of each well. The comparison curve between the predicted value and the actual value of the six wells 1 to 6 is shown as follows: Figure 2 As shown, the horizontal axis represents the number of days, the vertical axis represents the daily liquid production value, the orange curve represents the model prediction value, and the red curve represents the actual measurement value of the oil field. It can be seen that the errors of both are within 5%, which is within the acceptable error range of the oil field production area, so it can be applied in the production environment.
[0027] This embodiment designs a hybrid modeling method that integrates the mechanism model of the electric pump well and the LLM large language model for real-time production prediction of the electric pump well. With the help of knowledge in the fields of fluid mechanics, mechanics, artificial intelligence, etc., the mechanism model of the electric pump well is constructed to simulate the electric submersible pump and its working characteristics in the wellbore. The model can describe the operation mechanism of the electric submersible pump in detail and make a preliminary production prediction based on this. The predicted production is calculated with the actual production to obtain the error and feed it back to the LLM model. The LLM model reprograms the input time series data using text prototypes, represents the semantic information of the time series data by using natural language representation, and enhances the input context information by using domain expert knowledge and task instructions for time series prediction. Through the iterative learning process, the LLM model parameters are gradually adjusted to achieve error correction and compensation. If there are key parameters missing in the input data, such as flow pressure, etc., they can be predicted through the LLM model. Finally, the prediction results and compensated data are fed back to the mechanism model for parameter optimization to make the model closer to the actual situation, thereby obtaining the predicted value of the production of the electric pump well.
[0028] The above is a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as within the scope of protection of the present invention.
Claims
1. A method for predicting the production of submersible electric pump wells by integrating the mechanism of electric submersible pumps and a large language model, characterized in that: The specific steps are as follows: S1. Collect historical production data of the oil field as a sample data set, and divide the sample data set into a training set, a validation set, and a test set after preprocessing; S2. According to the attributes of all wells in the electric pump well attribute database, the correlation between the flow rate, flow velocity, pressure drop, head and power of the same well is analyzed to obtain the storage and transportation mechanism knowledge applicable to the actual electric pump well, and the storage and transportation mechanism knowledge is characterized; S3, based on the characterization results of step S2, further refine the characterization results according to the mass conservation equation and the momentum equation, and comprehensively obtain the electric pump well mechanism model; S4. Combined with the gathering and transportation pipeline network of the electric pump well, the attribute parameters of the single well in the gathering and transportation pipeline network are input into the pre-trained large language model to construct a large language model integrating mechanism knowledge; S5, setting the model parameters of the large language model integrating the mechanism knowledge obtained in step S4, and using the training set to train the network model with the set parameters. During the training process, the pressure, temperature and output of each part of the electric pump well pipe network are continuously calculated through the mechanism knowledge, and the change trend at each iteration is analyzed until the model training is completed; S6, based on the result obtained in step S5, using the coefficient of determination, mean square error and mean absolute error as evaluation indicators to evaluate the large language model integrating the mechanism knowledge; S7. Combined with the evaluation result in step S6, the data of the test set is input into the large language model integrating the mechanism knowledge for prediction, and the prediction result of the production of each electric pump well in the electric pump well network is obtained.
2. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 1 is characterized in that: The historical production data described in step S1 include well number, collection time, pump depth, current, voltage, power consumption, electric pump power, overall efficiency, wellhead diameter, density, oil pressure, flow pressure, bottom hole flow rate, wellhead temperature, water content, and daily liquid production, wherein the daily liquid production is the total liquid production of a single well on that day, which is obtained by reading the flow meter installed at the wellhead of the oil well in the crude oil production area; current, voltage, power consumption, electric pump power, overall efficiency, density, oil pressure, flow pressure, bottom hole flow rate, wellhead temperature, and water content are obtained using sensors installed at the crude oil production site, and the ratio of the number of training sets, validation sets, and test sets is 7:1.5:1.
5.
3. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 2 is characterized in that: Step S1 describes the preprocessing of the sample data set, which includes data cleaning and processing, identifying and filling missing data, and removing and correcting abnormal data. First, the Z-score method is used to detect outliers in the data. The Z-score is: ,in, and are the mean and standard deviation of the data respectively. When Considered as outliers, ; For the detected outliers, the K nearest neighbor algorithm is used for interpolation repair to find the K normal data points that are close to the outlier in the time series. , outliers are replaced by calculating the weighted average of these neighboring data points: ; Then use the moving average method to smooth the abnormal data, set the window size to 5, calculate the average value of the data points in the window around the abnormal point, replace the abnormal data point with the calculated value, and use the mean square error method to quantify the data difference.
4. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 3 is characterized in that: The electric pump well attributes in step S2 include wellbore pressure, fluid density, flow velocity, and flow rate; the storage and transportation mechanism knowledge includes continuity equation, head formula, power formula, and formation seepage pressure drop equation. The result of characterizing the storage and transportation mechanism knowledge is: According to the momentum equation, the pressure drop process of the fluid can be described by the movement of the wellbore fluid: ,in, Indicates the pressure in the wellbore. is the well depth direction, is the fluid density, is the acceleration due to gravity, is the friction factor, is the flow rate, is the wellbore diameter; Continuity equation Describe the relationship between flow rate and flow velocity, where It's traffic. is the cross-sectional area of the wellbore; The working performance of the electric submersible pump is described by the head formula and the power formula, where the head formula is: ,in, It is the lift. is the maximum lift, is the pump characteristic coefficient, and the power formula is: ,in, is power, is the efficiency of the pump; In the formation, the flow of fluid is described by the formation seepage pressure drop equation: ,in, is the flow rate, is the formation permeability, is the fluid viscosity, is the pressure gradient.
5. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 4 is characterized in that: Step S3 further refines the process of characterizing the results as follows: The pressure diffusion equation is used to describe the change of pressure over time: ,in is the reservoir porosity, It's pressure. It's time. is the gradient operator; When dealing with three-phase flow containing oil, gas and water, the mass conservation equation is used to describe the mass conservation of each phase: ,in is the phase saturation, is the phase density, is the phase velocity, is the source-sink term; The momentum equation describes the flow velocity of each phase: ,in, is the phase permeability, is the phase viscosity, is the permeability tensor, is the pressure gradient, is the phase density, is the acceleration due to gravity, is the change in depth direction; The obtained electric pump well mechanism model is: , in, is the mass density of the fluid, is the mass flow rate of the fluid, is the source-sink term, is the pressure drop in the wellbore, is the additional pressure drop caused by friction, is the head of the electric submersible pump, It is the relationship between flow rate and flow velocity.
6. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 5 is characterized in that: The construction process of the large language model integrating mechanism knowledge in step S4 is as follows: S41, input patching, multivariate time series Divide into Univariate time series , first normalize each input channel using reversible instance normalization, and then divide each sequence into multiple overlapping patches with a patch length of , the horizontal sliding step is , calculate the total number of patches as , each patch is embedded into a low-dimensional space and converted to ,in is the embedding dimension; S42, patch reprogramming, introduce hint prefixes, convert the time series data of the electric pump well into a representation space compatible with the large language model to align the time series parameter modality of the electric pump well with the modality of the natural language. When aligning, a set of text prototypes is learned by introducing a multi-head cross-attention layer. The text prototype From pre-trained word embeddings via linear projection To form a language description corresponding to the state of the electric pump well, the working process of the multi-head cross attention layer is: , , , , , By aggregating the output of each head , and get the overall patch representation , then Linear projection to the dimension aligned with the hidden layer of the base model forms the output representation of the reprogrammed patch ; S43, patch to be reprogrammed Used to generate the final yield forecast, discard the prompt prefix, keep only the forecast result, and obtain the final forecast result after linear projection .
7. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 6 is characterized in that: The model parameters in step S5 include the number of text prototypes, the number of backbone model layers, the input length, the patch dimension, the optimizer, the activation function and the number of iterations, wherein the number of text prototypes is 1000, the number of backbone model layers is 32, the input length is 512, indicating the number of production data input to the model; the patch dimension is 16, representing the hidden dimension of the embedded patch before the large language model is reprogrammed; the optimizer adopts the Adam optimizer, the activation function is the RELU activation function, and the number of iterations is 100.
8. The method for predicting the production of submersible electric pump wells by integrating the electric submersible pump mechanism and the large language model according to claim 7 is characterized in that: The calculation formulas for the determination coefficient, mean square error, and mean absolute error in step S6 are as follows: Coefficient of determination , Mean square error , Mean absolute error , in is the number of observations, It is The true value of an observation, It is The predicted value of an observation, yes The average value of the real data.
Citation Information
Patent Citations
Oil well yield prediction method and system based on hybrid neural network
CN118365183A
Oil well yield prediction method based on deep learning algorithm
CN110400006A
Pipe network well stopping and opening yield prediction method based on computable semantic network
CN116451877A
Long-term time sequence prediction method and system based on time sequence block repair
CN118862014A
Communication network performance prediction method and system based on large model
CN119172259A
Cited By
Oil well yield prediction method based on artificial intelligence
CN119904013A
CFD-based electric submersible pump oil-gas-water three-phase flow adaptability analysis method and system
CN120373212A
CFD-based oil-gas-water three-phase flow adaptability analysis method and system for submersible electric pump
CN120373212B
Oil and gas well yield prediction method and device based on pre-training large language model
CN120471196A
Oil field intelligent decision-making and self-adaptive scheduling system and method based on multi-modal neural network
CN120525303A