Short-term traffic flow prediction method based on dynamic multi-dimensional global perception graph convolutional network
By using a dynamic multidimensional global perception graph convolutional network to dynamically generate an adjacency matrix and combining it with a dynamic dual-stream gating fusion module and a trend-aligned attention mechanism, the problem of insufficient modeling accuracy and poor adaptability in existing short-term traffic flow prediction is solved, achieving higher prediction accuracy and stability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- ANHUI NORMAL UNIV
- Filing Date
- 2025-12-25
- Publication Date
- 2026-04-17
AI Technical Summary
Existing short-term traffic flow prediction methods have limited effectiveness in handling nonlinear and random fluctuations, making it difficult to fully capture the spatial structural features of traffic networks. The update mechanism of dynamic graph convolutional recurrent networks is not perfect, resulting in high computational complexity. The stability and scalability of self-supervised learning need to be verified, and they fail to effectively distinguish diverse spatiotemporal background information, leading to the accumulation of prediction errors.
A dynamic multidimensional global perception graph convolutional network is adopted. By dynamically generating the adjacency matrix and combining it with a dynamic dual-flow gating fusion module and a trend-aligned attention mechanism, the spatial and temporal heterogeneity of traffic flow is dynamically characterized, weights are adaptively allocated, error accumulation is reduced, and prediction accuracy is improved.
It significantly improves the model's adaptability to complex traffic networks and prediction accuracy, reduces errors in iterative prediction, and enhances the stability and generalization ability of prediction results. It outperforms existing benchmark models in terms of mean absolute error, root mean square error, and mean absolute percentage error on multiple traffic datasets.
Smart Images

