Urban expressway vehicle conflict risk prediction method and device, equipment and medium

By acquiring vehicle trajectory and traffic flow data from urban expressways, performing preprocessing and feature fusion, and integrating indicators using membership functions and fuzzy rules, the problem of inaccurate vehicle conflict risk prediction in existing technologies has been solved, achieving more efficient risk prediction and improved traffic safety.

CN119832730BActive Publication Date: 2025-12-16WUHAN UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411914615.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-24
Publication Date
2025-12-16
Estimated Expiration
2044-12-24

AI Technical Summary

Technical Problem

In existing technologies, the prediction of vehicle conflict risk relies on data analysis from roadside and vehicle-mounted equipment, resulting in low accuracy of risk warnings across the entire road segment. Furthermore, traditional indicators are one-sided and cannot comprehensively and accurately predict vehicle conflict risk.

Method used

By acquiring vehicle trajectory data and traffic flow data from urban expressways, and after preprocessing, the severity of conflicts and risk probability indicators are integrated using membership functions and fuzzy rules. These indicators are then fused with temporal and spatial features to predict the risks of vehicles at future times.

Benefits of technology

It improves the accuracy of predicting vehicle conflict risks on urban expressways, and can more comprehensively reflect the propagation characteristics of vehicle conflict risks in the spatiotemporal dimensions, thereby reducing the incidence of traffic accidents.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119832730B_ABST
    Figure CN119832730B_ABST
Patent Text Reader

Abstract

The application discloses a kind of urban expressway vehicle conflict risk prediction method and device, equipment and medium, it can be applied to traffic data processing technical field.The application obtains the first data set including vehicle trajectory data and traffic flow data in urban expressway after, the data in first data set is preprocessed to obtain conflict severity index and conflict risk occurrence probability index, then based on membership function and fuzzy rule, conflict severity index and conflict risk occurrence probability index are integrated to obtain current risk index, simultaneously, the time feature and space feature of the data in first data set are extracted, the time feature and space feature are fused to obtain space-time feature, then according to current risk index and space-time feature, the risk prediction of vehicle future time is carried out, so that the accuracy of urban expressway vehicle conflict risk prediction can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of traffic data processing, and particularly relates to a city expressway vehicle conflict risk prediction method and device, equipment and medium. BACKGROUND

[0002] In the related art, the analysis and early warning of vehicle conflict risk mainly rely on the data collected by roadside monitoring equipment and vehicle-mounted equipment for analysis. However, the deployment of such equipment is limited, so only data of specific road sections can be collected, which may result in low accuracy of risk early warning of the entire road section. Moreover, the current conflict risk judgment usually uses safety alternative indicators such as TTC (Time to Collision) and PET (Post-Encroachment Time), but these indicators have certain one-sidedness, which also leads to low accuracy of road section risk early warning.

[0003] To sum up, the technical problems in the related art need to be improved. SUMMARY

[0004] The main purpose of the embodiments of the present application is to provide a city expressway vehicle conflict risk prediction method and device, equipment and medium, which can effectively improve the accuracy of city expressway vehicle conflict risk prediction.

[0005] To achieve the above purpose, one aspect of the embodiments of the present application provides a city expressway vehicle conflict risk prediction method, which comprises the following steps:

[0006] Obtaining a first data set of a city expressway, wherein the first data set comprises vehicle trajectory data and traffic flow data;

[0007] Preprocessing the data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index;

[0008] Integrating the conflict severity index and the conflict risk occurrence probability index based on a membership function and fuzzy rules to obtain a current risk index;

[0009] Extracting time features and space features of the data in the first data set;

[0010] Fusing the time features and the space features to obtain spatio-temporal features;

[0011] Performing risk prediction of a vehicle at a future time according to the current risk index and the spatio-temporal features.

[0012] In some embodiments, the obtaining of the first data set of the city expressway comprises:

[0013] Obtaining vehicle trajectory video data of an urban expressway;

[0014] Performing vehicle detection on the vehicle trajectory video data through a preset target detection model to obtain a target vehicle;

[0015] Performing tracking analysis on the target vehicle to obtain a target vehicle trajectory;

[0016] Extracting traffic flow data from the vehicle trajectory video data according to the vehicle trajectory;

[0017] Constructing the first data set according to the target vehicle trajectory and the traffic flow data.

[0018] In some embodiments, the preprocessing of the data in the first data set to obtain the conflict severity index and the conflict risk occurrence probability index comprises:

[0019] Preprocessing the data in the first data set to obtain a second data set;

[0020] Calculating a plurality of candidate indexes according to the second data set;

[0021] Selecting a target index from the plurality of candidate indexes according to index correlation and risk factors, the target index comprising the conflict severity index and the conflict risk occurrence probability index.

[0022] In some embodiments, the preprocessing of the data in the first data set comprises:

[0023] Deleting duplicate data in the first data set;

[0024] Cleaning data with speed anomalies in the first data set through a sigma criterion.

[0025] In some embodiments, the conflict risk occurrence probability index is calculated according to the following formula:

[0026]

[0027] In the formula, Δa represents the acceleration difference between the front and rear vehicles, Δv represents the speed difference between the front and rear vehicles, and d represents the initial distance between the front and rear vehicles.

[0028] In some embodiments, the integration of the conflict severity index and the conflict risk occurrence probability index based on the membership functions and fuzzy rules to obtain a current risk index comprises:

[0029] Constructing a first membership function and a second membership function;

[0030] a first membership degree is calculated according to the conflict severity index and the first membership degree function;

