A method for real-time monitoring and prediction of traffic congestion caused by specific sudden gathering events

By acquiring and processing historical and real-time traffic data, using drones and deep learning models to build high-resolution maps, and updating traffic congestion prediction results in real time, the problems of traditional methods lacking accuracy and real-time performance in specific sudden gathering events are solved, and more accurate and timely traffic congestion management is achieved.

CN118609356BActive Publication Date: 2025-09-19CHINA AUTOMOTIVE ENG RES INST +3
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202410681934.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-05-29
Publication Date
2025-09-19
Estimated Expiration
2044-05-29

AI Technical Summary

Technical Problem

Traditional traffic congestion prediction methods lack accuracy and real-time performance under specific sudden gathering events, making it difficult to predict traffic congestion in a timely and accurate manner.

Method used

By acquiring historical traffic data, specific event data, and real-time monitoring data, high-resolution maps are constructed using drone aerial images and geographic information system tools. Deep learning models are then used to update traffic congestion prediction results in real time, and the prediction information is sent to the management end in real time.

Benefits of technology

It achieves timely prediction and management of traffic congestion caused by specific sudden gathering events, improves the accuracy and real-time nature of predictions, and reduces the uncertainty of human judgment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118609356B_ABST
    Figure CN118609356B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of road vehicle traffic control methods, and specifically to a method for real-time monitoring and prediction of traffic congestion caused by specific sudden gathering events, comprising: obtaining historical traffic data, data at the time of specific events, and real-time monitoring data; using public roads as a basis, using drone aerial imagery to collect high-resolution map data; processing the collected map data using geographic information system tools, including extracting and modeling information such as road networks, terrain, and buildings, and constructing abstracted and parameterized real-world scenarios using virtual environments; inputting real-time monitoring data into a trained deep learning model, updating prediction results in real time, and providing real-time traffic congestion prediction information; and sending the real-time traffic congestion prediction to a management terminal for display. The present invention ensures that the system's perception of events is timely and comprehensive through real-time data capture; and the prediction results of traffic congestion are more accurate and consistent with actual conditions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of traffic control methods for road vehicles, and in particular to a method for real-time monitoring and prediction of traffic congestion induced by specific sudden gathering events. Background Art

[0002] Traditional traffic congestion prediction technologies use a series of steps to identify potential congestion trends in response to specific sudden and clustered events. First, historical traffic data is analyzed to explore common traffic patterns and changes in data before and after a congestion event. Second, statistical models and predefined rules are used to determine potential congestion situations. These triggers typically include thresholds, such as a decrease in vehicle speed or a certain level of traffic volume. Sensor networks are also used to detect sudden and clustered events, such as accidents or weather changes. Rule-based prediction methods then rely on these predefined rules and empirical data to compare real-time data with historical data to predict potential congestion. However, traditional technologies rely on manual intervention, often requiring the judgment and decision-making of traffic managers. Finally, after a potential congestion situation is predicted, information is transmitted to drivers, traffic management authorities, and other stakeholders through alarm systems or other notification methods, enabling timely action.

[0003] While these traditional methods have some feasibility, they are relatively simple and primarily based on pre-defined rules and empirical evidence. This can lead to inaccuracies and real-time performance when handling complex real-time traffic scenarios and emergencies. First, they lack accuracy: they are not very accurate in predicting traffic congestion caused by specific sudden clustering events, making them difficult to handle intricate real-time traffic scenarios. Because traditional methods rely primarily on historical data and pre-defined rules, they may not accurately predict the scale and impact of such emergencies. In reality, such clustering events can lead to temporary congestion, and traditional technologies may not be able to accurately and promptly predict such changes due to the complex and changing circumstances surrounding such events. Second, they lack real-time performance: traditional methods react slowly to emergencies and struggle to accurately predict future traffic congestion. Due to incomplete data collection, lack of real-time aggregation and processing, and frequent reliance on manual judgment, traditional technologies may not be able to detect and predict the occurrence of such emergencies in a timely manner. Even when congestion occurs, data lags and insufficiency make it difficult for traditional technologies to provide accurate predictions within the required real-time timeframe. Therefore, the poor real-time performance further highlights the limitations of insufficient data collection, untimely processing and human subjective judgment, making traditional technologies more challenging in dealing with traffic congestion caused by emergencies. Summary of the Invention

[0004] The present invention aims to provide a method for real-time monitoring and prediction of traffic congestion induced by specific sudden gathering events, so as to solve the problems of insufficient accuracy and poor real-time performance of traditional methods in predicting traffic congestion induced by specific sudden gathering events.

[0005] The method for real-time monitoring and predicting traffic congestion caused by a specific sudden gathering event in this solution includes the following steps:

[0006] S10, obtaining historical traffic data, data on specific events, and real-time monitoring data, including traffic volume, speed, queue length, vehicle type, total traffic volume within a specific time period, and pedestrian flow in each lane;

[0007] S20, based on public roads, uses drone aerial images to collect high-resolution map data. GIS tools are used to process the collected map data, including the extraction and modeling of road networks, terrain, buildings, and other information. A virtual environment is used to construct abstract and parameterized real-world scenes.

[0008] S30, which inputs real-time monitoring data into the trained deep learning model, updates the prediction results in real time, and provides real-time traffic congestion prediction information;

[0009] S40: Send the real-time traffic congestion prediction to the management terminal for display.

[0010] The beneficial effects of this program are:

[0011] By capturing data in real time, the system ensures that its perception of events is timely and comprehensive, and can promptly predict traffic congestion caused by specific sudden gathering events on the road, and manage traffic congestion through timely display; traffic congestion prediction is completed automatically without relying on human intervention, avoiding the uncertainty of human judgment; processing data to give prediction results in real time, improving the response speed and availability of the system.

[0012] Furthermore, in S10, the real-time monitoring data is sent to the edge device by collecting real-time images through the camera. The edge device is responsible for processing the sensor data of the real-time images in real time, performing target detection based on computer vision and sensing technology, and obtaining real-time monitoring data;

[0013] When measuring traffic flow, a rectangular area is divided in front and behind each lane using the stop line as the dividing point. When a target passes through these two areas, a counter is incremented by 1, and the number of vehicles passing through per unit time is used as the traffic flow of the lane.

[0014] When detecting vehicle speed, the vehicle speed is calculated by the position information and time difference of the target in the two frames of images.

[0015] During queue length detection, the queue length of each lane on the real-time screen is identified and calculated, and the distance from the rear of the last vehicle identified in each lane to the stop line is the queue length;

[0016] When detecting vehicle types, the system uses fine-grained vehicle classification to classify vehicles into non-motor vehicles, small vehicles, cars, buses, and trucks. The vehicle speed is determined based on the vehicle type, and the congestion level of the vehicle type is determined based on the vehicle speed.

[0017] When detecting the total traffic volume, a specific time is divided into multiple time periods, and the total number of vehicles passing through each time period is counted in real time as the total traffic volume;

[0018] When monitoring pedestrian flow, the pedestrian flow on the sidewalk is monitored in real time, the pedestrian flow data is integrated with the lane-level traffic data, the correlation between pedestrian flow and vehicle flow in different time periods and areas is analyzed, a corresponding relationship model between pedestrian flow and vehicle flow is established, the lane's transportation capacity is evaluated, and timely adjustments and optimizations are made.

[0019] The beneficial effect is that by detecting multiple real-time monitoring data on the real-time screen in different methods, the real-time monitoring data can be obtained in real time and accurately.

[0020] Furthermore, in S10, the difference between the total vehicle volume within the two set time periods before and after the transfer point of two adjacent specific time periods is compared. If the difference between the total vehicle volume within the two set time periods is within the set range, the specific time after will be shifted to the specific time before according to the set time period.

[0021] The beneficial effect is: because in some specific sudden gathering events, some people will consider the congestion after the completion of the specific sudden gathering event, and then arrange to leave or return in advance, which will eventually lead to a random increase in traffic flow in advance, so that the situation during a peak gathering period is divided into two specific times, causing errors in traffic flow judgment. Therefore, by comparing the difference in the total traffic volume of the set time length at two adjacent specific times, and then dynamically adjusting the specific time, the probability of the same gathering peak being at the same specific time is increased, making the detection and judgment of the total traffic volume more accurate.

[0022] Furthermore, in S20, a drone is used to take multiple pictures at a fixed point, and the pictures are synthesized to show a panoramic view of the intersection. The altitude is set to 100m, and one picture is taken in each direction of the intersection.

[0023] When registering aerial images with geographic coordinate systems, the sample control points collected in advance are used to perform a registration algorithm with the images taken by the drone, and the sample control points are registered using the affine transformation formula;

[0024] Suppose the coordinates of a point on the original image are (x, y), and the new coordinates obtained after affine transformation are (x', y'). The affine transformation can be expressed in the following matrix form:

[0025]

[0026] Where (a, b) and (c, d) are the coefficients of the linear transformation that control the scaling, rotation, and shearing of the image; (e, f) is the translation vector that controls the translation of the image;

[0027] Image segmentation algorithms and feature extraction techniques are used to identify buildings and extract building boundaries. Based on the line features of the road and the shape, color and other features of the lane markings, image processing and pattern recognition algorithms are used to extract the road network and identify the lane markings, and a map is built to obtain a virtualized and parameterized real scene.

[0028] The beneficial effect is that the virtualization and parameterization establishment method of the real scene can truly reflect the actual situation, so as to facilitate accurate analysis and prediction in the background.

[0029] Furthermore, in S20, icons are used in the virtual scene to replace real traffic signs and markings, and a real-time motion model is introduced to simulate dynamic changes in the real traffic scene;

[0030] Combining camera calibration and map modeling, images in the virtual environment are generated in real time to simulate real traffic scenarios, including vehicles driving on the road, pedestrians crossing, and traffic flow at intersections.

[0031] The beneficial effects are: reducing the complexity of the virtual scene, making it more visual and understandable, and ensuring that the virtual scene can truly reflect the traffic conditions of different roads and intersections.

[0032] Furthermore, in S20, the camera in the real scene is calibrated, and the landmark points with obvious features in the captured image are selected to obtain the pixel coordinates in the captured image and the world coordinates in the real scene. A mapping relationship between the captured image and the real scene is established through multiple groups of such points. The mapping formula is:

[0033]

[0034] Where R is the rotation matrix, T is the translation vector, (X, Y, Z) is the coordinates of the space point in the camera coordinate system, and (x, y, z) is the world coordinates.

[0035] The beneficial effect is that by describing the transformation relationship from the camera coordinate system to the world coordinate system, the captured image can be accurately matched with the actual coordinates.

