Traffic abnormal event detection method based on velocity entropy

Through the detection method based on velocity entropy and the boundary of the encoding rule is blurred in combination with the Parzen window method, the existing traffic anomaly event detection methods are solved, and more efficient and accurate traffic anomaly event detection methods are achieved.

CN120088977APending Publication Date: 2025-06-03SOUTHEAST UNIV

Patent Information

Application Number
CN202510115526.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-24
Publication Date
2025-06-03

AI Technical Summary

Technical Problem

The existing traffic anomaly event detection methods have slow response speed and insufficient detection accuracy, making it difficult to quickly and accurately capture abnormal changes in traffic flow.

Method used

Using a detection method based on velocity entropy, the first velocity entropy and the second velocity entropy reflecting the disordered degree of velocity distribution are used, and the encoding rule boundaries are blurred in combination with the Parzen window method to improve the real-time and accuracy of the detection.

Benefits of technology

It significantly improves the real-time and accuracy of traffic abnormal events detection, especially in complex traffic scenarios, which can keenly capture the changing characteristics of traffic abnormal events.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120088977A_ABST
    Figure CN120088977A_ABST
Patent Text Reader

Abstract

The invention discloses a traffic abnormal event detection method based on velocity entropy, and belongs to the technical field of traffic monitoring and intelligent traffic, and the method comprises the steps: collecting road video and vehicle track data through a traffic monitoring camera, a vehicle GPS and an induction coil device, and extracting high-frequency velocity time sequence data; calculating a speed entropy reflecting the disorder degree of the traffic flow by adopting a discrete coding rule of speed distribution so as to quantify the dynamic change characteristic of the traffic flow; fuzzy processing is carried out on an event boundary in combination with a Parzen window method, so that the precision and robustness of speed entropy calculation are further improved; and finally, traffic abnormal events are detected and classified based on the improved velocity entropy and trajectory features. According to the method, the disorder degree of the traffic flow is dynamically quantified, the traffic abnormal events are accurately recognized, the real-time performance and accuracy of detection can be remarkably improved, the problem that an existing detection technology is inaccurate in understanding of the traffic system abnormal events is solved, and reliable abnormal event detection technical support is provided for a traffic management department.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of traffic monitoring and intelligent transportation, and particularly to a traffic anomaly event detection method based on speed entropy. Background Art

[0002] With the rapid development of urbanization and the continuous increase in the number of motor vehicles, the complexity and dynamics of urban traffic systems have increased significantly. Traffic anomaly events (such as traffic accidents, road blockages, sudden congestions, etc.) pose a major threat to the normal operation of traffic flows, which may lead to economic losses, environmental pollution, and potential traffic safety hazards. Therefore, how to quickly and accurately detect traffic anomaly events has become a technical problem that urgently needs to be solved in the current traffic management field.

[0003] Currently, common traffic anomaly event detection methods have problems such as slow response speed and insufficient detection accuracy. Especially in the initial stage of anomaly events, when there are local chaos or disorder phenomena in traffic flows, existing methods are difficult to quickly and accurately capture these features. Summary of the Invention

[0004] The purpose of the present invention is to overcome the deficiencies in the prior art and provide a traffic anomaly event detection method based on speed entropy. By introducing the speed entropy, an information - theory - based index, it can dynamically quantify the degree of disorder in the speed distribution of traffic flows, thereby sensitively capturing abnormal changes in traffic flows and improving the real - time performance and accuracy of traffic anomaly detection.

[0005] To achieve the above purpose, the present invention provides the following technical solutions:

[0006] In the first aspect, the present invention provides a traffic anomaly event detection method based on speed entropy, including the following steps:

[0007] S1. Collect road video data through roadside cameras, and obtain vehicle speed, position, and traffic flow information in combination with devices such as vehicle GPS and induction coils.

[0008] S2. Apply object detection and algorithms to the video data to extract vehicle trajectories and speed sequences. Denoise and standardize the extracted data, and use the Gaussian filtering algorithm to smooth the speed time series to obtain continuous data with a frequency above 20 hz, providing a data basis for speed entropy calculation;

[0009] S3. Based on the section vehicle speed time series generated in step S2, calculate the first speed entropy reflecting the degree of disorder in speed distribution:

[0010]

