Method, device and equipment for determining working conditions of drilling operation and storage medium

By using the pre-trained working condition probability prediction model, the working conditions in drilling operations are automatically identified, which solves the problem of low judgment accuracy in the existing technology and improves the accuracy of the judgment of working conditions.

CN120031176APending Publication Date: 2025-05-23CHINA UNIV OF PETROLEUM (BEIJING)

Patent Information

Application Number
CN202411969299.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

The accuracy of the operational condition judgment in the prior art in drilling operations is low, and errors are prone to occur depending on manual judgment.

Method used

The pre-trained working condition probability prediction model is used to determine the working condition probability of each preset drilling operation based on the current well recording data, and automatically identify the current working condition.

Benefits of technology

Reliance on operators is reduced, the accuracy of drilling operation conditions is improved, and the automatic identification of operation conditions during drilling is realized.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120031176A_ABST
    Figure CN120031176A_ABST
Patent Text Reader

Abstract

The invention discloses a method, device and equipment for determining drilling operation conditions and a storage medium, and belongs to the technical field of drilling engineering and deep learning. The method comprises the steps that in the process of drilling operation on a target well, current logging data of the target well at the current moment are obtained; based on a pre-trained working condition probability prediction model, the working condition probability of each first preset drilling operation working condition corresponding to the target well is determined according to the current logging data, and the first preset drilling operation working conditions comprise an overflow working condition, a leakage working condition and a normal working condition; and according to the multiple working condition probabilities, the current drilling operation working condition of the target well at the current moment is determined. According to the invention, the judgment accuracy of the drilling operation condition can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of drilling engineering and deep learning technology, and specifically to a method, device, equipment and storage medium for determining operating conditions. Background Art

[0002] As oil and gas production moves toward deep and ultra-deep layers, the complex wellbore temperature and pressure system and narrow safety density window may cause abnormal operating conditions in the operating wells, such as overflow and / or leakage. In the prior art, operators usually compare the parameters of the wells with the preset thresholds based on the on-site construction conditions and the fluctuation range of the well parameters to determine the abnormal operating conditions of the operating wells during the drilling process. However, this method is too dependent on the operators, and misjudgments may occur during the drilling operation. Therefore, the prior art has the problem of low accuracy in judging the operating conditions. Summary of the invention

[0003] The purpose of the embodiments of the present application is to provide a method, device, equipment and storage medium for determining drilling operation conditions, so as to solve the problem of low accuracy in determining the operation conditions in the prior art.

[0004] In order to achieve the above-mentioned object, the first aspect of the present application provides a method for determining a drilling operation condition, the method comprising:

[0005] During the drilling operation of the target well, current logging data of the target well at the current moment is obtained;

[0006] Based on the pre-trained operating condition probability prediction model, according to the current logging data, the operating condition probability of each first preset drilling operating condition corresponding to the target well is determined, wherein the first preset drilling operating condition includes an overflow condition, a leakage condition, and a normal condition;

[0007] According to multiple operating condition probabilities, the current drilling operating condition of the target well at the current moment is determined.

[0008] In an embodiment of the present application, the current drilling operation condition of the target well at the current moment is determined based on multiple operating condition probabilities, including: determining the largest operating condition probability among the multiple operating condition probabilities to obtain the target operating condition probability; and determining the first preset drilling operation condition corresponding to the target operating condition probability as the current operating condition of the target well at the current moment.

[0009] In an embodiment of the present application, normal operating conditions include multiple sub-normal operating conditions; the training process of the operating condition probability prediction model includes: obtaining historical logging data of multiple second preset drilling operation conditions, the second preset drilling operation conditions including overflow conditions, leakage conditions and multiple sub-normal operating conditions; multiple selections of historical logging data of a preset number of operating conditions from the historical logging data of multiple second preset drilling operation conditions to obtain multiple historical logging task sets; based on the multiple historical logging task sets, training the first initial operating condition probability prediction model to obtain the second initial operating condition probability prediction model; based on the historical logging data of multiple second preset drilling operation conditions, training the second initial operating condition probability prediction model to obtain the operating condition probability prediction model.

[0010] In an embodiment of the present application, a first initial operating condition probability prediction model is trained according to multiple historical logging task sets to obtain a second initial operating condition probability prediction model, including: training the first initial operating condition probability prediction model according to multiple historical logging task sets until the number of training times reaches a preset number of training times to obtain a second initial operating condition probability prediction model.

[0011] In an embodiment of the present application, a second initial operating condition probability prediction model is trained based on historical logging data of multiple second preset drilling operation conditions to obtain an operating condition probability prediction model, including: merging historical logging data of multiple sub-normal operating conditions in the historical logging data of multiple second preset drilling operation conditions into historical logging data of normal operating conditions to obtain historical logging data of multiple first preset drilling operation conditions; and updating model parameter values ​​of the second initial operating condition probability prediction model based on the historical logging data of multiple first preset drilling operation conditions to obtain an operating condition probability prediction model.

[0012] In an embodiment of the present application, the training process of the operating condition probability prediction model also includes data preprocessing, and the data preprocessing includes at least one of the following: based on a preset linear interpolation algorithm, missing data filling processing is performed on the historical logging data of multiple preset drilling operation conditions; based on a preset interquartile range method, abnormal data replacement processing is performed on the historical logging data of multiple preset drilling operation conditions.

