3.2. Feature Variable Selection
To accurately predict the target variable RSRP, it is essential to both understand the vessel motion attitude (roll, pitch, yaw, surge, sway, heave, etc.) and surrounding environment information (temperature, field strength, distance, etc.). Fifteen relevant influencing factors are listed below, followed by a brief description.
x1: surge, measured by an accelerometer to reflect the linear acceleration of the vessel in the X-axis direction, indicating the longitudinal motion state (forward/backward acceleration) of the vessel. The unit is usually g (9.8 m/s2).
x2: sway, measured by an accelerometer to reflect the linear acceleration of the vessel in the Y-axis direction, reflecting the lateral motion state of the vessel (acceleration of left and right swaying), and is used to monitor the force on the hull and the stability of navigation.
x3: heave, measured by an accelerometer to reflect the linear acceleration of the vessel in the Z-axis direction, reflecting the vertical motion state of the vessel (up and down jolting acceleration). It is commonly used for wave height estimation and navigation comfort assessment.
x4: roll, the angular velocity of the ship’s rotation around the X-axis, reflecting the rate of change of the longitudinal tilt of the hull. The unit is typically degrees per second (°/s) or radians per second (rad/s).
x5: pitch, the angular velocity of the ship’s rotation around the Y-axis, reflecting the speed of the ship’s heading change. The unit is usually degrees per second (°/s) or radians per second (rad/s).
x6: yaw, the angular velocity of the ship’s rotation around the Z-axis, reflecting the speed of the ship’s lateral tilt change. The unit is usually degrees per second (°/s) or radians per second (rad/s).
x7: roll angle, the angle of rotation around the X-axis, reflecting the longitudinal tilt of the hull. The unit is typically degrees (°).
x8: pitch angle, the angle of rotation around the Y-axis, reflecting the degree of deviation from the vessel’s course.
x9: heave angle, the angle of rotation around the Z-axis, reflecting the degree of lateral tilt of the hull.
x10: longitudinal magnetic (LM) field, measured by a magnetometer to determine the intensity of the Earth’s magnetic field in the X-axis direction of the vessel’s coordinate system. It is commonly used for course calculation and attitude correction, with units typically being Tesla (T) or Gauss (Gs).
x11: athwartship magnetic (AM) field, the intensity of the Earth’s magnetic field in the Y-axis direction of the vessel’s coordinate system.
x12: vertical magnetic (VM) field, the intensity of the Earth’s magnetic field in the Z-axis direction of the vessel’s coordinate system. It can be used to detect electromagnetic interference in the environment and assist in the calibration of the heading sensor.
x13: surrounding temperature (ST), the measurement of the air temperature around a vessel, typically expressed in °C or °F.
x14: ship speed (SS), the speed at which a vessel moves through water, typically measured in knots.
To extract the most critical input variables for predicting 5G signal strength, a feature selection strategy combining Pearson correlation coefficient analysis with the PSO algorithm was employed. The Pearson correlation coefficient [
45], also known as the Pearson product–moment correlation coefficient, measures the linear correlation between two variables X and Y, with values ranging from −1 to 1. A value of 1 indicates perfect positive correlation, −1 indicates perfect negative correlation, and 0 indicates no linear relationship between the variables.
For two variables
X = {
x1,
x2, …,
xn} and
Y = {
y1,
y2, …,
yn}, the Pearson correlation coefficient
r is calculated as follows:
where
r represents the correlation coefficient,
xi represents the feature value of the
ith sample in the input features, and
yi represents the feature value of the
ith sample in the output features.
As shown in
Figure 6 (Pearson correlation heatmap), the LM field exhibits the highest correlation coefficient. Based on feature scoring, surge and heave were excluded in subsequent tests, retaining the remaining data.
3.4. Hyperparameter Tuning
In the model training process, 20% of the data are designated as the test set, which is exclusively utilized for data prediction to preclude any interference from feature selection and model evaluation on the predictive outcomes. The remaining 80% of the data are allocated as the training set. A temporal partitioning approach is employed for dataset construction, with a window length of five time steps, thereby eliminating temporal overlap and leakage between the test set and the training set.
The optimization of hyperparameters proceeded in two phases. The initial phase focused on configuring the ConvLSTM architecture and its associated training parameters. Subsequently, the XGBoost model’s hyperparameters were automatically optimized via the PSO algorithm. The ConvLSTM model employed a three-layer architecture with progressively decreasing filter sizes (32, 16, and 8) to capture spatiotemporal features at multiple scales. Each ConvLSTM2D layer utilized a 3 × 3 kernel with appropriate padding to preserve spatial dimensions. The input tensor shape was configured as (5, 1, 15, 1) to accommodate the temporal sequence length and spatial dimensions. A fully connected layer with 64 ReLU-activated neurons followed by a single output neuron was employed for the final prediction. Training was conducted using the Mean Squared Error (MSE) loss function with a batch size of 32 and a maximum of 150 epochs. To prevent overfitting, we implemented early stopping with a patience of 10 epochs, monitoring the validation loss. The training would terminate if the validation loss failed to improve for 10 consecutive epochs.
For the XGBoost model, we implemented the PSO algorithm to automatically search for optimal hyperparameters. The PSO algorithm was configured with a swarm size of 20 particles and a maximum of 30 iterations. The algorithm parameters were set as follows: inertia weight, individual learning factor, and global learning factor. The minimum fitness threshold was set to 0.001.
Figure 7 displays the training curves for ConvLSTM. ConvLSTM employs one-dimensional feature vectors (15 features) and transforms them into a pseudo-spatial representation by reshaping the original three-dimensional tensor of dimensions (number of samples, 5, 15) into a five-dimensional tensor of dimensions (number of samples, 5, 1, 15, 1). The figure shows two curves: training loss represents iterations during training, while verification loss indicates iterations during prediction. It is evident that convergence is achieved around iteration 10, with MSE loss stabilizing in subsequent iterations.
By employing the PSO algorithm to optimize XGBoost hyperparameters, the optimal parameter ranges for XGBoost were ultimately determined, as shown in
Table 1.
Through iterative refinement, the optimal parameters for PSO-XGBoost and ConvLSTM are presented in
Table 2. Other models employ network search methodologies to identify the parameter configurations that yield optimal performance in predictive tasks. For precise definitions of each hyperparameter, refer to the documentation of corresponding functions in scikit-learn.
3.6. ConvLSTM-PSO-XGBoost Model Fusion Approach
ConvLSTM effectively extracts spatio-temporal correlation features from data through convolutional operations and gating mechanisms. Meanwhile, PSO-XGBoost enhances the efficiency of traditional XGBoost in handling high-dimensional features and modeling nonlinear relationships by optimizing hyperparameters via the PSO algorithm. Due to the significant heterogeneity in model architecture and characteristics between the two, the fusion model demonstrates multiple outstanding advantages when dealing with complex data scenarios. Specifically, it exhibits complementarity. ConvLSTM can effectively capture long-term temporal dependencies within the data by virtue of its unique structure, delving into the underlying patterns of data changes over time. Meanwhile, PSO-XGBoost excels at handling complex interactions among high-dimensional features, accurately grasping the information embedded in different feature combinations. These two models complement each other, jointly providing a more comprehensive and in-depth perspective for the analysis of complex data. On the other hand, the fusion model demonstrates remarkable robustness. Single models are often prone to interference when confronted with noisy data, leading to deviations in analysis results. In contrast, the fusion model, by integrating the strengths of different models, can effectively reduce its sensitivity to noisy data. Even in the presence of a certain degree of noise interference in the data, it can still maintain relatively stable and reliable performance. Furthermore, the fusion model possesses strong generalization ability. Through the adoption of an ensemble strategy, it organically combines the advantages of multiple models, avoiding the overfitting issues that may occur in single models and reducing the risk of overfitting. As a result, it can achieve favorable application results across a wider range of data distributions and scenarios.
The fusion achieves information complementarity by concatenating or transforming intermediate features from ConvLSTM and PSO-XGBoost. Its core lies in constructing a unified feature space. An effective model fusion method directly impacts the fusion results of ConvLSTM and PSO-XGBoost. By testing different fusion approaches and comparing the MAE and RMSE of the final fused models, the optimal fusion method is selected. The optimal fusion method for ConvLSTM-PSO-XGBoost is entropy-weighted fusion. Comparison diagrams for each fusion method are shown in
Figure 8.