Ship motion response prediction method based on neural network
By constructing the EMD-CNN-BiLSTM neural network prediction model, the problem of low prediction accuracy of ship motion response in the existing technology is solved, and higher prediction accuracy and computing efficiency are achieved, improving the safety and stability of the ship.
Patent Information
- Application Number
- CN202510333219.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-20
- Publication Date
- 2025-05-13
AI Technical Summary
The prior art predicts the motion response of a ship under complex sea conditions, and it is difficult to process nonlinear and non-stationary time series data.
A prediction method based on neural network is adopted, combining empirical modal decomposition (EMD), residual convolutional neural network (ResCNN) and bidirectional long and short-term memory network (BiLSTM), an EMD-CNN-BiLSTM neural network prediction model is constructed, and data is decomposed by EMD, ResCNN extracts features, and BiLSTM captures time series trends to improve prediction accuracy.
It significantly improves the prediction accuracy of ship motion response, improves the generalization ability and computing efficiency of the model, and ensures the safety and stability of the ship.
Smart Images

Figure CN119975704A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of ship motion prediction, in particular to a ship motion response prediction method based on neural network. Background Art
[0002] When ships are sailing at sea, they are subject to the combined effects of complex external forces such as wind, waves, and currents, which cause them to produce irregular, nonlinear, and highly non-stationary swaying motions, such as heave and sway, which pose a severe challenge to the stability and safety of ships. In order to ensure the safety of navigation and improve operational efficiency, it is particularly important to accurately predict the motion response of ships. However, traditional prediction methods, such as autoregressive models and Kalman filters, often have poor prediction effects when processing such nonlinear and non-stationary time series data. At the same time, although long short-term memory neural networks have good fitting capabilities in some cases, their fitting capabilities may also decline in the face of highly nonlinear ship motion data, and may even lead to problems such as inability to fit, gradient disappearance, or explosion.
[0003] Therefore, it is necessary to seek more effective methods to accurately predict the motion response of ships in complex sea conditions. Summary of the invention
[0004] The technical problem to be solved by the present invention is to provide a ship motion response prediction method which not only can improve the prediction accuracy of ship motion response but also has good generalization ability and computational efficiency, and has important application value for improving the safety and stability of ships in view of the shortcomings of the existing technology.
[0005] The technical problem to be solved by the present invention is achieved by the following technical solution. The present invention is a ship motion response prediction method based on a neural network, and the steps of the method are as follows:
[0006] (1) Data collection and preprocessing
[0007] Collect the motion data of the ship in different sea conditions and standardize the data;
[0008] (2) Model construction
[0009] Construct the EMD-CNN-BiLSTM neural network prediction model;
[0010] (3) Training and Optimization
[0011] Use the divided data set to train the model;
[0012] (4) Prediction and verification
[0013] The trained model is verified using the test set. Specifically, the data in the test set is graded using the EMD method, and then predictions are made on the decomposed data. Subsequently, the predicted data are re-superimposed and combined and compared with the original unprocessed test data to evaluate the accuracy of the model in the prediction task.
[0014] The technical problem to be solved by the present invention can also be further achieved by the following technical solution. For the above-mentioned ship motion response prediction method based on neural network, the specific operation of step (1) is:
[0015] According to the following formula, the ship motion response time series data in the training set is standardized to obtain the standardized ship motion response time series data;
[0016]
[0017] In the formula, Represents the ship motion response data x at time i i The standardized results, Represents the ship motion response data x at time i i , s represents the standard deviation of the original ship motion response time series data, and n represents the number of data.
[0018] The technical problem to be solved by the present invention can also be further achieved by the following technical scheme. For the above-mentioned neural network-based ship motion response prediction method, a time series data set is constructed, sampling is performed at intervals of 0.01 seconds, each sample contains 600 continuous time points, and is divided into a training set, a validation set, and a test set.
[0019] The technical problem to be solved by the present invention can also be further achieved by the following technical solution. For the above-mentioned neural network-based ship motion response prediction method, the EMD-CNN-BiLSTM neural network prediction model constructed in step (2) includes:
[0020] The first module is the empirical mode decomposition algorithm EMD, which is used as the input of the EMD-CNN-BiLSTM model to decompose the data into stationary data and transmit it to the next layer;
[0021] The second module is a convolutional layer ResCNN with multiple residual structures. The convolution submodule contains 256 convolution kernels, the time step is 3, padding = 'same', and the input and output sizes are the same. It is used to extract features from the input data, including the first convolution submodule, the second convolution submodule, and the third convolution submodule;
[0022] The output of EMD is the input of the first convolution submodule, the output of the first convolution submodule is the input of the second convolution submodule, and the output of the second convolution submodule is the input of the third convolution submodule. At the same time, the output of the first convolution submodule, the output of the second convolution submodule and the output of the third convolution submodule together constitute the input of the next layer of bidirectional long short-term memory neural network module;
[0023] The third module is a bidirectional long short-term memory neural network module BiLSTM. BiLSTM enhances the model's ability to capture past and future information in time series by training input data in two directions. It specifically includes the first BiLSTM layer, the first Dropout layer, the second BiLSTM layer, and the second Dropout layer. The first Dropout layer and the second Dropout layer are both used to randomly set the output of some neurons to zero when training the neural network model to improve the robustness of the model.
[0024] The fourth module is the fully connected layer, which is used to receive the output of the third module as input. At the same time, the fully connected layer serves as the output of the entire EMD-CNN-BiLSTM neural network model. At the same time, the predicted data after EMD decomposition is superimposed with the original data for prediction effect comparison.
[0025] The technical problem to be solved by the present invention can also be further achieved through the following technical scheme. For the above-mentioned neural network-based ship motion response prediction method, the first convolution submodule, the second convolution submodule, and the third convolution submodule have the same structure and are all composed of convolution layers and normalization layers connected in sequence.
[0026] The technical problem to be solved by the present invention can also be further achieved by the following technical solution. For the above-mentioned ship motion response prediction method based on neural network, the training method of step (3) is:
[0027] The dropout rate of the Dropout layer is set to 0.3, the hidden layer activation function is the mean square error function, the optimizer of the training model is Adam, the initial training learning rate is 0.001, the training batch size is 64, and the number of training iterations is 80;
[0028] The loss function for training uses the mean square error of the multi-dimensional output mean, as shown below:
[0029]
[0030] Among them, X i represents the actual value at time i, Represents the model prediction value.
[0031] The technical problem to be solved by the present invention can also be further achieved by the following technical solution. For the above-mentioned ship motion response prediction method based on neural network, the EMD decomposition method in step (4) is used to gradually decompose the complex nonlinear and non-stationary signals into a series of intrinsic mode functions, and sort them in descending order of frequency, and extract the overall trend of signal changes, which specifically includes the following steps:
[0032] (4.1) By identifying the local maximum and minimum points in the signal x(t), all extreme points are determined and the extreme values of the endpoints are appropriately extended to ensure that the entire signal is completely covered by the envelope. Then, the cubic spline interpolation method is used to connect these maximum and minimum points to form two upper and lower envelopes. The average value is the mean envelope m of the signal. 1 (t);
[0033] (4.2) Subtract the mean envelope m from the original signal x(t) 1 (t), and get a new signal h 1 (t), that is:
[0034] h 1 (t) = x(t) - m 1 (t)
[0035] (4.3) In order to verify h 1 (t) Whether it meets the standard of intrinsic mode function IMF, it is necessary to check the following two conditions:
[0036] Condition 1: The number of local maxima and minima in the signal should be equal to the number of zero crossings, or differ by at most one;
[0037] Condition 2: The mean envelope should be close to zero at all data points; if the signal component meets the quasi-Cauchy convergence principle, it is also considered to meet condition 2;
[0038]
[0039] Where: δ is the setting value for stopping the screening process, which is 0.2 to 0.3;
[0040] If the judgment condition is met, then h 1 (t) is an IMF component of the original signal x(t); if the discrimination condition is not met, h 1 (t) replaces the original signal x(t), and repeats (4.1) to (4.3) until the IMF component is found;
[0041] (4.4) Subtract the first IMF component imf from the original signal x(t) 1 (t), and get the new signal r without the high frequency part 1(t), repeat the above screening process to obtain the second IMF, the third IMF, ..., the nth IMF, until the remaining signal r n (t) The monotonicity condition is met, that is, the remainder is a constant term or a monotonic function, and the decomposition process is completed;
[0042] (4.5) Finally, the original signal x(t) is decomposed by EMD to obtain:
[0043]
[0044] Where: imf i (t) is the IMF component, R n (t) is the trend term (residual).
[0045] Compared with the prior art, the EMD-ResCNN-BiLSTM model of the present invention achieves performance improvements in multiple aspects by combining empirical mode decomposition (EMD), residual convolutional neural network (ResCNN) and bidirectional long short-term memory network (BiLSTM):
[0046] 1. Data decomposition and feature extraction
[0047] As a pre-processing step of the model, EMD can decompose complex non-stationary time series data into several stationary intrinsic mode functions (IMFs) with different local characteristics. This decomposition helps the model better capture subtle changes in the data and provides richer information for subsequent feature extraction and prediction.
[0048] 2. Residual network enhances feature expression
[0049] The ResCNN module enhances the network’s ability to learn deep features and improves the model’s ability to recognize complex patterns in time series data by introducing residual connections.
[0050] 3. Bidirectional LSTM improves time series understanding
[0051] The BiLSTM module takes advantage of its bidirectional characteristics to consider both past and future information in the time series data, thereby improving the model's prediction accuracy for the changing trend of the time series;
[0052] 4. Improved prediction performance
[0053] The EMD-ResCNN-BiLSTM model showed excellent prediction performance. Compared with traditional models such as ARIMA, RNN, and LSTM, the model had significantly lower evaluation indicators such as root mean square error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE).
[0054] 6. Computational efficiency and complexity
[0055] Although the model structure is relatively complex, by optimizing the algorithm and model design, the model controls the computational complexity while maintaining the prediction performance, and completes the model training and prediction tasks within a reasonable time. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] Figure 1 It is the EMD algorithm decomposition flow chart of the present invention;
[0057] Figure 2 It is the EMD-CNN-BiLSTM neural network structure diagram of the present invention;
[0058] Figure 3 This is a result diagram of a single sample validation set of ship heave according to the present invention;
[0059] Figure 4 This is a result diagram of a single sample test set of ship heave according to the present invention;
[0060] Figure 5 This is a result diagram of a single sample validation set of ship pitching according to the present invention;
[0061] Figure 6 This is a result diagram of the single sample test set of ship pitching of the present invention. DETAILED DESCRIPTION
[0062] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0063] A ship motion response prediction method based on neural network is proposed. The core lies in the innovative model architecture combining empirical mode decomposition (EMD), residual convolutional neural network (ResCNN) and bidirectional long short-term memory network (BiLSTM). The non-stationary time series is decomposed into multiple stationary intrinsic mode functions through EMD, and then the deep feature learning ability of ResCNN and the bidirectional time series analysis ability of BiLSTM are used to greatly improve the prediction accuracy of the model for complex time series data. In addition, the fully connected layer output and optimized computational efficiency of the model further enhance its performance and generalization ability in practical applications, so that this structural design not only improves the prediction accuracy of the model for ship motion response, but also has good generalization ability and computational efficiency, which has important application value for improving the safety and stability of ships.
[0064] The specific scheme of the present invention is:
[0065] 1. Data collection and preprocessing:
[0066] The motion posture data of the ship under different sea conditions are collected and the data are standardized. According to the following formula, the ship motion response time series data in the training set are standardized to obtain the standardized ship motion response time series data;
[0067]
[0068] In the formula, Represents the ship motion response data x at time i i The standardized results, Represents the ship motion response data x at time i i , s represents the standard deviation of the original ship motion response time series data, and n represents the number of data.
[0069] In order to eliminate the impact of dimension, a time series data set was constructed (sampled at intervals of 0.01 seconds, and each sample contained 600 consecutive time points) and divided into training set, validation set, and test set.
[0070] 2. Model construction:
[0071] Construct an EMD-CNN-BiLSTM neural network prediction model, which includes:
[0072] The first module is the empirical mode decomposition algorithm (EMD), which serves as the input of the EMD-CNN-BiLSTM model. It decomposes the data into stationary data and transmits it to the next layer. The decomposition flow chart of the EMD algorithm is as follows: Figure 1 As shown;
[0073] The second module is a convolutional layer (ResCNN) with multiple residual structures. The convolution submodule contains 256 convolution kernels, a time step of 3, padding = 'same', and the input and output sizes are the same. It is used to extract features from the input data, which includes the first convolution submodule, the second convolution submodule, and the third convolution submodule. The output of EMD is the input of the first convolution submodule, and the output of the first convolution submodule is used as the input of the second convolution submodule. The output of the second convolution submodule is used as the input of the third convolution submodule. At the same time, the output of the first convolution submodule, the output of the second convolution submodule, and the output of the third convolution submodule together constitute the input of the next layer of bidirectional long short-term memory neural network module. The first convolution submodule, the second convolution submodule, and the third convolution submodule have the same structure, and are composed of sequentially connected convolution layers and normalization layers;
[0074] The third module is a bidirectional long short-term memory neural network module (BiLSTM). BiLSTM enhances the model's ability to capture past and future information in time series by training input data in two directions (forward and reverse), thereby improving the accuracy of prediction. It includes the first BiLSTM layer (kernel size 256), the first Dropout layer, the second BiLSTM layer (kernel size 128), and the second Dropout layer. Both the Dropout layer and the second Dropout layer are used to randomly set the output of some neurons to zero when training the neural network model, which can help improve the robustness of the model and reduce the risk of overfitting, thereby improving the performance of the model on data that has not been seen in the future.
[0075] The fourth module is the fully connected layer, which is used to receive the output of the third module as input. At the same time, the fully connected layer serves as the output of the entire EMD-CNN-BiLSTM neural network model. At the same time, the predicted data after EMD decomposition is superimposed with the original data for prediction effect comparison.
[0076] The overall EMD-CNN-BiLSTM neural network structure is as follows Figure 2 shown.
[0077] 3. Training and optimization:
[0078] The model is trained using the divided data set. The dropout rate of the Dropout layer is set to 0.3, the hidden layer activation function is the mean square error function, the optimizer of the training model is Adam, the initial training learning rate is 0.001, the training batch size is 64, and the number of training iterations is 80.
[0079] The loss function for training uses the mean square error of the multi-dimensional output mean, as shown below:
[0080]
[0081] Among them, X i represents the actual value at time i, Represents the model prediction value.
[0082] 4. Prediction and verification:
[0083] The trained model was verified using the test set, and the predicted data after EMD decomposition was superimposed with the original data for comparison of the prediction effect to evaluate the prediction accuracy of the model.
[0084] Among them, the decomposition process of the EMD algorithm is:
[0085] (1) By identifying the local maximum and minimum points in the signal x(t), all extreme points are determined and the extreme values of the endpoints are appropriately extended to ensure that the entire signal is completely covered by the envelope; then, the cubic spline interpolation method is used to connect these maximum and minimum points to form two upper and lower envelopes, and their average value is the mean envelope m of the signal. 1 (t);
[0086] (2) Subtract the mean envelope m from the original signal x(t) 1 (t), and get a new signal h 1 (t), that is:
[0087] h 1 (t) = x(t) - m 1 (t)
[0088] (3) In order to verify h 1 (t) Whether it meets the criteria of intrinsic mode function (IMF) needs to check the following two conditions:
[0089] First, the number of local maxima and minima in the signal should be equal to the number of zero crossings, or differ by at most one. Second, the mean envelope should be close to zero at all data points. It is often difficult for signal components to fully satisfy the second condition, but they are usually considered to meet the condition if they obey the quasi-Cauchy convergence principle.
[0090]
[0091] Where: δ is the setting value for stopping the screening process, which is generally between 0.2 and 0.3;
[0092] If the judgment condition is met, then h 1 (t) is an IMF component of the original signal x(t); if the discrimination condition is not met, h 1 (t) replaces the original signal x(t), and repeats (1) to (3) until the IMF component is found.
[0093] (4) Subtract the first IMF component imf from the original signal x(t) 1 (t), and get the new signal r without the high frequency part 1 (t), repeat the above screening process to obtain the second IMF, the third IMF, ..., the nth IMF, until the remaining signal r n (t) The monotonicity condition is met, that is, the remainder is a constant term or a monotonic function, and the decomposition process is completed;
[0094] (5) Finally, the original signal x(t) is decomposed by EMD to obtain:
[0095]
[0096] Where: imf i (t) is the IMF component, R n (t) is the trend term (residual);
[0097] According to the above steps (1) to (5), the goal of the EMD decomposition method is to gradually decompose complex nonlinear and non-stationary signals into a series of intrinsic mode functions, which are sorted in descending order of frequency, and at the same time extract the overall trend of signal changes. This method can accurately capture the instantaneous frequency characteristics of each frequency component, ensure better reflection of the true amplitude-frequency characteristics of the signal, and give the model richer physical connotations.
[0098] The present invention has also been verified in practice:
[0099] Figure 3 is the result of the single sample validation set of ship heave, Figure 4 is the result of the single sample test set of ship heave, Figure 5 is the result of the single sample validation set of ship pitching, Figure 6 This is the result of the single sample test set of ship pitch;
[0100] It can be seen that the present invention can perform stably in the training set and can successfully predict the motion posture of the ship's heave in the verification set.
[0101] In summary, the EMD-ResCNN-BiLSTM model of the present invention forms an integrated model through its innovative structural design and the combination of multiple algorithms, giving full play to the advantages of each sub-module algorithm and showing significant performance advantages in the time series prediction task of ship motion posture.
Claims
1. A method for predicting ship motion response based on neural network, characterized in that: The steps of this method are as follows: (1) Data collection and preprocessing Collect the motion data of the ship in different sea conditions and standardize the data; (2) Model construction Construct the EMD-CNN-BiLSTM neural network prediction model; (3) Training and Optimization Use the divided data set to train the model; (4) Prediction and verification The trained model is verified using the test set. Specifically, the data in the test set is graded using the EMD method, and then predictions are made on the decomposed data. Subsequently, the predicted data are re-superimposed and combined and compared with the original unprocessed test data to evaluate the accuracy of the model in the prediction task.
2. The method for predicting ship motion response based on neural network according to claim 1, characterized in that: The specific operation of step (1) is: According to the following formula, the ship motion response time series data in the training set is standardized to obtain the standardized ship motion response time series data; In the formula, Represents the ship motion response data x at time i i The standardized results, Represents the ship motion response data x at time i i , s represents the standard deviation of the original ship motion response time series data, and n represents the number of data.
3. The method for predicting ship motion response based on neural network according to claim 2, characterized in that: Construct a time series data set, sample at intervals of 0.01 seconds, and each sample contains 600 consecutive time points, which are divided into training set, validation set, and test set.
4. The method for predicting ship motion response based on neural network according to claim 1, characterized in that: The EMD-CNN-BiLSTM neural network prediction model constructed in step (2) includes: The first module is the empirical mode decomposition algorithm EMD, which is used as the input of the EMD-CNN-BiLSTM model to decompose the data into stationary data and transmit it to the next layer; The second module is a convolutional layer ResCNN with multiple residual structures. The convolution submodule contains 256 convolution kernels, the time step is 3, padding = 'same', and the input and output sizes are the same. It is used to extract features from the input data, including the first convolution submodule, the second convolution submodule, and the third convolution submodule; The output of EMD is the input of the first convolution submodule, the output of the first convolution submodule is the input of the second convolution submodule, and the output of the second convolution submodule is the input of the third convolution submodule. At the same time, the output of the first convolution submodule, the output of the second convolution submodule and the output of the third convolution submodule together constitute the input of the next layer of bidirectional long short-term memory neural network module; The third module is a bidirectional long short-term memory neural network module BiLSTM. BiLSTM enhances the model's ability to capture past and future information in time series by training input data in two directions. It specifically includes the first BiLSTM layer, the first Dropout layer, the second BiLSTM layer, and the second Dropout layer. The first Dropout layer and the second Dropout layer are both used to randomly set the output of some neurons to zero when training the neural network model to improve the robustness of the model. The fourth module is the fully connected layer, which is used to receive the output of the third module as input. At the same time, the fully connected layer serves as the output of the entire EMD-CNN-BiLSTM neural network model. At the same time, the predicted data after EMD decomposition is superimposed with the original data for prediction effect comparison.
5. The method for predicting ship motion response based on neural network according to claim 4, characterized in that: in, The first convolution submodule, the second convolution submodule, and the third convolution submodule have the same structure, and are all composed of sequentially connected convolution layers and normalization layers.
6. The method for predicting ship motion response based on neural network according to claim 1, characterized in that: The training method of step (3) is: The dropout rate of the Dropout layer is set to 0.3, the hidden layer activation function is the mean square error function, the optimizer of the training model is Adam, the initial training learning rate is 0.001, the training batch size is 64, and the number of training iterations is 80; The loss function for training uses the mean square error of the multi-dimensional output mean, as shown below: Among them, X i represents the actual value at time i, Represents the model prediction value.
7. The method for predicting ship motion response based on neural network according to claim 1, characterized in that: The EMD decomposition method in step (4) is used to gradually decompose the complex nonlinear and non-stationary signal into a series of intrinsic mode functions, and sort them in descending order of frequency, while extracting the overall trend of the signal change, which specifically includes the following steps: (4.1) By identifying the local maximum and minimum points in the signal x(t), all extreme points are determined and the extreme values of the endpoints are appropriately extended to ensure that the entire signal is completely covered by the envelope. Then, the cubic spline interpolation method is used to connect these maximum and minimum points to form two upper and lower envelopes, and their average value is the mean envelope m1(t) of the signal; (4.2) Subtract the mean envelope m1(t) from the original signal x(t) to obtain a new signal h1(t), that is: h1(t)=x(t)-m1(t) (4.3) In order to verify whether h1(t) meets the criteria of the intrinsic mode function IMF, the following two conditions need to be checked: Condition 1: The number of local maxima and minima in the signal should be equal to the number of zero crossings, or differ by at most one; Condition 2: The mean envelope should be close to zero at all data points; if the signal component quasi-Cauchy convergence principle is met, it is also considered to meet condition 2; Where: δ is the setting value for stopping the screening process, ranging from 0.2 to 0.3; If the discrimination condition is met, h1(t) is an IMF component of the original signal x(t); if the discrimination condition is not met, h1(t) replaces the original signal x(t), and (4.1) to (4.3) are repeated until the IMF component is found. (4.4) Subtract the first IMF component imf1(t) from the original signal x(t) to obtain the new signal r1(t) without the high-frequency part. Repeat the above screening process to obtain the second IMF, the third IMF, and the nth IMF in turn, until the remaining signal r n (t) The monotonicity condition is met, that is, the remainder is a constant term or a monotonic function, and the decomposition process is completed; (4.5) Finally, the original signal x(t) is decomposed by EMD to obtain: Where: imf i (t) is the IMF component, R n (t) is the trend term (residual).