A drilling working condition identification method and device, computer equipment and medium
By constructing a working condition identification model based on state space recursive update, gating selection mechanism and dynamic convolution kernel, and combining it with a structured sequence decoding module, the problems of logical inconsistency and low recall rate in drilling working condition identification in the existing technology are solved, achieving high-precision drilling working condition identification and improving the intelligence and safety of drilling engineering.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA UNIV OF PETROLEUM (BEIJING)
- Filing Date
- 2026-01-13
- Publication Date
- 2026-05-05
AI Technical Summary
Existing drilling condition identification methods rely on logical thresholds or pure data-driven models, which can easily lead to illogical identification results. They are difficult to capture local and global features, and have low recall rates for complex conditions such as rotary lifting and pump start-up. They also lack logical modeling of condition transitions, which can easily lead to incorrect identification.
A drilling condition identification device is constructed by adopting a working condition identification model based on state space recursive update, gating selection mechanism and dynamic convolution kernel, combined with a structured sequence decoding module, and using conditional random field and restricted transition matrix for global constraints.
It improves the recognition accuracy and interpretation capability under long-tail conditions, enhances the intelligent, safe and digital transformation of drilling engineering, and has good engineering feasibility.
Smart Images

Figure CN121502491B_ABST
Abstract
Description
Technical Field
[0001] This manual relates to the field of oil and gas field exploration and development, and in particular to a drilling condition identification method, device, computer equipment and medium. Background Technology
[0002] Oil and gas drilling is one of the most critical aspects of oil and gas exploration and development. It establishes a wellbore between the surface and the reservoir to provide a pathway for oil and gas to flow to the surface. To ensure wellbore quality, the drilling process requires the coordination of various equipment and tools, and is completed collaboratively by workers from multiple professional fields. This construction process is complex, interconnected, and usually continuous. Statistics show that drilling costs account for more than 60% of the total cost of oil and gas exploration and development. To increase the intensity of oil and gas exploration and development and ensure energy security, it is imperative to reduce costs and increase efficiency in the drilling process. Therefore, timely analysis of performance indicators during drilling operations, provision of construction suggestions, and risk warnings are particularly important. The foundation of these efforts lies in accurately identifying the current drilling conditions and clarifying the construction operation status. By accurately obtaining the time proportion of each condition, the transition process between conditions, and the status of tools, reliable data support is provided for efficient KPI analysis, and a basis is provided for the next critical construction decisions, thereby reducing drilling risks and accidents.
[0003] Currently, most drilling condition identification methods are based on logical judgment models derived from expert experience. These models analyze drilling parameters by setting specific thresholds and rules, and can identify most common drilling conditions. Their advantage lies in their relatively simple implementation and good identification performance for most standard conditions. However, for some complex procedures involving multiple parameter variations that are difficult to describe with simple logical rules, such as rotary lifting and pump start-up (tripping in / out), traditional logical judgment models often struggle to identify them accurately.
[0004] In recent years, with the development of artificial intelligence technology, researchers have begun to introduce neural network models to realize the automatic identification of drilling conditions. Deep learning models such as convolutional neural networks (CNN) and recurrent neural networks (RNN / LSTM) have achieved certain results in the problem of condition classification. However, in existing research and industrial practice, such models still have several key problems: (1) The models generally lack the ability to integrate expert knowledge and cannot use the experience rules accumulated by field engineers over the years to assist in judgment, which easily leads to prediction results that contradict engineering logic; (2) Traditional logic threshold-based or deep learning models are difficult to capture local features and global features at the same time, resulting in low model accuracy; (3) Deep models have a good classification effect on mainstream conditions, but in identifying a small number of samples such as "starting the pump to start drilling (starting and stopping the drill)" and "rotating and lifting", the recall rate is low, the long tail problem is serious, which limits the integrity and practicality of the identification system; (4) Drilling field data has strong noise and short-term spikes, and traditional models are sensitive to fluctuations, which easily leads to incorrect identification; (5) There are strict operational sequence constraints between drilling conditions, and existing models lack modeling of condition transfer logic, which easily leads to unreasonable jumps. Summary of the Invention
[0005] To address the problem that existing technologies relying on logical thresholds or purely data-driven models are prone to producing illogical recognition results, this specification provides a drilling condition recognition method, apparatus, computer equipment, and medium. The method includes: performing initial classification of key feature parameters in real-time drilling parameters according to pre-set classification standard parameters to obtain initial operating condition categories. The classification standard parameters are determined as follows: determining the correlation coefficient between each key feature parameter and each drilling condition, obtaining the correlation coefficient calculation result; determining the classification standard parameters based on the correlation coefficient calculation result; and inputting the real-time drilling parameters corresponding to each initial operating condition category into the operating condition recognition model corresponding to the initial operating condition to obtain the drilling condition recognition result. The operating condition recognition model is constructed based on state-space recursive update, gating selection mechanism, and dynamic convolution kernel.
[0006] According to one aspect of an embodiment of this specification, the working condition identification model further includes: a structured sequence decoding module; the step of inputting real-time drilling parameters of multiple initial working condition categories into the working condition identification model and outputting drilling working condition identification results further includes: inputting real-time drilling parameters of multiple initial working condition categories into the working condition identification model and outputting time-series features; and applying global constraints to the time-series features based on the structured sequence decoding module to obtain the working condition identification results.
[0007] According to one aspect of an embodiment of this specification, the structured sequence decoding module includes: a conditional random field and a state transition matrix. Based on the structured sequence decoding module, global constraints on the temporal features include: combining the transmission score at each moment with the transition scores of adjacent condition labels to generate an overall scoring function for the complete path; and normalizing all condition label sequences according to the overall scoring function to obtain a conditional probability distribution, the formula of which is as follows:
[0008] ;
[0009] in, This represents the overall scoring function. Let x represent the observation sequence of real-time drilling parameters; y represent the working condition label sequence corresponding to the input observation sequence x; y′ represent all possible labels; establish the probability distribution of the modeling label sequence based on the conditional random field; iterate the partition function through all paths until the value of the objective function is minimized; determine the final transition score based on the state transition mask matrix and the initial transition score, and constrain the time series features based on the final transition.
[0010] According to one aspect of the embodiments of this specification, the correlation coefficient between each feature parameter and each working condition is determined in the following manner to obtain the correlation coefficient calculation result: the value of each key feature parameter is rank-transformed to generate an ordered column; the correlation coefficient between the ordered columns is calculated based on the label information of each working condition category; a feature working condition correlation matrix is established, where each element of the matrix represents the correlation coefficient calculation result between the feature and the working condition label.
[0011] According to one aspect of the embodiments of this specification, key feature parameters corresponding to each initial working condition category are respectively input into the working condition identification model corresponding to each initial working condition category to obtain drilling working condition identification results, including: performing state-space recursion on the key feature parameters to determine the relationship between the key feature parameters and the hidden states; performing nonlinear transformation on the key feature parameters and historical states based on gating units to generate gating weights; generating dynamic convolution kernels based on the hidden state parameters; performing pooling operations on the hidden state sequence to obtain a context representation vector; and outputting the working condition prediction probability based on the context representation vector.
[0012] This specification provides a drilling condition identification device, comprising: an initial classification unit, used to perform initial classification of key feature parameters in real-time drilling parameters according to pre-set classification standard parameters to obtain initial operating condition categories, wherein the classification standard parameters are determined by: determining the correlation coefficient between each key feature parameter and each drilling condition, obtaining the correlation coefficient calculation result; and determining the classification standard parameters based on the correlation coefficient calculation result; and an operating condition identification unit, used to input the real-time drilling parameters corresponding to each initial operating condition category into the operating condition identification model corresponding to the initial operating condition to obtain drilling condition identification results, wherein the operating condition identification model is constructed based on state space recursive update, gating selection mechanism, and dynamic convolution kernel.
[0013] This specification also provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the drilling condition identification method.
[0014] This specification also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the drilling condition identification method.
[0015] This application significantly improves the recognition accuracy and interpretation capability under long-tail conditions, providing solid support for the intelligent, safe, and digital transformation of drilling engineering, and is one of the key technical approaches to promote the upgrading of intelligent drilling systems in the oil and gas industry. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in the embodiments or prior art of this specification, the drawings used in the description of the embodiments or prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 The diagram shown is a flowchart of a drilling condition identification method according to an embodiment of this specification.
[0018] Figure 2 The diagram shown is a flowchart of a method for structured sequence decoding of output according to an embodiment of this specification.
[0019] Figure 3 The diagram shown is a flowchart of a method for globally constraining temporal features according to an embodiment of this specification.
[0020] Figure 4The diagram shown is a flowchart of a method for training and constructing a working condition recognition model according to an embodiment of this specification.
[0021] Figure 5A The diagram shown is a flowchart of a method for determining classification criteria parameters according to an embodiment of this specification.
[0022] Figure 5B The above is a flowchart of a method for determining the calculation result of the correlation coefficient according to an embodiment of this specification;
[0023] Figure 6 The diagram shown is a flowchart of a method for obtaining drilling condition identification results according to an embodiment of this specification.
[0024] Figure 7 The diagram shown is a preliminary classification of key feature parameters according to an embodiment of this specification.
[0025] Figure 8 The figure shown is a correlation coefficient heatmap of one embodiment of this specification;
[0026] Figure 9 The diagram shown is a structural schematic of a drilling condition identification device according to an embodiment of this specification.
[0027] Figure 10 The diagram shown is a schematic representation of a drilling condition identification method according to an embodiment of this specification.
[0028] Figure 11 The diagram shown is a structural schematic of a computer device according to an embodiment of this specification.
[0029] Explanation of symbols in the attached drawings:
[0030] 901. Initial classification unit;
[0031] 902. Operating Condition Identification Unit;
[0032] 1102. Computer equipment;
[0033] 1104. Processor;
[0034] 1106. Memory;
[0035] 1108. Drive mechanism;
[0036] 1110. Input / output module;
[0037] 1112. Input devices;
[0038] 1114. Output devices;
[0039] 1116. Presentation device;
[0040] 1118. Graphical User Interface;
[0041] 1120. Network interface;
[0042] 1122. Communication link;
[0043] 1124. Communication bus. Detailed Implementation
[0044] To enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this specification, and not all embodiments. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this specification.
[0045] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, apparatus, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.
[0046] This specification provides the operational steps of the methods described in the embodiments or flowcharts, but based on conventional or non-inventive labor, more or fewer operational steps may be included. The order of steps listed in the embodiments is merely one possible execution order among many and does not represent the only possible execution order. In actual system or device products, the methods shown in the embodiments or drawings can be executed sequentially or in parallel.
[0047] It should be noted that the drilling condition identification method, device, computer equipment and medium described in this specification can be used in the field of oil and gas field exploration and development, as well as in the field of artificial intelligence technology. This specification does not limit the application field of the drilling condition identification method, device, computer equipment and medium.
[0048] Figure 1 The diagram shown is a flowchart of a drilling condition identification method according to an embodiment of this specification, which specifically includes the following steps:
[0049] Step 101: Based on the pre-set classification standard parameters, perform initial classification of key feature parameters in real-time drilling parameters to determine the initial working condition category corresponding to the key feature parameters.
[0050] In the embodiments of this specification, key characteristic parameters represent core characteristic parameters reflecting the drilling operation status, including rotary table speed, torque, standpipe pressure, inlet flow rate, drilling pressure, well depth, hook load, and drill bit position.
[0051] In some embodiments of this specification, during normal drilling or reaming operations, both the rotary table and mud pump are in operation, and their values are relatively high. Conversely, during tripping operations, both values often approach zero. During simple circulation or pauses, the rotational speed approaches zero, but the flow rate remains normal. In rotating conditions, the flow rate approaches zero, but the rotational speed remains normal. Therefore, this step selects rotary table speed and inlet flow rate as two classification criteria parameters, which can accurately describe the main state characteristics of the drilling process. The rotary table speed reflects whether the drill string is rotating, and the inlet flow rate determines whether the mud pump is in the on / off state. For detailed descriptions of determining the classification criteria parameters in this step, please refer to [link to relevant documentation]. Figure 4 .
[0052] Based on the classification criteria parameters, the key characteristic parameters in the real-time drilling parameters are initially classified. In this step, the initial classification yields four initial operating condition categories: "reaming / drilling", "tripping in / out", "circulation / drilling", and "tripping in / out".
[0053] Step 102: Input the key feature parameters corresponding to each initial working condition category into the working condition identification model corresponding to each initial working condition category to obtain the drilling working condition identification result.
[0054] The working condition identification model is constructed based on state space recursive update, gating selection mechanism and dynamic convolution kernel, and is trained according to the key feature parameters of the sample.
[0055] After completing the initial division of working conditions in step 101, this application constructs a corresponding working condition recognition model for each initial working condition category. Specifically, a separate Mamba-Tiny sub-network is configured for each initial working condition to perform deep modeling of its internal fine-grained working conditions. This branching sub-network architecture reduces inter-class interference and avoids the masking effect of majority class features on minority class features during deep model training, thereby ensuring the fairness and accuracy of the model in long-tail working condition recognition. Specifically, the lightweight neural network architecture Mamba-Tiny based on a selective state-space model is used as the core modeling backbone of the recognition system to achieve dynamic modeling of minute-level long sequences.
[0056] The working condition identification model in this specification establishes a deep modeling architecture that takes into account both local features and global trends by combining recursive state updates, gating selection mechanisms, and dynamic convolutional kernels.
[0057] The core of the selective state-space model framework lies in encoding the input multivariate time-series data into a learnable state-space sequence. It uses parameterized convolutional kernels to dynamically filter key trend signals and employs a gating selection mechanism to selectively remember and forget during state updates, effectively extracting low-frequency trends and cross-variable coupling relationships. In drilling condition identification scenarios, the difference between many key states, such as "rotation lowering" and "rotation lifting," is not reflected in the absolute value at a particular moment, but rather in the trend coordination between parameters such as torque, hook load, and drill bit position. Examples include slow hook load descent, monotonically increasing position, and continuous torque fluctuation.
[0058] The operational condition identification model's structure enables the modeling of long-distance dependencies with linear complexity, taking into account both local response features and global behavioral evolution, thus greatly improving the accuracy and stability of identification. Because this structure consumes few resources and is highly portable during inference, it is suitable for drilling site control equipment and has good engineering feasibility.
[0059] This application not only effectively solves the shortcomings of traditional working condition identification models in terms of long dependency modeling, weak signal identification and logical consistency, but also provides a practical and feasible technical path for high-precision and real-time working condition identification in drilling operations, and has strong engineering application value and promotion prospects.
[0060] Figure 2 The diagram shown is a flowchart of a method for structured sequence decoding of output according to an embodiment of this specification, specifically including steps 201 to 202:
[0061] Step 201: Input the key feature parameters of multiple initial working condition categories into the working condition identification model corresponding to each initial working condition category, and output the time series features.
[0062] In this manual, the key feature parameters input to the working condition identification model are time series data. Specifically, drilling parameters are collected in real time according to a preset sampling period, so the key feature parameters obtained are time series data.
[0063] Key feature parameters are input into the working condition identification model, which then undergoes recursive state space updates, gating selection, and dynamic convolution to output temporal features.
[0064] In this specification, the form of time-series features is as follows: X[B,T,C], where B represents the number of features in the key feature parameters, T represents the time step, and C represents the feature dimension. For example, B = 12 indicates 12 different time-series feature sequences, which can be drilling data from 12 wells or drilling data input by 12 users; T = 1000 indicates that each time-series feature sequence includes 1000 consecutive observation time points; T = 10 indicates that the number of features observed simultaneously in each time step is 10.
[0065] Step 202: Based on the structured sequence decoding module, global constraints are applied to the temporal features to obtain the working condition identification result.
[0066] In this step, the output of drilling condition identification is input into the structured sequence decoding module to establish a restricted path search mechanism, and the state transition constraints of the drilling process are explicitly embedded in the global optimization decoding process.
[0067] Specifically, the structured sequence decoding module includes a Conditional Random Field (CRF) and a transition mask matrix. This step applies state transition constraints to the emission probability at each time step output by the working condition identification model, ensuring that the predicted path satisfies the logical rules of the drilling operation process in the time dimension. This ensures that the working condition identification strictly conforms to the drilling process logic and operational sequence throughout the entire time series path. In this step, the emission probability is obtained by softmax normalization of the emission score output by the working condition identification model, representing the conditional probability of the working condition identification model for the working condition label y at time t, given the observation sequence x. The formula is as follows:
[0068] Furthermore, the emission score is directly used as the emission term in CRF decoding. The emission score refers to the unnormalized log-likelihood of the model with respect to the label y at time t, which is derived from the hidden representation extracted by the dynamic convolution of the state-space network.
[0069] In this application, Conditional Random Fields (CRFs) are used to model the probability distribution of a label sequence given an observation sequence. The structured sequence decoding module uses CRFs combined with a restricted transition mask matrix to obtain a globally optimal label sequence that conforms to the drilling process logic through the Viterbi algorithm.
[0070] This step, which involves applying global constraints to temporal features based on the structured sequence decoding module, is described in detail in the following section. Figure 3 .
[0071] Figure 3 The diagram shown is a flowchart of a method for globally constraining temporal features according to an embodiment of this specification, specifically including steps 301 to 304:
[0072] Among them, the observation sequence represents the feature vector after state space processing by the working condition identification model, and the label sequence represents the state of eighteen types of drilling working conditions.
[0073] Step 301 combines the launch score at each moment with the transfer score of adjacent working condition labels to generate an overall scoring function for the complete path. In a drilling site, working conditions don't change instantaneously like a switch. For example, transitioning from drilling to tripping involves several steps: deceleration, stopping rotation, and then raising the drill string. These continuous physical actions determine the inherent dependencies and constraints between the working conditions of two consecutive time slices.
[0074] In some embodiments of this specification, if the identification algorithm only focuses on parameters at a single moment (such as rotational speed, torque, and flow rate), it will be misled by instantaneous noise and easily misjudge a pressure fluctuation as a change in operating conditions. However, when the algorithm comprehensively considers the state at the current moment and the state at the previous moment, that is, it considers adjacent operating conditions simultaneously, it can determine whether this fluctuation is within a reasonable transition trajectory.
[0075] Therefore, this step adopts the first-order Markov assumption of linear chain CRF: the dependency of the tag sequence is mainly reflected in adjacent time steps. By jointly modeling the launch score and the transition scores of adjacent conditions, a globally optimal path that satisfies the process constraints can be obtained by injecting drilling process priors through a restricted transition mask.
[0076] Specifically, this step first involves first-order Markov modeling based on a linear chain CRF, focusing only on the labels at time t-1. and Time tags A transition term is established to enable decoding to embed technological priors (restricted transition masks) while maintaining timing stability, thus achieving a globally optimal path search. This includes the transmission score. Indicates the model at time... For tags The unnormalized logarithmic fraction, from the hidden state Linear mapping yields (e.g.) CRF decoding directly uses transmit scores. As an emission term. Furthermore, the formula for the overall path scoring function is expressed as follows:
[0077] ;
[0078] in, Let x represent the overall scoring function, y represent the time-series features, and y represent the working condition label sequence. , Indicates time , tag as The emission score is output from the state space of the working condition identification model; Indicates the label from the state Transition to state The transfer score, Indicates that the label comes from Transferred to The transfer score. The transfer score is derived from the initial transfer score. and restricted transfer mask To be determined jointly.
[0079] when Retain the initial transition score. ,when The score is set to zero or a very small negative value to ensure that illegal transfers are completely blocked during decoding.
[0080] Initial transition score As learnable parameters of the CRF, they are learned from the data during the training phase by minimizing the negative log-likelihood (using sample frequency pairs). Log-proportional initialization is performed to accelerate convergence.
[0081] Step 302: Based on the overall scoring function, normalize all working condition label sequences to obtain the conditional probability distribution. The formula for the conditional probability distribution is as follows:
[0082] ;
[0083] in, This represents the overall scoring function. y represents the partition function, ensuring that the probability sum of all paths is 1; x represents the observation sequence of real-time drilling parameters, which consists of multi-channel time series data obtained by continuous sampling, including but not limited to key characteristic parameters such as riser pressure, rotary table speed, torque, and drilling pressure; y represents the working condition label sequence corresponding to the input observation sequence x; y′ represents all possible labels.
[0084] Step 303: Iterate through all paths using the partition function until the objective function value is minimized.
[0085] In this step, the objective function formula is as follows:
[0086] ;
[0087] in, Describe the objective function. Indicates the actual tag path, Let represent the partition function, x represent the observation sequence of real-time drilling parameters, and y represent the operating condition label sequence corresponding to the input observation sequence x. Calculating the partition function requires traversing all possible paths, and the computational complexity increases exponentially with the sequence length.
[0088] To improve efficiency, this application further employs a forward-backward dynamic programming algorithm for efficient computation. And its gradient, thereby achieving end-to-end joint training.
[0089] Although Standard Conditional Random Fields (SFRs) can achieve path-level optimization, their transition matrices are typically fully learnable and lack any physical constraints. This can lead to the model learning state transitions that are impossible in actual drilling processes. For example, a direct transition from a stationary state to a rotary drilling state, or from a rotary lifting state to a sliding drilling state, is clearly unreasonable in real-world operations. Therefore, it is necessary to filter out all transitions that do not conform to drilling logic. Table 1 illustrates these non-logical transition scenarios and is referred to as the constrained transition set.
[0090] Step 304: Determine the final transition score based on the state transition mask matrix and the initial transition score, and constrain the timing features based on the final transition score.
[0091] This step introduces a state transition mask matrix. This forcibly blocks all jumps that do not conform to drilling logic. The state transition mask matrix is defined as follows:
[0092] ;
[0093] The final transition score is determined based on the state mask transition matrix and the transition score. The formula is shown below:
[0094] ;in, Indicates the final transfer score. Indicates the label from the state Transition to state The transfer score, This represents the state transition mask matrix. When the transition mask is constrained... When the final transition score equals the initial transition score, the transition mask is restricted. When a transition does not conform to the process logic, the state transition mask matrix sets its score to zero or a very small negative value, completely masking the transition during decoding. Therefore, during global optimization, the Conditional Random Field (CRF) can only search for paths in the valid state subgraph, ensuring that the final output strictly follows the on-site operation process.
[0095] Specific examples of transfer rules, based on eighteen types of working conditions, are defined in Table 1 below:
[0096] Table 1. Set of Constrained Transfer Conditions
[0097]
[0098] Through the aforementioned restricted transition modeling, this application effectively narrows the candidate space of global path search, improves search efficiency, and ensures the physical rationality of the output path.
[0099] Figure 4 The diagram shown is a flowchart of a method for training and constructing a working condition recognition model according to an embodiment of this specification, specifically including steps 401 to 405:
[0100] Step 401: Obtain key feature sample parameters from historical drilling sample parameters.
[0101] In this step, based on the method of determining key characteristic parameters as in step 101, key parameters such as drilling pressure, rotation speed, torque, drilling fluid discharge, and wellbore trajectory parameters are screened from historical drilling sample data.
[0102] Step 402: Input the key feature sample parameters into the state space recursively to obtain the initial hidden representation.
[0103] In this step, key feature sample parameters are processed into batch time-series features and input into the state space recursion. All parameters are aligned by timestamp or drilling depth to form a time-series sequence with a uniform time step. The process of forming the time-series sequence also includes: data cleaning of key feature sample parameters and standardization or normalization of the data to avoid the impact of differences in parameter magnitudes on model training.
[0104] The key feature sample parameters after the above data preprocessing are processed into the form of time series features: X[B,T,C], which is [number of samples, time step, feature dimension]. For example, to obtain historical drilling sample data of 10 wells, 5 parameters are taken for 1000 time steps for each well, and the input format is [100, 1000, 5].
[0105] The state space recursion iterates through all time steps based on the temporal features of the input, generating the hidden state for each time step to obtain the hidden representation: H[B,T,D], which is: [number of samples, time step, dimension of hidden representation].
[0106] Alternatively, the hidden state of the last time step can be selected as the initial hidden representation, or the initial hidden representation within the corresponding time window can be extracted as a local representation for subsequent segmented analysis.
[0107] Step 403: The initial hidden representation is input into the gating selection mechanism to obtain a gated weighted representation. In this step, the gating selection mechanism generates a gating factor, applies time weighting or channel weighting, updates the weights or biases of the gating branches and regularization parameters, and outputs the gated weighted representation. .
[0108] Step 404: Input the gated weighted representation into the dynamic convolution kernel to obtain the emission features.
[0109] Dynamic convolution analyzes gated weighted representations through fully connected layers or lightweight convolutions. The feature distribution is used to generate dedicated convolutional kernel weights that match the input. Furthermore, dedicated convolutional kernels are used to convolve the gated weighted representations, aggregating the weighted features within a local temporal window to output emission features. Then linearly map to time-by-time sample emission scores. .in, The emission characteristic E[B,T, The new dimension of ] specifically represents the number of channels obtained after dynamic convolution and linear mapping. Dynamic convolution kernels and subsequent projection layers often change the number of channels (e.g., reducing the number of channels from 256 to 128 to reduce parameters); Indicates the number of operating condition categories.
[0110] Step 405: Determine the loss function value based on the score of the emission feature and the operating condition label, and iteratively update the initial model composed of the state space recursion, gating selection mechanism and dynamic convolution kernel based on the loss function value until the iteration stopping condition is met, thereby constructing the operating condition recognition model.
[0111] In this step, the sample emission score is calculated. With transition score matrix With a restricted transition mask, CRF uses forward, backward, or Viterbi logarithmic techniques to calculate gradients and updates all parameters end-to-end.
[0112] In this step, the loss function is as follows: ;
[0113] in, This represents the negative log-likelihood loss function. Mask ;
[0114] in, ; Represents the loss function of the smoothing term. ; Represents the kernel shape smoothing loss function. .
[0115] in, This represents the time-by-time emission score of the model output; This represents a sequence of labels indicating actual working conditions. This represents the label transition score matrix, with elements... Indicates from category Transfer to Category The score; Mask This indicates a restricted transfer mask (illegal transfers are set to 0, or in the implementation, it is related to...). The sum of the penalties is used to constrain the transitions in the CRF; The gating factor (reweighting time steps and / or channels) represents the sparse and smooth regularization, respectively. Represents a dynamic convolution kernel, denoted by implementation as (or Its shape is smooth and regular. ; ...
[0116] Based on the value of the loss function calculated by the initial model in each iteration, the initial model is iteratively optimized until the number of iterations reaches a preset threshold, or the value of the loss function converges to the preset threshold, at which point the initial model training is considered complete, and the constructed working condition recognition model is obtained.
[0117] Figure 5A The diagram shown is a flowchart of a method for determining classification criteria parameters according to an embodiment of this specification, specifically including steps 501 to 502:
[0118] Step 501: Determine the correlation between each key characteristic parameter and each working condition to obtain the correlation analysis results.
[0119] Before proceeding with this step, comprehensive logging parameters are continuously acquired from the actual well site using the on-site drilling data acquisition system. This allows for continuous sampling of multiple time-series parameters, including drill pressure, well depth, rotational speed, torque, pump pressure, inlet flow rate, standpipe pressure, hook load, and drill bit position. These parameters are referred to as characteristic parameters.
[0120] In some embodiments of this specification, key characteristic parameters such as rotary table speed, torque, riser pressure, inlet flow rate, drilling pressure, well depth, hook load, and drill bit position are closely related to changes in operating conditions.
[0121] For example, rotary table speed and torque can reflect the stress and rotation state of the drill bit, inlet flow rate and riser pressure directly determine the mud circulation characteristics, well depth and drill bit position characterize the drilling footage process, and hook load reflects the stress and tripping state of the drill string.
[0122] This step calculates the correlation between real-time drilling parameters and drilling conditions to obtain correlation analysis results. In some embodiments of this specification, during the model training phase, the correlation between historical drilling sample parameters and drilling conditions can be calculated separately to obtain correlation analysis results. Further, historical drilling sample parameters with higher values are selected as key feature parameters. In the embodiments of this specification, the Spearman Rank Correlation Coefficient can be used to calculate the correlation between the above key feature parameters and drilling conditions. By calculating the correlation coefficient, feature parameters with high correlation are selected as key feature parameters, thereby reducing redundant features and providing high-quality input data for subsequent model training. Specifically, strongly correlated feature parameters are retained as core features for subsequent modeling. These feature parameters can fully reflect the changes in key parameters during the drilling process, providing an important basis for subsequent model training. Therefore, in this specification, strongly correlated feature parameters are referred to as key feature parameters.
[0123] For details, please see the attached document. Figure 5B The above is a flowchart of a method for determining the correlation coefficient calculation result according to an embodiment of this specification, specifically including steps 5011 to 5013:
[0124] Step 5011: Perform rank transformation on the value of each key feature parameter to generate an ordered column.
[0125] The key feature parameters are sorted according to their numerical values, and each value of each key feature parameter is assigned a corresponding rank, forming an ordered column. The transformed ordered column can accurately reflect the relative magnitude relationships of the original key feature parameters.
[0126] Step 5012: Calculate the correlation coefficient between the order columns based on the label information of each working condition category.
[0127] In some embodiments of the specification, based on the causal relationship between equipment start-up / shutdown, drill string position, and fluid flow state during drilling operations, various drilling condition label information is defined, including but not limited to: rotary drilling, sliding drilling, forward reaming, reverse reaming, rotary lifting, rotary lowering, idle, circulation, in-situ circulation (tripping in / out), pump start tripping (tripping in / out), pump start tripping (tripping in / out), stuck, lifting drill string, lowering drill string, tripping, tripping, empty well, stationary. See Table 2 for specific operating condition categories.
[0128] Table 2 Operating Conditions
[0129]
[0130] During label generation, the difference between well depth and drill bit position is first calculated to determine whether the drill string has reached the bottom. Simultaneously, the coordinated changing trends of parameters such as rotational speed and torque, pump pressure and flow rate are analyzed to form multi-condition criterion nodes. These nodes are then compared sequentially through a rule tree and finally mapped to the corresponding drilling condition labels. Considering the short-term abrupt changes and ambiguous transition regions in some special conditions (e.g., "pump start-up (tripping in / out)" and "rotation lifting"), a corresponding drilling condition label is matched to each time-series data point of the key feature parameters, forming a one-to-one correspondence dataset in the form of "feature order column and condition label". For each feature variable's order column, it is paired with the label of each type of working condition (a label is recorded as 1 if the data point belongs to that condition, otherwise as 0). The Spearman correlation coefficient formula is used to calculate the correlation strength between the drilling condition label and the feature variable.
[0131] Specifically, let the order of a certain characteristic variable be R=[ (where n represents the total number of data points,) (Representing the rank of the nth data point), the label column for a certain type of working condition is S=[ [] represents the working condition label of the nth data point. First, calculate the mean of the order column and the mean of the label column, and then calculate the correlation coefficient using the formula.
[0132] For each working condition c∈{1,...,18}, a binary indicator is formed, as shown in the following formula:
[0133] ;in, The label indicates operating condition c.
[0134] For the key feature parameter x, let and The median rank (for cases of ties, the average rank is used).
[0135]
[0136] in, The correlation coefficient represents the rank. The label indicates operating condition c. This represents the mean of the ranking variable corresponding to the feature variable; This represents the mean of the ranking variables corresponding to the operating condition labels. The ranking variables for feature variables are obtained by replacing the original values with their rank after sorting the original values of the feature variables; the ranking variables for operating condition labels are obtained by replacing the original values with their rank after sorting the original values of the operating condition labels. n represents the number of data points. This represents the label for the i-th operating condition. This represents the rank of the i-th key feature parameter, and the correlation coefficient between the key feature parameter and 18 types of working conditions is calculated.
[0137] Step 5013: Establish a feature-condition correlation matrix. Each element of the matrix represents the correlation coefficient calculation result between the feature and the condition label.
[0138] Construct a correlation matrix for the characteristic operating conditions, with the matrix form shown below:
[0139]
[0140] ;in, This represents the k-th drilling feature. The label represents operating condition c. (Matrix) It is an 8-row × 18-column matrix. The rows of the matrix represent 8 core feature variables (including: rotary table speed, torque, etc.), and the columns represent 18 types of drilling conditions. The feature condition correlation matrix provides a comprehensive view of the relationship between each drilling feature and different conditions.
[0141] Specifically, each element in the feature condition matrix represents the Spearman correlation coefficient between the k-th drilling feature and the c-th condition. This coefficient ranges from -1 to 1. When the coefficient is positive, a larger value indicates a positive correlation between the feature's rank and the condition (a higher probability of the condition). Conversely, a negative value indicates a negative correlation (a lower probability of the condition). For example, if the correlation coefficient between the feature variable "rotary table speed" and the rotary drilling condition is 0.75, it means that the higher the rank of the rotary table speed, the significantly higher the probability that the feature variable belongs to the rotary drilling condition. Conversely, if the correlation coefficient between "rotary table speed" and the tripping / running-out condition is -0.72, it means that the higher the rank of the rotary table speed, the significantly lower the probability that the feature variable belongs to the tripping / running-out condition.
[0142] Step 502: Determine the classification criteria parameters based on the correlation analysis results.
[0143] like Figure 8 The diagram shown is a correlation coefficient heatmap according to an embodiment of this specification. The left axis of the diagram represents drilling characteristic parameters, including: rotary table speed, torque, inlet flow rate, riser pressure, drill bit position, measured well depth, hook height, and hook position. The horizontal axis 1 to 18 in the diagram represent 18 different operating conditions. The multiple color blocks in the diagram correspond to different correlation values, where a color that leans more towards orange-red indicates a higher correlation, and a color that leans more towards blue indicates a lower correlation.
[0144] The heatmap shows that drilling characteristic parameters—rotary speed and torque—are strongly correlated with conditions 1, 3, 4, 5, 6, and 7, but weakly correlated with other conditions. In other words, rotation-related operations (conditions 1 to 7) show a strong positive correlation with speed. Drilling characteristic parameters—inlet flow rate and standpipe pressure—are strongly correlated with conditions 1, 2, 3, 4, 8, 9, 10, and 11. Specifically, circulation operations (conditions 8 to 11) are closely related to inlet flow rate. This not only demonstrates the applicability of these two parameters as model features but also provides supporting evidence for preliminary classification. Furthermore, tripping-out related operations (conditions 12 to 16) show a more significant correlation with hook load, hook position, and well depth, consistent with the axial movement of the drill string. In contrast, empty wells and stationary states (conditions 17 to 18) show weaker correlations with most features because these states correspond to inactive operations.
[0145] Therefore, in one embodiment of this specification, the turntable speed and inlet flow rate are used as classification criteria parameters for the initial classification of key characteristic parameters.
[0146] In some other embodiments of this specification, torque and riser pressure, or torque and inlet flow rate, or rotary drilling speed and riser pressure may also be used as classification standard parameters. In some other embodiments of this specification, rotary drilling speed, torque, inlet flow rate, and riser pressure may also be used together as classification standard parameters.
[0147] After determining the classification standard parameters, this application further includes: performing initial classification of key feature parameters according to the classification standard parameters to obtain initial working condition categories. Specifically, a two-dimensional logical coordinate system is constructed with the classification standard parameters as the axis. For example, the presence or absence of rotation and the presence or absence of circulation are used as two-dimensional logical coordinates to aggregate the eighteen working conditions into four initial working condition categories: "reaming / drilling", "tripping in / out", "circulation / drilling", and "tripping in / out".
[0148] In some embodiments of this specification, under actual operating conditions, the measured speed or flow rate values often exhibit non-zero weak fluctuations when stationary due to zero drift or background disturbances in the measuring equipment. Therefore, relying solely on whether the value of key characteristic parameters is zero as a judgment criterion is unreliable. In some embodiments of this specification, an adaptive logic gating mechanism is adopted. Statistical indicators such as the mean, extreme values, and volatility within a sliding window are used to set start and stop thresholds for the speed and flow rate signals respectively. Based on this, a dual-threshold hysteresis discrimination logic is introduced. Only when the signal continuously exceeds the threshold and remains stable for a set duration is a state transition considered to have occurred, thereby effectively suppressing frequent misjudgments caused by zero drift and short-term glitches.
[0149] Therefore, in some embodiments of this specification, the initial operating condition category is obtained by comparing the key feature parameters with the magnitude of a preset adaptive threshold.
[0150] Specifically, when both the rotational speed and flow rate of the key characteristic parameter are greater than the preset adaptive threshold, it indicates that the drill string is simultaneously rotating and pumping, and this condition is classified as "reaming / drilling". If the rotational speed is greater than the preset adaptive threshold and the flow rate is less than or equal to the preset adaptive threshold, it indicates rotation but no pumping, and this condition is classified as "rotation". If the rotational speed is less than or equal to the preset adaptive threshold and the flow rate is greater than the preset adaptive threshold, it indicates no rotation but circulation, and this condition is classified as "circulation / drilling". If the rotational speed is less than or equal to the adaptive threshold and the flow rate is less than or equal to the adaptive threshold, it indicates that the equipment is stationary or in a purely mechanical state, and this condition is classified as "tripping in / out". This pre-classification structure, consisting of these four categories, has clear boundary segmentation criteria and is efficiently executed in the data processing flow through two-dimensional conditional logic judgments. This grouping method not only significantly simplifies the learning difficulty of the subsequent condition identification model but also provides a structurally traceable decision-making path.
[0151] Figure 6 The diagram shown is a flowchart of a method for obtaining drilling condition identification results according to an embodiment of this specification, specifically including steps 601 to 604:
[0152] Step 601: Perform state-space recursion on the key feature parameters to determine the relationship between the key feature parameters and the hidden states.
[0153] Specifically, this can be expressed by the following formula:
[0154] Where A represents the state transition matrix and B represents the input projection matrix. express Key feature parameters input at any time, , Indicates the number of channels. Indicates the sequence length. At time... At that time, the model introduces a hidden state vector. , Indicates at time Internal dynamic memory.
[0155] Through the state transition matrix and input projection matrix Update the hidden state vector and the state transition matrix. Used to control the evolution of hidden states over time. This is used to project key feature parameters into the latent state space. This recursive relationship ensures that the model can accumulate long-term contextual information, thereby adapting to low-frequency trends across time steps present in drilling data. For example, the slow changes in well depth and hook load, and the gradual fluctuations in torque. This latent state accumulation method can compress sequential evolution information of tens of minutes or even hours into a compact latent vector.
[0156] Step 602: Based on the gating unit, perform nonlinear transformation on the key feature parameters and historical states to generate gating weights.
[0157] The specific formula is as follows: ;
[0158] in, This indicates a hidden state. This represents the Sigmoid function. express Input data at any time, This represents the historical state at time t-1. and These represent the trainable weights, This represents element-wise product. Through a gating mechanism, the model can dynamically select which features to prioritize for memorization and which interference information to suppress, thereby effectively resisting interference from zero drift, noise spikes, and random disturbance signals. In this specification, this selective memorization feature is applicable to short-term hydraulic fluctuations and mechanical vibrations commonly found in drilling signals. It can shield irrelevant disturbances while maintaining effective trend signals, significantly improving the stability of the model in field deployment. The state-space structure in the condition identification model of this application can more naturally capture low-frequency trends and intervariate dependencies in drilling signals, such as the composite features formed by the slow evolution of drilling pressure and well depth over time. This is crucial for distinguishing subtle differences in operating conditions such as "rotational lowering" and "idling."
[0159] Step 603: Generate dynamic convolution kernels based on the hidden state parameters.
[0160] After obtaining the hidden state sequence in step 602, a selective convolution kernel function is introduced to achieve global aggregation across time.
[0161] In this application, the kernel weights are dynamically generated from the hidden state parameters, thereby enabling the convolution operation to have adaptive adjustment capabilities. The specific calculation formula is shown below:
[0162] ;
[0163] in, This represents a dynamically generated convolutional kernel based on state parameters, which expands linearly with the sequence length, ensuring a computational complexity of O(log n). Under the premise of covering long sequence dependencies, selective convolutional kernels significantly reduce computational complexity compared to attention mechanisms and avoid the resource bottleneck problem faced by self-attention in long sequence modeling. Through dynamic convolutional kernels, the model can not only extract the variation features of local time segments, but also capture the evolution trend of the overall sequence, achieving unity in local and global modeling.
[0164] Step 604: Perform pooling operation on the hidden state sequence to obtain the context representation vector, and output the working condition prediction probability based on the context representation vector.
[0165] In the embodiments described in this specification, a combination of average pooling and max pooling is used at the model's output to generate a context representation vector. This preserves global trends while enhancing features related to sudden changes. Furthermore, the context representation vector is mapped to the class space through a fully connected layer, outputting the predicted probability distributions for 18 work conditions. To improve training stability and prevent overfitting, normalization and Dropout regularization mechanisms are added before the fully connected layer, with the Dropout ratio set to 0.5 to ensure the model's generalization ability across different data subsets.
[0166] In terms of computational efficiency, the complexity of the Mamba-Tiny model in this application is linearly related to the sequence length. It does not cause a sharp increase in resource consumption as the input length increases, thus enabling it to operate stably in the constrained environment of the well site control computer.
[0167] In terms of robustness, the combination of gating mechanisms and dynamic convolutional kernels enables the model to actively select information channels and shield interference signals, ensuring reliable output even in high-noise and zero-drift environments. Regarding deployment adaptability, the structure is lightweight and modular, allowing for easy integration with front-end logic gating, back-end structured decoding, and confidence calibration modules to form a complete end-to-end recognition pipeline.
[0168] This application employs the Mamba-Tiny state-space model, combining recursive state updates, gating selection mechanisms, and dynamic convolutional kernels to establish a deep modeling architecture that considers both local features and global trends. In practical applications, this model demonstrates significant advantages in recognition accuracy, long sequence adaptability, real-time performance, and engineering deployability. It can meet the operational condition recognition needs under complex well site conditions, providing technical support for intelligent monitoring, anomaly detection, and decision support in the drilling process.
[0169] Figure 7 The diagram shown is a preliminary classification of key feature parameters according to an embodiment of this specification.
[0170] When both the rotational speed and flow rate of the key characteristic parameter are greater than the preset adaptive threshold, it indicates that the drill string is simultaneously rotating and pumping, and this condition is classified as "reaming / drilling". If the rotational speed is greater than the preset adaptive threshold and the flow rate is less than or equal to the preset adaptive threshold, it indicates rotation but no pumping, and this condition is classified as "rotation". If the rotational speed is less than or equal to the preset adaptive threshold and the flow rate is greater than the preset adaptive threshold, it indicates no rotation but circulation, and this condition is classified as "circulation / drilling". If the rotational speed is less than or equal to the adaptive threshold and the flow rate is less than or equal to the adaptive threshold, it indicates that the equipment is stationary or in pure mechanical motion, and this condition is classified as "tripping in / out". This pre-classification structure, consisting of these four categories, has clear boundary segmentation criteria and is efficiently executed in the data processing flow through two-dimensional conditional logic judgments. This grouping method not only significantly simplifies the learning difficulty of the subsequent condition identification model but also provides a structurally traceable decision path.
[0171] Figure 9 The diagram shown is a structural schematic of a drilling condition identification device according to an embodiment of this specification. The basic structure of the drilling condition identification device is illustrated in this figure. The functional units and modules can be implemented using software, or using general-purpose chips or specific chips to identify drilling conditions. The device specifically includes:
[0172] The initial classification unit 901 is used to perform initial classification of key characteristic parameters in real-time drilling parameters according to pre-set classification standard parameters to obtain the initial working condition category;
[0173] The working condition identification unit 902 is used to input the key feature parameters corresponding to each initial working condition category into the working condition identification model corresponding to the initial working condition to obtain the drilling working condition identification result. The working condition identification model is constructed based on state space recursive update, gating selection mechanism and dynamic convolution kernel.
[0174] Figure 10The diagram illustrates a drilling condition identification method according to an embodiment of this specification. In some embodiments of this specification, drilling parameters from a database or real-time monitoring system are labeled with operating condition tags based on a decision tree label generation mechanism using empirical rules and engineering logic. Subsequently, the labeled drilling parameters are cleaned and standardized. First, invalid samples missing key feature parameters are removed, and interference segments with drastic fluctuations but no physical meaning are excluded. Second, a sliding window sequence is constructed, with fixed-length time steps forming sample units for input into the deep learning model. The window length is set to 100 time steps based on the model's receptive field requirements and the drilling operation rhythm, approximately corresponding to 8 minutes of drilling time. The sliding window step size is set to 50, ensuring a sufficient number of samples while avoiding high overlap and redundancy between adjacent samples. Based on this, the data from each channel is normalized to eliminate the influence of dimensions. The normalized parameters are calculated on the training set and simultaneously used for verification and test data to ensure consistency in the evaluation process.
[0175] Finally, the processed dataset was divided into three parts: training set, validation set, and test set, with proportions of 70%, 15%, and 15%, respectively. Stratified sampling was performed for each drilling state category during the partitioning process to ensure consistency in category proportions and prevent imbalanced samples from affecting model training.
[0176] Using training and validation sets, initial classification of key feature parameters is performed to obtain initial working condition categories. Working condition recognition models for each category are then trained and adjusted. Finally, the test set is input into the working condition recognition model to obtain drilling working condition recognition results.
[0177] like Figure 11The diagram shown is a schematic representation of a computer device provided in an embodiment of this specification. The drilling condition identification method described in this application can be applied to the computer device. The computer device 1102 may include one or more processors 1104, such as one or more central processing units (CPUs), each of which can implement one or more hardware threads. The computer device 1102 may also include any memory 1106 for storing information of any kind, such as code, settings, data, etc. Without limitation, for example, the memory 1106 may include any one or more combinations of the following: any type of RAM, any type of ROM, flash memory, hard disk, optical disk, etc. More generally, any memory can use any technology to store information. Further, any memory can provide volatile or non-volatile retention of information. Further, any memory can represent a fixed or removable component of the computer device 1102. In one case, when the processor 1104 executes associated instructions stored in any memory or combination of memories, the computer device 1102 can perform any operation of the associated instructions. The computer device 1102 also includes one or more drive mechanisms 1108 for interacting with any memory, such as a hard disk drive mechanism, an optical disk drive mechanism, etc.
[0178] Computer device 1102 may further include an input / output module 1110 (I / O) for receiving various inputs (via input device 1112) and providing various outputs (via output device 1114). A specific output mechanism may include a presentation device 1116 and an associated graphical user interface (GUI) 1118. In other embodiments, the input / output module 1110 (I / O), input device 1112, and output device 1114 may be omitted, and the device may function solely as a computer device within a network. Computer device 1102 may also include one or more network interfaces 1120 for exchanging data with other devices via one or more communication links 1122. One or more communication buses 1124 couple the components described above together.
[0179] Communication link 1122 can be implemented in any way, such as via a local area network, a wide area network (e.g., the Internet), a point-to-point connection, or any combination thereof. Communication link 1122 may include any combination of hardwired links, wireless links, routers, gateway functions, name servers, etc., governed by any protocol or combination of protocols.
[0180] Corresponding to Figures 1 to 5A and Figure 5B In addition to the methods described above, embodiments of this specification also provide a computer-readable storage medium storing a computer program that, when executed by a processor, performs the steps of the methods described above.
[0181] This specification also provides computer-readable instructions, wherein when a processor executes the instructions, the program therein causes the processor to perform the following... Figures 1 to 5A and Figure 5B The method shown.
[0182] It should be understood that in the various embodiments of this specification, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this specification.
[0183] It should also be understood that, in the embodiments of this specification, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this specification generally indicates that the preceding and following related objects have an "or" relationship.
[0184] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed in this specification can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this specification.
[0185] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0186] In the several embodiments provided in this specification, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the couplings or direct couplings or communication connections shown or discussed may be indirect couplings or communication connections through some interfaces, devices, or units, or they may be electrical, mechanical, or other forms of connection.
[0187] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of the embodiments described in this specification, depending on actual needs.
[0188] Furthermore, the functional units in the various embodiments of this specification can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0189] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this specification, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this specification. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0190] This specification uses specific embodiments to illustrate the principles and implementation methods of this specification. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this specification. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this specification. Therefore, the content of this specification should not be construed as a limitation of this specification.
Claims
1. A method for identifying drilling conditions, characterized in that, The method includes: Based on pre-set classification standard parameters, key characteristic parameters in real-time drilling parameters are initially classified to determine the initial operating condition category corresponding to the key characteristic parameters. The classification standard parameters are determined as follows: the correlation coefficient between each key characteristic parameter and each drilling operating condition is determined to obtain the correlation coefficient calculation result; the classification standard parameters are determined based on the correlation coefficient calculation result. The key feature parameters corresponding to each initial working condition category are input into the working condition recognition model corresponding to each initial working condition category, and the time-series features are output. Based on the structured sequence decoding module, the time-series features are globally constrained to obtain the working condition recognition result, which includes: combining the transmission score at each moment with the adjacent working condition label transfer score to generate an overall scoring function for the complete path. Based on the overall scoring function, all working condition label sequences are normalized to obtain a conditional probability distribution, the formula of which is shown below: ; in, This represents the overall scoring function. Let represent the partition function, x represent the observation sequence of real-time drilling parameters; y represent the working condition label sequence corresponding to the input observation sequence x; and y′ represent all possible labels. Based on conditional random fields, establish the probability distribution of the modeled label sequence; Iterate through all paths using the partition function until the objective function value is minimized; The final transition score is determined based on the state transition mask matrix and the initial transition score, and the temporal features are constrained based on the final transition score; wherein, the working condition recognition model is constructed based on state space recursive update, gating selection mechanism and dynamic convolution kernel, and the working condition recognition model is trained based on the key feature parameters of the sample.
2. The method according to claim 1, characterized in that, The structured sequence decoding module includes: a conditional random field and a state transition matrix.
3. The method according to claim 1, characterized in that, The operating condition identification model is trained in the following manner: Obtain key feature sample parameters from historical drilling sample parameters; The key feature sample parameters are input into the state space recursively to obtain the initial hidden representation; The initial hidden representation is input into the gating selection mechanism to obtain the gating weighted representation; The gated weighted representation is input into the dynamic convolution kernel to obtain the emission features; The loss function value is determined based on the emission characteristics and operating condition labels. The initial model, which consists of state space recursion, gating selection mechanism and dynamic convolution kernel, is iteratively updated based on the loss function value until the iteration stopping condition is met, thus constructing the operating condition recognition model.
4. The method according to claim 1, characterized in that, The correlation coefficient between each key characteristic parameter and each operating condition is determined using the following method, and the correlation coefficient calculation results are obtained: The value of each key feature parameter is rank-transformed to generate an ordered column; Based on the label information of each working condition category, calculate the correlation coefficient between the order columns; Establish a feature-condition correlation matrix, where each element of the matrix represents the correlation coefficient calculation result between the feature and the condition label.
5. The method according to claim 1, characterized in that, The key feature parameters corresponding to each initial working condition category are input into the working condition identification model corresponding to each initial working condition category to obtain drilling working condition identification results, including: State-space recursion is performed on key feature parameters to determine the relationship between key feature parameters and hidden states; Based on the nonlinear transformation of key feature parameters and historical states by the gating unit, gating weights are generated. Generate dynamic convolution kernels based on the hidden state parameters; Pooling is performed on the hidden state sequence to obtain a context representation vector, and the operating condition prediction probability is output based on the context representation vector.
6. A drilling condition identification device, characterized in that, The device includes: An initial classification unit is used to perform initial classification of key feature parameters in real-time drilling parameters according to pre-set classification standard parameters, and determine the initial operating condition category corresponding to the key feature parameters. The classification standard parameters are determined as follows: the correlation coefficient between each key feature parameter and each drilling operating condition is determined, and the correlation coefficient calculation result is obtained; the classification standard parameters are determined based on the correlation coefficient calculation result. The working condition identification unit is used to input the key feature parameters corresponding to each initial working condition category into the working condition identification model corresponding to each initial working condition category to obtain the drilling working condition identification result and output the time series feature; based on the structured sequence decoding module, the time series feature is globally constrained to obtain the working condition identification result, which includes: combining the transmission score at each moment with the transfer score of the adjacent working condition label to generate an overall scoring function for the complete path; Based on the overall scoring function, all working condition label sequences are normalized to obtain a conditional probability distribution, the formula of which is shown below: ; in, This represents the overall scoring function. Let represent the partition function, x represent the observation sequence of real-time drilling parameters; y represent the working condition label sequence corresponding to the input observation sequence x; and y′ represent all possible labels. Based on conditional random fields, establish the probability distribution of the modeled label sequence; Iterate through all paths using the partition function until the objective function value is minimized; Based on the state transition mask matrix and the initial transition score, the final transition score is determined, and the temporal features are constrained based on the final transition score; wherein, the working condition recognition model includes: state space recursive update, gating selection mechanism and dynamic convolution kernel, and the working condition recognition model is trained based on the key feature parameters of the samples.
7. A computer device, characterized in that, The computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Well drilling underground working condition automatic identification method, device and equipment and storage medium
CN115263269A
Bi-GRU + MLP-based drilling complex working condition diagnosis method
CN117312986A