Method, device and product for predicting probability of occurrence of traffic accidents on urban expressway

By integrating traffic flow information and taxi GPS trajectory data, and using D-S evidence theory and machine learning algorithms, a real-time traffic accident prediction model is constructed, which solves the problem that existing technology cannot reflect traffic flow status and real-time prediction, and realizes the prediction of traffic accident risks. Accurate prediction and early warning improve traffic safety.

CN118675320AInactive Publication Date: 2024-09-20TAIZHOU UNIV (ZHEJIANG)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410675497.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-28
Publication Date
2024-09-20
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing urban expressway traffic accident prediction methods cannot fully reflect the impact of traffic flow status in different spatial ranges on accident risks, and cannot predict the possibility of accidents in real time and provide early warning.

Method used

By collecting and processing the traffic flow information of the target road, taxi GPS trajectory data and traffic accident records, using D-S evidence theory to fuse average speed, and combining BalancedBagging and GBDT/XGBoost algorithms, a real-time urban expressway traffic accident risk prediction model is constructed, and the model is optimized to Predict the probability of traffic accidents.

Benefits of technology

It realizes the full reflection of the risk impact of traffic flow status in different spatial ranges, can predict the possibility of traffic accidents in real time, provide early warning, and improve the level of traffic safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118675320A
    Figure CN118675320A
Patent Text Reader

Abstract

The invention discloses an urban expressway traffic accident occurrence probability prediction method, device and product, and relates to the technical field of safe driving. The method comprises the following steps: performing validity detection and missing data estimation on each piece of traffic flow information to obtain first feature data; determining second feature data according to the accident record set and the GPS track set; calculating third and fourth feature data according to the second feature data; obtaining a fusion average speed based on the third and fourth feature data; inputting the fusion average speed and the four feature data into a prediction model to obtain a traffic accident occurrence probability; processing the traffic accident occurrence probability and the four feature data to obtain a training set; and training and optimizing the prediction model by adopting the training set to obtain an optimized model, and predicting by adopting the optimized model. The method can fully reflect the influence of the traffic flow states in different spatial ranges on the accident occurrence risk, predicts the possibility of the accident occurrence in real time, and gives an early warning for the occurrence of the accident.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of safe driving technology, and in particular to a method, device and product for predicting the probability of traffic accidents on urban expressways. Background Art

[0002] Most of the existing prediction methods for the probability of traffic accidents on urban expressways are macro-prediction studies of traffic accidents. Based on cross-sectional microwave detector data and historical data, traffic accident risk prediction models are constructed to describe the relationship between factors such as traffic flow characteristics, vehicle characteristics, driver characteristics, road environment, and the probability of road traffic accidents, so as to identify road accident black spots and improve the level of road traffic safety. In essence, traditional traffic accident prediction is not to predict whether a traffic accident will occur or not, but to estimate the long-term average accident frequency on a given road. Its disadvantage is that it cannot fully reflect the impact of traffic flow states in different spatial ranges on the risk of accidents, and it is also impossible to predict the possibility of accidents in real time, and it is impossible to give early warning of the occurrence of accidents. Summary of the invention

[0003] The purpose of the present invention is to provide a method, device and product for predicting the probability of traffic accidents on urban expressways, which can fully reflect the impact of traffic flow conditions in different spatial ranges on the risk of accidents, predict the possibility of accidents in real time, and provide early warning of the occurrence of accidents.

[0004] To achieve the above object, the present invention provides the following solutions:

[0005] A method for predicting the probability of traffic accidents on urban expressways, comprising:

[0006] Collecting the traffic flow information of each lane of the target road at a preset collection frequency to obtain an information flow set;

[0007] Performing validity detection and missing data estimation on each vehicle flow information in the information flow set to obtain first feature data, wherein the first feature data includes valid vehicle flow information in the information flow set and vehicle flow information obtained by estimating valid vehicle flow information in the information flow set;

[0008] Collecting GPS track data of all taxis in operation in a target city within a set time period and accident records of all traffic accidents in the target city within the set time period to obtain a GPS track set and an accident record set; the target city is the city where the target road is located;

[0009] Determine the second characteristic data according to the accident record set and the GPS track set; the second characteristic data is the GPS track data of all taxis in operation traveling on the urban expressway within each target time period in the GPS track set; each target time period is the time period corresponding to each accident record in the accident record set;

