# Trajectory Prediction of Marine Moving Target Using Deep Neural Networks with Trajectory Data
## 4 Experiments
### Experimental Conditions  
In this research, the position of the marine motion ship was collected by the space-based AIS system. AIS devices can be installed on vessels and shore-based stations, as well as space-based payloads of satellites. Shore-based AIS data are typically sampled at shorter intervals of the minute level, such as one minute, generally for inshore ships. Space-based AIS data are sampled at longer intervals limited to satellite orbital periods, typically at the hour level, and generally for far-shore ships. Since the observation time of  
Figure 4: Diagram of the Training and Testing Process of the Trajectory Prediction Model. the satellite is sparse and uneven, the input data, which are related to the observation time, are non-uniform in time. The time-scale requirements for trajectory prediction depend on the regression period of the satellites, and there are also unequal intervals. The dataset selected for this experiment is the trajectory data of a single ship over a period of nearly a year around the east coast of the United States, with a total of about 6000 track points. Moreover, the time intervals of the track point are sparse and uneven, and about an hour. All trajectory samples are divided into the training set and test set at a ratio of 7:3. Different from the randomly generated training set and test set in other problems, in order to better conform to the scenario application and test the generalization of the model, the first 70% is selected as training sample data, and the 30% is the test sample data, which actually makes it harder to predict. In data pre-processing, duplicate and abnormal data records are deleted. In this paper, a trajectory sequence containing \(s\) time is taken as an experimental sample, and the previous \(s{-}1\) moment data are used as available information to predict the position at the \(s\)th moment. Firstly, sample segmentation of historical trajectory data is carried out. Take the data of adjacent \(s\) moments as a sample. In this experiment, take \(s{=}\) 10. It needs to be explained that if the value of the parameter \(s\) is too small, it cannot effectively represent the current moving status. Whereas if the value of \(s\) is too high, the correlation between the status of the ship's predictive moment and the status of its starting moment becomes weaker, which will interfere with the prediction result. For the experimental samples in this paper, good experimental results were obtained when \(s=10\) was selected. Then, the observation data of the first nine moments and the 10 th observation time, which are given as available information, are exploited to compute the multi-dimensional trajectory feature matrix as Equation (13) in Section 3.1. The model can predict the positions at any given moment. The prediction error of the model can be computed as Equation (18):  
\[\left\{ \begin{array}{l}e_{\lambda}=\hat{\lambda}-\lambda\\ e_{\varphi}=\hat{\varphi}-\varphi\end{array} \right. \tag{18}\]  
where \((\lambda,\varphi)\) represents the observation position, \((\hat{\lambda},\hat{\varphi})\) indicating the predicted position. In order to evaluate the prediction result, the distance error is computed, which is expressed as the surface arc distance of the predicted position and the actual observed position. The calculation formula is expressed as Equation (19):  
\[Dis=R{\bullet}\text{arccos}\big{(}\sin\varphi\sin\hat{\varphi}+\cos\varphi\cos \hat{\varphi}\cos(\hat{\lambda}-\lambda)\big{)} \tag{19}\]  
Root Mean Square Error (RMSE) is commonly used as the statistical criterion to evaluate model error, and the calculation formula is expressed as Equation (20):  
\[\left\{ \begin{array}{l}RMSE_{\lambda}=\sqrt{\frac{1}{n}\sum\limits_{i=1}^{n }\big{(}\hat{\lambda}_{i}-\lambda_{i}\big{)}^{2}}\\ RMSE_{\varphi}=\sqrt{\frac{1}{n}\sum\limits_{i=1}^{n}\big{(}\hat{\varphi}_{i} -\varphi_{i}\big{)}^{2}}\end{array} \right. \tag{20}\]  
In the problem of this paper, the prediction time is variable, and the error usually becomes larger with a longer prediction time.