Next Article in Journal
An Open-Source Test Environment for Effective Development of MARG-Based Algorithms
Next Article in Special Issue
Design and Optimization of a Pressure Sensor Based on Serpentine-Shaped Graphene Piezoresistors for Measuring Low Pressure
Previous Article in Journal
Feasibility of Mobile Laser Scanning towards Operational Accurate Road Rut Depth Measurements
Previous Article in Special Issue
Criterion Validity of Catapult ClearSky T6 Local Positioning System for Measuring Inter-Unit Distance
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Combined Method for MEMS Gyroscope Error Compensation Using a Long Short-Term Memory Network and Kalman Filter in Random Vibration Environments

1
Changchun Institute of Optics, Fine Mechanics and Physics, Chinese Academy of Sciences, Changchun 130033, China
2
University of Chinese Academy of Sciences, Beijing 100049, China
3
Key Laboratory of Airborne Optical Imaging and Measurement, Changchun Institute of Optics, Fine Mechanics and Physics, Chinese Academy of Sciences, Changchun 130033, China
*
Author to whom correspondence should be addressed.
Submission received: 2 January 2021 / Revised: 1 February 2021 / Accepted: 4 February 2021 / Published: 8 February 2021
(This article belongs to the Collection Modeling, Testing and Reliability Issues in MEMS Engineering)

Abstract

:
In applications such as carrier attitude control and mobile device navigation, a micro-electro-mechanical-system (MEMS) gyroscope will inevitably be affected by random vibration, which significantly affects the performance of the MEMS gyroscope. In order to solve the degradation of MEMS gyroscope performance in random vibration environments, in this paper, a combined method of a long short-term memory (LSTM) network and Kalman filter (KF) is proposed for error compensation, where Kalman filter parameters are iteratively optimized using the Kalman smoother and expectation-maximization (EM) algorithm. In order to verify the effectiveness of the proposed method, we performed a linear random vibration test to acquire MEMS gyroscope data. Subsequently, an analysis of the effects of input data step size and network topology on gyroscope error compensation performance is presented. Furthermore, the autoregressive moving average-Kalman filter (ARMA-KF) model, which is commonly used in gyroscope error compensation, was also combined with the LSTM network as a comparison method. The results show that, for the x-axis data, the proposed combined method reduces the standard deviation (STD) by 51.58% and 31.92% compared to the bidirectional LSTM (BiLSTM) network, and EM-KF method, respectively. For the z-axis data, the proposed combined method reduces the standard deviation by 29.19% and 12.75% compared to the BiLSTM network and EM-KF method, respectively. Furthermore, for x-axis data and z-axis data, the proposed combined method reduces the standard deviation by 46.54% and 22.30% compared to the BiLSTM-ARMA-KF method, respectively, and the output is smoother, proving the effectiveness of the proposed method.

1. Introduction

Fiber optic gyroscopes and laser gyroscopes have excellent performance, but they are too large and expensive for portable devices [1,2]. Micro-electro-mechanical-system (MEMS) gyroscopes have, in recent years, been used in low-cost inertial navigation systems (INS) due to their small size and low cost. However, the MEMS gyroscope has a significant error due to the manufacturing technology and structural composition [3,4]. The error of the MEMS gyroscope can be divided into deterministic error and random error. The deterministic error mainly refers to perturbation errors such as zero offsets and the scale factor, which can be corrected by a calibration test [5,6]. Random error refers to the random drift caused by uncertain factors, usually determined by the device’s accuracy level [7], with no precise repeatability. Therefore, it is difficult to accurately compensate for random error, which hinders the further improvement of MEMS gyroscope performance.
In MEMS gyroscope error compensation research, the MEMS gyroscope data are generally treated as time-series data. Scholars have proposed methods such as the autoregressive moving average (ARMA) model, the Allan variance (AV), the wavelet threshold (WT), the support vector machine (SVM), and the artificial neural network (ANN), and all of them have achieved excellent results [7,8,9,10,11,12,13,14]. Recently, various variants of the recurrent neural network (RNN), which has strong processing power for time-series data, have been shown to be superior to traditional methods in the research of error compensation in MEMS gyroscopes [15,16,17,18].
However, most of the research mentioned above has acquired data by placing the MEMS gyroscope in a static environment. In practical applications of the MEMS gyroscope, it is inevitably that it is affected by random vibration [19]. In random vibration environments, the MEMS gyroscope is interfered with by both internal device noise and external vibration noise [20], which dramatically affects the performance of the MEMS gyroscope. The degradation of performance in vibrating environments is a fatal problem for MEMS gyroscopes [21,22], so it is essential to research error compensation methods in random vibration environments.
Most of the current research on improving the performance of the MEMS gyroscope in random vibration environments is to fix the MEMS gyroscope on a vibration isolation platform [23,24,25]. However, this kind of method is not universal [26]. There is not much research based on time-series models—the windowed measurement error covariance (WMEC) method has been applied to compensate for the effects of the vibration environments [27], singular spectrum analysis (SSA) was proposed to remove the low-frequency vibration noise perturbations of MEMS accelerometers [28], and the third-order autoregressive (AR) model was used to estimate the Kalman filter to compensate for the MEMS gyroscope’s attitude angle error caused by random vibration [29].
Considering the dramatic perturbation of the MEMS gyroscope in random vibration environments, in this paper, a combined method of a long short-term memory (LSTM) network and Kalman filter is proposed for error compensation, with the Kalman smoother and expectation-maximization (EM) algorithm to dynamically adjust the predicted values of the LSTM network to improve the performance in error compensation. The main contributions of this paper are as follows:
(1)
The combination of LSTM network and Kalman filter is applied to MEMS gyroscope error compensation in random vibration environments;
(2)
The proper input data step and the network topology are explored, and the error compensation performance of the bidirectional LSTM (BiLSTM) network and other recurrent neural network (RNN) variants are compared;
(3)
In designing the Kalman filter, the EM algorithm is used to estimate the parameters. It is compared with the ARMA model, a parameter estimation method commonly used in research of the MEMS gyroscope error compensation problem.
The remainder of this paper is organized as follows: (1) Section 2 introduces the methods, including BiLSTM network, Kalman filter, ARMA-KF model, and EM-KF model, and gives the illustration of this paper proposed method; (2) Section 3 presents the experiment, results, and comparisons; and (3) the remaining sections are the conclusion, appendix, and references.

2. Method

2.1. Multi-Layer BiLSTM Network and Kalman Filter