[0011] where, H(V x ,V y) is the first speed entropy, V is the set of speed vectors of all vehicles, V x is the set of lateral speed vectors of all vehicles, V y is the set of longitudinal speed vectors of all vehicles, (v x , v y ) represents the speed vector element in the set V, v x is the lateral speed component of the vehicle, v y is the longitudinal speed component of the vehicle, p(v x , v y ) is the probability distribution of the speed vector;

[0012] The fixed interval division method is used to discretize the speed values in the first speed entropy to obtain a discretized code. The speed range is divided into multiple discrete intervals, each interval corresponding to a specific speed vector range, and the speed values within each interval are encoded. Further, the second speed entropy is calculated in the form of Shannon entropy, and its calculation formula is as follows:

[0013]

[0014] In the formula, is the speed vector in the second speed entropy, D is the state space of the speed vector , and D is a closed set, s r is a subset of the closed set D;

[0015] S4. Based on the Parzen window method, the boundary of the coding rule is blurred, and the relative position of the speed vector in the second speed entropy is weighted by the Gaussian kernel function to eliminate the boundary effect of event division and improve the effectiveness of the second speed entropy.

[0016] S5. Based on the output of the second speed entropy obtained in steps S3 and S4, traffic anomaly event detection and classification are performed. According to historical data, the normal range [H min , H max and the anomaly threshold H threshold,i of the second speed entropy are set. When the value of the second speed entropy in a certain time window meets the following conditions, it is determined as a traffic anomaly event:

[0017] H(v)>H threshold

[0018] According to the cumulative time T duration of the second speed entropy exceeding the anomaly threshold, the type of the anomaly event is judged. When the cumulative time is less than 1 minute, the anomaly event is a local abnormal driving behavior. When the cumulative time is between 1 and 10 minutes, the type of the anomaly event is a local conflict. When the cumulative time is more than 10 minutes, the anomaly is a traffic flow state phase transition.

[0019] In the step S3, the specific velocity entropy in the traffic flow, that is, the second velocity entropy, is calculated by dividing the subset s of the closed set D r as follows:

[0020]

[0021] In the formula, is the velocity vector in the second velocity entropy, D is the state space of the velocity vector and D is a closed set, s r is a subset of the closed set D;

[0022] Among them, s r (r = 1, 2,..., N) satisfies the following rules:

[0023] When r ≠ q,

[0024] In the formula, U represents the union operation of sets, represents the union of the sets s r from r = 1 to N, which is equal to the set D, and D is a closed set; when r ≠ q, represents any two different sets s r and s q that are disjoint from each other.

[0025] In actual calculation, each subset s i is divided by a rectangular region, and the probability value is estimated by frequency. The discretized calculation formula of the second velocity entropy is as follows:

[0026]

[0027] N jk (V) represents the number of velocity vectors in the set s jk , and m represents the total number of velocity vectors. The set s jk is defined as:

[0028]

[0029] Among them, Δ x and Δ y represent the interval lengths of the lateral velocity and the longitudinal velocity respectively, and j and k are the indices of the lateral and longitudinal velocity intervals. The coding rules can be dynamically adjusted according to the road type and traffic flow characteristics. For example, in urban roads, the lateral velocity interval coding can be set as [0, 2], [2, 4],..., [18, 20] m / s, while in highways, the lateral velocity interval coding can be set as [0, 5], [5, 10],... [25, 30] m / s.

[0030] Further, in step S4, the Parzen window method is used to blur the coding rule boundary, and the operation steps are as follows:

[0031] Step S4.1: Weight the relative position of the velocity vector and the event center to calculate the weighted frequency N′ jk (V). The formula is as follows:

[0032]

[0033] where is the event center point; represents the kernel function for weighted calculation; the function adopts a Gaussian kernel, and its definition is as follows:

[0034]

[0035] where h x , h y represent the bandwidth parameters of the horizontal and vertical velocity components. The bandwidth parameters h x and h y can be dynamically adjusted according to the speed distribution in the actual traffic scenario to optimize the adaptability and accuracy of the second speed entropy calculation.

[0036] Step S4.2: Use the weighted frequency N′ jk (V) to calculate the blurred second speed entropy, and the formula is as follows:

[0037]

[0038] where: H(V) is the second speed entropy; N represents the total number of velocity vectors; N′ jk (V) is the weighted frequency of event s jk .

[0039] Second, the present invention provides a traffic anomaly event detection system, including a data acquisition module, a data processing module, a speed entropy calculation module, a boundary blurring processing module, and an event detection and classification module, where:

[0040] The data acquisition module is used to collect traffic flow data, including collecting road video data through roadside cameras, and combining vehicle GPS and induction coil devices to obtain vehicle speed, position, and traffic flow information;

[0041] The data processing module is used to extract the vehicle trajectory and speed sequence, denoise and normalize the extracted data, and smooth the speed time series using the Gaussian filtering algorithm to obtain continuous data with a frequency above 20Hz;

[0042] The speed entropy calculation module is used to calculate the first speed entropy reflecting the degree of disorder of the speed distribution based on the data of the speed time series obtained in step S2, and discretize the speed values in the first speed entropy using the fixed interval division method to obtain the discretized coding, and calculate the second speed entropy in the form of Shannon entropy;

[0043] The boundary blurring processing module is used to blur the boundary of the coding rule based on the Parzen window method, and weight the relative positions of the speed vectors in the second speed entropy through the Gaussian kernel function to eliminate the boundary effect of event division;

[0044] The event detection and classification module is used to detect and classify traffic abnormal events according to the normal range and abnormal threshold of the second speed entropy, and the cumulative time when the second speed entropy exceeds the abnormal threshold.

[0045] In a third aspect, the present invention provides an electronic terminal, including a processor and a storage medium;

[0046] The storage medium is used to store instructions;

[0047] The processor is used to operate according to the instructions to execute the steps of the method according to any one of claims 1 to 5.

[0048] In a fourth aspect, the present invention provides a computer-readable storage medium, on which a computer program is stored, characterized in that when the program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.

[0049] Compared with the prior art, the beneficial effects achieved by the present invention:

[0050] (1) By introducing the speed entropy, an information theory-based index, the present invention can dynamically quantify the degree of disorder of the traffic flow speed distribution, thereby keenly capturing the change characteristics of traffic abnormal events. Compared with the traditional detection methods based on speed or density changes, the present invention has significant improvements in both real-time performance and accuracy, especially stronger adaptability in complex traffic scenarios.

[0051] (2) The present invention uses an improved Parzen window method to blur the coding boundary of the speed vector, eliminating the limitation of the traditional strict event division method being sensitive to unit event parameters. This improvement significantly improves the robustness and stability of speed entropy calculation, especially outstanding in dealing with boundary events and small sample data.

[0052] (3) The detection method of the present invention does not rely on complex machine learning models or large-scale labeled data. Instead, it realizes the accurate detection of traffic abnormal events through statistical methods and information theory models, greatly reducing the computational cost and data annotation pressure in practical applications, and providing an efficient and reliable solution for intelligent transportation systems. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] The drawings forming a part of the specification depict embodiments of the present invention and, together with the specification, are used to explain the principles of the present invention;

