A method and device for measuring tool face angle of rotary steerable drilling tool system

By introducing conditional generation adversarial networks and residual neural networks into the rotary guide drilling tool system, the particle degradation and noise covariance matrix unknown in tool face angle measurement are solved, and a higher precision tool face angle estimation is achieved, reducing drilling costs.

CN120123662BActive Publication Date: 2025-08-22CHINA UNIV OF PETROLEUM (EAST CHINA)
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510596248.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-09
Publication Date
2025-08-22
Estimated Expiration
2045-05-09

AI Technical Summary

Technical Problem

In the prior art In the rotary guide drilling tool system, the measurement accuracy of tool face angle is insufficient, especially when the noise covariance matrix is ​​unknown under complex underground working conditions, the traditional particle filtering method has particle degradation and shortage problems, making it difficult to achieve accurate tool face angle estimation.

Method used

The particle generation model based on the condition generation adversarial network and the noise covariance estimation model of the residual neural network are adopted, combined with the measurement data of high-precision IMU sensors, dynamic measurement of tool face angle is performed through the particle filtering algorithm, and particle selection is used for the condition generation adversarial network, and the noise covariance matrix is ​​estimated through the residual neural network to improve the measurement accuracy.

Benefits of technology

The tool face angle estimation accuracy of rotary guide drilling tool system is improved, the drilling cost is reduced, and the measurement stability and accuracy in complex operating conditions are enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120123662B_ABST
    Figure CN120123662B_ABST
Patent Text Reader

Abstract

The present invention relates to a method and device for measuring the tool face angle of a rotary steerable drilling tool system. The method comprises the following steps: S1, establishing a dynamic mathematical model of the tool face angle and embedding it into a traditional particle filter algorithm framework; S2, establishing a particle generation model based on a conditional generative adversarial network; S3, establishing a noise covariance estimation model based on a residual neural network; S4, training the residual neural network using measurement data from a high-precision IMU sensor; S5, selecting particles using a generator; S6, calculating weights using a discriminator and a residual neural network; and S7, calculating the tool face angle using a particle filter algorithm. Taking into account the high nonlinearity and unknown time-varying noise covariance matrix of rotary steerable drilling tool systems under complex working conditions, the present invention proposes an intelligent particle filter method for drilling tool systems that can accurately measure the tool face angle in real time, which is of great significance for improving drilling efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of oilfield drilling, and relates to a method and a device for measuring the tool face angle of a rotary steering drilling tool system. Background Art

[0002] The rotary steerable drilling tool system (RSDTS) is a key device in oil and gas exploration, used to precisely control the drill bit to drill according to a preset tool face angle. The measurement accuracy of the tool face angle directly affects system performance, and traditional static measurement methods lack real-time performance. To this end, the paper "Estimation of Toolface for dynamic point-the-bit rotarysteerable systems via nonlinear polynomial filtering" (Sheng Li, Niu Yichun, Wang Weiliang, et al., IEEE Transactions on Industrial Electronics, 2022) transforms real-time measurement into a nonlinear filtering problem. However, the complex downhole environment presents two major challenges for filtering: first, traditional methods (such as EKF and UKF) have difficulty handling the nonlinear dynamics in the model; second, the covariance matrix of the measurement noise and process noise is unknown and time-varying, increasing the difficulty of filtering.

[0003] The particle filter is a widely used algorithm for nonlinear filtering. Its core approach is to combine importance sampling theory with probability distribution approximation methods for discrete random measures to achieve recursive computation of probability distributions. According to the paper "A tutorial on particle filters for online nonlinear / non-Gaussian Bayesian tracking" (Arulampala MS, Maskell S, Gordon N, Clapp T. IEEE Transactions on Signal Processing, 2002), traditional particle filters suffer from particle shortage and degradation, resulting in particles failing to accurately describe the true distribution. This phenomenon stems from suboptimal particle state selection, and the key to resolving it lies in designing an appropriate importance sampling distribution. The paper "Remaining useful life prediction of lithium-ton batteries based on conditional variational autoencoders-particle filter" (Ruihua Jiao, Kaixiang Peng, Jie Dong. IEEE Transactions on Intrumentation and Measurement, 2020) utilizes a conditional variational autoencoder generative model to guide particle state selection, learn the underlying distribution of the data, and generate new data that matches the distribution. Using a sequential sampling strategy, this method is able to sample from the theoretically optimal true posterior distribution. However, the generative model is essentially a black box model, and it is difficult to directly obtain the true probability value from it, which makes the direct calculation of particle weights more difficult.