The long short-term memory network is a variant of the recurrent neural network used to solve the gradient vanishing or gradient explosion problem of RNNs [30,31]. A detailed description of LSTM units can be found in references [15,16,17,18].
The basic LSTM network only considers the historical and current inputs and ignores future inputs [32]. Therefore, the LSTM network can perform the reverse operation, superimpose the forward and reverse information flows, and fully utilize the front and back inputs at the current time to improve the error compensation performance. In addition, the previous hidden layer’s output is used as the input of the following layer to explore the more in-depth features of the time-series data, thus enhancing the model’s nonlinear fitting ability. The multi-layer BiLSTM network information flow is shown in Figure 1.
The cell state of the Layer n BiLSTM network at time t can be presented as:
[ i t ( n ) f t ( n ) o t ( n ) c ˜ t ( n ) ] = [ σ σ σ t a n h ]   [ W i , x ( n ) W i , h ( n ) W f , x ( n ) W f , h ( n ) W o , x ( n ) W o , h ( n ) W c ˜ , x ( n ) W c ˜ , h ( n ) ]   [ h t ( n 1 ) h t ( n ) ]
where h t ( n 1 ) is the hidden state of the Layer n 1 at time t . Each hidden state is composed of forward and reverse superposition. The related equations are denoted as follows:
h t ( n ) = h t ( n ) h t ( n )
The Kalman filter is an optimal state estimation method that can be applied to dynamic systems with random disturbances. It estimates the system state based on discrete measurement that contain noise [33,34]. Suppose the state–space model is built as:
x ^ k = Φ x ^ k 1 + Γ ω k 1
y k = H x k + v k
where Φ is the system state transition matrix, Γ is the system noise-driven matrix, H is the measurement matrix, x ^ k is the system state vector, y k is the measurement vector, ω k is the system noise vector, and v k is the measurement noise vector.
The noise of the system models and measurement models are assumed to have normal distribution in the Kalman filter, such that [35]:
ω k N ( 0 , Q )
v k N ( 0 , R )
where Q is the covariance matrix of the system models and R is the covariance matrix of measurement models.
The Kalman filter is composed of two-stage optimization. In the predicted stage, the current system state vector is predicted based on the system state vector at the previous time, such that:
x ^ k / k 1 = Φ x ^ k 1
P k / k 1 = Φ P k 1 Φ T + Γ Q Γ T
where x ^ k / k 1 is the predicted value of the system state vector and P k / k 1 is the predicted covariance matrix of the system state vector.
In the updated stage of the Kalman filter, the current system state vector is updated by using the measurement vector, such that:
K k = P k / k 1 H T ( H P k / k 1 H T + R ) 1
x ^ k = x ^ k / k 1 + K k ( y k H x ^ k / k 1 )
P k = ( I K k H ) P k / k 1
where K k is the Kalman filter gain matrix and P k is the updated covariance matrix of the system state vector.

2.2. Kalman Filter Design with ARMA Model

The autoregressive moving average model is the most widespread model used in time-series analysis, and it is derived and developed on the basis of the linear regression model. The ARMA model can be described as [36]:
x t = i = 1 p φ i x t i j = 1 q θ j ε t j + ε t ,   ε t N ( 0 , δ ε 2 )
where p and q are the order of the ARMA model; φ i and θ j are coefficients that satisfy stationary and invertible conditions, respectively [37]; and   ε t is white noise, which is an uncorrelated random variable with mean zero and constant variance. The model expresses that the measured values of the stochastic process { x t } at time t are correlated with the previous p measurements and the previous q white noise.
The steps to design a Kalman filter using the ARMA model as follows: (1) test the stationarity and normality of the measurement data, (2) determine the model type according to the autocorrelation function and partial autocorrelation function, (3) determine the order and parameters of the model according to the Akaike information criterion (AIC) [38], and (4) perform adaptive testing of the designed model.

2.3. Kalman Filter Design with EM Algorithm

The expectation-maximization algorithm is an iterative method proposed by Shumway and Stoffer to compute maximum likelihood estimates based on incomplete data [39]. It is convergent and can identify parameters and states in the model [40]. Andrieu and Doucet introduced the EM algorithm for parameter estimation for linear state–space models was introduced [41]. The EM algorithm is an iterative numerical algorithm for computing the maximum likelihood estimation (MLE). The linear Gaussian state–space model used for the EM algorithm can be expressed as follows [42]:
x k = Φ x k 1 + ω k 1
y k = H x k + υ k
The conditional probability densities of the state equation and the measurement equation are obtained from Equations (13) and (14), respectively:
p ( x k | x k 1 ) = exp { 1 2 [ x k Φ x k 1 ] T Q 1 [ x k Φ x k 1 ] } ( 2 π ) n 2 | Q | 1 2
p ( y k | x k ) = exp { 1 2 [ y k H x k ] T R 1 [ y k H x k ] } ( 2 π ) m 2 | R | 1 2
It is assumed that the likelihood of the system state data and the evolution of the states is Gaussian, which are defined by the following equations [43]:
p ( Y , X | Θ ) = p ( x 1 ) k = 1 N p ( y k | x k ) k = 2 N p ( x k | x k 1 )
where Y is the measurement data, X is the unknown system state data, and Θ is the parameter set of linear Gaussian state–space model. Θ can be represented as follows:
Θ = { Φ , H , Q , R }
By taking the log of the likelihood we arrive at the following formula:
ln p ( Y , X | Θ ) = 1 2 k = 2 N { ln | Q | + [ x k Φ x k 1 ] T Q 1 [ x k Φ x k 1 ] } 1 2 k = 1 N { ln | R | + [ y k H x k ] T R 1 [ y k H x k ] }
Depending on the maximum likelihood method, the linear Gaussian state–space model can be identified through an EM algorithm [42]. The algorithm alternates between two steps—the E-step (expectation) and the M-step (maximization) [44]. In general, the likelihood density function based on the measurement data, denoted by p ( Θ | Y ) , is called the posterior distribution of the measurement. The EM algorithm aims to compute the maximum likelihood estimation of p ( Θ | Y ) . Θ i is denoted as the estimate of the likelihood function at the beginning of the i th iteration.
In the E-step, the expectation for the conditional distribution of ln p ( Y , X | Θ ) concerning X , is calculated such that:
Ω ( Θ | Θ i , Y ) E X { ln p ( Θ | Y , X ) | Θ i , Y } = [ ln p ( Θ | Y , X ) ] ( X | Θ i , Y ) d X
In the M-step, Ω ( Θ | Θ i , Y ) is maximized to find Θ i + 1 such that:
Ω ( Θ i + 1 | Θ i , Y ) = a r g max Θ [ Ω ( Θ | Θ i , Y ) ]
The E-step and the M-step are iterated until,
L ( Θ i + 1 ) L ( Θ i ) < τ
where τ is the predefined threshold. Equation (22) means that it has satisfied the convergence criterion. The specific process of designing a Kalman filter using the EM algorithm is given as follows:
The value of Ω ( Θ | Θ i , Y ) is determined by the following [45]:
E X ( x k | Y ) = x ^ k | N
E X ( x k x k 1 T | Y ) = P k , k 1 | N + x ^ k | N x ^ k 1 | N T
E X ( x k x k T | Y ) = P k | N + x ^ k | N x ^ k | N T
where x ^ k | N is the smoothed value of the system state vector and P k | N is the smoothed covariance matrix of the system state vector. P k , k 1 | N is initialized by:
P k , k 1 | k = ( I K k H ) Φ P k 1
P k , k 1 | N = P k , k 1 | k + [ P k | N P k ] P k | k 1 P k , k 1 | k
x ^ k | N and P k | N can be obtained by smoothing the outputs of Kalman filter using backward-pass methods such as the Rauch–Tung–Striebel (RTS) smoother [46]. This method is summarized in the following equations:
J k 1 = P k 1 Φ T P k | k 1 1
x ^ k 1 | N = x ^ k 1 + J k 1 ( x ^ k | N x ^ k / k 1 )
P k 1 | N = P k 1 J k 1 ( P k | N P k | k 1 ) J k 1 T
Then, the model parameters are re-estimated by maximizing the Ω ( Θ | Θ i , Y ) over Θ using partial derivatives of Ω ( Θ | Θ i , Y ) and setting them to zero. Solving these equations yields the updated parameters (in the i th iteration) as follows:
L ( Θ ) Φ = k = 2 N Q 1 ( P k , k 1 | N + x ^ k | N x ^ k | N T ) + k = 2 N Q 1 Φ ( P k 1 | N + x ^ k 1 | N x ^ k 1 | N T ) = 0
Φ i + 1 = ( k = 2 N P k , k 1 | N + x ^ k | N x ^ k | N T ) ( k = 2 N P k 1 | N + x ^ k 1 | N x ^ k 1 | N T ) 1
L ( Θ ) H = k = 1 N R 1 y k x ^ k | N T + k = 1 N R 1 H ( P k | N + x ^ k | N x ^ k | N T ) = 0
H i + 1 = ( k = 1 N y k x ^ k | N T ) [ k = 1 N ( P k | N + x ^ k | N x ^ k | N T ) ] 1
L ( Θ ) Q 1 = N 2 Q 1 2 k = 1 N ( P k | N + x ^ k | N x ^ k | N T ) + Φ [ 1 N k = 2 N ( P k , k 1 | N + x ^ k | N x ^ k 1 | N T ) ] = 0
Q i + 1 = 1 N ( k = 1 N ( P k | N + x ^ k | N x ^ k | N T ) Φ i + 1 k = 2 N ( P k , k 1 | N + x ^ k | N x ^ k 1 | N T ) )
L ( Θ ) R 1 = N + 1 2 R k = 1 N ( 1 2 y k y k T H x ^ k | N y k T + 1 2 H ( P k | N + x ^ k | N x ^ k | N T ) H T ) = 0
R i + 1 = 1 N + 1 ( k = 1 N y k y k T ) H i + 1 ( 1 N + 1 k = 1 N y k x ^ k | N ) T
In this paper, based on the EM algorithm, the proposed LSTM and Kalman filter combination method is illustrated in Figure 2.

