DOI: 10.3390/app16168216 ISSN: 2076-3417

Traffic Flow Prediction Based on Hypergraph Transformer: A Case Study in Huangmaohai Cross-Sea Corridor

Fan Jiang, Zhiyong Ma, Pumulo Mukozomba, Zhihao Ke, Shaowei Zhang, Huayang Yu

Reliable traffic flow forecasting is a core component of intelligent transportation systems; however, many current approaches are still unable to simultaneously model spatial interdependencies and long-term temporal correlations, particularly in cross-sea corridors that exhibit directional heterogeneity and pronounced temporal variability. This study aims to develop an accurate and stable traffic flow prediction framework for cross-sea corridors. To achieve this, an HGTransformer model was proposed that constructed a hypergraph from traffic nodes based on spatial proximity and correlated flow variations, and used hypergraph convolution to extract spatial node representations. These representations were then fed into a Transformer equipped with multi-head self-attention and positional encoding, enabling the model to capture global temporal dependencies in the evolution of traffic flow. Using hourly traffic flow data from the Huangmaohai cross-sea corridor, the model was tested on 1 to 4 h forecasting horizons and compared with long short-term memory (LSTM), multi-layer perceptron (MLP), random forest (RF), support vector regression (SVR), and Bayesian regression (BR) models. The proposed model achieved the best overall performance, with average mean absolute percentage error (MAPE), mean absolute error (MAE), weighted mean absolute percentage error (WMAPE), and root mean square error (RMSE) of 0.178, 13.375, 0.140, and 20.538, respectively. At the 1 h horizon, these values further decreased to 0.172, 12.678, 0.132, and 19.401, while preserving peak–valley structures more accurately under both short- and longer-horizon forecasting. The main contribution of this study lies in the systematic application and validation of the Huangmaohai Corridor dataset, including a reproducible hypergraph construction strategy tailored specifically for this particular infrastructure.

More from our Archive