Monte Carlo sampling-based electric police checkpoint monitoring vehicle track completion method
By applying big data and Monte Carlo sampling method in the electric alarm bayonet system, combining the shortest path algorithm and traffic allocation model, the problem of difficulty in determining the starting and end points in vehicle trajectory completion is solved, and the accurate completion of the vehicle trajectory is achieved.
Patent Information
- Application Number
- CN202510249619.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-04
- Publication Date
- 2025-06-03
AI Technical Summary
The prior art is difficult to accurately determine the starting and ending points of the vehicle driving, resulting in inaccurate results of vehicle trajectory completion.
The Monte Carlo sampling method based on big data is adopted to obtain vehicle traffic data through the electric alarm checkpoint system, pre-process and shortest path Dijkstra algorithm calculation, and a traffic distribution model is constructed based on signaling big data, road network sequence matching and Monte Carlo random sampling is performed, and a path that meets the average travel distance distribution curve is selected as the complete trajectory of vehicle travel.
Accurate completion of trajectories of different types of vehicles is achieved, and the accuracy and reliability of trajectory completion are improved.
Smart Images

Figure CN120089010A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method for completing the vehicle trajectory monitored by an electronic police checkpoint, and particularly to a method for completing the vehicle trajectory monitored by an electronic police checkpoint based on Monte Carlo sampling, belonging to the technical field of vehicle trajectory completion. Background Art
[0002] An electronic police checkpoint is a common electronic police device, generally installed at the entrance and exit of a road, automatically detecting the status and information of passing vehicles, and can be used for vehicle violations, road traffic flow status evaluation, etc. Therefore, based on the data of the electronic police checkpoint, the spatial position of a vehicle on the road network at different times can be identified. However, due to the cost of installing checkpoint devices and the detection efficiency problem, it is difficult to determine the continuous state of the vehicle in the road network and the starting and ending points of the vehicle's travel.
[0003] In the prior art, the vehicle travel trajectory completion method is to construct the shortest path between continuously detected vehicle points to complete the trajectory. However, it is difficult to find the starting and ending points of the vehicle's travel by this method, or to identify the starting and ending points through floating car GPS data to match the starting and ending points of the vehicle monitored by the checkpoint. However, the common floating car GPS data only represents the travel of some special groups, and its path selection has particularity, making it difficult to characterize the travel characteristics of private cars.
[0004] In summary, a method for completing the vehicle trajectory monitored by an electronic police checkpoint based on Monte Carlo sampling under big data is needed. Summary of the Invention
[0005] A brief overview of the present invention is given below to provide a basic understanding of certain aspects of the present invention. It should be understood that this overview is not an exhaustive overview of the present invention. It is not intended to identify the key or important parts of the present invention, nor is it intended to limit the scope of the present invention. Its purpose is only to present certain concepts in a simplified form as a prelude to the more detailed description that follows.
[0006] In view of this, to solve the problem that the trajectory completion result is inaccurate due to the difficulty in determining the starting and ending points of different types of vehicles' travel in the prior art, the present invention provides a method for completing the vehicle trajectory monitored by an electronic police checkpoint based on Monte Carlo sampling under big data.
[0007] The technical solution is as follows: A method for completing the vehicle trajectory monitored by an electronic police checkpoint based on Monte Carlo sampling under big data, comprising the following steps:
[0008] S1. Preprocess the vehicle passing data obtained by the electronic police checkpoint system, and obtain the updated vehicle trajectory sequence through the matching relationship between the checkpoint device and the actual road network;
[0009] S2. Based on the updated vehicle trajectory sequence, calculate the shortest path through the Dijkstra algorithm for the shortest path, complete the road sequence between the detection points of the traffic police checkpoint system, and obtain the road sequence for vehicle detection;
[0010] S3. Based on signaling big data, construct a traffic assignment model, perform traffic assignment on the actual road network, and obtain the travel trajectory sequence and travel distance distribution curve between traffic zones;
[0011] S4. Based on the road sequence for vehicle detection and the travel trajectory sequence between traffic zones, perform road network sequence matching to obtain the detected vehicle path set;
[0012] S5. According to the detected vehicle path set, use Monte Carlo random sampling to select the paths that conform to the average travel distance distribution curve as the complete travel trajectories of the final vehicle trips.
[0013] Furthermore, in S1, obtain the desensitized vehicle passing data in the traffic police checkpoint system and perform data cleaning on it. The desensitized vehicle passing data includes the unique ID of the vehicle, the time of passing through the checkpoint, and the geographical location of the checkpoint. After data cleaning is completed, traverse each vehicle, record the checkpoint ID passed by each vehicle, and obtain the checkpoint ID sequence of the vehicle, that is, the vehicle trajectory sequence. By matching the geographical location of the checkpoint with the actual road network, the checkpoint ID sequence of the vehicle is converted into the actual road sequence, and the vehicle trajectory sequence is updated to obtain the road sequence passed by each vehicle successively, that is, the updated vehicle trajectory sequence.
[0014] Furthermore, in S2, based on the updated vehicle trajectory sequence, construct a road network topology graph, where the nodes represent intersections, the edges represent roads, and the weights of the edges are distance, travel time, and congestion level. Based on the road nodes corresponding to the detection points of the checkpoint, calculate the shortest path and the node sequence of the shortest path between the detection points through the Dijkstra algorithm for the shortest path, concatenate the shortest path nodes between all detection points, obtain the detection path of the whole detected vehicle, traverse each vehicle, and obtain the road sequence for vehicle detection;
[0015] The calculation steps of the Dijkstra algorithm for the shortest path are as follows:
[0016] S21. Initialization:
[0017] Set the distance from the starting point to itself to 0 and the distance to all other nodes to infinity, and create a set of unvisited nodes containing all nodes in the road network;
[0018] S22. Select a node:
[0019] Select a node closest to the starting point from the set of unvisited nodes as the current node;
[0020] S23. Update the distance:
[0021] For each adjacent node of the current node, calculate the distance from the current node to the adjacent node. If the distance from the current node to the adjacent node is less than the previously recorded distance from the current node to the previous adjacent node, update the distance from the current node to the adjacent node;
[0022] S24. Mark as visited:
[0023] Mark the current node as visited;
[0024] S25. Repeat:
[0025] Repeat steps S22 - S24 until the end point is visited or all nodes are visited, obtaining the shortest paths from the starting point to other nodes.
[0026] Furthermore, in S3, construct a traffic assignment model, use signaling big data to obtain the origin - destination (OD) of vehicle trips, adopt the user equilibrium assignment method based on the Wardrop equilibrium assignment principle, perform traffic assignment on the road network through the traffic assignment model, obtain the travel trajectory sequence between traffic zones by analyzing the traffic assignment results, and obtain the travel distance distribution curve by counting the travel volumes within different distance ranges;
[0027] The traffic assignment model is expressed as:
[0028]
[0029] where min:Z(X) represents the traffic assignment result, x a represents the traffic flow of section a, t a represents the traffic impedance of section a, t a (x a ) represents the impedance function of section a with traffic flow as the independent variable, represents the traffic flow on the k - th path between the origin r and the destination s, represents the path - path related variable. If section a belongs to the k - th path between the OD with origin r and destination s, then otherwise it is 0, q rs represents the OD traffic volume with origin r and destination s.
[0030] Further, in S4, for each vehicle, based on the road sequence detected by the vehicle and the travel trajectory sequence between traffic zones, perform road network sequence matching, select the travel trajectory sequence between traffic zones with the highest matching value as the candidate set of complete vehicle travel trajectories, that is, the detected vehicle path set.
[0031] Further, in S5, for each vehicle, according to the candidate set of complete vehicle travel trajectories, calculate the travel distance of each candidate trajectory therein, and adopt the Monte Carlo random sampling and rejection-acceptance method to select the path that conforms to the distribution curve of the average travel distance as the complete travel trajectory of the final vehicle travel.
[0032] The beneficial effects of the present invention are as follows: First, based on the spatial position of the bayonet device, determine the road where the bayonet device is located, traverse the vehicle ID, determine the sequence of road node matches of the bayonet passed by the vehicle, and based on the shortest path, complete the node sequence between the corresponding road nodes of the front and rear bayonets as the effective vehicle trajectory under bayonet detection; Secondly, adopt the OD matrix of motor vehicle travel demand recognized under signaling big data, and use the traffic assignment method in the road network to obtain the travel paths between different traffic zones and the distribution curve of motor vehicle travel distance under spatial distribution; Finally, perform spatial matching on the completed effective trajectories of each vehicle detected by the bayonet to obtain the set of travel paths between traffic zones of each vehicle based on big data as the alternative full-link trajectory set, and use the Monte Carlo method for sampling to select the set that most conforms to the distribution curve of motor vehicle travel distance under signaling as the final matched and complete vehicle travel trajectory under bayonet device monitoring; The present invention realizes the trajectory completion of different types of vehicles. Description of the Drawings
[0033] The drawings described herein are used to provide a further understanding of the present invention, and constitute a part of the present invention. The illustrative embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0034] Figure 1 It is a schematic flow chart of an electric police bayonet monitoring vehicle trajectory completion method based on Monte Carlo sampling under big data. Detailed Embodiments
[0035] In order to make the technical solutions and advantages in the embodiments of the present invention clearer, the following further describes the exemplary embodiments of the present invention in detail with reference to the drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than an exhaustive list of all embodiments. It should be noted that, without conflict, the embodiments in the present invention and the features in the embodiments can be combined with each other.
[0036] Refer to Figure 1A detailed description of this embodiment, an electric police checkpoint vehicle trajectory completion method based on Monte Carlo sampling under big data, specifically includes the following steps:
[0037] S1. Preprocess the vehicle passing data obtained by the electric police checkpoint system. Through the matching relationship between the checkpoint equipment and the actual road network, obtain the updated vehicle trajectory sequence;
[0038] S2. According to the updated vehicle trajectory sequence, use the shortest path Dijkstra algorithm to calculate the shortest path, complete the road sequence between the detection points of the electric police checkpoint system, and obtain the road sequence of vehicle detection;
[0039] S3. Based on signaling big data, construct a traffic assignment model, perform traffic assignment on the actual road network, and obtain the travel trajectory sequence and travel distance distribution curve between traffic zones;
[0040] S4. Based on the road sequence of vehicle detection and the travel trajectory sequence between traffic zones, perform road network sequence matching to obtain the detected vehicle path set;
[0041] S5. According to the detected vehicle path set, use Monte Carlo random sampling to select the path that conforms to the average travel distance distribution curve as the complete travel trajectory of the final vehicle travel.
[0042] Further, in the S1, obtain the desensitized vehicle passing data in the electric police checkpoint system and perform data cleaning on it. The desensitized vehicle passing data includes information such as the unique ID of the vehicle, the time of passing through the checkpoint, and the geographical location of the checkpoint. After the data cleaning is completed, traverse each vehicle, record the checkpoint ID passed by each vehicle, obtain the checkpoint ID sequence of the vehicle, that is, the vehicle trajectory sequence. By matching the geographical location of the checkpoint with the actual road network, the checkpoint ID sequence of the vehicle is converted into the actual road sequence, and the vehicle trajectory sequence is updated to obtain the road sequence passed by each vehicle in sequence, that is, the updated vehicle trajectory sequence.
[0043] Specifically, since the obtained original data, that is, the desensitized vehicle passing data, may contain noise, duplicate records, error information, etc., it is necessary to perform data cleaning to remove invalid data, correct error information, and fill in missing values to ensure the accuracy and integrity of the data;
[0044] The checkpoint ID sequence reflects the driving trajectory of the vehicle. To better understand the driving path of the vehicle, it is necessary to match the checkpoint equipment with the actual road network, so as to convert the checkpoint ID sequence of the vehicle into the actual road sequence, and update the trajectory sequence of the vehicle according to the matching relationship between the checkpoint equipment and the road network.
[0045] Further, in S2, according to the updated vehicle trajectory sequence, a road network topology graph is constructed, where nodes represent intersections, edges represent roads, and the weights of the edges are distance, travel time, congestion level, etc. Based on the road nodes corresponding to the detection points of the checkpoint, through the shortest path Dijkstra algorithm, the shortest path and the node sequence of the shortest path between the detection points are calculated, and the shortest path nodes between all detection points are concatenated to obtain the detection path of the entire detected vehicle. Each vehicle is traversed to obtain the road sequence of vehicle detection;
[0046] The calculation steps of the shortest path Dijkstra algorithm are as follows:
[0047] S21. Initialization:
[0048] Set the distance from the starting point to itself as 0 and the distance to all other nodes as infinity (∞), and create a set of unvisited nodes containing all nodes in the road network;
[0049] S22. Select a node:
[0050] Select a node closest to the starting point from the set of unvisited nodes as the current node;
[0051] S23. Update the distance:
[0052] For each adjacent node of the current node, calculate the distance to the adjacent node through the current node. If the distance from the current node to the adjacent node is less than the previously recorded distance from the current node to the previous adjacent node, update the distance from the current node to the adjacent node;
[0053] S24. Mark as visited:
[0054] Mark the current node as visited;
[0055] S25. Repeat:
[0056] Repeat steps S22 - S24 until the end point is visited or all nodes are visited to obtain the shortest path from the starting point to other nodes.
[0057] Further, in S3, a traffic assignment model is constructed. The origin-destination (OD) (starting point - destination) of vehicle trips is obtained using signaling big data. The user equilibrium assignment (UE) method based on the Wardrop equilibrium assignment principle is adopted. Through the traffic assignment model, traffic assignment is performed on the road network. By analyzing the traffic assignment results, the trip trajectory sequence between traffic zones (traffic analysis units divided based on geographical location) is obtained. By counting the trip volumes within different distance ranges, the trip distance distribution curve is obtained;
[0058] The traffic assignment model is expressed as:
[0059]
[0060] Among them, min:Z(X) represents the traffic assignment result, and x a represents the traffic flow of section a, and t a represents the traffic impedance of section a, also known as the travel time, t a (x a ) represents the impedance function of section a with the traffic flow as the independent variable, represents the traffic flow on the k-th path between the origin r and the destination s, represents the path-path related variable. If section a belongs to the k-th path between the OD with the origin r and the destination s, then otherwise it is 0, q rs represents the OD traffic volume with the origin r and the destination s.
[0061] Specifically, the travel trajectory between traffic zones reflects the actual driving path of vehicles from one traffic zone to another. At the same time, based on the travel trajectory between traffic zones, the distribution of travel distances can be further analyzed.
[0062] Furthermore, in S4, for each vehicle, according to the road sequence detected by the vehicle and the travel trajectory sequence between traffic zones, road network sequence matching is performed, and the travel trajectory sequence with the highest matching value between traffic zones is selected as the candidate vehicle complete travel trajectory set, that is, the detected vehicle path set.
[0063] Furthermore, in S5, for each vehicle, according to the candidate vehicle complete travel trajectory set, the travel distance of each candidate trajectory is calculated, and the Monte Carlo random sampling and rejection-acceptance method are used to select the path that conforms to the distribution curve of the average travel distance as the complete travel trajectory of the final vehicle travel;
[0064] Specifically, assume that the candidate vehicle complete travel trajectory set is a set distribution g(d) about the trajectory distance d, as the proposal distribution, and the average travel distance distribution curve distribution f(d) is used as the target distribution function. Define a constant term M (usually taken as 1) to satisfy f(d) ≤ M·g(d);
[0065] Randomly select a travel trajectory x from the candidate vehicle complete travel trajectory set g(d) to obtain its travel distance d i , and at the same time draw a sample u from the uniform distribution U(0, 1). If then accept the sample x as the sample of the target distribution function f(d), that is, the travel trajectory of the current vehicle, otherwise reject it.
[0066] Although the present invention has been described in terms of a limited number of embodiments, those skilled in the art will appreciate, upon reading the foregoing description, that other embodiments can be contemplated within the scope of the invention as thus described. Further, it should be noted that the language used in this specification has been principally selected for readability and instructional purposes and not to limit or define the inventive subject matter. Accordingly, many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the appended claims. For the scope of the present invention, the disclosure herein is illustrative and not restrictive, and the scope of the invention is defined by the appended claims.
Claims
1. A method for completing vehicle trajectory at electronic police checkpoints based on Monte Carlo sampling under big data, characterized in that: The following steps are involved: S1. Preprocess the vehicle traffic data obtained by the electronic police checkpoint system, and obtain an updated vehicle trajectory sequence through the matching relationship between the checkpoint equipment and the actual road network; S2. According to the updated vehicle trajectory sequence, the shortest path is calculated by the shortest path Dijkstra algorithm to complete the road sequence between the detection points of the electric police checkpoint system to obtain the road sequence of vehicle detection; S3. Based on signaling big data, a traffic distribution model is constructed to distribute traffic on the actual road network, and the travel trajectory sequence and travel distance distribution curve between traffic cells are obtained; S4. Based on the road sequence of vehicle detection and the travel trajectory sequence between traffic cells, a road network sequence is matched to obtain a detection vehicle path set; S5. Based on the detected vehicle path set, Monte Carlo random sampling is used to select a path that conforms to the average travel distance distribution curve as the complete travel trajectory of the final vehicle travel.
2. According to the method of claim 1, the vehicle trajectory completion method for monitoring by electronic police checkpoints based on Monte Carlo sampling under big data is characterized in that: In S1, the desensitized vehicle traffic data in the electric police checkpoint system is obtained and the data is cleaned. The desensitized vehicle traffic data includes the vehicle's unique ID, the time of passing the checkpoint and the geographical location of the checkpoint. After the data cleaning is completed, each vehicle is traversed, and the checkpoint ID passed by each vehicle is recorded to obtain the vehicle's checkpoint ID sequence, that is, the vehicle trajectory sequence. By matching the geographical location of the checkpoint with the actual road network, the vehicle's checkpoint ID sequence is converted into an actual road sequence, and the vehicle trajectory sequence is updated to obtain the road sequence that each vehicle has passed through, that is, the updated vehicle trajectory sequence.
3. The method for completing the vehicle trajectory of an electric police checkpoint based on Monte Carlo sampling under big data according to claim 2 is characterized in that: In S2, a road network topology diagram is constructed according to the updated vehicle trajectory sequence, wherein nodes represent intersections, edges represent roads, and edge weights are distance, travel time, and congestion degree. Based on the road nodes corresponding to the detection points of the checkpoints, the shortest path and the node sequence of the shortest path between the detection points are calculated by the shortest path Dijkstra algorithm, and the shortest path nodes between all the detection points are connected in series to obtain the detection path of the entire detection vehicle, and each vehicle is traversed to obtain the road sequence of vehicle detection; The calculation steps of the shortest path Dijkstra algorithm are as follows: S21. Initialization: Set the distance from the starting point to itself to 0 and the distance to all other nodes to infinity, and create an unvisited node set that includes all nodes in the road network; S22. Select nodes: Select a node closest to the starting point from the unvisited node set as the current node; S23. Update distance: For each adjacent point of the current node, calculate the distance from the current node to the adjacent point. If the distance from the current node to the adjacent point is less than the previously recorded distance from the current node to the previous adjacent point, update the distance from the current node to the adjacent point. S24. Tag access: Mark the current node as visited; S25. Repeat: Repeat steps S22-S24 until the end point is visited or all nodes are visited, and the shortest path from the starting point to other nodes is obtained.
4. According to claim 3, a method for completing vehicle trajectory at an electric police checkpoint based on Monte Carlo sampling under big data, characterized in that: In S3, a traffic distribution model is constructed, and the travel OD of vehicles is obtained by using signaling big data. A user balance distribution method based on the warrop balance distribution principle is adopted to distribute traffic to the road network through the traffic distribution model. By analyzing the traffic distribution results, a travel trajectory sequence between traffic cells is obtained. By counting the travel volume within different distance ranges, a travel distance distribution curve is obtained. The traffic assignment model is expressed as: Among them, Z(X) represents the traffic assignment result, x a represents the traffic flow of road section a, t a represents the traffic impedance of road section a, t a (x a ) represents the impedance function of section a with flow rate as the independent variable, represents the flow on the kth path between the departure point r and the destination point s, represents a path-path related variable. If segment a belongs to the kth path between ODs with a departure point of r and a destination of s, then Otherwise, 0, q rs It represents the OD traffic volume with the departure point r and the destination point s.
5. The method for completing the vehicle trajectory of an electric police checkpoint based on Monte Carlo sampling under big data according to claim 4 is characterized in that: In S4, each vehicle is traversed, and a road network sequence is matched according to the road sequence detected by the vehicle and the travel trajectory sequence between the traffic cells, and the travel trajectory sequence between the traffic cells with the highest matching value is selected as the complete travel trajectory set of the selected vehicle, that is, the detected vehicle path set.
6. The method for completing the vehicle trajectory of an electric police checkpoint based on Monte Carlo sampling under big data according to claim 5 is characterized in that: In S5, for each vehicle, the travel distance of each candidate trajectory is calculated according to the complete travel trajectory set of the candidate vehicles, and the Monte Carlo random sampling and rejection-acceptance method are used to select the path that conforms to the average travel distance distribution curve as the complete travel trajectory of the final vehicle travel.