3. Experiments and Results

In this section, the designed experiments and the analysis of the results are presented to verify the effectiveness of the proposed method.

3.1. Data Acquisition

The MSI320H MEMS Inertial Measurement Unit (IMU) was employed for experiments. This consists of a three-axis MEMS gyroscope and a three-axis MEMS accelerometer. The real picture and the gyroscope specifications of MSI320H are shown in Figure 3a and Table 1, respectively. The MSI320H was fixed on the vibration table. A picture of the vibration table is shown in Figure 3b. The data acquisition procedure of the MSI320H is shown in Figure 3c. Data from the MSI320H was sent to the xPC via the RS422 communication interface with a Baud of 921,600 bps. The xPC decoded the gyroscope data and sent it to the host computer via the network cable. The MSI320H was preheated at room temperature with power for 20 minutes. Then, linear vibration experiments were performed. The vibration direction of the vibration table is the y-axis of the gyroscope, and the power spectral density (PSD) of the linear random vibration loads is shown in Figure 3d.
As illustrated in Figure 3d, the acceleration of the applied vibration loads can be expressed as follows:
a v ( t ) = ξ v sin ( ω v t ) ,   ω v [ 20 · 2 π , 2000 · 2 π ]
where ξ v = 6 g. The sample rate was set to 200 Hz, and approximately 60,000 data were acquired in the random vibration environment. The variation of gyroscope x-axis signal affected by random vibration is shown in Figure 4, and the error of the gyroscope increased significantly in random vibration environments.

3.2. Comparison of BiLSTM and Other RNN Variants

The outliers of the acquired data in random vibration environments were eliminated using the Puata criterion [47]. Because the linear random vibration test’s direction was the y-axis of the gyroscope, the x-axis and z-axis directions were in a random vibration environment. For the consideration of model generality, we took the last 80% of the processed x-axis data as the training set and the first 20% of the x-axis and z-axis data were used as the testing set.
If the hidden layer structure of the designed network is too simple, it is not easy to characterize the time-series model of gyroscope data. Conversely, it increases the complexity of the network, reduces the learning speed of the network, and tends to fall into local minima during the learning process. With the above considerations, in this paper, the proposed BiLSTM network is shown in Figure 5. The dense layer transformed the high-dimensional stacked sequence of the hidden layer into an output sequence with the same shape as the input sequence. Moreover, considering a large number of network parameters, dropout was set in the dense layer to prevent the overfitting phenomenon [48].
The adaptive moment estimation (Adam) optimization algorithm was used to update the network parameters [49]. The Adam algorithm uses default parameters. The activation function of the Dense layer is rectified linear unit (ReLU). The specifications used for network training are illustrated in Table 2. Moreover, the root mean square error (RMSE) was used as the loss function. The network training was performed on Tensorflow 2.0.0 and Keras 2.3.1 over the Ubuntu 16.04-LTS-x86 64 operating system. The heterogeneous computing platform was equipped with Intel Xeon E5-1620 and GeForce RTX-2080Ti GPUs.
In order to verify the performance of BiLSTM for gyroscope error compensation in random vibration environments, proper values for the input data step size, the number of hidden units, and the number of hidden layers was first explored using the x-axis testing set. Subsequently, training was performed using the identified values. The BiLSTM network results were compared with the LSTM network, gated recurrent unit (GRU) network, and bidirectional GRU (BiGRU) network using the x-axis and z-axis testing sets, respectively.
As shown in Table 3, Table 4 and Table 5, when the input data step size and the number of hidden layers are more extensive, the training time per epoch will be longer. So we needed to make a trade-off between the results and the computational performance. According to the results, the best results were obtained when taking the input data step of 20, the number of hidden units of 128, and the number of hidden layers of 10. Although it does not indicate that this is the optimal parameter for the network, it will be the proper value to be obtained considering the computational resources.
The results are shown in Figure 6 and Figure 7 and Table 6 and Table 7. Figure 6 shows the training loss within 50 epochs, and convergence was achieved for all networks. Table 6 and Table 7 show that the standard deviations of the BiLSTM network results for the x-axis and z-axis were reduced by 46.81% and 43.63%, respectively, compared to the raw data, proving that the BiLSTM network is feasible for the application in the research of MEMS gyroscope error compensation. Furthermore, compared with the results of the LSTM network, the BiGRU network, and the GRU network, the standard deviation values of BiLSTM results in the x-axis were reduced by 14.06%, 11.66%, and 17.33%, respectively, and the standard deviation values of BiLSTM results in the z-axis were reduced by 12.71%, 10.04%, and 14.04%, respectively. This indicates that the error compensation performance of the BiLSTM network is better than these three networks.

3.3. Comparison of LSTM-EM-KF and LSTM-ARMA-KF

In this section, the raw data and BiLSTM network results of the x-axis and z-axis are used as the measurement, respectively. The Kalman filter parameters are estimated by the ARMA model and EM algorithm, and the filter results are compared.

3.3.1. Estimating Kalman Filter Parameters Using the ARMA Model

