# A ResNet1D-AttLSTM-Based Approach for Ship Trajectory Classification
## 1 Introduction
[PERSON] et al. [34] proposed a CNN-LSTM progressive trajectory classification model. By segmenting trajectories into sub-segments, the model uses CNNs to extract local motion pattern features within each sub-segment, which are then input into an LSTM for classification. However, this progressive method relies on the granularity of local motion patterns in sub-segments for temporal feature extraction, potentially leading to information loss. [PERSON] et al. [35] proposed a 1 DCNN-LSTM hybrid classification model, achieving classification by fusing the results of the two networks at the classifier level, but this fusion may limit the model's comprehensive understanding of the original trajectory data. Despite significant progress in using AIS data for ship classification, existing research still faces the following limitations: (1) Image-based methods may lead to information loss during data conversion, and their applicability is limited in small dataset scenarios due to the difficulty in visualizing certain types of features; (2) RNNs and their variants are constrained by sequential processing mechanisms and long-range dependency issues, as well as the sequential traversal characteristics of convolution operations, making it difficult for current methods to effectively extract joint motion patterns in non-adjacent regions; (3) when using convolutional networks to process trajectory sequences (rather than trajectory images), existing methods do not consider using residual blocks to expand network depth to enhance model scalability. As the number of network layers and input trajectory lengths increase, these methods may face challenges in addressing gradient vanishing or explosion issues. To address these issues, this study proposes the following innovative solutions:  
* **Non-adjacent co-feature extraction based on self-attention:** To overcome the limitations in extracting features from non-adjacent regions, this study leverages the self-attention mechanism [36], which can directly attend to any position in the sequence and dynamically focus on the most useful information for the current task, to construct the AttLSTM module. By innovatively integrating the self-attention mechanism with the LSTM architecture, the model can more effectively extract feature patterns that require joint representation across multiple regions, even if these patterns are discontinuously distributed within a region. * **Depth-scalable architecture with residual learning:** To enhance model scalability in sequence tasks while minimizing gradient-related concerns, this study proposes the Resnet1D module. This module combines one-dimensional convolution with skip connections, constructing a multi-scale feature pyramid to ensure stable gradient propagation while expanding model depth. Based on these innovations, this paper constructs the ResNet1D-AttLSTM hybrid classification model for ship trajectories, achieving multi-level, multi-dimensional feature extraction and fusion: the model performs multi-granularity spatial feature mining through the ResNet1D module, captures temporal dynamic evolution patterns using AttLSTM, and finally generates high-integrity spatiotemporal joint feature representations through a designed projection fusion strategy for ship trajectory classification.