[0004] When the noise covariance matrix is ​​unknown, the application of particle filtering faces significant challenges. Unlike Kalman filtering, particle filtering, as a non-parametric Bayesian filtering implementation, makes it difficult to directly introduce parametric methods such as variational Bayesian inference or maximum expectation to jointly estimate the noise covariance matrix and state. Although the paper "Joint state estimation for nonlinear state-space model with unknown time-variant noise statistics" (Li K, Zhao SY, Liu F. International Journal of Adaptive Control and Signal Processing, 2021) attempts to combine variational Bayesian inference with particle filtering and derives an update formula for the measurement noise covariance, due to the particle filter's reliance on the sampling process, this method is prone to deviations when dealing with particle shortages and degradation problems, and its theoretical effectiveness is limited. In addition, when the process noise covariance is unknown, the determination of particle states and the calculation of weights are more complicated.

[0005] Currently, there is little research available on the dynamic measurement of toolface angles in rotary steerable drilling systems. Considering the effects of strong nonlinearity in the output function and the unknown, time-varying noise covariance matrix under complex downhole conditions, a new intelligent particle filtering method, using deep learning, is designed for this system to improve toolface angle estimation accuracy. Summary of the Invention

[0006] The present invention addresses the problems of particle degradation and shortage in particle filtering of tool face angles, as well as the problem of unknown noise covariance matrix under complex downhole working conditions. A method for measuring the tool face angle of a rotary steerable drilling tool system is provided, which can accurately estimate the tool face angle and reduce drilling costs.

[0007] In order to achieve the above object, the present invention provides a method for measuring the tool face angle of a rotary steerable drilling tool system, comprising the following steps:

[0008] S1. Establish a dynamic mathematical model of tool face angle and embed it into the traditional particle filter algorithm framework;

[0009] S2. Establish a particle generation model based on conditional generative adversarial network;

[0010] S3. Establish a noise covariance estimation model based on residual neural network;

[0011] S4, using the measurement data of the high-precision IMU sensor to train the residual neural network;

[0012] S5, using conditional generative adversarial network generator for particle selection;

[0013] S6, using the discriminator and residual neural network to calculate weights;

[0014] S7. Use particle filter algorithm to solve tool face angle.

[0015] Furthermore, in step S1, the specific steps of establishing the dynamic mathematical model of the tool face angle are:

[0016] The measurement equation of the triaxial accelerometer is as follows:

[0017] (1)

[0018] Where, 、 Represents the measurement values ​​of the y-axis and z-axis of the accelerometer, is the gyroscope measurement, 、 and They represent the measurement noise of the sensor, represents the component of gravitational acceleration, assuming that it satisfies , is noise, Indicates the tool face angle.

[0019] Let the state variable represents the tool face angle, represents the gravitational acceleration component, then the tool face angle dynamic model is as follows:

[0020] (2)

[0021] in,

[0022] x k = [ x 1 , k x 2 , k ] , B = [ m 0 ] , u k = y 3 , k ω k = [ − m ω 1 , k ω 2 , k ] , y k = [ y 1 , k y 2 , k ] v k = [ v 1 , k v 2 , k ] , h ( x k ) = [ x 2 , k s i n ( x 1 , k ) − x 2 , k c o s ( x 1 , k ) ]

[0023] in, is the system sampling interval, and to describe the noise characteristics of the well, it is assumed that and , in The representative mean is The covariance matrix is Gaussian distribution, and are the unknown time-varying covariance matrix parameters;

[0024] In the particle filter framework, for The posterior distribution of the state at the moment , which can be expressed as

[0025]