When modeling time-series data using the ARMA model, the time-series data must meet stationarity and normality requirements. Therefore, a polynomial fitting method was used to eliminate the trend term before modeling. In this paper, the stationarity was tested using the run test, and the normality was tested by calculating the skewness, ξ , and the kurtosis, υ .
According to the test, after eliminating the trend term, the raw data and BiLSTM network results of the x-axis and z-axis met the stationarity and normality requirements. The test process is shown in Appendix A. Moreover, as illustrated in Figure A1, the autocorrelation function and partial autocorrelation function diagrams exhibit trailing properties, and all models can be identified as an ARMA ( p , q ) model.
The next step is to determine the order of the model. If the order is increased, the identified model will be more realistic, but the computational difficulty will also increase as the order increases. Therefore, the maximum order was set to 3, which means the maximum value of p and q was set to 3. Furthermore, the Akaike information criterion (AIC) was used for determining model order. Determining the model order process and the Durbin–Watson test results are shown in Appendix B.
For x-axis raw data, the model identified is identified as ARMA(3,3):
x n = 0.3126 x n 1 + 0.8168 x n 2 + 0.1520 x n 3 + ε n + 0.6885 ε n 1 0.3241 ε n 2 0.0366 ε n 3
For x-axis BiLSTM network results, the model is identified as ARMA(3,3):
x n = 0.8505 x n 1 + 0.8891 x n 2 0.7745 x n 3 + ε n + 0.1354 ε n 1 0.8476 ε n 2 0.0815 ε n 3
For z-axis raw data, the model identified is identified as ARMA(1,3):
x n = 0.8593 x n 1 + ε n 0.51915 ε n 1 + 0.0328 ε n 2 0.0236 ε n 3
For z-axis BiLSTM network results, the model identified is identified as ARMA(3,3):
x n = 2.0000 x n 1 1.2268 x n 2 + 0.2031 x n 3 + ε n 1.0446 ε n 1 0.0809 ε n 2 0.1086 ε n 3
where x n is the output of the ARMA model, ε n is the driving white noise (with mean, 0, and variance, δ ^ ε 2 ). The Kalman filter parameters are presented in Table 8. The value of R is the variance of the measurement. The initial value of the Kalman filter is set as follows: x 1 = [ 0 ; 0 ; 0 ; 0 ] , and P 1 is the fourth-order identity matrix.

3.3.2. Estimating Kalman Filter Parameters Using the EM Algorithm

When using the EM algorithm to estimate the Kalman filter parameters, only the iteration convergence conditions and initial parameters need to be set. The M-step convergence constant τ in Equation (22) was set to 0.1. The Kalman filter’s initial values were set to x 1 = 0   and   P 1 = 1 , and the Kalman filter’s initial parameters were set to Φ 1 = 1 , H 1 = 1 , Q 1 = 1 , and R 1 = 1 . The change of the log-likelihood function during the iteration of the EM algorithm is shown in Figure 8. The parameter estimation results are presented in Table 9.

3.3.3. Kalman Filtering Results

The results are illustrated in Table 10 and Table 11. For the x-axis data, the standard deviation of the BiLSTM-EM-KF results was reduced by 51.58% and 31.92% compared to the BiLSTM network and EM-KF, respectively. For the z-axis data, the standard deviation of the BiLSTM-EM-KF results was reduced by 29.19% and 12.75% compared to the BiLSTM network and EM-KF, respectively. Therefore, the combined method proposed in this paper can be demonstrated to improve the gyroscope error compensation performance of the BiLSTM network and EM algorithm. Moreover, compared with BiLSTM-ARMA-KF results, the standard deviation of the BiLSTM-EM-KF was reduced by 46.54% and 22.30% in x-axis and z-axis, respectively. It indicates the proposed method’s superior performance to that of BiLSTM-ARMA-KF. Furthermore, according to Figure 9, the curves of BiLSTM-EM-KF results are smoother, which proves that the proposed combined method is effective.

4. Conclusions

In this paper, a combined method of an LSTM network and Kalman filter is proposed for MEMS gyroscope error compensation in random vibration environments. Through the results, the following conclusions were obtained:
(1)
After exploring proper input data step size and network topology, the network was trained, and the test results showed that the BiLSTM network outperformed the LSTM network, the GRU network, and the BiGRU network in gyroscope error compensation;
(2)
Combining the BiLSTM network with the EM-KF method can improve their gyroscopic error compensation performance;
(3)
In the classical gyroscope error compensation method, the ARMA-KF method, tedious data testing and model checking are required. In contrast, the EM-KF method only needs to set the initial parameters and the convergence value, which is much easier to apply. Moreover, the ARMA-KF method parameters cannot be updated through the filtering process, which means that satisfactory results cannot be obtained if the parameters are not defined correctly before the filtering process. From the filtering results, compared with BiLSTM-ARMA-KF, the standard deviation of the BiLSTM-EM-KF results were 46.54% and 22.30% lower, in x-axis and z-axis, and the output curve was smoother, which proves the effectiveness of the proposed method in this paper.
Future work should include conducting dynamic field experiments to obtain MEMS gyroscope outputs, as well as combining neural networks with more state-of-the-art Kalman filter methods for MEMS gyroscope error compensation and using fiber optic gyroscopes or laser gyroscopes as benchmarks for comparison.

Author Contributions

Conceptualization, C.Z. and H.C.; methodology, C.Z., S.C. and W.X.; software, C.Z. and Y.Y.; validation, S.C. and H.S.; formal analysis, C.Z. and S.C.; investigation, H.C. and W.X.; resources, S.C. and W.X.; data curation, C.Z.; writing—original draft preparation, C.Z.; writing—review and editing, C.Z.; visualization, C.Z.; supervision, S.C.; project administration, H.S.; funding acquisition, W.X. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the Natural Science Foundation of Jilin Province, China, grant number 20200201170JC.

Conflicts of Interest

The authors declare no conflict of interest.

Appendix A. Stationarity and Normality Tests

