Traffic flow prediction method based on long-period multi-dimensional feature fusion

By using a method based on long-period multi-dimensional feature fusion and employing graph convolutional networks and self-attention mechanisms, the problem of temporal dependence and spatial correlation in traffic flow prediction was solved, achieving high-precision traffic flow prediction and optimizing traffic management.

CN120977121APending Publication Date: 2025-11-18SHANDONG JIANZHU UNIV

Patent Information

Application Number
CN202511225035.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-29
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

Existing traffic flow prediction methods struggle to simultaneously capture long-term temporal dependencies and local and global spatial correlations in traffic data, failing to accurately simulate the delay impact of traffic changes on adjacent road segments, resulting in insufficient prediction accuracy.

Method used

A method based on long-term multi-dimensional feature fusion is adopted. By acquiring graph structure data and historical traffic state data at multiple time scales, and using graph convolutional networks and self-attention mechanisms, local spatial dependencies and global spatial dependencies are fused to generate multi-dimensional dynamic features for traffic flow prediction.

Benefits of technology

It significantly improves the accuracy and applicability of traffic flow forecasting, enabling early prediction of potential congestion areas, optimization of traffic control strategies, reduction of traffic delays, and improvement of travel efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120977121A_ABST
    Figure CN120977121A_ABST
Patent Text Reader

Abstract

The invention discloses a traffic flow prediction method based on long-period multi-dimensional feature fusion, and belongs to the field of traffic flow prediction, and the method comprises the steps: firstly constructing graph structure data containing nodes and a connection relation according to a road sensor network; secondly, historical traffic state data of multiple time scales such as day and week are collected and arranged, and periodic feature vectors are obtained through double-convolution-layer time sequence coding; then, node local spatial dependence is captured through Chebyshev polynomial graph convolution, global spatial dependence between remote nodes is modeled through a self-attention mechanism, and global-local fusion features are formed through splicing; injecting week and time slice information in a one-hot coding form to generate a multi-dimensional dynamic feature fused with a time rule; and finally, dynamically distributing feature weights through a self-attention decoder, and outputting traffic flow prediction results of all nodes in a future time step length. According to the method, the traffic flow prediction precision and applicability are remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the field of traffic flow prediction, and particularly relates to a traffic flow prediction method based on long-period multi-dimensional feature fusion. BACKGROUND

[0002] With the acceleration of global urbanization and the continuous expansion of transportation networks, traffic management is facing severe challenges. Traffic congestion, air pollution, and low travel efficiency are becoming increasingly prominent, seriously affecting the travel experience of residents and the efficiency of urban operation. Traditional traffic management methods mainly rely on manual patrols, fixed monitoring points, and static traffic models, which have problems such as response lag and insufficient prediction accuracy. Therefore, intelligent transportation systems (ITS) have become a key technology for optimizing urban traffic, which aims to effectively alleviate road congestion and improve traffic efficiency through real-time data analysis and traffic flow prediction.

[0003] In the field of traffic prediction, existing methods mainly include statistical models, machine learning models, and deep learning models. Statistical methods are difficult to cope with the complex changes of actual traffic data due to the assumption of traffic data stationarity. Machine learning methods such as support vector machines and neural networks have certain improvements, but they still cannot capture the complex spatial correlations and long-term dynamic changes in the transportation network. In recent years, graph neural networks have been widely used in traffic flow prediction due to their ability to model road network topology. However, existing methods are difficult to capture long-period temporal dependence and local and global spatial correlations in traffic data simultaneously. In addition, the spatial information transmission has a lag, which cannot accurately simulate the delay impact of traffic changes on adjacent road segments. Traditional models mostly model local and global information separately, ignoring their collaborative relationship. Therefore, existing technologies cannot comprehensively and accurately predict complex dynamic changes in large-scale transportation networks, and a new traffic flow prediction method that combines long-period temporal information, local and global spatial correlations, and dynamic weight distribution is needed. SUMMARY

[0004] To solve the above technical problems, the present application provides a traffic flow prediction method based on long-period multi-dimensional feature fusion, comprising:

[0005] According to the topology of the transportation network, graph structure data containing nodes and connection relationships are obtained;

[0006] According to the graph structure data, multi-time scale historical traffic state data are obtained;

[0007] According to the historical traffic state data, a periodic feature vector encoded by multi-scale time series is obtained;

[0008] According to the periodic feature vector, a local spatial feature fused with local spatial dependence is obtained;

[0009] According to the local spatial feature, a global-local fusion feature fusing global spatial dependence is obtained;

[0010] According to the global-local fusion feature, a multi-dimensional dynamic feature fusing time regularity is obtained;

[0011] According to the multi-dimensional dynamic feature, a traffic flow prediction result in a future time step is obtained.

[0012] Optionally, the obtaining of the graph structure data comprises:

[0013] According to road sensor layout information, sensors are mapped as nodes;

[0014] According to road physical connection relationship, roads are mapped as edges;

[0015] According to the correspondence between nodes and edges, an adjacency matrix is generated and the graph structure data is constructed.

[0016] Optionally, the obtaining of the multi-time-scale historical traffic state data comprises:

[0017] According to a preset sliding time window, first historical data with a day scale is obtained;

[0018] According to a preset sliding time window, second historical data with a week scale is obtained;

[0019] According to the first historical data and the second historical data, the historical traffic state data is spliced.

[0020] Optionally, the obtaining of the periodic feature vector comprises:

[0021] According to the historical traffic state data, a first convolutional layer is used to maintain the time sequence dimension and extract day scale features;

[0022] According to the day scale features, a second convolutional layer is used for down-sampling to suppress noise and extract week scale features;

[0023] According to the day scale features and the week scale features, the periodic feature vector is spliced.

[0024] Optionally, the obtaining of the local spatial feature comprises:

[0025] According to the periodic feature vector, a Chebyshev polynomial approximation graph convolution operator is used to aggregate node neighborhood information;

[0026] According to the aggregation result, the local spatial feature is generated to represent the direct traffic influence relationship between adjacent nodes.

[0027] Optionally, the obtaining of the global-local fusion feature comprises:

[0028] According to the local space feature, a query vector, a key vector and a value vector are constructed;

[0029] According to the dot product result of the query vector and the key vector, an attention weight between nodes is obtained;

[0030] According to the attention weight, the value vector is weighted and summed to obtain a global space feature;

[0031] According to the global space feature and the local space feature, the global-local fusion feature is generated.

[0032] Optionally, the obtaining of the multi-dimensional dynamic feature comprises:

[0033] According to the current date and the specific time point, a week one-hot encoding and a time slice one-hot encoding are generated;

[0034] According to the one-hot encoding, a time encoding vector is mapped through a linear layer;

[0035] According to the time encoding vector and the global-local fusion feature, the multi-dimensional dynamic feature is generated.

[0036] Optionally, the obtaining of the traffic flow prediction result comprises:

[0037] According to the multi-dimensional dynamic feature, a self-attention decoder is used to dynamically allocate feature weights;

[0038] According to the weight allocation result, the traffic flow of all nodes in the future time steps is predicted, and a prediction tensor is output.

[0039] In another aspect, the present application also provides an electronic device comprising a memory, a processor and a computing program stored in the memory and executable on the processor, wherein the processor executes the computing program to realize the method.

[0040] In another aspect, the present application also provides a computer readable storage medium storing a computer program, wherein the computer program is executed by a processor to realize the method.

[0041] Compared with the prior art, the present application has the following advantages and technical effects:

[0042] This invention aims to provide a method for predicting urban traffic flow based on long-term historical data, overcoming the limitations of existing models in modeling complex spatiotemporal dependencies and significantly improving the accuracy and applicability of predictions. Through this invention, managers can scientifically formulate traffic control strategies and optimize road resource allocation based on high-precision prediction results, thereby effectively alleviating traffic congestion, improving travel efficiency, and reducing system operating costs. This invention is particularly suitable for complex real-world scenarios such as sparse sensor distribution, diverse urban structures, and frequent emergencies, possessing good applicability and promotional value. Attached Figure Description

[0043] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:

[0044] Figure 1 This is a schematic diagram of the method flow according to an embodiment of the present invention. Detailed Implementation

[0045] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.

[0046] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.

[0047] Example 1

[0048] like Figure 1 As shown, this embodiment provides a traffic flow prediction method based on long-term multi-dimensional feature fusion, including:

[0049] Based on the traffic network topology, obtain graph structure data containing nodes and connection relationships;

[0050] Based on the graph structure data, obtain historical traffic status data at multiple time scales;

[0051] Based on the historical traffic status data, obtain a periodic feature vector encoded by multi-scale time series.

[0052] Based on the periodic feature vector, obtain the local spatial features that fuse local spatial dependencies;

[0053] Based on the local spatial features, obtain the global-local fusion features that fuse global spatial dependencies;

[0054] According to the global-local fusion feature, a multi-dimensional dynamic feature of fusion time law is obtained;

[0055] According to the multi-dimensional dynamic feature, a traffic flow prediction result in a future time step is obtained.

[0056] The specific process is as follows:

[0057] Road congestion is closely related to traffic flow density, especially in urban trunk road networks, key nodes and intersection areas. In order to accurately predict the trend of traffic flow and alleviate road congestion, the present application proposes a traffic flow prediction method based on long-period historical data and multi-dimensional feature fusion. This method introduces a multi-time scale historical data modeling mechanism, and combines a spatial structure double dependence modeling module (local graph convolution and global attention mechanism). In the environment of dynamic change of urban traffic state, it can accurately capture the complex spatio-temporal evolution law in the road network. This not only significantly improves the response ability and prediction accuracy of the model to traffic emergencies, but also enables traffic management departments to predict potential congestion areas in advance, develop dynamic relief programs, thereby effectively reducing traffic delays, shortening average travel time, and improving road resource utilization efficiency.

[0058] The traffic prediction target of the present embodiment is to predict the traffic data Y of all nodes in the future H time steps based on the multi-dimensional historical observation data in the past P time steps. H×N×c Wherein, N represents the set of all roads, intersections and sensor nodes in the traffic network, C is the feature dimension of a single node (in the present embodiment, C=1, representing traffic flow).

[0059] Step 1: Represent the urban road traffic system as a topological graph structure: Let the traffic network graph be G(V,E,A), wherein: V={v1,v2,...,v N} represents the set of road sensors; E is the edge set, representing the connection relationship between road sensors; A R N×N is the adjacency matrix, and the element A ij represents the topological relationship between node i and node j, if the two nodes are directly connected, then A ij >0, otherwise 0.

[0060] Step 2: Collect and organize multi-time scale historical traffic state data: Let P be the number of historical observation time steps, X R P×N×c represents the historical traffic data tensor, wherein X t R N×c represents the observation data of all sensors at time t; In order to extract the long-term trend and periodicity in the historical traffic data, a time series feature encoding module is constructed by means of a sliding window, and data in the past one day is extracted Data in the past week where C d , C w are the encoding features of day and week respectively.

[0061] Step 3: Multi-scale temporal feature encoding: obtain the day-scale encoding feature and the week-scale encoding feature by downsampling encoding process using two layers of one-dimensional convolution and normalization to extract temporal information. The first layer of convolution kernel size k1=3, maintains the time series dimension, and preserves the original information; the second layer of convolution kernel size: k2=s, downsampling to extract key features, while reducing the data dimension, suppressing noise interference, and finally output the encoded day-scale feature and week-scale feature effectively capturing the periodic changes and long-term trends in travel patterns. The spliced day-scale and week-scale features are used as the original input X into the convolution layer to generate node embedding vector X e . The formula is as follows:

[0062] X e = BatchNorm(Conv(X 1:P ));

[0063] Step 4: Spatial dependency information modeling: after extracting the temporal features, the system further integrates spatial dependency information based on the traffic network topology. First, use the graph convolution network (GCN) to model the local spatial relationship between nodes. By constructing a Chebyshev polynomial approximation graph convolution operator based on the Laplacian matrix and the adjacency matrix A, the information in the local neighborhood of each node is efficiently aggregated to generate local spatial features X GCN , capturing the direct traffic influence relationship between roads and intersections. The formula is as follows:

[0064]

[0065] where Z (k) is recursively calculated by the following formula:

[0066]

[0067] where λ max is the largest eigenvalue of L, and I is the identity matrix.

[0068] At the same time, to overcome the problem of insufficient ability of traditional models to depict dynamic interactions between distant nodes, the system introduces a self-attention mechanism by constructing query key value vectors The attention score a between nodes and nodes is calculated by the dot product between the query of node i and the key value of node j ij Then normalized by the softmax function to ensure that the sum of the attention scores of a given node on all other nodes is 1, as shown in the following formula:

[0069]

[0070] Where d k is the dimension of the key vector. The resulting normalized attention score a ij As a weight, indicates how much attention node i should give to node j. Using these attention weights, the weighted sum of the value vectors Vj of all operation nodes is calculated, dynamically adjusting the interaction weight between different nodes, forming a global spatial feature representation, generating the updated feature representation of the node, as shown in the following equation. The formula is as follows:

[0071]

[0072] The concatenation of local and global features gives So that the system not only pays attention to the direct impact of adjacent roads, but also fully models the complex dynamic interaction between distant nodes, effectively reflecting the multi-scale spatial dependence structure of the entire urban traffic network.

[0073] Step 5: Spatio-temporal fusion: Based on spatial feature extraction, the system further integrates time information to enhance the adaptability to traffic periodicity and irregular patterns. Through one-hot encoding, the day of the week information V d ∈R 7 And the specific time slice information V t ∈R 288 (The dataset is collected every five minutes, and there are 288 time points in a day), and a linear layer is used to produce a time encoding output V Te ∈R 295 with length equal to S e The number of feature channels. Combined with the aforementioned multi-dimensional spatio-temporal joint features ST e , the final multi-dimensional dynamic feature representation STE is formed. STE = Nrom(ST H·N·1 + V). This feature comprehensively reflects the historical dynamics, spatial structure and temporal regularity of the traffic network, providing comprehensive information support for high-precision traffic flow prediction.

[0074] Step 6: Prediction output: The final system uses a self-attention decoder structure to dynamically allocate the influence weight of each feature information on the prediction result, focusing on key nodes and time windows that have a significant impact on future traffic state changes, and realizes high-precision prediction of the traffic state of all nodes within the future H time steps. The prediction result is in the form of a tensor Y H·N·1 Output.

[0075] The technical effect of the embodiment is:

[0076] (1) By introducing a multi-time scale historical data modeling mechanism and a spatial structure dual-dependent modeling module (local graph convolution and global attention mechanism), the application can not only effectively depict the change rule of daily periodic traffic flow, but also adapt to complex urban operation scenarios by modeling irregular modes (such as holiday collective travel, large-scale gathering activities, and chain reaction induced by sudden accidents).

[0077] (2) The embodiment effectively improves the response ability and prediction accuracy of the model to traffic emergencies, and helps the traffic management department to predict potential congestion areas in advance, develop dynamic relief programs, thereby reducing traffic delay, shortening average travel time, and improving urban road resource utilization efficiency.

[0078] On the other hand, the embodiment also provides an electronic device, which includes a memory, a processor, and a computing program stored in the memory and executable on the processor, and the processor implements the method when executing the computing program.

[0079] On the other hand, the embodiment also provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the method.

[0080] The above is only the preferred specific embodiment of the present application, but the protection scope of the present application is not limited to this. Any person skilled in the art can easily think of changes or replacements within the technical range disclosed in the present application, which should be covered in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A traffic flow prediction method based on long-term multi-dimensional feature fusion, characterized in that, include: Based on the traffic network topology, obtain graph structure data containing nodes and connection relationships; Based on the graph structure data, obtain historical traffic status data at multiple time scales; Based on the historical traffic status data, obtain a periodic feature vector encoded by multi-scale time series. Based on the periodic feature vector, obtain the local spatial features that fuse local spatial dependencies; Based on the local spatial features, obtain the global-local fusion features that fuse global spatial dependencies; Based on the global-local fusion features, obtain multi-dimensional dynamic features of the fusion time pattern; Based on the aforementioned multi-dimensional dynamic features, traffic flow prediction results are obtained within the future time step.

2. The method according to claim 1, characterized in that, The acquisition of the graph structure data includes: Based on the road sensor deployment information, the sensors are mapped as nodes; Based on the physical connections of the roads, the roads are mapped as edges; Based on the correspondence between nodes and edges, an adjacency matrix is ​​generated and the graph structure data is constructed.

3. The method according to claim 1, characterized in that, The acquisition of the multi-timescale historical traffic status data includes: Based on a preset sliding time window, obtain the first historical data on a daily scale; Based on a preset sliding time window, obtain the second historical data on a weekly scale; The historical traffic status data is formed by combining the first historical data and the second historical data.

4. The method according to claim 1, characterized in that, The acquisition of the periodic feature vector includes: Based on the historical traffic data, the time series dimension is preserved and daily-scale features are extracted through the first convolutional layer; Based on the daily-scale features, downsampling is performed through a second convolutional layer to suppress noise and extract weekly-scale features; The periodic feature vector is obtained by concatenating the daily and weekly features.

5. The method according to claim 1, characterized in that, The acquisition of the local spatial features includes: Based on the periodic feature vector, the node neighborhood information is aggregated using a graph convolution operator approximated by Chebyshev polynomials. Based on the aggregation results, the local spatial features are generated to represent the direct traffic impact relationships between adjacent nodes.

6. The method according to claim 1, characterized in that, The acquisition of the global-local fusion features includes: Based on the local spatial features, construct the query vector, key vector, and value vector; Based on the dot product of the query vector and the key vector, obtain the attention weights between nodes; The global spatial features are obtained by weighted summation of the value vectors based on the attention weights. The global-local fusion feature is generated by concatenating the global and local spatial features.

7. The method according to claim 1, characterized in that, The acquisition of the multi-dimensional dynamic features includes: Generate weekday unique hot codes and time slice unique hot codes based on the current date and specific time. Based on the one-hot encoding, it is mapped to a time-encoded vector through a linear layer; The multi-dimensional dynamic features are generated by fusing the time encoding vector with the global-local fusion features.

8. The method according to claim 1, characterized in that, The acquisition of the traffic flow prediction results includes: Based on the aforementioned multi-dimensional dynamic features, the feature weights are dynamically allocated using a self-attention decoder; Based on the weight allocation results, the traffic flow of all nodes within the future time step is predicted, and the prediction tensor is output.

9. An electronic device comprising a memory, a processor, and a computing program stored in the memory and executable on the processor, characterized in that, When the processor executes the computing program, it implements the method of any one of claims 1-8.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1-8.

Citation Information

Patent Citations

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

    CN116935649A

  • Full-period traffic flow prediction method based on spatial-temporal feature deep fusion

    CN119541195A

  • Traffic flow prediction method and device based on global-local space-time dependency interaction

    CN120496328A

Cited By

  • Traffic jam long-period prediction method and system fusing spatial-temporal characteristics

    CN121354354A