[0013] In an embodiment of the present application, the operating condition probability prediction model is a model trained based on a meta-learning algorithm.

[0014] A second aspect of the present application provides a device for determining an operating condition, comprising: a memory configured to store instructions; and a processor configured to call the instructions from the memory and implement the above-mentioned method for determining an operating condition when executing the instructions.

[0015] A third aspect of the present application provides a device for determining an operating condition, comprising: a device for determining an operating condition according to the above-mentioned device.

[0016] A fourth aspect of the present application provides a machine-readable storage medium having instructions stored thereon, the instructions being used to enable a machine to execute the above-mentioned method for determining an operating condition.

[0017] Through the above technical scheme, during the process of drilling operations on the target well, the current logging data of the target well at the current moment is obtained; then, based on the pre-trained operating condition probability prediction model, the operating condition probability of each first preset drilling operating condition corresponding to the target well can be determined according to the current logging data, wherein the first preset drilling operating condition includes overflow condition, leakage condition and normal condition; thereby, according to multiple operating condition probabilities, the current drilling operating condition of the target well at the current moment is determined. In this way, compared with the existing technology, the dependence on operating personnel is reduced, the automatic identification of drilling operating conditions during drilling is realized, and the accuracy of drilling operating condition judgment is improved.

[0018] Other features and advantages of the embodiments of the present application will be described in detail in the subsequent specific implementation section. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] The accompanying drawings are used to provide a further understanding of the embodiments of the present application and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present application, but do not constitute a limitation on the embodiments of the present application. In the accompanying drawings:

[0020] Figure 1 A schematic diagram of a process for determining an operating condition according to an embodiment of the present application is shown;

[0021] Figure 2 A schematic diagram of the division of a meta-training set constructed based on historical logging data of a preset drilling operation condition is schematically shown;

[0022] Figure 3 The schematic diagram of the structure of the initial operating condition probability prediction model according to the embodiment of the present application is shown;

[0023] Figure 4 The figure schematically shows a comparison of the model output accuracy of the first model in the present application and the second model in the prior art. DETAILED DESCRIPTION

[0024] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the technical scheme in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. It should be understood that the specific implementation methods described herein are only used to illustrate and explain the embodiments of the present application, and are not used to limit the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0025] It should be noted that the acquisition, transmission, storage, use, and processing of data in the technical solution of this application are in compliance with the relevant provisions of national laws and regulations. In the embodiments of this application, some existing solutions in the industry such as certain software, components, and models may be mentioned, which should be considered as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of this application, but it does not mean that the applicant has or will necessarily use the solution.

[0026] It should be noted that if the embodiments of the present application involve directional indications (such as up, down, left, right, front, back...), the directional indications are only used to explain the relative position relationship, movement status, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly.

[0027] In addition, if there are descriptions involving "first", "second", etc. in the embodiments of the present application, the descriptions of "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or suggesting their relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the ability of ordinary technicians in the field to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by this application.

[0028] Figure 1 The following schematically shows a flow chart of a method for determining drilling operation conditions according to an embodiment of the present application. Figure 1 As shown, the embodiment of the present application provides a method for determining a drilling operation condition, which is described by taking the method applied to a processor as an example. The method may include the following steps:

[0029] Step S101, during the drilling operation of the target well, current logging data of the target well at the current moment is obtained.

[0030] Step S102, based on the pre-trained operating condition probability prediction model and according to the current logging data, determine the operating condition probability of each first preset drilling operating condition corresponding to the target well, wherein the first preset drilling operating condition includes overflow condition, leakage condition and normal condition.

[0031] Step S103, determining the current drilling operation condition of the target well at the current moment according to the multiple operating condition probabilities.

[0032] It can be understood that the target well is a well that is being drilled at the current moment. The drilling operation is the situation encountered during the drilling of the target well. The current logging data is the logging data obtained at the current moment. The logging data may include but is not limited to data such as well depth, drill bit position, drilling pressure, torque, rotary table speed, hook load, riser pressure, inlet and outlet flow, inlet and outlet density, inlet and outlet temperature, inlet and outlet conductivity, total volume of the mud pool and total hydrocarbon content. The pre-trained operating condition probability prediction model is a pre-trained operating condition probability prediction model, and the operating condition probability prediction model is used to predict the operating condition probability of each first preset drilling operation condition. The first preset drilling operation condition is a pre-set drilling operation condition. The first preset drilling operation condition may include overflow conditions, leakage conditions and normal conditions. The operating condition probability is the probability of occurrence of each preset drilling operation condition. The current drilling operation condition is the operating condition of the target well at the current moment.

[0033] Specifically, during the drilling operation of the target well, the processor can obtain the current logging data of the target well at the current moment in real time, and can specifically determine the current logging data at the current moment through a sensor or other data acquisition device set at the position of the target well. Then, the current logging data obtained by the processor is input into the pre-trained working condition probability prediction model, and the working condition probability of each first preset drilling working condition corresponding to the target well is output, such as the overflow working condition probability of the overflow working condition, the leakage working condition probability of the leakage working condition, and the normal working condition probability of the normal working condition, so as to determine the current drilling working condition of the target well at the current moment based on the working condition probability (including the overflow working condition probability of the overflow working condition, the leakage working condition probability of the leakage working condition, and the normal working condition probability of the normal working condition).

