In order to verify the effectiveness of the proposed method, numerous experiments have been performed. The experiments were divided into two parts based on simulation data (see
Section 4.1) and real data (see
Section 4.2). Simulations were run on the model described in
Section 2. The real data were acquired by the Sailfish AUV.
4.1. Results on Simulation Data
First, the validity of AUV system identification based on the LSTM neural network is verified. A set of hyperparameters is randomly set for the LSTM neural network, and a system identification experiment is carried out for the above AUV simulation system. In total, 4990 input and output data pairs are used for model identification, of which 4000 sets of data are used as training sets to train the LSTM neural network. The other 990 sets of data are used as validation sets to test the recognition effect of the model. The number of training is set to 100.
The change curve of the loss function during training is shown in
Figure 7. As shown in the figure, the loss curve converges during training, and the value of the loss function decreases with iterations. From the perspective of the convergence of the loss curve, the application of the LSTM neural network can effectively realize the identification of the AUV system.
After 100 times of training, the validation dataset is brought into the network model to test. After calculation, the squared sum of the output error is 8.490711, and the mean and variance of the absolute value of the error are 0.1761263 and 0.0145471, respectively. We can see that the output of the LSTM network model can fit the actual output of the system after 100 times of training. However, the error between the network output and the real output is large. The fitting curve between the network output and the real output will be shown in the comparison results of different methods later.
The large output fitting error of the above LSTM neural network model is because the hyperparameter settings of the model are not suitable. The identification accuracy is greatly affected by the network hyperparameter settings. Inappropriate hyperparameter settings may even lead to non-convergence. In order to achieve high-precision system identification, a reinforcement learning algorithm is used to optimize the selection of the hyperparameters of the above neural network.
Data were divided into training and test sets during each test, yielding a training set of 4000 and a test set of 990. The proposed method was performed for 100 episodes. To demonstrate the optimization performance of the method, we compare the results of five different stages (proc1-0th episode, proc2-25th episode, proc3-50th episode, proc4-75th episode, and proc5-100th episode).
We can see from the above results that the five optimized LSTM neural network models can make the loss curve converge quickly, shown in
Figure 8. It can be also noticed that the convergence speed increases as the episode increases, and this method has prominent optimization characteristics.
The statistical results of the output errors of the five groups of LSTM neural network models on the validation set are recorded in
Table 4. In order to make the trend of MSE more apparent, it is enlarged 1000 times and displayed in
Figure 9. As can be seen from the graph, the MAE, MSE and RMSE of the error of making predictions on the validation set decrease as the number of episodes increases. The above results also demonstrate the performance of the method from a statistical point of view.
In order to further illustrate the advantages of this method, we compared the effect of the method before and after optimization with the commonly used DR algorithm. We compare the prediction results on the validation set optimized after 0 episodes and 100 episodes with the results predicted by the DR algorithm. The fitting curves of the network output and the real output of the AUV’s position, linear velocity, angle, and angular velocity are shown in
Figure 10,
Figure 11,
Figure 12 and
Figure 13, respectively. It can be seen from the figure that the optimized LSTM model makes the output of the 12 variables of the identification model have better agreement with the actual system output. In order to more clearly reflect the effectiveness of the method proposed in this paper, the MAE, MSE, and RMSE indicators of the prediction error are shown in
Table 5. Compared with the unoptimized approach and DR, our method shows superior performance, with less MAE (28.42%, 29.13%), MSE (38.66%, 38.96%), and RMSE (21.70%, 25.81%). It can be seen that the deviation between the output of our method and the actual system is smaller than that of the other two methods.
4.2. Results on Real Data
The AUV dataset is required for training and validating the LSTM neural network model identification method. Therefore, the experiments of data collection should be carried out first. The experiments were carried out on the Sailfish AUV, as shown in
Figure 14.
The actual data includes the sensor’s noise in the acquisition process, and it is more difficult to obtain an accurate model than the simulation. Therefore, the method performed 200 episodes. The experimental dataset is divided into training and testing sets, yielding a training set of 4000 and a test set of 990. From the loss curve of the LSTM neural network in the training process, this method has prominent learning characteristics, as shown in
Figure 15.
The fitting curve between the network output and the real output is shown in
Figure 16,
Figure 17,
Figure 18 and
Figure 19. The calculated MSE of the output error is 550.830181, and the MAE and RMSE values are 6.250734 and 23.469771, respectively. We can see that the LSTM neural network obtained by optimization can fit the system’s actual output and achieve high-precision recognition of AUVs. In order to illustrate the superiority of the method, it is compared with the commonly used dead reckoning (DR) method. The results are shown in
Table 6, the proposed method provided 64.90% higher MAE, 64.20% higher MSE, and 37.76% higher RMSE than the DR method.
Due to the small prediction bias for the AUV motion state, It turns out, yet again, that the proposed method has high predictive power. Therefore, the proposed identification method is of great significance to the actual navigation control of AUV.