For stationarity, the most common test method is the run test. It was divided equally into 20 groups { X 1 ,   X 2 , , X 20 } , and the mean square value of each group was σ i where i [ 1 , 20 ] . The mean of { σ i } was σ m e a n , and the difference between each σ i and σ m e a n formed { σ a i } :
σ a i = σ i σ m e a n
The total number of positive values in { σ a i } was recorded as n 1 , and the total number of negative values in { σ a i } was recorded as n 2 . The number of positive and negative alternations in order and plus 1 more was the Run r . According to the run test table, whether r was within the confidence interval was determined at the significance level α = 0.05 .
After eliminating the trend term, the raw data and BiLSTM network results of the x-axis and z-axis met the stationarity requirements. The test process is presented in Table A1, Table A2, Table A3 and Table A4.
Table A1. Run test process of x-axis raw data.
Table A1. Run test process of x-axis raw data.
σ m e a n = 0.0604 , n 1 = 8 , n 2 = 12 , r = 14 , Significance Level α = 0.05 , Confidence Interval [ 6 , 16 ] .
X 1 X 2 X 3 X 4 X 5 X 6 X 7 X 8 X 9 X 10
σ i 0.06150.05830.05160.06210.06640.05720.06400.05450.05710.0628
σ a i 0.0011−0.0021−0.00880.00170.0060−0.00320.0036−0.0059−0.00330.0024
r12 3 456 7
X 11 X 12 X 13 X 14 X 15 X 16 X 17 X 18 X 19 X 20
σ i 0.06010.06020.05650.07430.05850.06550.05320.06930.05880.0557
σ a i −0.0003−0.0002−0.00390.0139−0.00190.0051−0.00720.0089−0.0016−0.0047
r 8 91011121314
Table A2. Run test process of x-axis BiLSTM network results.
Table A2. Run test process of x-axis BiLSTM network results.
σ m e a n = 0.0175 , n 1 = 11 , n 2 = 9 , r = 14 , Significance Level α = 0.05 , Confidence Interval [ 6 , 16 ] .
X 1 X 2 X 3 X 4 X 5 X 6 X 7 X 8 X 9 X 10
σ i 0.01890.01770.01440.01920.01980.01630.01910.01540.01590.0192
σ a i 0.00140.0002−0.00310.00170.0023−0.00120.0016−0.0022−0.00160.0017
r1 23 456 7
X 11 X 12 X 13 X 14 X 15 X 16 X 17 X 18 X 19 X 20
σ i 0.01760.01780.01590.02240.01490.01910.01440.02050.01660.0150
σ a i 0.00010.0003−0.00160.0049−0.00260.0016−0.00310.0030−0.0009−0.0025
r 891011121314
Table A3. Run test process of z-axis raw data.
Table A3. Run test process of z-axis raw data.
σ m e a n = 0.0596 , n 1 = 10 , n 2 = 10 , r = 10 , Significance Level α = 0.05 , Confidence Interval [ 6 , 16 ] .
X 1 X 2 X 3 X 4 X 5 X 6 X 7 X 8 X 9 X 10
σ i 0.06730.05650.06390.06940.06110.05700.04890.05330.05560.0539
σ a i 0.0077−0.00310.00430.00980.0015−0.0026−0.0107−0.0063−0.0040−0.0057
r123 4
X 11 X 12 X 13 X 14 X 15 X 16 X 17 X 18 X 19 X 20
σ i 0.05770.06710.06420.06450.05850.06190.05160.06220.06200.0560
σ a i −0.00190.00750.00460.0049−0.00110.0023−0.00800.00260.0024−0.0036
r 5 6789 10
Table A4. Run test process of z-axis BiLSTM network results.
Table A4. Run test process of z-axis BiLSTM network results.
σ m e a n = 0.0183 , n 1 = 9 , n 2 = 11 , r = 10 , Significance Level α = 0.05 , Confidence Interval [ 6 , 16 ] .
X 1 X 2 X 3 X 4 X 5 X 6 X 7 X 8 X 9 X 10
σ i 0.02160.01590.02000.02270.01800.01680.01390.01600.01580.0158
σ a i 0.0033−0.00240.00170.0044−0.0003−0.0015−0.0044−0.0023−0.0025−0.0025
r123 4
X 11 X 12 X 13 X 14 X 15 X 16 X 17 X 18 X 19 X 20
σ i 0.01730.02170.02130.02080.01750.01970.01540.01990.01910.0162
σ a i −0.00100.00340.00300.0025−0.00080.0014−0.00290.00160.0008−0.0021
r 5 6789 10
For normality, the most common test method is calculating skewness, ξ , and kurtosis, υ . When the calculated ξ is close to 0, and υ is close to 3, the data are considered to satisfy normality. For the valuation of ξ and υ:
ξ = E [ ( x N e x σ x ) 3 ] = E [ ( x N e x ) 3 ] { E [ ( x N e x ) 2 ] } 3 2 = 1 N n = 1 N ( x N e x ) 3 [ 1 N n = 1 N ( x N e x ) 2 ] 3 2
υ = E [ ( x N e x σ x ) 4 ] = E [ ( x N e x ) 4 ] { E [ ( x N e x ) 2 ] } 2 = 1 N n = 1 N ( x N e x ) 4 [ 1 N n = 1 N ( x N e x ) 2 ] 2
where e x and σ x are the mean and standard deviation of the data, respectively.
After eliminating the trend term, the raw data and BiLSTM network results of the x-axis and z-axis met the normality requirements. The results are presented in Table A5.
Table A5. The normality test results.
Table A5. The normality test results.
x-axis Raw Datax-axis BiLSTM Network Resultsz-axis Raw Dataz-axis BiLSTM Network Results
Skewness ξ2.83292.72832.72942.8156
Kurtosis υ0.0177−0.1077−0.0631−0.0170

Appendix B. Determine the ARMA Model Order

Figure A1. Autocorrelation function and partial autocorrelation function diagram. (a,b) x-axis raw data, (c,d) x-axis BiLSTM network results, (e,f) z-axis raw data, and (g,h) z-axis BiLSTM network results.
Figure A1. Autocorrelation function and partial autocorrelation function diagram. (a,b) x-axis raw data, (c,d) x-axis BiLSTM network results, (e,f) z-axis raw data, and (g,h) z-axis BiLSTM network results.
Sensors 21 01181 g0a1aSensors 21 01181 g0a1b
The Akaike information criterion can be expressed as follows:
AIC ( p , q ) = N ln ( δ 2 ( p , q ) ) + 2 ( p + q + 1 )
where δ 2 is the variance of driving white noise under each order and N is the total number of data samples. When AIC obtains the minimum value, the fitted model is the optimal model. In the case that the maximum values of p and q are set to 3, the AIC values at each order are shown in Table A6, Table A7, Table A8 and Table A9.
Table A6. AIC values of x-axis raw data at each order.
Table A6. AIC values of x-axis raw data at each order.
p = 0p = 1p = 2p = 3
q = 0 −4350.7006−5373.4026−5483.9134
q = 1−2378.8661−5480.4267−5503.6485−5503.2634
q = 2−3784.2642−5501.9738−5502.2446−5501.9462
q = 3−4524.5464−5504.1306−5502.9798−5514.9860
Table A7. AIC values of x-axis BiLSTM network results at each order.
Table A7. AIC values of x-axis BiLSTM network results at each order.
p = 0p = 1p = 2p = 3
q = 0 −33245.8540−33390.6679−33390.1658
q = 1−24407.6844−33392.3127−33390.3534−33387.4822
q = 2−28837.8009−33390.3543−33391.2919−33390.0297
q = 3−30742.3669−33388.3649−33390.0548−33456.4704
Table A8. AIC values of z-axis raw data at each order.
Table A8. AIC values of z-axis raw data at each order.
p = 0p = 1p = 2p = 3
q = 0 −3384.5655−4241.9726−4367.2696
q = 1−1992.4063−4410.0138−4414.9553−4417.2529
q = 2−3107.6730−4414.3979−4414.5702−4415.3240
q = 3−3612.4223−4417.6140−4415.7666−4414.6351
Table A9. AIC values of z-axis BiLSTM network results at each order.
Table A9. AIC values of z-axis BiLSTM network results at each order.
p = 0p = 1p = 2p = 3
q = 0 −31059.1193−31186.5670−31212.5235
q = 1−23478.3934−31198.8844−31202.3767−31212.2053
q = 2−27430.5011−31206.1886−31221.9048−31228.0632
q = 3−29112.3646−31212.9557−31211.5881−31262.0166
The first-order autocorrelation of the identified model residuals { ω t } was tested by the Durbin–Watson method. Assuming that the first-order correlation of { ω t } can be defined as:
ω t = ρ ω t 1 + v t
when ρ   = 0, there is no first-order autocorrelation in { ω t } . Then the Durbin–Watson test value d :
d = n = 2 N ( ω n ω n 1 ) 2 n = 1 N ω n 2 2 ( 1 ρ )
The identified model’s Durbin–Watson test value is shown in Table A10, indicating that the estimated model satisfies the requirements.
Table A10. D-W test results.
Table A10. D-W test results.
x-axis Raw Datax-axis BiLSTM Network Resultsz-axis Raw Dataz-axis BiLSTM Network Results
Durbin–Watson test value1.99972.00641.99981.9903