[0031] a second membership degree is calculated according to the conflict risk occurrence probability index and the second membership degree function;

[0032] fuzzy logic is constructed according to the fuzzy rules;

[0033] the current risk index is determined according to the first membership degree, the second membership degree and the fuzzy logic.

[0034] In some embodiments, the time feature and the space feature of the data in the first data set are extracted, including:

[0035] The time feature of the data in the first data set is extracted by an attention long short-term network model;

[0036] The space feature of the data in the first data set is extracted by a graph convolution network model.

[0037] To achieve the above object, another aspect of the embodiment of the present application proposes a device for predicting vehicle conflict risk on urban expressway, which comprises:

[0038] A first module is configured to acquire a first data set of urban expressway, wherein the first data set comprises vehicle trajectory data and traffic flow data;

[0039] A second module is configured to pre-process data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index;

[0040] A third module is configured to integrate the conflict severity index and the conflict risk occurrence probability index based on a membership degree function and fuzzy rules to obtain a current risk index;

[0041] A fourth module is configured to extract time feature and space feature of data in the first data set;

[0042] A fifth module is configured to fuse the time feature and the space feature to obtain space-time feature;

[0043] A sixth module is configured to predict risk of vehicle at future time according to the current risk index and the space-time feature.

[0044] To achieve the above object, another aspect of the embodiment of the present application proposes an electronic device, which comprises:

[0045] at least one processor;

[0046] at least one memory configured to store at least one program;

[0047] When the at least one program is executed by the at least one processor, the at least one processor implements the above method.

[0048] To achieve the above object, another aspect of the embodiment of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the above method.

[0049] The embodiment of the present application at least has the following beneficial effects: the present application provides a city expressway vehicle conflict risk prediction method and device, equipment and medium, the scheme obtains the first data set including vehicle trajectory data and traffic flow data in the city expressway, and the data in the first data set is preprocessed to obtain the conflict severity index and the conflict risk occurrence probability index, then the conflict severity index and the conflict risk occurrence probability index are integrated based on the membership function and the fuzzy rule to obtain the current risk index, and after the time feature and the space feature of the data in the first data set are extracted, the time feature and the space feature are fused to obtain the space-time feature, and then the risk prediction of the vehicle at the future moment is carried out according to the current risk index and the space-time feature, so that the accuracy of the city expressway vehicle conflict risk prediction can be effectively improved. BRIEF DESCRIPTION OF DRAWINGS

[0050] Figure 1 is a flowchart of the city expressway vehicle conflict risk prediction method provided by the embodiment of the present application;

[0051] Figure 2 is a shooting effect schematic diagram of the city expressway provided by the embodiment of the present application;

[0052] Figure 3 is a vehicle recognition effect schematic diagram provided by the embodiment of the present application;

[0053] Figure 4 is a vehicle trajectory tracking effect schematic diagram provided by the embodiment of the present application;

[0054] Figure 5 is a data distribution schematic diagram of TTC provided by the embodiment of the present application;

[0055] Figure 6 is a data distribution schematic diagram of MTTC provided by the embodiment of the present application;

[0056] Figure 7 is a data distribution schematic diagram of PSD provided by the embodiment of the present application;

[0057] Figure 8 is a data distribution schematic diagram of THW provided by the embodiment of the present application;

[0058] Figure 9is a schematic diagram of the relevance of the time metric index provided by the embodiment of the present application;

[0059] Figure 10 is a schematic diagram of the fuzzy logic provided by the embodiment of the present application;

[0060] Figure 11 is a schematic diagram of the fusion of the time feature and the space feature provided by the embodiment of the present application;

[0061] Figure 12 is a structural schematic diagram of the urban expressway vehicle collision risk prediction device provided by the embodiment of the present application;

[0062] Figure 13 is a hardware structural schematic diagram of the electronic device provided by the embodiment of the present application. DETAILED DESCRIPTION

[0063] In order to make the purpose, technical scheme and advantages of the present application more clear, the present application is further described in detail below in combination with the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. When the following description relates to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementation described in the following exemplary embodiments does not represent all the implementations consistent with the embodiments of the present application, but is only an example of devices and methods consistent with some aspects of the embodiments of the present application.

[0064] It can be understood that the terms "first", "second", and the like used in the present application can be used herein to describe various concepts, but unless specifically stated, these concepts are not limited by these terms. These terms are only used to distinguish one concept from another. For example, without departing from the scope of the embodiments of the present application, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as the first information. Depending on the context, the word "if" as used herein can be interpreted as "when" or "when" or "in response to determining".

[0065] The terms "at least one", "multiple", "each", "any" and the like used in the present application include one, two or more than two, multiple includes two or more than two, each refers to each of the corresponding multiple, and any refers to any one of the multiple.

[0066] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as understood by those skilled in the art to which the present application belongs. The terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.

[0067] In the related art, since the data collection of the vehicle-mounted and roadside devices relies on advanced sensor technology and stable communication network, all the data affecting the vehicle conflict risk of the road section cannot be obtained in time and accurately, and thus the vehicle conflict risk prediction accuracy is not high. Moreover, most algorithms only focus on the behavior characteristics in the time sequence, and the data is too single, and thus the vehicle conflict risk prediction accuracy is not high.