[0034] Through the above technical scheme, during the process of drilling operations on the target well, the current logging data of the target well at the current moment is obtained; then, based on the pre-trained operating condition probability prediction model, the operating condition probability of each first preset drilling operating condition corresponding to the target well can be determined according to the current logging data, wherein the first preset drilling operating condition includes overflow condition, leakage condition and normal condition; thereby, according to multiple operating condition probabilities, the current drilling operating condition of the target well at the current moment is determined. In this way, compared with the existing technology, the dependence on technical personnel is reduced, the automatic identification of drilling operating conditions during drilling is realized, and the accuracy of drilling operating condition judgment is improved.

[0035] In one embodiment, the current drilling operating condition of the target well at the current moment is determined based on multiple operating condition probabilities, including: determining the maximum operating condition probability among the multiple operating condition probabilities to obtain the target operating condition probability; and determining the first preset drilling operating condition corresponding to the target operating condition probability as the current operating condition of the target well at the current moment.

[0036] It can be understood that the target operating condition probability is the maximum operating condition probability among the operating condition probabilities of the first preset drilling operation conditions.

[0037] Specifically, the processor can determine the maximum operating condition probability among multiple operating condition probabilities, that is, determine the maximum operating condition probability among the three operating condition probabilities of the overflow operating condition, the loss operating condition probability of the loss operating condition, and the normal operating condition probability of the normal operating condition, and use the maximum operating condition probability as the target operating condition probability, so as to use the first preset drilling operating condition corresponding to the target operating condition probability as the current operating condition of the target well at the current moment. For example, if the overflow operating condition probability of the overflow operating condition is 0.23, the loss operating condition probability of the loss operating condition is 0.61, and the normal operating condition probability of the normal operating condition is 0.16, then the target operating condition probability is determined to be 0.61, and the loss operating condition corresponding to the target operating condition probability (the loss operating condition probability is 0.61) is determined to be the current operating condition of the target well at the current moment.

[0038] The processor can also obtain a preset weight coefficient corresponding to the first preset drilling operation condition, calculate multiple probability product values ​​of the preset weight coefficient corresponding to the preset drilling operation condition and the condition probability corresponding to the first preset drilling operation condition, thereby determining the largest probability product value among the multiple product values, and using it as the target condition probability, so as to determine the first preset drilling operation condition corresponding to the target condition probability as the current operating condition of the target well at the current moment.

[0039] In this way, the most likely operating condition during the drilling process can be predicted based on the operating condition probability, and used as the current operating condition of the target well at the current moment, which will help operators make corresponding processing strategies based on the current operating condition of the target well, thereby ensuring the safety of each operator during the drilling operation.

[0040] In one embodiment, the normal operating condition includes multiple sub-normal operating conditions; the training process of the operating condition probability prediction model includes: obtaining historical logging data of multiple second preset drilling operation conditions, the second preset drilling operation conditions including overflow conditions, leakage conditions and multiple sub-normal operating conditions; multiple selections of historical logging data of a preset number of conditions from the historical logging data of multiple second preset drilling operation conditions to obtain multiple historical logging task sets; based on the multiple historical logging task sets, training the first initial operating condition probability prediction model to obtain the second initial operating condition probability prediction model; based on the historical logging data of multiple second preset drilling operation conditions, training the second initial operating condition probability prediction model to obtain the operating condition probability prediction model.

[0041] It can be understood that the second preset drilling operation condition can include overflow condition, leakage condition and multiple sub-normal conditions, the normal condition can include multiple sub-normal conditions, and the sub-normal conditions can be stationary, in-situ circulation, in-situ rotation, in-situ circulation-rotation, drilling, drilling-pumping, reverse marking, dry reverse marking, drilling, drilling-pumping, marking, dry marking, sliding drilling and composite drilling. The historical logging data is the historically stored logging data. The preset number of working conditions is the number of working conditions set in advance, and the preset number of working conditions can be set to 3. The historical logging task set is the historical logging data of the preset number of working conditions selected multiple times from the historical logging data of multiple second preset drilling operation conditions, and the first initial working condition probability prediction model is a working condition probability prediction model that has not been trained. The second working condition probability prediction model is a model trained based on the first initial working condition probability prediction model, and the working condition probability prediction model is a trained model.

[0042] Specifically, the processor can obtain historical logging data of multiple second preset drilling operation conditions from a pre-built logging database or other data acquisition channels, and annotate the historical logging data in combination with drilling logs and expert experience to obtain historical logging data with second preset drilling operation condition labels, thereby selecting historical logging data of a preset number of conditions from the historical logging data of multiple second preset drilling operation conditions multiple times to obtain multiple historical logging task sets, and based on the multiple historical logging task sets, update the initialization model parameter values ​​of the first initial condition probability prediction model to obtain the optimal model parameter values, thereby obtaining a second condition probability prediction model, and then, based on the historical logging data, re-update the model parameter values ​​of the second condition probability prediction model to obtain the condition probability prediction model, and thus, train the condition probability prediction model multiple times to improve the accuracy of the condition probability prediction of the condition probability prediction model.

