Prediction system based on traffic management and prediction method thereof
By deploying sensor networks at traffic sections and road intersections, collecting and preprocessing traffic flow data, and using machine learning algorithms to build traffic flow prediction models, it solves the difficulty of providing accurate traffic flow in existing technology under complex conditions such as rainy and snowy weather and holidays. The prediction problem realizes high-accurate traffic flow prediction and optimized traffic management strategy.
Patent Information
- Application Number
- CN202411988624.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-02-07
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the face of complex conditions such as rain and snow weather and holidays, it is difficult for the existing technology to provide accurate traffic flow forecasts and timely and effective traffic management strategies, resulting in frequent traffic congestion and accidents.
Through a sensor network deployed at traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays, data preprocessing and feature extraction are carried out, and a traffic flow prediction model is constructed using machine learning algorithms to carry out traffic flow prediction models. Real-time prediction and formulate corresponding traffic management strategies.
Achieve accurate prediction of traffic flow during rainy and snowy weather and holidays, timely identify traffic flow density, vehicle speed, bottleneck location and congestion points, provide scientific basis for traffic management decisions, significantly improve the accuracy and reliability of forecasts, and optimize traffic Management strategies to reduce traffic accidents and congestion.
Smart Images

Figure CN119399962A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of urban traffic management, and in particular to a prediction system based on traffic management and a prediction method thereof. Background Art
[0002] With the continuous acceleration of urbanization, the increase in traffic flow has become one of the main challenges of urban traffic management, especially during rainy and snowy weather conditions and holidays, the volatility and complexity of traffic flow have increased, leading to traffic congestion, frequent traffic accidents and difficult traffic control. Traditional traffic management methods often rely on manual experience or static rules, lacking the ability to dynamically respond to and predict real-time traffic data.
[0003] In the existing technology, most traffic flow prediction methods rely on historical traffic data and simple models, lacking the ability to accurately predict specific weather conditions and holidays. Traditional traffic flow prediction methods usually ignore the impact of weather changes (such as rainy and snowy weather) and holidays on traffic flow, and cannot fully consider the changes in traffic flow patterns caused by these special factors. They are not optimized for specific complex weather conditions and special periods (such as holidays), resulting in low accuracy of prediction results and difficulty in effectively guiding actual traffic management. Therefore, in the face of complex conditions such as rainy and snowy weather and holidays, the existing technology is difficult to provide accurate traffic flow predictions and timely and effective traffic management strategies. Summary of the invention
[0004] The invention provides a prediction system based on traffic management and a prediction method thereof.
[0005] A prediction method based on traffic management includes the following steps:
[0006] S1, data collection: through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected;
[0007] S2, data preprocessing: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays. The preprocessing includes data cleaning, outlier removal, missing value filling and data standardization;
[0008] S3, feature extraction: based on the pre-processed traffic flow data, feature variables closely related to traffic flow are extracted, the feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio;
[0009] S4, model construction: using the extracted feature variables, a machine learning algorithm is used to build a traffic flow prediction model;
[0010] S5, prediction analysis: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow during rainy and snowy weather conditions and holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points;
[0011] S6, traffic management strategy formulation: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model. The traffic management strategies include traffic signal optimization, road speed limit adjustment, traffic control measures and traffic flow guidance.
[0012] Optionally, the S1 includes:
[0013] S11, sensor network deployment: deploy multiple types of sensor equipment at traffic sections and road intersections to collect traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays, wherein the multiple types of sensor equipment include radar sensors, video surveillance equipment, infrared sensors, geomagnetic sensors, and vehicle-mounted GPS equipment;
[0014] S12, traffic flow data collection: During holidays and rainy and snowy weather conditions, multiple types of sensors collect traffic flow data in real time, including vehicle passing rate, lane occupancy rate, vehicle speed, traffic density and vehicle type ratio;
[0015] S13, data synchronization and transmission: The traffic flow data collected by various types of sensors (including traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays) are transmitted to the data processing center in real time through wireless communication or wired network to ensure that there is no delay or loss in the data transmission process. Encryption technology is used during the transmission process to ensure data security;
[0016] S14, sensor data calibration and verification: calibrate the collected traffic flow data to ensure the consistency and accuracy of data from different types of sensors;
[0017] S15, data storage and backup: Store the real-time collected traffic flow data in the cloud or local server, and set up a data backup strategy to prevent data loss or damage.
[0018] Optionally, S2 includes:
[0019] S21, data cleaning: data cleaning of the collected traffic flow data under rainy and snowy weather conditions and during holidays;
[0020] S22, outlier elimination: performing outlier detection on the collected traffic flow data (including traffic flow data under rainy and snowy weather conditions and during holidays);
[0021] S23, missing value filling: fill in the missing values in the traffic flow data;
[0022] S24, data standardization processing: standardizing the collected traffic flow data;
[0023] S25, data verification and integration: overall verification of the data after data cleaning, outlier removal, missing value filling and standardization.
[0024] Optionally, the S3 specifically includes:
[0025] S31, feature variable selection: based on the preprocessed traffic flow data, select feature variables closely related to traffic flow, the selected feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio;
[0026] S32, feature engineering: performing feature engineering on the selected feature variables;
[0027] S33, feature standardization and normalization: In order to eliminate the dimensional differences of different features and improve the training effect of the model, the extracted features are standardized and normalized;
[0028] S34, feature selection based on L1 regularization: The L1 regularization method is used to select the extracted features. The goal of L1 regularization is to compress unimportant feature coefficients to zero through penalty terms, thereby selecting the features that have the greatest impact on the prediction.
[0029] Optionally, the S4 includes:
[0030] S41, Application of Random Forest Algorithm: Random forest algorithm is used as the construction algorithm of traffic flow prediction model.
[0031] S42, data division and preprocessing: before starting to train the model, first divide the extracted feature variable data set into a training set and a test set;
[0032] S43, build random forest model: use random forest algorithm to build traffic flow prediction model.
[0033] S44, Hyperparameter tuning during training: During the construction process, the traffic flow prediction model is optimized by adjusting the hyperparameters;
[0034] S45, model training and evaluation: Use the training set data to train the traffic flow prediction model, and use the test set to evaluate the traffic flow prediction model;
[0035] S46, final model selection and application: After training is completed, the traffic flow prediction model is applied to actual traffic management to predict traffic flow based on real-time data.
[0036] Optionally, the S5 includes:
[0037] S51, input data: input the traffic flow data collected in real time under rainy and snowy weather conditions and the traffic flow data during holidays into the constructed traffic flow prediction model;
[0038] S52, traffic flow density prediction: predicting the traffic flow density in the future time period based on the input data through the traffic flow prediction model;
[0039] S53, vehicle speed prediction: the vehicle speed is predicted based on the real-time collected data and the predicted traffic flow density through the traffic flow prediction model.
[0040] Optionally, S5 further includes:
[0041] S54, predicting the location of traffic bottlenecks: based on the established traffic flow prediction model, comprehensively analyzing the traffic flow density and vehicle speed, predicting the location of traffic bottlenecks;
[0042] S55, predict traffic congestion points: analyze traffic flow data through traffic flow prediction models to predict possible traffic congestion points.
[0043] Optionally, the S6 includes:
[0044] S61, Traffic Signal Optimization: Based on the results of the traffic flow prediction model, analyze the traffic flow, vehicle speed and bottleneck points of the intersections controlled by each traffic light, and optimize the control strategy of the traffic light according to the prediction results of the real-time traffic flow density and vehicle speed;
[0045] S62, road section speed limit adjustment: based on the prediction results of the traffic flow prediction model, combined with the real-time vehicle speed and traffic density, the speed limit is adjusted for congested sections and sections with lower vehicle speeds.
[0046] Optionally, S6 further includes:
[0047] S63, Traffic control measures: Based on the prediction results of the traffic flow prediction model, analyze the road sections or intersections where serious traffic congestion or bottlenecks may occur, formulate and implement corresponding traffic control measures, including temporary closure of some lanes, prohibition of traffic during specific time periods, restriction of traffic of certain vehicles, etc.;
[0048] S64, Traffic flow guidance: Based on the results of the traffic flow prediction model and combined with real-time traffic flow information, formulate and implement traffic flow guidance strategies, including guiding vehicles to bypass traffic congestion points and choose unobstructed routes through electronic road signs, traffic broadcasts or navigation systems.
[0049] A prediction system based on traffic management, used to implement the above-mentioned prediction method based on traffic management, includes the following modules:
[0050] Data collection module: Through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected;
[0051] Data preprocessing module: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays;
[0052] Feature extraction module: extracts feature variables closely related to traffic flow based on preprocessed traffic flow data;
[0053] Model building module: using the extracted feature variables and machine learning algorithms to build a traffic flow prediction model;
[0054] Prediction and analysis module: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow in rainy and snowy weather conditions and during holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points;
[0055] Management strategy formulation module: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model.
[0056] Beneficial effects of the present invention:
[0057] The present invention collects traffic flow data specifically for rainy and snowy weather conditions and during holidays, and builds a traffic flow prediction model in combination with a machine learning model, which can effectively identify and predict traffic flow fluctuations under different weather conditions and during holidays. Through accurate traffic flow prediction, the density, vehicle speed, bottleneck location and congestion points of traffic flow can be identified in a timely manner, thereby providing a scientific basis for traffic management decisions. Compared with the prior art, the present invention takes into account the influence of different time periods and weather factors in the prediction process, significantly improving the accuracy and reliability of the prediction.
[0058] Based on accurate traffic flow prediction results, the present invention can automatically generate and adjust a variety of traffic management strategies, including traffic signal optimization, road speed limit adjustment, traffic control and traffic flow guidance. Through intelligent traffic signal light control, traffic bottlenecks when traffic flow density is too high can be reduced, and traffic accidents caused by too low speed can be avoided; through reasonable road speed limit adjustment, the threat of excessive speed to traffic safety can be effectively avoided. Through real-time guidance of traffic flow, the distribution of vehicles can be optimized, traffic congestion can be reduced, thereby greatly improving traffic efficiency and road network safety.
[0059] The present invention, by predicting traffic flow and traffic bottlenecks in real time, can quickly take emergency measures when serious traffic congestion occurs, such as temporary road section control, lane closure and traffic guidance, so as to quickly alleviate the congestion. Especially in special circumstances such as holidays and rainy and snowy weather, it can more accurately predict changes in traffic flow and deploy traffic management plans in advance to avoid traffic paralysis or traffic accidents. In addition, the optimized traffic management strategy can reduce the frequency of traffic accidents, reduce transportation costs, enhance the overall economic benefits of society, and improve people's travel experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0060] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only for the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0061] Figure 1 A schematic diagram of a method flow of an embodiment of the present invention;
[0062] Figure 2 Schematic diagram of a system flow of an embodiment of the present invention. DETAILED DESCRIPTION
[0063] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. At the same time, it is explained here that in order to make the embodiments more detailed, the following embodiments are the best and preferred embodiments, and those skilled in the art may also adopt other alternatives to implement some known technologies; and the accompanying drawings are only for more specific description of the embodiments, and are not intended to specifically limit the present invention.
[0064] In the present invention, the traffic flow prediction model adopted is specifically aimed at the main congested intersections in third-tier cities, especially the intersections in the main office areas in the city center. In these specific areas, traffic flow is greatly affected by weather and holiday factors, and congestion is prone to occur. In order to better deal with this problem, the present invention specifically predicts traffic flow during rainy and snowy weather and holidays, with special attention paid to the morning peak (7 am-9 am) and evening peak (5 am-7 pm) hours. By accurately predicting the changes in traffic flow during these periods, the model can provide real-time decision support for traffic management, help alleviate traffic pressure, reduce the occurrence of congestion, and provide traffic management personnel with effective response strategies for early prevention.
[0065] like Figure 1 As shown, a prediction method based on traffic management includes the following steps:
[0066] S1, data collection: through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected;
[0067] S2, data preprocessing: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays. The preprocessing includes data cleaning, outlier removal, missing value filling and data standardization;
[0068] S3, feature extraction: based on the pre-processed traffic flow data, feature variables closely related to traffic flow are extracted, the feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio;
[0069] S4, model construction: using the extracted feature variables, a machine learning algorithm is used to build a traffic flow prediction model;
[0070] S5, prediction analysis: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow during rainy and snowy weather conditions and holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points;
[0071] S6, traffic management strategy formulation: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model. The traffic management strategies include traffic signal optimization, road speed limit adjustment, traffic control measures and traffic flow guidance.
[0072] Optionally, the S1 includes:
[0073] S11, sensor network deployment: deploy multiple types of sensor equipment at traffic sections and road intersections to collect traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays, wherein the multiple types of sensor equipment include radar sensors, video surveillance equipment, infrared sensors, geomagnetic sensors, and vehicle-mounted GPS equipment;
[0074] S12, traffic flow data collection: During holidays and rainy and snowy weather conditions, multiple types of sensors collect real-time traffic flow data, including vehicle passing rate, lane occupancy rate, vehicle speed, traffic density and vehicle type ratio. The data collection time is the morning peak (7:00-9:00) and evening peak (5:00-7:00) time periods of third-tier cities, and the collection location is the intersection of the main office area in the city center;
[0075] In order to reflect the changes in traffic flow in real time, set an appropriate data collection time interval (e.g., every minute, every hour), and adjust the data collection frequency according to weather conditions (e.g., the speed of change of rainy and snowy weather);
[0076] S13, data synchronization and transmission: The traffic flow data collected by various types of sensors (including traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays) are transmitted to the data processing center in real time through wireless communication or wired network to ensure that there is no delay or loss in the data transmission process. Encryption technology is used during the transmission process to ensure data security;
[0077] In order to improve the stability and reliability of data transmission, the sensor network can set up redundant communication channels and conduct regular equipment inspection and maintenance;
[0078] S14, sensor data calibration and verification: calibrate the collected traffic flow data to ensure the consistency and accuracy of data from different types of sensors;
[0079] Eliminate data errors or deviations caused by sensor failures by cross-checking data from multiple sensors (such as video surveillance equipment and radar sensors);
[0080] S15, data storage and backup: The real-time collected traffic flow data is stored in the cloud or local server, and a data backup strategy is set to prevent data loss or damage. A standardized data format is used during the data storage process to facilitate subsequent data processing and analysis.
[0081] By deploying a variety of sensors at traffic sections and road intersections, real-time traffic flow data is collected under rainy and snowy weather conditions and during holidays. Through a reasonable data collection frequency, data transmission and calibration mechanism, the collected data is ensured to be accurate, timely and highly reliable, providing effective data support for subsequent traffic flow forecasts and traffic management strategy formulation.
[0082] Optionally, S2 includes:
[0083] S21, data cleaning: Data cleaning is performed on the collected traffic flow data under rainy and snowy weather conditions and during holidays. Data cleaning includes the following operations:
[0084] Formatting: Format all data to ensure that fields such as timestamp, sensor type, and data value conform to the specified format, and remove abnormal data that does not conform to the format;
[0085] Deduplication: By checking the unique identifier of each record (such as the combination of sensor ID and timestamp), duplicate data is eliminated to ensure that each data record is unique;
[0086] Data correction: Correct data with incorrect format, garbled characters or missing fields to ensure that the data format and content are consistent and meet the requirements of subsequent analysis;
[0087] S22, outlier removal: performing outlier detection on the collected traffic flow data (including traffic flow data under rainy and snowy weather conditions and during holidays), the specific steps include:
[0088] (1) Outlier detection based on statistical methods: outlier detection is performed on each data feature (such as vehicle speed, lane occupancy, traffic density, etc.), and outliers are eliminated using the 3σ method (that is, data exceeding three times the standard deviation of the mean is considered an outlier), expressed as:
[0089] ;
[0090] in, is the value of each data record, is the mean value of this feature, is the standard deviation of the feature. , then the data is considered to be an outlier.
[0091] (2) Outlier detection based on IQR method: Calculate the interquartile range (IQR) of each data feature. The specific calculation method is:
[0092] ,in, and The first and third quartiles of the data, respectively. If the data value is out of range , then the data is considered as an outlier.
[0093] (3) Eliminate outliers: Eliminate outliers identified by the above two methods to ensure that all values in the data set are within a reasonable range and conform to the actual rules of traffic flow;
[0094] S23, missing value filling: fill the missing values in the traffic flow data. The specific steps include:
[0095] Mean filling method: For missing continuous data (such as vehicle speed and traffic density), the mean of the feature is used to fill the missing value. The specific calculation method is:
[0096] ;
[0097] in, is the existing data of this feature, is the total number of data, is the value after filling;
[0098] Linear interpolation: For time series data, linear interpolation is used to fill missing values, expressed as:
[0099] ;
[0100] in, and are the data values at the previous and next time points respectively, and The timestamps of the previous and next time points, is the time point where the missing value is located, is the data value after interpolation;
[0101] S24, data standardization processing: standardize the collected traffic flow data to ensure that each feature data is within the same scale range to avoid affecting subsequent model training due to inconsistent dimensions. The specific steps include:
[0102] Z-score standardization method: Perform Z-score standardization on each feature and transform the data into a standard normal distribution with a mean of 0 and a standard deviation of 1. The specific calculation formula is:
[0103] ;
[0104] in, is the original data value, is the mean value of this feature, is the standard deviation of the feature. The mean of the standardized data is 0 and the standard deviation is 1;
[0105] Min-Max normalization method: Normalize each feature and scale the data to the interval [0,1]. The specific calculation formula is:
[0106] ;
[0107] in, is the original data value, and are the minimum and maximum values of the feature, is the normalized value;
[0108] S25, data verification and integration: perform overall verification on the data after data cleaning, outlier removal, missing value filling and standardization to ensure the consistency and accuracy between different data sources (such as data collected by multiple sensors). The specific steps include:
[0109] Data consistency check: Compare the same type of data (such as vehicle speed, lane occupancy) from different sensors to ensure that the timestamps between the data are aligned and resolve data deviations between sensors.
[0110] The cleaned, filled and standardized data are integrated into a data set in a unified format to facilitate subsequent feature extraction and model building.
[0111] Optionally, the S3 specifically includes:
[0112] S31, feature variable selection: based on the preprocessed traffic flow data, select feature variables closely related to traffic flow. The selected feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio, as follows:
[0113] Traffic flow density: Traffic flow density is usually an important indicator to measure the degree of traffic flow, which indicates the number of vehicles on a unit length of road. Its calculation formula is:
[0114] Traffic flow density ;
[0115] Among them, "number of vehicles" refers to the number of vehicles passing through in a specific time period, and "road length" refers to the length of the measured road section. This feature reflects the degree of road congestion and directly affects the prediction of traffic flow;
[0116] Average speed: Average speed is used to describe the speed of traffic flow and reflects the road's capacity. The calculation formula is:
[0117] Average speed ;
[0118] Among them, "total travel distance" is the total distance traveled by vehicles in a specific time period, and "total time" is the total time taken by all vehicles to travel that distance. This feature plays a key role in predicting traffic flow and congestion levels;
[0119] Lane occupancy rate: Lane occupancy rate reflects the usage of road lanes, indicating the proportion of lanes occupied by vehicles in a certain period of time. The calculation formula is:
[0120] ;
[0121] Among them, "Number of occupied lanes" is the number of lanes occupied by vehicles, and "Total number of lanes" is the total number of all lanes on the road. This feature is crucial for predicting traffic bottlenecks and optimizing traffic signal control.
[0122] Vehicle type ratio: The vehicle type ratio reflects the proportion of different types of vehicles (such as small cars, large cars, trucks, etc.) in the traffic flow. The calculation formula is:
[0123] Vehicle Type Ratio ;
[0124] Among them, "the number of vehicles of a certain type" refers to the number of vehicles of a certain type in a specific period of time, and "the total number of vehicles" refers to the total number of vehicles of all types in that period of time. The proportion of vehicle types has a greater impact on the changes in traffic flow and road carrying capacity;
[0125] S32, Feature Engineering: Perform feature engineering on the selected feature variables to extract more effective features, including:
[0126] Feature synthesis: Generate new composite features by combining existing feature variables. For example, you can combine "traffic flow density" with "vehicle speed" to calculate the "vehicle speed-flow ratio" feature, which reflects the relationship between vehicle speed and flow, and helps predict changes in traffic flow.
[0127] Time feature extraction: Extract the time field in the data to generate new time-related features. For example, extracting information such as "hours", "working days and non-working days", and "holidays" tags can help distinguish the regularity of traffic flow in different time periods.
[0128] Seasonal characteristics: Based on factors such as season and climate, seasonal characteristics such as "seasonal index" or "climate factor" are extracted to take into account traffic flow fluctuations under different seasons or climate conditions;
[0129] S33, feature standardization and normalization: In order to eliminate the dimensional differences of different features and improve the training effect of the model, the extracted features are standardized and normalized;
[0130] S34, feature selection based on L1 regularization: The L1 regularization method is used to select the extracted features. The goal of L1 regularization is to compress unimportant feature coefficients to zero through penalty terms, thereby selecting the features that have the greatest impact on prediction. The specific steps are as follows:
[0131] L1 regularized regression model: Use the Lasso regression model for feature selection. The goal of Lasso regression is to minimize the following loss function:
[0132] ;
[0133] in, is the loss function, is the actual value, For the The sample eigenvalues, For the The regression coefficient of the feature, is the regularization parameter, which controls the sparsity of the model. Through L1 regularization, the most influential features for traffic flow prediction are finally selected;
[0134] By extracting features closely related to traffic flow (such as traffic flow density, average speed, lane occupancy, and vehicle type ratio) from preprocessed traffic flow data, and further engineering these features (such as feature synthesis, time feature extraction, seasonal feature extraction, etc.), and finally using L1 regularization (Lasso regression) for feature selection, the most meaningful features for traffic flow prediction are automatically screened out. These steps ensure that the selected features can maximize the accuracy and reliability of the prediction model.
[0135] Optionally, the S4 includes:
[0136] S41, Application of Random Forest Algorithm: Random forest algorithm is used as the construction algorithm of traffic flow prediction model. Random forest is an integrated learning method. By constructing multiple decision trees and combining their outputs for prediction, it can effectively handle complex nonlinear relationships, reduce overfitting and improve prediction accuracy. The main advantages of random forest algorithm are its strong robustness, high accuracy and good generalization ability, which is suitable for traffic flow prediction problems.
[0137] S42, data division and preprocessing: before starting to train the model, first divide the extracted feature variable data set into a training set and a test set. The common division ratio is 70% training set and 30% test set.
[0138] S43, constructing a random forest model: constructing a traffic flow prediction model using a random forest algorithm, including the following steps:
[0139] Sample sampling: Randomly select sample data from the training set (through bootstrap sampling), and each training will extract different sample data to build different decision trees.
[0140] Feature selection: For each decision tree, a subset is randomly selected from the feature set for node splitting each time a node is split. The generation of each decision tree does not rely on the full feature set, but rather uses a subset of features to reduce overfitting and improve model diversity.
[0141] Decision tree construction: Based on the selected feature subsets and sample data, multiple decision trees with variable depths are constructed. Each decision tree continuously splits nodes until the tree depth limit or other stopping conditions (such as the number of samples at the node is lower than the minimum threshold) are met.
[0142] Voting or averaging: For regression problems (traffic flow prediction), the final prediction value is obtained by averaging the prediction results of all decision trees; for classification problems, a voting mechanism is used to determine the final prediction category.
[0143] S44, Hyperparameter tuning during training: During the construction process, the traffic flow prediction model is optimized by adjusting the hyperparameters. Common hyperparameters include:
[0144] Number of trees: controls the number of trees in the forest. Generally, increasing this value can improve the stability of the model, but the computational cost will also increase.
[0145] Maximum tree depth: controls the depth of each tree to prevent overfitting;
[0146] Minimum number of samples per split: Set the minimum number of samples required for each node to split. A higher value can avoid overfitting.
[0147] Maximum number of features: controls the number of features selected at each split. A smaller subset of features can enhance randomness and improve the generalization ability of the model.
[0148] These hyperparameters can be tuned by cross-validation methods, commonly grid search or random search, to find the optimal hyperparameter combination;
[0149] S45, model training and evaluation: Use the training set data to train the traffic flow prediction model, and use the test set to evaluate the traffic flow prediction model to ensure the prediction effect of the model;
[0150] S46, final model selection and application: After training is completed, the traffic flow prediction model is applied to actual traffic management to predict traffic flow based on real-time data (real-time data includes real-time traffic flow data, weather data and holidays).
[0151] Optionally, the S5 includes:
[0152] S51, input data: input the traffic flow data collected in real time under rainy and snowy weather conditions and traffic flow data during holidays into the constructed traffic flow prediction model, and the input data includes processed characteristic variables such as real-time traffic density, vehicle speed, lane occupancy rate, vehicle type ratio, etc.;
[0153] S52, traffic flow density prediction: The traffic flow density in the future time period is predicted based on the input data through the traffic flow prediction model. The traffic flow density refers to the number of vehicles passing through a unit area within a unit time. The prediction of traffic flow density can be calculated by the following formula:
[0154] ;
[0155] in, Forecast time point The traffic flow density at Forecast time point The number of vehicles passing through the road section at that time, is the length of the road section;
[0156] S53, vehicle speed prediction: The vehicle speed is predicted by the traffic flow prediction model based on the real-time collected data and the predicted traffic flow density. The vehicle speed prediction formula is:
[0157] ;
[0158] in, Forecast time point The speed of the vehicle at is the traffic flow density at the corresponding time point, Other influencing factors (such as weather conditions, traffic signal status, etc.).
[0159] Optionally, S5 further includes:
[0160] S54, predicting the traffic bottleneck location: Based on the established traffic flow prediction model, a comprehensive analysis of traffic flow density and vehicle speed is performed to predict the traffic bottleneck location. The traffic bottleneck location refers to the road section or intersection where traffic flow is blocked and congestion occurs. The bottleneck prediction can be calculated by the following formula:
[0161] ;
[0162] in, Forecast time point The degree of bottleneck when For road section The traffic flow density, For road section Speed is the total number of road sections, and the bottleneck location refers to the road section or intersection with high density and low vehicle speed;
[0163] S55, predicting traffic congestion points: using the traffic flow prediction model, analyzing traffic flow data, predicting possible traffic congestion points. Traffic congestion points refer to sections where vehicle speeds drop significantly due to excessive traffic or road flow restrictions. Congestion point prediction can be calculated using the following formula:
[0164] ;
[0165] in, Forecast time point The degree of congestion at For road section The traffic flow density, is the maximum load density of the road section, is the vehicle speed, is the minimum safe speed for this section of road. For all road segments within the prediction range, congestion points usually occur in areas where traffic density is close to the maximum and vehicle speed is close to the minimum;
[0166] By predicting bottleneck locations and congestion points based on traffic flow prediction models, the locations of traffic bottlenecks and congestion points can be predicted in advance, providing real-time data support for the optimization and adjustment of traffic management strategies.
[0167] Optionally, the S6 includes:
[0168] S61, traffic signal optimization: Based on the results of the traffic flow prediction model, the traffic flow, vehicle speed and bottleneck points of the intersections controlled by each traffic light are analyzed, and the control strategy of the traffic light is optimized according to the prediction results of the real-time traffic flow density and vehicle speed. The traffic signal optimization includes signal cycle adjustment, green light duration adjustment, red light duration adjustment, etc., which is expressed as:
[0169] ;
[0170] in, is the green light time adjustment amount, is the traffic flow density, is the vehicle speed, is the bottleneck position, Influencing factors (such as weather, holidays, etc.);
[0171] S62, speed limit adjustment for road sections: Based on the prediction results of the traffic flow prediction model, combined with the real-time vehicle speed and traffic density, the speed limit is adjusted for congested sections and sections with low vehicle speeds. Specifically, when the traffic flow is too large or the vehicle speed is too low, the speed limit is reduced to avoid traffic accidents. Conversely, the speed limit is increased to improve the road capacity. The speed limit adjustment can be achieved through the following formula:
[0172] ;
[0173] in, The adjusted speed limit is is the traffic flow density, is the vehicle speed, The load capacity of the road section.
[0174] Optionally, S6 further includes:
[0175] S63, Traffic control measures: Based on the prediction results of the traffic flow prediction model, analyze the road sections or intersections where serious traffic congestion or bottlenecks may occur, formulate and implement corresponding traffic control measures, including temporary closure of some lanes, prohibition of traffic during specific time periods, restriction of traffic of certain vehicles, etc.;
[0176] S64, Traffic flow guidance: Based on the results of the traffic flow prediction model and combined with real-time traffic flow information, formulate and implement traffic flow guidance strategies, including guiding vehicles to bypass traffic congestion points and choose unobstructed routes through electronic road signs, traffic broadcasts or navigation systems.
[0177] like Figure 2 As shown, a prediction system based on traffic management is used to implement the above-mentioned prediction method based on traffic management, including the following modules:
[0178] Data collection module: Through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected;
[0179] Data preprocessing module: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays;
[0180] Feature extraction module: extracts feature variables closely related to traffic flow based on preprocessed traffic flow data;
[0181] Model building module: using the extracted feature variables and machine learning algorithms to build a traffic flow prediction model;
[0182] Prediction and analysis module: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow in rainy and snowy weather conditions and during holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points;
[0183] Management strategy formulation module: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model.
[0184] The present invention covers any substitution, modification, equivalent method and scheme made on the essence and scope of the present invention. In order to make the public have a thorough understanding of the present invention, specific details are described in detail in the following preferred embodiments of the present invention, but those skilled in the art can fully understand the present invention without the description of these details. In addition, in order to avoid unnecessary confusion about the essence of the present invention, well-known methods, processes, procedures, components and circuits are not described in detail.
[0185] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A prediction method based on traffic management, characterized in that: The following steps are involved: S1, data collection: through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected; S2, data preprocessing: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays. The preprocessing includes data cleaning, outlier removal, missing value filling and data standardization; S3, feature extraction: based on the pre-processed traffic flow data, feature variables closely related to traffic flow are extracted, the feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio; S4, model construction: using the extracted feature variables, a machine learning algorithm is used to build a traffic flow prediction model; S5, prediction analysis: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow during rainy and snowy weather conditions and holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points; S6, traffic management strategy formulation: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model. The traffic management strategies include traffic signal optimization, road speed limit adjustment, traffic control measures and traffic flow guidance.
2. A prediction method based on traffic management according to claim 1, characterized in that: The S1 includes: S11, sensor network deployment: deploy multiple types of sensor equipment at traffic sections and road intersections to collect traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays, wherein the multiple types of sensor equipment include radar sensors, video surveillance equipment, infrared sensors, geomagnetic sensors, and vehicle-mounted GPS equipment; S12, traffic flow data collection: During holidays and rainy and snowy weather conditions, multiple types of sensors collect traffic flow data in real time, including vehicle passing rate, lane occupancy rate, vehicle speed, traffic density and vehicle type ratio; S13, data synchronization and transmission: the traffic flow data collected by multiple types of sensors are transmitted to the data processing center in real time through wireless communication or wired network; S14, sensor data calibration and verification: calibrating the collected traffic flow data; S15, data storage and backup: Store the real-time collected traffic flow data in the cloud or local server, and set up a data backup strategy to prevent data loss or damage.
3. A prediction method based on traffic management according to claim 2, characterized in that: The S2 includes: S21, data cleaning: data cleaning of the collected traffic flow data under rainy and snowy weather conditions and during holidays; S22, outlier elimination: performing outlier detection on the collected traffic flow data; S23, missing value filling: fill in the missing values in the traffic flow data; S24, data standardization processing: standardizing the collected traffic flow data; S25, data verification and integration: overall verification of the data after data cleaning, outlier removal, missing value filling and standardization.
4. A prediction method based on traffic management according to claim 3, characterized in that: The S3 specifically includes: S31, feature variable selection: based on the preprocessed traffic flow data, select feature variables closely related to traffic flow, the selected feature variables include traffic flow density, average vehicle speed, lane occupancy rate and vehicle type ratio; S32, feature engineering: performing feature engineering on the selected feature variables; S33, feature standardization and normalization: standardize and normalize the extracted features; S34, feature selection based on L1 regularization: The L1 regularization method is used to select the extracted features and select the features that have the greatest impact on the prediction.
5. A prediction method based on traffic management according to claim 4, characterized in that: The S4 includes: S41, Application of Random Forest Algorithm: Random Forest Algorithm is used as the construction algorithm of traffic flow prediction model; S42, data division and preprocessing: dividing the extracted feature variable data set into a training set and a test set; S43, building a random forest model: using the random forest algorithm to build a traffic flow prediction model; S44, Hyperparameter tuning during training: During the construction process, the traffic flow prediction model is optimized by adjusting the hyperparameters; S45, model training and evaluation: Use the training set data to train the traffic flow prediction model, and use the test set to evaluate the traffic flow prediction model; S46, final model selection and application: After training is completed, the traffic flow prediction model is applied to actual traffic management to predict traffic flow based on real-time data.
6. A prediction method based on traffic management according to claim 5, characterized in that: The S5 includes: S51, input data: input the traffic flow data collected in real time under rainy and snowy weather conditions and the traffic flow data during holidays into the constructed traffic flow prediction model; S52, traffic flow density prediction: predicting the traffic flow density in the future time period based on the input data through the traffic flow prediction model; S53, vehicle speed prediction: the vehicle speed is predicted based on the real-time collected data and the predicted traffic flow density through the traffic flow prediction model.
7. A prediction method based on traffic management according to claim 6, characterized in that: The S5 further includes: S54, predicting the location of traffic bottlenecks: based on the established traffic flow prediction model, comprehensively analyzing the traffic flow density and vehicle speed, predicting the location of traffic bottlenecks; S55, predicting traffic congestion points: analyzing traffic flow data through a traffic flow prediction model to predict traffic congestion points.
8. The prediction method based on traffic management according to claim 7, characterized in that: The S6 includes: S61, Traffic Signal Optimization: Based on the results of the traffic flow prediction model, analyze the traffic flow, vehicle speed and bottleneck points of the intersections controlled by each traffic light, and optimize the control strategy of the traffic light according to the prediction results of the real-time traffic flow density and vehicle speed; S62, road section speed limit adjustment: adjust the speed limit based on the prediction results of the traffic flow prediction model, combined with the real-time vehicle speed and traffic density.
9. A prediction method based on traffic management according to claim 8, characterized in that: The S6 further includes: S63, Traffic control measures: Based on the prediction results of the traffic flow prediction model, analyze the road sections or intersections where serious traffic congestion or bottlenecks may occur, and formulate and implement corresponding traffic control measures; S64, Traffic flow guidance: Develop and implement traffic flow guidance strategies based on the results of the traffic flow prediction model and real-time traffic flow information.
10. A prediction system based on traffic management, used to implement a prediction method based on traffic management as claimed in any one of claims 1 to 9, characterized in that: Includes the following modules: Data collection module: Through the sensor network deployed on traffic sections and road intersections, traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays are collected; Data preprocessing module: preprocess the collected traffic flow data under rainy and snowy weather conditions and traffic flow data during holidays; Feature extraction module: extracts feature variables closely related to traffic flow based on preprocessed traffic flow data; Model building module: using the extracted feature variables and machine learning algorithms to build a traffic flow prediction model; Prediction and analysis module: Based on the constructed traffic flow prediction model, real-time prediction of traffic flow in rainy and snowy weather conditions and during holidays is carried out. The prediction results include traffic flow density, vehicle speed, traffic bottleneck location and possible congestion points; Management strategy formulation module: formulate corresponding traffic management strategies based on the prediction results of the traffic flow prediction model.
Citation Information
Patent Citations
Control method based on big data
CN116758762A
Urban road traffic flow state prediction method and system based on big data
CN118447687A
Community traffic flow prediction and optimization system based on artificial intelligence
CN118982927A
Method, communidation device and storage medium for transmitting sidelink channel
KR1020250019430A
Cited By
Big data analysis and prediction system based on cloud computing
CN120297475A