[0026] in, It is 0 time The particle state at the moment Represents the system output, Representative particles Collection of is the particle weight, is the number of particles, is the Dirac function. In the update phase, a new particle state is generated by introducing a preset sampling distribution.

[0027] The weight recursive formula can be derived through the principle of importance sampling

[0028]

[0029] And the relevant probability density function can be calculated according to the following formula

[0030]

[0031] in, Represents Gaussian distribution The probability density function of .

[0032] Furthermore, in step S2, the conditional generative adversarial network is used to guide the particle filter for sampling. For any time , its generator The input label is the tool face angle dynamic model (2) State of the moment , Moment Label and a random Gaussian noise , the output is distributed Status Discriminator The input includes the real state of the system and the data generated by the generator, and the output is the discrimination score. The neural network is optimized through the dynamic game between the generator and the discriminator, so that the generated data approximately obeys the posterior distribution. .

[0033] Furthermore, in step S3, the noise covariance matrix is ​​estimated using a residual neural network combined with a particle filter; for any time ,right The particle state at the moment Perform grid processing to convert it into image data; the input of the residual neural network includes Particle imaging data at each moment and Systematic measurement of time , the residual neural network output is The process noise covariance matrix parameters at time and The measurement covariance matrix parameters at time , which respectively represent the estimated value of the noise covariance matrix, and the calculation formula is:

[0034] , .

[0035] Furthermore, in step S4, the high-precision IMU sensor includes a gyroscope and an accelerometer, and the conditional generative adversarial network and the residual network are trained using the gyroscope and accelerometer measurements of the high-precision IMU, including the following steps:

[0036] S401: Use Tool face angle and The accelerometer measurement at each moment is used as the input of the generator in the conditional generative adversarial network. The measured value of the tool face angle at the moment is used as the output, and the discriminator is trained with the log-likelihood based on the score as the loss function;

[0037] S402: Use the temporal back propagation algorithm to train the residual neural network, and its loss function is:

[0038]

[0039] Since the neural network parameters The state estimation error at different times has different effects, so s t = [ w t 1 ,..., w t N s ] represents a set of weights, z t = [ U t − 1 V t ] represents the output of the neural network, As the input terminal and , then the gradient of the neural network can be calculated as follows:

[0040]

[0041] For each moment t, in order to obtain , we need to use the chain rule

[0042] .

[0043] Furthermore, in step S5, a conditional generative adversarial network is used to replace the traditional particle selection mechanism. The specific method is as follows: for any time and particles ,Will and tags The data generated by the generator in the conditional generative adversarial network is used as particles ,Right now In addition, for the more complex items in the particle weight calculation , using the discriminator score to represent, that is, making the following reasonable assumptions

[0044] .

[0045] Furthermore, in step S6, the covariance matrix is ​​estimated using the residual neural network, and the discriminator of the conditional generative adversarial network is combined to guide the particle filter to update the particle weights. The specific method is: the covariance matrix generated by the residual neural network is used to calculate the likelihood value of the particle according to the following formula

[0046]

[0047] The calculation of particle prior probability includes

[0048]

[0049] Calculate the pseudo weight of the particle state , and then calculate the particle weight according to the following formula:

[0050] .

[0051] Furthermore, in step S7, the tool face angle is calculated according to the following formula:

[0052] .

[0053] The present invention also provides a tool face angle measurement device for a rotary steerable drilling tool system, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of any of the above-described methods for measuring the tool face angle of a rotary steerable drilling tool system are implemented.

[0054] Compared with the prior art, the advantages and positive effects of the present invention are:

[0055] The present invention provides a method and apparatus for dynamically measuring the tool face angle of a rotary steerable drilling tool system. Taking into account the high nonlinearity of the accelerometer measurement system's output function and the unknown, time-varying noise covariance matrix, the present invention introduces a conditional generative adversarial network for particle guidance and uses a residual neural network to estimate the covariance matrix, further improving the filtering accuracy of the rotary steerable drilling tool system. BRIEF DESCRIPTION OF THE DRAWINGS

[0056] Figure 1 This is a flow chart of a tool face angle measurement method according to an embodiment of the present invention;