[0010] Calculate the third characteristic data and the fourth characteristic data according to the second characteristic data; the third characteristic data includes the average speed of each taxi in operation on each road section on each viaduct in the second characteristic data; the fourth characteristic data includes the average speed of each road section on each viaduct;

[0011] Based on the third and fourth feature data, the fusion average speed is obtained by using DS evidence theory;

[0012] The fused average speed, the first feature data, the second feature data, the third feature data and the fourth feature data are input into a real-time urban expressway traffic accident risk prediction model to obtain a probability of a traffic accident;

[0013] BalancedBagging is used to process the probability of traffic accidents, the first feature data, the second feature data, the third feature data and the fourth feature data to obtain a training set;

[0014] The training set is used to train the urban expressway traffic accident risk prediction model and optimize the optimized model to obtain the optimized model, and the optimized model is used to predict the probability of urban expressway traffic accidents.

[0015] Optionally, performing validity detection and missing data estimation on each vehicle flow information in the information flow set to obtain first feature data specifically includes:

[0016] Performing validity detection on each vehicle flow information in the information flow set to obtain valid vehicle flow information;

[0017] Perform missing data estimation on valid traffic flow information to obtain estimated traffic flow information;

[0018] The valid traffic flow information and the estimated traffic flow information are determined as first feature data.

[0019] Optionally, the second feature data is determined according to the accident record set and the GPS track set, specifically including:

[0020] The target trajectory set is obtained by deleting the GPS trajectory data of the taxis in operation traveling on the urban road under the viaduct from the GPS trajectory set;

[0021] The GPS trajectory data of all operating taxis in the target trajectory set within each target time period are determined as the second feature data.

[0022] Optionally, calculating the third feature data and the fourth feature data according to the second feature data specifically includes:

[0023] Calculate the average speed of each taxi in operation on each road section on each viaduct in the second characteristic data according to the second characteristic data and the length of each road section on each viaduct;

[0024] The average speed of each road section on each viaduct is calculated based on the average speed of each operating taxi on each road section on each viaduct in the second characteristic data.

[0025] Optionally, the urban expressway traffic accident risk prediction model is trained and optimized using the training set to obtain an optimized model, specifically including:

[0026] The urban expressway traffic accident risk prediction model constructed by the GBDT algorithm is trained using the training set to obtain a trained urban expressway traffic accident risk prediction model;

[0027] The XGBoost algorithm is used to optimize the trained urban expressway traffic accident risk prediction model to obtain the optimized model.

[0028] Optionally, missing data estimation is performed on valid traffic flow information to obtain estimated traffic flow information, specifically including:

[0029] The random walk method is used to estimate the missing data of valid traffic flow information to obtain the estimated traffic flow information.

[0030] A computer device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the above-mentioned method for predicting the probability of traffic accidents on urban expressways.

[0031] A computer program product includes a computer program, which, when executed by a processor, implements the above-mentioned method for predicting the probability of traffic accidents on urban expressways.

[0032] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:

[0033] The present invention performs validity detection and missing data estimation on each vehicle flow information in the information flow set to obtain first feature data; determines second feature data according to an accident record set and a GPS track set; calculates third feature data and fourth feature data according to the second feature data; obtains a fused average speed using DS evidence theory based on the third feature data and the fourth feature data; inputs the fused average speed, the first feature data, the second feature data, the third feature data and the fourth feature data into a real-time urban expressway traffic accident risk prediction model to obtain the probability of a traffic accident; uses Balanced Bagging to process the probability of a traffic accident, the first feature data, the second feature data, the third feature data and the fourth feature data to obtain a training set; uses the training set to train and optimize the urban expressway traffic accident risk prediction model to obtain an optimized model, and uses the optimized model to predict the probability of an urban expressway traffic accident. The present invention fuses the third feature data and the fourth feature data, trains and optimizes the model based on the fused data, vehicle flow information and GPS track information, and can fully reflect the influence of traffic flow states in different spatial ranges on the risk of accidents, predicts the possibility of accidents in real time according to the optimized model, and makes early warnings for the occurrence of accidents. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0035] Figure 1 A schematic diagram of a method for predicting the probability of traffic accidents on urban expressways provided by an embodiment of the present invention;

[0036] Figure 2 A flowchart of a method for detecting the validity of data provided by an embodiment of the present invention;