[0068] Therefore, the embodiments of the present application provide a city expressway vehicle conflict risk prediction method and device, equipment and medium. After obtaining a first data set including vehicle trajectory data and traffic flow data in the city expressway, the data in the first data set is preprocessed to obtain a conflict severity index and a conflict risk occurrence probability index. Then, the conflict severity index and the conflict risk occurrence probability index are integrated based on a membership function and fuzzy rules to obtain a current risk index. After extracting the time characteristics and the space characteristics of the data in the first data set, the time characteristics and the space characteristics are fused to obtain space-time characteristics. Then, the risk prediction of the vehicle at a future time is performed according to the current risk index and the space-time characteristics, so as to effectively improve the accuracy of the city expressway vehicle conflict risk prediction.

[0069] The city expressway vehicle conflict risk prediction method provided by the embodiments of the present application relates to the technical field of traffic data processing. The city expressway vehicle conflict risk prediction method provided by the embodiments of the present application can be applied to a terminal, can be applied to a server, and can also be software running in the terminal or the server. In some embodiments, the terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a vehicle-mounted terminal, and the like, but is not limited thereto. The server end can be configured as an independent physical server, can be configured as a server cluster or a distributed system composed of multiple physical servers, can be configured as a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDNs, and basic cloud computing services such as big data and artificial intelligence platforms, and the server can also be a node server in a blockchain network. The software can be an application for implementing the city expressway vehicle conflict risk prediction method, and the like, but is not limited to the above forms.

[0070] The application is operable in a multitude of general or special computer system environments or configurations. Examples of well known computing systems, environments, and / or configurations that can be suitable for use with the application include personal computers, server computers, handheld or laptop devices, tablet devices, multiprocessor systems, microprocessor-based systems, set top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments that include any of the above systems or devices, and the like. The application can be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, and the like, that perform particular tasks or implement particular abstract data types. The application can also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules can be located in local and remote computer storage media including memory storage devices.

[0071] Figure 1 is an optional flowchart of a city expressway vehicle conflict risk prediction method provided by an embodiment of the application, Figure 1 The method in the embodiment can include, but is not limited to, steps S101 to S106.

[0072] Step S110, acquiring a first data set of a city expressway, wherein the first data set includes vehicle trajectory data and traffic flow data;

[0073] Step S120, pre-processing data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index;

[0074] Step S130, integrating the conflict severity index and the conflict risk occurrence probability index based on a membership function and fuzzy rules to obtain a current risk index;

[0075] Step S140, extracting time features and space features of data in the first data set;

[0076] Step S150, fusing the time features and the space features to obtain spatio-temporal features;

[0077] Step S160, performing risk prediction of a future time of a vehicle according to the current risk index and the spatio-temporal features.

[0078] In the embodiment of the application, the process of acquiring the first data set of the city expressway can be performed by acquiring vehicle trajectory video data of the city expressway, performing vehicle detection on the vehicle trajectory video data by a preset target detection model to obtain a target vehicle, performing tracking analysis on the target vehicle to obtain a target vehicle trajectory, extracting traffic flow data from the vehicle trajectory video data according to the vehicle trajectory, and constructing the first data set according to the target vehicle trajectory and the traffic flow data.

[0079] It is understood that this embodiment allows for the use of drones to capture vehicle trajectory video data on urban expressways within legal and compliant airspace and timeframes. Specifically, to ensure comprehensive collection of vehicle trajectory video on urban expressways, this embodiment focuses on drone photography of highway sections with high traffic volume, covering areas such as mainline straightaways, curves, long distances, and areas with multiple lanes. Simultaneously, it prioritizes capturing merging, merging, and speed limit change scenarios at intersections, ramp entrances and exits, tunnel entrances and exits, and accident-prone sections. Each video data segment will cover at least one complete scene, with a length of 400-800 meters, a total duration of 2-3 hours, a resolution of 3840x2160, a frequency of 30Hz, and a drone altitude not exceeding 300 meters. Data collection will cover peak and off-peak hours, enabling comprehensive analysis of vehicle conflict risks under different traffic conditions. Specific shooting effects are shown below. Figure 2 As shown.

[0080] In this embodiment, after capturing vehicle trajectory video data, the video data can be preliminarily edited and converted in format to facilitate subsequent data processing. Then, based on the converted vehicle trajectory video data, target vehicle identification and tracking are performed to obtain the target vehicle trajectory. Specifically, this embodiment can use the YOLOV8 target detection model for target vehicle identification. The YOLOV8 target detection model can directly predict the target's position, category, and confidence level using regression methods, eliminating the need for multi-step processing like the R-CNN series. The YOLO algorithm directly feeds the image into the neural network, completing the prediction of the target bounding box, category, and confidence level in one step, achieving an end-to-end operation. It is understood that this embodiment can use the DeepSORT model for target vehicle tracking. DeepSORT is a deep learning-based multi-target tracking algorithm, developed from the original SORT algorithm. DeepSORT introduces deep learning to extract the target's appearance features, thereby improving tracking accuracy in complex scenes. DeepSORT has been widely used in various fields such as video surveillance, intelligent transportation systems, and crowd behavior analysis due to its high efficiency and robustness. In particular, DeepSORT has demonstrated its unique advantages in situations where multiple targets need to be accurately tracked and the scenarios are complex and ever-changing.

