A traffic data processing method and device based on improved Kalman filtering
By improving the Kalman filter technology and combining the traffic flow data of upstream intersections and target intersections for spatio-temporal prediction, the problem of low traffic flow prediction accuracy in the existing technology is solved, and more accurate traffic flow prediction and traffic light timing optimization are achieved. Relieved traffic congestion.
Patent Information
- Application Number
- CN202411540307.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-01-10
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art has low prediction accuracy in traffic flow prediction, which cannot meet the needs of traffic flow prediction, and thus cannot provide accurate data support for time distribution optimization of intersections.
A traffic data processing method based on improved Kalman filter is adopted. By obtaining the traffic flow at the upstream intersection and the historical traffic flow at the target intersection, the Kalman filter is used to predict the time and space of the traffic flow, and the traffic light timing is adjusted according to the prediction results.
It improves the prediction accuracy of the traffic flow at the target intersection, improves the quality of traffic light timing, and alleviates traffic congestion.
Smart Images

Figure CN119049306B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of intelligent transportation technology, and in particular to a method and device for processing traffic data based on improved Kalman filtering. Background Art
[0002] In recent years, with the rapid development of economic globalization, the scale of urban traffic has continued to expand, and the traffic volume at traffic intersections in various cities has increased significantly. Accurate traffic prediction models can provide accurate data support for management personnel, especially for the timing adjustment and optimization of intersections, thereby effectively improving overall operational efficiency and service levels.
[0003] Since traffic flow has the characteristics of nonlinearity, periodicity and randomness, the prediction method based on statistical models is to make predictions under the assumption of environmental and movement restrictions, and the statistical method usually adopts qualitative and quantitative predictions, that is, predictions are made through expert judgment, empirical analysis and reasoning summary. Therefore, the prediction accuracy of this method is low and cannot meet the needs of traffic flow prediction at this stage, and thus cannot provide accurate data support for the timing optimization of intersections. Summary of the invention
[0004] The following is a summary of the subject matter described in detail herein. This summary is not intended to limit the scope of the claims.
[0005] The present application aims to at least solve the technical problems existing in the prior art. To this end, the present application proposes a traffic data processing method and device based on improved Kalman filtering, which can improve the prediction accuracy of the target intersection, thereby improving the timing quality of the target intersection and alleviating traffic congestion at the intersection.
[0006] A first aspect of an embodiment of the present application provides a traffic data processing method based on an improved Kalman filter, the method comprising:
[0007] When the traffic light at the target intersection is of the first timing duration, obtaining the traffic volume of the upstream intersection corresponding to the target intersection and the historical traffic volume of the target intersection in multiple cycles;
[0008] According to Kalman filtering, based on the traffic volume of the upstream intersection and the historical traffic volume, predicting the predicted traffic volume of the target intersection within a period;
[0009] According to the predicted traffic flow, the traffic light at the target intersection is adjusted to a second timing duration, and when a traffic quality index of the second timing duration is better than that of the first timing duration, the second timing duration is used as the actual timing duration of the traffic light at the target intersection.
[0010] A second aspect of an embodiment of the present application provides a traffic data processing device based on an improved Kalman filter, the device comprising:
[0011] A first traffic flow calculation unit, used for obtaining the traffic flow of an upstream intersection corresponding to the target intersection and the historical traffic flow of the target intersection in multiple cycles when the traffic light at the target intersection is of the first timing duration;
[0012] A second vehicle flow calculation unit, configured to predict the predicted vehicle flow of the target intersection within a period based on the vehicle flow of the upstream intersection and the historical vehicle flow according to a Kalman filter;
[0013] A timing duration calculation unit is used to adjust the traffic light at the target intersection to a second timing duration according to the predicted traffic flow, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, use the second timing duration as the actual timing duration of the traffic light at the target intersection.
[0014] The electronic device provided in the third aspect of an embodiment of the present application includes at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute the traffic data processing method based on improved Kalman filtering.
[0015] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the traffic data processing method based on the improved Kalman filter.
[0016] The method provided in the embodiments of the present application has at least the following beneficial effects:
[0017] When the traffic light at the target intersection is of the first timing duration, obtain the traffic volume of the upstream intersection corresponding to the target intersection and the historical traffic volume of the target intersection within the cycle; predict the predicted traffic volume of the target intersection within the cycle based on the traffic volume of the upstream intersection and the historical traffic volume according to the Kalman filter; adjust the traffic light at the target intersection to the second timing duration according to the predicted traffic volume, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, use the second timing duration as the actual timing duration of the traffic light at the target intersection. This method not only takes into account the traffic volume of the upstream intersection of the target intersection, but also takes into account the historical traffic volume of the target intersection. Through the Kalman filter, the spatiotemporal prediction process of the traffic volume at the target intersection is realized, which improves the prediction accuracy of the traffic volume, thereby improving the quality of timing and alleviating traffic congestion.
[0018] It can be understood that the beneficial effects of the second to fourth aspects compared with the related art are the same as the beneficial effects of the first aspect compared with the related art. Please refer to the relevant description in the first aspect, and no further details will be given here. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0020] Figure 1 is a flow chart of an embodiment of a traffic data processing method based on improved Kalman filtering provided by the present application;
[0021] Figure 2 It is a comparison chart of an embodiment of traffic light timing scheme optimization comparison provided by the present application;
[0022] Figure 3 is a comparison diagram of an embodiment of Kalman's traffic flow and real traffic flow in different periods provided by the present application;
[0023] Figure 4 is a comparison diagram of another embodiment of the Kalman traffic flow and the real traffic flow in different periods provided by the present application;
[0024] Figure 5 is a comparison chart of an embodiment of the comparison of the second objective function value provided by the present application;
[0025] Figure 6 is a structural diagram of an embodiment of a traffic data processing device based on improved Kalman filtering provided by the present application;
[0026] Figure 7 It is a structural diagram of an embodiment of an electronic device provided by the present application. DETAILED DESCRIPTION
[0027] In order to make the purpose and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0028] It should be noted that, although the functional modules are divided in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first", "second", etc. in the specification, claims and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0029] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0030] like Figure 1 One embodiment of the present application includes a traffic data processing method based on improved Kalman filtering, the method comprising:
[0031] Step S100, when the traffic light at the target intersection is of the first timing duration, obtaining the traffic volume of the upstream intersection corresponding to the target intersection and the historical traffic volume of the target intersection in multiple cycles;
[0032] Step S300, predicting the predicted traffic flow of the target intersection within the period based on the traffic flow of the upstream intersection and the historical traffic flow according to the Kalman filter;
[0033] Step S500, according to the predicted traffic volume, the traffic light at the target intersection is adjusted to a second timing duration, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, the second timing duration is used as the actual timing duration of the traffic light at the target intersection.
[0034] In this embodiment, the target intersection can be any three-way intersection or crossroad, and the target intersection has a traffic light. The first timing duration refers to the timing duration that is initially set.
[0035] The purpose of this embodiment is to first predict the traffic flow at the target intersection based on existing data, and then use the prediction results to re-time the traffic lights at the target intersection to obtain the actual timing of the traffic lights at the target intersection that can alleviate traffic congestion.
[0036] In step S100, the traffic volume of the upstream intersection corresponding to the target intersection and the historical traffic volume of the target intersection within a period are first obtained.
[0037] Then, in step S300, not only the traffic flow data of the upstream intersection is considered to predict the traffic flow of the target intersection, but also the historical traffic flow of the target intersection in different periods is considered to predict the traffic flow of the target intersection, that is, the Kalman filter is used to consider the spatial propagation characteristics of the traffic flow. The space-based prediction method can take into account the mutual influence of traffic flow between different intersections, and the time series-based prediction method can take into account the time series changes of traffic flow in time. The spatiotemporal prediction of traffic flow is achieved through Kalman filtering, which can provide more accurate prediction data, thereby providing more accurate decision support for traffic light timing.
[0038] It should be noted that the improved Kalman of the present application means that based on the Kalman filtering technology, in the process of predicting the traffic flow, the historical data at different times are considered for prediction, and the traffic flow at the upstream intersection is also considered to predict the traffic flow at the target intersection.
[0039] The following describes the processing flow based on Kalman filtering:
[0040] The traffic volume of the cycle is averaged to the traffic volume per second, and the cycle includes the red light timing and green light timing; then it is aggregated to the five-minute traffic volume (five minutes generally includes multiple cycles), and this data is input into the Kalman filter model as follows:
[0041] ;
[0042] ;
[0043] in, , , is the state transition matrix, is the process noise, is the observation noise (set to the unit matrix 0.01 during the experiment), It is The correlation coefficient of the cycle, It is The input features are The flow ratio of the cycle, It is The traffic ratio of the predicted traffic flow in the period. and is defined as follows:
[0044] ;
[0045] ;
[0046] in, It is The input features are The traffic flow observation value of the period, It is The input features are The historical average of traffic flow in the period, It is the predicted section The predicted traffic flow of the cycle, It is the predicted section The historical mean of traffic flow in the period. The following is the iterative equation:
[0047] ;
[0048] ;
[0049] ;
[0050] ;
[0051] ;
[0052] The first two equations are the prediction part, where is the prior estimate of the state vector (in this formula It is a vector containing three parameters. According to field experiments, the traffic flow of the predicted period of the same section is strongly correlated with the traffic flow of the first three adjacent periods, but weakly correlated with the time between other periods. Therefore, the prediction uses the data of the first three periods, and the state vector is its corresponding coefficient). is the posterior estimate of the state vector, is the state transition matrix, is the a priori estimate of the error covariance, is the posterior estimate of the error covariance; the last three equations are the parameter correction part, where is the Kalman gain, is the covariance matrix of the process noise, is the covariance matrix of the observation noise, It is a unit array. It is The flow ratio of the predicted flow of the period (the current prediction result of the iterative equation is a ratio, which needs to be converted to obtain the flow value), It is The flow ratio of the observed vehicle flow in the period is defined as:
[0053] ;
[0054] in It is the predicted section The traffic flow observation value of the period, It is the deadline The mean traffic volume during the period. This is the error between the prediction and the actual state. The posterior estimate of the state vector is obtained by correction. , the last step is to calculate the covariance matrix Therefore, the covariance matrix will be updated in each iteration, and the model will be adjusted continuously to achieve the purpose of fitting the actual traffic flow.
[0055] In step S500, the traffic light at the target intersection is adjusted to a second timing duration according to the predicted traffic flow, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, the second timing duration is used as the actual timing duration of the traffic light at the target intersection.
[0056] In some embodiments of the present application, adjusting the traffic light at the target intersection to the second timing duration according to the predicted traffic flow in step S500 includes:
[0057] Step S510, determining a plurality of first objective functions corresponding to the timing duration of the target intersection; wherein the plurality of first objective functions at least include: a first objective function for maximizing the amount of vehicles passing through, a first objective function for maximizing the average speed of passing vehicles, and a first objective function for minimizing the delay of vehicles waiting for a red light; passing vehicles are vehicles passing through the target intersection;
[0058] Step S520 , performing multi-objective solving on the multiple first objective functions according to the non-dominated sorting genetic algorithm to obtain the second timing duration of the traffic light at the target intersection.
[0059] In this embodiment, multiple optimization objectives are considered simultaneously, such as: the first objective function of maximizing vehicle throughput, maximizing the average speed of passing vehicles, and minimizing the delay of vehicles waiting for red lights; and providing a corresponding first objective function, using a non-dominated sorting genetic algorithm to find the optimal traffic light timing plan for the target intersection while considering multiple optimization objectives, thereby achieving adjustment and optimization of traffic flow to alleviate traffic congestion.
[0060] This embodiment takes multiple optimization objectives into consideration at the same time, and the use of a non-dominated sorting genetic algorithm can more effectively handle multi-objective optimization problems and provide a better traffic light timing solution.
[0061] In some embodiments of the present application, when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration in step S500, before using the second timing duration as the actual timing duration of the traffic light at the target intersection, the method further includes:
[0062] Step S410, when the traffic light at the target intersection is at the second timing duration, determining the vehicle passing volume, the average speed of the passing vehicles, and the delay of the vehicles waiting for the red light at the target intersection within the cycle;
[0063] Step S420, determining a second traffic quality value corresponding to the second timing duration according to the number of vehicles passing, the average speed of the vehicles passing, and the delay time of the vehicles waiting for the red light;
[0064] Step S430, determining a first traffic quality value corresponding to the first timing duration when the traffic light at the target intersection is of the first timing duration;
[0065] When the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, the second timing duration is used as the actual timing duration of the traffic light at the target intersection, including:
[0066] Step S530: When the second traffic quality value is better than the first traffic quality value, the second timing duration is used as the actual timing duration of the traffic light at the target intersection.
[0067] In some embodiments of the present application, a second objective function is constructed, and a second traffic quality value corresponding to the second timing duration is determined according to the second objective function based on the vehicle throughput, the average speed of the passing vehicles, and the vehicle waiting red light delay, including:
[0068] ;
[0069] in, is the second pass quality value, It is the ratio of the vehicle throughput of the target intersection to the green light timing duration. Each cycle corresponds to a value according to different directions and lanes. is the average speed of vehicles passing through the target intersection. The speed is across the intersection, so the passing time is matched to the corresponding cycle. Each cycle in the same direction corresponds to an average passing speed. The waiting time for the vehicle at the target intersection is the red light delay, and each cycle corresponds to a value according to different directions and lanes. They are For details, see the subsequent embodiments.
[0070] Different weights can be selected for different time periods. In normal time periods, the delay can be used as the main weight, and in peak time periods, the traffic volume can be used as the main weight. Each lane reflects the traffic effect of the cycle in real time, and the second objective function can be obtained through the changes in the traffic light ratio. The change in value is then fed back to the adjustment of the traffic lights.
[0071] This embodiment constructs a second objective function for comprehensive evaluation of multiple factors. , which is determined by the vehicle flow per unit time N, the passing speed V, and the vehicle delay DT, and each is given a certain weight. This comprehensive evaluation method can more comprehensively reflect the traffic conditions at the intersection and provide a more reasonable decision-making basis for the timing of traffic lights. Compared with the existing technology, it can more comprehensively evaluate the traffic conditions, thereby achieving a better traffic light timing plan.
[0072] In some embodiments of the present application, the first objective function for maximizing vehicle throughput in step S510 includes:
[0073] ;
[0074] in, The target intersection is in the direction of vehicle travel The vehicle traffic volume on is 3 or 4, The target intersection is in the direction of vehicle travel The green light on the For cycle.
[0075] The first objective function that maximizes the average speed of the vehicles includes:
[0076] ;
[0077] in, The target intersection is in the direction of vehicle travel The vehicle traffic volume on is 3 or 4, The target intersection is in the direction of vehicle travel The green light on the The target intersection is in the direction of vehicle travel The length of the road section, The driving direction of the vehicle at the target intersection The waiting red light delay.
[0078] The first objective function for minimizing the delay of vehicles waiting for red lights includes:
[0079] ;
[0080] in, The target intersection is in the direction of vehicle travel The vehicle traffic volume on is 3 or 4, The target intersection is in the direction of vehicle travel The green light on the For cycle.
[0081] The non-dominated sorting genetic algorithm optimizes the timing plan by finding the Pareto optimal solution set, and needs to set different weights for speed, throughput and delay, so that it can fit the situation of the intersection in more time periods, and introduce conditional logic into the optimization genetic algorithm. Specifically, when the traffic volume is large, the throughput is given priority; under normal circumstances, the delay is the main weight, which is consistent with the second objective function. The specific operation plan is as follows:
[0082] (1) Non-dominated sorting:
[0083] Individuals in a population are divided into different classes according to the number of other individuals they dominate. Each class forms a non-dominated layer.
[0084] (2) Crowding distance allocation:
[0085] The crowding distance is based on the density of the individual's neighborhood in the objective function space. For each direction of the vehicle individual in the data, its crowding distance in the objective function space is calculated.
[0086] (3) Selection, crossover and mutation:
[0087] Using the tournament selection strategy, individuals are selected for crossover and mutation to generate a new population. The crossover operation adopts the crossover method of simulated binary crossover (SBX).
[0088] (4) Iteration:
[0089] Repeat the above steps until the termination condition is met, such as reaching the maximum number of iterations or the solution set converges.
[0090] The method provided in this embodiment first performs a spatiotemporal prediction of the traffic flow at the target intersection. After obtaining the predicted results of the traffic flow, a multi-objective optimization algorithm is used to control the timing plan of traffic lights in real time, and the set objective function is used as an evaluation indicator, which can effectively improve the traffic capacity of the traffic intersection.
[0091] This embodiment has the following effects:
[0092] (1) Not only the traffic flow of the upstream intersection of the target intersection is taken into account, but also the historical traffic flow of the target intersection. The spatiotemporal prediction process of the traffic flow of the target intersection is realized through Kalman filtering, which improves the prediction accuracy of the traffic flow, thereby improving the quality of timing and alleviating traffic congestion.
[0093] (2) In the timing optimization, multiple optimization objectives are designed, such as: the first objective function of maximizing the vehicle throughput at the target intersection, maximizing the average speed of vehicles passing through, and minimizing the delay of vehicles waiting for red lights; and providing a corresponding first objective function. The non-dominated sorting genetic algorithm can find the optimal traffic light timing plan for the target intersection while considering multiple optimization objectives, thereby achieving the adjustment and optimization of traffic flow to alleviate traffic congestion.
[0094] (3) The second objective function P is designed to not only focus on the traffic volume, but also consider the vehicle speed and vehicle delay. It is determined by the traffic volume per unit time N, the speed V, and the vehicle delay time DT, and each is given a certain weight. This comprehensive evaluation method can more comprehensively reflect the traffic conditions at the intersection and provide a more reasonable decision-making basis for the timing of traffic lights. Compared with the existing technology, it can more comprehensively evaluate the traffic conditions, thereby achieving a better traffic light timing plan.
[0095] For ease of understanding, this application also provides experimental examples:
[0096] (1) Experimental environment;
[0097] Here, some intersections in a certain area of Shanghai are selected (selected as target intersections), and the measured data of the intersections are optimized, merged and analyzed. The periodic traffic flow is first normalized, then aggregated into five-minute traffic flow and predicted using the improved Kalman filter model.
[0098] Through the induction of the virtual coil and the intersection camera, relevant intersection information, including traffic flow, speed, intersection waiting time, intersection waiting length, driving direction, etc., a custom Python model is used to simulate traffic flow. Parameters such as traffic light timing, traffic flow, and vehicle behavior are set in the model. Through simulation tests, the traffic flow, speed, and delay data obtained from the new timing scheme are also brought into the second objective function to compare the model evaluation of the intersection evaluation indicators.
[0099] Table 1
[0100]
[0101] (2) Data processing;
[0102] In the actual process, there is no way to accurately obtain the cycle in real time. The program intercepts it every ten minutes, and each interception is put into the cache table. The cache table only stores the data of two interceptions. After each interception, the cache table will sort and extract the complete cycle. The missing data at the end will be left for the next interception for matching. The unmatched data in the middle will be treated as an error. Then the required cycle data will be written into the result table. Correspondingly, the license plate data will be directly intercepted into the cache table.
[0103] The data collected during the complete cycle of interception and collation under this type of method.
[0104] The definition of recorded throughput needs to be combined with the layout of virtual coils on the road. After the virtual coils on different roads are detected, data is intercepted and updated.
[0105] According to the extracted correct cycle, the traffic flow, delayed speed and other data are calculated and stored in the result table. The missing cycle is not calculated for the time being.
[0106] The dynamic display program will also extract data from these result tables every ten minutes, including traffic flow, delay, and speed to calculate the second objective function P value (traffic flow, delay, and speed are calculated by specifying weights). The obtained P value and the traffic data calculation results are used to adaptively modify the timing in real time, and the traffic data is substituted into the second objective function to compare the size relationship of the P value before and after the modification of the timing to continuously improve the timing plan.
[0107] For the specific adjustment of the weights of each indicator in the second objective function P, by analyzing the real-time monitoring results of specific intersections and obtaining the traffic data characteristics in different time periods, the weight adjustment ideas of the second objective function are roughly analyzed.
[0108] According to the experimental results, the data characteristics of a specific intersection are monitored in real time for a period of time. This is used as the evaluation standard to analyze the current time period and assign corresponding weights. Based on the collected real-time data characteristics, since whether it is a working day has no obvious impact on the detected indicators, in the process of weight setting, it can be mainly divided into normal time period and peak time period, and the settings are as follows:
[0109] Table 2
[0110]
[0111] like Figure 2 , the objective function with set weights is used as the evaluation index, and the second objective function is required to reach a better value as much as possible according to the weight tilt at different times. The non-dominated sorting genetic algorithm is used to adjust the timing of traffic lights at intersections, and the comparison image of the modified timing scheme and the original timing scheme is obtained.
[0112] (3) Experimental results;
[0113] like Figure 3 , is the prediction result diagram of the designed Kalman filter model for the data of two intersections in the experimental location.
[0114] like Figure 4 This is a prediction display of traffic flow on one of the road sections. It can be seen that the improved Kalman filter model will be continuously adjusted to fit the actual data during the prediction process.
[0115] like Figure 5 This is the prediction of traffic flow on another road section. The traffic flow between these two intersections is small, and the prediction accuracy of the improved Kalman filter model will be lower, but it can also achieve a better fitting effect. By comparing data from different sections, the model will be more accurate in predicting sections with large traffic flow (congested sections).
[0116] Using the predicted traffic flow and other data, after applying the multi-objective optimization algorithm to the intersection timing, the original timing scheme is substituted into the objective function P of the corresponding time to obtain the red data. After the simulation, the new traffic data is counted and the custom Python model is used to simulate the traffic flow. The parameters such as traffic light timing, traffic flow, and vehicle behavior are set in the model. Through simulation tests, the traffic flow, speed, and delay data obtained from the new timing scheme are also brought into the objective function. Through the simulation and comparative analysis scheme, the conclusion of effective optimization of the traffic conditions at the intersection can be obtained.
[0117] like Figure 6 One embodiment of the present application provides a traffic data processing device based on improved Kalman filtering, the device comprising:
[0118] The first traffic flow calculation unit 1100 is used to obtain the traffic flow of the upstream intersection corresponding to the target intersection and the historical traffic flow of the target intersection within a period when the traffic light at the target intersection is of the first timing duration;
[0119] The second vehicle flow calculation unit 1200 is used to predict the predicted vehicle flow of the target intersection within the period based on the vehicle flow of the upstream intersection and the historical vehicle flow according to the Kalman filter;
[0120] The timing duration calculation unit 1300 is used to adjust the traffic light at the target intersection to a second timing duration according to the predicted traffic flow, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, use the second timing duration as the actual timing duration of the traffic light at the target intersection.
[0121] It should be noted that the traffic data processing device based on improved Kalman filtering provided in this embodiment and the traffic data processing method based on improved Kalman filtering mentioned above are based on the same inventive concept. Therefore, the relevant content of the above-mentioned traffic data processing method based on improved Kalman filtering is also applicable to the content of a traffic data processing device based on improved Kalman filtering provided in this embodiment. Therefore, it will not be repeated here.
[0122] like Figure 7 The present application also provides an electronic device, which includes:
[0123] at least one memory;
[0124] at least one processor;
[0125] at least one program;
[0126] The program is stored in the memory, and the processor executes at least one program to implement the traffic data processing method based on the improved Kalman filter in the present disclosure.
[0127] The electronic device may be any intelligent terminal including a mobile phone, a tablet computer, a personal digital assistant (PDA), a vehicle-mounted computer, etc.
[0128] The electronic device according to the embodiment of the present application is described in detail below.
[0129] The processor 1600 may be implemented by a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical timing provided by the embodiment of the present invention;
[0130] The memory 1700 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device or a random access memory (RAM). The memory 1700 can store an operating system and other application programs. When the technical timing provided in the embodiment of this specification is implemented by software or firmware, the program code is stored in the memory 1700, and the processor 1600 calls and executes the traffic data processing method based on the improved Kalman filter in the embodiment of the present invention.
[0131] Input / output interface 1800, used to implement information input and output;
[0132] Communication interface 1900, used to realize communication interaction between the device and other devices, which can be realized through wired mode (such as USB, network cable, etc.) or wireless mode (such as mobile network, WIFI, Bluetooth, etc.);
[0133] Bus 2000 , which transmits information between various components of the device (e.g., processor 1600 , memory 1700 , input / output interface 1800 , and communication interface 1900 );
[0134] The processor 1600 , the memory 1700 , the input / output interface 1800 , and the communication interface 1900 are connected to each other in communication within the device via the bus 2000 .
[0135] An embodiment of the present invention further provides a storage medium, which is a computer-readable storage medium. The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the above-mentioned traffic data processing method based on improved Kalman filtering.
[0136] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0137] The embodiments described in the present invention are intended to more clearly illustrate the technical timing duration of the embodiments of the present invention, and do not constitute a limitation on the technical timing duration provided by the embodiments of the present invention. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical timing duration provided by the embodiments of the present invention is equally applicable to similar technical issues.
[0138] Those skilled in the art will appreciate that the technical timings shown in the figures do not constitute limitations on the embodiments of the present invention, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0139] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of timing duration in this embodiment.
[0140] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0141] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0142] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: 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 indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural 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, c can be single or multiple.
[0143] In the several embodiments provided in the present 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 schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0144] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of timing duration in this embodiment.
[0145] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0146] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical timing duration of the present application is essentially or the part that contributes to the prior art or all or part of the technical timing duration can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including multiple instructions to enable an electronic device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store programs.
[0147] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A traffic data processing method based on improved Kalman filtering, characterized in that: The method comprises: When the traffic light at the target intersection is of the first timing duration, obtaining the traffic volume of the upstream intersection corresponding to the target intersection and the historical traffic volume of the target intersection in multiple cycles; According to Kalman filtering, based on the traffic volume of the upstream intersection and the historical traffic volume, predicting the predicted traffic volume of the target intersection within a period; According to the predicted traffic volume, adjusting the traffic light at the target intersection to a second timing duration, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, using the second timing duration as the actual timing duration of the traffic light at the target intersection; According to the predicted traffic volume, adjusting the traffic light at the target intersection to the second timing duration includes: Determine a plurality of first objective functions corresponding to the timing duration of the target intersection; wherein the plurality of first objective functions at least include: a first objective function for maximizing the amount of vehicles passing through, a first objective function for maximizing the average speed of passing vehicles, and a first objective function for minimizing the delay of vehicles waiting for a red light; the passing vehicles are vehicles passing through the target intersection; According to a non-dominated sorting genetic algorithm, a plurality of first objective functions are solved for multi-objective purposes to obtain a second timing duration of the traffic light at the target intersection; When the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, before using the second timing duration as the actual timing duration of the traffic light at the target intersection, the method further includes: When the traffic light at the target intersection is of the second timing duration, determining the number of vehicles passing through the target intersection within a period, the average speed of vehicles passing through, and the delay of vehicles waiting for the red light; Determine a second traffic quality value corresponding to the second timing duration according to the number of vehicles passing, the average speed of vehicles passing, and the delay time of vehicles waiting for a red light; Determine a first traffic quality value corresponding to the first timing duration when the traffic light at the target intersection is of the first timing duration; When the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, using the second timing duration as the actual timing duration of the traffic light at the target intersection comprises: When the second traffic quality value is better than the first traffic quality value, the second timing duration is used as the actual timing duration of the traffic light at the target intersection; The second traffic quality value corresponding to the second timing duration is determined according to the vehicle passing volume, the average speed of the passing vehicles, and the delay time of the vehicles waiting for the red light: ; in, is the second pass quality value, is the ratio of the vehicle throughput at the target intersection to the green light timing duration, is the average speed of vehicles passing through the target intersection, Delay the vehicle's waiting time at the red light at the target intersection. They are The weight of .
2. The traffic data processing method based on improved Kalman filtering according to claim 1 is characterized in that: The first objective function for maximizing vehicle throughput includes: ; in, The target intersection in the vehicle travel direction The vehicle traffic volume on is 3 or 4, The target intersection in the vehicle travel direction The green light on the For cycle.
3. The traffic data processing method based on improved Kalman filtering according to claim 1 is characterized in that: The first objective function for maximizing the average vehicle speed of the vehicle includes: ; in, The target intersection in the vehicle travel direction The vehicle traffic volume on is 3 or 4, The target intersection in the vehicle travel direction The green light on the The target intersection in the vehicle travel direction The length of the road section, The driving direction of the vehicle at the target intersection The waiting red light delay.
4. The traffic data processing method based on improved Kalman filtering according to claim 1 is characterized in that: The first objective function for minimizing the delay of vehicles waiting for red lights includes: ; in, The target intersection in the vehicle travel direction The vehicle traffic volume on is 3 or 4, The target intersection in the vehicle travel direction The green light on the For cycle.
5. A traffic data processing device based on improved Kalman filtering, characterized in that: The device comprises: A first traffic flow calculation unit, used for obtaining the traffic flow of an upstream intersection corresponding to the target intersection and the historical traffic flow of the target intersection in multiple cycles when the traffic light at the target intersection is of the first timing duration; A second vehicle flow calculation unit, configured to predict the predicted vehicle flow of the target intersection within a period based on the vehicle flow of the upstream intersection and the historical vehicle flow according to a Kalman filter; A timing duration calculation unit is used to adjust the traffic light at the target intersection to a second timing duration according to the predicted traffic flow, and when the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, use the second timing duration as the actual timing duration of the traffic light at the target intersection. The adjusting the traffic light at the target intersection to the second timing duration according to the predicted traffic flow includes: Determine a plurality of first objective functions corresponding to the timing duration of the target intersection; wherein the plurality of first objective functions at least include: a first objective function for maximizing the amount of vehicles passing through, a first objective function for maximizing the average speed of passing vehicles, and a first objective function for minimizing the delay of vehicles waiting for a red light; the passing vehicles are vehicles passing through the target intersection; According to a non-dominated sorting genetic algorithm, a plurality of first objective functions are solved for multi-objective purposes to obtain a second timing duration of the traffic light at the target intersection; When the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, before using the second timing duration as the actual timing duration of the traffic light at the target intersection, the method further includes: When the traffic light at the target intersection is of the second timing duration, determining the number of vehicles passing through the target intersection within a period, the average speed of vehicles passing through, and the delay of vehicles waiting for the red light; Determine a second traffic quality value corresponding to the second timing duration according to the number of vehicles passing, the average speed of vehicles passing, and the delay time of vehicles waiting for a red light; Determine a first traffic quality value corresponding to the first timing duration when the traffic light at the target intersection is the first timing duration; When the traffic quality index of the second timing duration is better than the traffic quality index of the first timing duration, using the second timing duration as the actual timing duration of the traffic light at the target intersection comprises: When the second traffic quality value is better than the first traffic quality value, the second timing duration is used as the actual timing duration of the traffic light at the target intersection; The second traffic quality value corresponding to the second timing duration is determined according to the vehicle passing volume, the average speed of the passing vehicles, and the delay time of the vehicles waiting for the red light: ; in, is the second pass quality value, is the ratio of the vehicle throughput at the target intersection to the green light timing duration, is the average speed of vehicles passing through the target intersection, Delay the vehicle's waiting time at the red light at the target intersection. They are The weight of .
6. An electronic device, characterized in that: It includes at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute the traffic data processing method based on improved Kalman filtering as described in any one of claims 1 to 4.
7. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the traffic data processing method based on improved Kalman filtering as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Traffic light control method and system integrating deep prediction network and Kalman filtering algorithm
CN115497294A
Vehicle group-based mixed traffic flow signal control method and device
CN118609346A