[0036] Furthermore, in S30, the deep learning model is adjusted using a machine learning algorithm and a neural network to simulate the ever-changing traffic situation, including a target recognition model that captures traffic information at each intersection in real time and a decision model that makes predictions based on the traffic information;

[0037] The YOLOv5 model is used as the target recognition model. Through the collection, annotation, and training of specific scene images, the target recognition model integrates real-time monitoring data and divides the current traffic conditions into five states: smooth, slightly congested, moderately congested, severely congested, and extremely congested, for use in the decision-making model;

[0038] The decision model obtains state information from the target recognition model and takes a continuous data segment at 10s intervals, with each segment length being 1h, and preprocesses the obtained data;

[0039] The historical data is normalized into the format required by the deep learning model. The Transformer model is used as the prediction model, and the preprocessed data is used as the input sequence for training to predict the traffic status for the next 60 time steps.

[0040] Furthermore, in S30, the Transformer model processes the temporal information of the traffic state through position coding to capture changes in the traffic state. The position coding represents the position coding of each position in the sequence through sine and cosine functions, which is expressed as:

[0041]

[0042]

[0043] Where pos is the position, i is the index of the dimension, and d model is the dimension of the model;

[0044] The feedforward neural network in the Transformer model performs nonlinear transformations on the positional encoding to capture complex patterns and relationships in the data. The calculation formula of the feedforward neural network is:

[0045] FFN(x)=ReLU(xW1+b1)W2+b2:

[0046] Among them, W1 and W2 are the learning parameter matrices, b1 and b 21 is the bias vector and ReLU is the activation function.

[0047] The beneficial effect is that through position encoding, changes in traffic status at different time points can be accurately captured, and position encoding allows the model to consider time information when processing sequence data, which helps the model better understand the temporal sequence relationship of historical data and make accurate predictions.

[0048] Furthermore, in S10, the corresponding relationship model between pedestrian flow and vehicle flow adopts a three-section polynomial regression model, and the specific formula is:

[0049] y=β0+β1x+β2x 2 +β3x 3 +ε;

[0050] Among them, y is the traffic flow, x is the pedestrian flow, β0, β1, β2, β3 are the coefficients of the model, and ε is the error term.

[0051] The beneficial effect is that through model limitation, the corresponding situation of vehicle flow and pedestrian flow can be accurately reflected. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] Figure 1 This is a flowchart of an embodiment of a method for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event according to the present invention;

[0053] Figure 2 This is a system architecture diagram of an embodiment of a method for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event according to the present invention;

[0054] Figure 3 This is a Transformer network structure diagram in an embodiment of the method for real-time monitoring and prediction of traffic congestion induced by specific sudden gathering events of the present invention. DETAILED DESCRIPTION

[0055] The following is further detailed description through specific implementation methods.

[0056] Example 1

[0057] Methods for real-time monitoring and prediction of traffic congestion caused by specific sudden gathering events, such as Figure 1 and Figure 2 As shown, the following steps are included:

[0058] S10, obtain historical traffic data, data when specific events occur, and real-time monitoring data, including traffic volume, speed, queue length, vehicle type, total traffic volume in a specific time period, and pedestrian flow in each lane.

[0059] Real-time monitoring data is collected by cameras and sent to edge devices. The cameras are installed at the lanes. The edge devices are existing devices installed at the lanes. The edge devices are responsible for processing the sensor data of the real-time images in real time, performing target detection based on computer vision and sensing technology to obtain real-time monitoring data.

[0060] Traffic flow is the total number of vehicles passing through per unit time. Traffic flow data is broken down into lanes to provide more detailed traffic flow information. Using real-time data, dynamic curves of traffic flow are generated to help traffic management personnel more intuitively understand changing trends at intersections. Traffic flow detection uses individual cameras to collect lane-level data. Each lane is divided into two rectangular areas, one before and one after the stop line. After a target passes through these two areas, a counter is incremented by 1, and the number of vehicles passing through per unit time is used as the traffic flow for that lane. Real-time monitoring of traffic flow at specific intersections is performed to capture any sudden changes, especially the influx of vehicles that may occur at the end of a special event.

[0061] Vehicle speed is the speed at which a vehicle is traveling. Vehicle trajectory data is used to generate speed distribution maps, helping to identify areas of potential congestion or high-speed traffic. Combined with historical speed data, trend analysis is performed to predict future traffic conditions. Speed ​​detection calculates the vehicle's speed based on the target's position and time difference between the previous and next frames. Focusing on speeds at specific intersections, the system monitors speed changes in real time to identify potential congestion in advance.

[0062] In another embodiment, cameras are used to monitor the jamming situation in different lanes to predict potential traffic congestion. A high-definition camera monitoring system is used to monitor the vehicle driving conditions in each lane in real time, and automatically identify and record jamming behaviors. Edge devices process data and analyze the number of jams on major roads and intersections within a specific time period and within 500 meters of the event location. The specific time period is 2 hours before and after the start and end of the event. These data can help determine the frequency and distribution of jams in different lanes. Corrections for increasing or decreasing the degree of congestion: increasing the degree of congestion: if it is found that the number of jams in a lane exceeds the set value within a set time length, the congestion level of the lane is predicted to increase. Set the time length and the set value; reducing the degree of congestion: within the set time length, if the number of jams is less than half of the set value, the congestion expectation for the lane is predicted to decrease.