[0081] In the embodiments of the present application, YOLOv8 is used for vehicle detection, and the output bounding box and vehicle features can be used as input for DeepSORT. This seamless integration allows the YOLOv8+DeepSORT model to perform well in multi-target vehicle tracking. Specifically, in the application process, first install the dependent libraries such as Python, PyTorch, OpenCV, and clone the repositories of YOLOv8 and DeepSORT from GitHub. After installing the required dependencies, load the YOLOv8 pre-trained model and set the detection parameters, preprocess the collected vehicle trajectory video data, and use YOLOv8 for vehicle detection to obtain the bounding box and confidence. Then, extract the bounding box of each detected vehicle and initialize the DeepSORT tracker. Pass the detection results and features to DeepSORT for data association and tracking state update. Repeat this process on each frame of the video while visualizing the tracking results. Finally, adjust the parameters according to the actual application scenario to optimize performance. The vehicle recognition effect of the embodiments is shown in FIG. 1. Figure 3 The vehicle trajectory tracking effect is shown in FIG. 2. Figure 4 The vehicle trajectory tracking effect is shown in FIG. 2.

[0082] After completing the identification of target vehicles and vehicle trajectory tracking, the embodiments can extract traffic flow data from the vehicle trajectory video data to form a preliminary vehicle trajectory dataset. The preliminary vehicle trajectory dataset contains the following information: the sequence number of each frame of video, the unique identifier of the vehicle, the horizontal and vertical coordinate positions of the four vertices of the vehicle bounding box, and the length and width dimensions of the vehicle. Using the data in the preliminary vehicle trajectory dataset, real-time vehicle speed, acceleration and deceleration, and vehicle headway can be calculated. Combining these calculated parameters with the preliminary vehicle trajectory dataset will build a more comprehensive and rich first dataset.

[0083] In the embodiments of the present application, the process of preprocessing the data in the first dataset to obtain the conflict severity index and the conflict risk occurrence probability index includes but is not limited to the following steps:

[0084] Step S210, preprocessing the data in the first dataset to obtain a second dataset;

[0085] Step S220, calculating a plurality of candidate indexes according to the second dataset;

[0086] Step S230, selecting a target index from the plurality of candidate indexes according to the index correlation and risk factors, wherein the target index includes the conflict severity index and the conflict risk occurrence probability index.

[0087] It can be understood that due to the influence of various factors in the collection of the first data set, such as shooting weather, environmental conditions, vehicle trajectory target detection tracking algorithm errors, etc., the first data set inevitably has certain errors. In order to improve the data quality and the accuracy of the analysis, the first data set is cleaned and preprocessed in the embodiment to identify and correct these errors. Specifically, the embodiment first deletes the duplicate records in the first data set to avoid redundancy. Then, the data of the vehicle temporarily parked on the lane in the first data set is removed, and the vehicle data with too slow driving speed is cleaned according to the 3σ principle. For data points with abnormal speed changes, such as instantaneous reduction from high speed to zero, the missing speed value is estimated by calculating the distance and time interval between adjacent data points. At the same time, the 3σ principle is also applied to further clean the data with abnormal speed in the first data set. In addition, for the data in the first data set with continuously changing latitude and longitude and zero speed, the speed value is corrected by calculating the distance and time difference between adjacent coordinate points. Finally, for the repeated measurement data of the same vehicle at the same time point, the first valid data record is retained to ensure the consistency of the data.

[0088] It can be understood that the 3σ (Sigma) rule is also called the Ruda rule, which assumes that a set of detection data only contains random errors, and then calculates and processes to obtain the standard deviation. Then, according to a certain probability, an interval is determined, and it is considered that the error exceeding this interval is not a random error but a gross error, and the data with gross error is removed. The specific comparison process is as follows:

[0089] μ-3σ < X < μ+3σ;

[0090] In the formula, μ represents the average value of the data, σ represents the standard error of the data, and X represents a single data point in the data set.

[0091] In the embodiment of the application, since the time measurement index integrates the distance and speed factors, the time measurement index is used for conflict analysis in the embodiment. Specifically, the time measurement index includes but is not limited to TTC, MTTC, TIT, PSD, THW, MTC, DRAC, IMTTC, etc. Among them, TTC (Time to Collision) is the collision time, which represents the time required for the vehicle to reach the collision point with the front obstacle (such as another vehicle, pedestrian or other fixed obstacle) under the current speed and driving direction of the vehicle without changing the driving state. Its data distribution is as shown in Figure 5 The specific calculation process is as follows:

[0092]

[0093] In the formula, TTC represents the collision time; x r and vr , respectively, represent the relative distance and relative speed of the front and rear vehicles; x i and x p represent the positions of the rear of the front vehicle and the front of the rear vehicle, respectively, and x p > x i ; v l and v p represent the speeds of the front and rear vehicles, respectively.

[0094] It can be understood that there are many derivative indexes of TTC. The MTTC (modified time-to-collision) is a variant of TTC, which considers the accelerations and speeds of the following vehicle and the leading vehicle, so that the MTTC has stronger robustness, and its data distribution is as shown in Figure 6 In the MTTC, the condition for the vehicle to collide is as follows:

[0095]

[0096] In the formula, v f and v1 represent the speeds of the front and rear vehicles, respectively, and a f and a1 represent the accelerations of the front and rear vehicles, respectively.

[0097] The calculation formula of the MTTC is as follows:

[0098]

[0099] In the formula, Δa represents the acceleration difference between the front and rear vehicles; Δv represents the speed difference between the front and rear vehicles, and d represents the initial distance between the front and rear vehicles.

[0100] The TIT (Time Integrated TTC) is used to measure the severity of traffic conflicts, and its calculation formula is as follows:

[0101]

[0102] In the formula, t represents the time step; T represents the research time period, TTC * represents the TTC threshold, TTC i (t) represents the TTC value of the vehicle i at time t, and τ sc represents the time interval.