[0043] In one embodiment, a first initial operating condition probability prediction model is trained according to multiple historical logging task sets to obtain a second initial operating condition probability prediction model, including: according to multiple historical logging task sets, the first initial operating condition probability prediction model is trained until the number of training times reaches a preset number of training times to obtain the second initial operating condition probability prediction model.

[0044] It can be understood that the preset number of training times is a pre-set number of training times.

[0045] Specifically, based on multiple historical logging task sets, the first initial operating condition probability prediction model is trained, thereby training the first initial operating condition probability prediction model multiple times, and updating the model parameter values ​​of the first initial operating condition probability prediction model multiple times until the number of training times reaches a preset number of training times or until the model converges. At this time, the training process of the first initial operating condition probability prediction model is the update process of updating the initialization model parameter values ​​to the optimal model parameter values. After the initial model parameter values ​​of the first initial operating condition probability prediction model are updated to the optimal model parameter values, the initial model parameter values ​​of the second initial operating condition probability prediction model can be obtained. In one embodiment, a second initial operating condition probability prediction model is trained based on historical logging data of multiple second preset drilling operation conditions to obtain an operating condition probability prediction model, including: merging historical logging data of multiple sub-normal operating conditions in the historical logging data of multiple second preset drilling operation conditions into historical logging data of normal operating conditions to obtain historical logging data of multiple first preset drilling operation conditions; and updating model parameter values ​​of the second initial operating condition probability prediction model based on the historical logging data of multiple first preset drilling operation conditions to obtain an operating condition probability prediction model.

[0046] It can be understood that the initial values ​​of the model parameter values ​​of the second initial operating condition probability prediction model are the optimal model parameter values ​​of the first initial operating condition probability prediction model.

[0047] The processor can process the historical logging data set, and uniformly modify the historical logging data set with the sub-normal working condition label to the historical logging data set with the normal working condition label; the processor can also obtain the logging data corresponding to the adjacent wells adjacent to the target well at the current moment, clean the logging data (i.e., fill in missing data and / or replace abnormal data) and mark the logging data (mark the logging data as logging data with overflow, leakage or normal three working condition labels), and then, undersample the historical logging data set or the logging data set after cleaning and marking, so as to construct a logging data set of the first preset drilling operation working condition (which may include overflow, leakage or normal three working conditions). Using this logging data set, the model parameter value of the second initial working condition probability prediction model can be updated to obtain the optimal model parameter value, so that the working condition probability prediction model corresponding to the optimal parameter can be obtained.

[0048] In one embodiment, the training process of the operating condition probability prediction model also includes data preprocessing, and the data preprocessing includes at least one of the following: based on a preset linear interpolation algorithm, missing data filling processing is performed on the historical logging data of multiple preset drilling operation conditions; based on a preset interquartile range method, abnormal data replacement processing is performed on the historical logging data of multiple preset drilling operation conditions.

[0049] It can be understood that the preset linear difference algorithm is a preset linear difference algorithm, which is used to fill in missing data in historical logging data. The preset interquartile range method is a preset interquartile range method, which is used to identify and replace abnormal data.

[0050] Specifically, after obtaining historical logging data of multiple second preset drilling operation conditions, and before selecting historical logging data of a preset number of conditions from the historical logging data of multiple second preset drilling operation conditions multiple times to obtain multiple historical logging task sets, data preprocessing can be performed on the historical logging data of multiple second preset drilling operation conditions, and missing data filling processing can be performed on the historical logging data of multiple second preset drilling operation conditions based on a preset linear interpolation algorithm, or abnormal data replacement processing can be performed on the historical logging data of multiple second preset drilling operation conditions based on a preset interquartile range method; the processor can also first perform missing data filling processing on the historical logging data of multiple second preset drilling operation conditions based on a preset linear interpolation algorithm, and then perform abnormal data replacement processing on the historical logging data of multiple second preset drilling operation conditions based on a preset interquartile range method, or first perform abnormal data replacement processing on the historical logging data of multiple second preset drilling operation conditions based on a preset interquartile range method, and then perform missing data filling processing on the historical logging data of multiple preset drilling operation conditions based on a preset linear interpolation algorithm.

[0051] Before inputting the historical logging data of multiple second preset drilling operation conditions into the first initial condition probability prediction model, data preprocessing is performed on the historical logging data of multiple second preset drilling operation conditions to ensure the integrity and consistency of the data, thereby improving the training effect of the first initial condition probability prediction model.

[0052] In one embodiment, the operating condition probability prediction model is a model trained based on a meta-learning algorithm.

[0053] It can be understood that the meta-learning algorithm is a learning algorithm based on tasks (such as a historical logging task set).

[0054] Specifically, historical logging data of a preset number of working conditions are selected multiple times from a small number of historical logging data of multiple second preset drilling operation conditions, thereby obtaining multiple historical logging task sets, and the multiple historical logging task sets are input into the first initial working condition probability prediction model, and the first initial working condition probability prediction model is trained, and the initialization model parameter value of the first initial working condition probability prediction model can be updated to the optimal model parameter value, and the optimal model parameter value is used as the initialization model parameter value of the second initial working condition probability prediction model to obtain the second initial working condition probability prediction model, and then the second initial working condition probability prediction model is trained, and the initialization model parameter value of the second initial working condition probability prediction model can be updated to the optimal model parameter value to obtain the working condition probability prediction model. In the case where the historical logging data (sample size) of multiple second preset drilling operation conditions is small, a meta-learning algorithm is used to classify the historical logging data of multiple second preset drilling operation conditions, and a large number of historical logging task sets can be obtained, thereby updating the initial model parameter value of the first initial working condition probability prediction model, and a better training effect can be obtained.