[0037] Figure 3 A flowchart of a taxi GPS data deletion method provided by an embodiment of the present invention;

[0038] Figure 4 A flowchart of a method for selecting a non-accident group provided by an embodiment of the present invention;

[0039] Figure 5 This is the principle diagram of the BalancedBagging algorithm;

[0040] Figure 6 A schematic diagram of the DS evidence theory provided by an embodiment of the present invention;

[0041] Figure 7 It is a diagram of the internal structure of a computer device;

[0042] Figure 8 A flow chart of a method for predicting the probability of traffic accidents on urban expressways provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0043] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0044] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0045] The present invention provides a method for predicting the probability of traffic accidents on urban expressways to fill the gap in the current lack of in-depth research on real-time traffic accident prediction. Figure 8 As shown, the method for predicting the probability of traffic accidents on urban expressways includes:

[0046] Step 101: Collect the traffic flow information of each lane of the target road at a preset collection frequency to obtain an information flow set.

[0047] Step 102: Validity detection and missing data estimation are performed on each vehicle flow information in the information flow set to obtain first characteristic data. The first characteristic data includes valid vehicle flow information in the information flow set and vehicle flow information estimated from valid vehicle flow information in the information flow set (missing traffic flow data obtained from estimating valid vehicle flow information).

[0048] Step 103: Collect GPS trajectory data of all operating taxis in the target city within a set time period and accident records of all traffic accidents in the target city within a set time period to obtain a GPS trajectory set and an accident record set. The target city is the city where the target road is located. GPS trajectory data includes but is not limited to taxi license plate number, date, time, passenger status, longitude and latitude, speed and direction.

[0049] Step 104: Determine the second characteristic data according to the accident record set and the GPS track set. The second characteristic data is the GPS track data of all taxis in operation traveling on the urban expressway in each target time period in the GPS track set; each target time period is the time period corresponding to each accident record in the accident record set.

[0050] Step 105: Calculate third and fourth characteristic data based on the second characteristic data; the third characteristic data includes the average speed of each operating taxi in each section on each viaduct in the second characteristic data; the fourth characteristic data includes the average speed of each section on each viaduct.

[0051] Step 106: Obtain the fusion average speed using DS evidence theory based on the third feature data and the fourth feature data.

[0052] Step 107: Input the fused average speed, the first feature data, the second feature data, the third feature data and the fourth feature data into a real-time urban expressway traffic accident risk prediction model to obtain the probability of a traffic accident.

[0053] Step 108: Use BalancedBagging to process the traffic accident occurrence probability, the first feature data, the second feature data, the third feature data, and the fourth feature data to obtain a training set.

[0054] Step 109: Use the training set to train the urban expressway traffic accident risk prediction model and optimize it to obtain an optimized model, and use the optimized model to predict the probability of urban expressway traffic accidents.

[0055] In actual applications, the traffic flow information of each lane of the target road is collected at a preset collection frequency to obtain an information flow set, which specifically includes:

[0056] The traffic information of each lane of the target road is collected every 30 seconds using a side-mounted cross-section microwave detector. One lane corresponds to multiple side-mounted cross-section microwave detectors. The traffic information of one lane includes but is not limited to the equipment number, lane number, collection date, flow (the speed of all vehicles passing through the lane within 30 seconds), speed (the average speed of all vehicles passing through each microwave vehicle detector in the lane within 30 seconds), collection time and time occupancy rate (the ratio of the cumulative time of vehicles passing through all microwave vehicle detectors on the lane within 30 seconds to 30 seconds).

[0057] In practical applications, since the raw data collected by the cross-sectional microwave detector may contain some errors or missing fragments, it is necessary to perform validity detection before extracting real-time traffic flow features. The validity detection and missing data estimation of each vehicle flow information in the information flow set are performed to obtain the first feature data, which specifically includes:

[0058] Perform validity detection on each vehicle flow information in the information flow set to obtain valid vehicle flow information. Figure 2The data validity detection step shown performs validity detection on the data and stores the detected valid traffic flow data.

[0059] For data that has passed the validity test, if the collected data itself is missing, the missing traffic flow data needs to be estimated to ensure the integrity of the data.

[0060] In practical applications, since the traffic flow data corresponding to the time and space range of the extracted accidents are mostly discrete and missing, the random walk method is used to estimate the missing data of valid traffic flow information to obtain the estimated traffic flow information. The random walk formula is as follows:

[0061] X' t+1 =X t

[0062] Where X' t+1 is the estimated value of the parameter at time t+1 (specifically traffic flow, speed or time occupancy in the present invention); X t is the observed value of the parameter at time t, that is, the collected value.

[0063] In practical applications, the accident records of all traffic accidents in the target city within a set time period are collected to obtain a GPS trajectory set and an accident record set, specifically:

[0064] Obtain all accident records of the target city in the past year. Each accident record includes the date, time, location, driver information, accident information, and a brief description of the accident.

[0065] In practical applications, the second feature data is determined based on the accident record set and the GPS track set, specifically including:

[0066] The target trajectory set is obtained by deleting the GPS trajectory data of the taxis in operation that travel on the urban roads under the viaduct from the GPS trajectory set. For the taxi GPS data, since most urban expressways exist in the form of viaducts, it is necessary to remove the vehicles traveling on the urban roads under the viaduct when performing spatial aggregation on the taxi GPS in order to extract the real and effective taxis in operation that reflect the actual traffic flow information. Figure 3 The GPS data of taxis in operation are deleted to identify the taxis in operation traveling on the city expressway within the time range corresponding to each accident.

[0067] The GPS trajectory data of all operating taxis in the target trajectory set within each target time period are determined as the second characteristic data. The GPS trajectory data of operating taxis traveling on the urban expressway within the time range corresponding to each accident are determined as the second characteristic data.

[0068] In practical applications, since the taxi GPS trajectory data can only obtain the GPS position of the taxi and the instantaneous speed of the vehicle, only the traffic flow speed feature will be extracted based on the second feature data, and the third feature data and the fourth feature data will be calculated based on the second feature data, specifically including:

[0069] The average speed of each taxi in operation on each section of each viaduct within the second characteristic data is calculated based on the second characteristic data and the length of each section on each viaduct. The calculation formula is: Where n is the total number of GPS trajectory data of taxi p in operation on section k on a certain viaduct; V q represents the speed value of the qth GPS trajectory data of the operating taxi p, L is the length of the section k on a certain viaduct; V p The average speed of the operating taxi p on the road section k on a certain viaduct is represented as the third feature data.

[0070] The average speed of each section on each viaduct is calculated based on the average speed of each operating taxi on each section on each viaduct in the second characteristic data. The calculation formula is: Where M is the number of vehicles on section k on a certain viaduct; V k is the average speed of section k on a certain viaduct, which serves as the fourth feature data.

[0071] In practical applications, the fusion average speed is obtained based on the third feature data and the fourth feature data using the DS evidence theory, that is, the fusion of the average speed of the road section specifically includes:

[0072] DS evidence theory can establish an effective fusion model for heterogeneous sensor data. Its principle is as follows: Figure 6 shown. Figure 6 Part (a) represents a DS data fusion method: all data are fused together through DS data theory fusion, and finally the fused data is output. Figure 6 Part (b) shows another DS data fusion method: two sets of data are fused separately, and then the fused data is fused with another set of data until all the data are fused, and finally the fused data is output. The two methods have equivalent effects.

[0073] The specific steps are as follows:

[0074] Step 1: Based on the third and fourth feature data, establish the DS evidence theory knowledge recognition framework: F(t) = {v mircrove (t),v GPS (t)}, due to v mircrove (t) and v GPS (t) are from the fourth feature data and the third feature data respectively, vmircrove (t) represents the average speed of a certain road section based on the section microwave detector data during the period t, i.e., the average speed of the taxis in operation on the viaduct section; v GPS (t) represents the average speed of a certain section of road based on the GPS trajectory data of taxis during period t, that is, the average speed of the section on the viaduct. The two can be considered mutually exclusive, so the power set of all elements in F(t) is: 2 F(t) ={φ,X1(t),X2(t),X3(t)}, where X1(t) = v mircrove , indicating the average speed of a section of the viaduct under the fourth characteristic data; X2(t) = v GPS , represents the average speed of taxis in operation on a certain section of the viaduct under the decision of the third feature data; X3(t) = v mircrove (t)∩v GPS (t) is an uncertain decision, which means it cannot be determined whether it is X1(t) or X2(t).

[0075] Step 2: Determine the basic trust allocation for different decisions under the two types of data sources:

[0076] The basic trust function allocation is a quantitative standard for the degree of support for a decision and also serves as evidence for each decision.