[0103] The PSD (Potential Safety Distance) is a concept used to evaluate the safety margin when a vehicle follows, which is the ratio of the actual distance between two vehicles to the distance required to avoid collision under the maximum available deceleration rate (MADR), and its data distribution is as shown in Figure 7The PSD value greater than 1 indicates that the actual distance is sufficient to avoid collision at the maximum available deceleration, and the PSD value less than 1 indicates that the distance is insufficient and there is a risk of collision. The calculation formula of PSD is as follows:

[0104]

[0105] In the formula, D represents the current distance between the vehicle and the front vehicle, v represents the current speed of the vehicle, and a max represents the maximum deceleration that the vehicle can exert (usually set to 3.924 m / s considering the friction and the earth's gravity).

[0106] THW (time headway) is an important indicator for evaluating driving safety, reflecting the time interval of the head ends of two consecutive vehicles passing through a section in a vehicle queue driving on the same lane. The data distribution is as shown in Figure 8 The calculation formula of THW is as follows:

[0107]

[0108] In the formula, D represents the headway, and v represents the speed of the rear vehicle.

[0109] It can be understood that the correlation of the above-mentioned time measurement indicators is as shown in Figure 9 Because there is a high correlation in some conflict risk indicators (time measurement indicators), they may reflect the same aspect of the data, leading to information redundancy. At the same time, it may lead to the problem of multicollinearity, making the estimation of the indicators of the model unstable and difficult to explain. Therefore, before the next conflict analysis, the embodiment comprehensively considers the correlation of the indicators to ensure the effectiveness, accuracy and practicability of the analysis results, for example, TTC cannot well represent the conflict risk when the speeds of the front and rear vehicles are close, and in some cases, it cannot serve as a conflict risk indicator. In addition, the selection of the conflict risk indicators should be selected from the conflict severity and the conflict risk probability. Based on this, the embodiment selects THW as the conflict severity indicator and MTTC as the conflict risk probability indicator.

[0110] In the embodiment of the application, the process of integrating the conflict severity indicator and the conflict risk probability indicator based on the membership function and the fuzzy rule to obtain the current risk indicator includes but is not limited to the following deficiencies:

[0111] Step S310, constructing a first membership function and a second membership function;

[0112] Step S320, calculating a first membership degree according to the conflict severity indicator and the first membership function;

[0113] Step S330, calculating the second membership degree according to the conflict risk occurrence probability index and the second membership degree function;

[0114] Step S340, constructing the fuzzy logic according to the fuzzy rule;

[0115] Step S350, determining the current risk index according to the first membership degree, the second membership degree and the fuzzy logic.

[0116] It can be understood that the first membership degree function is as follows:

[0117]

[0118] In the formula, x represents an upper limit constant, which can be determined according to actual conditions.

[0119] The embodiment can calculate the first membership degree according to the conflict severity index. Specifically, when MTTC>6s, it is determined that the low risk occurrence probability, when MTTC is between 6 seconds and infinity, the first membership degree increases from 0 and reaches a certain threshold (for example, reaches 1). When 4 seconds<MTTC≤6 seconds, it is determined that the moderate risk occurrence probability, when MTTC is between 4 seconds and 6 seconds, the first membership degree increases from 0 to 1. MTTC≤4 is determined as the high risk occurrence probability, when MTTC is between 0 and 4 seconds, the first membership degree decreases from 1 to 0.

[0120] The second membership degree function is as follows:

[0121]

[0122] The embodiment can calculate the second membership degree according to the conflict risk occurrence probability index. Specifically, when THW>2 seconds, it is determined to be safe. When 1.1 seconds<THW≤2 seconds, it is determined to be the moderate risk severity, when THW is between 1.1 seconds and 2 seconds, the second membership degree increases from 0 to 1. THW≤1.1 seconds is determined as the high risk severity, when THW is between 0 and 1.1 seconds, the second membership degree decreases from 1 to 0.

[0123] The embodiment quantifies the previous data to the degree of belonging to the fuzzy set (L, M, H) through the above membership degree function, so as to integrate the conflict frequency and the conflict severity into a whole risk index as the current risk index through the fuzzy logic.

[0124] In the embodiments of the present application, the following three criteria are mainly followed for the establishment of fuzzy rules: when the conflict frequency and the conflict severity are both low, the overall risk indicator is also low; when the conflict frequency is low and the conflict severity is high, or the conflict frequency is high and the conflict severity is low, the overall risk indicator is medium; when the conflict frequency and the conflict severity are both high, the overall risk indicator is high. Based on the above three criteria, nine fuzzy rules are established, and the specific fuzzy logic is as shown in Figure 10

[0125] It can be understood that, since the propagation of vehicle conflict risk not only has time continuity, but also presents spatial diffusion. Therefore, in order to more accurately predict and prevent vehicle conflict risk, the embodiments comprehensively consider the propagation characteristics of time dimension and space dimension, and make all-round and multi-angle prediction and optimization of vehicle conflict risk, so as to improve the accuracy of risk prediction and effectively reduce the probability of traffic accidents. Specifically, the embodiments first divide the data in the first data set into a training set, a validation set and a test set in the proportions of 70%, 15% and 15% respectively, to facilitate the subsequent training of the model.

[0126] For time series prediction, since the vehicle conflict risk data is a dynamic time series, the embodiments extract time features from the time correlation of consecutive frames in the sequence. Specifically, traditional neural networks have difficulty in dealing with long-term dependence problems in time series, while RNN can capture this dependence to some extent through its loop structure. Although the basic RNN has the problem of gradient disappearance or explosion, improved variants such as LSTM (Long Short-Term Memory Network) can more effectively handle long-term dependencies.

[0127] Among them, LSTM is a solution to overcome the short-term memory problem, which introduces an internal mechanism called "gate" to regulate information flow. Therefore, the present application selects to use LSTM to extract spatial features. The LSTM unit includes three gates, of which the input gate is used to decide which information in the current input data needs to be updated to the cell state, the forget gate decides which information needs to be discarded from the cell state, and decides which information in the cell state needs to be output to the next hidden state.

[0128] Forget gate: f t = σ(W f · [h t-1 , x t ] + b f ) ;

[0129] Input gate: i t = σ(W i · [h t-1 , x t ] + b i ) ; ​

[0130] Output gate: o t =σ(W o ·[h t-1 ,x t ]+b o );

[0131] New candidate cell status:

[0132] Cell state:

[0133] Hidden state:

[0134] In the formula, W f W i W o Let b be the weight matrix. f b i b o is the bias value, ⊙ is the element-wise multiplication operation, and tanh is the hyperbolic tangent function.

[0135] Furthermore, this embodiment adds an attention layer to the LSTM to construct a novel attention-LSTM model, achieving better prediction results. The attention mechanism allows the network to selectively focus on specific time steps when processing the input sequence. This mechanism helps the network better understand and utilize key information in the input sequence.

[0136] In this application, the input data is first converted into a three-dimensional array with dimensions [number of samples, time step, number of features]. Next, a Sequential model is created, and an LSTM layer is added. Each LSTM layer requires specifying the number of neurons and the shape of the input. Through cross-validation, the model performs best with 128 neurons and a 3-second time step. After the LSTM layer, an attention layer is added. This embodiment uses the TensorFlow Addons' Attention layer to assign different weights to the output at different time steps, and then applies a softmax function to ensure the sum of the weights is 1. A fully connected layer is added after the attention layer as the output layer, and the number of neurons in this layer should match the dimension of the output. After completing the model structure, the model is compiled using the mean squared error loss function and the Adam optimizer. Then, the model is trained by calling the `fit` method, passing in the training data and labels, as well as defined training parameters such as batch size and number of training epochs, to obtain the temporal features.

[0137] For the spatial feature prediction of the spatial dimension, the embodiment selects a graph convolution network model. The graph convolution network model is a neural network that performs convolution operations on a graph, can automatically learn the feature representation of the graph structure, and realizes feature extraction and classification on the graph. The graph convolution network model has the ability to process large-scale graph data, and has good scalability and efficiency. In traffic conflict analysis, a large amount of trajectory data usually needs to be processed, and the graph convolution network model can efficiently process these data, improving the speed and accuracy of the analysis. Specifically, the graph convolution network model is as follows:

[0138]

[0139] In the formula, H (l) represents the node feature matrix of the lth layer; represents the adjacency matrix of the graph; W (l) is the weight matrix of the lth layer; and σ(·) represents an activation function.

[0140] Specifically, the embodiment first divides the data in the first data set into several regions according to the lanes and lengths, numbers the regions, and converts the input data into a three-dimensional array with dimensions [lane, region, feature number]. Then, a graph convolution network model is created, and a graph convolution layer is added to it. Each graph convolution layer needs to specify the number and size of filters and the shape of the input. Through cross-validation, the model performs best when the number of filters is set to 32 and the filter size is 3x3. After the graph convolution layer, a global average pooling layer is added to summarize the spatial features of each sample. Then, a fully connected layer is added as the output layer, and the number of neurons in the layer should match the dimension of the output result. After completing the model structure, the Adam optimizer is used to compile the model. Then, the model is trained by calling the fit method of the model, inputting the training data and labels, and defining the batch size, number of training rounds, and other training parameters to obtain the spatial features.

[0141] It can be understood that, after obtaining the time features and spatial features, the time features (Time) and spatial features (spatial) are fused as shown in Figure 11 . The output result can be input into a fully connected layer to map the fused features to a category space, and then the probability distribution of each risk category can be obtained. In combination with the current risk indicator, the probability of the risk occurring at the future time can be predicted. Specifically, the output result of the fully connected layer is a vector with a size of (N, 3), where N represents the batch size, each row corresponds to the output vector of an input sample, and 3 represents three vehicle conflict risk levels L, M, and H. The maximum probability in the category is the result of the conflict risk prediction.

[0142] From the above, the method provided by the embodiment of the application has the following beneficial effects:

[0143] The application can obtain more comprehensive and real-time traffic flow data by taking advantage of the high-altitude perspective and flexible maneuvering of the unmanned aerial vehicle, thereby comprehensively analyzing the vehicle conflict risk. The data set provides important data support for the analysis of vehicle conflict risk on urban expressways, and can be used to develop more accurate and practical vehicle conflict risk prediction models, thereby effectively reducing the incidence of traffic accidents and improving the level of road traffic safety. Moreover, the embodiment can more comprehensively reflect the propagation characteristics of vehicle conflict risk in the time-space dimension by fusing the time characteristics and the space characteristics, thereby more accurately predicting potential conflict risks and providing important reference for traffic management and decision-making.

[0144] With reference to Figure 12 The embodiment of the application provides a vehicle conflict risk prediction device for urban expressways, and the device comprises:

[0145] A first module 1210 is configured to obtain a first data set of the urban expressway, wherein the first data set comprises vehicle trajectory data and traffic flow data;

[0146] A second module 1220 is configured to pre-process the data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index;

[0147] A third module 1230 is configured to integrate the conflict severity index and the conflict risk occurrence probability index based on a membership function and fuzzy rules to obtain a current risk index;

[0148] A fourth module 1240 is configured to extract time characteristics and space characteristics of the data in the first data set;

[0149] A fifth module 1250 is configured to fuse the time characteristics and the space characteristics to obtain time-space characteristics;

[0150] A sixth module 1260 is configured to perform risk prediction of a future time of a vehicle according to the current risk index and the time-space characteristics.

[0151] It can be understood that the content in the above method embodiment is applicable to the device embodiment, the device embodiment specifically implements the same functions as the above method embodiment, and achieves the same beneficial effects as the above method embodiment.

[0152] The embodiment of the present application further provides an electronic device, which comprises a memory and a processor. The memory stores a computer program, and the processor executes the computer program to realize the above-mentioned city expressway vehicle collision risk prediction method. The electronic device can be any intelligent terminal, such as a tablet computer or a vehicle-mounted computer.

[0153] It can be understood that the contents in the above-mentioned method embodiments are applicable to the present device embodiment, the present device embodiment specifically realizes the same functions as the above-mentioned method embodiments, and achieves the same beneficial effects as the above-mentioned method embodiments.

[0154] Please refer to Figure 13 , Figure 13 The hardware structure of the electronic device of another embodiment is illustrated, and the electronic device comprises:

[0155] The processor 1310 can be implemented in the form of a general-purpose CPU (Central Processing Unit), a microprocessor, an ASIC (Application Specific Integrated Circuit), or one or more integrated circuits, and is used to execute related programs to realize the technical solutions provided by the embodiments of the present application.

[0156] The memory 1320 can be implemented in the form of a ROM (Read Only Memory), a static storage device, a dynamic storage device, or a RAM (Random Access Memory). The memory 1320 can store an operating system and other application programs. When the technical solutions provided by the embodiments of the present application are implemented by software or firmware, the related program codes are stored in the memory 1320 and are called and executed by the processor 1310 to realize the city expressway vehicle collision risk prediction method of the embodiments of the present application.

[0157] The input / output interface 1330 is used to realize information input and output.

[0158] The communication interface 1340 is used to realize the communication interaction between the device and other devices. The communication can be realized by a wired manner (for example, a USB, a network cable, etc.) or a wireless manner (for example, a mobile network, WIFI, Bluetooth, etc.).

[0159] The bus 1350 transmits information between various components (for example, the processor 1310, the memory 1320, the input / output interface 1330, and the communication interface 1340) of the device.

[0160] The processor 1310, the memory 1320, the input / output interface 1330, and the communication interface 1340 are communicatively connected with each other through a bus 1350.

[0161] The embodiment of the present application further provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the urban expressway vehicle collision risk prediction method.

[0162] It can be understood that the contents in the above method embodiments are all applicable to the present storage medium embodiment, the present storage medium embodiment specifically implements the functions of the above method embodiments, and achieves the same beneficial effects as the above method embodiments.

[0163] The memory is a non-transitory computer readable storage medium, and can be used to store a non-transitory software program and a non-transitory computer executable program. In addition, the memory can include a high-speed random access memory, and can also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state memory device. In some embodiments, the memory can optionally include a memory remotely arranged relative to the processor, and these remote memories can be connected to the processor through a network. Examples of the above network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof.

[0164] The embodiments described in the embodiments of the present application are used to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art can know that, with the evolution of technology and the appearance of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0165] Those skilled in the art can understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and can include more or fewer steps than the figures, or combine certain steps, or different steps.

