A method for short-time traffic flow prediction on expressway based on accumulation of multi-path contribution
By constructing a directed graph and a multi-path contribution accumulation method with dynamic trend cycle correction, the problems of opaque decision logic and insufficient adaptability in short-term traffic forecasting of highways are solved, and accurate, traceable traffic forecasting and rapid response capabilities are achieved.
Patent Information
- Application Number
- CN202511636816.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-10
- Publication Date
- 2026-03-03
- Estimated Expiration
- 2045-11-10
AI Technical Summary
Existing methods for short-term traffic flow forecasting on highways suffer from problems such as opaque decision-making logic, poor interpretability, insufficient adaptability, and inability to quantitatively assess the dynamic interaction characteristics and spatiotemporal coupling mechanisms of the road network.
A multi-path contribution accumulation method is adopted, which constructs a directed graph for path retrieval and pruning, and combines dynamic trend cycle correction and closed-loop feedback system to achieve the accuracy and adaptability of traffic prediction. The perturbation factor and probability transition matrix are used for traffic transmission to establish a spatiotemporal coupling mechanism.
It improves the accuracy and traceability of traffic forecasting, enables rapid response to emergencies, reduces error accumulation, ensures the stability and adaptability of forecast results, and provides scientific decision support.
Smart Images

Figure CN121075137B_ABST
Abstract
Description
Technical Field
[0001] This invention specifically relates to a method for predicting short-term traffic flow on highways based on the accumulation of multi-path contributions. Background Technology
[0002] Short-term traffic flow forecasting for highways refers to the technology of predicting traffic flow on a specific road segment in real time over the next few hours using mathematical models and machine learning algorithms. Its core is to analyze historical traffic data, weather, holidays, and other factors, combined with real-time traffic information, to quickly generate minute-level or hourly traffic flow forecasts, providing decision support for traffic management and reducing congestion risks. Current mainstream solutions for short-term traffic flow forecasting on highways mostly use neural network models to achieve short-term prediction; however, short-term traffic flow forecasting for highways still has the following problems:
[0003] First, the internal decision-making logic of neural network models is opaque. When the prediction results deviate, it is impossible to trace when and by which path the traffic flow was obtained, nor can it provide a precise location area. The interpretability is poor and the error rate is too high. Second, when using neural network models to predict short-term traffic flow on highways, they cannot cope with sudden road conditions, have poor adaptability, and are inflexible in use. Third, in separating the processing of time series prediction and spatial topology transmission, it is easy to overlook the dynamic interaction characteristics of the road network. It is impossible to quantitatively evaluate the real-time prediction results after the upstream gantry of the highway has implemented scheduling and control measures, and there is a lack of spatiotemporal coupling mechanism.
[0004] Therefore, it is necessary to invent a method for short-term traffic flow prediction on highways based on the accumulation of multi-path contributions to solve the above problems. Summary of the Invention
[0005] The purpose of this invention is to provide a method for predicting short-term traffic flow on highways based on the accumulation of multi-path contributions, so as to solve the above-mentioned shortcomings in the technology.
[0006] To achieve the above objectives, the present invention provides the following technical solution: a method for short-term traffic flow prediction on highways based on multi-path contribution accumulation, comprising the following steps:
[0007] Step 1: Obtain the computable road network, observation data, and status of the highway, and process them to obtain the input data;
[0008] Step 2: Based on the input data, assuming the highway network is a directed graph, perform reverse path retrieval and pruning to obtain a list of multi-dimensional attribute information of paths that can be reached within the predicted time.
[0009] Step 3: Based on the minute-level traffic flow of the toll station, obtain the initial predicted traffic flow of the toll station, and combine the deviation of the initial basic predicted traffic flow with the dynamic trend cycle to generate the basic predicted traffic flow.
[0010] Step 4: Based on the multidimensional attribute information list of each path and the basic predicted traffic, obtain the total traffic of the target node within the prediction time.
[0011] Preferably, in step 1, the observation data is the vehicle passage record for each node, including license plate, vehicle type, passage time, and observed vehicle speed; the status includes: accident, weather, and maintenance; the computable road network includes: edges, node IDs, topological relationships, and corresponding distance weights, where edges are road segments and nodes are gantries / toll stations; the input data includes disturbance factors. OD probability Road section speed The system includes minute-level traffic flow and computable road network; both segment speed and minute-level traffic flow statistics are differentiated by vehicle type, including large vehicles and small vehicles; in OD probability, O represents the origin and D represents the destination, and OD probability represents the probability that at a certain node, traffic flow will choose to go to the next undetermined direction.
[0012] The specific steps to obtain the input data are as follows: 1.1 Calculate the disturbance factor using the following formula. :
[0013] ;
[0014] in, This is the weather impact coefficient, set to a range of [0,1]. The accident levels are set from 1 to 5. This is the maintenance impact coefficient. A value of 0 indicates no maintenance, and a value of 1 indicates complete closure. The coefficient for small cars or large vehicles is determined by weather conditions. Specifically: For a small car, For large vehicles; For each accident level, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles; Due to the impact of maintenance, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles;
[0015] 1.2 After the prediction task is initiated, the system first retrieves the observation data of the target gantry and its related road sections before the prediction time point;
[0016] Specifically, the 85th percentile of the vehicle speed observations for each road segment is calculated to obtain the segment speed of large vehicles / small vehicles in each road segment; the minute-level flow of large vehicles / small vehicles at each node is calculated based on the vehicle passage time records at each node; and the OD probability of large vehicles / small vehicles between nodes is calculated based on the minute-level flow of large vehicles / small vehicles at each node.
[0017] When road segment speed, minute-level flow rate, or OD probability is missing due to input errors, data acquisition interruptions, or equipment malfunctions, the system will automatically find and correct the missing values. These missing values include speed fill values. Flow fill value OD fill value ;
[0018] The specific steps for automatically finding and correcting fill values are as follows:
[0019] 1.2.1. Cross-group road segment speed, minute-level traffic flow, and OD probability by time period and date;
[0020] The time periods are divided into morning, evening, early morning, morning peak, and evening peak; the dates are divided into weekdays and holidays.
[0021] 1.2.2. The 85th percentile of the historical road segment data for each group is used as the baseline speed. Based on the perturbation factor Calculate speed fill value The specific calculation formula is as follows:
[0022] ;
[0023] 1.2.3. For the probability of missing ODs in road segments, the default value of the same period is used as the OD filling value. ;
[0024] 1.2.4 For minute-level traffic flow at missing gantries / toll stations on road sections, the default value for the same period is used as the traffic flow fill value. ;
[0025] Among them, the default value for the same period refers to the historical OD probability or historical minute-level traffic flow under the same day, time period, road segment, and vehicle type last week;
[0026] 1.2.3 Filling values using velocity OD fill value Flow fill value The correction and filling are used to obtain the final input of road segment speed, minute-level flow rate, and OD probability;
[0027] 1.3 Obtain the computable road network.
[0028] Preferably, in step 2, a directed graph is provided. ,and ; This refers to the set of nodes for gantries and toll stations. ; Let be a set of directed edges. The multi-dimensional attribute information list includes: total dynamic passage time. Total OD probability Path dynamic travel time ;
[0029] Obtaining the reachable paths and their corresponding multidimensional attribute information list includes the following steps:
[0030] 2.1 Using the target node as the root node of the current search, perform reverse path retrieval to obtain the set of all paths within the directed graph. ;
[0031] 2.2 For all paths, let the source node be... Calculation path The total dynamic passage time is The calculation formula is as follows:
[0032] ;
[0033] in, ; s is the target node; For a line from The directed path to s consists of a series of ordered road segments. ,and ;e ij For path A directed road segment on the road, its direction starting from node Pointing to node ,and , for The 1 node for The 1 node ; For path A series of intermediate nodes passed through; For the node sequence The next node; For application to road segment e ij The larger the disturbance factor, the more severe the delay caused by congestion, accidents, etc., on that road section, and the greater the actual travel time is compared to the basic travel time. for The basic passage time, and , for distance, for Speed limits on the road section;
[0034] 2.3. Only retain nodes that meet the time constraints, and calculate the total dynamic passage time. and source node to downstream nodes Road section passage time Add nodes to the reachable domain set and continue traversing. Terminate the traversal when all possible nodes have been visited and evaluated, and output the final reachable domain. ;
[0035] The time constraints are specifically as follows: , For the total forecast duration, such as ;
[0036] 2.4 Calculate the reachable region The source node of each path to downstream nodes Path dynamic travel time and the total OD probability O p The specific formula is as follows:
[0037] ;
[0038] ;
[0039] For nodes arrive OD probability; for arrive The permitted travel time for the road section; for arrive The perturbation factor; This is the error attenuation factor, used to reflect the strength of the probability attenuation due to path distance. ; It is a natural constant; The symbol for multiplication;
[0040] 2.5 Store the multidimensional attributes of each node in each path to obtain a list of multidimensional attribute information of paths that can be reached within the predicted time.
[0041] Preferably, in step 3, based on the minute-level traffic flow of the toll station, the initial predicted traffic flow of the toll station is obtained. The deviation of the initial basic predicted traffic flow is then corrected using a dynamic trend cycle to generate the basic predicted traffic flow, including the following steps:
[0042] 3.1 Calculate the minute-level traffic characteristics and real-time status characteristics of the data, as detailed below:
[0043] Data minute-level traffic characteristics The calculation formula is:
[0044] ;
[0045] in, For historical reference days; To predict the time, ; For time intervals; It is a loop variable, and ; for Flow rate at any given moment;
[0046] Real-time status characteristics of data The calculation formula is:
[0047] ;
[0048] in, This represents the current queue length. Instantaneous throughput; This is the adjustment coefficient; This represents the maximum queue length. To achieve the maximum pass rate;
[0049] 3.2. The minute-level traffic characteristics and real-time status characteristics of the data are independently normalized to obtain... The specific formula is as follows:
[0050] ;
[0051] in, Substitute and ; For normalized ,Right now and ; for and The maximum value; for and The minimum value;
[0052] 3.3. Based on minute-level data flow characteristics and real-time data status characteristics, generate... Initial predicted flow at time The specific formula is as follows:
[0053] ;
[0054] in, Weights for minute-level data traffic characteristics; Weights for real-time status features of the data;
[0055] The perturbation factor weights are defined by the following constraints: , ; yes The perturbation factor at any given moment;
[0056] 3.4. Based on the dynamic trend cycle, the error of the initial predicted flow is calculated. The specific formula is as follows:
[0057] ;
[0058] in, It is a function for maximizing the value; for + The observed flow rate at any given time; for + Error value at any given time;
[0059] 3.5 Based on error value To correct the deviation of the initial predicted flow, a closed-loop feedback system is established to achieve adaptive parameter optimization. The specific process is as follows:
[0060] when The weights are dynamically adjusted as needed.
[0061] 3.6 Update the weights of minute-level data flow characteristics, real-time data status characteristics, and disturbance factor weights. The specific formulas are as follows:
[0062] ;
[0063] in, = , , ; The rate factor for weight adjustment; The updated weights; These are the original weights;
[0064] 3.7, will Substituting into the predicted flow calculation formula, we obtain the basic predicted flow. The specific formula is as follows:
[0065] .
[0066] Preferably, in step 4, based on the multi-dimensional attribute information list of each path and the basic predicted traffic, the total traffic of the target node s within the prediction time T is obtained. The specific steps are as follows:
[0067] 4.1 Map the minute-level traffic time window of each path to the predicted traffic time window according to the causal law of spatiotemporal transmission, and determine the path and its historical traffic time window according to the nearest priority principle, thus obtaining... Minute-level traffic ;
[0068] 4.2, Regarding The weighted flow is then calculated to obtain the weighted predicted flow. The specific formula is as follows:
[0069] ;
[0070] 4.3, will By aggregating the paths, we obtain the predicted flow rate of the target prediction point s at time t. The specific formula is as follows:
[0071] ;
[0072] 4.4 will Aggregated by time, we get The specific formula is as follows:
[0073] ;
[0074] in, For predicting time Total flow within; For path right Traffic contribution at any given moment; Let be the set of all feasible paths pointing to s.
[0075] Preferably, in step 4.1, the minute-level traffic time window for each path is mapped to the predicted traffic time window according to the causal law of spatiotemporal transmission, that is, Leave at any time Should be in The vehicle that arrives at time s;
[0076] Based on the nearest-first principle, the path and its historical traffic time window are determined to obtain the minute-level traffic at time t. The specific steps are as follows:
[0077] 4.1.1, downstream nodes Record For path depth of path ,but ;
[0078] 4.1.2 Calculation Path The traffic mapping time window and its historical traffic time window, specifically: in a path with a path depth of 1 In the middle, the source node is directly connected to The path format is →s, total dynamic passage time is ;
[0079] For the path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ];
[0080] On a path with a path depth of 2 In this process, the source node is connected to the intermediate node. The path format is →s, total dynamic passage time is + Dynamic travel time along the route = - ;
[0081] For path The contribution of the path needs to be removed from the traffic contribution. The covered time period has a traffic mapping time window of [[ + , + The historical traffic time window for tracing is [ - , ];
[0082] On a path with path depth k In the middle, the path form is →…→ s, total dynamic passage time is The dynamic travel time for the route is ;
[0083] For path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ];
[0084] 4.1.3. Let the target traffic mapping time window be... The historical traffic time window is [ - , Based on this, a traffic redistribution algorithm is used to calculate minute-level traffic. ;
[0085] The target traffic mapping time window can be an integer or a non-integer.
[0086] Preferably, in step 4.1.3, a traffic redistribution algorithm is used to calculate minute-level traffic. Specifically:
[0087] The target traffic is reallocated to each minute within the time window to calculate the path. The contributed historical traffic is obtained in minute-level traffic. The specific steps are as follows:
[0088] A. Predicted time The historical traffic mapping time window traced in minutes belongs to Corresponding path No. Minutes later, the minutes and the Minutes earlier;
[0089] in, , , Historical traffic time window for tracing [ - , ];
[0090] B. Path The flow rate of the source gantry is calculated in seconds. The proportion is allocated to the prediction time, and the mapping result for each minute of the prediction time is calculated, specifically B1, let the first minute be B1. The historical traffic for minutes is as follows Calculation path Historical traffic allocation to the first minutes of data The specific formula is as follows:
[0091] ;
[0092] in, The offset in seconds when aligning to minutes; if =0 indicates a one-to-one correspondence between the historical traffic time window and the target traffic mapping time window; if This indicates that the mapping between the two time windows has a time offset;
[0093] B2. Calculation Path The historical flow of the source gantry u is allocated to the target minute. The flow rate is calculated using the following formula:
[0094] ;
[0095] B3. For each minute within the target minute, repeat the calculation in step B2 until the path is obtained. exist ∈[ , + The flow rate per minute within [the specified range] Specifically:
[0096] ;
[0097] in, .
[0098] Preferably, in step 4.1.2, for the deepest path, if Call the toll station's basic predicted traffic. As ;
[0099] Its basic forecast flow time window ∈[ , Traffic mapping to The historical traffic time window for tracing is [ , T];
[0100] and This indicates that the source node is a toll station without an upstream topological relationship.
[0101] Compared with the prior art, the beneficial effects of the present invention are:
[0102] 1. This invention combines a computable road network with real-time travel time to construct a directed graph with spatiotemporal weights, and performs path pruning, which can greatly reduce invalid calculations; furthermore, it prioritizes the use of historical data from the nearest upstream node to predict the traffic flow at the target time, thereby reducing accumulated errors.
[0103] 2. This invention is based on the probability distribution of historical / real-time data. The probability of a vehicle moving from one gantry to another is adjusted according to an error attenuation factor. The accuracy of upstream gantry traffic flow prediction is transmitted to downstream gantry through a probability transfer matrix, forming an accuracy recursion mechanism. That is, the probability transfer matrix achieves the recursive transmission of upstream gantry traffic flow prediction accuracy, effectively controlling the error accumulation effect. The upstream prediction error is attenuated rather than nonlinearly amplified during transmission, allowing the downstream gantry's prediction accuracy to inherit and optimize the upstream prediction results. Simultaneously, this mechanism enhances the traceability of prediction results, clearly tracing the transmission path and sources of influence of traffic flow prediction, providing a scientific basis for subsequent prediction optimization.
[0104] 3. This invention transforms dynamic disturbance factors such as accidents, weather, and maintenance into real-time correction factors. Through closed-loop feedback, it dynamically adjusts the traffic transmission weights to achieve perception, prediction, correction, and end-to-end response. This enables the system to achieve real-time adaptive capability, quickly respond to emergencies, automatically adjust prediction model parameters, and continuously improve the accuracy of the prediction model through continuous learning and adjustment. In case of sudden road conditions, it can quickly adjust the traffic transmission strategy and effectively reduce prediction deviation. This end-to-end response mechanism ensures that the system can maintain high prediction accuracy and stability when facing complex and ever-changing traffic environments.
[0105] 4. This invention employs a spatiotemporal conservation model based on the pigeonhole principle. Within a certain time window, the total number of vehicles entering the reachable domain is equal to the superposition of traffic flows from each gantry. This establishes a spatiotemporally coupled prediction basis. Through this probability allocation mechanism, accurate calculation and allocation of traffic flow can be achieved, ensuring that traffic flow prediction conforms to the physical conservation law and avoiding unreasonable traffic flow allocation. At the same time, the system can dynamically adjust the reachable domain range to adapt to different prediction needs, providing a solid physical basis for traffic flow prediction.
[0106] 5. This invention breaks through the mapping barrier between minute-level traffic data and continuous traffic time by using a minute-level sliding window to divide non-integer passage time into seconds-level segments, achieving a significant improvement in time accuracy. The system can handle more precise time modeling requirements, improve the time continuity of the model, thereby maximizing the use of existing traffic data and improving the timeliness of prediction. It finds the optimal balance between accuracy and computational efficiency, and realizes high-precision traffic prediction for short-term traffic flow on highways.
[0107] 6. This invention proposes a penetrating impact assessment of road speed limit and toll station closure control commands. When a toll station is closed, the basic predicted traffic flow of that toll station is directly reset to zero. When a speed limit is implemented, the travel time is recalculated in real time. This allows for real-time quantification of the specific impact of control measures on traffic flow. The system can provide traffic management departments with scientific decision support and dynamically adjust the prediction model according to changes in control measures. This mechanism also has an effect verification function, which can verify the actual effect of control measures. Attached Figure Description
[0108] Figure 1 This is a flowchart of the present invention;
[0109] Figure 2 This is a schematic diagram of the spatiotemporal allocation of the present invention;
[0110] Figure 3 This is a demonstration diagram of a typical ideal long path in this invention;
[0111] Figure 4 This is a partial path demonstration diagram of the actual business process in this invention;
[0112] Figure 5 This is a partial path demonstration diagram of the actual business process in this invention;
[0113] Figure 6 This is a partial path demonstration diagram of the actual business process in this invention. Detailed Implementation
[0114] To enable those skilled in the art to better understand the technical solution of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings.
[0115] This invention provides the following: Figure 1 -Appendix Figure 6 The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation, as shown, includes the following steps:
[0116] Step 1: Obtain the computable road network, observation data, and status of the highway, and process them to obtain the input data;
[0117] The observation data includes vehicle passage records for each node, including license plate number, vehicle type, passage time, and observed vehicle speed; status includes: accident, weather, and maintenance; the computable road network includes: edges, node IDs, topological relationships, and corresponding distance weights, where edges represent road segments and nodes represent gantries / toll stations; input data includes disturbance factors. OD probability Road section speed The system includes minute-level traffic flow and computable road network; both segment speed and minute-level traffic flow statistics are differentiated by vehicle type, including large vehicles and small vehicles; in OD probability, O represents the origin and D represents the destination, and OD probability represents the probability that at a certain node, traffic flow will choose to go to the next undetermined direction.
[0118] The specific steps to obtain the input data are as follows:
[0119] 1.1 The disturbance factor is calculated using the following formula. :
[0120] ;
[0121] in, This is the weather impact coefficient, set to a range of [0,1]. The accident levels are set from 1 to 5. This is the maintenance impact coefficient. A value of 0 indicates no maintenance, and a value of 1 indicates complete closure. The coefficient for small cars or large vehicles is determined by weather conditions. Specifically: For a small car, For large vehicles; For each accident level, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles; Due to the impact of maintenance, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles;
[0122] 1.2 After the prediction task is initiated, the system first retrieves the observation data of the target gantry and its related road sections before the prediction time point;
[0123] Specifically, the 85th percentile of the vehicle speed observations for each road segment is calculated to obtain the segment speed of large vehicles / small vehicles in each road segment; the minute-level flow of large vehicles / small vehicles at each node is calculated based on the vehicle passage time records at each node; and the OD probability of large vehicles / small vehicles between nodes is calculated based on the minute-level flow of large vehicles / small vehicles at each node.
[0124] The OD probability describes the path selection behavior of traffic flow at road network nodes, directly reflecting the tendency of traffic flow to choose the next node. When segment speed, minute-level traffic flow, or OD probability is missing due to input errors, data collection interruptions, or equipment malfunctions, the system will automatically find and correct the missing values. These filler values include speed filler values. Flow fill value OD fill value ;
[0125] The specific steps for automatically finding and correcting fill values are as follows:
[0126] 1.2.1. Cross-group road segment speed, minute-level traffic flow, and OD probability by time period and date;
[0127] The time periods are divided into morning, evening, early morning, morning peak, and evening peak; the dates are divided into weekdays and holidays.
[0128] 1.2.2. The 85th percentile of the historical road segment data for each group is used as the baseline speed. Based on the perturbation factor Calculate speed fill value The specific calculation formula is as follows:
[0129] ;
[0130] In this formula, the larger the ϕ value, such as W=1 in heavy rain and A=5 in major accidents, the lower the filling speed, which conforms to the degradation logic of actual road conditions.
[0131] 1.2.3. For the probability of missing ODs in road segments, the default value of the same period is used as the OD filling value. ;
[0132] 1.2.4 For minute-level traffic flow at missing gantries / toll stations on road sections, the default value for the same period is used as the traffic flow fill value. ;
[0133] Among them, the default value for the same period refers to the historical OD probability or historical minute-level traffic flow under the same day, time period, road segment, and vehicle type last week;
[0134] 1.2.3 Filling values using velocity OD fill value Flow fill value The correction and filling are used to obtain the final input of road segment speed, minute-level flow rate, and OD probability;
[0135] 1.3 Obtain the computable road network. The specific process is as follows:
[0136] The specific method for obtaining the computable road network is consistent with the method published in the document entitled "Method for Constructing Computable Road Networks", which has the publication number CN120508601A, thereby obtaining the computable road network of the expressway.
[0137] In step 1, the system can flexibly retrieve the attributes of arbitrary paths, nodes, and edges in subsequent analysis, achieving efficient traffic allocation and path tracing in large-scale road networks. Data loading is dynamic, and the calculation involves large-scale trajectory matching, such as vehicle... The path probability allows calculation of only the current prediction window, such as the next hour, which can greatly reduce invalid calculations and reduce the complexity of calculations.
[0138] Step 2: Based on the input data, assuming the highway network is a directed graph, use the BFS algorithm to perform reverse path retrieval and pruning to obtain a list of multi-dimensional attribute information of paths that can be reached within the predicted time.
[0139] Among them, there is a directed graph. ,and ; This refers to the set of nodes for gantries and toll stations. ; Let be a set of directed edges. The multi-dimensional attribute information list includes: total dynamic passage time. Total OD probability Path dynamic travel time ;
[0140] Obtaining the reachable paths and their corresponding multidimensional attribute information list includes the following steps:
[0141] 2.1 Using the target node as the root node of the current search, perform reverse path retrieval to obtain the set of all paths within the directed graph. ;
[0142] 2.2 For all paths, let the source node be... Calculation path The total dynamic passage time is The calculation formula is as follows:
[0143] ;
[0144] in, ; s is the target node; For a line from The directed path to s consists of a series of ordered road segments. ,and ;e ij For path A directed road segment on the road, its direction starting from node Pointing to node ,and , for The 1 node for The 1 node ; For path A series of intermediate nodes passed through; For the node sequence The next node; For application to road segment e ij The larger the disturbance factor, the more severe the delay caused by congestion, accidents, etc., on that road section, and the greater the actual travel time is compared to the basic travel time. for The basic passage time, and , for distance, for Speed limits on the road section;
[0145] 2.3. Only retain nodes that meet the time constraints, and calculate the total dynamic passage time. and source node to downstream nodes Road section passage time Add nodes to the reachable domain set and continue traversing. Terminate the traversal when all possible nodes have been visited and evaluated, and output the final reachable domain. ;
[0146] The time constraints are specifically as follows: , Total forecast duration;
[0147] 2.4 Calculate the reachable region The source node of each path to downstream nodes Path dynamic travel time and the total OD probability O p The specific formula is as follows:
[0148] ;
[0149] ;
[0150] For nodes arrive OD probability; for arrive The permitted travel time for the road section; for arrive The perturbation factor; This is the error attenuation factor, used to reflect the strength of the probability attenuation due to path distance. ; It is a natural constant; The symbol for multiplication;
[0151] 2.5 Store the multidimensional attributes of each node in each path to obtain a list of multidimensional attribute information of paths that can be reached within the predicted time.
[0152] In step 2, the probability transfer chain transmission mechanism calculates the traffic of each path based on the probability distribution of historical / real-time data. It can be dynamically adjusted according to the path status, so that the accuracy of upstream gantry traffic prediction will be transmitted to downstream gantry through the probability transfer matrix, forming an "accuracy recursion" mechanism. The path information is stored in a dictionary structure, which is convenient for subsequent traffic decomposition, tracking and reuse.
[0153] Step 3: Based on the minute-level traffic flow at the toll station, obtain the initial predicted traffic flow for the toll station. Then, combine this with a dynamic trend cycle to correct the deviation of the initial basic predicted traffic flow, generating the basic predicted traffic flow. This includes the following steps:
[0154] 3.1 Calculate the minute-level traffic characteristics and real-time status characteristics of the data, as detailed below:
[0155] Data minute-level traffic characteristics The calculation formula is:
[0156] ;
[0157] in, For historical reference days; To predict the time, ; For time intervals; It is a loop variable, and ; for Flow rate at any given moment;
[0158] Real-time status characteristics of data The calculation formula is:
[0159] ;
[0160] in, This represents the current queue length. Instantaneous throughput; This is the adjustment coefficient; This represents the maximum queue length. To achieve the maximum pass rate;
[0161] 3.2. The minute-level traffic characteristics and real-time status characteristics of the data are independently normalized to obtain... The specific formula is as follows:
[0162] ;
[0163] in, Substitute and ; For normalized ,Right now and ; for and The maximum value; for and The minimum value;
[0164] 3.3. Based on minute-level data flow characteristics and real-time data status characteristics, generate... Initial predicted flow at time The specific formula is as follows:
[0165] ;
[0166] in, Weights for minute-level data traffic characteristics; Weights for real-time status features of the data;
[0167] The perturbation factor weights are defined by the following constraints: , ; yes The perturbation factor at any given moment;
[0168] 3.4. Based on the dynamic trend cycle, the error of the initial predicted flow is calculated. The specific formula is as follows:
[0169] ;
[0170] in, It is a function for maximizing the value; for + The observed flow rate at any given time; for + Error value at any given time;
[0171] 3.5 Based on error value To correct the deviation of the initial predicted flow, a closed-loop feedback system is established to achieve adaptive parameter optimization. The specific process is as follows:
[0172] when The weights are dynamically adjusted as needed.
[0173] 3.6 Update the weights of minute-level data flow characteristics, real-time data status characteristics, and disturbance factor weights. The specific formulas are as follows:
[0174] ;
[0175] in, = , , ; The rate factor for weight adjustment; The updated weights; These are the original weights;
[0176] 3.7, will Substituting into the predicted flow calculation formula, we obtain the basic predicted flow. The specific formula is as follows:
[0177] ;
[0178] In step 3, the three types of features are weighted and combined to process the path and information list, thereby achieving adaptive parameter optimization and accurately obtaining the basic predicted traffic flow of the toll station in the future.
[0179] Step 4: Based on the multi-dimensional attribute information list of each path and the basic predicted traffic, obtain the total traffic of the target node s within the prediction time T. The specific steps are as follows:
[0180] 4.1 Map the minute-level traffic time window of each path to the predicted traffic time window according to the causal law of spatiotemporal transmission, and determine the path and its historical traffic time window according to the nearest priority principle, thus obtaining... Minute-level traffic ;
[0181] In this context, the minute-level traffic time window for each path is mapped to the predicted traffic time window according to the causal law of spatiotemporal transmission, which is... Leave at any time Should be in The vehicle that arrives at time s;
[0182] Based on the nearest-first principle, the path and its historical traffic time window are determined to obtain the minute-level traffic at time t. The specific steps are as follows:
[0183] 4.1.1, downstream nodes Record For path depth of path ,but ;
[0184] 4.1.2 Calculation Path The traffic mapping time window and its historical traffic time window, specifically: in a path with a path depth of 1 In the middle, the source node is directly connected to The path format is →s, total dynamic passage time is ;
[0185] For path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ];
[0186] On a path with a path depth of 2 In this process, the source node is connected to the intermediate node. The path format is →s, total dynamic passage time is + Dynamic travel time along the route = - ;
[0187] For path The contribution of the path needs to be removed from the traffic contribution. The covered time period has a traffic mapping time window of [[ + , + The historical traffic time window for tracing is [ - , ];
[0188] On a path with path depth k In the middle, the path form is →…→ s, total dynamic passage time is The dynamic travel time for the route is ;
[0189] For path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ];
[0190] 4.1.3. Let the target traffic mapping time window be... The historical traffic time window is [ - , Based on this, a traffic redistribution algorithm is used to calculate minute-level traffic. ;
[0191] Wherein, the target traffic mapping time window is an integer or a non-integer, and The specific calculation steps are as follows:
[0192] The target traffic is reallocated to each minute within the time window to calculate the path. The contributed historical traffic is obtained in minute-level traffic. The specific steps are as follows:
[0193] A. Predicted time The historical traffic mapping time window traced in minutes belongs to Corresponding path No. Minutes later, the minutes and the Minutes earlier;
[0194] in, , , Historical traffic time window for tracing [ - , ];
[0195] B. Path The flow rate of the source gantry is calculated in seconds. The proportion is allocated to the prediction time, and the mapping result for each minute of the prediction time is calculated, specifically as follows:
[0196] B1, let the first The historical traffic for minutes is as follows Calculation path Historical traffic allocation to the first minutes of data The specific formula is as follows:
[0197] ;
[0198] in, This is the number of seconds offset when aligning to minutes; see attached. Figure 2 As shown, if =0 indicates a one-to-one correspondence between the historical traffic time window and the target traffic mapping time window; if This indicates that the mapping between the two time windows has a time offset;
[0199] B2. Calculation Path The historical flow of the source gantry u is allocated to the target minute. The flow rate is calculated using the following formula:
[0200] ;
[0201] B3. For each minute within the target minute, repeat the calculation in step B2 until the path p is obtained. ∈[ , + The flow rate per minute within [the specified range] Specifically:
[0202] ;
[0203] in, ;
[0204] Among them, for the deepest path, if Call the toll station's basic predicted traffic. As ;
[0205] Among them, the basic forecast flow time window ∈[ , Traffic mapping to The historical traffic time window for tracing is [ , T];
[0206] in, This indicates that its source node is a toll station with no upstream topological relationship;
[0207] 4.2, Regarding The weighted flow is then calculated to obtain the weighted predicted flow. The specific formula is as follows:
[0208] ;
[0209] 4.3, will By aggregating the paths, we obtain the predicted flow rate of the target prediction point s at time t. The specific formula is as follows:
[0210] ;
[0211] 4.4 will Aggregated by time, we get The specific formula is as follows:
[0212] ;
[0213] in, For predicting time Total flow within; For path right Traffic contribution at any given moment; For all pointers The set of feasible paths.
[0214] In step 4, by introducing a conservation error, a nearest-first principle is proposed as a constraint. The contribution of shallower paths (closer to the target node) is calculated first, and time periods already covered by shallower paths are removed from the contributions of deeper paths (farther from the target node). This ensures traffic conservation, avoids duplicate traffic calculations, and achieves the target node's goal. High-precision flow prediction.
[0215] Verification Experiment
[0216] Taking any target gantry in the computable road network of a certain expressway as an example, an experiment is conducted to verify the precision of the expressway short-term traffic flow prediction method (hereinafter referred to as the system) based on multi-path contribution accumulation proposed in this application. The specific steps are as follows:
[0217] I. Data Preprocessing and Dynamic Loading
[0218] After the prediction task is initiated, the system first retrieves all observation data of the target gantry and its related road sections within the first 30 minutes of the prediction period;
[0219] If the traffic flow of gantry A is predicted from 13:00:00 to 13:30:59 on a certain day, the system automatically summarizes about 12,000 vehicle passage records from 12:30:00 to 12:59:59, covering information such as license plate, vehicle type, passage time, gantry / toll station ID;
[0220] The system extracts minute-by-minute speed observations of large and small vehicles (e.g., from 12:57:00 to 12:57:59, the 85th percentile speed of small vehicles is 100 km / h, and that of large vehicles is 70 km / h), as well as real-time OD (Original Displacement) probabilities calculated every 15 minutes (e.g., from 12:45:00 to 12:59:59, the probability for small vehicles in the main lane is 0.72, and in the diversion lane it is 0.35; for large vehicles, the probability in the main lane is 0.91, and in the diversion lane it is 0.15). In addition, the system also simultaneously acquires the current weather (e.g., moderate rain). Accidents (such as two minor accidents) ), maintenance (such as stage 1 maintenance) Disturbance factors such as )
[0221] After the observation data is loaded, the system automatically loads the computable road network (networkx graph structure) of the entire expressway network in Jiangsu Province, including all gantry / toll station nodes, road segment distances, spatial relationships, etc. in Jiangsu Province. This enables the system to flexibly retrieve the attributes of any path, node, and edge in subsequent analysis, and achieve efficient traffic allocation and path tracking under a large-scale road network.
[0222] In actual operations, observation data for some road segments or time periods may be missing due to equipment failures or other reasons. In such cases, the system will automatically search for and fill in the missing data using the historical 85th percentile speed or OD transition probability for the same day, time period, and road segment (and vehicle type) from the previous week. For example, if the speed of cars on a certain road segment during the morning rush hour on Tuesday of this week is missing, the system will prioritize using the 85th percentile speed of cars on that road segment during the morning rush hour on Tuesday of last week as the filler value. If historical data under the same group is also unavailable, a larger range of groups (such as the historical 85th percentile speed or OD probability of the same time period + date type) will be used to supplement the data. For missing traffic at the minute level, the system will perform spatial compensation calculations by combining the real-time traffic and OD probability of upstream facilities. All default values are stored in a multi-dimensional classification default data table to ensure that the filling process is efficient and reasonable.
[0223] II. Construction and Storage of Path Information
[0224] The system is based on the entire network structure and employs a reverse breadth-first search algorithm, as detailed in the attached diagram. Figure 3 As shown, its appendix Figure 3 -Appendix Figure 6 In the diagram, L, K, K1, A, B, C, and D are all highway gantry / toll station nodes, xc represents a car, and dc represents a truck. With the target node s as the root node, the following three paths can be identified:
[0225] L → s, K → L → s, K1 → K → L → s;
[0226] Dynamic calculation in the prediction time window T =All upstream nodes and paths reachable within 30 minutes. The system calculates the following feasible paths: Path 1: L → s, Path 2: K → L → s;
[0227] The system automatically extracts and calculates the following attributes:
[0228] Distance between road segments: K→L is 2000 meters, L→s is 3000 meters, total path distance rice;
[0229] Observed speeds: The 85th percentile speed of the small car from K to L is 100 km / h, and from L to s it is 90 km / h, while the speeds of the large car are 70 km / h and 60 km / h respectively;
[0230] Travel time: 10 minutes for cars from K to L, and 20 minutes for cars from L to S; 17 minutes for cars from K to L, and 25 minutes for cars from L to S.
[0231] Disturbance factor:
[0232] For the car: if the perturbation factor for K→L is 1.1 and the perturbation factor for L→s is 1.6, then the weighted travel time for K→L is... The passage time for L→s is Total travel time for cars minute;
[0233] Large vehicles: Weighted travel time from K to L is The passage time for L→s is Total travel time for large vehicles minute;
[0234] OD transition probability: 0.75 for the car from K to L, 0.68 for L to s, and the total OD probability of the path. The probability of OD for the K→L large vehicle is 0.55, and for the L→s vehicle it is 0.78. ;
[0235] The system then stores the attributes of each feasible path in a structured dictionary format, such as:
[0236] Path 1: {“path”: [“L”, “s”], “tau_xc”: 32, “total_tau_xc”: 32, “od_prob_xc”: 0.68, “speed_xc”:
[90] , “tau_dc”: 40, “total_tau_dc”: 40, “od_prob_dc”: 0.68, “speed_dc”:
[60] , “phi”: [1.6]};
[0237] Path 2: {"path": ["K", "L", "s"], "tau_xc": 11, "total_tau_xc": 42, "od_prob_xc": 0.51, "speed_xc": [100, 90], "tau_dc": 18.7, "total_tau_dc": 58.7, "od_prob_dc": 0.429, "speed_dc": [70, 60] , "phi": [1.1, 1.6]};
[0238] The system automatically caches all reachable domain nodes and their path relationships as a subgraph structure, which facilitates subsequent traffic decomposition, tracking and reuse. This subgraph only contains nodes and paths reachable within the prediction time window, which greatly improves the computational efficiency under large-scale road networks.
[0239] Through the above process, the system can dynamically and in batches generate all feasible paths and their attributes for the target node s in complex highway networks, providing efficient and structured data support for subsequent algorithms such as traffic prediction and path contribution allocation. Even if the road network structure is complex, the system can complete path enumeration and attribute calculation within seconds, meeting the real-time requirements of large-scale highway traffic prediction.
[0240] III. Traffic Flow Prediction for Edge Gantry / Toll Stations
[0241] After the test task is started, the system automatically retrieves minute-level traffic data of the target node at the same time period in the past 7 days as a historical reference. At the same time, the system obtains the current queue length (e.g., 120 vehicles) and instantaneous throughput (e.g., 110 vehicles per minute) in real time, and collects disturbance information such as weather (e.g., moderate rain), accidents (e.g., 2 minor accidents), and maintenance (e.g., 1 maintenance section) simultaneously. All data is automatically normalized to facilitate subsequent fusion.
[0242] The system weights and fuses multiple features, including historical traffic average, real-time queuing and throughput, and disturbance factors, to quickly generate a basic prediction result. For example, if the historical average is 420 vehicles / minute, the real-time status feature is normalized to 0.68, and the disturbance factor is 1.12, the system automatically assigns weights and calculates a preliminary predicted traffic flow of approximately 211 vehicles / minute. To improve prediction accuracy, the system automatically analyzes the traffic flow trend over the past 5 minutes (e.g., an average increase of 15 vehicles per minute) and compares it with the same period last week and the historical average to obtain periodic deviations (e.g., +10 vehicles / minute). Based on this, the system corrects the preliminary prediction result, and finally outputs a predicted traffic flow of approximately 221 vehicles / minute.
[0243] After the prediction results are generated, the system will continuously monitor the actual observed traffic flow (e.g., 240 vehicles / minute) and automatically calculate the error (0.079 in this example). If the error is found to be consistently large, the system will automatically adjust the weights of each feature and the correction parameters to ensure that the model is adaptively optimized and the prediction results are more in line with reality.
[0244] In actual operation, if a toll station is temporarily closed, the system will automatically set the predicted traffic flow of that node to zero. If a speed limit is imposed on a certain road section, the system will automatically adjust the passage time and traffic flow prediction of the relevant routes to ensure that the prediction results reflect the latest control measures in real time.
[0245] IV. Path Contribution Cumulative Prediction Model
[0246] Taking an ideal, typical long path A→B→C→D→s as an example, and using the calculation for a small car as an example (the calculation for a large car is similar), the details are as follows (see attached). Figure 4 As shown, the system predicts the flow rate of the target gantry node s from 17:00 to 17:30, specifically as follows:
[0247] Assume the travel time for each road segment is as follows: A→B: 8 minutes, B→C: 7 minutes, C→D: 9 minutes, D→s: 6 minutes. Then the total travel time for the path A→B→C→D→s is 8+7+9+6=30 minutes, which exactly fills the prediction window.
[0248] Based on the spatiotemporal offset of the path, the system needs to trace the traffic data of each upstream node during the corresponding time period: Node D: Vehicles need to arrive at s between 17:00 and 17:29, and must pass through D between 16:54 and 17:23 (i.e., 17:00 - 6 minutes to 17:29 - 6 minutes); Node C: These vehicles need to pass through C between 16:45 and 17:14 (i.e., 16:54 - 9 minutes to 17:23 - 9 minutes); Node B: These vehicles need to pass through B between 16:38 and 17:07 (i.e., 16:45 - 7 minutes to 17:14 - 7 minutes); Node A: These vehicles need to pass through node A between 16:30 and 16:59 (i.e., 16:38 - 8 minutes to 17:07 - 8 minutes); where any node time refers to the complete time interval from the start second to the end second of that minute, such as 16:59 which refers to the complete 1-minute time interval from 16:59:00 to 16:59:59; node D: Theoretically, for a vehicle to arrive at node S between 17:00 and 17:29, it needs to pass through node D between 16:54 and 17:24. However, since only observation data up to 16:59 is available in actual operations, the observation data for node D is not yet available for the first 9 minutes of the prediction window (i.e., 17:00-17:08). At this time, the system will automatically use data from an earlier period of node C to fill in the gaps. Specifically, for the traffic prediction of the 9 minutes from 17:06 to 17:14 passing through target node s, the data from the upstream node C passing through from 16:51 to 16:59 will be used instead, thus ensuring that a reasonable upstream traffic input can be obtained for every minute within the prediction window. Similarly, for the predicted traffic flow passing through target node s from 17:15 to 17:21 and from 17:22 to 17:29, the system will automatically send data to the upstream nodes (B, A) to ensure that the prediction input for each minute is complete and continuous. Although the traffic flow data of node A from 16:30 to 16:59 can be used to replace the traffic flow that reaches node s within half an hour, considering the significant differences in key parameters such as disturbance factors and traffic speed among different road segments, adopting the proximity principle can effectively reduce the accumulation of errors in traffic flow prediction.
[0249] The core concept of the proximity principle is: prioritize the node data that is spatially closer to the target node s as the basis for traffic calculation, and only consider using the data of the second nearest neighbor node as an alternative when the data of the nearest neighbor node cannot meet the calculation accuracy requirements.
[0250] Based on the aforementioned tracing and completion mechanism, the system sequentially extracts the minute-by-minute traffic data for nodes A, B, C, and D within the required historical time period. Specifically: for the predicted traffic of node s from 17:00 to 17:05 (6 minutes), the system directly uses the minute-by-minute traffic data of node D from 16:54 to 16:59 to complete the data; for the predicted traffic of node s from 17:06 to 17:14, the system uses the observation data of node C from 16:51 to 16:59; for the predicted traffic of node s from 17:15 to 17:21, the system uses the observation data of node B from 16:53 to 16:59; and for the predicted traffic of node s from 17:22 to 17:29, the system uses the observation data of node A from 16:52 to 16:59. All extracted historical traffic data is in minute format, precisely corresponding to each minute within the prediction window.
[0251] After completing the spatiotemporal overlap allocation of historical traffic for each node, the system also needs to weight the OD transition probability of the traffic at each level of the node. Specifically, taking the path A→B→C→D→s as an example, assuming the OD transition probabilities of A→B, B→C, C→D, and D→s are 0.80, 0.75, 0.70, and 0.65 respectively, the weighting process of the system is as follows:
[0252] First, the traffic allocated from node A to node B is multiplied by the OD transfer probability of A→B (0.80) to obtain the actual traffic reaching node B. Then, the traffic allocated from node B to node C is multiplied by the OD transfer probability of B→C (0.75); and so on. The traffic at node C is multiplied by the OD transfer probability of C→D (0.70); the traffic at node D is multiplied by the OD transfer probability of D→s (0.65), finally yielding the traffic contribution reaching node s. Therefore, the total OD transfer probability of the path A→B→C→D→s is 0.80 × 0.75 × 0.70 × 0.65 = 0.273. The system will multiply the allocated traffic of upstream nodes by the OD transfer probability of each segment in turn, recursively calculating to finally obtain the traffic contribution of this path to the target node s per minute. Meanwhile, in actual business operations, the total travel time of some paths may exceed the current prediction window, as shown in the attached figure. Figure 5As shown, assuming the total travel time for the path A→B→C→D→s is 35 minutes (A→B: 10 minutes, B→C: 8 minutes, C→D: 9 minutes, D→s: 8 minutes, total 35 minutes), when the system predicts the traffic flow at node s every minute from 17:00 to 17:29, theoretically it needs to trace the historical traffic data of node A from 16:50 to 16:59. However, in reality, vehicles passing through node A from 16:55 to 16:59 will not arrive at node s until 17:30 to 17:34, which is outside the current prediction window. Therefore, when making this prediction, the system will only consider the observation data of node A from 16:50 to 16:54. In actual business, the travel time for each segment of the path is often not an integer number of minutes, as shown in the attached figure. Figure 6 As shown, taking the path B→A→s as an example, assuming the travel time from A→s is 3 minutes and 40 seconds and the travel time from B→A is 2 minutes and 10 seconds, the system needs to perform fine segmentation and weighted allocation of the observation data of the upstream gantry to ensure that the historical traffic of each node can be accurately mapped to the predicted value of the target node s every minute. The specific operation is as follows:
[0253] Data allocation for gantry A: The vehicle's travel time from gantry A to gantry S is 3 minutes and 40 seconds. Therefore, the observation data from gantry A (16:56:20-16:59:59) will be mapped to the prediction interval of gantry S (17:00:00-17:03:39). Since the observation data is in minutes (e.g., gantry A 16:56 refers to 16:56:00-16:56:59), the system needs to divide the observation data A1 from gantry A at 16:56 into seconds and extract the portion from 16:56:20-16:56:59, i.e., (A1 / 60)×40. Similarly, the observation data from gantry A at 16:57, 16:58, and 16:59 will all be used for mapping. Data allocation for gantry B: The vehicle's travel time from gantry B to gantry A is 2 minutes and 10 seconds. Therefore, the observation data from gantry B between 16:57:50 and 16:59:59 will be mapped to the prediction interval of gantry s between 17:03:40 and 17:05:49. Similarly, the observation data B1 from gantry B at 16:57 needs to extract the portion from 16:57:50 to 16:57:59, i.e., (B1 / 60)×10. The observation data from gantry B at 16:58 and 16:59 are used entirely for mapping. Since the prediction results of node s need to be output in minutes (e.g., 17:00...), the prediction data will be used to map the data. The system will divide and accumulate the observation data of gantry A from 16:56:20 to 16:57:20 according to the number of overlapping seconds, and map it to the predicted value of gantry S from 17:00:00 to 17:00:59. For example, the 40 seconds of data of gantry A from 16:56:20 to 16:56:59 and the 20 seconds of data of gantry A from 16:57:00 to 16:57:20 are from the observation data of gantry A at 16:56 and 16:57 respectively. The system will weight and merge them to obtain the predicted flow of gantry S at 17:00. The prediction values for the remaining minutes are similar, all achieved by segmenting, weighting, and accumulating the upstream gantry observation data; taking the path B→A→s as an example, assuming the travel time from A→s is 3 minutes and 40 seconds and the travel time from B→A is 2 minutes and 10 seconds, the traffic flow of node s for the minute from 17:00:00 to 17:00:59 is predicted as follows;
[0254] Case 1
[0255] The observation data for gantry A are as follows: 16:56 (16:56:00-16:56:59): 31 vehicles; 16:57 (16:57:00-16:57:59): 28 vehicles; 16:58 (16:58:00-16:58:59): 35 vehicles; 16:59 (16:59:00-16:59:59): 30 vehicles;
[0256] Mapping analysis: Since the passage time from A to s is 3 minutes and 40 seconds, the observation data from gantry A from 16:56:20 to 16:57:20 will be mapped to gantry s from 17:00:00 to 17:00:59; among them, 16:56:20 to 16:56:59 is 40 seconds, which comes from the data from gantry A at 16:56; 16:57:00 to 16:57:20 is 20 seconds, which comes from the data from gantry A at 16:57.
[0257] Data segmentation and weighted calculation: 40 seconds of data from gantry A at 16:56: 31 × (40 / 60) = 20.66667 vehicles; 20 seconds of data from gantry A at 16:57: 28 × (20 / 60) = 9.33333 vehicles; combined, the predicted flow rate for gantry S at 17:00 is 20.66667 + 9.33333 = 30 vehicles. Therefore, the system ultimately segments and maps the observation data from gantry A from 16:56:20 to 16:57:20 to the predicted value of gantry S from 17:00:00 to 17:00:59, which is 30 vehicles.
[0258] OD probability weighting: Let the OD transition probability of B→A be 0.75 and the OD transition probability of A→s be 0.65, then the total OD probability of the path B→A→s is 0.75×0.65=0.4875; the system will multiply the above segmented and weighted traffic result by the total OD probability of the path to obtain the final predicted traffic allocated to gantry s from 17:00:00 to 17:00:59;
[0259] Therefore, the final predicted traffic volume is: 30 × 0.65 = 19.5 vehicles. That is, the system will finally divide and weight the observation data of A gantry 16:56:20-16:57:20, and combine it with the path OD probability to map the predicted value of s gantry 17:00:00-17:00:59 to 19.5 vehicles.
[0260] After obtaining the traffic flow forecast, the system will further perform multi-source data weighted fusion processing. The fusion process will comprehensively consider various external influencing factors such as meteorological conditions, traffic accidents, and road construction. By establishing a corresponding weight allocation mechanism, the system will achieve quantitative evaluation and dynamic adjustment of different influencing factors, thereby improving the accuracy and reliability of the final traffic flow forecast results.
[0261] Case 2
[0262] The observation data for gantry A are as follows: 16:59 (16:59:00-16:59:59): 40 vehicles; The observation data for gantry B are as follows: 16:57 (16:57:00-16:57:59): 50 vehicles; 16:58 (16:58:00-16:58:59): 45 vehicles;
[0263] Mapping relationship analysis: The vehicle passes through gantry A from 16:59:20 to 16:59:59, and after 3 minutes and 40 seconds, it will arrive at gantry S from 17:03:00 to 17:03:39. The vehicle passes through gantry B from 16:57:50 to 16:58:09, and after 2 minutes and 10 seconds, it arrives at gantry A from 17:00:00 to 17:00:19, and after another 3 minutes and 40 seconds, it arrives at gantry S from 17:03:40 to 17:03:59. Therefore, the flow rate of gantry S from 17:03:00 to 17:03:59 is contributed by gantry A from 16:59:20 to 16:59:59 (40 seconds) and gantry B from 16:57:50 to 16:58:09 (20 seconds).
[0264] Data Segmentation and Weighted Calculation: For gantry A, the 40-second data at 16:59 (16:59:20-16:59:59): 40 × (40 / 60) = 26.67 vehicles; For gantry B, the 10-second data at 16:57 (16:57:50-16:57:59): 50 × (10 / 60) = 8.33 vehicles; For gantry B, the 10-second data at 16:58 (16:58:00-16:58:09): 45 × (10 / 60) = 7.50 vehicles; Total contribution of gantry B: 8.33 + 7.50 = 15.83 vehicles; OD Probability Weighting: Assuming the OD transition probability from A to B is 0.75, and the OD transition probability from A to s is 0.65; Weighted contribution of gantry A: 26.67 × 0.65 = 17.335 5 vehicles (corresponding to gantry S 17:03:00-17:03:39); Weighted contribution of gantry B: 15.83×0.75×0.65=7.717125 vehicles (corresponding to gantry S 17:03:40-17:03:59); Therefore, the predicted value mapped to gantry S 17:03:00-17:03:59 is 25.052625 vehicles; Furthermore, if there are multiple paths, the system repeats the above tracing, allocation, and weighting process for each path, and finally sums up the traffic contributions of all paths to obtain the total predicted traffic of node S in each minute; The system will also automatically check the conservation relationship between the sum of traffic contributions of all upstream nodes and the predicted traffic of node S. If there is an error, it will be dynamically adjusted through the error compensation term;
[0265] The above experiments show that the system can achieve high-precision, spatiotemporally aligned prediction of traffic flow for target node s every minute from 17:00 to 17:30. Even if the path is long and crosses multiple nodes, it can accurately trace and allocate the traffic contribution of each path, significantly improving the precision and interpretability of the prediction. In actual business, this mechanism supports various intelligent traffic management needs such as anomaly tracing and path scheduling, greatly enhancing the practicality and intelligence level of the system.
[0266] In summary
[0267] This invention constructs a directed graph with spatiotemporal weights by combining a computable road network with real-time travel time, and performs path pruning, which can greatly reduce invalid calculations; furthermore, it prioritizes the use of historical data from the nearest upstream node to predict the traffic flow at the target time, thereby reducing accumulated errors.
[0268] Based on the probability distribution of historical / real-time data, the probability of a vehicle moving from one gantry to another is adjusted according to an error decay factor. The accuracy of upstream gantry traffic flow prediction is transmitted to downstream gantry through a probability transfer matrix, forming an accuracy recursion mechanism. This mechanism effectively controls the cumulative effect of errors, attenuating upstream prediction errors rather than amplifying them during transmission. This allows downstream gantry prediction accuracy to inherit and optimize the upstream prediction results. Simultaneously, this mechanism enhances the traceability of prediction results, clearly tracing the transmission path and sources of influence of traffic flow prediction, providing a scientific basis for subsequent prediction optimization.
[0269] By transforming dynamic disturbance factors such as accidents, weather, and maintenance into real-time correction factors, and dynamically adjusting traffic transmission weights through closed-loop feedback, the system achieves perception, prediction, correction, and end-to-end response, enabling real-time adaptive capability. It can quickly respond to emergencies, automatically adjust prediction model parameters, and continuously improve the accuracy of prediction models through continuous learning and adjustment. In case of sudden road conditions, it can quickly adjust traffic transmission strategies and effectively reduce prediction deviations. This end-to-end response mechanism ensures that the system can maintain high prediction accuracy and stability when facing complex and ever-changing traffic environments.
[0270] Furthermore, by adopting a spatiotemporal conservation model based on the pigeonhole principle, the reachability domain of the road network is regarded as a pigeonhole and vehicles as goods. Through probability allocation, the number of goods in each pigeonhole per minute is accurately calculated. That is, within a certain time window, the total number of all vehicles entering the reachability domain is equal to the superposition of the flow at each gantry. This establishes a spatiotemporal coupled prediction basis. Through this probability allocation mechanism, accurate calculation and allocation of traffic flow can be achieved, ensuring that traffic flow prediction conforms to the physical conservation law and avoiding unreasonable traffic flow allocation. At the same time, the system can dynamically adjust the reachability domain range to adapt to different prediction needs, providing a solid physical basis for traffic flow prediction.
[0271] By using a minute-level sliding window to divide non-integer travel time into second-level segments, the mapping barrier between minute-level traffic data and continuous travel time is broken through, and the time accuracy is significantly improved. The system can handle more precise time modeling requirements, improve the time continuity of the model, thereby maximizing the use of existing traffic data and improving the timeliness of prediction. It has found the optimal balance between accuracy and computational efficiency, and realized high-precision traffic prediction for short-term traffic on highways.
[0272] By proposing penetrating impact assessments of road speed limits and toll station closure control orders, the system can directly reduce traffic flow to zero when toll stations are closed and recalculate travel time in real time when speed limits are implemented. This allows for real-time quantification of the specific impact of control measures on traffic flow. The system can provide traffic management departments with scientific decision support and dynamically adjust the prediction model according to changes in control measures. The mechanism also has an effect verification function, which can verify the actual effect of control measures.
[0273] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used above are only some embodiments described in this invention. Obviously, those skilled in the art can obtain other drawings based on these drawings.
[0274] The foregoing has only described certain exemplary embodiments of the present invention by way of illustration. Undoubtedly, those skilled in the art can modify the described embodiments in various ways without departing from the spirit and scope of the present invention. Therefore, the foregoing drawings and descriptions are illustrative in nature and should not be construed as limiting the scope of protection of the claims of the present invention.
Claims
1. A method for short-term traffic flow prediction on highways based on multi-path contribution accumulation, characterized in that, Includes the following steps: Step 1: Obtain the computable road network, observation data, and status of the highway, and process them to obtain the input data; In step 1, the observation data is the vehicle passage record for each node, including license plate, vehicle type, passage time, and observed vehicle speed; the status includes: accident, weather, and maintenance; the computable road network includes: edges, node IDs, topological relationships, and corresponding distance weights, where edges are road segments and nodes are gantries / toll stations; the input data includes disturbance factors. OD probability Road section speed The system includes minute-level traffic flow and computable road network; both segment speed and minute-level traffic flow statistics are differentiated by vehicle type, including large vehicles and small vehicles; in OD probability, O represents the origin and D represents the destination, and OD probability represents the probability that at a certain node, traffic flow will choose to go to the next undetermined direction. The specific steps to obtain the input data are as follows: 1.1 Calculate the disturbance factor using the following formula. : ; in, This is the weather impact coefficient, set to a range of [0,1]. The accident levels are set from 1 to 5. This is the maintenance impact coefficient. A value of 0 indicates no maintenance, and a value of 1 indicates complete closure. The coefficient for small cars or large vehicles is determined by weather conditions. Specifically: For a small car, For large vehicles; For each accident level, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles; Due to the impact of maintenance, the coefficient for small vehicles or large vehicles is as follows: For a small car, For large vehicles; 1.2 After the prediction task is initiated, the system first retrieves the observation data of the target gantry and its related road sections before the prediction time point; 1.3 Obtain the computable road network; Step 2: Based on the input data, assuming the highway network is a directed graph, perform reverse path retrieval and pruning to obtain a list of multi-dimensional attribute information of the paths that can be reached within the predicted time. In step 2, there is a directed graph as follows: ,and ; This refers to the set of nodes for gantries and toll stations. ; Let be a set of directed edges. The multi-dimensional attribute information list includes: total dynamic passage time. Total OD probability Path dynamic travel time ; Obtain the reached path and its corresponding multidimensional attribute information list, including the following steps: 2.1 Using the target node as the root node of the current search, perform reverse path retrieval to obtain the set of all paths within the directed graph. ; 2.2 For all paths, let the source node be... Calculation path The total dynamic passage time is The calculation formula is as follows: ; in, ; s is the target node; For a line from The directed path to s consists of a series of ordered road segments. ,and ;e ij For path A directed road segment on the road, its direction starting from node Pointing to node ,and , for The 1 node for The 1 node ; For path A series of intermediate nodes passed through; For the node sequence The next node; For application to road segment e ij The perturbation factor; for The basic passage time, and , for distance, for Speed limits on the road section; 2.3 Only retain nodes that meet the time constraints, and calculate the total dynamic passage time. and source node to downstream nodes Road section passage time Add nodes to the reachable domain set and continue visiting them. Terminate the traversal once all nodes have been visited and evaluated, and output the final reachable domain. ; Specifically, the time constraint is as follows: , Total forecast duration; 2.4 Calculate the reachable region The source node of each path to downstream nodes Path dynamic travel time and the total OD probability O p The specific formula is as follows: ; ; For nodes arrive OD probability; for arrive The permitted travel time for the road section; for arrive The perturbation factor; This is the error attenuation factor, used to reflect the strength of the probability attenuation due to path distance. ; It is a natural constant; The symbol for multiplication; 2.5 Store the multidimensional attributes of each node in each path to obtain a list of multidimensional attribute information of the path to be reached within the prediction time. Step 3: Based on the minute-level traffic flow of the toll station, obtain the initial predicted traffic flow of the toll station, and combine the deviation of the initial basic predicted traffic flow with the dynamic trend cycle to generate the basic predicted traffic flow. Step 4: Based on the multi-dimensional attribute information list of each path and the basic predicted traffic, obtain the total traffic of the target node within the prediction time. The specific steps are as follows: 4.1 Map the minute-level traffic time window of each path to the predicted traffic time window according to the causal law of spatiotemporal transmission, and determine the path and its historical traffic time window according to the nearest priority principle, thus obtaining... Minute-level traffic ; 4.2, Regarding The weighted flow is then calculated to obtain the weighted predicted flow. The specific formula is as follows: ; 4.3, will By aggregating the paths, we obtain the predicted flow rate of the target prediction point s at time t. The specific formula is as follows: ; 4.4 will Aggregated by time, we get The specific formula is as follows: ; in, For predicting time Total flow within; For path right Traffic contribution at any given moment; Let be the set of all feasible paths pointing to s.
2. The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation as described in claim 1, characterized in that: In step 1.2, the 85th percentile of the vehicle speed observations for each road segment is calculated to obtain the segment speed of large vehicles / small vehicles in each road segment; By recording the vehicle passage time at each node, calculate the minute-level traffic flow of large vehicles / small vehicles at each node; Calculate the OD probability between nodes for large / small vehicles by using minute-level traffic flow at each node; When road segment speed, minute-level flow rate, or OD probability is missing due to input errors, data acquisition interruptions, or equipment malfunctions, the system will automatically find and correct the missing values. These missing values include speed fill values. Flow fill value OD fill value ; The specific steps for automatically finding and correcting fill values are as follows: 1.2.
1. Cross-group road segment speed, minute-level traffic flow, and OD probability by time period and date; The time periods are divided into morning, evening, early morning, morning peak, and evening peak; the dates are divided into weekdays and holidays. 1.2.
2. The 85th percentile of the historical road segment data for each group is used as the baseline speed. Based on the perturbation factor Calculate speed fill value The specific calculation formula is as follows: ; 1.2.
3. For the probability of missing ODs in road segments, the default value of the same period is used as the OD filling value. ; 1.2.4 For minute-level traffic flow at missing gantries / toll stations on road sections, the default value for the same period is used as the traffic flow fill value. ; Among them, the default value for the same period refers to the historical OD probability or historical minute-level traffic flow under the same day, the same time period, the same road segment, and the same vehicle type last week; 1.2.3 Filling values using velocity OD fill value Flow fill value The correction and filling process yields the final input road segment speed, minute-level flow rate, and OD probability.
3. The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation according to claim 1, characterized in that, In step 3, based on the minute-level traffic flow at the toll station, the initial predicted traffic flow is obtained. The deviation of the initial basic predicted traffic flow is then corrected using a dynamic trend cycle to generate the basic predicted traffic flow, which includes the following steps: 3.1 Calculate the minute-level traffic characteristics and real-time status characteristics of the data, as detailed below: Data minute-level traffic characteristics The calculation formula is: ; in, For historical reference days; To predict the time, ; For time intervals; It is a loop variable, and ; for Flow rate at any given moment; Real-time status characteristics of data The calculation formula is: ; in, This represents the current queue length. Instantaneous throughput; This is the adjustment coefficient; This represents the maximum queue length. To achieve the maximum pass rate; 3.
2. The minute-level traffic characteristics and real-time status characteristics of the data are independently normalized to obtain... The specific formula is as follows: ; in, Substitute and ; For normalized ,Right now and ; for and The maximum value; for and The minimum value; 3.
3. Based on minute-level data flow characteristics and real-time data status characteristics, generate... Initial predicted flow at time The specific formula is as follows: ; in, Weights for minute-level data traffic characteristics; Weights for real-time status features of the data; The perturbation factor weights are defined by the following constraints: , ; yes The perturbation factor at any given moment; 3.
4. Based on the dynamic trend cycle, the error of the initial predicted flow is calculated. The specific formula is as follows: ; in, It is a function for maximizing the value; for + The observed flow rate at any given time; for + Error value at time; 3.5 Based on error value To correct the deviation of the initial predicted flow, a closed-loop feedback system is established to achieve adaptive parameter optimization. The specific process is as follows: when The weights are dynamically adjusted as needed. 3.6 Update the weights of minute-level data flow characteristics, real-time data status characteristics, and disturbance factor weights. The specific formulas are as follows: ; in, = , , ; The rate factor for weight adjustment; The updated weights; These are the original weights; 3.7, will Substituting into the predicted flow calculation formula, we obtain the basic predicted flow. The specific formula is as follows: 。 4. The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation as described in claim 1, characterized in that: In step 4.1, the minute-level traffic time window for each path is mapped to the predicted traffic time window according to the causal law of spatiotemporal propagation, which is... Leave at any time Should be in The vehicle that arrives at time s; Based on the nearest-first principle, the path and its historical traffic time window are determined to obtain the minute-level traffic at time t. The specific steps are as follows: 4.1.1, downstream nodes Record For path depth of path ,but ; 4.1.2 Calculation Path The traffic mapping time window and its historical traffic time window, specifically: in a path with a path depth of 1 In the middle, the source node is directly connected to The path format is →s, total dynamic passage time is ; For the path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ]; On a path with a path depth of 2 In this process, the source node is connected to the intermediate node. The path format is →s, total dynamic passage time is + Dynamic travel time along the route = - ; For path The contribution of the path needs to be removed from the traffic contribution. The covered time period has a traffic mapping time window of [[ + , + The historical traffic time window for tracing is [ - , ]; On a path with path depth k In the middle, the path form is →…→ s, total dynamic passage time is The dynamic travel time for the route is ; For path The contribution, its traffic mapping time window is [ , + The historical traffic time window for tracing is [ - , ]; 4.1.
3. Let the target traffic mapping time window be... The historical traffic time window is [ - , Based on this, a traffic redistribution algorithm is used to calculate minute-level traffic. ; The target traffic mapping time window can be an integer or a non-integer.
5. The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation according to claim 4, characterized in that: In step 4.1.3, a traffic redistribution algorithm is used to calculate minute-level traffic. Specifically: The target traffic is reallocated to each minute within the time window to calculate the path. The contributed historical traffic is obtained in minute-level traffic. The specific steps are as follows: A. Predicted time The historical traffic mapping time window traced in minutes belongs to Corresponding path No. Minutes later, the minutes and the Minutes earlier; in, , , Historical traffic time window for tracing [ - , ]; B. Path The flow rate of the source gantry is calculated in seconds. The proportion is allocated to the prediction time, and the mapping result for each minute of the prediction time is calculated, specifically as follows: B1, let the first The historical traffic for minutes is as follows Calculation path Historical traffic allocation to the first minutes of data The specific formula is as follows: ; in, The offset in seconds when aligning to minutes; if =0 indicates a one-to-one correspondence between the historical traffic time window and the target traffic mapping time window; if This indicates that the mapping between the two time windows has a time offset; B2. Calculation Path The historical flow of the source gantry u is allocated to the target minute. The flow rate is calculated using the following formula: ; B3. For each minute within the target minute, repeat the calculation in step B2 until the path is obtained. exist ∈[ , + The flow rate per minute within [the specified range] Specifically: ; in, .
6. The method for short-term traffic flow prediction on highways based on multi-path contribution accumulation according to claim 5, characterized in that: In step 4.1.2, for the deepest path, if Call the toll station's basic predicted traffic. As Its basic forecast flow time window ∈[ , Traffic mapping to The historical traffic time window for tracing is [ , T], and This indicates that the source node is a toll station without an upstream topological relationship.
Citation Information
Patent Citations
Construction method of computable road network
CN120508601A
Toll station flow prediction method considering road network OD flow contribution time-varying characteristics
CN111739292A