[0057] Figure 2Schematic diagram of the tool face angle model;

[0058] Figure 3 Schematic diagram of the intelligent particle filtering algorithm of the present invention;

[0059] Figure 4 The distribution diagram of particle states of different algorithms over all time;

[0060] Figure 5 The distribution diagram of particle states of different algorithms on four time slices;

[0061] Figure 6 This is a diagram of the tool face angle measurement results of the algorithm described in the present invention;

[0062] Figure 7 Schematic diagram of the estimation error between the algorithm of the present invention and four similar algorithms;

[0063] Figure 8 Schematic diagram of the estimation error between the algorithm of the present invention and three similar algorithms;

[0064] Figure 9 Schematic diagram of the filtering results of the algorithm and low-pass filter described in the present invention. DETAILED DESCRIPTION

[0065] The present invention is described in detail below by way of exemplary embodiments, but it should be understood that elements, structures, and features of one embodiment may be beneficially combined in other embodiments without further description.

[0066] See also Figure 1 An embodiment of the present invention provides a tool face angle measurement method (ResCGAN-PF) for a rotary steerable drilling tool system. This method, based on intelligent particle filtering, can address the problems of high nonlinearity and unknown time-varying noise covariance matrices in the system. The specific steps are as follows:

[0067] S1. Establish a dynamic mathematical model of the tool face angle system and embed it into the traditional particle filter algorithm framework;

[0068] Simple diagram of a rotary steerable drilling tool system Figure 2 The measurement equation of the triaxial accelerometer is as follows:

[0069] (1)

[0070] Where, 、 Represents the measurement values ​​of the y-axis and z-axis of the accelerometer, is the gyroscope measurement, 、 and They represent the measurement noise of the sensor, represents the component of gravitational acceleration, assuming that it satisfies , is noise, Indicates the tool face angle.

[0071] Let the state variable represents the tool face angle, represents the gravitational acceleration component, then the tool face angle dynamic model is as follows:

[0072] (2)

[0073] in,

[0074] x k = [ x 1 , k x 2 , k ] , B = [ m 0 ] , u k = y 3 , k ω k = [ − m ω 1 , k ω 2 , k ] , y k = [ y 1 , k y 2 , k ] v k = [ v 1 , k v 2 , k ] , h ( x k ) = [ x 2 , k s i n ( x 1 , k ) − x 2 , k c o s ( x 1 , k ) ]

[0075] in, is the system sampling interval, which is generally set to 0.001. To describe the noise characteristics of the well, assume and , in The representative mean is The covariance matrix is Gaussian distribution, and are the unknown time-varying covariance matrix parameters.

[0076] In the particle filter framework, for The posterior distribution of the state at the moment , which can be expressed as

[0077]

[0078] in, It is 0 time The particle state at the moment Represents the system output, Representative particles Collection of is the particle weight, is the number of particles, It is a Dirac function. In the update phase, a new particle state is generated by introducing a preset sampling distribution. The weight recursive formula can be derived through the importance sampling principle.

[0079]

[0080] And the relevant probability density function can be calculated according to the following formula

[0081]

[0082] in, Represents Gaussian distribution The probability density function of .

[0083] S2. Establish a particle generation model based on conditional generative adversarial networks and learn the posterior distribution;

[0084] Using conditional generative adversarial networks to guide particle filtering for sampling, in order to solve the particle degradation and shortage problems in particle filtering, a feasible approach is to adopt a suitable sampling distribution. Since the optimal sampling distribution satisfies:

[0085]

[0086] This part requires designing a generator to simulate the distribution For any moment , its generator The input label of is the tool face angle dynamic model, as shown in formula (2) State of the moment , Moment Label and a random Gaussian noise , the output is distributed Status Discriminator The input includes the real state and the generated state of the generator, and the output is the discriminant score. The dynamic game between the generator and the discriminator optimizes the neural network so that the generated data approximately obeys the posterior distribution. .