[0166] The device embodiments described above are only schematic, and the units described as separate components can or can not be physically separate, that is, can be located in one place, or can be distributed on multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the present embodiment.

[0167] Those skilled in the art can understand that all or some of the steps in the above disclosed method, the functional modules / units in the system and the device can be implemented as software, firmware, hardware and their appropriate combinations.

[0168] The terms "first", "second", "third", "fourth", and the like in the description and in the claims of this application, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the use of the terms so termed is interchangeable under appropriate circumstances such that the embodiments of the application described herein are, for example, capable of orderly or chronological mundane operation, reverse order operation, based on circuitry availability, based on stated preference or the like, and that "default" or other orderings are thus permissible. Further, the terms "comprise", "comprising", "include", "including", and the like, are specifically intended to be open-ended. That is, references to individual steps and the like do not suhstantially exclude the presence of two or more of a given step or its integral presence in the process, method, system, article, or apparatus having been made with a wider scope. The use of notation such as "first", "second", "third", etc. does not generally limit the areas, but is used to connect like elements or to distinguish one claim from another. These terms can be used interchangeably when appropriate. Terms concerning the relative position of elements can be interpreted such that their use adheres to their normal meaning, but they can also be interpreted to mean the opposite according to specific claims.

[0169] It should be understood that, in the application, "at least one" refers to one or more, and "multiple" refers to two or more. "And / or" is used to describe the relationship between associated objects, which means that there can be three relationships, for example, "A and / or B" can represent three cases: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the front and rear associated objects. "At least one of the following" or similar expressions means any combination of these items, including any combination of single or multiple items. For example, at least one of a, b or c can mean a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0170] In several embodiments provided by the application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative, for example, the division of the above-mentioned units is only a logical functional division, and actual implementation can have another division manner, for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the displayed or discussed each other can be indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.