[0054] With reference to the drawings, the present invention can be more clearly understood from the following detailed description, where:

[0055] Figure 1 is a flowchart of the traffic abnormal event detection method based on speed entropy provided by the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0056] The technical solution of the present invention will be described in detail below with reference to the drawings and specific embodiments. It should be understood that the specific features in the embodiments of the present application and the embodiments are detailed descriptions of the technical solution of the present application, rather than limitations on the technical solution of the present application. Without conflict, the technical features in the embodiments of the present application and the embodiments can be combined with each other; the following embodiments are only used to more clearly illustrate the technical solution of the present invention and cannot be used to limit the protection scope of the present invention;

[0057] The term "and / or" in this article is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B may represent: A exists alone, A and B exist simultaneously, and B exists alone; in addition, the character " / " in this article generally represents an "or" relationship between the front and rear associated objects;

[0058] Embodiment 1

[0059] Figure 1 is a flowchart of a traffic abnormal event detection method based on speed entropy in Embodiment 1 of the present invention; this flowchart only shows the logical order of the method described in this embodiment. On the premise of non-conflict, in other possible embodiments of the present invention, the steps shown or described may be completed in a different order from Figure 1 that shown.

[0060] This embodiment is a typical implementation manner of the present invention, providing a traffic abnormal event detection method based on speed entropy. This method can be applied to a terminal and can be executed by an electronic terminal. The electronic terminal can be implemented in a software and / or hardware manner and can be integrated in the terminal. For example: any smart phone, tablet computer or computer device with a communication function; asFigure 1 As shown in Figure 1 , the method of this embodiment specifically includes the following steps:

[0061] S1. Collect traffic flow data, including collecting road video data, vehicle speed, position, and traffic flow information;