[0087] Based on the generator-discriminator framework, the conditional generative adversarial network (CGAN) introduces conditional information and adds labels to the input of the discriminator and generator. Assuming that the data under a given label Subject to conditional distribution , the generator of the conditional generative adversarial network can generate The optimization goal is achieved through the adversarial game between the discriminator and the generator, and its loss function can be expressed as:

[0088] m i n G m a x D V ( G , D ) =  x l o g [ D ( x | y ) ] +  z l o g [ 1 − D ( G ( z , y ) ) ] .

[0089] The generator input of CGAN consists of the following three parts: random variables obeying multivariate Gaussian distribution , system output and the particle state at the previous moment , the output is the current particle state The generator network consists of three fully connected layers, each with 64 neurons, and each layer integrates a batch normalization layer and a LeakyRelu activation function. Correspondingly, the discriminator also adopts a three-layer fully connected network structure, with the same number of neurons in each layer as the generator, and is also equipped with a batch normalization layer and a LeakyRelu activation function.

[0090] S3. Establishing a noise covariance estimation model based on a residual neural network, and estimating the noise covariance matrix based on the residual neural network;

[0091] The noise covariance matrix is ​​estimated by using a residual neural network combined with a particle filter. Since the distribution information of the state in the particle filter is represented by disordered particles, it is difficult to extract features from it. Since the state of the rotary steerable drilling tool system is two-dimensional, its particle set can be treated as an image for processing. For any time ,right The particle state at the moment Perform grid processing to convert it into image data. The input of the residual neural network includes Particle imaging data at each moment and Systematic measurement of time , the residual neural network output is The process noise covariance matrix parameters at time and The measurement covariance matrix parameters at time , which respectively represent the estimated value of the noise covariance matrix, and the calculation formula is:

[0092] , .

[0093] The ResNet module consists of three identical residual blocks. The number of channels of its convolutional layer is 64, and each convolutional layer uses a convolution kernel of size 3x3 and a LeakyRelu activation function.

[0094] S4. Use the measurement data of the high-precision IMU sensor to train the residual neural network;

[0095] Specifically, the IMU sensor includes an IMU gyroscope and an accelerometer, and the conditional generative adversarial network and the residual neural network are trained through the IMU gyroscope and accelerometer measurements; the steps include:

[0096] S401: Use Tool face angle and The accelerometer measurement at each moment is used as the input of the generator in the conditional generative adversarial network. The measured value of the tool face angle at the moment is used as the output, and the discriminator is trained with the log-likelihood based on the score as the loss function;

[0097] S402: Since the network parameters of the residual neural network will have different effects on the estimation error at different times, the residual neural network is trained using the temporal back propagation algorithm, and its loss function is:

[0098] .

[0099] Since the neural network parameters The state estimation error at different times has different effects, so s t = [ w t 1 ,..., w t N s ] represents a set of weights, z t = [ U t − 1 V t ] represents the output of the neural network, As the input terminal and , then the gradient of the neural network can be calculated as follows:

[0100]

[0101] For each moment t, in order to obtain , we need to use the chain rule

[0102]

[0103] as well as:

[0104] d s t d s t − 1 = [ d w t 1 d w t − 1 1 ⋯ d w t 1 d w t − 1 N s ⋮ ⋱ ⋮ d w t N s d w t − 1 1 ⋯ d w t N s d w t − 1 N s ]

[0105] is the gradient effect of the output of the neural network on the particle weight,

[0106] d s t d z t = [ d w t 1 d U t − 1 d w t 1 d V t ⋮ ⋮ d w t N s d U t − 1 d w t N s d V t ]

[0107] for i ∈ [ 1 , N s ] ,have

[0108]

[0109] and The calculation involves the probability density function of the Gaussian distribution and Total differential of the covariance matrix, is the gradient of the neural network output with respect to the input.

[0110] S5. Use the conditional generative adversarial network generator for particle selection;

[0111] For particle collections , combining the particle state with the current observation value to form the input feature , and use it as the input of the generator in CGAN. In this way, the generated particles obey the distribution

[0112]

[0113] Implemented the particle sampling step. For the more complex items in the particle weight calculation , using the discriminator score to represent, that is, making the following reasonable assumptions

[0114] .