[0055] As oil and gas drilling moves towards deep and ultra-deep layers, the wellbore temperature and pressure system is complex, the safety density window is narrow, and overflow and leakage occur frequently. If they are not detected in time, it is very easy to cause huge losses of manpower and financial resources. Therefore, how to timely determine the drilling operation conditions (such as overflow or leakage) during the drilling operation is of great guiding significance to ensure drilling safety.

[0056] At present, the technical experience method and artificial intelligence method can be used. The technical experience method can be based on engineering phenomena and mechanism models. By real-time monitoring of the fluctuation amplitude of parameters such as the mud pool liquid level, inlet and outlet flow difference, total hydrocarbon content, and the difference between the theoretical calculated value and the measured value of the wellbore hydraulic model, the size relationship between these characteristic parameters and the preset threshold value can be compared to judge the occurrence of overflow / loss. This method relies heavily on the field experience of technicians and the accuracy of the mechanism model, and it is difficult to guarantee timeliness and reliability. The artificial intelligence method does not require harsh condition assumptions. Based on a large amount of drilling data, it can automatically extract the complex nonlinear mapping relationship between logging parameters and overflow / loss, and has a high degree of intelligence. Commonly used machine learning algorithms include support vector machines (SVM), artificial neural networks (ANN), convolutional neural networks (CNN), and recurrent neural networks (RNN). The above algorithms take a single task as the goal, and find the optimal network weights in a given large number of data sets by optimizing the loss function. However, considering the large differences in drilling engineering parameters between different wells and blocks, the number of overflow and leakage samples is scarce, which makes it difficult to meet the requirements of machine learning algorithms for the quality of training data samples, making the existing overflow / leakage intelligent detection methods weak in generalization and transferability. In this regard, under the condition of the scarcity of overflow / leakage samples, it is very necessary to use the powerful nonlinear fitting ability of machine learning algorithms to establish a method for determining drilling operation conditions.

[0057] A specific embodiment of the present invention provides a method for determining a drilling operation condition, obtaining historical logging data measured during the drilling process of different wells and blocks, wherein the historical logging data may include missing values ​​and / or abnormal values, and data preprocessing may be performed on the historical logging data. If it is determined that there are missing values ​​in the historical logging data, a preset linear interpolation method may be used to perform missing value filling processing. The preset linear interpolation method mainly uses a linear equation to calculate the missing values. The specific process is: assuming that the position of the missing value is x, and the two known data points before and after are (x 1 ,y 1 ) and (x 2 ,y 2 ), the missing values ​​can be determined by the following formula:

[0058]

[0059] Among them, y is a missing value, y 1 For x 1 The measured value of the position, y 2 For x 2 The measured value of position, x 1 is the position before the missing value position x, x 2 One position after the missing value position x.

[0060] If it is determined that there are outliers in the historical logging data, the preset interquartile range method can be used to replace the outliers. The preset interquartile range method can use the quartiles of the data to identify and remove outliers. The specific process is: arrange the historical logging data in ascending order (from small to large), and count the first quartile (Q 1 ) and the third quartile (Q 3 ), the interquartile range (IQR) can be determined by the following formula:

[0061]

[0062] Among them, IQR is the interquartile range, Q 3 is the third quartile, Q 1 The first quartile, LOW is the lower limit of normal value, and UP is the upper limit of normal value.

[0063] If a certain data in the historical logging data exceeds the upper and lower limits of the normal value, the data will be regarded as an abnormal value and replaced based on the linear interpolation method.

[0064] The normal drilling conditions (normal conditions) are subdivided into 14 categories, including static, in-situ circulation, in-situ rotation, in-situ circulation-rotation, drilling, drilling-pumping, reverse reaming, dry reverse reaming, drilling, drilling-pumping, reaming, dry reaming, sliding drilling and composite drilling. The abnormal drilling conditions include overflow and leakage. Combined with the drilling log and the operation experience of the operators, each condition is labeled. A single sample is a two-dimensional array with a shape of (L,n), where L is the sequence length, n=17, representing the number of parameters in the historical logging data. The parameters in the historical logging data may include well depth, drill bit position, drilling pressure, torque, rotary table speed, hook load, riser pressure, inlet and outlet flow, inlet and outlet density, inlet and outlet temperature, inlet and outlet conductivity, total volume of mud pool and total hydrocarbon content. In this way, the historical logging data containing the preset drilling operation condition labels is established.

