Traffic flow prediction method based on dynamic graph convolution circulation network

Through the improved method of dynamic graph convolution recurrent network, combined with dynamic graph generation and residual correction module, the problem of neglecting spatial and temporal dynamic correlation in traffic flow prediction is solved, and the prediction accuracy is improved.

CN120279714AActive Publication Date: 2025-07-08JIAHE CO CREATION (DALIAN) INFORMATION TECHNOLOGY CO LTD

Patent Information

Application Number
CN202510764002.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-10
Publication Date
2025-07-08
Estimated Expiration
2045-06-10

AI Technical Summary

Technical Problem

The existing traffic flow prediction methods ignore the spatial and temporal correlation in traffic flow, resulting in inaccurate prediction.

Method used

Using a method based on dynamic graph convolution recurrent network, the adaptive graph convolution recurrent network AGCRN model is used, combined with the dynamic graph generation module and the residual correction module, to capture the spatiotemporal characteristics of the traffic network and gradually refine the traffic change mode.

Benefits of technology

It improves the accuracy of traffic flow prediction, can better capture the dynamic characteristics and spatial relationships of the traffic network, and enhances the model's evaluation ability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120279714A_ABST
    Figure CN120279714A_ABST
Patent Text Reader

Abstract

The invention discloses a traffic flow prediction method based on a dynamic graph convolution circulation network, and belongs to the technical field of traffic information. The method comprises the following steps: acquiring historical traffic flow data, preprocessing the historical traffic flow data, and constructing a data set; an AGCRN model is improved, firstly, a dynamic filter of a self-attention mechanism is added to a graph generation part of an AGCRN to capture dynamic spatial features, and then a dynamic graph generation module is added to a gating recursive unit part to capture periodic time dependence. And finally, adding a residual error correction module into the AGCRN to carry out error feature extraction. Training the improved AGCRN model until a predetermined performance index is reached, and obtaining a traffic flow prediction model; and predicting the traffic flow of the traffic network by using the traffic flow prediction model. According to the method, the graph convolutional network is improved, so that the prediction accuracy of the traffic network flow is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of traffic information technology, and specifically, relates to a traffic flow prediction method based on a dynamic graph convolutional recurrent network. Background Art

[0002] With the rapid development of social economy and urbanization, the number of urban cars shows an explosive growth trend, the traffic flow is increasing day by day, resulting in frequent traffic jams and traffic accidents, which brings many challenges to urban management and residents' lives. Therefore, accurate traffic prediction is particularly important, and accurately and timely predicting traffic flow has become an urgent task in the research of the intelligent transportation field in the big data era.

[0003] However, the traffic road network itself has complex spatio-temporal characteristics, which makes traffic flow prediction a very challenging task. Most of the existing methods rely on predefined static adjacency matrices, and often process spatial features and temporal features separately, ignoring the coupling relationship between the two, which causes the model to be unable to accurately capture the complex spatio-temporal dynamic correlations in traffic flow. Therefore, how to capture high-accuracy spatio-temporal dynamic correlations is the key to its practical application. Summary of the Invention

[0004] The purpose of the present invention is to propose a traffic flow prediction method based on a dynamic graph convolutional recurrent network to improve the prediction accuracy of traffic flow in order to solve the problems existing in the existing traffic flow prediction.

[0005] To achieve the above purpose, the technical solution provided by the present invention is as follows: A traffic flow prediction method based on a dynamic graph convolutional recurrent network, including the following steps: S1: Obtain historical traffic flow data, preprocess it using the sliding window method, and construct a data set; S2: Based on the Adaptive Graph Convolutional Recurrent Network (AGCRN) model as the basic model, embed a dynamic graph generation module before the Gated Recurrent Unit (GRU) in the encoder-decoder of the basic model to obtain a dynamic graph convolutional gated recurrent unit. At least two dynamic graph convolutional gated recurrent units are stacked to form a dynamic graph convolutional recurrent module, and the output of the previous-stage dynamic graph convolutional gated recurrent unit is used as the input of the next stage, and a dynamic filter based on the self-attention mechanism is added to the dynamic graph generation module; at the same time, a residual correction module is added to the tail of the basic model; the residual correction module is configured to receive the first-stage prediction result output by the encoder-decoder and the original model input, calculate a residual signal according to the first-stage prediction result and the original model input, perform secondary encoding and decoding correction on the residual signal to obtain a second-stage prediction result, and add the two-stage prediction results together to synthesize the final traffic flow prediction result; S3: Train the improved Adaptive Graph Convolutional Recurrent Network (AGCRN) model until the predetermined performance metrics are achieved to obtain a traffic flow prediction model; S4: Use the traffic flow prediction model to predict the traffic flow of the traffic road network.