[0115] S6, using the discriminator and residual neural network to calculate weights;

[0116] Specifically, a residual neural network is used to estimate the covariance matrix, and the discriminator of the conditional generative adversarial network is combined to guide the particle filter to update the particle weights;

[0117] Use residual neural network to estimate the covariance matrix and guide particle filter to update particle weights;

[0118] The covariance matrix generated by the residual neural network is used to calculate the particle likelihood value according to the following formula:

[0119]

[0120] The calculation of particle prior probability includes

[0121]

[0122] Calculate the pseudo weight of the particle state

[0123]

[0124] Then calculate the particle weight according to the following formula:

[0125]

[0126] Algorithm design diagram as follows Figure 3 .

[0127] S7. Use particle filter algorithm to solve tool face angle.

[0128] The tool face angle is calculated by taking the weighted average of each particle and its weight, i.e.

[0129] .

[0130] This patent proposes a tool face angle measurement method for rotary steerable drilling tool systems. First, to address the particle shortage and degradation issues inherent in the application of particle filtering algorithms, a particle selection mechanism based on a conditional generative adversarial network (CGAN) is constructed. In this mechanism, a generator network optimizes the sampling distribution through adversarial training to generate a high-precision particle set; a discriminator network evaluates the true posterior probability of the generated particles, thereby guiding the calculation of particle weights. Second, to address the unknown and time-varying nature of the noise covariance matrix in complex downhole conditions, a covariance matrix estimator based on a residual neural network is designed. This module is integrated end-to-end with a CGAN-guided particle filtering algorithm to form a closed-loop optimization system. The residual network module fully utilizes the model information in the particle filtering algorithm while providing accurate covariance matrix estimation for the particle filter.

[0131] In other embodiments, a rotary steerable drilling tool system tool face angle measurement device is also provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the various steps of the method described in the above-mentioned rotary steerable drilling tool system tool face angle measurement method are implemented, and the specific steps are not repeated here.

[0132] To demonstrate the effectiveness and feasibility of this invention, the following is a further explanation of the invention, based on experiments using a rotary steerable drilling tool system. The experimental noise environment was generated by a vibration platform. The experimental data demonstrates that the proposed algorithm can effectively solve the dynamic measurement problem of tool face angles and achieves higher accuracy than similar algorithms.

[0133] Example 1:

[0134] We first verified the significant advantages of the ResCGAN-PF algorithm over traditional PF algorithms in particle selection. We performed particle filtering on 2,000 data points over 20 seconds from the test set and compared the particle distribution results of different algorithms. Figure 4 The particle distribution of each algorithm at 2000 sampling points is shown in the figure. The upper figure shows the tool face angle value, and the lower figure shows the gravitational acceleration component. Figure 5 We further compare the particle states at four specific time points (k=75, 250, 500, and 750): the blue points represent the traditional particle filter algorithm, the yellow points represent the ResCGAN-PF algorithm, and the red points represent the true state. The number of particles for all algorithms is set to 64.

[0135] Experimental results show that most particles in traditional particle filters are far from the true state, indicating poor particle selection. Because traditional particle filters fail to fully utilize the measured posterior information, a large number of particles are concentrated in low-likelihood regions, resulting in a particle shortage. Furthermore, a large number of particles have low weights, resulting in wasted computational resources and causing particle degradation. In contrast, the particle states of the ResCGAN-PF algorithm are closer to the true state and provide effective information. By guiding particles to concentrate in high-likelihood regions through a conditional generative adversarial network, ResCGAN-PF accurately describes the posterior distribution of the current state, effectively addressing particle degradation and shortage issues, and significantly improving filtering accuracy.

[0136] Example 2:

[0137] Figure 6 The filtering performance of the ResCGAN-PF algorithm was demonstrated. Experiments showed that the estimated values ​​of the tool face angle and gravitational acceleration components fluctuated slightly around the true values, verifying the algorithm's robustness under time-varying and unknown noise covariance matrices. To comprehensively evaluate the algorithm's performance, two sets of experiments were designed: the first set compared the traditional particle filter (PF), genetic particle filter (GPF), and variational autoencoder particle filter (CVAEPF) to verify the improved particle selection strategy; the second set compared the variational Bayesian filter (VBPF) and expectation-maximization Kalman filter (EMKF), focusing on evaluating the proposed method's advantages in handling time-varying noise covariance.