[0171] The units described above as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, that is, they can be located in one place, or they can be distributed on multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the embodiment of the application.

[0172] In addition, each function unit in each embodiment of the present application can be integrated in one processing unit, or each unit can be physically present separately, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software function unit.

[0173] When the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application, essentially or in part, or all or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes multiple instructions used to cause a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods in the embodiments of the present application. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various other media that can store programs.

[0174] The preferred embodiments of the embodiments of the present application are described above with reference to the accompanying drawings, and are not intended to limit the scope of the embodiments of the present application. Any modifications, equivalent replacements and improvements made by those skilled in the art without departing from the scope and essence of the embodiments of the present application shall be within the scope of the embodiments of the present application.

Claims

1. A method for predicting the risk of vehicle collision on urban expressway, characterized in that, The method comprises the following steps: obtaining a first data set of urban expressway, wherein the first data set comprises vehicle trajectory data and traffic flow data; preprocessing data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index; integrating the conflict severity index and the conflict risk occurrence probability index based on a membership function and a fuzzy rule to obtain a current risk index; extracting time characteristics and space characteristics of data in the first data set; fusing the time characteristics and the space characteristics to obtain space-time characteristics; performing risk prediction of a vehicle at a future time based on the current risk index and the space-time characteristics; wherein the conflict severity index comprises a headway, which is used to reflect a time interval of passing a section by head ends of two continuous vehicles in a vehicle queue traveling on the same lane; a calculation formula of the conflict risk occurrence probability index is as follows: ; In the formula, MTTC represents the conflict risk occurrence probability index; ; ; represents the acceleration difference between the front and rear vehicles; represents the speed difference between the front and rear vehicles, represents the initial distance between the front and rear vehicles; the risk prediction of the vehicle at the future time based on the current risk index and the space-time characteristics comprises: mapping the space-time characteristics to a category space to obtain a probability distribution of each risk category; predicting a probability of risk occurrence at the future time based on the probability distribution and the current risk index.