[0063] Cutting in can cause a congestion propagation effect, where congestion in one lane gradually spreads to adjacent lanes. For example, when congestion in the left-turn lane reaches a certain level, it can affect the speed of the through lane, causing vehicles in the through lane to stagnate and increase congestion in the through lane. By analyzing the cut-in situation in different lanes, it is possible to more accurately assess vehicle speed and congestion. If a lane is found to be significantly cut-in, the speed prediction for vehicles in that lane can be adjusted promptly to correct for any deviations in speed estimation. This helps improve the accuracy of congestion predictions and enable more timely implementation of traffic control measures to alleviate congestion. By analyzing the cut-in situation in different lanes, it is possible to more accurately predict traffic congestion and promptly correct for any deviations in speed estimation.

[0064] The queue length is the distance from the stop line to the rear of the last vehicle. Real-time monitoring of vehicle queues provides timely data support for intersection signal optimization. When detecting queue length, the camera captures images to identify and calculate the queue length for each lane. The queue length is calculated from the rear of the last vehicle identified in each lane to the stop line at the intersection traffic light. When the gap between two vehicles in a lane is greater than 10 meters, the distance from that vehicle to the stop line is used as the queue length, and the queue distance of the vehicle behind is discarded. The queue length for each lane can also be identified and calculated on the real-time screen, with the distance from the rear of the last vehicle identified in each lane to the stop line as the queue length.

[0065] Vehicle type detection uses fine-grained vehicle classification into non-motorized vehicles, small vehicles, cars, buses, and trucks. Small vehicles include bicycles, motorcycles, and tricycles. The vehicle speed is determined based on the vehicle type, and the congestion level of the vehicle type is determined based on the vehicle speed:

[0066] High-level congestion: Slower vehicles, such as large trucks and buses, are prone to high-level congestion in high-density situations. Because they travel at low speeds, even at low density, they can cause other vehicles to slow down, leading to high-level congestion. When these vehicles travel in narrow areas such as intersections, ramps, and curves, they can easily cause traffic jams, significantly impacting overall traffic flow.

[0067] Medium-level congestion: Faster vehicles, such as small cars, can cause medium-level congestion in high-density situations. Despite their high speeds, high density can still lead to medium-level localized congestion. When small vehicles gather in bottlenecks or high-traffic areas, the need to maintain safe distances can lead to traffic congestion, but the severity is relatively mild.

[0068] Low-level congestion: In low-density situations, most types of vehicles may not cause significant congestion. However, low-level congestion may still occur in certain circumstances. For example, when small vehicles travel on highways at low density but high speeds, low-level congestion may occur. This congestion may be temporary, such as due to traffic accidents, temporary construction, road closures, etc., and generally does not have a long-term impact on overall traffic flow.

[0069] By classifying congestion into different levels, we can more accurately assess the contribution of different types of vehicles to traffic congestion, thereby improving the prediction accuracy of the model.

[0070] Total vehicle flow is the total number of vehicles passing through a specific time period. This specific time period is set based on actual needs, for example, 12 hours. When monitoring total vehicle flow, the specific time period is divided into multiple time periods, and the total number of vehicles passing through each time period is counted in real time as the total vehicle flow. This allows for a more detailed understanding of traffic flow trends. By combining historical data with analysis of vehicle flow trends and visualizing the real-time distribution of vehicle flows using heat maps, traffic density in different areas can be intuitively understood. Multi-dimensional changes in time, vehicle type, and location provide a deeper and more comprehensive understanding of traffic flow characteristics and patterns. At specific intersections, such as exhibition hall entrances and exits, vehicle flow statistics can significantly impact traffic changes caused by specific sudden gatherings. Typically, a large number of vehicles will flow out within just a dozen minutes after the end of an exhibition or performance. Leveraging historical data and real-time monitoring information, we can predict the scale and duration of traffic flow at specific intersections following the end of a performance or exhibition, providing effective support for traffic management. Analyzing historical data for specific intersections, with a particular focus on traffic flow changes associated with special events like performances and exhibitions, provides empirical insights for predicting similar events in the future.

[0071] When monitoring pedestrian flow, we monitor the pedestrian flow on the sidewalk in real time, integrate the pedestrian flow data with the lane-level traffic data, analyze the correlation between pedestrian flow and vehicle flow in different time periods and areas, and establish a corresponding relationship model between pedestrian flow and vehicle flow. This model uses a three-section polynomial regression model. The specific formula is as follows:

[0072] y=β0+β1x+β2x 2 +β3x 3 +ε;

[0073] Where y represents vehicle flow, x represents pedestrian flow, β0, β1, β2, and β3 are model coefficients, and ε is the error term. Lane capacity is assessed and timely adjustments and optimizations are made. For changes in pedestrian flow caused by specific events, such as events and markets, historical data analysis and model predictions can be used to pre-evaluate the impact of events on sidewalk and roadway occupancy and pedestrian evacuation. Based on the predictions, appropriate traffic control measures can be implemented in advance, such as adjusting lane allocations, adding temporary traffic signs, and setting up temporary pedestrian lanes, to ensure smooth operation of the transportation system and safe evacuation of pedestrians. Furthermore, to adjust pedestrian and vehicle flow patterns, data mining and machine learning technologies within intelligent traffic management systems can be used to train and optimize the model. Through deep learning and pattern recognition of historical data, underlying patterns and correlations between pedestrian and vehicle flows can be discovered, thereby improving the model's adaptability to complex traffic environments and enabling more accurate pedestrian and vehicle flow prediction and correction. In summary, through comprehensive analysis and model optimization of pedestrian and vehicle flows, the ability to predict traffic congestion caused by specific gathering events, and the operating efficiency and safety of the transportation system can be more effectively improved.