[0138] Since the first set of algorithms cannot handle the case where the noise covariance matrix is ​​time-varying and unknown, we set the process noise in the algorithm to , The mutation parameter in GPF is set to 0.1. Figure 7 Given the estimation error based on the sine and cosine metrics, it is calculated as

[0139]

[0140] Experimental results show that the ResCGAN-PF algorithm achieves the lowest estimation error among all compared algorithms. In the first set of experiments, both CVAEPF and ResCGAN-PF improve particle selection strategies through generative models. However, CVAE only optimizes particle distribution and cannot directly participate in weight calculation, while the CGAN discriminator provides effective information for weight updates, making ResCGAN-PF more compatible with the particle filter framework. Compared with traditional PF, GPF improves particle diversity and reduces estimation error through genetic manipulation. However, due to the lack of theoretical support for genetic algorithms and the fact that they do not change the particle sampling distribution, their performance is inferior to intelligent algorithms based on generative models.

[0141] Figure 8The estimation errors of the ResCGAN-PF algorithm and existing adaptive filtering algorithms are demonstrated. The VBPF algorithm sets the process noise covariance matrix to 0.1I, and the measurement noise covariance matrix to an initial value of I, which is iteratively updated using a variational Bayesian algorithm. However, it lacks an adaptive update mechanism for the process noise covariance matrix and does not fully consider the time-varying nature of the noise, resulting in inferior performance to the ResCGAN-PF algorithm. The EMEKF algorithm relies on a first-order linear approximation of the system's nonlinear functions for updating the noise covariance matrix, resulting in low estimation accuracy for highly nonlinear systems. Because the output function of the RSDTS system contains sine and cosine functions, the EMEKF filtering performance is poor. In contrast, the ResCGAN-PF algorithm leverages the particle filter's advantage in fitting nonlinearities to overcome the limitations of linearization methods. By leveraging a generative model-guided particle selection strategy and the ability to dynamically estimate the noise covariance matrix, the ResCGAN-PF algorithm effectively solves the tool face angle measurement problem for RSDTS under complex working conditions.

[0142] Example 3:

[0143] In order to illustrate the application prospects of the present invention in practical engineering, we compare the ResCGAN-PF algorithm with the traditional low-pass filter. We design the following low-pass filter for solving the tool face angle in system (2):

[0144]

[0145] in,

[0146] φ k * = [arctan ( − y 1 , k y 2 , k ) , y 1 , k 2 + y 2 , k 2 ]

[0147] That is, the tool face angle is directly calculated from the accelerometer measurement value. is the time constant (determines the cutoff frequency) and is set to 0.1. The tool face angle measurement results of the low-pass filter and the proposed algorithm are shown in Figure 9 As shown in Figure 3, it can be seen that the tool face angle estimation effect of the low-pass filter is poor due to the failure to fully utilize the information in the state space equation.

[0148] The above embodiments are used to explain the present invention rather than to limit the present invention. Any modifications and changes made to the present invention within the spirit of the present invention and the protection scope of the claims shall fall within the protection scope of the present invention.

Claims