References

  1. Brown, A.K. Gps/ins uses low-cost mems imu. IEEE Aerosp. Electron. Syst. Mag. 2005, 20, 3–10. [Google Scholar] [CrossRef]
  2. Noureldin, A.; Karamat, T.B.; Eberts, M.D.; El-Shafie, A. Performance enhancement of MEMS-based INS/GPS integration for low-cost navigation applications. IEEE Trans. Veh. Technol. 2008, 58, 1077–1096. [Google Scholar] [CrossRef]
  3. Chia, J.; Low, K.; Goh, S.; Xing, Y. In A low complexity Kalman filter for improving MEMS based gyroscope performance. In Proceedings of the 2016 IEEE Aerospace Conference, Big Sky, MO, USA, 5–12 March 2016; pp. 1–7. [Google Scholar]
  4. Mohammadi, Z.; Salarieh, H. Investigating the effects of quadrature error in parametrically and harmonically excited MEMS rate gyroscopes. Measurement 2016, 87, 152–175. [Google Scholar] [CrossRef]
  5. Zhang, H.; Wu, Y.; Wu, W.; Wu, M.; Hu, X. Improved multi-position calibration for inertial measurement units. Meas. Sci. Technol. 2009, 21, 015107. [Google Scholar] [CrossRef]
  6. Fong, W.; Ong, S.; Nee, A. Methods for in-field user calibration of an inertial measurement unit without external equipment. Meas. Sci. Technol. 2008, 19, 085202. [Google Scholar] [CrossRef]
  7. Huang, L. Auto regressive moving average (ARMA) modeling method for Gyro random noise using a robust Kalman filter. Sensors 2015, 15, 25277–25286. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  8. Narasimhappa, M.; Nayak, J.; Terra, M.H.; Sabat, S.L. ARMA model based adaptive unscented fading Kalman filter for reducing drift of fiber optic gyroscope. Sens. Actuators 2016, 251, 42–51. [Google Scholar] [CrossRef]
  9. Seong, S.M.; Lee, J.G.; Park, C.G. Equivalent ARMA model representation for RLG random errors. IEEE Trans. Aerosp. Electron. Syst. 2000, 36, 286–290. [Google Scholar] [CrossRef]
  10. Quinchia, A.G.; Ferrer, C.; Falco, G.; Falletti, E.; Dovis, F. In Analysis and modelling of MEMS inertial measurement unit. In Proceedings of the 2012 International Conference on Localization and GNSS, Starnberg, Germany, 25–27 June 2012; pp. 1–7. [Google Scholar]
  11. Kang, C.H.; Kim, S.Y.; Park, C.G. Improvement of a low cost MEMS inertial-GPS integrated system using wavelet denoising techniques. Int. J. Aeronaut. Space Sci. 2011, 12, 371–378. [Google Scholar] [CrossRef] [Green Version]
  12. Zhang, Y.S.; Yang, T. Modeling and compensation of MEMS gyroscope output data based on support vector machine. Measurement 2012, 45, 922–926. [Google Scholar] [CrossRef]
  13. Bhatt, D.; Aggarwal, P.; Bhattacharya, P.; Devabhaktuni, V. An enhanced mems error modeling approach based on nu-support vector regression. Sensors 2012, 12, 9448–9466. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  14. El-Rabbany, A.; El-Diasty, M. An efficient neural network model for de-noising of MEMS-based inertial data. J. Navig. 2004, 57, 407. [Google Scholar] [CrossRef]
  15. Jiang, C.; Chen, S.; Chen, Y.; Zhang, B.; Feng, Z.; Zhou, H.; Bo, Y. A MEMS IMU de-noising method using long short term memory recurrent neural networks (LSTM-RNN). Sensors 2018, 18, 3470. [Google Scholar] [CrossRef] [Green Version]
  16. Jiang, C.; Chen, S.; Chen, Y.; Bo, Y.; Han, L.; Guo, J.; Feng, Z.; Zhou, H. Performance analysis of a deep simple recurrent unit recurrent neural network (SRU-RNN) in MEMS gyroscope de-noising. Sensors 2018, 18, 4471. [Google Scholar] [CrossRef] [Green Version]
  17. Jiang, C.; Chen, Y.; Chen, S.; Bo, Y.; Li, W.; Tian, W.; Guo, J. A mixed deep recurrent neural network for MEMS gyroscope noise suppressing. Electronics 2019, 8, 181. [Google Scholar] [CrossRef] [Green Version]
  18. Zhu, Z.; Bo, Y.; Jiang, C. A MEMS Gyroscope Noise Suppressing Method Using Neural Architecture Search Neural Network. Math. Probl. Eng. 2019, 2019, 5491243. [Google Scholar] [CrossRef] [Green Version]
  19. Barbour, N.M. Inertial Navigation Sensors; Charles Stark Draper Lab Inc.: Cambridge, MA, USA, 2010. [Google Scholar]
  20. Jafari, M.; Najafabadi, T.A.; Moshiri, B.; Tabatabaei, S.S.; Sahebjameyan, M. PEM stochastic modeling for MEMS inertial sensors in conventional and redundant IMUs. IEEE Sens. J. 2014, 14, 2019–2027. [Google Scholar] [CrossRef]
  21. Cho, J.Y. High-Performance Micromachined Vibratory Rate and Rate-Integrating Gyroscopes. Ph.D. Thesis, University of Michigan, Ann Arbor, MI, USA, 2012. [Google Scholar]
  22. Park, B.S.; Han, K.; Lee, S.; Yu, M. Analysis of compensation for a g-sensitivity scale-factor error for a MEMS vibratory gyroscope. J. Micromech. Microeng. 2015, 25, 115006. [Google Scholar] [CrossRef]
  23. Dean, R.; Flowers, G.; Hodel, S.; MacAllister, K.; Horvath, R. In Vibration Isolation of MEMS Sensors for Aerospace Applications. In Proceedings of the SPIE Proceedings Series; SPIE: Bellingham, WA, USA, 2002; pp. 166–170. [Google Scholar]
  24. Reid, J.R.; Bright, V.M.; Kosinski, J.A. A micromachined vibration isolation system for reducing the vibration sensitivity of surface transverse wave resonators. IEEE Trans. Ultrason. Ferroelectr. Freq. Control 1998, 45, 528–534. [Google Scholar] [CrossRef]
  25. Reid, J.R.; Bright, V.M.; Stewart, J.T.; Kosinski, J.A. In Reducing the normal acceleration sensitivity of surface transverse wave resonators using micromachined isolation systems. In Proceedings of the 1996 IEEE International Frequency Control Symposium, Honolulu, HI, USA, 5–7 June 1996; pp. 464–472. [Google Scholar]
  26. Dean, R.; Flowers, G.; Sanders, N.; Horvath, R.; Johnson, W.; Kranz, M.; Whitley, M. Experimental validation and testing of components for active damping control for micromachined mechanical vibration isolation filters using electrostatic actuation. In Smart Structures and Materials 2006: Smart Electronics, MEMS, BioMEMS, and Nanotechnology; International Society for Optics and Photonics: Bellingham, WA, USA, 2006; p. 61721C. [Google Scholar]
  27. Kim, J.M.; Mok, S.H.; Leeghim, H.; Lee, C.Y. Vibration-Robust Attitude and Heading Reference System Using Windowed Measurement Error Covariance. Int. J. Aeronaut. Space Sci. 2017, 18, 555–564. [Google Scholar] [CrossRef]
  28. Wu, Z.; Yao, M.; Ma, H.; Jia, W. De-noising MEMS inertial sensors for low-cost vehicular attitude estimation based on singular spectrum analysis and independent component analysis. Electron. Lett. 2013, 49, 892–893. [Google Scholar] [CrossRef]
  29. Hao, X.Y.; Li, M.; Han, X.F.; Jia, H.G. In Analysis on the influence of random vibration on MEMS gyro precision and error compensation. In Applied Mechanics and Materials; Trans Tech Publications: Stafa, Switzerland, 2012; pp. 4164–4168. [Google Scholar]
  30. Hochreiter, S.; Schmidhuber, J. Long short-term memory. Neural Comput. 1997, 9, 1735–1780. [Google Scholar] [CrossRef]
  31. Bengio, Y.; Simard, P.; Frasconi, P. Learning long-term dependencies with gradient descent is difficult. IEEE Trans. Neural Netw. 1994, 5, 157–166. [Google Scholar] [CrossRef] [PubMed]
  32. Graves, A.; Schmidhuber, J. In Framewise phoneme classification with bidirectional LSTM networks. In Proceedings of the 2005 IEEE International Joint Conference on Neural Networks, Montreal, QC, Canada, 31 July–4 August 2005; pp. 2047–2052. [Google Scholar]
  33. Kalman, R.E. A new approach to linear filtering and prediction problems. J. Basic Eng. Mar 1960, 82, 35–45. [Google Scholar] [CrossRef] [Green Version]
  34. Kustiawan, I.; Chi, K.H. Handoff decision using a Kalman filter and fuzzy logic in heterogeneous wireless networks. IEEE Commun. Lett. 2015, 19, 2258–2261. [Google Scholar] [CrossRef]
  35. Hosseinyalamdary, S. Deep Kalman filter: Simultaneous multi-sensor integration and modelling; A GNSS/IMU case study. Sensors 2018, 18, 1316. [Google Scholar] [CrossRef] [Green Version]
  36. Zhang, Y.; Peng, C.; Mou, D.; Li, M.; Quan, W. An adaptive filtering approach based on the dynamic variance model for reducing MEMS gyroscope random error. Sensors 2018, 18, 3943. [Google Scholar] [CrossRef] [Green Version]
  37. Yan, Y.; Guo, P.; Liu, L. In A novel hybridization of artificial neural networks and ARIMA models for forecasting resource consumption in an IIS web server. In Proceedings of the 2014 IEEE International Symposium on Software Reliability Engineering Workshops, Naples, Italy, 3–6 November 2014; pp. 437–442. [Google Scholar]
  38. Lőrincz, I.; Tajmar, M. Identification of error sources in high precision weight measurements of gyroscopes. Measurement 2015, 73, 453–461. [Google Scholar] [CrossRef] [Green Version]
  39. Shumway, R.H.; Stoffer, D.S. An approach to time series smoothing and forecasting using the EM algorithm. J. Time Ser. Anal. 1982, 3, 253–264. [Google Scholar] [CrossRef]
  40. Wu, C.J. On the convergence properties of the EM algorithm. Ann. Stat. 1983, 11, 95–103. [Google Scholar] [CrossRef]
  41. Andrieu, C.; Doucet, A. In Online expectation-maximization type algorithms for parameter estimation in general state space models. In Proceedings of the 2003 IEEE International Conference on Acoustics, Speech, and Signal Processing, Hong Kong, China, 6–10 April 2003; p. VI-69. [Google Scholar]
  42. Wen, Q.; Ge, Z.; Song, Z. Data-based linear Gaussian state-space model for dynamic process monitoring. AIChE J. 2012, 58, 3763–3776. [Google Scholar] [CrossRef]
  43. Mirikitani, D.; Nikolaev, N. Nonlinear maximum likelihood estimation of electricity spot prices using recurrent neural networks. Neural Comput. Appl. 2011, 20, 79–89. [Google Scholar] [CrossRef]
  44. Moore, T.J.; Sadler, B.M.; Kozick, R.J. Maximum-likelihood estimation, the Cramér–Rao bound, and the method of scoring with parameter constraints. IEEE Trans. Signal. Process. 2008, 56, 895–908. [Google Scholar] [CrossRef]
  45. Hesar, H.D.; Mohebbi, M. An Adaptive Kalman Filter Bank for ECG Denoising. IEEE J. Biomed. Health Inform. 2020, 25, 13–21. [Google Scholar] [CrossRef]
  46. Hartikainen, J.; Solin, A.; Särkkä, S. Optimal Filtering with Kalman Filters and Smoothers—A Manual for MATLAB Toolbox EKF/UKF; Aalto University School of Science: Espoo, Finland, 2011. [Google Scholar]
  47. Rousseeuw, P.J.; Leroy, A.M. Robust Regression and Outlier Detection; John Wiley & Sons: Hoboken, NJ, USA, 2005; Volume 589. [Google Scholar]
  48. Srivastava, N.; Hinton, G.; Krizhevsky, A.; Sutskever, I.; Salakhutdinov, R. Dropout: A simple way to prevent neural networks from overfitting. J. Mach. Learn. Res. 2014, 15, 1929–1958. [Google Scholar]
  49. Kingma, D.P.; Ba, J. Adam: A method for stochastic optimization. arXiv 2014, arXiv:1412.6980. [Google Scholar]