[0074] Edge devices use the efficient communication protocol MQTT to transmit processed data to the central processing unit in real time. Edge computing technology allows for partial data processing on edge devices, reducing the amount of data transmitted to the central processing unit and improving the real-time performance of the system.

[0075] The central processor is responsible for aggregating data from various edge devices and performing further integration and cleansing. A distributed system architecture is applied to ensure high availability and processing capacity, while real-time stream processing technology is used for data processing.

[0076] S20, based on public roads, uses drone aerial images to collect high-resolution map data, and uses geographic information system (GIS) tools to process the collected map data, including the extraction and modeling of road networks, terrain, buildings, and other information. It uses virtual environments to construct abstract and parameterized real-world scenes to ensure the accuracy and precision of the map, so that real traffic scenes can be accurately simulated in the virtual environment. Specifically:

[0077] Use a drone to take multiple pictures at a fixed point, then synthesize the pictures to show the panoramic view of the intersection. The altitude is set to 100m, and one picture is taken in each direction of the intersection.

[0078] When registering the aerial image with the geographic coordinate system, in order to improve the accuracy of the map, the sample control points collected in advance are used to perform a registration algorithm with the images taken by the drone, and the sample control points are registered using the affine transformation formula. The sample control points collected in advance are collected using the existing method, which will not be repeated here;

[0079] Suppose the coordinates of a point on the original image are (x, y), and the new coordinates obtained after affine transformation are (x', y'). The affine transformation can be expressed in the following matrix form:

[0080]

[0081] Where (a, b) and (c, d) are the coefficients of the linear transformation that control the scaling, rotation, and shearing of the image; (e, f) is the translation vector that controls the translation of the image;

[0082] Image segmentation algorithms and feature extraction techniques are used to identify buildings and extract building boundaries. Image segmentation algorithms and feature extraction techniques are already available and will not be described in detail here. Based on the line features of the road and the shape, color and other features of the lane markings, image processing and pattern recognition algorithms are used to extract the road network and identify the lane markings, and a map is established to obtain a virtualized and parameterized real scene.

[0083] Icons replace real traffic signs and markings in virtual scenes, introducing a real-time motion model to simulate the dynamic changes in real traffic scenes. Icons are used to represent different types of signs, such as pedestrians, small vehicles, cars, buses, and trucks, making the virtual scenes more visual and understandable. Combining camera calibration and map modeling, images are generated in real time within the virtual environment to simulate real traffic scenarios, including vehicles on the road, pedestrians crossing, and traffic flow at intersections, ensuring that the virtual scenes accurately reflect the traffic conditions of different roads and intersections.

[0084] Calibrate the camera in the real scene, select the landmark points with obvious features in the captured image, obtain the pixel coordinates in the captured image and the world coordinates in the real scene, and establish the mapping relationship between the captured image and the real scene through multiple groups of such points. The mapping formula is:

[0085]

[0086] Where R is the rotation matrix, T is the translation vector, (X, Y, Z) is the coordinates of the space point in the camera coordinate system, and (x, y, z) is the world coordinates.

[0087] S30 feeds real-time monitoring data into a trained deep learning model, updates predictions in real time, and provides real-time traffic congestion forecasts. Using machine learning algorithms and neural networks, the deep learning model is adjusted to simulate ever-changing traffic conditions. This includes a target recognition model that captures traffic information at each intersection in real time, and a decision-making model that makes predictions based on this traffic information. By effectively integrating the target recognition model with the decision-making model, enabling them to work together, the system improves its integrated performance in real-time traffic monitoring and decision-making.

[0088] The YOLOv5 model is used as the target recognition model. The YOLO model is a deep learning model for real-time target recognition and localization. Its unique design enables it to simultaneously identify multiple targets in an image and locate their bounding boxes. The target recognition model is trained by collecting, annotating, and training specific scene images, and then undergoes extensive optimization of existing methods. It has good generalization performance and can adapt to the various specific traffic scenarios described in this patent. The target recognition model integrates real-time monitoring data to categorize current traffic conditions into five states: unobstructed, slightly congested, moderately congested, severely congested, and extremely congested, for use in the decision-making model.

[0089] The decision model obtains state information from the target recognition model and takes a continuous data segment at 10-second intervals. The length of each data segment is 1 hour, that is, each data segment contains 360 ordered state values. The obtained data is preprocessed. When there is noise and missing values ​​in the data, the preprocessing is to smooth the data and use sliding average to reduce the impact of noise on the model; for missing values, interpolation is used to ensure the integrity and continuity of the data.

[0090] like Figure 3 As shown, historical data is normalized into the format required by the deep learning model. The Transformer model is used as the prediction model, and the preprocessed data is used as the input sequence. The model is trained to predict traffic conditions for 60 time steps into the future. The Transformer is a sequence-to-sequence model that effectively captures long-range dependencies within sequences. The Transformer model is trained using historical data to minimize the error between the predicted sequence and the true sequence. Metrics such as the mean squared error (MSE) are used to measure the accuracy of the predictions.