[0077] Let m:2 F(t) ——→[0,1], m is called the basic trust allocation value, which satisfies the following conditions:

[0078]

[0079] Where i represents the evidence provided by the i-th data source, j represents the j-th decision; m i (X j (t)) represents the evidence provided by the i-th data source for X j The support level of (t) is called decision X j (t) basic distribution value; P i (X j (t)) is the X of the ith data source j (t) basic probability distribution function; m i (φ) represents decision The basic distribution value of X j (t) represents the three decisions in step one.

[0080] Assume P i (X j (t))Satisfy where u i (t) and They represent the mean and variance of the average speed of the road section in the t period under the historical data of the i-th data source.i (t) represents the average speed of the road section under the historical data of the i-th data source in time period t; P i (X1(t)) represents the basic probability distribution function of X1(t) under the i-th data source; P i (X2(t)) represents the basic probability distribution function of X1(t) under the i-th data source; P i (X3(t)) represents the basic probability distribution function of X1(t) under the i-th data source.

[0081] P i (X j (t)) The specific calculation method is as follows:

[0082]

[0083] Step 3: Demspster evidence synthesis based on the third feature data and the fourth feature data is used to synthesize the two data sources:

[0084]

[0085] Where K represents the conflict between the evidence provided by the two types of data sources, m1(B) represents the basic probability distribution function under the third characteristic data, and m2(C) represents the basic probability distribution function under the fourth characteristic data. The closer it is to 0, the greater the conflict in evidence provided by different data sources; A represents the above uncertain decision, B represents the above decision is the average speed of a certain section of road under the third characteristic data, and C represents the above decision is the average speed of a certain section of road under the fourth characteristic data.

[0086] Step 4: Determine the weights of the two types of data sources based on the speed weight calculation formula:

[0087] The weight calculation formula of the average speed in period t based on the third characteristic data is:

[0088]

[0089] The weight calculation formula of the average speed in the t period based on the fourth characteristic data is:

[0090] ω GPS =1-α(t)

[0091] Finally, substituting the above formula into the average speed of the t period after integrating the two types of data sources can be obtained:

[0092] v(t)=ω mircrove *v mircrove (t)+ω GPS *v GPS (t)

[0093] Wherein, m(X1(t)) represents the basic distribution value of the fourth feature data source, m(X2(t)) represents the basic distribution value under the third feature data, ω mircrove is the weight of the third feature data α(t); ω GPS is the weight 1-α(t) of the fourth feature data.

[0094] Because the traffic flow conditions before an accident are closely related to the risk of an accident, they are called pre-accident conditions. Traffic conditions without accidents under certain conditions are defined as normal traffic flow conditions. In order to determine the changes in traffic flow conditions between traffic accidents and normal conditions, a control group (i.e., data under normal traffic conditions) needs to be established for comparison with the accident group data. Figure 4 The non-accident group selection steps shown are used to clarify the data of the control group. Because the occurrence of traffic accidents is a low-probability event, the experimental data of the control group is significantly more than that of the accident group. Therefore, the creation of a real-time urban expressway traffic accident risk prediction model is an unbalanced data classification problem, that is, the number of majority class samples is much larger than the number of minority class samples. In the past, the creation of traffic accident prediction models for the problem of unbalanced data classification mostly adopted the "case-control" method, that is, data under the state of traffic accidents were selected as cases, and the corresponding data under non-accident states were used as controls. After that, most studies used a 1:4 ratio of case group and control group data to create models based on empirical methods. However, selecting a 1:4 ratio based on empirical methods will result in a large amount of control group data being unable to be included in the model, which may affect the prediction performance of the model. Therefore, the present invention will use the BalancedBagging integrated sampling method as a method for processing unbalanced sample sets. BalancedBagging is used to process the probability of traffic accidents, the first feature data, the second feature data, the third feature data and the fourth feature data to obtain a training set. The principle of the Balanced Bagging algorithm is as follows Figure 5 As shown, the set consisting of the control group data and the experimental group data is directly divided into subsets that include both the control group data and the experimental group data, and the control group data and the experimental group data are resampled on different subsets. The traffic accident probability prediction model is classified to generate multiple classifiers, and then the weighted combination of all classifier results can give the final training set.

[0095] In practical applications, the training set is used to train and optimize the urban expressway traffic accident risk prediction model to obtain the optimized model, which specifically includes:

[0096] The training set is used to train the urban expressway traffic accident risk prediction model constructed by the GBDT algorithm to obtain a trained urban expressway traffic accident risk prediction model.

[0097] The XGBoost algorithm is used to optimize the trained urban expressway traffic accident risk prediction model to obtain the optimized model.

[0098] In practical applications, the training set is used to train the urban expressway traffic accident risk prediction model constructed by the GBDT algorithm. The specific steps to obtain the trained urban expressway traffic accident risk prediction model are as follows:

[0099] Step 1: Establish the initial accident risk prediction objective function y0':

[0100]

[0101] y i represents the probability of traffic accident occurrence corresponding to the i-th group of samples in the training set. A group of samples includes the probability of traffic accident occurrence, the first feature data, the second feature data, the third feature data and the fourth feature data corresponding to each other. c represents the predicted value obtained by inputting the first feature data, the second feature data, the third feature data and the fourth feature data corresponding to the i-th group of data into the accident risk prediction model. h it represents the decision tree model of the tth iteration, and N represents the total number of sample groups.

[0102] The loss function can be defined as:

[0103]

[0104] Where n represents the total number of samples included in the training set, y′ t represents the accident risk prediction objective function of the tth iteration.

[0105] The accident risk prediction model can be defined as:

[0106] c=β t h it

[0107] Among them, h it is the decision tree model after the tth iteration.

[0108] Step 2: Train the model for t=1 to T iterations:

[0109] 1) Calculate the residual value r of the accident risk classification (i = 1 to N) of each experimental group and the control group at the tth iteration it , y′ t-1 Represents the accident risk prediction objective function of the t-1th iteration:

[0110]

[0111] 2) Use the training set to build a decision tree model h it:

[0112]

[0113] 3) Calculate the weight β by minimizing the loss function t , and update the objective function y' t

[0114] β t =argmin β L(y i ,y′ t-1 +β t h it )

[0115] y′ t =y′ t-1 +β t (h it +r it y′ t-1 )

[0116]

[0117] 4) Update the number of iterations t, enter the next iteration, return to 1), and stop iterating when t=T to obtain the trained urban expressway traffic accident risk prediction model.

[0118] Step 3: Output the trained urban expressway traffic accident risk prediction model.

[0119] The model for predicting the risk of high-speed urban traffic accidents established according to the present invention has good application prospects. The present invention allows early warning of accident risks based on traffic flow parameters, and traffic management personnel can release relevant traffic information in a timely manner to take appropriate safety measures.

[0120] The present invention implements a cross-sectional microwave detector for detecting traffic flow data entering the full sample detection category, but it only allows the acquisition of the state of cross-sectional traffic flow, and does not allow the acquisition of traffic flow information for the entire road section. The GPS trajectory data of taxis can effectively overcome this shortcoming by continuously tracking the traffic information of the entire road section. Figure 1 As shown in the figure, the present invention proposes to integrate two data sources using the theoretical method of DS evidence to provide a database for predicting traffic accident risks. The Balanced Bagging resampling method is used to balance the accident and non-accident sample data, which better solves the unbalanced classification problem related to real-time accident prediction. Finally, the "black box model" of real-time accident risk prediction for urban highways is explained based on feature importance analysis and partial dependency graphs, and relevant analysis is performed.

[0121] According to the present invention, the traffic management department can give early warning of traffic accident risks, plan traffic police management in a timely manner, and more effectively improve the road safety level of the urban road system.

[0122] The present invention can effectively predict the urban road traffic accident rate, help traffic-related management departments to give early warning of traffic accident risks in a targeted manner, make timely traffic management dispatches, avoid the occurrence of traffic accidents, and effectively improve the traffic safety level of the urban road system.

[0123] For the creation of the model, the present invention is driven by an integrated machine learning algorithm XGBoost algorithm. The model created by the XGBoost algorithm can better fit the nonlinear relationship between real-time traffic flow characteristics and accident risks on urban highways, and has better interpretability.

[0124] In one embodiment, a computer device is also provided, including a memory and a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the method for predicting the probability of an urban expressway traffic accident described in the above method embodiments is implemented. The computer device may be a database, and its internal structure diagram may be as shown in FIG. Figure 7 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store pending transactions. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a data processing method is implemented.