[0065] Then, based on the established historical logging data containing the second preset drilling operation condition label, a meta-learning algorithm (N-Way, K-Shot) is used to divide the historical logging data containing the second preset drilling operation condition label, and N operating conditions are selected multiple times from the multiple second preset drilling operation condition labels to obtain a set of multiple operating condition classification tasks (historical logging task set). Since the operating condition probability prediction model is a probability prediction of overflow, leakage, and normal conditions for drilling operations, the number of preset conditions N=3, that is, the model performs three classifications, and the output results are overflow, leakage, or normal. The sample size of each condition is split into a first data set and a second data set in a ratio of 8:2, where the first data set is used to construct the operating condition classification task in the meta-training set, and the second data set is used to construct the operating condition classification task in the meta-test set. The specific steps for constructing the meta-training set are as follows: Figure 2 As shown, 3 working conditions are randomly selected from the 16 working conditions in the first data set as a working condition classification task. For each working condition classification task, K samples (small number) are randomly selected from each working condition to form a support set, and a certain number of samples are randomly selected from each working condition to form a query set. Similarly, the specific steps for constructing the meta-test set are: randomly select 3 working conditions from the 16 working conditions in the second data set as a working condition task. For each working condition task, K samples (small number) are randomly selected from each working condition to form a support set, and a certain number of samples are randomly selected from each working condition to form a query set.

[0066] The model structure of the operating condition probability prediction model includes Conv1D layer, Relu layer, Average Pooling1D layer, Self Attention layer and FC layer. Among them, the Average Pooling1D layer calculates the average value within a fixed window to reduce the data dimension and prevent overfitting; the Self Attention layer is used to enhance the model's ability to capture global information; the FC layer is used to map the captured high-dimensional features to the target dimension. First, the one-dimensional convolutional (Conv1D) neural network can be used to extract the temporal features of a single parameter and the coupling features between multiple parameters in each sample. Secondly, the self-attention mechanism is used to further strengthen the mapping relationship between the features extracted by the one-dimensional convolutional neural network and the operating condition type. Finally, the fully connected layer and the flexible maximum activation function (Softmax) are used to obtain the classification results. Figure 3As shown in the figure, the initial operating condition probability prediction model includes Conv1D layer, Relu layer, Average Pooling1D layer, Self Attention layer and FC layer. Among them, the Average Pooling1D layer calculates the average value in a fixed window to reduce the data dimension and prevent overfitting; the Self Attention layer is used to enhance the model's ability to capture global information; the FC layer is used to map the captured high-dimensional features to the target dimension.

[0067] When using a one-dimensional convolutional neural network to extract the temporal features of a single parameter and the coupling features between multiple parameters in each sample, the input sample (sample data in historical logging data or current logging data) passes through Conv1D 1 layer, Relu 1 layer, Conv1D 2 layer, Relu 2 layer and Average Pooling1D layer in sequence, and the output result is a two-dimensional matrix. For the Conv1D layer and Conv1D 2 layer, the number of convolution kernels is 64, the size of the convolution kernel is 3, and the convolution stride is 2. For the Average Pooling1D layer, the pooling window size is 2 and the pooling stride is 2.

[0068] Relu(x)=max(0,x)

[0069] Among them, Relu(x) is the activation function, and x is the data of the input sample.

[0070] When using the self-attention mechanism to further strengthen the mapping relationship between the features extracted by the one-dimensional convolutional neural network and the working condition type, the specific process is as follows:

[0071] The output matrix of the Average Pooling1D layer is respectively related to the three trainable weight matrices W q , W k and W v Multiplying together the query vector matrix Q, the key vector matrix K and the value vector matrix V, the formula for determining the output matrix can be shown as follows:

[0072]

[0073] Among them, W q is the first trainable weight matrix, W k is the second trainable weight matrix, W v is the third trainable weight matrix, Q is the query vector matrix, K is the key vector matrix, V is the value vector matrix, and X is the input matrix.

[0074] Based on matrices Q, K, and V, the output of the Self Attention layer can be obtained as shown in the following formula:

[0075]

[0076] Among them, Att(Q,K,V) is the output result of the Self Attention layer, T is the matrix transpose symbol, and d represents the dimension of the vector.

[0077] Then, the output matrix of the Self Attention layer is flattened into a high-dimensional vector as the input of the FC layer, outputting a vector of dimension 3, and using the Softmax function to output the probabilities of three working conditions (overflow condition, leakage condition, and normal condition).

[0078] Furthermore, considering that the dimensions of data in different historical logging task sets are quite different, each sample is processed by the normalization method before being input into the neural network, and each data value is uniformly scaled to 0-1 to unify the dimensions of each data. For example, as shown in the following formula, the Min-Max normalization method is mainly used to scale the maximum and minimum values ​​of the same type of data:

[0079]

[0080] Among them, x' i is the data after normalization of the ith parameter in the logging data, x i is the data of the i-th parameter in the logging data that has not been normalized, max(x i ) is the maximum value of the i-th parameter in the logging data without normalization, min(x i ) is the minimum value of the i-th parameter in the logging data without normalization, and ε is a constant (a very small number) to prevent the denominator from being zero.

[0081] After building the structure of the first initial operating condition probability prediction model, it is also necessary to update the initial model parameter values ​​of the first initial operating condition probability prediction model to improve the accuracy of the model output. Based on the scarcity of overflow and leakage data samples, a small sample learning algorithm is used to optimize the parameter values ​​of the first initial operating condition probability prediction model. Among them, the small sample learning algorithm (Model-Agnostic Meta-Learning, MAML) is a typical representative of the meta-learning algorithm. By optimizing the initialization parameters of the neural network, the model can quickly adapt to new classification tasks through a small number of samples, which is very suitable for the scenario where the overflow / leakage sample volume is scarce during drilling.