2. The method of claim 1, wherein, The obtaining of the first data set of the urban expressway comprises: obtaining vehicle trajectory video data of the urban expressway; performing vehicle detection on the vehicle trajectory video data by using a preset target detection model to obtain a target vehicle; performing tracking analysis on the target vehicle to obtain a target vehicle trajectory; extracting traffic flow data from the vehicle trajectory video data based on the target vehicle trajectory; constructing the first data set based on the target vehicle trajectory and the traffic flow data.

3. The method of claim 1, wherein, The preprocessing of the data in the first data set to obtain the conflict severity index and the conflict risk occurrence probability index comprises: preprocessing the data in the first data set to obtain a second data set; calculating a plurality of candidate indexes based on the second data set; selecting target indexes from the plurality of candidate indexes based on index correlation and risk factors, wherein the target indexes comprise the conflict severity index and the conflict risk occurrence probability index.

4. The method of claim 3, wherein, The preprocessing of the data in the first data set comprises: deleting duplicate data in the first data set; cleaning data with speed anomaly in the first data set by using a sigma criterion.

5. The method of claim 1, wherein, The integration of the conflict severity index and the conflict risk occurrence probability index based on the membership function and the fuzzy rule to obtain the current risk index comprises: constructing a first membership function and a second membership function; calculating a first membership degree based on the conflict severity index and the first membership function; calculating a second membership degree based on the conflict risk occurrence probability index and the second membership function; constructing a fuzzy logic based on the fuzzy rule; determining the current risk index based on the first membership degree, the second membership degree and the fuzzy logic.

6. The method of claim 1, wherein, The extraction of the time characteristics and the space characteristics of the data in the first data set comprises: extracting time features of data in the first data set by an attention long short-term network model; extracting spatial features of data in the first data set by a graph convolution network model.

7. An urban expressway vehicle collision risk prediction device characterized by comprising: The device comprises: a first module configured to acquire a first data set of an urban expressway, the first data set comprising vehicle trajectory data and traffic flow data; a second module configured to pre-process data in the first data set to obtain a conflict severity index and a conflict risk occurrence probability index; a third module configured to integrate the conflict severity index and the conflict risk occurrence probability index based on a membership function and fuzzy rules to obtain a current risk index; a fourth module configured to extract time features and spatial features of data in the first data set; a fifth module configured to fuse the time features and the spatial features to obtain spatio-temporal features; a sixth module configured to perform risk prediction of a vehicle at a future time based on the current risk index and the spatio-temporal features. The conflict severity index comprises headway, which reflects a time interval of head ends of two consecutive vehicles in a vehicle queue traveling on the same lane passing through a section. The conflict risk occurrence probability index is calculated according to the following formula: ; In the formula, MTTC represents the conflict risk occurrence probability index; ; ; represents the acceleration difference between the front and rear vehicles; represents the speed difference between the front and rear vehicles, represents the initial distance between the front and rear vehicles; The risk prediction of the vehicle at the future time based on the current risk index and the spatio-temporal features comprises: mapping the spatio-temporal features to a category space to obtain a probability distribution of each type of risk; predicting a probability of risk occurrence at the future time according to the probability distribution and the current risk index.

8. An electronic device, comprising: comprise: at least one processor; at least one memory configured to store at least one program; when the at least one program is executed by the at least one processor, the at least one processor implements the method according to any one of claims 1 to 6.

9. A computer-readable storage medium storing a computer program, the computer program comprising instructions that, when executed by a computer, cause the computer to perform the method of any one of claims 1 to 8. The computer program is executed by the processor to implement the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Mountainous area double-lane highway hidden danger section traffic conflict risk dynamic evaluation method

    CN112508392A

  • Method for predicting short-time traffic risk of road section by utilizing roadside observation data

    CN113436432A