[0006] Furthermore, in step S1, the process of preprocessing using the sliding window method is as follows: The time series data is segmented into input-output sample pairs according to a historical window of 12 time steps. Each input is 12 consecutive time steps, and the output is the next 12 time steps.

[0007] Furthermore, the improved Adaptive Graph Convolutional Recurrent Network (AGCRN) model includes a model input layer, a primary encoder-decoder, and a residual correction module. The model input layer performs node embedding learning based on the input historical traffic flow data to generate initial node embeddings. Then, the historical traffic flow data and the initial node embeddings are jointly input into the primary encoder-decoder and the residual correction module. The encoder in the primary encoder-decoder first extracts features from the historical traffic flow data through a dynamic graph convolutional recurrent module, then performs residual connection and layer normalization, and then performs residual connection and layer normalization again after passing through the hidden layer to achieve encoding. The decoder in the primary encoder-decoder first extracts features from the historical traffic flow data through a dynamic graph convolutional recurrent module, then performs residual connection and layer normalization, then aligns with the output of the encoder through a multi-head attention layer, then performs residual connection and layer normalization, and finally performs residual connection and layer normalization again after passing through the hidden layer to decode the first-stage prediction result. Finally, the historical traffic flow data and the first-stage prediction result are processed by the residual correction module to obtain the final traffic flow prediction result; It should be noted that the historical traffic flow data and the initial node embeddings as the original input are directly input separately. The primary encoder-decoder and the residual correction module extract the features of the historical traffic flow data, and the initial node embeddings are used to assist in feature extraction.

[0008] Among them, the primary encoder-decoder includes encoders and decoders. The encoders are stacked in order, and each encoder processes the output of the previous stage to gradually extract higher-order features; The decoders are connected in series in the generation order; the output of the previous decoder is used as the input of the next decoder.

[0009] The residual correction module includes a residual signal extraction layer, a secondary encoder-decoder, and a prediction result merging layer, and the secondary encoder-decoder has the same internal network structure as the primary encoder-decoder.

[0010] Furthermore, the following formula is run in the dynamic graph generation module: ; ; ; ; Among them, is the dynamic signal obtained after filtering at time step ; represents the activation function; , and are the query matrix, key matrix, and value matrix respectively; represents matrix transpose; is the embedding dimension; represents the activation function; represents the element-wise multiplication operation; the dynamic signal is multiplied element-wise with the initial node embedding to generate the dynamic node embedding at time step ; is the dynamic Laplacian matrix at time step , which is generated by calculating the similarity between nodes and performing normalization through the construction method of the Laplacian matrix; the normalization process of the Laplacian matrix is a prior art and will not be elaborated here; represents the activation function; is the degree matrix; is the input at time step ; the static adjacency matrix is the initialized support matrix, combined with to calculate through multi-channel graph convolution to obtain the dynamic graph convolution feature , where is the weight, is the bias matrix, is matrix concatenation.

[0011] Furthermore, the following formula is run in the dynamic graph convolutional gated recurrent unit: ; ; ; where is the input at time step ; is the output at time step ; represents the sigmoid activation function, represents feature concatenation, represents matrix splitting to split out the update gate and the reset gate , is the dynamic graph generation module, and the candidate hidden state is calculated through the input features and the updated hidden state, and the final hidden state is obtained by weighted update according to the reset gate and the candidate hidden state The residual correction module operates according to the following formula:

[0012] ; ; ; ; where is the output of the primary encoder-decoder, and the first-stage prediction result is obtained through spatio-temporal convolution , is spatio-temporal convolution, and the secondary stage performs secondary modeling on the residual signal, is the input of the original model, is the secondary encoder-decoder, and the secondary prediction result is obtained through residual calculation ; The two-stage prediction results are combined to obtain the final prediction .