[0082] If the initialization model parameter value of the first initial operating condition probability prediction model is θ 0 , for each work condition classification task in the meta-training set i Perform the following steps: iThe initialization model parameter value of the corresponding task model is set to θ 0 ; Use the support set of this task for forward propagation and determine the cross entropy loss function l(θ i ), as shown in the following formula:

[0083]

[0084] Among them, l(θ i ) is Task i The corresponding cross entropy loss function, θ i For Task i The model parameter value of the corresponding task model, p j For Task i The probability of the j-th operating condition predicted by the corresponding task model. If the true label is the j-th category, then y j =1, otherwise, y j =0.

[0085] The optimal parameters can be determined using the following formula:

[0086]

[0087] Among them, α is the preset learning rate, the former θ i is the updated model parameter value, the latter θ i is the model parameter value after the last update, l(θ i ) is Task i The corresponding cross entropy loss function.

[0088] Classify tasks according to each working condition in the above meta-training set i , determine the task of classifying the working conditions i The optimal parameter θ of the corresponding task model i Then, use each work condition to classify tasks i The query set and task model are forward propagated to calculate the cross entropy loss function l(θ i ), and accumulate the loss values ​​of the task model corresponding to each operating condition classification task (historical logging task) in the operating condition classification task set (historical logging task set) on the query set to update the initialization model parameter value θ 0 , as shown in the following formula:

[0089]

[0090] Among them, the former is the initialization model parameter value after this update, the latter is the initialization model parameter value after the last update, η is the preset learning rate; M is the total number of tasks in the operating condition classification task set (historical logging task set).

[0091] Based on the operating condition classification task set (historical logging task set) in the above meta-training set, the initialization parameter θ of the first initial operating condition probability prediction model is 0 Perform multiple updates until the set number of training times is reached and the iteration is stopped, and the model parameter value θ at this time is saved 0 is the optimal model parameter value.

[0092] Then, for each operating condition classification task in the meta-test set, we first use the optimal initialization parameter θ saved above 0 As the initial model parameter value of the task model corresponding to the working condition classification task, the initial model parameter value of the corresponding task model is updated using the Support set of the task. Secondly, the structure of the first initial working condition probability prediction model is optimized using the loss value of the task model corresponding to each task in the meta-test set in the Query set. That is, the model parameter values ​​of the first initial working condition probability prediction model are updated and its structure is optimized to obtain the second initial working condition probability prediction model, thereby ensuring that the performance of the subsequently obtained working condition probability prediction model is optimal.

[0093] In the process of drilling the target well, a working condition probability prediction model is obtained based on the meta-learning algorithm training. If a small amount of logging data corresponding to the overflow and / or leakage conditions of the wells adjacent to the target well and a large amount of logging data under normal conditions can be collected, the small amount of logging data corresponding to the overflow and / or leakage conditions and the large amount of logging data under normal conditions are cleaned and labeled to obtain the logging data of the adjacent wells labeled with the preset drilling operation conditions; if a small amount of logging data corresponding to the overflow and / or leakage conditions and a large amount of logging data under normal conditions cannot be collected, the historical logging data is obtained; and the multiple categories of normal drilling conditions (normal conditions) in the adjacent well logging data or historical logging data are uniformly labeled as normal, and under-sampled to construct a training set containing only the three conditions of overflow, leakage and normal, and the best model parameter value θ saved in the end is used as the training set. 0 As the initialization model parameter value of the second operating condition probability prediction model, and using the training set constructed above to the model parameter value θ of the second operating condition probability prediction model 0 Update to get the optimal model parameter value θ * , so we can get the optimal model parameter value θ * The corresponding pre-trained operating condition probability prediction model.

[0094] The current logging data of the target well at the current moment is obtained, and then the current logging data can be processed by filling missing data, replacing abnormal data, and normalizing the data. The processed current logging data is input into the working condition probability prediction model trained based on the meta-learning algorithm, and the probabilities of overflow, leakage, and normal working conditions are output. The working condition with the highest working condition probability can be selected as the current working condition. In this way, based on the small sample learning algorithm, the powerful nonlinear fitting ability of the deep learning method is used to overcome the problem of weak generalization of the deep learning model caused by the small number of overflow / leakage samples, and the same operating condition intelligent recognition accuracy can be achieved under the condition of a small number of samples as under the condition of a large number of training samples. The pre-trained working condition probability prediction model can be deployed to the drilling site or remote control center to realize the intelligent recognition of the current working condition (overflow condition, leakage condition, or normal condition) of the target well, which has important guiding significance for ensuring drilling safety.

[0095] In order to verify the effectiveness of the pre-trained operating probability prediction model in this application, L=60 in this experiment, and 50 samples of overflow, leakage, and normal operating conditions were collected from wells that have not participated in the model parameter value training. Among them, 30 samples of each operating condition were randomly selected for overflow / leakage intelligent detection model (i.e., pre-trained operating probability prediction model) training, and the rest were used for model testing. The first model is the operating probability prediction model obtained by training based on the meta-learning algorithm in this application. By updating the initialization model parameter value θ 0 , which can be obtained by iterating 50 times. The second model is a working condition probability prediction model obtained by training based on a machine learning algorithm in the prior art, which can be obtained by randomly initializing the model parameter values ​​and iterating 5000 times. Figure 4 As shown, by analyzing the accuracy of the first model and the second model on the test data, it can be found that the first model can achieve a higher recognition accuracy under the condition of a small number of overflow / leakage samples, while the second model has a lower accuracy under the condition of a small number of samples. Therefore, using the model trained based on the meta-learning algorithm in this application, it is possible to achieve the same operating condition recognition accuracy under the condition of a small number of samples as under the condition of a large number of training samples.