[0062] S2. Extract the data of vehicle trajectories and speed sequences from the road video data, perform denoising and normalization processing on the extracted data, and smooth it using the Gaussian filtering algorithm to obtain the speed time series, obtaining data of the speed time series with a frequency above 20 Hz and continuous, providing a data basis for speed entropy calculation;

[0063] S3. Based on the data of the speed time series obtained in step S2, calculate the first speed entropy reflecting the degree of disorder of the speed distribution, and discretize the speed values in the first speed entropy using the fixed interval partitioning method to obtain the second speed entropy in the form of Shannon entropy;

[0064] S4. Fuzzify the regular boundaries of the discretized encoding obtained in step S3 based on the Parzen window method, and weight the relative positions of the speed vectors in the second speed entropy through the Gaussian kernel function to eliminate the boundary effect of event partitioning, so as to improve the effectiveness of the second speed entropy;

[0065] S5. Detect and classify traffic abnormal events according to the normal range and abnormal threshold of the second speed entropy, and the cumulative time when the second speed entropy exceeds the abnormal threshold.

[0066] Preferably, the road video data is collected by roadside cameras, and the vehicle speed, position, and traffic flow information are obtained through vehicle GPS and induction coil devices.

[0067] Further, step S2 specifically includes:

[0068] Trajectory extraction: Use the YOLO object detection method, combine with the Hungarian algorithm for multi-object tracking, apply object detection and tracking algorithms to the collected roadside video data, extract vehicle trajectories, generate trajectory data including the speed, time, and spatial position information of each vehicle, and set the collection frequency to 50 Hz;

[0069] Data preprocessing: Perform denoising and normalization processing on the vehicle speed time series, and smooth the speed data using the Gaussian filtering algorithm to generate a smoothed speed time series.

[0070] Specifically, in step S3, the calculation formula of the first speed entropy is:

[0071]

[0072] where, H(V x ,V y) is the first speed entropy, V is the set of speed vectors of all vehicles, V x is the set of lateral speed vectors of all vehicles, V y is the set of longitudinal speed vectors of all vehicles, (v x , v y ) represents the speed vector element in the set V, v x is the lateral speed component of the vehicle, v y is the longitudinal speed component of the vehicle, p(v x , v y ) is the probability distribution of the speed vector.

[0073] Furthermore, in step S3, the second speed entropy is calculated by partitioning the subset s r of the closed set D, and the calculation formula is as follows:

[0074]

[0075] In the formula, is the speed vector in the second speed entropy, D is the state space of the speed vector , and D is a closed set, s r is a subset of the closed set D;

[0076] Among them, s r (r = 1, 2,..., N) satisfies the following rules:

[0077] When r ≠ q,

[0078] In the calculation, a rectangular region is used to partition each subset s i , and the probability value is estimated by frequency. The discretized calculation formula of the second speed entropy is as follows:

[0079]

[0080] N jk (V) represents the number of speed vectors in the set s jk , m represents the total number of speed vectors; the set s jk is defined as:

[0081]

[0082] Among them, Δ x represents the length of the partitioning interval of the lateral speed, Δ y represents the length of the partitioning interval of the longitudinal speed, j is the index of the lateral speed interval, and k is the index of the longitudinal speed interval.

[0083] Specifically, in step S4, the Parzen window method is used to blur the coding rule boundary, and the operation steps are as follows:

[0084] Step S4.1: Weight the relative position of the velocity vector and the event center to calculate the weighted frequency N′ jk (V), and its formula is as follows:

[0085]

[0086] where is the event center point; represents the kernel function for weighted calculation; the function adopts a Gaussian kernel, and its definition is as follows:

[0087]

[0088] where h x ,h y represent the bandwidth parameters of the horizontal and vertical velocity components; the bandwidth parameters h x and h y are dynamically adjusted according to the velocity distribution in the actual traffic scenario to optimize the adaptability and accuracy of the second velocity entropy calculation;

[0089] Step S4.2: Use the weighted frequency N′ jk (V) to calculate the blurred second velocity entropy, and the formula is as follows:

[0090]

[0091] where: H(V) represents the second velocity entropy; N is the total number of velocity vectors in the second velocity entropy. The number of velocity vectors in the first velocity entropy and the second velocity entropy is the same, both being the number of vehicles on the corresponding road section; N′ jk (V) represents the weighted frequency of event s jk .

[0092] Furthermore, S5 specifically includes:

[0093] Set the normal range [H min ,H max and the abnormal threshold H threshold,i of the second velocity entropy according to historical data. When the value of the second velocity entropy within a certain time window meets the following conditions, it is determined as a traffic abnormal event:

[0094] H(v)>H threshold

[0095] According to the cumulative time T when the second velocity entropy exceeds the abnormal thresholdduration Determine the type of abnormal event. When the cumulative time is less than 1 minute, the abnormal event is a local abnormal driving behavior. When the cumulative time is between 1 and 10 minutes, the type of abnormal event is a local conflict. When the cumulative time is more than 10 minutes, the abnormality is a traffic flow state phase transition.

[0096] Embodiment 2

[0097] In one embodiment, a traffic abnormal event detection method based on speed entropy is provided. As Figure 1 shown, the content includes traffic flow data collection, traffic flow data processing, road segment speed entropy calculation, Parzen window-based speed entropy fuzzification processing, and traffic abnormal event detection:

[0098] S1. Traffic flow data collection:

[0099] Collect real-time traffic flow data, including vehicle speed, position, and flow information, through traffic monitoring cameras, ground induction coils, and vehicle GPS devices deployed on the roadside.

[0100] S2. Traffic flow data processing:

[0101] Extract the vehicle trajectory and speed sequence data from the road video data, denoise and standardize the extracted data, and smooth it using the Gaussian filtering algorithm to obtain a speed time series. Obtain data of a speed time series with a frequency above 20 Hz and continuous, providing a data basis for speed entropy calculation.

[0102] S3. Road segment speed entropy calculation:

[0103] Based on the vehicle trajectory data generated in step S1, calculate the first speed entropy to quantify the disorder degree of the traffic flow. First, discretize the speed data according to a predefined speed interval to obtain a discretized code, and then calculate the second speed entropy in the form of Shannon entropy. The second speed entropy is the actual calculated value and can be applied in engineering.

[0104] S4. Parzen window-based speed entropy fuzzification processing:

[0105] Use the Parzen window method to fuzzify the rule boundaries of the discretized code of speed events to reduce the boundary effect problem in speed interval division, and weight the relative positions of the speed vectors in the second speed entropy through the Gaussian kernel function to eliminate the boundary effect of event division and improve the effectiveness of the second speed entropy.

[0106] S5. Traffic abnormal event detection:

[0107] Based on the calculation results of steps S3 and S4, through the dynamic change analysis of the second velocity entropy, traffic anomaly event detection is realized, and the type of anomaly event is identified when the entropy value reaches the boundary condition. Specifically, according to the normal range and anomaly threshold of the second velocity entropy, and the cumulative time when the second velocity entropy exceeds the anomaly threshold, traffic anomaly event detection and classification are carried out.

[0108] Furthermore, in step S2, data processing includes trajectory extraction and data preprocessing steps. Trajectory extraction uses object detection methods such as YOLO, combined with the Hungarian algorithm for multi-object tracking. Apply object detection and tracking algorithms to the collected roadside video data to extract vehicle trajectories, and generate trajectory data containing the speed, time, and spatial position information of each vehicle. The acquisition frequency is set to 50Hz. The data preprocessing step includes denoising and normalization processing of the vehicle speed time series. Use the Gaussian filtering algorithm to smooth the speed data and generate a smoothed speed time series.

[0109] Furthermore, in step S3, the calculation formula for the first velocity entropy is:

[0110]

[0111] where p(v x ,v y ) is the joint distribution probability, calculated from the ratio of the number of vehicles in the interval to the total number of vehicles. v x is the lateral component of the vehicle speed, and v y is the longitudinal component of the vehicle speed. In actual calculation, a rectangular region is used to divide each subset s i , and the probability value is estimated by frequency. The discretized calculation formula for the second velocity entropy is as follows:

[0112]

[0113] N jk (V) represents the number of speed vectors in the set s jk , and m represents the total number of speed vectors. The set s jk is defined as:

[0114]

[0115] where Δ x and Δ yrespectively represent the division interval lengths of the horizontal speed and the vertical speed, and j and k are the indexes of the horizontal and vertical speed intervals respectively. The encoding rule can be dynamically adjusted according to the road type and traffic flow characteristics. For example, in urban roads, the horizontal speed interval encoding can be set as [0, 2], [2, 4], …, [18, 20] m / s, while in highways, the horizontal speed interval encoding can be set as [0, 5], [5, 10], … [25, 30] m / s.

[0116] Further, in step S4, the Gaussian kernel function is adopted, and according to the relative position of the speed vector and the event center , the speed vector is weighted and calculated to get rid of the heterogeneity brought by the strict boundary encoding rule. The kernel function formula is:

[0117]

[0118] The formula for calculating the fuzzified weighted frequency is:

[0119]

[0120] where h x , h y represent the bandwidth parameters of the horizontal and vertical speed components, and (jΔ x , kΔ y ) is the event center point. The formula for calculating the second speed entropy obtained after fuzzification is:

[0121]

[0122] where N′ jk (V) is the fuzzified weighted frequency, N is the total number of speed vectors in the second speed entropy, that is, the total number of vehicles corresponding to the research section, and the number of speed vectors in the first speed entropy and the second speed entropy is the same, both being N.

[0123] Further, in step S5, the abnormal traffic event detection method includes the following operations:

[0124] S5.1. Set the normal second speed entropy range [H min , H max and the abnormal threshold H threshold ;

[0125] S5.2. Within the set time window, if the second speed entropy value H(V) exceeds the abnormal threshold H threshold , and the duration reaches the set abnormal threshold T duration , then it is determined as a traffic abnormal event.

[0126] S5.3. Discriminate the event type i according to the duration T:

[0127]

[0128] The above are only the preferred embodiments of the present invention. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present invention, several improvements and modifications can be made, and these improvements and modifications should also be regarded as the protection scope of the present invention.

[0129] Embodiment 3

[0130] The embodiment of the present invention also provides a traffic anomaly event detection system, which is characterized by including:

[0131] A data acquisition module for acquiring traffic flow data, including acquiring road video data through roadside cameras, and combining vehicle GPS and induction coil devices to obtain vehicle speed, position, and traffic flow information;

[0132] A data processing module for extracting vehicle trajectories and speed sequences, and performing denoising and normalization processing on the extracted data, using a Gaussian filtering algorithm to smooth the speed time series to obtain continuous data with a frequency above 20Hz;

[0133] A speed entropy calculation module for calculating a first speed entropy reflecting the degree of disorder of speed distribution based on the data of the speed time series obtained in step S2, and performing discretization calculation on the speed values in the first speed entropy using a fixed interval partitioning method to obtain a discretized code, and calculating a second speed entropy in the form of Shannon entropy;

[0134] A boundary fuzzy processing module for blurring the boundaries of the coding rules based on the Parzen window method, weighting the relative positions of the speed vectors in the second speed entropy through a Gaussian kernel function, and eliminating the boundary effect of event partitioning;

[0135] An event detection and classification module for detecting and classifying traffic anomaly events according to the normal range and anomaly threshold of the second speed entropy, and the cumulative time for which the second speed entropy exceeds the anomaly threshold.

[0136] The traffic anomaly event detection system provided by the embodiment of the present invention can execute the traffic anomaly event detection method based on speed entropy provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects for executing the method.

[0137] Embodiment 4

[0138] The embodiment of the present invention also provides an electronic terminal, including a processor and a storage medium; the storage medium is used for storing instructions; the processor is used for operating according to the instructions to execute the steps of the following method:

[0139] S1. Collect traffic flow data, including collecting road video data through roadside cameras, and combining vehicle GPS and induction coil devices to obtain vehicle speed, position, and traffic flow information;

[0140] S2. Extract the data of vehicle trajectories and speed sequences from the road video data, perform denoising and normalization processing on the extracted data, and use the Gaussian filtering algorithm to smooth it to obtain a speed time series, obtaining data of a continuous speed time series with a frequency above 20 Hz, providing a data basis for speed entropy calculation;

[0141] S3. Based on the data of the speed time series obtained in step S2, calculate the first speed entropy reflecting the degree of disorder of speed distribution, and use the fixed interval partitioning method to discretize the speed values in the first speed entropy to obtain a discretized code, obtaining the second speed entropy in the form of Shannon entropy;

[0142] S4. Fuzzify the regular boundaries of the discretized code based on the Parzen window method, and weight the relative positions of the speed vectors in the second speed entropy through the Gaussian kernel function to eliminate the boundary effect of event partitioning, so as to improve the effectiveness of the second speed entropy;

[0143] S5. Detect and classify traffic anomaly events according to the normal range and anomaly threshold of the second speed entropy, and the cumulative time when the second speed entropy exceeds the anomaly threshold.

[0144] The electronic terminal provided by the embodiment of the present invention can execute the traffic anomaly event detection method based on speed entropy provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects for executing the method.

[0145] Embodiment 5

[0146] The embodiment of the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the following method are implemented:

[0147] S1. Collect traffic flow data, including collecting road video data through roadside cameras, and combining vehicle GPS and induction coil devices to obtain vehicle speed, position, and traffic flow information;

[0148] S2. Extract the data of vehicle trajectories and speed sequences from the road video data, perform denoising and normalization processing on the extracted data, and use the Gaussian filtering algorithm to smooth it to obtain a speed time series, obtaining data of a continuous speed time series with a frequency above 20 Hz, providing a data basis for speed entropy calculation;

[0149] S3. Based on the data of the speed-time series obtained in step S2, calculate the first speed entropy reflecting the disorder degree of the speed distribution, and use the fixed interval partitioning method to discretize the speed values in the first speed entropy to obtain a discretized code, so as to obtain the second speed entropy in the form of Shannon entropy;

[0150] S4. Based on the Parzen window method, blur the regular boundary of the discretized code, and weight the relative positions of the speed vectors in the second speed entropy through the Gaussian kernel function to eliminate the boundary effect of event partitioning, so as to improve the effectiveness of the second speed entropy;

[0151] S5. According to the normal range and abnormal threshold of the second speed entropy, and the cumulative time when the second speed entropy exceeds the abnormal threshold, detect and classify traffic abnormal events.

[0152] A computer-readable storage medium provided by an embodiment of the present invention stores a computer program thereon, which can execute a traffic abnormal event detection method based on speed entropy provided by any embodiment of the present invention, and has functional modules and beneficial effects corresponding to the execution of the method.

[0153] The above are only the preferred embodiments of the present invention. It should be pointed out that for those of ordinary skill in the art, without departing from the technical principle of the present invention, several improvements and deformations can still be made, and these improvements and deformations should also be regarded as the protection scope of the present invention.

Claims

1. A method for detecting abnormal traffic events based on speed entropy, characterized in that: The following steps are involved: S1. Collecting traffic flow data, including collecting road video data, vehicle speed, location and flow information; S2, extracting vehicle trajectory and speed sequence data from the road video data, and processing the extracted data to obtain speed time series data with a frequency of more than 20 Hz and continuous, to provide a data basis for speed entropy calculation; S3, based on the data of the speed time series obtained in step S2, calculating a first speed entropy reflecting the disorder degree of speed distribution, and using a fixed interval division method to discretize the speed value in the first speed entropy to obtain a second speed entropy in the form of Shannon entropy; S4, fuzzifying the regular boundary of the discretized code obtained in step S3 based on the Parzen window method, and weighting the relative position of the velocity vector in the second velocity entropy by a Gaussian kernel function; S5. Detect and classify abnormal traffic events according to the normal range and abnormal threshold of the second speed entropy, and the accumulated time that the second speed entropy exceeds the abnormal threshold.

2. The method for detecting abnormal traffic events based on speed entropy according to claim 1, characterized in that: The road video data is collected by roadside cameras, and the vehicle speed, location and flow information are obtained by vehicle GPS and induction coil equipment.

3. The method for detecting abnormal traffic events based on speed entropy according to claim 1, characterized in that: Step S2 specifically includes: Trajectory extraction: YOLO target detection method is used in combination with the Hungarian algorithm for multi-target tracking. The target detection and tracking algorithm is applied to the collected roadside video data to extract vehicle trajectories and generate trajectory data including the speed, time and spatial position information of each vehicle. The acquisition frequency is set to 50Hz. Data preprocessing: De-noise and standardize the vehicle speed time series, use the Gaussian filter algorithm to smooth the speed data, and generate a smooth speed time series.

4. The method for detecting abnormal traffic events based on speed entropy according to claim 1, characterized in that: In step S3, the calculation formula of the first velocity entropy is: Among them, H(V x ,V y ) is the first speed entropy, V is the speed vector set of all vehicles, V x is the set of lateral velocity vectors of all vehicles, V y is the set of longitudinal velocity vectors of all vehicles, (v x ,v y ) is the velocity vector element in the traversal set V, v x is the lateral velocity component of the vehicle, v y is the longitudinal velocity component of the vehicle, p(v x ,v y ) is the probability distribution of the velocity vector.

5. The method for detecting abnormal traffic events based on speed entropy according to claim 4 is characterized in that: In step S3, the second velocity entropy is obtained by dividing the closed set D into subsets s r The calculation formula is as follows: In the formula, is the velocity vector in the second velocity entropy, D is the velocity vector The state space of , and D is a closed set, s r is a subset of the closed set D; Among them, s r (r=1,2,…,N) satisfies the following rules: When r≠q, In the formula, U represents the union operation of sets, Represents a set s r , the union of r from 1 to N is equal to set D, and D is a closed set; when r≠q, Denote any two different sets s r and q There is no intersection between them; Use a rectangular area for each subset s r Divide and estimate the probability value by frequency. The discretization calculation formula of the second velocity entropy is as follows: N jk (V) represents the set s jk The number of velocity vectors in the set s, m represents the total number of velocity vectors; jk Defined as: Among them, Δ x Indicates the length of the lateral velocity interval, Δ y Indicates the length of the longitudinal speed interval, j is the index of the lateral speed interval, and k is the index of the longitudinal speed interval.

6. The method for detecting abnormal traffic events based on speed entropy according to claim 5, characterized in that: In step S4, the Parzen window method is used to fuzzy the rule boundary of the discretized code, and the operation steps are as follows: Step S4.1: Use kernel function to transform velocity vector With Event Center The relative position is weighted and the weighted frequency N′ is calculated jk (V), the formula is as follows: in is the center point of the event; Represents the kernel function, which is used for weighted calculation; function A Gaussian kernel is used, which is defined as follows: in h x The bandwidth parameter of the transverse velocity component, h y represents the bandwidth parameter of the longitudinal velocity component; the bandwidth parameter h of the transverse velocity component x and the bandwidth parameter h of the longitudinal velocity component y Ability to adjust according to the speed distribution in actual traffic scenarios to optimize the calculation of the second speed entropy; Step S4.2: Using weighted frequency N′ jk (V) Calculate the second velocity entropy after fuzzification, the formula is as follows: Where: H(V) represents the second velocity entropy; N is the total number of velocity vectors in the second velocity entropy; N′ jk (V) represents event s jk The weighted frequency.

7. The method for detecting abnormal traffic events based on speed entropy according to claim 6, characterized in that: S5 specifically includes: Set the normal range of the second speed entropy based on historical data [H min ,H max ] and abnormal threshold H threshold,i , when the value of the second speed entropy within a certain time window meets the following conditions, it is determined to be a traffic abnormality event: H(v)>H threshold According to the cumulative time T of the second speed entropy exceeding the abnormal threshold duration Determine the type of abnormal event. When the cumulative time is less than 1 minute, the abnormal event is a local abnormal driving behavior. When the cumulative time is between 1 and 10 minutes, the abnormal event type is a local conflict. When the cumulative time is more than 10 minutes, the abnormality is a phase change in the traffic flow state.

8. A traffic abnormality event detection system, characterized in that: It includes data acquisition module, data processing module, speed entropy calculation module, boundary fuzzy processing module and event detection and classification module, among which: The data acquisition module is used to collect traffic flow data, including collecting road video data through roadside cameras, and obtaining vehicle speed, location and flow information in combination with vehicle GPS and induction coil equipment; The data processing module is used to extract vehicle trajectory and speed sequence, and perform denoising and standardization on the extracted data, and use Gaussian filtering algorithm to smooth the speed time series to obtain continuous data with a frequency above 20 Hz; The speed entropy calculation module is used to calculate the first speed entropy reflecting the disorder degree of speed distribution based on the speed time series data obtained in step S2, and to discretize the speed value in the first speed entropy by using a fixed interval division method to obtain a discretized code, and to calculate the second speed entropy in the form of Shannon entropy; The boundary fuzzification processing module is used to fuzzify the boundary of the coding rule based on the Parzen window method, and weight the relative position of the velocity vector in the second velocity entropy by a Gaussian kernel function to eliminate the boundary effect of event division; The event detection and classification module is used to detect and classify abnormal traffic events according to the normal range and abnormal threshold of the second speed entropy, and the accumulated time that the second speed entropy exceeds the abnormal threshold.

9. An electronic terminal, characterized in that: including processor and storage medium; The storage medium is used to store instructions; The processor is used to operate according to the instructions to execute the steps of the method according to any one of claims 1 to 6.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Expressway abnormal event type identification and position estimation method

    CN118840861A

  • Driving state determination device

    JP2015030365A

Cited By

  • Traffic incident detection system based on Leiyu fusion

    CN120954195A