[0091] Traffic status data is time-series. By taking the historical traffic status data sequence as input, the Transformer model can learn the dependencies between sequence data and thus predict future traffic status. The self-attention mechanism of the Transformer model allows the model to pay attention to the entire historical sequence at each time step, which can better capture the long-term dependencies in the sequence, thereby improving the accuracy of the prediction. In the self-attention mechanism, given an input sequence X = {x1, x2, ..., x n}, the attention weight is calculated by the following formula:

[0092]

[0093] Where Q = XW Q , K=XW K 、V=XW V They are respectively the query Q, key K, value V, and W obtained by linear transformation of the input sequence X. V is the learned parameter matrix, d k is the dimension of the key.

[0094] The Transformer model uses positional encoding to process the temporal information of traffic conditions, capturing changes in traffic conditions and accurately capturing changes in traffic conditions at different time points. Positional encoding allows the model to consider temporal information when processing sequence data, helping the model better understand the temporal order of historical data and make accurate predictions. The positional encoding uses sine and cosine functions to represent the positional encoding of each position in the sequence, expressed as:

[0095]

[0096]

[0097] Where pos is the position, i is the index of the dimension, and d model is the dimension of the model.

[0098] The feedforward neural network in the Transformer model performs nonlinear transformations on positional encodings to capture complex patterns and relationships in the data. In the Transformer model, residual connections exist between each sublayer's output and its input. Residual connections allow information to be passed directly within the network, helping to alleviate the problem of vanishing or exploding gradients and simplifying the training process. Residual connections also make the network easier to train, allowing for deeper stacking of layers and increasing the model's representational capabilities. Residual connections and normalization can alleviate the problem of vanishing or exploding gradients during model training, helping to improve the model's training stability and performance.

[0099] A feedforward neural network is included at each position, using two fully connected layers and an activation function. The calculation formula of the feedforward neural network is:

[0100] FFN(x)=ReLU(xW1+b1)W2+b2;

[0101] Among them, W1 and W2 are the learning parameter matrices, b1 and b 21 is the bias vector and ReLU is the activation function.

[0102] Using a subset of historical data as a validation set, cross-validation techniques are used to assess the generalization ability of the deep learning model and its performance on the validation set. Based on the validation set results, the model is then fine-tuned. Fine-tuning involves adjusting model hyperparameters, learning rates, and other parameters. This is the t-tuning process, which may require adjustments to the model's hyperparameters and learning rate. The training and fine-tuning process is iterated until the model performs satisfactorily on the validation set. The trained Transformer model is deployed in a real-world traffic system for real-time traffic status prediction. In practice, the model is regularly updated to adapt to changing traffic conditions and new data.

[0103] S40 sends the real-time traffic congestion forecast to the management terminal for display. The management terminal can be a terminal such as a tablet or mobile phone used by traffic management personnel. The traffic congestion forecast is displayed through intuitive charts, maps, and other elements, and can comprehensively display multi-dimensional traffic information, including key indicators such as traffic volume, speed, and queue length. This provides traffic management personnel with prediction results and helps them better respond to traffic congestion caused by specific sudden gathering events. It monitors specific sudden gathering times in real time and uses dynamic updates to display traffic conditions in real time, ensuring the timeliness of information and enabling traffic management personnel to quickly identify changing traffic flow trends. Different traffic conditions are indicated by color coding (green indicates unobstructed traffic, yellow indicates slow traffic, and red indicates congestion), which helps to quickly identify problem areas.

[0104] Compared to existing technologies, this embodiment utilizes real-time monitoring via cameras, data processing by local edge devices, and predictions by the central processor. This ensures the system can quickly respond and make accurate traffic forecasts. This allows for the timely detection of traffic congestion caused by specific sudden gatherings such as concerts and exhibitions, enabling traffic control to be implemented before the corresponding congestion occurs. This improves the effectiveness of traffic management and prevents traffic congestion from becoming too severe to clear. The real-time monitoring and prediction module more comprehensively considers key factors in data collection, processing, transmission, and prediction, improving the system's real-time performance, accuracy, and reliability.

[0105] Example 2

[0106] The method for real-time monitoring and prediction of traffic congestion induced by specific sudden gathering events is different from the method of embodiment 1 in that, in S10, the difference between the total amount of vehicle flow within the two set time periods before and after the transfer point of two adjacent specific time periods is compared, and the set time period is less than or equal to the specific time period, for example, the set time period is two-thirds of the length of the specific time period. If the difference in the total amount of vehicles within the two set time periods is within the set range, the specific time after will be shifted to the specific time before according to the set time period.

[0107] Since the leaders of a specific sudden gathering event are people or cars, and the leaders of cars are also people, due to the influence of people's subjective thinking, they will anticipate various congestion problems after the end of the specific sudden gathering event. Therefore, some leaders will take the initiative to leave the corresponding area in advance before the end of the specific sudden gathering event, thereby causing some time periods before the end of the specific sudden gathering event to enter congestion in advance. The division of the specific time period may divide the data that enters congestion in advance into two time periods, making the data appear less congested. Therefore, this embodiment 2 compares the difference between the total traffic volume of set durations at two adjacent specific times, and then dynamically adjusts the specific time to increase the probability of the same gathering peak being at the same specific time, making the detection and judgment of the total traffic volume more accurate.

[0108] Example 3