[0013] Compared with the prior art, the traffic flow prediction method based on the dynamic graph convolutional recurrent network proposed by the present invention has the following advantages: 1. The dynamic graph generation method provided by the present invention is for the generation of the dynamic graph structure. The generation method of the dynamic graph structure can model the relationship between any two positions in the sequence through the self-attention mechanism, adaptively assign importance to different elements in the input of the dynamic graph generation module, realize the adaptive construction and dynamic update of the graph structure, enhance the representation ability of important information, and improve the accuracy of model evaluation; 2. The dynamic graph convolutional gated recurrent unit provided by the present invention can capture the spatial and temporal characteristics in the dynamic traffic network, and improve the accuracy of model evaluation; 3. The residual correction module provided by the present invention gradually refines the traffic flow change pattern through a two-stage prediction mechanism, and improves the accuracy of model evaluation; In summary, the method proposed by the present invention improves the prediction accuracy of traffic flow and can be popularized in the field of traffic flow prediction. Brief Description of the Drawings

[0014] Figure 1Flow chart of the traffic flow prediction method based on the dynamic graph convolutional recurrent network of the present invention; Figure 2 Schematic diagram of the network structure of the improved AGCRN model adopted by the present invention; Figure 3 Schematic diagram of the network structure of the dynamic graph convolutional recurrent module; Figure 4 Flow chart of the dynamic graph generation method adopted by the present invention; Figure 5 Schematic diagram of the structure of the dynamic graph generation module of the present invention; Figure 6 Schematic diagram of the structure of the dynamic graph convolutional gated recurrent unit of the present invention; Figure 7 Flow chart of the working process of the residual correction module adopted by the present invention; Figure 8 Training and validation loss graph of the improved AGCRN model of the present invention; Figure 9 Model evaluation result graph of the index value of the improved AGCRN model of the present invention on the PEMS04 dataset. Detailed implementation manners

[0015] To make the objectives, features, and advantages of the present invention more obvious and understandable, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the present invention is not limited by the following embodiments, and the specific implementation manners can be determined according to the technical solutions of the present invention and the actual situation. In order to avoid confusing the essence of the present invention, well-known methods, processes, and procedures are not described in detail.

[0016] The present invention first adds a dynamic filter based on the self-attention mechanism to the graph generation part of the adaptive graph convolutional recurrent network AGCRN to capture dynamic spatial features, then adds a dynamic graph generation module to the gated recurrent unit part to capture periodic time dependencies, and finally adds a residual correction module to the adaptive graph convolutional recurrent network AGCRN to extract error features, effectively improving the prediction accuracy of traffic flow.

[0017] Figure 1 The flow schematic diagram of the traffic flow prediction method based on the dynamic graph convolutional recurrent network is shown, and the specific steps of the method are as follows: S1: Obtain historical traffic flow data, preprocess it, and construct a data set; S1-1: Obtain historical traffic flow data, and the source of the historical traffic flow data is the traffic flow data obtained through road sensors or a public data set. The public data set PEMS04 is adopted in the present invention; S1-2: Preprocess the PEMS04 dataset, segment it in the way of a sliding window. The historical window data of every 12 time steps forms the input vector of the model, which is used to predict the data of the next 12 time steps (that is, segment the time series data into input-output sample pairs according to a historical window of 12 time steps. Each input is 12 consecutive time steps, and the output is the next 12 time steps).

[0018] S2: Improve the Adaptive Graph Convolutional Recurrent Network (AGCRN) to obtain an improved AGCRN model. The schematic diagram of the network structure of the improved AGCRN model is as Figure 2 shown, including a model input layer, a primary encoder-decoder, and a residual correction module. The model input layer performs node embedding learning based on the input historical traffic flow data to generate an initial node embedding, and then inputs the historical traffic flow data and the initial node embedding into the primary encoder-decoder and the residual correction module together. Among them, the primary encoder-decoder includes encoders and decoders. The encoders are stacked in order. Each encoder processes the output of the previous stage and gradually extracts higher-order features. The decoders are connected in series according to the generation order. The output of the previous decoder is used as the input of the next decoder. The encoders in the primary encoder-decoder first perform feature extraction on the historical traffic flow data through a dynamic graph convolutional recurrent module, then perform residual connection and layer normalization, and then perform residual connection and layer normalization again after passing through a hidden layer to achieve encoding. The decoders in the primary encoder-decoder first perform feature extraction on the historical traffic flow data through a dynamic graph convolutional recurrent module, then perform residual connection and layer normalization, then align with the output of the encoder through a multi-head attention layer, then perform residual connection and layer normalization, and finally perform residual connection and layer normalization again after passing through a hidden layer to decode and obtain the first-stage prediction result. Finally, the historical traffic flow data and the first-stage prediction result are processed by the residual correction module to obtain the final traffic flow prediction result. As Figure 2 shown, the residual correction module includes a residual signal extraction layer, a secondary encoder-decoder, and a prediction result merging layer, and the secondary encoder-decoder has the same internal network structure as the primary encoder-decoder.