[0125] In one embodiment, a computer program product is provided, including a computer program, which, when executed by a processor, implements the method for predicting the probability of traffic accidents on urban expressways described in the above-mentioned method embodiments.

[0126] It should be noted that the object information (including but not limited to object device information, object personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the object or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards.

[0127] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0128] The principles and implementation methods of the present invention are described in this article using specific examples. The description of the above embodiments is only used to help understand the method and core idea of ​​the present invention. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present invention.

Claims

1. A method for predicting the probability of traffic accidents on urban expressways, characterized in that: include: Collecting the traffic flow information of each lane of the target road at a preset collection frequency to obtain an information flow set; Performing validity detection and missing data estimation on each vehicle flow information in the information flow set to obtain first feature data, wherein the first feature data includes valid vehicle flow information in the information flow set and vehicle flow information obtained by estimating valid vehicle flow information in the information flow set; Collecting GPS track data of all taxis in operation in a target city within a set time period and accident records of all traffic accidents in the target city within the set time period to obtain a GPS track set and an accident record set; the target city is the city where the target road is located; Determine the second characteristic data according to the accident record set and the GPS track set; the second characteristic data is the GPS track data of all taxis in operation traveling on the urban expressway within each target time period in the GPS track set; each target time period is the time period corresponding to each accident record in the accident record set; Calculate the third characteristic data and the fourth characteristic data according to the second characteristic data; the third characteristic data includes the average speed of each operating taxi in each section on each viaduct in the second characteristic data; the fourth characteristic data includes the average speed of each section on each viaduct; Based on the third and fourth feature data, the fusion average speed is obtained by using DS evidence theory; The fused average speed, the first feature data, the second feature data, the third feature data and the fourth feature data are input into a real-time urban expressway traffic accident risk prediction model to obtain a probability of a traffic accident; BalancedBagging is used to process the probability of traffic accidents, the first feature data, the second feature data, the third feature data and the fourth feature data to obtain a training set; The training set is used to train the urban expressway traffic accident risk prediction model and optimize the optimized model to obtain the optimized model, and the optimized model is used to predict the probability of urban expressway traffic accidents.

2. The method for predicting the probability of traffic accidents on urban expressways according to claim 1, characterized in that: Performing validity detection and missing data estimation on each vehicle flow information in the information flow set to obtain first feature data specifically includes: Performing validity detection on each vehicle flow information in the information flow set to obtain valid vehicle flow information; Perform missing data estimation on valid traffic flow information to obtain estimated traffic flow information; The valid traffic flow information and the estimated traffic flow information are determined as first feature data.

3. The method for predicting the probability of traffic accidents on urban expressways according to claim 1, characterized in that: The second feature data is determined according to the accident record set and the GPS track set, specifically including: The target trajectory set is obtained by deleting the GPS trajectory data of the taxis in operation traveling on the urban road under the viaduct from the GPS trajectory set; The GPS trajectory data of all operating taxis in the target trajectory set within each target time period are determined as the second feature data.

4. The method for predicting the probability of traffic accidents on urban expressways according to claim 1, characterized in that: Calculating the third feature data and the fourth feature data according to the second feature data specifically includes: Calculate the average speed of each taxi in operation on each road section on each viaduct in the second characteristic data according to the second characteristic data and the length of each road section on each viaduct; The average speed of each road section on each viaduct is calculated based on the average speed of each operating taxi on each road section on each viaduct in the second characteristic data.

5. The method for predicting the probability of traffic accidents on urban expressways according to claim 1, characterized in that: The training set is used to train and optimize the urban expressway traffic accident risk prediction model to obtain the optimized model, which specifically includes: The urban expressway traffic accident risk prediction model constructed by the GBDT algorithm is trained using the training set to obtain a trained urban expressway traffic accident risk prediction model; The XGBoost algorithm is used to optimize the trained urban expressway traffic accident risk prediction model to obtain the optimized model.

6. The method for predicting the probability of traffic accidents on urban expressways according to claim 2, characterized in that: The missing data of valid traffic flow information is estimated to obtain the estimated traffic flow information, including: The random walk method is used to estimate the missing data of valid traffic flow information to obtain the estimated traffic flow information.

7. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method for predicting the probability of occurrence of traffic accidents on urban expressways as described in any one of claims 1-6.

8. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method for predicting the probability of a traffic accident on an urban expressway as described in any one of claims 1 to 6 is implemented.