[0109] The method for real-time monitoring and prediction of traffic congestion induced by specific sudden gathering events differs from the first embodiment in that, in S40, the congestion prediction information also includes the stages of increasing pedestrian flow, increasing vehicle flow, and increasing both pedestrian and vehicle flow. When the congestion prediction information indicates the stages of increasing both pedestrian and vehicle flow, no data correction is performed. When the congestion prediction information indicates the stages of increasing pedestrian flow or increasing vehicle flow, the backend server obtains the event type of the specific sudden gathering event at the location of the congestion prediction information. This is obtained from pre-registered information on large-scale gathering events. Event types include exhibitions, actor concerts, and various types of centralized conferences.

[0110] The backend server collects statistics on the age distribution of the crowd in specific sudden gathering events based on the event type. The age distribution of the crowd is obtained from the advance ticket purchase, registration and other information of participating in the specific sudden gathering events. If there is no advance ticket purchase, registration and other information, the age distribution of the crowd is estimated based on the type of event and the specific exhibition time. For example, if the exhibition type is a housing fair and the exhibition time is a weekend, and there is no ticket purchase and registration information, the estimated participants of the housing fair are 60% young and middle-aged and 40% elderly people. If the exhibition type is furniture and the exhibition time is a weekday, the estimated participants of the furniture fair are 75% elderly people and 25% young and middle-aged.

[0111] After obtaining the age distribution of the crowd, the background server obtains the distribution of venue exits at the location of the specific sudden gathering event, and obtains the transportation conditions in the direction of each venue exit, and estimates the flow trend and flow speed of the crowd based on the transportation conditions and the age distribution of the crowd. For example, when the transportation is the subway, the flow trend of the elderly is estimated to be in the direction of the transportation, and the flow speed is slower. When the transportation is a taxi or an online car-hailing service, the flow trend of young and middle-aged people is in this direction, and the flow speed is relatively faster. According to the flow trend and flow speed, real-time correction information of the acquired data is fed back to S10, such as correction information of data acquired by increasing the frequency of sending when the flow trend and flow speed are slow.

[0112] Since there are great differences in the participants of different specific sudden gathering events, and there are certain differences in information such as the activity speed and transportation bias of different participants, if a fixed data acquisition frequency is used, the acquisition of data changes or changes in different situations will not be timely. In this embodiment three, when it is judged that the congestion prediction information is an increase in the flow of vehicles or people, the relevant information and type of the specific sudden gathering event is further obtained, the age of the participants is classified, and the flow trend and flow speed of participants of different age groups are further estimated in combination with the exit distribution of the venue and the transportation conditions in the exit direction. Finally, the data acquisition frequency of different locations is corrected to obtain data at different locations in a targeted and timely manner, and ensure that the corresponding congestion situation can be analyzed in time, so that the analysis of the congestion situation is more accurate and timely.

[0113] The above is only an embodiment of the present invention, and the common knowledge such as the specific structure and characteristics of the scheme is not described in detail here. It should be pointed out that for those skilled in the art, without departing from the structure of the present invention, several variations and improvements can be made, which should also be regarded as the scope of protection of the present invention, and these will not affect the effect of the implementation of the present invention and the practicality of the patent. The scope of protection required by this application shall be based on the content of its claims, and the specific implementation methods and other records in the specification can be used to interpret the content of the claims.

Claims

1. A method for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event, characterized in that: The following steps are involved: S10, acquiring historical traffic data, data from specific events, and real-time monitoring data, including traffic volume, speed, queue length, vehicle type, total traffic volume within a specific time period, and pedestrian flow in each lane. Compare the difference between the total traffic volume within two set time periods at the transfer point of two adjacent specific time periods. If the difference between the total traffic volume within the two set time periods is within a set range, shift the vehicle volume within the later specific time period to the earlier specific time period by the set time period. S20, based on public roads, uses drone aerial images to collect high-resolution map data. GIS tools are used to process the collected map data, including the extraction and modeling of road networks, terrain, and building information, and the use of virtual environments to construct abstract and parameterized real-world scenes. S30, which inputs real-time monitoring data into the trained deep learning model, updates the prediction results in real time, and provides real-time traffic congestion prediction information; S40, sending the real-time traffic congestion prediction to the management terminal for display; The congestion prediction information also includes the stage of increasing pedestrian flow, the stage of increasing vehicle flow, and the stage of increasing both pedestrian and vehicle flow. When the congestion prediction information is in the stage of increasing both pedestrian and vehicle flow, no correction is performed on the data. When the congestion prediction information is in the stage of increasing pedestrian flow or increasing vehicle flow, the backend server obtains the event type of the specific sudden gathering event at the location of the congestion prediction information, which is obtained from the pre-registered information of large-scale gathering events. The event types include exhibitions, actor concerts, and various types of concentrated meetings. The backend server calculates the age distribution of the crowd at a specific sudden gathering event based on the event type. The age distribution of the crowd is obtained from the pre-ticket purchase and registration information of the specific sudden gathering event. If there is no pre-ticket purchase and registration information, the age distribution of the crowd is estimated based on the type of event and the specific exhibition time. After obtaining the age distribution of the crowd, the background server obtains the distribution of venue exits at the location of the specific sudden gathering event, and obtains the transportation conditions in the direction of each venue exit, and estimates the flow trend and flow speed of the crowd based on the transportation conditions and the age distribution of the crowd; and feeds back real-time correction information of the obtained data to S10 according to the flow trend and flow speed.