[0019] As Figure 3 shown, the dynamic graph convolutional recurrent module is composed of stacked dynamic graph convolutional gated recurrent units, and the output of the previous dynamic graph convolutional gated recurrent unit is used as the input of the next dynamic graph convolutional gated recurrent unit. A dynamic graph generation module is embedded in the dynamic graph convolutional gated recurrent unit, and a dynamic filter based on the self-attention mechanism is added to the dynamic graph generation module.

[0020] S2-1: Add a dynamic filter based on the self-attention mechanism after the input part of the dynamic graph generation module, and put the preprocessed traffic flow data (which is a four-dimensional vector , is the batch size, indicating the number of samples input in one training; represents the time length of the input sequence; is the number of nodes, indicating the number of sensor nodes in the traffic network; is the hidden state dimension, indicating the feature dimension of each node in the model) into the dynamic filter for processing to obtain a dynamic signal; then, multiply it element-wise with the initial node embedding to obtain a dynamic node embedding; then, generate a dynamic adjacency matrix through the dynamic node embedding; finally, obtain the dynamic graph convolution feature through convolution calculation. It should be noted that the initial node embedding refers to the initial vector representation given to the nodes before the start of model training, which belongs to the prior art and will not be elaborated in detail.

[0021] In the step S2-1, the dynamic graph generation module is improved, and the specific steps are as follows: In the dynamic graph generation, a dynamic filter based on the self-attention mechanism is used. After the data is input, it first undergoes filtering processing by the dynamic filter based on the self-attention mechanism, and then the dynamic graph convolution feature is obtained through graph convolution calculation with the Chebyshev polynomial as the kernel. The self-attention mechanism can model the relationship between any two positions in the sequence, adaptively assign importance to different elements in the input of the dynamic graph generation module, and enhance the representation ability of important information.

[0022] Figure 4 The flowchart of the dynamic graph generation method proposed according to the embodiments of the present invention is shown. The traffic flow data first generates an initial node embedding through node embedding learning, then obtains spatio-temporal attention through the dynamic filter, and then generates a dynamic graph according to the attention weights.

[0023] The formula calculation of the dynamic graph structure generation of the present invention is as follows: (1); (2); (3); (4); Among them, is the dynamic signal obtained after filtering at time step ; represents the activation function; , and They are the query matrix, the key matrix, and the value matrix respectively; represents matrix transpose; is the embedding dimension; represents the activation function; represents the element-wise multiplication operation; dynamic signal and the initial node embedding are multiplied element-wise to generate the dynamic node embedding at the time step ; is at the time step the dynamic Laplacian matrix, which is generated by calculating the similarity between nodes and is standardized through the construction method of the Laplacian matrix; the standardization process of the Laplacian matrix is a prior art and will not be elaborated here; represents the activation function; is the degree matrix; is the time step input of; static adjacency matrix is the initialized support matrix, combined with is calculated through multi-channel graph convolution to obtain the dynamic graph convolution feature , where is the weight, is the bias matrix, is matrix concatenation.

[0024] Figure 5 shows the structural schematic diagram of the dynamic graph generation module proposed according to the example of the present invention.

[0025] S2-2: The dynamic graph convolution recurrent module is composed of multiple stacked dynamic graph convolution gated recurrent units. After dynamic graph generation and gated calculation, the output of the dynamic graph convolution recurrent module is obtained.