Figure CN121884580A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of traffic flow prediction. Specifically, this invention relates to a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network. Background Technology
[0002] Despite significant progress in short-term traffic flow prediction, several problems remain to be addressed. Traditional statistical methods heavily rely on the assumption of data stationarity, failing to handle the prevalent nonlinearity and random fluctuations in traffic flow, resulting in limited predictive effectiveness. While machine learning methods can model complex data, they often depend on manual feature design and selection, making it difficult to fully uncover potential patterns in traffic data. Furthermore, most focus only on temporal correlations, failing to effectively capture the spatial structural features of the road network. Although deep learning methods offer advantages in spatiotemporal modeling, most graph neural network-based models rely on predefined adjacency matrices, making it difficult to fully reflect the dynamic spatial correlations of the road network, potentially overlooking potential effective connections.
[0003] To address the aforementioned shortcomings, some studies have attempted to introduce dynamic graph modeling methods, such as dynamic graph convolutional recurrent networks and decomposed dynamic graph convolutional recurrent networks. While these methods can dynamically adjust adjacency relationships through data-driven approaches, their update mechanisms remain imperfect and fail to fully reflect the complex changes in traffic flow across different time periods. Furthermore, the introduction of attention mechanisms enhances the model's ability to characterize spatiotemporal dependencies to some extent, but it introduces high computational complexity in large-scale traffic networks, impacting its practical application efficiency. Although self-supervised learning methods have emerged in recent years and can improve the generalization ability of traffic flow representations through auxiliary tasks, their stability and scalability still need to be verified. Meanwhile, in short-term prediction tasks, some methods fail to effectively distinguish diverse spatiotemporal background information, easily leading to the continuous accumulation of errors during the prediction process, reducing overall prediction accuracy and reliability.
[0004] Therefore, existing technologies still have shortcomings in short-term traffic flow prediction, such as limited modeling accuracy, insufficient dynamic adaptability, and imperfect spatiotemporal feature capture. There is an urgent need to propose a new technical solution to further improve the accuracy and applicability of short-term traffic flow prediction.
[0005] Therefore, this invention proposes a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network. Summary of the Invention
[0006] This invention aims to overcome the shortcomings of existing technologies and proposes a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network, in order to achieve the following objectives: improve the accuracy and applicability of short-term traffic flow prediction.
[0007] To achieve the above objectives, the technical solution adopted by this invention is as follows: a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network, the method comprising the following steps:
[0008] Step S1: Obtain the input dynamic graph feature sequence And generate spatiotemporal meta-parameters; where t represents the time step and P represents the sequence length;
[0009] Step S2: After feature enhancement of the dynamic graph feature sequence, it is fused with the spatiotemporal meta-parameters, and then spatiotemporal feature encoding is performed separately.
[0010] Step S3: Fuse the spatiotemporal features obtained from the spatiotemporal feature encoding;
[0011] Step S4: Decode the spatiotemporal trend alignment of the fused spatiotemporal features.
[0012] Preferably, step S1 includes:
[0013] In the time dimension, the temporal embedding representation matrix is constructed as follows: The periodic embedding representation matrix is ,in, Indicates the time step of a day. Indicates the number of cycles. Indicates the time embedding dimension;
[0014] For any given time t, using the index function and The corresponding time position codes are extracted from the time embedding matrix and the periodic embedding matrix, and combined to obtain the final time embedding matrix as follows:
[0015] ;
[0016] in, This represents the Hadamard element-wise product;
[0017] In the spatial dimension, a spatial embedding matrix is introduced. Where N is the number of road network nodes, Embedding dimensions into space.
[0018] Preferably, step S1 further includes: dynamically generating meta-parameters for the temporal embedding matrix and the spatial embedding matrix respectively through a dynamic adjustment mechanism based on meta-parameters, including:
[0019] Construct a low-rank parameter pool ,in, Indicates the dimension of the meta-parameter. The size of the set of learnable parameters;
[0020] For any query vector Generate meta-parameters ,Right now:
[0021] ;
[0022] Correspondingly, in the time dimension, for the time embedding matrix B represents the number of rows in the matrix, obtained through the time meta-parameter pool. Mapped to time meta-parameters In the spatial dimension, for a spatial embedding matrix Through the spatial meta-parameter pool Mapping to spatial meta-parameters .
[0023] Preferably, the feature enhancement in step S2 includes:
[0024] For the input dynamic graph feature sequence Perform nonlinear mapping:
[0025] ;
[0026] in, This represents the feature encoding function, which uses a multilayer perceptron structure to encode features from the input dynamic graph feature sequence. Perform a nonlinear transformation to obtain the corresponding enhanced features. .
[0027] Preferably, in step S2, for the enhanced features Temporal features obtained by fusing with time meta-parameters The encoding is performed through a gating mechanism, and the gating mechanism update process is as follows:
[0028] ;
[0029] ;
[0030] ;
[0031] ;
[0032] in, This indicates that the door is being reset. Indicates an update to the door. Indicates candidate gates, Indicates a hidden state; This represents the Sigmoid activation function; It is the hyperbolic tangent activation function; , , , , , All are learnable parameters; This represents the element-wise multiplication operation; This represents matrix multiplication.
[0033] Preferably, in step S2,
[0034] For enhanced features Spatial features obtained after fusing with time meta-parameters The spatial dependencies of the traffic network are modeled by introducing dynamic graph convolution operations, which are as follows:
[0035] ;
[0036] in, Representation of features The output after dynamic graph convolution operation; It is the identity matrix; Degree matrix; b represents the graph convolution kernel parameters; b represents the bias term. The adjacency matrix of a dynamic graph is represented as follows:
[0037] ;
[0038] in, Indicates enhanced features; This represents the introduced learnable spatial embedding matrix, which is obtained by fusing spatial meta-parameters with the original spatial embedding matrix. This represents the modified linear unit activation function.
[0039] Preferably, step S3 includes: performing spatiotemporal feature fusion through a dynamic dual-stream gating fusion module, including:
[0040] Temporal features obtained from encoding Spatial features obtained by encoding By concatenating the feature dimensions, the two feature paths are combined into a joint feature representation, i.e.:
[0041] ;
[0042] Next, a learnable transformation matrix is introduced. And combined with the Sigmoid activation function to generate a dynamic gating weight matrix, that is:
[0043] ;
[0044] in, This represents the Sigmoid function, used to constrain the gate weights within the interval [0, 1].
[0045] After obtaining the dynamic gating weights, a gating weighting strategy is used to weight and fuse the two feature streams to obtain the final joint feature representation:
[0046] ;
[0047] in, This indicates an element-wise multiplication operation.
[0048] Preferably, step S4 includes:
[0049] Embedding historical time Embedded with future time The transformations are performed together to obtain the query Q, key K, and value V, i.e.:
[0050] ;
[0051] ;
[0052] ;
[0053] ;
[0054] in, This represents the spatiotemporal characteristics after fusion; Indicates the fusion function;
[0055] Then, the attention weights are calculated using a trend-aligned attention mechanism to obtain the attention matrix. The results of each attention head are then concatenated, and the spatiotemporal trend-aligned feature representation is obtained through linear mapping. The specific calculation formula is as follows:
[0056] ;
[0057] ;
[0058] in, The projection matrix; This indicates a multi-head splicing operation; This represents the final bullish trend alignment feature representation;
[0059] Finally, the decoder input is... Alignment features with trends The result is obtained through residual connection fusion, i.e.:
[0060] ;
[0061] in, This represents the decoder input.
[0062] Preferably, step S4 further includes: introducing a multi-step prediction strategy: using historical features As input to the decoder, and combined with the spatiotemporal meta-parameters of future time steps Perform feature fusion, that is:
[0063] ;
[0064] in, The calculation method is as follows:
[0065] ;
[0066] In the formula, It is a feature encoder, which adopts a fully connected network structure and uses the Sigmoid activation function to enhance feature representation ability; Represents the time embedding matrix; Represents the spatial embedding matrix; Represents the spatiotemporal meta-parameter pool;
[0067] Subsequently, As input to the dynamic graph convolutional recursive unit, the prediction results for the next m time steps are computed in parallel over all future time steps.
[0068] The technical effects of this invention are as follows:
[0069] (1) This invention dynamically generates an adjacency matrix through feature enhancement and multidimensional parameter learning mechanisms, which can dynamically characterize the spatial and temporal heterogeneity of different regions and time periods, avoiding the limitations of traditional methods that rely on fixed or static adjacency matrices, thereby improving the model's adaptability and expressive ability to complex traffic networks. (2) This invention introduces a dynamic dual-stream gating fusion mechanism, which can adaptively allocate weights in the interaction process of temporal and spatial features, effectively improving the modeling accuracy of global and local spatiotemporal dependencies, and enhancing the stability and generalization ability of the prediction results. (3) The trend-aligned parallel prediction module proposed in this invention significantly reduces the error accumulation problem in iterative prediction by fusing the temporal features of the prediction target with historical features, and can more accurately capture the trend changes of traffic flow, making the prediction results more consistent with the real dynamic laws. (4) Experiments on multiple real traffic datasets show that the method proposed in this invention is superior to existing benchmark models in terms of mean absolute error, root mean square error, and mean absolute percentage error, verifying the effectiveness and advancement of this method in short-term traffic flow prediction tasks. Attached Figure Description
[0070] Figure 1A schematic diagram illustrating the principle of a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network, provided in an embodiment of the present invention.
[0071] Figure 2 This is a schematic diagram illustrating the impact of the spatiotemporal embedding matrix on the prediction task on the PEMS04 and PEMS08 datasets, as provided in an embodiment of the present invention.
[0072] Figure 3 This is a schematic diagram showing the efficiency comparison results of different models provided in this embodiment of the invention on the Manchester dataset.
[0073] Figure 4 This is a schematic diagram illustrating the sensitivity analysis results of parameters on different datasets provided in this embodiment of the invention. Detailed Implementation
[0074] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. This is to help those skilled in the art to have a more complete, accurate, and in-depth understanding of the inventive concept and technical solutions of the present invention, and to facilitate its implementation. It should be noted that the terms "first," "second," etc., used in this application are only for the convenience of describing the technical solutions and to distinguish components; the corresponding component configurations may be the same or different, and are not intended to limit the scope of this application. To make the technical solutions of the present invention clearer, the present invention will be explained and illustrated through the following embodiments.
[0075] This embodiment provides a short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network, such as... Figure 1 As shown, the method includes the following steps:
[0076] Step S1: Obtain the input dynamic graph feature sequence And generate spatiotemporal meta-parameters; where t represents the time step and P represents the sequence length;
[0077] Step S2: After feature enhancement of the dynamic graph feature sequence, it is fused with the spatiotemporal meta-parameters, and then spatiotemporal feature encoding is performed separately.
[0078] Step S3: Fuse the spatiotemporal features obtained from the spatiotemporal feature encoding;
[0079] Step S4: Decode the spatiotemporal trend alignment of the fused spatiotemporal features.
[0080] Referring to step S1, a spatiotemporal meta-parameter generation method is first proposed to address the periodic behavioral characteristics of travel groups in traffic flow prediction, and to establish multi-scale temporal dependencies. This step captures temporal patterns in traffic data by constructing a temporal embedding representation matrix and a periodic embedding representation matrix. Specifically, in the time dimension, the temporal embedding representation matrix is constructed as follows: The periodic embedding representation matrix is ,in, Indicates the time step of a day. Indicates the number of cycles. Indicates the time embedding dimension;
[0081] For any given time t, using the index function and The corresponding time position codes are extracted from the time embedding matrix and the periodic embedding matrix, and combined to obtain the final time embedding matrix as follows:
[0082] ;
[0083] in, This represents the Hadamard element-wise product.
[0084] To further supplement spatial information, this embodiment introduces a spatial embedding matrix in the spatial dimension. Where N is the number of road network nodes, Embedding dimensions into space.
[0085] Considering the limited adaptability of static embedding in complex traffic scenarios, this embodiment provides a dynamic adjustment mechanism based on meta-parameters, which dynamically generates meta-parameters for the temporal embedding matrix and the spatial embedding matrix, respectively. In this mechanism, a low-rank meta-parameter pool is first constructed. ,in, Indicates the dimension of the meta-parameter. The size of the set of learnable parameters.
[0086] For any query vector Generate meta-parameters ,Right now:
[0087] ;
[0088] Correspondingly, in the time dimension, for the time embedding matrix B represents the number of rows in the matrix, obtained through the time meta-parameter pool. Mapped to time meta-parameters In the spatial dimension, for a spatial embedding matrix Through the spatial meta-parameter pool Mapping to spatial meta-parameters .
[0089] To enhance feature representation capabilities, this embodiment also embeds the original space. With original time embedding The spatiotemporal joint embedding is obtained by fusion. Combined with the spatiotemporal meta-parameter pool Generate fused spatiotemporal meta-parameters The calculation method is as follows:
[0090] ;
[0091] In the formula, It is a feature encoder, which adopts a fully connected network structure and uses the Sigmoid activation function to enhance feature representation ability; Represents the time embedding matrix; Represents the spatial embedding matrix; This represents the spatiotemporal meta-parameter pool.
[0092] Through the above steps, the spatiotemporal meta-parameters are dynamically generated, providing dynamic input features for subsequent processing. This allows for adjustments to features based on real-time traffic data, enhancing adaptability to different time periods and regions.
[0093] Referring to step S2, feature enhancement is first performed on the original input features to transform the raw traffic data into more expressive hidden features, providing a foundation for subsequent interactions. The feature enhancement includes:
[0094] For the input dynamic graph feature sequence Perform nonlinear mapping:
[0095] ;
[0096] in, This represents the feature encoding function, which uses a multilayer perceptron structure to encode features from the input dynamic graph feature sequence. Perform a nonlinear transformation to obtain the corresponding enhanced features. Then, the enhanced features are fused with the temporal and spatial meta-parameters respectively to obtain dynamic temporal and spatial feature inputs, thereby enhancing the model's adaptability in dynamically changing environments and enabling more accurate encoding of traffic flow features.
[0097] Specifically, for enhanced features Temporal features obtained by fusing with time meta-parameters In this embodiment, encoding is performed using a gating mechanism, and the gating mechanism update process is as follows:
[0098] ;
[0099] ;
[0100] ;
[0101] ;
[0102] in, This indicates that the door is being reset. Indicates an update to the door. Indicates candidate gates, Indicates a hidden state; This represents the Sigmoid activation function; It is the hyperbolic tangent activation function; , , , , , All are learnable parameters; This represents the element-wise multiplication operation; This represents matrix multiplication. This gating mechanism enables effective memorization and forgetting of information in dynamic traffic environments.
[0103] For enhanced features Spatial features obtained after fusing with time meta-parameters The spatial dependencies of the traffic network are modeled by introducing dynamic graph convolution operations, which are as follows:
[0104] ;
[0105] in, Representation of features The output after dynamic graph convolution operation; It is the identity matrix; Degree matrix; b represents the graph convolution kernel parameters; b represents the bias term. The adjacency matrix of a dynamic graph is represented as follows:
[0106] ;
[0107] in, Indicates enhanced features; This represents the introduced learnable spatial embedding matrix, which is obtained by fusing spatial meta-parameters with the original spatial embedding matrix. This represents the modified linear unit activation function.
[0108] Through this step, this embodiment uses a gating mechanism to capture temporal dependencies in the time dimension and uses dynamic graph convolution operations to model complex road network topology in the spatial dimension, realizing dynamic multidimensional encoding of traffic flow features. By generating an adaptive adjacency matrix through feature enhancement and multidimensional metaparameter learning, it can dynamically characterize the spatial and temporal heterogeneity of different regions and time periods, avoiding the limitations of traditional methods that rely on fixed or static adjacency matrices.
[0109] Referring to step S, in order to effectively capture the interaction relationship between heterogeneous features and achieve adaptive fusion of multi-source information, this embodiment uses a dynamic dual-stream gating fusion module to perform spatiotemporal feature fusion. This module dynamically adjusts and fuses the spatiotemporal feature streams through a learnable gating strategy, thereby enhancing the model's adaptability to multidimensional information.
[0110] First, the temporal features obtained from the encoding Spatial features obtained by encoding By concatenating the feature dimensions, the two feature paths are combined into a joint feature representation, i.e.:
[0111] ;
[0112] Next, a learnable transformation matrix is introduced. And combined with the Sigmoid activation function to generate a dynamic gating weight matrix, that is:
[0113] ;
[0114] in, This represents the Sigmoid function, used to constrain the gate weights within the interval [0, 1]; this gate weight matrix can adaptively assign different fusion ratios to temporal and spatial features.
[0115] After obtaining the dynamic gating weights, a gating weighting strategy is used to weight and fuse the two feature streams to obtain the final joint feature representation:
[0116] ;
[0117] in, This represents an element-wise multiplication operation. Through this method, this embodiment can adaptively adjust the contribution ratio of temporal and spatial features at different time steps and dimensions, thereby achieving dynamic fusion of dual-stream features. Compared with traditional static fusion methods, the dynamic dual-stream gating fusion module proposed in this invention can dynamically allocate weights according to the context, enhancing the representation ability of complex traffic dynamic patterns while preserving the original feature structure, and providing a more robust joint feature input for subsequent predictive decoders.
[0118] Referring to step S4, to improve the accuracy of traffic flow prediction and effectively reduce the temporal distribution deviation between historical data and the prediction target, a spatiotemporal trend-aligned decoder is proposed. This decoder combines a trend-aligned attention mechanism with a dynamic graph convolution module for information integration, and employs a multi-step prediction strategy to enhance the model's ability to model complex traffic dynamics.
[0119] Specifically, the historical time is first embedded Embedded with future time The transformations are performed together to obtain the query Q, key K, and value V, i.e.:
[0120] ;
[0121] ;
[0122] ;
[0123] ;
[0124] in, This represents the spatiotemporal characteristics after fusion; This represents the fusion function.
[0125] Then, the attention weights are calculated using a trend-aligned attention mechanism to obtain the attention matrix. The results of each attention head are then concatenated, and the spatiotemporal trend-aligned feature representation is obtained through linear mapping. The specific calculation formula is as follows:
[0126] ;
[0127] ;
[0128] in, The projection matrix; This indicates a multi-head splicing operation; This represents the final bullish trend alignment feature representation;
[0129] Finally, the decoder input is... Alignment features with trends The result is obtained through residual connection fusion, i.e.:
[0130] ;
[0131] in, This represents the decoder input. Through this step, the decoder can effectively mitigate the problem of prediction error accumulation while maintaining the continuity of the prediction target.
[0132] To further improve prediction accuracy, this embodiment introduces a multi-step prediction strategy: using historical features As input to the decoder, and combined with the spatiotemporal meta-parameters of future time steps Perform feature fusion, that is:
[0133] ;
[0134] Subsequently, As input to the dynamic graph convolutional recursive unit, the prediction results for the next m time steps are computed in parallel over all future time steps. In this way, the model can predict traffic flow values for multiple future time steps in parallel, effectively reducing the impact of prediction errors accumulating over time. In summary, the spatiotemporal trend-aligned decoder proposed in this invention, through trend-aligned attention mechanism, multi-head attention stitching, and multi-step prediction strategy, can improve the model's ability to model and predict future traffic conditions while maintaining temporal consistency, providing more accurate short-term traffic flow prediction results for the overall system.
[0135] The present invention was tested on the California Highway Traffic Dataset (PEMS04, PEMS08) and the Manchester City Road Traffic Dataset (Manchester) in the United Kingdom to evaluate the performance of the proposed short-term traffic flow prediction method based on dynamic multidimensional global perception graph convolutional network (DMGGCN model).
[0136] In the performance evaluation process, this invention selected several representative benchmark models for comparative experiments, including VAR (Vector Autoregression); GRU (Gated Recurrent Unit); DCRNN (Diffused Convolutional Recurrent Neural Network); AGCRN (Adaptive Graph Convolutional Recurrent Neural Network); DSTAGNN (Dynamic Spatiotemporal Awareness Graph Neural Network); and STDN (Spatiotemporal Dynamic Network).
[0137] To ensure the scientific validity and reliability of the experimental results, this invention introduces several commonly used predictive performance evaluation metrics during model training and testing, including mean absolute error (MAE), root mean square error (RMSE), and mean absolute percentage error (MAPE).
[0138] The experiments of this invention compare four aspects: predictive performance comparison, ablation experiments, model efficiency study, and model parameter analysis.
[0139] To verify the effectiveness of the DMGGCN model in traffic prediction tasks, this invention conducted a comprehensive comparative analysis of prediction accuracy with various classic models on the PEMS04, PEMS08, and Manchester datasets. The results are shown in Table 1. The following conclusions can be drawn from the comparison: (1) Compared with statistical models such as VAR, DMGGCN can significantly reduce prediction errors. This is because statistical methods usually rely only on the assumption of linear stationarity, which is difficult to cope with the non-stationarity and complex dynamic changes in traffic flow data, so the prediction results fluctuate greatly. (2) Compared with the GRU model that only considers time dependence, graph-based models (such as DCRNN, AGCRN, and DSTAGNN) achieve higher accuracy by modeling spatial dependencies. Among them, AGCRN and DSTAGNN can characterize more flexible spatial topology with the help of adaptive adjacency matrices, and their performance is better than that of DCRNN with a fixed graph structure. (3) The STDN model has certain advantages in modeling periodic patterns through trend and seasonal decomposition mechanisms, but its response to short-term sudden traffic and dynamic local features is limited, and its prediction accuracy is still insufficient under complex road network conditions. (4) Compared with the above methods, DMGGCN effectively integrates global topological relationships and local dynamic features by introducing a dynamic multidimensional graph convolution structure, and combines a gating mechanism to achieve coordinated modeling of temporal dependencies and spatial propagation, thus better adapting to the dynamics and complexity of traffic flow signals. Therefore, DMGGCN demonstrates the best prediction performance on multiple datasets, verifying its practical value and advantages in complex traffic network environments.
[0140]
[0141] Table 1
[0142] Through ablation experiments, this invention verifies the impact of each component module on traffic prediction performance. Based on the DMGGCN model, six different variants were designed, and comparative experiments were conducted on two public datasets, PEMS04 and PEMS08. The characteristics of five variants are as follows:
[0143] (1) w / o T-encoder: Removes the time meta-parameter encoder and no longer explicitly models time dependencies.
[0144] (2) w / o S-encoder: Removes the spatial meta-parameter encoder, which weakens the ability to model the spatial dependence of traffic networks.
[0145] (3) w / o DDGA: The dynamic dual-stream gated fusion module is replaced with a simple feature splicing and weighting method, which reduces the precision of spatiotemporal feature fusion.
[0146] (4) w / o TAA: Replacing the trend-aware attention mechanism with a recursive multi-step prediction method weakens the model’s ability to model long-term trends.
[0147] (5) w / o TSTAD: Remove the spatiotemporal trend aligned decoder and use only the multilayer perceptron for multi-step prediction, ignoring the suppression effect of the decoding stage on error accumulation.
[0148] According to the experimental results in Table 3, the complete DMGGCN model achieved the lowest MAE, RMSE, and MAPE error metrics on both datasets, significantly outperforming all variant models. The performance degradation was most pronounced after removing the DDGA module, especially on the PEMS08 dataset where the error reached its highest value, indicating that an efficient dual-stream gating fusion mechanism is crucial for capturing complex spatiotemporal dependencies. Removing the T-encoder significantly increased the error, demonstrating the importance of temporal features for traffic flow prediction; removing the S-encoder led to insufficient spatial modeling, validating the necessity of spatial features. Removing TAA resulted in a significant increase in MAPE on the PEMS04 dataset and a significant increase in RMSE on the PEMS08 dataset, indicating that trend-aware attention plays a key role in capturing long-term dependencies and periodic patterns. Removing TSTAD also reduced prediction accuracy, particularly on the PEMS08 dataset, demonstrating that the decoding stage effectively suppresses error accumulation and improves multi-step prediction stability. In summary, each component module of the DMGGCN proposed in this invention plays an irreplaceable role in the overall architecture, and the synergistic effect between the modules significantly improves the predictive performance of the model, verifying the effectiveness and advancement of this method in complex traffic flow prediction tasks.
[0149]
[0150] Table 2
[0151] This invention further proposes to verify the contribution of the spatiotemporal embedding matrix to prediction performance. To this end, different model variants are designed to examine the roles of temporal and spatial embeddings in the prediction task, respectively:
[0152] (1) w / o Et: Replace the time embedding matrix with a static matrix of all 1s to eliminate heterogeneity modeling in the time dimension and to verify the importance of time information in prediction.
[0153] (2) w / o Es: Replace the spatial embedding matrix with a static matrix of all 1s to weaken the modeling of spatial heterogeneity, thereby analyzing the impact of spatial features on the prediction results.
[0154] (3) w / o Est: Replace both the time and space embedding matrices with static matrices of all 1s, while weakening the modeling of spatiotemporal information, in order to verify the overall value of spatiotemporal fusion modeling.
[0155] Experimental results on the PEMS04 and PEMS08 datasets show that, as Figure 2 As shown, the complete DMGGCN model proposed in this invention outperforms the three variants mentioned above on all evaluation metrics, demonstrating that the dynamic spatiotemporal embedding matrix can significantly improve prediction performance. Specifically: on the PEMS04 dataset, the variant that removes the time dimension and dynamically models has the largest error, indicating that temporal features play a crucial role in prediction tasks with shorter time scales. On the PEMS08 dataset, the variant that simultaneously removes both temporal and spatial information has the most significant error, further highlighting the necessity of dynamic spatiotemporal information fusion for improving prediction accuracy. Therefore, the complete model proposed in this invention maintains optimal performance on both datasets, thus confirming the important contribution of the dynamic spatiotemporal embedding matrix in traffic flow prediction.
[0156] This invention evaluates the computational efficiency of the proposed DMGGCN model on the Manchester traffic dataset and compares it with several representative graph convolution-based prediction models. Experimental results are as follows: Figure 3 As shown, while maintaining prediction accuracy, DMGGCN's training time and memory consumption are slightly increased compared to lightweight models, but it exhibits significantly higher efficiency compared to several high-complexity models. This additional overhead mainly comes from the spatiotemporal meta-parameter encoder introduced in this invention, which significantly enhances the model's ability to capture complex spatiotemporal dependencies, thereby improving prediction performance.
[0157] It is worth noting that this invention effectively controls model size and resource consumption by designing a meta-parameter pool, enabling DMGGCN to maintain high training efficiency and low hardware overhead while ensuring strong representational capabilities. Compared with direct optimization in a large-scale parameter space, this invention not only improves computational efficiency but also enhances the model's scalability and practicality in large-scale spatiotemporal prediction tasks. Therefore, this invention achieves a balance between performance and efficiency in handling high-dimensional traffic data modeling problems, providing a solution for practical applications that combines accuracy and computational feasibility.
[0158] In the implementation of this invention, to further verify the impact of key model parameters on prediction performance, a sensitivity analysis was performed on the spatiotemporal embedding dimension, and experimental evaluations were conducted on three heterogeneous traffic datasets (PEMS04, PEMS08, and Manchester). The experimental results are as follows: Figure 4As shown, it can be observed that the prediction error (MAE, MAPE) exhibits a nonlinear trend with the change of embedding dimension, indicating that this parameter has a significant impact on model performance.
[0159] The spatial embedding dimension exhibits a convexity effect on the model's prediction accuracy. On the PEMS04 dataset, a spatial embedding dimension of 10 yields optimal results; on the PEMS08 dataset, the optimal value is 5; and on the Manchester dataset, the optimal value is 12. Insufficient spatial embedding dimension makes it difficult for the model to adequately characterize the spatial correlations in the road network, leading to underfitting; while excessively high spatial embedding dimension introduces redundant features, increases noise, and degrades performance.
[0160] The impact of temporal embedding dimension on different datasets shows significant regional differences. The optimal temporal embedding dimensions for the PEMS04, PEMS08, and Manchester datasets are 24, 20, and 20, respectively. This indicates that traffic patterns in different regions differ in temporal complexity, and a reasonable temporal embedding dimension can better capture local and global temporal dependencies.
[0161] Comprehensive experimental results demonstrate that appropriately selecting the embedding dimension is crucial for balancing feature representation ability and model generalization ability. If the embedding dimension is too small, it can easily lead to underfitting; if the embedding dimension is too large, it increases the risk of overfitting and reduces prediction accuracy. Therefore, this invention proposes that in practical applications, the embedding dimension parameter should be fine-tuned for specific datasets to obtain optimal prediction performance and stronger adaptability.
[0162] The present invention has been described above by way of example with reference to the accompanying drawings. Obviously, the specific implementation of the present invention is not limited to the above-described manner. Any non-substantial improvements made using the inventive concept and technical solution; or the direct application of the inventive concept and technical solution to other situations without modification, are all within the protection scope of the present invention.
Claims
1. A short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network, characterized in that: The method includes the following steps: Step S1: Obtain the input dynamic graph feature sequence And generate spatiotemporal meta-parameters; where t represents the time step and P represents the sequence length; Step S2: After feature enhancement of the dynamic graph feature sequence, it is fused with the spatiotemporal meta-parameters, and then spatiotemporal feature encoding is performed separately; Step S3: Fuse the spatiotemporal features obtained from the spatiotemporal feature encoding; Step S4: Decode the spatiotemporal trend alignment of the fused spatiotemporal features.
2. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 1, characterized in that: Step S1 includes: In the time dimension, the temporal embedding representation matrix is constructed as follows: The periodic embedding representation matrix is ,in, Indicates the time step of a day. Indicates the number of cycles. Indicates the time embedding dimension; For any given time t, using the index function and The corresponding time position codes are extracted from the time embedding matrix and the periodic embedding matrix, and combined to obtain the final time embedding matrix as follows: ; in, This represents the Hadamard element-wise product; In the spatial dimension, a spatial embedding matrix is introduced. Where N is the number of road network nodes, Embedding dimensions into space.
3. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 2, characterized in that: Step S1 further includes: dynamically generating meta-parameters for the temporal embedding matrix and the spatial embedding matrix respectively through a dynamic adjustment mechanism based on meta-parameters, including: Construct a low-rank parameter pool ,in, Indicates the dimension of the meta-parameter. The size of the set of learnable parameters; For any query vector Generate meta-parameters ,Right now: ; Correspondingly, in the time dimension, for the time embedding matrix B represents the number of rows in the matrix, obtained through the time meta-parameter pool. Mapped to time meta-parameters In the spatial dimension, for a spatial embedding matrix Through the spatial meta-parameter pool Mapping to spatial meta-parameters .
4. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 3, characterized in that: The feature enhancement in step S2 includes: For the input dynamic graph feature sequence Perform nonlinear mapping: ; in, This represents the feature encoding function, which uses a multilayer perceptron structure to encode features from the input dynamic graph feature sequence. Perform a nonlinear transformation to obtain the corresponding enhanced features. .
5. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 4, characterized in that: In step S2, for the enhanced features Temporal features obtained by fusing with time meta-parameters The encoding is performed through a gating mechanism, and the gating mechanism update process is as follows: ; ; ; ; in, This indicates that the door is being reset. Indicates an update to the door. Indicates candidate gates, Indicates a hidden state; This represents the Sigmoid activation function; It is the hyperbolic tangent activation function; , , , , , All are learnable parameters; This represents the element-wise multiplication operation; This represents matrix multiplication.
6. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 5, characterized in that: In step S2, For enhanced features Spatial features obtained after fusing with time meta-parameters The spatial dependencies of the traffic network are modeled by introducing dynamic graph convolution operations, which are as follows: ; in, Representation of features The output after dynamic graph convolution operation; It is the identity matrix; Degree matrix; b represents the graph convolution kernel parameters; b represents the bias term. The adjacency matrix of a dynamic graph is represented as follows: ; in, Indicates enhanced features; This represents the introduced learnable spatial embedding matrix, which is obtained by fusing spatial meta-parameters with the original spatial embedding matrix. This represents the modified linear unit activation function.
7. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 6, characterized in that: Step S3 includes: performing spatiotemporal feature fusion through a dynamic dual-stream gated fusion module, including: Temporal features obtained from encoding Spatial features obtained by encoding By concatenating the feature dimensions, the two feature paths are combined into a joint feature representation, i.e.: ; Next, a learnable transformation matrix is introduced. And combined with the Sigmoid activation function to generate a dynamic gating weight matrix, that is: ; in, This represents the Sigmoid function, used to constrain the gate weights within the interval [0, 1]. After obtaining the dynamic gating weights, a gating weighting strategy is used to weight and fuse the two feature streams to obtain the final joint feature representation: ; in, This indicates an element-wise multiplication operation.
8. The short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 7, characterized in that: Step S4 includes: Embedding historical time Embedded with future time The transformations are performed together to obtain the query Q, key K, and value V, i.e.: ; ; ; ; in, This represents the spatiotemporal characteristics after fusion; Indicates the fusion function; Then, the attention weights are calculated using a trend-aligned attention mechanism to obtain the attention matrix. The results of each attention head are then concatenated, and a spatiotemporal trend-aligned feature representation is obtained through linear mapping. The specific calculation formula is as follows: ; ; in, The projection matrix; This indicates a multi-head splicing operation; This represents the final bullish trend alignment feature representation; Ultimately, the decoder input is... Alignment features with trends The result is obtained through residual connection fusion, i.e.: ; in, This represents the decoder input.
9. A short-term traffic flow prediction method based on a dynamic multidimensional global perception graph convolutional network according to claim 8, characterized in that: Step S4 further includes: introducing a multi-step prediction strategy: using historical features As input to the decoder, and combined with the spatiotemporal meta-parameters of future time steps Perform feature fusion, that is: ; in, The calculation method is as follows: ; In the formula, It is a feature encoder, which adopts a fully connected network structure and uses the Sigmoid activation function to enhance feature representation ability; Represents the time embedding matrix; Represents the spatial embedding matrix; Represents the spatiotemporal meta-parameter pool; Subsequently, As input to the dynamic graph convolutional recursive unit, the prediction results for the next m time steps are computed in parallel over all future time steps.
Citation Information
Cited By
Space-time traffic flow prediction method based on double-flow decoupling
CN122090626A