1. A method for measuring the tool face angle of a rotary steerable drilling tool system, characterized in that The following steps are involved: S1. Establish a dynamic mathematical model of tool face angle and embed it into the traditional particle filter algorithm framework; S2. Establish a particle generation model based on conditional generative adversarial network; use conditional generative adversarial network to guide particle filtering for sampling. For any time , its generator The input tag is the tool face angle dynamic mathematical model State of the moment , System output at each moment and a random Gaussian noise , the output is distributed Status Discriminator The input includes the real state of the system and the data generated by the generator, and the output is the discrimination score. The neural network is optimized through the dynamic game between the generator and the discriminator, so that the generated data approximately obeys the posterior distribution. ; S3. Establish a noise covariance estimation model based on residual neural network; use residual neural network combined with particle filter to estimate the noise covariance matrix; for any time ,right The particle state at the moment Perform grid processing to convert it into image data; the input of the residual neural network includes Particle imaging data at each moment and System output at each moment , the residual neural network output is The process noise covariance matrix parameters at time and The measurement covariance matrix parameters at time , which respectively represent the estimated value of the noise covariance matrix, and the calculation formula is: , ; S4, using the measurement data of the high-precision IMU sensor to train the residual neural network; S5, using the generator to select particles; S6. Use the discriminator and residual neural network to calculate the weights; use the residual neural network to estimate the covariance matrix, and combine the discriminator of the conditional generative adversarial network to guide the particle filter to update the particle weights. The specific method is: the covariance matrix generated by the residual neural network is used to calculate the likelihood value of the particle according to the following formula The calculation of particle prior probability includes Calculate the pseudo weight of the particle state , and then calculate the particle weight according to the following formula: ; S7. Use particle filter algorithm to solve tool face angle.

2. The method for measuring the tool face angle of a rotary steerable drilling tool system according to claim 1, wherein: In step S1, the specific steps of establishing the dynamic mathematical model of the tool face angle are: The measurement equation of the triaxial accelerometer is as follows: (1) Where, 、 Represents the measurement values ​​of the y-axis and z-axis of the accelerometer, is the gyroscope measurement, 、 and They represent the measurement noise of the sensor, represents the component of gravitational acceleration, assuming that it satisfies , is noise, represents the tool face angle; Let the state variable represents the tool face angle, represents the gravitational acceleration component, then the tool face angle dynamic model is as follows: (2) in, in, is the system sampling interval, and to describe the noise characteristics of the well, it is assumed that and , in The representative mean is The covariance matrix is Gaussian distribution, and are the unknown time-varying covariance matrix parameters; In the particle filter framework, for The posterior distribution of the state at the moment , which can be expressed as in, It is 0 time The particle state at the moment, Represents the system output, Representative particles Collection of is the particle weight, is the number of particles, Is the Dirac function. In the update phase, a new particle state is generated by introducing a preset sampling distribution. The weight recursive formula can be derived through the principle of importance sampling And the relevant probability density function can be calculated according to the following formula in, Represents Gaussian distribution The probability density function of .

3. The method for measuring the tool face angle of a rotary steerable drilling tool system according to claim 1, wherein: In step S4, the high-precision IMU sensor includes a gyroscope and an accelerometer, and the conditional generative adversarial network and the residual network are trained using the gyroscope and accelerometer measurements of the high-precision IMU, including the following steps: S401: Use Tool face angle and The accelerometer measurement at each moment is used as the input of the generator in the conditional generative adversarial network. The measured value of the tool face angle at the moment is used as the output, and the discriminator is trained using the log-likelihood based on the score as the loss function; S402: Use the temporal back propagation algorithm to train the residual neural network, and its loss function is: Since the neural network parameters The state estimation error at different times has different effects, so represents a set of weights, represents the output of the neural network, As the input terminal and , then the gradient of the neural network can be calculated as follows: For each moment t, in order to obtain , we need to use the chain rule 。 4. The method for measuring the tool face angle of a rotary steerable drilling tool system according to claim 1, wherein: In step S5, the conditional generative adversarial network is used to replace the traditional particle selection mechanism. The specific method is as follows: for any time and particles ,Will and tags The data generated by the generator in the conditional generative adversarial network is used as particles ,Right now ; In addition, for the more complex items in the particle weight calculation , using the discriminator score to represent, that is, making the following reasonable assumptions 。 5. The method for measuring the tool face angle of a rotary steerable drilling tool system according to claim 1, wherein: In step S7, the tool face angle is calculated according to the following formula: 。 6. A device for measuring tool face angle of a rotary steerable drilling tool system, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that When the processor executes the computer program, the steps of the method for measuring the tool face angle of a rotary steerable drilling tool system according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Target tracking algorithm based on generative adversarial network

    CN110232702A

  • Robot state estimation method and system based on variational inference

    CN115070765A