[0026] In the step S2-2, the part of the dynamic graph convolution gated recurrent unit is improved. A variant of the GRU technology is used in the dynamic graph convolution recurrent network. The dynamic graph generation module is combined with the GRU to obtain the dynamic graph convolution gated recurrent unit, which takes the dynamic spatial relationship and time series change between nodes as the core and can capture the spatial and temporal characteristics in the dynamic traffic network. It should be noted that GRU (Gated Recurrent Unit) is an improved recurrent neural network (RNN) and belongs to the prior art.

[0027] The structure of the dynamic graph convolution gated recurrent unit (AGCRU) of the present invention is as Figure 6 shown, Figure 6 in is the dynamic graph convolution gated recurrent unit at the time step The input of is the input of the dynamic graph convolutional gated recurrent unit at time step The input of is the input of the dynamic graph convolutional gated recurrent unit at time step where is an abbreviation of which is the initial node embedding, and (5); (6); (7); where is the input at time step ; is the output at time step ; represents the sigmoid activation function, represents feature concatenation, represents matrix splitting to split out the update gate and the reset gate , is the dynamic graph generation module, and the candidate hidden state is calculated from the input features and the updated hidden state. The final hidden state is obtained by weighted update according to the reset gate and the candidate hidden state .

[0028] S2-3: Improve the adaptive graph convolutional recurrent network (AGCRN) network part, add a residual correction module after the network main body, and train the optimized network; In the step S2-3, improve the adaptive graph convolutional recurrent network (AGCRN) network part, add a residual correction module after the network main body for time series prediction, and form a dual encoder-decoder residual architecture. After the residual correction calculation of the first-stage prediction result and the original model input, it is sent to the secondary encoder-decoder for error feature extraction.

[0029] The residual correction module of the present invention is calculated as follows: (8); (9); (10); where is the output of the primary encoder-decoder, and the first-stage prediction result is obtained through spatio-temporal convolution, is a spatio-temporal convolution. In the second stage, the residual signal is modeled again. is the original model input. is the secondary encoder-decoder, and the secondary prediction result is obtained through residual calculation. ; The two-stage prediction results are combined to obtain the final prediction. This structure gradually refines the traffic flow change pattern through a two-stage prediction mechanism, and is especially suitable for dynamic adaptation to sudden traffic events.

[0030] The flowchart of the residual correction module of the present invention is specifically as Figure 7 shown.

[0031] S3: Train the improved AGCRN model until the improved AGCRN model reaches a predetermined performance index to obtain a trained traffic flow prediction model; In the step S3, when training the improved AGCRN model, set the number of iterations to 300, use the early stopping mechanism, set the patience value to 15, the initial learning rate to 0.003, and the number of batch sizes to 64. During the training process, the loss function used is .

[0032] The training loss and validation loss results of the PEMS04 dataset (PEMS04 Dataset) of the present invention are as Figure 8 shown, and it can be seen that the loss function and its convergence speed of this model are both very good.

[0033] The metrics used in the present invention are three common metrics for measuring the performance of a prediction model: Mean Absolute Error ( ): is the average of the absolute errors between the predicted value and the true value. It is less sensitive to outliers and reflects the average prediction error. The calculation formula is as follows: (11); where is the predicted value of the th sample, is the true value of the th sample, is the number of samples.

[0034] Root Mean Square Error ( ): is the square root of the average of the squared errors between the predicted value and the true value. It punishes larger errors more severely and can better reflect the performance of the model in the case of larger errors. The calculation formula is as follows: (12); where is the predicted value of the th sample, is the true value of the th sample, is the number of samples.

[0035] Mean Absolute Percentage Error ( ): is the average of the absolute percentage errors between the predicted values and the true values. It provides a measure of the relative error and is easy to compare with other datasets or models. The calculation formula is as follows: (13); where is the predicted value of the th sample, is the true value of the th sample, is the number of samples.

[0036] The values of these three metrics of this model are as Figure 9 shown.

[0037] Table 1 is a comparison table of this model and existing pose evaluation models.

[0038] Table 1 Comparison Table of this Model and Existing Pose Evaluation Models

[0039]

