A gyroscopic vibration imaging method based on Bi-LSTM strong encoder
Through a deep learning method based on Bi-LSTM strong encoder, a high-precision gyroscope oscillator characterization distributed images are constructed, which solves the problem of degradation of measurement accuracy and large amount of finite element analysis in complex environments, and realizes more efficient gyroscope internal structure analysis and intelligent adjustment.
Patent Information
- Application Number
- CN202510205637.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-25
- Publication Date
- 2025-04-22
- Estimated Expiration
- 2045-02-25
AI Technical Summary
The measurement accuracy of existing MEMS gyroscopes has decreased in complex environments, the finite element analysis method has a large amount of calculation and long solution time, and the analysis method combined with deep learning has not yet fully explored the internal structure and electrical characteristics distribution of the gyroscope.
The gyro vibration imaging method based on Bi-LSTM strong encoder is adopted to build a model through deep learning technology, and the complex nonlinear relationship of gyro characterization parameters is extracted using Bi-LSTM and Transformer encoder to construct a high-precision oscillator characterization distributed image.
It significantly improves the accuracy and quality of image reconstruction, enhances the transparency of the internal structure of the gyroscope, improves the intelligence level of gyroscope adjustment, and reduces the cost of gyroscope adjustment.
Smart Images

Figure CN119693432B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of MEMS gyroscopes, and in particular relates to a gyroscope vibration mode imaging method based on a Bi-LSTM strong encoder. Background Art
[0002] MEMS (Micro Electro Mechanical systems) gyroscopes work based on the Coriolis effect, and their core principle is to use the energy transfer between two orthogonal resonant modes to measure angular velocity. The performance of gyroscopes is easily affected by complex environments such as temperature, which leads to a decrease in measurement accuracy and makes it difficult to ensure the accuracy of predictions.
[0003] Traditional finite element analysis methods use fine meshing to draw images of complex gyroscope structures in order to observe the internal structure of the gyroscope, which results in a huge amount of calculation and a lengthy solution time. Therefore, analysis methods combined with deep learning have received widespread attention. Using deep learning technology to learn the physical change laws of the internal parameters of the gyroscope and analyze the vibration characteristics of the gyroscope is of great significance for non-destructive testing and quality control during the gyroscope processing process.
[0004] Existing artificial neural network (ANN) models can map complex nonlinear functions and have been recognized in many fields, such as radial basis function (RBF) neural network, enhanced ML method combined with adaptive soft threshold segmentation (AST-ELM), and a supervised autoencoder (AE) neural network with encoder and decoder networks to construct images. Although these methods have made some progress in the field of electrical capacitance tomography (ECT), most of these methods are a combination of deep learning and gyro electrical imaging. The research of these methods mainly focuses on the surface of gyro equipment and its impact on electrical signals, which also means that the research on the complexity of the internal structure and the distribution of electrical characteristics of gyro equipment is not deep enough. Therefore, the existing methods still have the following main disadvantages:
[0005] (1) High time complexity. When dealing with gyroscopes with highly complex internal structures and subtle feature changes, the finite element method constructs images through precise mesh division, which requires a lot of computing time.
[0006] (2) Limited prediction accuracy. Since the complex relationship between the internal parameters of the gyroscope is not fully considered and there is a lack of in-depth research on the distribution of the internal electrical characteristics of the gyroscope, the existing algorithms may not be able to accurately capture the deep laws of the gyroscope's operation, resulting in limited prediction accuracy.
[0007] (3) Low spatial resolution. Due to the nonlinearity and ill-posedness of electrical imaging problems, the spatial resolution of the reconstruction results is often low, which makes it difficult to meet application scenarios with high requirements for details.
[0008] Therefore, the present invention proposes a gyroscopic vibration imaging method based on a Bi-LSTM (Bidirectional Long Short-Term Memory) strong encoder. Summary of the invention
[0009] The purpose of the present invention is to provide a gyro vibration type imaging method based on a Bi-LSTM strong encoder, and to use deep learning technology to build a gyro vibration type imaging model based on a Bi-LSTM strong encoder to construct a resonator characterization distribution image to improve the accuracy and quality of image reconstruction and enhance the transparency of the internal structure of the gyroscope.
[0010] To achieve the above object, the present invention provides the following technical solutions:
[0011] A gyroscopic vibration imaging method based on Bi-LSTM strong encoder includes the following steps:
[0012] Step 1, obtaining a real resonator characterization distribution diagram and gyroscope characteristic parameters that vary with time, and constructing a gyroscope characteristic parameter data set, and preprocessing the data set; the gyroscope characteristic parameters include standing wave angle, amplitude, phase and energy;
[0013] Step 2: Build a gyroscopic vibration imaging model based on Bi-LSTM strong encoder, which includes Bi-LSTM strong encoder module, fully connected layer and reshaping module;
[0014] The Bi-LSTM strong encoder module includes a Bi-LSTM unit and a Transformer encoder;
[0015] The processing process of the preprocessed data in the gyroscopic vibration imaging model is as follows:
[0016] First, the preprocessed gyroscope characteristic parameters are passed through the Bi-LSTM unit to output a hidden state sequence. Then, the hidden state sequence is input into the Transformer encoder to extract the global features of the sequence, and the output of the Transformer encoder and the output of the Bi-LSTM unit are residually connected.
[0017] After the residual connection, the different gyroscope characteristic parameter variables are mapped to the pixel values of the image through the fully connected layer to obtain the resonator representation distribution on the pixels of the entire image;
[0018] Finally, the input is sent to the reshape module, where the low-dimensional features are converted into a two-dimensional image shape using a reshape operation;
[0019] Step 3: Based on the data set of step 1, the gyroscopic vibration imaging model constructed in step 2 is trained and evaluated, and then the trained gyroscopic vibration imaging model is used to construct a gyroscopic resonator characterization distribution image.
[0020] Compared with the prior art, the present invention has the following beneficial effects:
[0021] The present invention utilizes deep learning methods to automatically learn the complex nonlinear relationship between the internal variables of the gyroscope, rather than staying on the surface of the gyroscope device and its impact on the electrical signal. It improves the traditional Bi-LSTM network structure, introduces the Transformer model as a powerful global information encoder, and uses residual connections to learn finer-grained features, so as to better capture the complex spatiotemporal dependencies between the internal parameters of the gyroscope, significantly improves the accuracy and quality of image reconstruction, enhances the transparency of the internal structure of the gyroscope, and improves the intelligence level of gyroscope adjustment.
[0022] While deeply analyzing the internal structure of the gyroscope, the present invention also fully considers the impact of various factors such as micromachining process accuracy and material properties on system performance, and constructs a large-scale gyroscope characteristic parameter data set; this data set contains the change rules of the internal parameters of the gyroscope (such as standing wave angle, amplitude, phase, energy, etc.) under the influence of different factors, providing strong data support for model training and verification.
[0023] The present invention breaks through the limitations of traditional analysis methods and can reveal the internal operating mechanism of the gyroscope in a more comprehensive and in-depth manner. It not only realizes the refined modeling of the internal structure of the gyroscope, but also provides new ideas and technical means for the future design, processing and adjustment of gyroscopes, which helps to reduce the adjustment cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments are briefly introduced below.
[0025] Figure 1 This is a physical model diagram of a MEMS gyroscope under non-ideal conditions;
[0026] Figure 2 It is a flow chart of a gyroscopic vibration imaging method based on a Bi-LSTM strong encoder in an embodiment;
[0027] Figure 3 It is a structural diagram of LSTM in the embodiment;
[0028] Figure 4 It is a structural diagram of the Transformer encoder in the embodiment;
[0029] Figure 5This is a curve comparison chart of training Loss and verification Loss;
[0030] Figure 6 This is a comparison diagram between the image reconstructed using the method of the present invention and the real image. DETAILED DESCRIPTION
[0031] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.
[0032] Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making any creative work shall fall within the scope of protection of the present invention.
[0033] Example
[0034] like Figure 2 As shown, this embodiment describes a gyroscopic vibration imaging method based on a Bi-LSTM strong encoder, and the method includes the following steps:
[0035] Step 1: Obtain a real resonator characterization distribution diagram and gyroscope characteristic parameters that vary with time, construct a gyroscope characteristic parameter data set, and preprocess the data set; the gyroscope characteristic parameters include standing wave angle, amplitude, phase, and energy.
[0036] The gyroscope system integrates the main control chip, interface circuit and gyroscope. The main control chip is responsible for signal processing and closed-loop control, and the interface circuit is responsible for signal amplification and sampling. Through precise design, accurate measurement and closed-loop control of the gyroscope angular rate are ensured. This step is based on the mathematical model of the motion equation of the gyroscope mode, combined with the four error sources of frequency difference, damping difference, damping coupling degree, and stiffness coupling degree. Through coherent demodulation, the in-phase channel (in-phase component) and orthogonal channel (orthogonal component) of the x and y modes are obtained, and the characterization information such as standing wave angle, amplitude, phase and energy are solved, and a large-scale data set is constructed to provide a basis for image reconstruction.
[0037] The following is a detailed description of the basic principle of the gyroscope. The gyroscope works based on the Coriolis effect. The core principle is to use the energy transfer between two orthogonal resonant modes (i.e., primary resonance and secondary resonance) to measure angular velocity. This system can be simplified to a spring-damper-mass block model with two degrees of freedom, such as Figure 1As shown in the figure, in this model, the x-axis is responsible for excitation, corresponding to the primary resonant mode; the y-axis is responsible for picking up vibration, corresponding to the secondary resonant mode. When an alternating electrostatic force is applied to the x-axis to excite vibration, if there is an angular velocity input on the z-axis, the Coriolis force will act on the mass block, causing the vibration amplitude of the y-axis to change. This change is proportional to the angular velocity, so by detecting the displacement of the y-axis, the angular velocity of the z-axis can be known. The primary resonant mode is also called the driving mode, and the secondary resonant mode is called the sensitive or detection mode.
[0038] In step 1, obtaining the distribution diagram and parameters of the actual resonator characterization of the gyroscope includes the following steps:
[0039] Step 1.1, gyroscope equation modeling;
[0040] In practical applications, the precision of micromachining technology and the influence of material properties on the gyro system must be fully considered. Therefore, the damping coefficient and stiffness coefficient are defined for the two modes respectively. Figure 1 As shown, the mathematical model is:
[0041] ;
[0042] ;
[0043] In the formula, m represents the equivalent mass, x and y represent the displacements on the two axes respectively. and Represents the speed on the two axes respectively. and Represent the acceleration on the two axes, represents the damping of the x mode, represents the stiffness of the x mode, represents the damping of the y mode, represents the y-modal stiffness; and As the driving force to drive the two modes respectively, if there is an angular velocity input on the z-axis, and Represent the Coriolis force sensitivity items sensed in the x-mode and y-mode respectively, where is the angular gain factor, which is determined by the geometry of the gyro head and the vibration mode of the gyro effect.
[0044] In actual gyroscopes, there are problems of damping cross-coupling and stiffness cross-coupling between the two gyroscope modes. The damping coupling is caused by the problem of non-proportional damping, while the stiffness coupling is caused by misalignment and manufacturing defects. The mathematical model considering cross-coupling is expressed as:
[0045] ;
[0046] ;
[0047] In the formula, = is the stiffness coupling coefficient term between the two modes, = is the damping coupling coefficient term between the two modes.
[0048] The Laplace transform to the complex frequency domain is expressed as:
[0049] ;
[0050] In practice, the following commonly used quantities are defined:
[0051] ;
[0052] In the formula, is the physical rotation angular rate of the z-axis, is the resonant frequency of the x mode, is the resonant frequency of the y mode; and is the quality factor of the two modes; and represents the intermediate variable caused by stiffness cross-coupling; and Represents the intermediate variable caused by damped cross coupling.
[0053] An ideal axisymmetric gyroscope requires the same stiffness in both modes, that is, the same resonant frequency. , this state of the gyro is called mode matching; in actual axisymmetric gyros, there is often a frequency difference , resonant frequency difference It is used to reflect the degree of modal splitting. This state of the gyroscope is called modal splitting.
[0054] Step 1.2: Data generation.
[0055] exist Figure 2In the structure of the gyro system, the two input ports of the gyro model are x-mode input and y-mode input (excitation electrodes), and the two output ports are x-mode output and y-mode output (detection electrodes). The signals output from the two input ports are picked up by their respective transimpedance amplifier circuits, and the charge in the gyro detection capacitor is extracted in the form of current, converted into voltage and transmitted to the analog-to-digital converter. The analog-to-digital converter converts the picked-up vibration information from an analog signal to a digital signal, and transmits it to the field programmable gate array FPGA through a full-duplex serial peripheral interface protocol. In the FPGA, the demodulation of the in-phase channel (in-phase component) and the orthogonal channel (orthogonal component) of the two modes is completed through multiple multipliers and low-pass filters, and the baseband signal obtained is , , and , For x modal believer, is the x-mode orthogonal channel, For the y mode, is the signal of the y-mode orthogonal channel. , , and The vibration energy E can be derived:
[0056] ;
[0057] By using the demodulation reference signal in the coherent demodulation , By adding a phase into the phase modulator, the function of the phase modulator can be realized; after the phase of the sensitive mode (y-th resonant mode) is corrected by the phase modulator, the sensitive mode , which can represent the angular rate output, and the driving mode , , it is necessary to perform phase and modulus length calculations in the CORDIC circuit of the FPGA to obtain the phase and amplitude of the driving mode respectively for use in the phase-locked loop and automatic gain control.
[0058] Due to the limitations of processing technology and materials, it is impossible for the two modes of the micro-resonant gyro mechanical vibrator to achieve complete consistency in damping and stiffness ( , ≠ ). Therefore, under non-ideal conditions, the dynamic standing wave angle output solution of the full-angle mode gyro is for:
[0059] ;
[0060] In the formula, represents the damping error coefficient between the two modes, represents the resonant frequency difference between the two modes, represents the orthogonality error of the resonator, represents the vibration energy of the gyroscope resonator, represents the angle, represents the gyro angular rate gain, Represents the physical rotation angular rate about the z-axis.
[0061] According to the above principles, the numerical simulation method is used to establish a finite element model of the resonator, visualize the calculated vibration mode, and obtain the real resonator characterization distribution diagram. At the same time, the gyroscope characteristic parameters such as standing wave angle, amplitude, phase and energy are generated.
[0062] In step 1, simulation technology is used to generate simulation data such as standing wave angle, amplitude, phase and energy. When collecting data, noise and uncertainty will inevitably be generated. Direct use will affect the training effect of the model. Therefore, a series of preprocessing of the original data is required. Data preprocessing includes the following steps:
[0063] (1) Data cleaning: In order to improve the quality and reliability of the data, outliers and repeated gyroscope characteristic parameter data were processed;
[0064] (2) Smoothing filtering: In order to suppress high-frequency noise and retain low-frequency information, a moving average filter is used to effectively separate high-frequency and low-frequency information to achieve a denoising effect;
[0065] (3) Data normalization: Scaling the data to the range of [-1, 1] can prevent gradient explosion or vanishing problems during model training and accelerate model convergence.
[0066] The preprocessed data are arranged in time series. Each time series constitutes a sample. The sample contains the standing wave angle, amplitude, phase and energy that change with time. The final data set is a collection of 1.13 million gyroscope characteristic parameters of different time series. For easy processing, the data is stored in CSV file format, where each row represents a time step and each column represents a characteristic parameter.
[0067] To facilitate subsequent model training, the preprocessed dataset is divided into training set, validation set and test set in a ratio of 7:1:2. The training set is used for model learning, the validation set is used for selecting model hyperparameters and verifying model effects, and the test set is used to evaluate the generalization ability of the model on unseen data.
[0068] Step 2: To address the problems of low prediction efficiency and low reconstructed image resolution in existing methods, this embodiment builds a gyroscopic vibration imaging model based on a Bi-LSTM strong encoder, which includes a Bi-LSTM strong encoder module, a fully connected layer, and a reshaping module. The Bi-LSTM strong encoder module includes a Bi-LSTM unit and a Transformer encoder;
[0069] The Bi-LSTM unit is used to encode the gyroscope characteristic parameter sequence and output the hidden state sequence; the Transformer encoder uses the encoder part in the Transformer model to extract the features of the input sequence in the gyroscope characteristic parameter time series prediction.
[0070] First, the preprocessed gyroscope characteristic parameters pass through the Bi-LSTM unit to output a hidden state sequence; then, the hidden state sequence is input into the Transformer encoder to extract the global features of the sequence; in order to alleviate the accuracy loss caused by too low resolution, the output of the Transformer encoder and the output of the Bi-LSTM unit are residually connected, allowing the feature information to be directly passed to the deep network, retaining more original information and avoiding the loss of feature information in the intermediate process; after the residual connection, the different gyroscope characteristic parameter variables are mapped to the pixel values of the image through the fully connected layer to obtain the oscillator representation distribution on the pixels of the entire image; finally, it is input into the reshaping module, and the low-dimensional features are converted into a two-dimensional image shape using the reshape operation.
[0071] The Bi-LSTM unit in the present invention includes a forward propagation layer and a backward propagation layer, which can learn the complex pattern of the gyroscope characteristic parameters changing over time, so as to make accurate predictions.
[0072] The preprocessed gyroscope characteristic parameters are passed through a forward propagation layer and a backward propagation layer respectively. The forward propagation layer starts from the starting position of the gyroscope characteristic parameter sequence and processes to the right one time step at a time to generate a series of forward hidden state sequences; the backward propagation layer starts from the end position of the gyroscope characteristic parameter sequence and processes to the left one time step at a time to generate a series of reverse hidden state sequences. Finally, for each time step, the forward hidden state sequence and the reverse hidden state sequence are summed to obtain the final hidden state representation, which also contains the contextual information of the gyroscope characteristic parameter sequence, so it can better understand the gyroscope characteristic parameter sequence data.
[0073] The LSTM consists of a series of fully connected layers, and its structure is as follows Figure 3 As shown, any function can be approximated by adjusting its parameters. Each layer consists of several basic neuron units, and the mathematical expression of the neuron is:
[0074] ;
[0075] In the formula, For input, is the output of the neuron, is the bias, is the learnable weight, (.) is a nonlinear activation function.
[0076] LSTM effectively solves the gradient vanishing and gradient exploding problems faced when processing long sequence data by setting up a gating mechanism, enabling it to learn the long-term dependencies between the characteristic parameters of the gyroscope, which is crucial for understanding the dynamics of the gyroscope. The core of LSTM lies in its cell state and gating mechanism. Its structure is as follows: Figure 3 As shown in the figure. The cell state plays the role of a conveyor belt, which runs through the entire time series and is responsible for the long-term transmission of information. For the prediction of gyroscope characteristic parameters, the cell state is like a memory bank, which stores key information about the historical operating state of the gyroscope, such as the changing trend of the standing wave angle, amplitude, phase and energy at past moments. In order to predict the gyroscope characteristic parameters at the next moment, LSTM needs to effectively manage these long-term memories. The gating mechanism is responsible for controlling the flow of information in the cell state, including three key parts: the forget gate, the input gate and the output gate.
[0077] The forget gate determines which past gyroscope characteristic parameter information in the unit state needs to be retained and which needs to be discarded. It receives the input of the gyroscope characteristic parameters at the current moment and the hidden state at the previous moment , through the Sigmoid activation function and Mapped to a value between 0 and 1, a value close to 0 means the information will be forgotten, and a value close to 1 means the information will be retained. The calculation formula is:
[0078] ;
[0079] In the formula, is the activation value of the forget gate, is the logistic activation function, is the weight matrix of the forget gate, is the bias term of the forget gate, is the hidden state at the previous time step, is the input for the current time step.
[0080] The input gate is responsible for controlling the input of the current gyroscope characteristic parameters How much information will be updated into the cell state. The input gate also receives the input of the current time step and the hidden state at the previous moment , an update ratio is calculated through the Sigmoid activation function and compared with the The current input processed by the activation function is multiplied to obtain the information that needs to be updated to the unit state. The calculation formula is as follows:
[0081] ;
[0082] ;
[0083] In the formula, is the activation value of the input gate, is the candidate memory cell state, and is the weight matrix and bias term of the input gate, and are the weight matrices and bias terms of the candidate memory cell states.
[0084] The unit state is updated according to the results of the forget gate and the input gate, thereby realizing long-term memory of the gyroscope state.
[0085] The output gate determines which gyro parameter feature information in the cell state will be output as the hidden state at the current moment. The output gate receives the gyro state input at the current moment, the hidden state at the previous moment, and the updated cell state, including the gyro state information of the previous time step and the context information learned by the model. It calculates an output ratio through the Sigmoid activation function and compares it with the output ratio after The unit state after the activation function is multiplied to obtain the hidden state at the current moment. The calculation formula is:
[0086] ;
[0087] ;
[0088] In the formula, and is the weight matrix and bias of the output gate, is the activation value of the output gate, is the updated memory cell state, It is the final hidden state output, which is used to predict the gyroscope characteristic parameters at the next moment.
[0089] The Transformer encoder relies entirely on the attention mechanism to capture dependencies in the sequence. Its structure is as follows Figure 4As shown. The Transformer model consists of two parts: an encoder and a decoder. However, in the prediction of the gyroscope characteristic parameter time series, the present invention only uses the encoder part to extract the features of the input sequence, which enables the Transformer model to be used as a Transformer encoder for feature extraction. The specific process of modeling in the Transformer encoder is as follows:
[0090] After the hidden state sequence output by the Bi-LSTM unit is input into the Transformer encoder, the embedding layer is first used to map each hidden state vector in the hidden state sequence to a high-dimensional vector space. The hidden state vector output by the Bi-LSTM unit is converted into a dense vector representation that can be processed by the Transformer encoder, making it easier for the model to learn the complex relationship between the gyroscope characteristic parameters.
[0091] Then, the temporal position information is added to the gyroscope characteristic parameter sequence through position encoding, because the self-attention mechanism itself does not perceive the position of the elements in the sequence. Position encoding ensures that the Transformer encoder can distinguish data at different time points and better capture the dynamic characteristics of the gyroscope characteristic parameters. Then it passes through a multi-head self-attention layer and a feedforward network layer, and uses residual connections and layer normalization; among them, the self-attention layer can parallelly calculate the dependencies between each gyroscope characteristic parameter in the sequence, and the feedforward network can learn the complex nonlinear relationship between the gyroscope characteristic parameters. This self-attention mechanism gives the Transformer encoder a powerful sequence modeling capability, enabling it to learn the complex nonlinear dependencies between the gyroscope characteristic parameters, and can capture the correlation between different time points, so as to better predict the future distribution of gyroscope characteristic parameters.
[0092] Then, at the output of the Transformer encoder, it is residually connected to the output of the Bi-LSTM unit, allowing the feature information to be directly passed to the deep network, retaining more original information, avoiding the loss of feature information in the intermediate process, better learning the fine-grained features in the data, improving the representation ability of the network, and improving prediction accuracy. Finally, the feature information after the residual connection is input to the fully connected layer, mapping the feature to a 256*256*C vector (C represents the number of channels), and then converted to an image using a reshape operation.
[0093] Step 3: Based on the data set of step 1, the gyroscopic vibration imaging model constructed in step 2 is trained and evaluated, and then the trained gyroscopic vibration imaging model is used to construct a gyroscopic resonator characterization distribution image.
[0094] During model training, supervised learning is used to train the gyroscopic modal imaging model on the training set. By adjusting the weights and bias of the Bi-LSTM strong encoder module, a nonlinear neural network model is established between the input and output of the gyroscopic modal imaging model; the nonlinear neural network generates prediction results through forward propagation, and the mean square error (MSE) loss function is used to minimize the difference between the predicted parameters and the true parameters. The relative image error IE and the relationship coefficient CC between the real oscillator representation distribution image and the reconstructed oscillator representation distribution image are used to evaluate the image quality and the performance of the reconstruction algorithm.
[0095] Among them, the process of model training using supervised learning is as follows:
[0096] In the data set construction part, the data set has been divided into training set, validation set and test set in a ratio of 7:1:2. The model training on the training set first extracts the features of the gyroscope characteristic parameter samples by the Bi-LSTM strong encoder module, effectively learning the complex dependencies between the gyroscope characteristic parameters; finally, the different gyroscope characteristic parameter variables are mapped to the pixel values of the image through the fully connected layer, and the resonator representation distribution on the pixels of the entire image is obtained. The output is reshaped into an image with a resolution of 256*256, achieving finer-grained gyroscope parameter feature distribution details. The Bi-LSTM strong encoder module establishes a nonlinear network model between the input and output of the gyroscope vibration imaging model by adjusting the weights and bias of each layer of LSTM. The nonlinear neural network generates prediction results through forward propagation, uses the mean square error (MSE) loss function to calculate the error between the prediction result and the true value, calculates the gradient of the error with respect to the neural network parameters through back propagation, and uses the stochastic gradient descent (SGD) optimizer to update the parameters of the neural network to reduce the loss.
[0097] A total of 500 training cycles were set during the training process. In order to prevent overfitting during the training process, 10% of the training samples were randomly selected for verification during each training iteration. The loss curves of training and verification are shown in Figure 2. Figure 5 As shown, the error between the predicted result and the true value is close to 0.10.
[0098] In order to quantify the performance of the model, the present invention uses two indicators, relative image error (IE) and relationship coefficient (CC), to evaluate the model. In the data set construction part, in order to intuitively reflect the operating status of the gyroscope, the curves of these characterization parameters changing over time are plotted, thereby obtaining a real resonator characterization distribution image. During the evaluation, the image quality is evaluated by the relative image error IE and relationship coefficient CC between the real resonator characterization distribution image and the reconstructed resonator characterization distribution image.
[0099] The calculation formula of relative image error IE is as follows:
[0100] ;
[0101] In the formula, represents the distribution image of the resonator characterization predicted by the gyroscopic vibration imaging model, Represents the distribution image of the real harmonic oscillator representation;
[0102] Relationship coefficient It is used to measure the similarity between the predicted oscillator representation distribution image and the real oscillator representation distribution image. The calculation formula is as follows:
[0103] ;
[0104] In the formula, for The average value of for is the average value, and N is the number of pixels in the imaging area.
[0105] In order to prove the effectiveness of the method of the present invention, an ablation experiment was carried out on the test set, and the average values of the relative IE and CC of the reconstructed images under different error parameters were calculated. As shown in Table 1, the IE and CC of the prediction results of only constructing the Bi-LSTM network are 0.1512 and 0.9416, respectively, while the IE and CC of combining Bi-LSTM with Transformer can reach 0.1403 and 0.9522, respectively. The relative image error is reduced by nearly 0.072, and the relationship coefficient is increased by nearly 0.011.
[0106] Table 1 Comparison of IE and CC prediction results of different networks
[0107]
[0108] The experimental results are visualized, and the effect is as follows Figure 6 As shown, the results prove that the method of the present invention can reconstruct an image that is very close to the actual dielectric constant distribution.
[0109] The embodiments of the present invention are only used to illustrate the technical solutions of the present invention rather than to limit the present invention. It can be understood by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention. The scope of the present invention is defined by the attached claims and their equivalents.
Claims
1. A gyroscopic vibration imaging method based on Bi-LSTM strong encoder, characterized in that: The following steps are included: Step 1: Obtain a real resonator characterization distribution diagram and gyroscope characteristic parameters that vary with time, construct a gyroscope characteristic parameter data set, and preprocess the data set; Gyroscope characteristic parameters include standing wave angle, amplitude, phase and energy; Step 2: Build a gyroscopic vibration imaging model based on Bi-LSTM strong encoder, which includes Bi-LSTM strong encoder module, fully connected layer and reshaping module; The Bi-LSTM strong encoder module includes a Bi-LSTM unit and a Transformer encoder; The processing process of the preprocessed data in the gyroscopic vibration imaging model is as follows: First, the preprocessed gyroscope characteristic parameters are passed through the Bi-LSTM unit to output a hidden state sequence. Then, the hidden state sequence is input into the Transformer encoder to extract the global features of the sequence, and the output of the Transformer encoder and the output of the Bi-LSTM unit are residually connected. After the residual connection, the different gyroscope characteristic parameter variables are mapped to the pixel values of the image through the fully connected layer to obtain the resonator representation distribution on the pixels of the entire image; Finally, the input is sent to the reshape module, where the low-dimensional features are converted into a two-dimensional image shape using a reshape operation; Step 3: Based on the data set of step 1, the gyroscopic vibration imaging model constructed in step 2 is trained and evaluated, and then the trained gyroscopic vibration imaging model is used to construct a gyroscopic resonator characterization distribution image.
2. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 1, characterized in that: In step 1, obtaining the distribution diagram and parameters of the actual resonator characterization of the gyroscope includes the following steps: Step 1.1, according to the gyroscope system, and considering the influence of micro-machining process accuracy, material properties on the system, and the damping cross-coupling and stiffness cross-coupling between the two gyroscope modes, a gyroscope model is established; Step 1.2, the two input ports of the gyroscope model are x-mode input and y-mode input, and the two output ports are x-mode output and y-mode output; The signals output from the two input ports are respectively picked up by their respective transimpedance amplifier circuits, and the charge in the gyro detection capacitor is extracted in the form of current, and converted into voltage and transmitted to the analog-to-digital converter. The analog-to-digital converter converts the picked-up vibration information from analog signals to digital signals, and transmits it to the field programmable logic gate array FPGA through a full-duplex serial peripheral interface protocol; In FPGA, multiple multipliers and low-pass filters are used to demodulate the in-phase and quadrature channels of the two modes, and the baseband signals obtained are , , and , For x modal believer, is the x-mode orthogonal channel, For the y mode, is the signal of the y-mode orthogonal channel; Baseband signal , , and The vibration energy E can be derived: ; By using the demodulation reference signal in the coherent demodulation , By adding a phase into the y-mode, the function of the phase modulator can be realized; after the y-mode phase is corrected by the phase modulator, the y-mode It can represent the angular rate output; and the x-mode , , it is necessary to perform phase and modulus length calculation in the CORDIC circuit of the FPGA to obtain the phase and amplitude of the x mode respectively for the phase-locked loop and automatic gain control; Under non-ideal conditions, it is impossible to achieve perfect agreement between damping and stiffness; therefore, the dynamic standing wave angle output solution of the full-angle mode gyro is for: ; In the formula, represents the damping error coefficient between the two modes, represents the resonant frequency difference between the two modes, represents the orthogonality error of the resonator, represents the vibration energy of the gyroscope resonator, represents the angle, represents the gyro angular rate gain, Represents the physical rotation angular rate about the z-axis.
3. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 2, characterized in that: The specific process of step 1.1 is as follows: First, the gyroscope system is simplified into a spring-damper-mass block model with two degrees of freedom. Considering the precision of the micromachining process and the influence of material properties on the system, the mathematical model is: ; ; In the formula, m represents the equivalent mass, x and y represent the displacements on the two axes respectively. and Represents the speed on the two axes respectively. and Represent the acceleration on the two axes, represents the damping of the x mode, represents the stiffness of the x mode, represents the damping of the y mode, represents the y-modal stiffness; and As the driving force to drive the two modes respectively, if there is an angular velocity input on the z-axis, and Represent the Coriolis force sensitivity items sensed in the x-mode and y-mode respectively, where is the angular gain factor, which is determined by the geometry of the gyro head and the vibration mode of the gyro effect; In actual situations, there is damping cross-coupling and stiffness cross-coupling between the two gyro modes. The mathematical model considering cross-coupling is expressed as: ; ; In the formula, = is the stiffness coupling coefficient term between the two modes, = is the damping coupling coefficient term between the two modes; Then, the Laplace transform is transformed into the complex frequency domain as follows: ; The following common quantities are defined: ; In the formula, is the physical rotation angular rate of the z-axis, is the resonant frequency of the x mode, is the resonant frequency of the y mode; and is the quality factor of the two modes; and represents the intermediate variable caused by stiffness cross-coupling; and Represents the intermediate variable caused by damping cross coupling; in actual axisymmetric gyroscopes there is a difference in resonant frequency , resonant frequency difference Used to reflect the degree of modal splitting.
4. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 1, characterized in that: In step 1, data preprocessing includes the following steps: (1) Data cleaning: processing abnormal values and repeated gyroscope characteristic parameter data; (2) Smoothing filtering: using moving average filtering to separate high-frequency and low-frequency information, suppress high-frequency noise, and retain low-frequency information; (3) Data normalization, scaling the data to the range of [-1, 1]; Then, the preprocessed data are arranged in time series. Each group of time series constitutes a sample. The sample contains the standing wave angle, amplitude, phase and energy that change with time. The final data set is a collection of gyroscope characteristic parameters of different time series. The preprocessed data is stored in CSV file format, where each row represents a time step and each column represents a characterization parameter; The preprocessed data set is then divided into training set, validation set and test set in a ratio of 7:1:
2. The training set is used for model learning, the validation set is used for selecting model hyperparameters and verifying model effects, and the test set is used to evaluate the generalization ability of the model on unseen data.
5. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 1, characterized in that: In step 2, the Bi-LSTM unit includes a forward propagation layer and a backward propagation layer; The preprocessed gyroscope characteristic parameters pass through a forward propagation layer and a backward propagation layer respectively. The forward propagation layer starts from the starting position of the gyroscope characteristic parameter sequence and processes to the right time step by time step to generate a series of forward hidden state sequences; the backward propagation layer starts from the end position of the gyroscope characteristic parameter sequence and processes to the left time step by time step to generate a series of reverse hidden state sequences; finally, for each time step, the forward hidden state sequence and the reverse hidden state sequence are summed to obtain the hidden state sequence.
6. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 5, characterized in that: Both the forward propagation layer and the back propagation layer contain several LSTMs, each of which contains a cell state and a gating mechanism; The unit state runs through the entire time series, is responsible for the long-term transmission of information, and stores the historical operating status information of the gyroscope; Gating mechanisms are used to control the flow of information within a cell state.
7. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 6, characterized in that: The gating mechanism includes forget gate, input gate and output gate; The forget gate is used to determine whether to retain or forget the past gyroscope characteristic parameter information in the unit state; The input gate is used to control the input of the gyroscope characteristic parameters at the current moment How much information will be updated into the cell state? The output gate is used to determine which gyroscope characteristic parameter feature information in the unit state will be output as the hidden state at the current moment.
8. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 1, characterized in that: In step 2, the specific process of modeling in the Transformer encoder is as follows: After the hidden state sequence output by the Bi-LSTM unit is input into the Transformer encoder, the embedding layer is first used to map each hidden state vector in the hidden state sequence to a high-dimensional vector space, converting the hidden state vector into a dense vector representation that can be processed by the Transformer encoder; Then, the temporal position information is added to the gyroscope characteristic parameter sequence through position encoding. Position encoding ensures that the Transformer encoder can distinguish data at different time points. Then it passes through a multi-head self-attention layer and a feedforward network layer, and uses residual connections and layer normalization. Among them, the self-attention layer can parallelly calculate the dependencies between the characteristic parameters of each gyroscope in the sequence, and the feedforward network can learn the complex nonlinear relationship between the characteristic parameters of the gyroscope.
9. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 4, characterized in that: In step 3, the gyroscopic vibration imaging model is trained on the training set using supervised learning. The training process is as follows: By adjusting the weights and bias of the Bi-LSTM strong encoder module, a nonlinear neural network model is established between the input and output of the gyroscopic vibration imaging model. The nonlinear neural network generates prediction results through forward propagation, and uses the mean square error loss function to calculate the error between the prediction result and the true value; the gradient of the error with respect to the neural network parameters is calculated through back propagation, and the parameters of the neural network are updated using the stochastic gradient descent optimizer to reduce the loss; During the training of the gyroscopic imaging model, multiple training cycles were set. In order to prevent overfitting in the training process, 10% of the training set samples were randomly selected for verification during each training iteration.
10. The gyroscopic vibration imaging method based on Bi-LSTM strong encoder according to claim 1, characterized in that: In step 3, the relative image error between the real resonator representation distribution image and the predicted resonator representation distribution image is calculated. and the relationship coefficient , to evaluate the gyroscopic modal imaging model; The calculation formula of relative image error IE is as follows: ; In the formula, represents the distribution image of the resonator characterization predicted by the gyroscopic vibration imaging model, Represents the distribution image of the real harmonic oscillator representation; Relationship coefficient It is used to measure the similarity between the predicted oscillator representation distribution image and the real oscillator representation distribution image. The calculation formula is as follows: ; In the formula, for The average value of for is the average value, and N is the number of pixels in the imaging area.
Citation Information
Patent Citations
Scanning galvanometer control system for area array infrared wide-area imaging
CN109060146A
Wind speed prediction method based on variational mode decomposition and attention mechanism
CN114218870A