[0096] An embodiment of the present application also provides a device for determining an operating condition, comprising: a memory configured to store instructions; and a processor configured to call the instructions from the memory and to implement the above-mentioned method for determining an operating condition when executing the instructions.

[0097] An embodiment of the present application also provides a device for determining an operating condition, including: a device for determining an operating condition according to the above.

[0098] An embodiment of the present application also provides a machine-readable storage medium, on which instructions are stored, and the instructions are used to enable a machine to execute the above-mentioned method for determining an operating condition.

[0099] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0100] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0101] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0102] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0103] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0104] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0105] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0106] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0107] The above are only embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included within the scope of the claims of the present application.

Claims

1. A method for determining drilling operation conditions, characterized in that: The method comprises: During the drilling operation of the target well, obtaining the current logging data of the target well at the current moment; Based on the pre-trained operating condition probability prediction model, according to the current logging data, determining the operating condition probability of each first preset drilling operating condition corresponding to the target well, wherein the first preset drilling operating condition includes an overflow condition, a leakage condition, and a normal condition; The current drilling operation condition of the target well at the current moment is determined according to the multiple operating condition probabilities.

2. The method according to claim 1, characterized in that Determining the current drilling operation condition of the target well at the current moment according to the plurality of operating condition probabilities includes: Determining the maximum operating condition probability among the multiple operating condition probabilities to obtain a target operating condition probability; The first preset drilling operating condition corresponding to the target operating condition probability is determined as the current operating condition of the target well at the current moment.

3. The method according to claim 1, characterized in that The normal operating condition includes multiple sub-normal operating conditions; the training process of the operating condition probability prediction model includes: Acquire historical logging data of multiple second preset drilling operation conditions, where the second preset drilling operation conditions include the overflow condition, the leakage condition, and the multiple seed normal conditions; Selecting historical logging data of a preset number of working conditions multiple times from the historical logging data of the plurality of second preset drilling operation working conditions to obtain multiple historical logging task sets; According to the plurality of historical logging task sets, training a first initial operating condition probability prediction model to obtain a second initial operating condition probability prediction model; The second initial working condition probability prediction model is trained according to the historical logging data of the plurality of second preset drilling operation working conditions to obtain the working condition probability prediction model.

4. The method according to claim 3, characterized in that The step of training the first initial operating condition probability prediction model according to the plurality of historical logging task sets to obtain a second initial operating condition probability prediction model comprises: According to the multiple historical logging task sets, the first initial operating condition probability prediction model is trained until the number of training times reaches a preset number of training times to obtain the second initial operating condition probability prediction model.

5. The method according to claim 3, characterized in that: The training of the second initial working condition probability prediction model according to the historical logging data of the plurality of second preset drilling operating conditions to obtain the working condition probability prediction model includes: Merging the historical logging data of the plurality of sub-normal working conditions among the historical logging data of the plurality of second preset drilling operating conditions into the historical logging data of the normal working condition, so as to obtain the historical logging data of the plurality of first preset drilling operating conditions; According to the historical logging data of the plurality of the first preset drilling operation conditions, the model parameter values ​​of the second initial operating condition probability prediction model are updated to obtain the operating condition probability prediction model.

6. The method according to claim 3, characterized in that The training process of the operating condition probability prediction model also includes data preprocessing, and the data preprocessing includes at least one of the following: Based on a preset linear interpolation algorithm, performing missing data filling processing on the historical logging data of the plurality of preset drilling operation conditions; Based on a preset interquartile range method, abnormal data replacement processing is performed on the historical logging data of the plurality of preset drilling operation conditions.

7. The method according to claim 1, characterized in that The operating condition probability prediction model is a model trained based on a meta-learning algorithm.

8. A device for determining operating conditions, characterized in that: include: a memory configured to store instructions; as well as A processor is configured to call the instructions from the memory and implement the method for determining the working condition according to any one of claims 1 to 7 when executing the instructions.

9. A device for determining an operating condition, characterized in that: include: The device for determining operating conditions according to claim 8.

10. A machine-readable storage medium, characterized in that: The machine-readable storage medium stores instructions for causing a machine to execute the method for determining a working condition according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Drilling spill risk identification method, system and device based on convolutional neural network

    CN110443488A

  • Well drilling overflow leakage working condition prediction method and device

    CN111827982A

  • Well drilling underground working condition automatic identification method, device and equipment and storage medium

    CN115263269A

  • Petroleum drilling working condition identification method and device, electronic equipment and medium

    CN117786468A

  • Well drilling risk identification method and system and related equipment thereof

    CN118133159A

Cited By

  • Joint prediction method and system for drilling tool jamming risk and storage medium

    CN120832596A

  • Stuck pipe risk joint prediction method and system and storage medium

    CN120832596B