[0040] The numerical values of the comparison models and the specific content of the models are publicly available at: Comparison Model [1]: Weng W, Fan J, Wu H, et al. A decomposition dynamic graph convolutional recurrent network for traffic forecasting[J]. Pattern Recognition, 2023, 142: 109670. (Weng W, Fan J, Wu H, etc. A decomposition dynamic graph convolutional recurrent network for traffic forecasting[J]. Pattern Recognition, 2023, 142: 109670.) Comparison Model [2]: Choi J, Choi H, Hwang J, et al. Graph neural controlled differential equations for traffic forecasting[C] / / Proceedings of the AAAI Conference on artificial intelligence. 2022, 36(6): 6367-6374. (Choi J, Choi H, Hwang J, etc. Graph Neural Controlled Differential Equations for Traffic Forecasting[C] / / Proceedings of the AAAI Conference on Artificial Intelligence. 2022, 36(6): 6367-6374.) Comparison Model [3]: Fang Z, Long Q, Song G, et al. Spatial-temporal graph ode networks for traffic flow forecasting[C] / / Proceedings of the 27th ACM SIGKDD conference on knowledge discovery & data mining. 2021: 364-373. (Fang Z, Long Q, Song G, etc. Spatial-Temporal Graph ODE Networks for Traffic Flow Forecasting[C] / / Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery and Data Mining. 2021: 364-373.) Comparison Model [4]: Bai L, Yao L, Li C, et al. Adaptive graph convolutional recurrent network for traffic forecasting[J]. Advances in neural information processing systems, 2020, 33: 17804-17815. (Bai L, Yao L, Li C, etc. Adaptive Graph Convolutional Recurrent Network for Traffic Forecasting[J]. Advances in Neural Information Processing Systems, 2020, 33: 17804-17815.) Comparison model [5]: Song C, Lin Y, Guo S, et al. Spatial-temporal synchronous graph convolutional networks: A new framework for spatial-temporal network data forecasting[C] / / Proceedings of the AAAI conference on artificial intelligence. 2020, 34(01): 914-921. (Song C, Lin Y, Guo S, etc. Spatial-temporal synchronous graph convolutional networks: A new framework for spatial-temporal network data forecasting[C] / / Proceedings of the AAAI conference on artificial intelligence. 2020, 34(01): 914-921.) S4: Use the trained traffic flow prediction model to predict the traffic flow.

[0041] As can be seen from Table 1, the accuracy of this model is higher than that of the existing traffic flow prediction models.

[0042] The present invention is described by way of some embodiments. It is known to those skilled in the art that, without departing from the spirit and scope of the present invention, various changes or equivalent replacements can be made to these features and embodiments. Additionally, under the teachings of the present invention, these features and embodiments can be modified to adapt to specific situations and materials without departing from the spirit and scope of the present invention. Therefore, the present invention is not limited by the specific embodiments disclosed herein, and all embodiments falling within the scope of the claims of this application belong to the scope protected by the present invention.

Claims

1. A traffic flow prediction method based on a dynamic graph convolutional recurrent network, characterized in that It includes the following steps: S1: Obtain historical traffic flow data, preprocess it using the sliding window method, and construct a data set; S2: Based on the Adaptive Graph Convolutional Recurrent Network (AGCRN) model, embed a dynamic graph generation module before the Gated Recurrent Unit (GRU) in the encoder-decoder of the basic model to obtain a dynamic graph convolutional gated recurrent unit. At least two dynamic graph convolutional gated recurrent units are stacked to form a dynamic graph convolutional recurrent module, and the output of the previous-stage dynamic graph convolutional gated recurrent unit is used as the input of the next stage. A dynamic filter based on the self-attention mechanism is added to the dynamic graph generation module; at the same time, a residual correction module is added to the end of the basic model. The residual correction module is configured to receive the first-stage prediction result and the original model input, calculate the residual signal according to the first-stage prediction result and the original model input, perform secondary encoding and decoding correction on the residual signal to obtain the second-stage prediction result, and add the two-stage prediction results together to synthesize the final traffic flow prediction result; S3: Train the improved Adaptive Graph Convolutional Recurrent Network (AGCRN) model until a predetermined performance index is reached to obtain a traffic flow prediction model; S4: Use the traffic flow prediction model to predict the traffic flow of the traffic road network.

2. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 1, characterized in that In step S1, the process of preprocessing using the sliding window method is as follows: The time series data is segmented into input-output sample pairs according to a historical window of 12 time steps. Each input is 12 consecutive time steps, and the output is the next 12 time steps.

3. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 1, wherein The improved Adaptive Graph Convolutional Recurrent Network (AGCRN) model includes a model input layer, a primary encoder-decoder, and a residual correction module. The model input layer performs node embedding learning based on the input historical traffic flow data to generate an initial node embedding, and then inputs the historical traffic flow data and the initial node embedding into the primary encoder-decoder and the residual correction module together. The encoder in the primary encoder-decoder first extracts features from the historical traffic flow data through the dynamic graph convolutional recurrent module, then performs residual connection and layer normalization, and then performs residual connection and layer normalization again after passing through the hidden layer to achieve encoding; the decoder in the primary encoder-decoder first extracts features from the historical traffic flow data through the dynamic graph convolutional recurrent module, then performs residual connection and layer normalization, then aligns with the output of the encoder through the multi-head attention layer, then performs residual connection and layer normalization, and finally performs residual connection and layer normalization again after passing through the hidden layer to decode and obtain the first-stage prediction result; finally, the historical traffic flow data and the first-stage prediction result are processed by the residual correction module to obtain the final traffic flow prediction result.

4. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 3, wherein The first-level codec includes encoders and decoders. The encoders are stacked in order, and each encoder processes the output of the previous stage; The decoders are connected in series in the order of generation; the output of the previous decoder is used as the input of the next decoder.

5. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 4, wherein The residual correction module includes a residual signal extraction layer, a secondary encoder-decoder, and a prediction result merging layer, and the secondary encoder-decoder has the same internal network structure as the primary encoder-decoder.

6. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 1, characterized in that The following formula runs in the dynamic graph generation module: ; ; ; ; Among them, is the dynamic signal obtained after filtering at the time step ; represents the activation function; , and are the query matrix, key matrix, and value matrix respectively; represents matrix transpose; is the embedding dimension; represents the activation function; represents the element-wise multiplication operation; the dynamic signal is element-wise multiplied by the initial node embedding to generate the dynamic node embedding at the time step ; is the dynamic Laplacian matrix at the time step , which is generated by calculating the similarity between nodes and performing normalization through the construction method of the Laplacian matrix; represents the activation function; is the degree matrix; is the input at the time step ; the static adjacency matrix is the initialized support matrix, which is combined with and calculated through multi-channel graph convolution to obtain the dynamic graph convolution feature , where is the weight, is the bias matrix, and is matrix concatenation.

7. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 1, wherein The following formula runs in the dynamic graph convolutional gated recurrent unit: ; ; ; where is the input at time step ; is the output at time step ; represents the sigmoid activation function, represents feature concatenation, represents matrix splitting to split out the update gate and the reset gate , is the dynamic graph generation module, and the candidate hidden state is calculated from the input features and the updated hidden state, and the final hidden state is obtained by weighted update according to the reset gate and the candidate hidden state .

8. The traffic flow prediction method based on a dynamic graph convolutional recurrent network according to claim 1, wherein The following formula runs in the residual correction module: ; ; ; Among them is the output of the primary codec, and the primary stage prediction result is obtained through spatio-temporal convolution , is the spatio-temporal convolution, and the secondary stage performs secondary modeling on the residual signal is the original model input is the secondary codec, and the secondary prediction result is obtained through residual calculation ; The two-stage prediction results are combined to obtain the final prediction .

Citation Information

Patent Citations

  • Traffic flow prediction method and device based on dynamic space-time diagram convolution circulation network, and storage medium

    CN114220271A

  • Rail transit passenger flow prediction model and method of adaptive graph convolutional recurrent neural network combined with attention mechanism

    CN115423189A

  • Method for predicting traffic flow by using spatial dynamic graph convolutional network

    CN115482656A

  • Multi-view fusion space-time dynamic graph convolutional network urban traffic flow prediction method

    CN116935649A

  • Periodic adaptive graph convolution circulation network traffic flow prediction method

    CN117291780A

Cited By

  • Photovoltaic energy storage joint optimization scheduling method and system based on deep reinforcement learning

    CN120875494A

  • Photovoltaic energy storage joint optimization scheduling method and system based on deep reinforcement learning

    CN120875494B

  • Wafer test offset detection method and system and storage medium

    CN120995897A

  • Abnormal traffic flow prediction method and system based on multi-scale spatial-temporal feature fusion

    CN121583097A