2. The method of claim 1, wherein: In S10, the real-time monitoring data is collected by the camera in real time and sent to the edge device. The edge device is responsible for processing the sensor data of the real-time image in real time, performing target detection based on computer vision and sensing technology, and obtaining real-time monitoring data; When measuring traffic flow, a rectangular area is divided in front and behind each lane using the stop line as the dividing point. When a target passes through these two areas, a counter is incremented by 1, and the number of vehicles passing through per unit time is used as the traffic flow of the lane. When detecting vehicle speed, the vehicle speed is calculated by the position information and time difference of the target in the two frames of images. During queue length detection, the queue length of each lane on the real-time screen is identified and calculated, and the distance from the rear of the last vehicle identified in each lane to the stop line is the queue length; When detecting vehicle types, the system uses fine-grained vehicle classification to classify vehicles into non-motor vehicles, small vehicles, cars, buses, and trucks. The vehicle speed is determined based on the vehicle type, and the congestion level of the vehicle type is determined based on the vehicle speed. When detecting the total traffic volume, a specific time is divided into multiple time periods, and the total number of vehicles passing through each time period is counted in real time as the total traffic volume; When monitoring pedestrian flow, the pedestrian flow on the sidewalk is monitored in real time, the pedestrian flow data is integrated with the lane-level traffic data, the correlation between pedestrian flow and vehicle flow in different time periods and areas is analyzed, a corresponding relationship model between pedestrian flow and vehicle flow is established, the lane's transportation capacity is evaluated, and timely adjustments and optimizations are made.

3. The method for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event according to claim 1, characterized in that: In the S20, a drone is used to take multiple pictures at a fixed point, and the pictures are synthesized to show a panoramic view of the intersection. The altitude is set to 100m, and one picture is taken in each direction of the intersection; When registering aerial images with geographic coordinate systems, the sample control points collected in advance are used to perform a registration algorithm with the images taken by the drone, and the sample control points are registered using the affine transformation formula; Suppose the coordinates of a point on the original image are (x, y), and the new coordinates obtained after affine transformation are , then the affine transformation can be expressed in the following matrix form: ; Where (a, b) and (c, d) are the coefficients of the linear transformation that control the scaling, rotation, and shearing of the image; (e, f) is the translation vector that controls the translation of the image; Image segmentation algorithms and feature extraction techniques are used to identify buildings and extract building boundaries. Based on the line features of the road and the shape and color features of lane markings, image processing and pattern recognition algorithms are used to extract the road network and identify lane markings, and a map is built to obtain a virtualized and parameterized real scene.

4. The method of claim 3 for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event, characterized in that: In S20, icons are used in the virtual scene to replace real traffic signs and markings, and a real-time motion model is introduced to simulate dynamic changes in the real traffic scene; Combining camera calibration and map modeling, images in the virtual environment are generated in real time to simulate real traffic scenarios, including vehicles driving on the road, pedestrians crossing, and traffic flow at intersections.

5. The method for real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event according to claim 4, characterized in that: In S20, the camera in the real scene is calibrated, and landmark points with obvious features in the captured image are selected to obtain pixel coordinates in the captured image and world coordinates in the real scene. A mapping relationship between the captured image and the real scene is established through multiple groups of such points. The mapping formula is: ; Where R is the rotation matrix, T is the translation vector, (X, Y, Z) is the coordinates of the space point in the camera coordinate system, and (x, y, z) is the world coordinates.

6. The method of claim 1, wherein: In S30, the deep learning model is adjusted using a machine learning algorithm and a neural network to simulate the ever-changing traffic situation, including a target recognition model that captures traffic information at each intersection in real time and a decision model that makes predictions based on the traffic information; The YOLOv5 model is used as the target recognition model. Through the collection, annotation, and training of specific scene images, the target recognition model integrates real-time monitoring data and divides the current traffic conditions into five states: smooth, slightly congested, moderately congested, severely congested, and extremely congested, for use in the decision-making model; The decision model obtains state information from the target recognition model and takes a continuous data segment at 10s intervals, with each segment length being 1h, and preprocesses the obtained data; The historical data is normalized into the format required by the deep learning model. The Transformer model is used as the prediction model, and the preprocessed data is used as the input sequence for training to predict the traffic status for the next 60 time steps.

7. The method of claim 6, wherein: In S30, the Transformer model processes the temporal information of the traffic state through position coding to capture changes in the traffic state. The position coding represents the position coding of each position in the sequence through sine and cosine functions, which is expressed as: ; ; Where pos is the position, i is the index of the dimension, is the dimension of the model; The feedforward neural network in the Transformer model performs nonlinear transformations on the positional encodings to capture complex patterns and relationships in the data. The calculation formula of the feedforward neural network is: ; in, and is the learned parameter matrix, and is the bias vector and ReLU is the activation function.

8. The method of real-time monitoring and prediction of traffic congestion caused by a specific sudden gathering event according to claim 2, characterized in that: In S10, the corresponding relationship model between the pedestrian flow and the vehicle flow adopts a three-section polynomial regression model, and the specific formula is: ; in, It's traffic flow. It's the flow of people. 、 、 、 are the coefficients of the model, is the error term.

Citation Information

Patent Citations

  • Depth learning-based regional traffic signal lamp control system and method

    CN110349407A

  • Fusion method and system of mobile video and geographic scene and electronic equipment

    CN111582022A

  • Traffic flow information monitoring method based on deep learning and edge calculation

    CN114023062A

  • Traffic flow prediction method and device based on local-global spatial-temporal feature fusion

    CN116311880A

  • Composite scene area traffic signal optimization control method

    CN118053296A