Figure 1. Information flow of multi-layer bidirectional long short-term memory (BiLSTM) network.
Figure 1. Information flow of multi-layer bidirectional long short-term memory (BiLSTM) network.
Sensors 21 01181 g001
Figure 2. An illustration of this paper’s proposed method.
Figure 2. An illustration of this paper’s proposed method.
Sensors 21 01181 g002
Figure 3. Experimental system. (a) MSI3200H inertial measurement unit, (b) vibration table, (c) data acquisition procedure, and (d) power spectral density of linear random vibration loads.
Figure 3. Experimental system. (a) MSI3200H inertial measurement unit, (b) vibration table, (c) data acquisition procedure, and (d) power spectral density of linear random vibration loads.
Sensors 21 01181 g003
Figure 4. The variation of gyroscope x-axis signal.
Figure 4. The variation of gyroscope x-axis signal.
Sensors 21 01181 g004
Figure 5. Multi-layer BiLSTM network.
Figure 5. Multi-layer BiLSTM network.
Sensors 21 01181 g005
Figure 6. Training loss of BiLSTM, LSTM, BiGRU, and GRU.
Figure 6. Training loss of BiLSTM, LSTM, BiGRU, and GRU.
Sensors 21 01181 g006
Figure 7. Comparison of error compensation performance of BiLSTM, LSTM, BiGRU, and GRU. (a) Part of the x-axis data zoomed-in and (b) part of the z-axis data zoomed-in.
Figure 7. Comparison of error compensation performance of BiLSTM, LSTM, BiGRU, and GRU. (a) Part of the x-axis data zoomed-in and (b) part of the z-axis data zoomed-in.
Sensors 21 01181 g007
Figure 8. Log-likelihood value change of the iteration epoch.
Figure 8. Log-likelihood value change of the iteration epoch.
Sensors 21 01181 g008
Figure 9. Comparison of error compensation performance of BiLSTM-EM-KF and BiLSTM-ARMA-KF. (a) Part of the x-axis data zoomed-in and (b) part of the z-axis data zoomed-in.
Figure 9. Comparison of error compensation performance of BiLSTM-EM-KF and BiLSTM-ARMA-KF. (a) Part of the x-axis data zoomed-in and (b) part of the z-axis data zoomed-in.
Sensors 21 01181 g009
Table 1. Specifications of MSI320H gyroscope.
Table 1. Specifications of MSI320H gyroscope.
GYROInput range±1800°/s
Bias instability (Allan variance)36°/h
Angular random walk (Allan variance)0.4°/√h
Bandwidth (−3 dB)≥220 Hz
GENERALSample rate100 1000 Hz
Weight≤25 g
Supply voltage5.0 ± 0.5 V
RS422 transmission bit rate921600 bps
Mechanical shock, any direction≥20,000 g
Table 2. Specifications used for network training.
Table 2. Specifications used for network training.
The output dimension of dense layer1
Activation function of dense layerReLU
Dropout rate0.5
Batch size256
Training epoch50
Learning rate0.001
Table 3. Performance with varying values of the input data step.
Table 3. Performance with varying values of the input data step.
Number of Hidden LayersNumber of Hidden UnitsInput Data StepSTD (°/s)Time/Epoch
106450.155123 s
1064100.148138 s
1064150.148360 s
1064200.134682 s
1064250.136898 s
1064300.1501115 s
Table 4. Performance with varying values of the number of hidden units.
Table 4. Performance with varying values of the number of hidden units.
Number of Hidden LayersNumber of Hidden UnitsInput Data StepSTD (°/s)Time/Epoch
108200.150482 s
1016200.145982 s
1032200.155981 s
1064200.134682 s
10128200.132681 s
10256200.146888 s
Table 5. Performance with varying values of the number of hidden layers.
Table 5. Performance with varying values of the number of hidden layers.
Number of Hidden LayersNumber of Hidden UnitsInput Data StepSTD (°/s)Time/Epoch
1128200.149310 s
2128200.151319 s
3128200.159727 s
4128200.155734 s
5128200.165842 s
6128200.150550 s
7128200.147058 s
8128200.145966 s
9128200.154275 s
10128200.132681 s
11128200.140590 s
12128200.139398 s
Table 6. Comparison of raw data, BiLSTM, LSTM, BiGRU, and GRU standard deviation values for x-axis data.
Table 6. Comparison of raw data, BiLSTM, LSTM, BiGRU, and GRU standard deviation values for x-axis data.
x-axisSTD (°/s)Percentage
Raw data0.2493
BiLSTM0.132653.19%
LSTM0.154361.89%
BiGRU0.150160.21%
GRU0.160464.34%
Table 7. Comparison of raw data, BiLSTM, LSTM, BiGRU, and GRU standard deviation values for z-axis data.
Table 7. Comparison of raw data, BiLSTM, LSTM, BiGRU, and GRU standard deviation values for z-axis data.
z-axisSTD (°/s)Percentage
Raw data0.2400
BiLSTM0.135356.38%
LSTM0.155064.58%
BiGRU0.150462.67%
GRU0.157465.58%
Table 8. Kalman filter parameters of all measurements.
Table 8. Kalman filter parameters of all measurements.
Φ Γ H Q R
x-axis raw data [ 0.3126 0.8168 0.1520 0 1 0 0 0 0 1 0 0 0 0 1 0 ] [ 1 0.6885 0.3241 0.0366 0 0 0 0 0 0 0 0 0 0 0 0 ] [ 1 0 0 0 ] [ 0.0370 0 0 0 0 0.0370 0 0 0 0 0.0370 0 0 0 0 0.0370 ] 0.0604
x-axis BiLSTM [ 0.8505 0.8891 0.7745 0 1 0 0 0 0 1 0 0 0 0 1 0 ] [ 1 0.1354 0.8476 0.0815 0 0 0 0 0 0 0 0 0 0 0 0 ] [ 1 0 0 0 ] [ 0.0036 0 0 0 0 0.0036 0 0 0 0 0.0036 0 0 0 0 0.0036 ] 0.0175
z-axis raw data [ 0.8593 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 ] [ 1 0.5191 0.0328 0.0236 0 0 0 0 0 0 0 0 0 0 0 0 ] [ 1 0 0 0 ] [ 0.0405 0 0 0 0 0.0405 0 0 0 0 0.0405 0 0 0 0 0.0405 ] 0.0596
z-axis BiLSTM [ 2.0000 1.2268 0.2031 0 1 0 0 0 0 1 0 0 0 0 1 0 ] [ 1 1.0446 0.0809 0.1086 0 0 0 0 0 0 0 0 0 0 0 0 ] [ 1 0 0 0 ] [ 0.0043 0 0 0 0 0.0043 0 0 0 0 0.0043 0 0 0 0 0.0043 ] 0.0183
Table 9. The parameter estimation results.
Table 9. The parameter estimation results.
Φ H Q R
x-axis raw data0.97230.13500.00160.1181
x-axis BiLSTM0.97380.34220.00160.2852
z-axis raw data0.94710.13270.00650.1155
z-axis BiLSTM0.95300.29830.00440.2430
Table 10. Comparison of raw data, BiLSTM, ARMA-KF, EM-KF, BiLSTM-ARMA-KF, and BiLSTM-EM-KF standard deviation values for x-axis data.
Table 10. Comparison of raw data, BiLSTM, ARMA-KF, EM-KF, BiLSTM-ARMA-KF, and BiLSTM-EM-KF standard deviation values for x-axis data.
x-axisSTD (°/s)Percentage
Raw data0.2493
BiLSTM0.132653.19%
ARMA-KF0.161864.90%
EM-KF0.094337.83%
BiLSTM-ARMA-KF0.120148.17%
BiLSTM-EM-KF0.064225.75%
Table 11. Comparison of raw data, BiLSTM, ARMA-KF, EM-KF, BiLSTM-ARMA-KF, and BiLSTM-EM-KF standard deviation values for z-axis data.
Table 11. Comparison of raw data, BiLSTM, ARMA-KF, EM-KF, BiLSTM-ARMA-KF, and BiLSTM-EM-KF standard deviation values for z-axis data.
z-axisSTD (°/s)Percentage
Raw data0.2400
BiLSTM0.135356.38%
ARMA-KF0.185377.21%
EM-KF0.109845.75%
BiLSTM-ARMA-KF0.123351.38%
BiLSTM-EM-KF0.095839.92%
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Zhu, C.; Cai, S.; Yang, Y.; Xu, W.; Shen, H.; Chu, H. A Combined Method for MEMS Gyroscope Error Compensation Using a Long Short-Term Memory Network and Kalman Filter in Random Vibration Environments. Sensors 2021, 21, 1181. https://0-doi-org.brum.beds.ac.uk/10.3390/s21041181

AMA Style

Zhu C, Cai S, Yang Y, Xu W, Shen H, Chu H. A Combined Method for MEMS Gyroscope Error Compensation Using a Long Short-Term Memory Network and Kalman Filter in Random Vibration Environments. Sensors. 2021; 21(4):1181. https://0-doi-org.brum.beds.ac.uk/10.3390/s21041181

Chicago/Turabian Style

Zhu, Chenhao, Sheng Cai, Yifan Yang, Wei Xu, Honghai Shen, and Hairong Chu. 2021. "A Combined Method for MEMS Gyroscope Error Compensation Using a Long Short-Term Memory Network and Kalman Filter in Random Vibration Environments" Sensors 21, no. 4: 1181. https://0-doi-org.brum.beds.ac.uk/10.3390/s21041181

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop