A city traffic flow prediction method based on multiple space-time characteristics of a road network

By combining wavelet decomposition and dynamic graph convolutional networks with multi-branch convolutional feature extraction, the multiple spatiotemporal characteristics of urban traffic flow are adaptively separated and fused, solving the problem of difficulty in separating traffic flow trends and disturbances in traditional methods, and achieving high-precision traffic flow prediction.

CN120913415BActive Publication Date: 2026-01-16EAST CHINA JIAOTONG UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511443686.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-10
Publication Date
2026-01-16
Estimated Expiration
2045-10-10

AI Technical Summary

Technical Problem

Existing technologies struggle to effectively separate and model smooth periodic trends and sudden disturbances in urban traffic flow, resulting in insufficient accuracy in traffic flow prediction.

Method used

A method for predicting urban traffic flow based on the multi-temporal characteristics of road networks is adopted. The method performs hierarchical decomposition through wavelet decomposition units, combines dynamic graph convolutional networks and multi-branch convolutional feature extraction modules to adaptively extract low-frequency and high-frequency features, and fuses them through inverse wavelet transform to construct a multi-scale traffic flow prediction model.

Benefits of technology

It significantly improves the accuracy and generalization ability of traffic flow prediction, can adaptively handle complex traffic geography and diverse traffic modes, and enhances the ability to extract multi-scale features in prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120913415B_ABST
    Figure CN120913415B_ABST
Patent Text Reader

Abstract

The application discloses a kind of urban traffic flow prediction methods based on road network multiple space-time characteristics, comprising the following steps: obtaining the historical traffic flow information and road topological connection structure information of relevant area, according to the prediction demand, corresponding data set is constructed;The historical traffic flow information is preprocessed, and space-time feature tensor and construction road adjacency matrix are constructed;Space-time feature tensor is input into the trainable promotion wavelet decomposition unit and is hierarchically decomposed, to obtain low-frequency component and high-frequency component;The original traffic flow time series data is hierarchically decomposed by wavelet decomposition unit, and the features of different frequency components are extracted and modeled respectively, so that the low-frequency component sufficiently learns the global trend and periodic change of traffic flow, and the high-frequency component focuses on describing the suddenness, local dynamic change in traffic network.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application belongs to the technical field of intelligent transportation, and particularly relates to a city traffic flow prediction method based on multiple space-time characteristics of a road network. BACKGROUND

[0002] Traffic flow prediction, as a key technology in the construction of intelligent transportation cities, is of great significance in urban planning and traffic congestion management. By modeling the space-time dynamics of the road network, traffic flow prediction can simulate the congestion trend of the road in the future and help relevant management departments to develop effective intervention measures in a timely manner. At the same time, travelers can also optimize their travel paths in combination with prediction information and real-time navigation systems to improve the overall travel experience. Traffic flow is a space-time coupled dynamic process based on road network structure, and therefore has complex multiple space-time characteristics. How to achieve high-precision city traffic flow prediction still faces many challenges.

[0003] In the time dimension, traffic flow shows obvious periodicity and trend. For example, the peak value of traffic flow during the peak period of working days and the traffic flow distribution during non-working days both reflect the regularity of traffic flow change over time. At the same time, the development of urbanization and social economy promotes the sustained growth trend of traffic flow on a longer time scale, reflecting its long-term evolution characteristics.

[0004] In the spatial dimension, traffic flow characteristics mainly come from the topology of the road network and the complex correlation between road segments. Spatial correlation is reflected in that: on the one hand, the traffic states of adjacent road segments are highly correlated, such as the change of upstream traffic volume often directly affects the traffic distribution of downstream; on the other hand, even road segments far apart may have indirect effects due to sudden events such as traffic accidents; in addition, spatial heterogeneity is manifested in that different road segments exhibit different traffic patterns due to differences in structural attributes and functional positioning, for example, urban trunk roads are usually densely trafficked, while suburban roads are sparsely trafficked.

[0005] Therefore, city traffic flow exhibits complex multiple characteristics in space-time, which poses a challenge to accurate prediction. Although time-frequency analysis methods such as wavelet transform provide a way to deal with such multi-scale data, the traditional form has significant defects. Traditional wavelet analysis relies on fixed and non-adaptive basis functions, which makes it difficult to optimally separate the smooth periodic trend and sudden random disturbance in traffic data. This suboptimal feature separation limits the learning ability of the model. Therefore, designing a module that can adaptively learn the decomposition method according to the data characteristics to achieve more accurate feature extraction is a key problem that needs to be solved. SUMMARY

[0006] The present application aims to provide a city traffic flow prediction method based on multiple space-time characteristics of road networks, which utilizes the multiple space-time characteristics of city road traffic flow for prediction, thereby improving the accuracy of traffic flow prediction.

[0007] To achieve the above object, the present application provides the following technical solution: a city traffic flow prediction method based on multiple space-time characteristics of road networks, comprising the following steps:

[0008] Obtain historical traffic flow information and road topology connection structure information of the relevant area, and construct a corresponding data set according to the prediction requirement;

[0009] Preprocess the historical traffic flow information, construct a space-time feature tensor according to the preprocessed historical traffic flow information, and extract the road topology connection structure information of the observed road to construct a road adjacency matrix;

[0010] Input the space-time feature tensor into a trainable lifting wavelet decomposition unit for hierarchical decomposition to obtain low-frequency components and high-frequency components;

[0011] Input the low-frequency components and high-frequency components obtained by the wavelet decomposition unit into two parallel processing paths respectively; for the low-frequency components, utilize a dynamic graph convolution network (DWH-GCN) to model a dynamic spatial feature vector in combination with the road adjacency matrix, input the dynamic spatial feature vector into a Mamba time series modeling module to capture long-range dependence, and obtain low-frequency features containing space-time characteristics; extract the high-frequency components through a multi-branch convolution feature extraction module to obtain high-frequency dynamic weight features;

[0012] Jointly reconstruct the low-frequency features containing space-time characteristics and the high-frequency dynamic weight features through an inverse wavelet transform module to obtain multi-scale fusion features;

[0013] Input the reconstructed multi-scale fusion features into a fully connected layer for prediction to obtain traffic flow prediction results.

[0014] As a preferred technical solution of the present application, the historical traffic flow information adopts a PEMS series public data set, which contains sensor data of multiple real-world connected roads, and the sensor aggregates the number of vehicles passing through, and the road topology connection structure information is obtained by preprocessing the connection information of the sensor.

[0015] As a preferred technical solution of the present application, the historical traffic flow information is normalized in the form of range standardization, and the missing data in the information data collection process is filled by using a time series interpolation strategy.

[0016] As a preferred technical solution of the present application, the space-time feature tensor is constructed according to the space-time characteristics of N roads and a total of T time steps , Dimensions of a spatio-temporal feature tensor, , wherein , denotes the traffic flow observation value at time t, denotes the traffic flow observation value of road N at time t; the road topology connection structure information of the observed road is extracted to construct an N*N road adjacency matrix .

[0017] As a preferred technical solution of the present application, the specific process of hierarchical decomposition of the wavelet decomposition unit is as follows:

[0018] The input spatio-temporal feature tensor X is down-sampled in the time dimension using a learnable one-dimensional convolution kernel, and is divided into half of the original length to obtain the preliminary low-frequency component and the high-frequency component ;

[0019] The preliminary low-frequency component and the high-frequency component are projected and transformed using orthogonal matrices and , and and are optimized through back propagation, so that the decomposition kernel dynamically adapts to the signal characteristics;

[0020] The channel attention is set, the low-frequency component and the high-frequency component after the projection transformation are spliced along the feature channel, the spliced features are respectively subjected to average pooling and maximum pooling, then the results of the average pooling and the maximum pooling are dynamically weighted and fused, and the features after the weighted fusion generate a channel attention mask through a convolution path , and then the final low-frequency component and the high-frequency component are obtained through a segmentation operation.

[0021] As a preferred technical solution of the present application, in the processing path of the low-frequency component s, the dynamic graph convolution network, for each node, mines the feature expression capability in the potential space of the node itself by introducing a learnable node embedding vector, splices the features of the node pair , i and j are different nodes, and a spatial relationship dynamic weight is further generated through a multi-layer perceptron:

[0022] ;

[0023] is a multi-layer perceptron; the spatial relationship dynamic weight is generated according to a probability normalization function ;

[0024] The local features and the global connection relationship of the road adjacency matrix are dynamically weighted to obtain a dynamic adjacency matrix A dyn :

[0025] ;

[0026] wherein, is the kth road adjacency matrix, k = 0, 1, 2, representing a fixed spatial preset relationship;

[0027] Then the spatial correlation of the dynamic adjacency matrix is captured:

[0028] S H ;

[0029] wherein, S H is a dynamic spatial feature vector obtained by multiplying the dynamic adjacency matrix and the low-frequency component s;

[0030] The dynamic spatial feature vector S H is input into the Mamba time series modeling module, and long time series dependence is modeled through a state space equation; meanwhile, the output of the Mamba time series modeling module is added to the low-frequency component s using a residual connection to obtain a low-frequency feature s out .

[0031] As a preferred technical solution of the present application, in the processing path of the high-frequency component, a multi-branch convolution feature extraction module is arranged, the multi-branch convolution feature extraction module includes at least two convolution kernels of different sizes, and multi-scale time series feature extraction is performed on the high-frequency component; each convolution branch performs parallel convolution operation on the input high-frequency component data to obtain local feature information at different time scales, and the output results of the multi-convolution branches are fused through a feature fusion layer to obtain fused high-frequency features; dynamic weighting is performed on the fused high-frequency features in combination with channel attention to obtain high-frequency dynamic weight features.

[0032] As a preferred technical solution of the present application, the inverse wavelet transform module first receives the low-frequency features containing space-time characteristics and the high-frequency dynamic weight features, and then performs inverse restoration operation on the orthogonal wavelet basis used in the decomposition stage through parameter-bound orthogonal matrix inverse transformation.

[0033] The present application also provides a computer readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the steps of the urban traffic flow prediction method based on multiple space-time characteristics of a road network as described above.

[0034] The present application also provides a computer device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the urban traffic flow prediction method based on multiple space-time characteristics of a road network as described above.

[0035] Compared with the prior art, the present application has the beneficial effects of:

[0036] The original traffic flow time series data is hierarchically decomposed by the wavelet decomposition unit, the characteristics of different frequency components are extracted and modeled respectively, the low-frequency components sufficiently learn the global trend and periodic changes of the traffic flow, and the high-frequency components mainly depict the sudden and local dynamic changes in the traffic network; the spatial correlation of the low-frequency components is modeled by combining the graph convolution network, and the high-frequency disturbance characteristics are efficiently extracted by combining the multi-branch convolution and attention mechanism, so as to effectively fuse the topological connection relationship and complex traffic mode between each node of the urban road.

[0037] Not only the extraction ability of multi-scale and multi-mode characteristics of the traffic flow is improved, but also the traffic information of different road sections and time periods can be adaptively fused, so that the accuracy and generalization ability of the traffic flow prediction are significantly improved, and the defects of the traditional method in modeling the complex traffic geographical structure and various traffic modes are overcome. BRIEF DESCRIPTION OF DRAWINGS

[0038] Figure 1 The method flowchart of the present application is shown in the figure;

[0039] Figure 2 The wavelet decomposition schematic diagram of the present application is shown in the figure;

[0040] Figure 3 The road adjacency matrix construction schematic diagram of the present application is shown in the figure;

[0041] Figure 4 The Mamba time series modeling module structure schematic diagram of the present application is shown in the figure;

[0042] Figure 5 The experimental result schematic diagram of the present application is shown in the figure. DETAILED DESCRIPTION

[0043] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the scope of protection of the present application.

[0044] Please refer to Figures 1-5 The present application provides a kind of urban traffic flow prediction method based on road network multiple space-time characteristics, comprising the following steps:

[0045] Step one: Obtain the historical traffic flow information and road topology connection structure information of the relevant area, and construct the corresponding data set according to the prediction demand; in this embodiment, the historical traffic flow information is a PEMS series public data set, which contains sensor data of multiple real-world connected roads, and the sensor aggregates the number of vehicles passing every 5 minutes, and the road topology connection structure is the connection information of the original sensor after preprocessing, which is set to 1 if connected, and 0 if not connected, and the road itself is self-connected, as a preset road connection matrix.

[0046] Step two: preprocessing the historical traffic flow information, constructing the spatio-temporal feature tensor according to the preprocessed historical traffic flow information, extracting the road topology connection structure information of the observed road to construct the road adjacency matrix , and dividing the training set, test set and validation set; the specific content is as follows: according to the data continuity principle, the data set is divided into training set, test set and validation set; the historical traffic flow information is normalized by using the range standardization form, and the missing data in the information data collection process is filled by using the time series interpolation strategy; according to the spatio-temporal features of N roads and T time steps, the spatio-temporal feature tensor , represents the dimension of the spatio-temporal feature tensor, , wherein , represents the traffic flow observation value at time t, represents the traffic flow observation value of road N at time t; the road topology connection structure information of the observed road is extracted to construct the N*N road adjacency matrix , as shown in (a) of Figure 3 , {A, B, C, D, E, F} are 5 related roads, and the road adjacency matrix is shown in (b) of Figure 3 . In this embodiment, the method for filling the missing data is: if a single data point is missing, the average of the previous and next data points is used to fill it; if there are many missing values, a linear interpolation method is used to construct a linear relationship according to the effective data on both sides of the missing value, thereby filling the missing value; when the data set is divided into training set, test set and validation set, the proportion is 6:2:2; at the same time, in order to avoid the leakage of external information during prediction, only the training set is processed by using the range standardization method, and then the test set and the validation set are processed by using the conversion method of the training set, at the same time, the continuity of the time series is maintained.

[0047] Step three: input the spatiotemporal feature tensor into the trainable lifting wavelet decomposition unit for hierarchical decomposition to obtain low-frequency components and high-frequency components; the specific content is as follows: the preprocessed spatiotemporal feature tensor X is input into the trainable lifting wavelet decomposition unit to perform hierarchical decomposition operation; traditional wavelet decomposition technology relies on an experienced preselected fixed wavelet basis, such as Haar wavelet; the core defect lies in that this preset method lacks adaptability, that is, once the decomposition method is determined, it cannot be changed, and it is difficult to better match the complex dynamics of specific traffic data, often leading to that the low-frequency trend and high-frequency disturbance of the signal cannot be completely separated, thereby limiting the final performance of the prediction model; unlike the traditional method, the trainable lifting wavelet decomposition unit in the present application is completely adaptive and does not depend on any preset mother wavelet, but the decomposition process itself is learned end to end as part of the model; specifically, the trainable lifting wavelet decomposition unit dynamically decomposes the input feature into low-frequency components and high-frequency components through a set of self-adaptable convolution kernels, the internal dynamic weight adjustment mechanism can optimize the weights of the low-frequency components and the high-frequency components in real time, and adaptively allocate their contribution in subsequent modeling, thereby enhancing the feature representation capability; Figure 2 A wavelet decomposition schematic diagram of the present application is shown in FIG. 1. In this embodiment, the convolution kernel size is set to 5, which can capture a wider local context; the wavelet decomposition layer number is set to 3, thereby better controlling the multiscale analysis depth of the traffic flow information; a feedback mechanism is introduced to enhance the information interaction between the layers and adapt to the complex time-varying characteristics of the traffic flow; the specific steps are as follows:

[0048] The input spatiotemporal feature tensor X is down-sampled in the time dimension using a learnable one-dimensional convolution kernel and is divided into half of the original length to obtain the preliminary low-frequency component and the high-frequency component :

[0049] ;

[0050] wherein, is the preliminary low-frequency component, representing the main trend and periodic change of the traffic flow; is the preliminary high-frequency component, representing the sudden event or random disturbance in the traffic flow; Conv1d is a learnable one-dimensional convolution layer, and its weight is automatically optimized in the model training; Chhunk is a segmentation operation, and the feature tensor doubled in the channel dimension after the convolution operation is divided into two parts on average;

[0051] The orthogonal matrix and are used to linearly transform the preliminary low-frequency component and the high-frequency component to ensure the stability of the decomposition:

[0052] ;

[0053] ;

[0054] wherein, and are the low-frequency component and the high-frequency component after projection transformation, respectively; and and are optimized by back propagation to make the decomposition kernel dynamically adapt to the signal characteristics.

[0055] To further adjust the channel weights of the low-frequency component and the high-frequency component, a channel attention is set; the low-frequency component and the high-frequency component after projection transformation are spliced along the feature channel, and the number of channels is doubled; the spliced features are respectively captured by average pooling and maximum pooling to capture the global features and local features of the signal, and the results of the average pooling and the maximum pooling are further dynamically weighted and fused to balance the local features and the global features; the features after weighted fusion generate a channel attention mask through a convolution path, suppress noise and highlight important features, and then obtain the final low-frequency component and high-frequency component through a segmentation operation:

[0056] ;

[0057] ;

[0058] wherein, F is the feature after splicing the low-frequency component and the high-frequency component after projection transformation, and represent two learnable weights, balancing the importance of average pooling and maximum pooling ; and are two weight matrices realized by convolution layers; is a nonlinear activation function, is an activation function for generating a channel attention mask , is a segmentation operation, s is the final low-frequency component, and d is the final high-frequency component.

[0059] Step four: input the low-frequency component and the high-frequency component obtained by the wavelet decomposition unit into two parallel processing paths respectively; for the low-frequency component, use a dynamic graph convolution network (DWH-GCN) to model a dynamic spatial feature vector combined with a road adjacency matrix, input the dynamic spatial feature vector into a Mamba time series modeling module to capture long-range dependencies, and obtain a low-frequency feature containing spatial and temporal characteristics; extract the high-frequency component through a multi-branch convolution feature extraction module to obtain a high-frequency dynamic weight feature;

[0060] In the processing path of the low-frequency component s, a dynamic graph convolution network (DWH-GCN) first mines the feature expression ability of each node in the implicit space by introducing a learnable node embedding vector, laying a foundation for subsequent spatial relationship modeling; then, a normalized road adjacency matrix is generated, and then the low-frequency component s is subjected to spatial feature extraction by the dynamic graph convolution network, so as to fully model the topological structure and spatial correlation between nodes and effectively improve the perception of the spatial distribution of the traffic network.

[0061] For each node, the feature expression ability of the node in the potential space is mined by introducing a learnable node embedding vector, and the features of the node pair are spliced , i and j are different nodes, and a multi-layer perceptron is further used to generate a spatial relationship dynamic weight:

[0062] ;

[0063] is a multi-layer perceptron, which learns the complex relationship between the node pair; according to a probability normalization function is used to generate a spatial relationship dynamic weight ;

[0064] The local features and the global connection relationship of the road adjacency matrix are dynamically weighted to obtain a dynamic adjacency matrix A dyn :

[0065] ;

[0066] wherein, is the kth road adjacency matrix, k=0, 1, 2, representing a fixed spatial preset relationship; when k=0, =I (unit matrix, representing self-connection) ; when k=1, = (predefined physical adjacency matrix) ; when k=2, =clamp( +I) (representing a combination of first-order neighbors and itself), clamp is a function for limiting a numerical value in a specified interval; the obtained spatial relationship dynamic weight is distributed to the corresponding road adjacency matrix, and the three basic matrices are multiplied by the dynamic weight and added to obtain a dynamic adjacency matrix A dyn ;

[0067] Then the spatial correlation of the dynamic adjacency matrix is captured:

[0068] S H ;

[0069] wherein, S H is a dynamic spatial feature vector obtained by multiplying the dynamic adjacency matrix with the low-frequency component s; each row vector of the dynamic spatial feature vector represents a new feature representation of a node (e.g., a traffic monitoring point) after fusing its neighborhood spatial information at a specific time step; the dynamic spatial feature vector captures dynamic spatial correlation and serves as an input for subsequent model levels for further time series analysis or prediction;

[0070] The dynamic adjacency matrix is multiplied with the corresponding input feature matrix, and the features of each time step are processed independently, which is similar to a first-order graph convolution operation, thereby realizing the interaction of node information between roads and enhancing the interpretability of the flow of traffic flow along the road network. The dynamic spatial feature vector S H is input into the Mamba time series modeling module to model long-term time series dependence through a state space equation; at the same time, the output of the Mamba time series modeling module is added to the low-frequency component s out using a residual connection to obtain a low-frequency feature s H that contains refined spatiotemporal characteristics, retains the basic features, and enhances the time series evolution information to avoid gradient disappearance.

[0071] The Mamba time series modeling module is shown in Figure 4 to further capture the long-term time series dependence relationship in the traffic flow data and strengthen the model's representation ability of low-frequency global dynamics.

[0072] The core task of the Mamba time series modeling module is to capture the long-term dependence relationship of traffic flow data in the time dimension; the dynamic spatial feature vector S H is rearranged, and the rearranged tensor is sent to the Mamba time series modeling module; in the processing flow of the Mamba time series modeling module, the input tensor shape is [B, L, C], wherein B represents the batch size, i.e., the number of samples processed simultaneously; L represents the sequence length, i.e., the number of time steps; and C represents the channel number, i.e., the feature dimension of each time step; the flow first splits the input dynamic spatial feature vector S H into a trunk path and a gating path, and projects them to a higher dimension through a linear layer respectively, then the trunk path uses one-dimensional convolution and selective scanning mechanism to capture long-distance time series dependence, while the gating path generates a dynamic "gate" through an activation function; subsequently, the output of the trunk path is element-wise multiplied with the "gate" to realize selective screening and fusion of time series information; finally, a linear layer projects the fused result back to the original channel dimension, thereby outputting a low-frequency feature s out that contains spatiotemporal characteristics after deep time series modeling and information refinement.

[0073] In the processing path of the high-frequency component d, a multi-branch convolution feature extraction module is arranged, which includes at least two convolution kernels of different sizes, and multi-scale time sequence feature extraction is performed on the high-frequency component respectively; each convolution branch performs parallel convolution operation on the input high-frequency component data to obtain local feature information under different time scales, and the output results of the multi-convolution branch are fused through a feature fusion layer to obtain fused high-frequency features; in combination with channel attention, the fused high-frequency features are dynamically weighted to obtain high-frequency dynamic weight features, so as to enhance the attention degree to key disturbance modes and suppress invalid noise.

[0074] In the multi-branch convolution feature extraction module, each convolution branch has a convolution kernel of different scales, such as sizes of {1, 3} and {3, 5}. By cascading convolution operations of different receptive fields, spatial and temporal features of different details can be captured. Dynamic weights of each channel are generated by using a convolution network, and then channel adaptive allocation is performed.

[0075] d out ;

[0076] d out for the high-frequency dynamic weight feature; is the feature extraction result of the first convolution branch, is the feature extraction result of the second convolution branch, and each convolution branch includes a convolution kernel of different sizes; is the dynamic weight generated by the mth convolution branch; is the output of the first convolution branch; is a 1x1 convolution operation, indicates a channel concatenation operation of features.

[0077] It should be noted that: the convolution network essentially adopts a multi-branch convolution feature extraction module with dynamic branch weighting attention mechanism. The core of the module is to construct multiple parallel convolution branches, each branch using a convolution kernel of different sizes (such as 1x3, 3x5 combination). This multi-branch structure is inspired by the design concept of Inception network, and its purpose is to capture and fuse features from multiple different receptive field scales without significantly increasing the computational cost. It is a common strategy to build an efficient and lightweight convolution network.

[0078] Step five: joint reconstruction of the low-frequency feature and the high-frequency dynamic weight feature containing spatial and temporal characteristics through an inverse wavelet transform module to obtain a multi-scale fusion feature;

[0079] The inverse wavelet transform module first receives the low-frequency feature containing the spatio-temporal characteristics and the high-frequency dynamic weight feature, and then performs inverse transformation on the orthogonal wavelet basis used in the decomposition stage through the parameter-bound orthogonal matrix.

[0080] The joint reconstruction is the inverse module of the adaptive wavelet transform, and the operation is opposite; this series of symmetrical inverse operations accurately reconstruct the processed low-frequency and high-frequency signal components back to the original signal form; it first transforms the low-frequency and high-frequency components from their respective feature subspaces back to the unified representation space through inverse projection using the transpose of the base matrix used in decomposition; then, the two recovered signals are spliced in the channel dimension through channel merging to integrate into a single, more information-rich tensor; finally, the sequence length of the tensor is restored to the original resolution before decomposition using transpose convolution with a step size of 2 for upsampling, thereby completing the reconstruction process of the entire signal.

[0081] Step six: input the reconstructed multi-scale fusion feature into the fully connected layer for prediction to obtain the traffic flow prediction result. The specific process is as follows:

[0082] Two fully connected layers are used to realize dimension conversion, thereby outputting the traffic flow prediction result; when evaluating the difference between the predicted value and the actual value, the mean square error is used as the loss function Loss, and the calculation formula of the loss function Loss is as follows:

[0083] ;

[0084] Wherein, represents the true value at time t, represents the predicted value at time t.

[0085] At the same time, the root mean square error (RMSE) and the mean absolute error (MAE) are used as performance evaluation indexes, the RMSE gives a much higher "penalty" to large errors than small errors, and the MAE directly reflects the average size of the model prediction error.

[0086] The prediction result of the example of the application is shown in Figure 5 . Figure 5The change of the broken line statistical chart shows the evaluation performance of the method on the PEMS03 and PEMS04 public traffic flow data sets; specifically, the root mean square error (RMSE) and the mean absolute error (MAE) are used as performance indicators in the evaluation process, and the lower the values of the two, the better the model prediction performance; in the experimental setting, the current 12 consecutive time steps (corresponding to 60 minutes) are selected as input to predict the future 3 (15 minutes), 6 (30 minutes), 9 (45 minutes) and 12 time steps (60 minutes) of urban traffic flow changes.

[0087] From Figure 5 It can be seen from the results that the method achieves lower RMSE and MAE values at all prediction time spans, and the evaluation indicators of the model slowly rise stably as the observation time increases, the predicted value and the true value are visualized clearly, indicating that the model has high accuracy and stability in short-term and long-term traffic flow prediction tasks; this experimental result further verifies the effectiveness and superiority of the technical solution in capturing the spatio-temporal characteristics of traffic flow and improving the prediction accuracy, fully demonstrating its practical value and wide applicability in complex traffic scenarios.

[0088] Another embodiment of the application provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the steps of the urban traffic flow prediction method based on the multiple spatio-temporal characteristics of the road network as described above.

[0089] Still another embodiment of the application is a computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the urban traffic flow prediction method based on the multiple spatio-temporal characteristics of the road network as described above.

[0090] Although embodiments of the application have been shown and described in detail, to the extent that the above detailed description sets forth various embodiments of the application and the best mode contemplated, no limitation of the scope of the application is intended to be implied therefrom. The scope of the application is defined by the appended claims and their equivalents.

Claims

1. A method for urban traffic flow prediction based on multiple spatio-temporal characteristics of road networks, characterized in that: The method comprises the following steps: obtaining historical traffic flow information and road topology connection structure information of a relevant area, and constructing a corresponding data set according to a predicted demand; preprocessing the historical traffic flow information, constructing a space-time feature tensor according to the preprocessed historical traffic flow information, and extracting road topology connection structure information of an observed road to construct a road adjacency matrix; inputting the space-time feature tensor into a trainable lifting wavelet decomposition unit for hierarchical decomposition to obtain low-frequency components and high-frequency components; inputting the low-frequency components and the high-frequency components obtained by the wavelet decomposition unit into two parallel processing paths respectively, for the low-frequency components, modeling a dynamic space feature vector by using a dynamic graph convolution network combined with the road adjacency matrix, inputting the dynamic space feature vector into a Mamba time series modeling module to capture long-range dependence, and obtaining low-frequency features containing space-time characteristics; extracting high-frequency dynamic weight features by a multi-branch convolution feature extraction module. reconstructing the low-frequency features containing space-time characteristics and the high-frequency dynamic weight features by an inverse wavelet transform module to obtain multi-scale fusion features; inputting the reconstructed multi-scale fusion features into a fully connected layer for prediction to obtain a traffic flow prediction result. The specific process of hierarchical decomposition of the wavelet decomposition unit is as follows: The input spatio-temporal feature tensor X is down-sampled in the time dimension with a learnable one-dimensional convolution kernel and split into two halves of the original length, resulting in preliminary low-frequency and high-frequency components and high-frequency components ; Utilizing orthogonal matrices and Projecting the preliminary low-frequency components and high-frequency components and optimizing by backpropagation and to dynamically adapt the decomposition kernel to the signal characteristics; The low-frequency component and the high-frequency component after the projection transformation are spliced along the feature channel to set the channel attention, the spliced features are respectively subjected to average pooling and maximum pooling, then the results of the average pooling and the maximum pooling are dynamically weighted and fused, and the features after the weighted fusion generate the channel attention mask through a convolution path and then the final low-frequency component and high-frequency component are obtained through a segmentation operation. In the processing path of the low-frequency component s, the dynamic graph convolution network mines the feature expression ability of each node in the node potential space by introducing a learnable node embedding vector, and splices the features of the node pair , i and j are different nodes, and the spatial relationship dynamic weight is further generated by a multilayer perceptron: ; is a multilayer perceptron; according to a probability normalization function generates spatial relation dynamic weights ; The dynamic adjacency matrix A is obtained by dynamically weighting the local features and global connection relationship of the road adjacency matrix dyn : ; wherein, is the kth road adjacency matrix, k = 0, 1, 2, representing a fixed spatial preset relationship; Then the spatial correlation of the dynamic adjacency matrix is captured: S H ; where S H is a dynamic spatial feature vector obtained by multiplying the dynamic adjacency matrix with the low-frequency component s; The dynamic spatial feature vector S H is input to the Mamba temporal modeling module, which models long temporal dependencies through a state space equation; the output of the Mamba temporal modeling module is added to the low frequency component s using a residual connection to obtain the low frequency feature s out ; In the processing path of the high-frequency components, a multi-branch convolution feature extraction module is set, the multi-branch convolution feature extraction module includes at least two convolution kernels of different sizes, and multi-scale time series feature extraction is performed on the high-frequency components respectively; each convolution branch performs parallel convolution operation on the input high-frequency component data to obtain local feature information at different time scales, and the output results of the multi-convolution branches are fused through a feature fusion layer to obtain fused high-frequency features; the fused high-frequency features are dynamically weighted by combining channel attention to obtain high-frequency dynamic weight features. 2.The urban traffic flow prediction method based on multiple space-time characteristics of road network according to claim 1, characterized in that: The historical traffic flow information adopts a PEMS series public data set, which contains sensor data of multiple real-world connected roads, and the sensor aggregates the number of vehicles passing through, and the road topology connection structure information is obtained by preprocessing the connection information of the sensor, and is set to 1 if there is a connection, and is set to 0 if there is no connection, and the road itself is self-connected. 3.The urban traffic flow prediction method based on multiple space-time characteristics of road network according to claim 1, characterized in that: The historical traffic flow information is normalized in the form of range standardization, and the missing data in the information data collection process is filled by using a time series interpolation strategy. 4.The urban traffic flow prediction method based on multiple space-time characteristics of road network according to claim 1, characterized in that: A space-time feature tensor is constructed according to N roads and total T time steps , The dimension of the space-time feature tensor represents , wherein , The traffic flow observation value at time t represents The traffic flow observation value of road N at time t represents; extracting the road topology connection structure information of the observed road to construct an N*N road adjacency matrix .

5. The urban traffic flow prediction method based on multiple space-time characteristics of road network according to claim 1, characterized in that: The inverse wavelet transform module first receives the low-frequency features containing space-time characteristics and the high-frequency dynamic weight features, and then performs inverse restoration operation on the orthogonal wavelet basis used in the decomposition stage through parameter-bound orthogonal matrix inverse transformation.

6. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer program, when executed by a processor, implements the steps of the urban traffic flow prediction method based on the multiple space-time characteristics of the road network as claimed in any one of claims 1-5.

7. A computer device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, The processor executes the computer program to implement the steps of the urban traffic flow prediction method based on the multiple space-time characteristics of the road network as claimed in any one of claims 1-5.

Citation Information

Patent Citations

  • Traffic prediction method, system and device based on dynamic space-time diagram convolutional neural network, and medium

    CN117218837A

  • Time sequence prediction method and device based on period embedding and multi-scale features

    CN119622319A