Online Road Matching Method, Device, Medium and Equipment Based on Beidou Positioning

Through the combination of geohash search and topological search, real-time screening and scoring candidate road segments is solved, and the interruption and delay problems of road matching algorithms in the existing technology are achieved, and efficient online road matching is achieved.

CN114935773BActive Publication Date: 2025-08-05CHINA TRANSPORT TELECOMM & INFORMATION GRP CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210475457.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-29
Publication Date
2025-08-05
Estimated Expiration
2042-04-29

AI Technical Summary

Technical Problem

Existing road matching algorithms based on HMM model are prone to interrupts and delays in vehicle trajectory matching, especially when the positioning point offset is large, it is easy to produce false matching results, and complete online matching cannot be achieved.

Method used

The geohash search algorithm is used to combine topological search to filter candidate sections in real time, and score each candidate section in real time, select the best matching section and matching points, form a complete trajectory, and realize online road matching.

Benefits of technology

The search speed of candidate road segments is improved, error matching is reduced, and real-time generation of positioning point matching results is realized, solving the problems of matching interrupts and delays in the prior art.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114935773B_ABST
    Figure CN114935773B_ABST
Patent Text Reader

Abstract

The present invention relates to an online road matching method based on Beidou positioning, the method comprising: collecting Beidou positioning data of each positioning point in a vehicle trajectory in real time, filtering the positioning points based on preset filtering conditions to select qualified positioning points; for the qualified positioning points, using a geohash retrieval algorithm and a topological search combined method to complete a real-time search of a candidate road section set; scoring each candidate road section in the candidate road section set in real time, and outputting a real-time scoring result for each candidate road section; for the real-time scoring result of each candidate road section, selecting the optimal current matching road section and current matching point based on a preset result selection strategy, connecting the current matching point in series with the previous matching point to form a complete trajectory, and achieving real-time matching of online roads. The present invention also relates to an online road matching device, medium, and equipment based on Beidou positioning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of navigation technology, and in particular to an online road matching method, device, medium and equipment based on Beidou positioning. Background Art

[0002] Currently, vehicle satellite positioning data typically includes spatial location information such as the vehicle's longitude and latitude. However, due to various errors in satellite positioning, the positioning data we obtain is not precise. Relying solely on the information in the positioning data cannot accurately determine the vehicle's road location. The road matching algorithm matches each positioning point in the trajectory to the road on which it is most likely to have traveled and calculates the corresponding matching points to accurately locate the vehicle. Due to the limitations of the on-board positioning terminal and interference from signal strength, the Beidou trajectory data we use has large offset errors and a relatively low trajectory sampling frequency. The average interval between trajectory points for the same vehicle is approximately 30 seconds.

[0003] The document "A Review of Road Network Matching Algorithms[J]., Gao Wenchao, Li Guoliang, Tana; Journal of Software, 2018, 29(02): 225-250." discloses that the most commonly used method in a road matching algorithm is to use a hidden Markov model (HMM) to model the road matching problem and use the Viterbi algorithm to solve it.

[0004] The paper "Shortest path and vehicle trajectory aided map-matching for low-frequency GPS data[J].Quddus M,Washington S.Transportation Research Part C,2015,55:328-339." discloses a candidate road segment scoring and selection process.

[0005] In the prior art, the HMM model abstracts the road matching algorithm into two state sets: an observable state set and an implicit state set. Figure 1The basic principle of HMM is demonstrated, where the positioning point is the observable state set, and its matching point on the corresponding road is the corresponding implicit state set. For each moment, the trajectory point and the candidate matching point have a matching probability, which indicates the possibility of the point matching the candidate point, represented by the observed state probability; the arrows between the candidate matching points at different moments indicate the transfer of the road section, which is the probability of the implicit state from the previous point to the next point, represented by the state transfer matrix. The arrival probability of each point is calculated as the arrival probability of the candidate point at the previous moment + the corresponding transfer probability * the observation probability of the point. In HMM, the road matching problem becomes a search for a path in the implicit state set that maximizes the probability of the candidate point arriving at the last moment. The path found is the final matched trajectory. This problem is often solved using the Viterbi algorithm. For example Figure 2 As shown, the Viterbi algorithm is a dynamic programming method.

[0006] Algorithms based on the HMM model all model the road matching problem by defining different observation probability matrices and state transition matrices. The matching process is mainly as follows:

[0007] For each trajectory point, obtain the candidate edges within a certain distance near it and calculate the corresponding candidate points.

[0008] Use candidate points to construct a candidate graph, that is, a set of hidden states.

[0009] The Viterbi algorithm is used to calculate the path with the highest probability based on the observation probability matrix and the state transition matrix.

[0010] However, existing HMM-based algorithms can experience interruptions in practical applications, where the probability of state transitions from one moment to the next is zero, leading to subsequent matching failures or splitting a complete trajectory into two discontinuous trajectories. When the correct road is not selected when selecting candidate edges, incorrect matching results or matching interruptions are likely to occur, especially when the trajectory point deviation error is large.

[0011] Secondly, since the algorithm uses the Viterbi algorithm to solve, it needs to pre-build a candidate graph for calculation, so it cannot fully realize online matching. Currently, most methods set a time window, cache trajectory points for a period of time, and match them in batches. In the real-time matching scenario, there will be a certain delay.

[0012] In order to solve the problems existing in the existing technology, it is urgent to develop a method that can use geohash index combined with topological search to improve the efficiency of selecting candidate road sections. At the same time, it can also streamline and optimize the positioning point matching process based on the characteristics of Beidou data. Summary of the Invention

[0013] The technical problem to be solved by the present invention is to address the deficiencies of the existing technology and provide an online road matching method, device, medium and equipment based on Beidou positioning.

[0014] The present invention solves the above technical problems with the following technical solutions: an online road matching method based on Beidou positioning, the method comprising:

[0015] Initial screening step: collect Beidou positioning data of each positioning point in the vehicle trajectory in real time, filter the positioning points based on preset filtering conditions, and select qualified positioning points;

[0016] Candidate road section selection steps: For qualified positioning points, a real-time search of the candidate road section set is completed by combining the geohash search algorithm and topological search;

[0017] Candidate road segment scoring step: scoring each candidate road segment in the candidate road segment set in real time, and outputting the real-time scoring result of each candidate road segment;

[0018] Target matching step: Based on the real-time scoring results of each candidate road segment, the optimal current matching road segment and current matching point are selected based on the preset result selection strategy. The current matching point is connected in series with the previous matching point to form a complete trajectory, realizing real-time matching of the online road.

[0019] Preferably, the above-mentioned primary screening step includes:

[0020] Average speed calculation steps: Calculate the average moving speed of the positioning point;

[0021] Filter positioning point steps: if the distance between the positioning point and the previous matching point is less than the preset minimum distance, the positioning point is skipped; if the average speed is greater than the preset limit speed, the positioning point is skipped; output the filtered qualified positioning points.

[0022] Preferably, the candidate road section selection step includes:

[0023] Geohash value calculation steps: The geographical area centered on the positioning point is divided into nine rectangular areas, and the unique geohash value of each rectangular area is calculated;

[0024] Perpendicular line screening step: based on the geohash value, the candidate road segments to be screened are searched, and it is determined whether the foot of the perpendicular line from the positioning point to each candidate road segment to be screened is on the candidate road segment to be screened. If so, the candidate road segment to be screened is included in the set of candidate road segments;

[0025] Topology search step: Based on the preset upper limit distance of the topology search, the end point of the matching road segment of the previous positioning point is added to the queue to be searched, and the corresponding simplified road segment stored in the graph database is searched. It is determined whether the perpendicular foot of the positioning point and each road segment in the simplified road segment is on the road segment. If so, the road segment is added to the candidate road segment set. After iteratively searching the search queue, the candidate road segment set that has passed the topology search is output;

[0026] Deduplication step: Based on the candidate road segment set that has undergone vertical line screening and topological search, deduplication is performed and the final candidate road segment set is output.

[0027] Preferably, the candidate road segment scoring step includes:

[0028] First positioning point scoring step: After a first screening based on the angle between the vehicle's travel direction and each candidate road segment, the vertical distance from the positioning point to each candidate road segment is calculated. The shortest road segment corresponding to the shortest vertical distance is selected, and the foot of the positioning point on the shortest road segment is the matching point.

[0029] Subsequent positioning point scoring steps: Based on the matching point and matching road segment information of the previous positioning point, the vertical distance score, angle score and shortest path distance score are calculated for each candidate road segment in the candidate road segment set, and the weighted sum of each score is calculated as the comprehensive score of the candidate road segment.

[0030] Preferably, the target road section matching step includes:

[0031] Sorting and evaluation step: sort each candidate road segment according to the comprehensive score, calculate the difference between the highest score and the second highest score and compare it with the preset minimum value, and skip the positioning point if the difference is less than the preset minimum value;

[0032] Matching step: If the current positioning point is the last positioning point or the score difference is greater than the threshold, the corresponding road segment with the highest comprehensive score is selected as the target matching road segment, and the shortest path distance is supplemented to fill the path between the current matching point and the previous matching point.

[0033] Preferably, the topology search step includes:

[0034] Initialization step: read the matching road segment information of the previous positioning point, and determine the upper limit distance of the topology search and the positioning points in the search queue;

[0035] Iterative topology search steps: For each positioning point in the search queue, search the graph database for a simplified road segment with the qualified positioning point as the starting point, and the perpendicular line from the positioning point to the starting and ending points of the simplified road segment. Determine whether the foot of the perpendicular line is on the connecting line. If so, determine whether the foot of the perpendicular line between the positioning point and each road segment in the simplified road segment is on the road segment. If so, add the road segment to the candidate road segment set. Otherwise, continue the topology search for the next qualified positioning point until the search queue is completed.

[0036] Preferably, the subsequent positioning point scoring step includes:

[0037] Vertical distance score calculation steps: Calculate vertical distance score Among them, d ⊥ is the vertical distance between the current positioning point and the candidate road section, and D1 is the preset vertical distance threshold;

[0038] Angle score calculation steps: Calculate the angle score s2(θ) = |cos(θ)|, where the current positioning point is P i , the previous matching point is P′ i-1 , current positioning point P i The foot of the perpendicular on the candidate road segment is the matching point P′ i , connecting line P′ i-1 P i Angle θ1 with the north direction and the connecting line P′ i-1 P′ i The difference between the angle θ2 and the true north direction is θ;

[0039] Shortest path distance score calculation steps: Calculate the shortest path distance score Among them, d path For the line P′ i-1 P i The length and point P' i To point P' i-1 The difference in the shortest path distance through the road network, D2 is the preset distance threshold.

[0040] The present invention also provides an online road matching device based on Beidou positioning, which adopts the online road matching method based on Beidou positioning as described above, and the device includes:

[0041] Initial screening module: used to collect Beidou positioning data of each positioning point in the vehicle trajectory in real time, filter the positioning points based on preset filtering conditions, and select qualified positioning points;

[0042] Candidate road section selection module: for the qualified positioning points, using the geohash search algorithm and topological search to complete the real-time search of the candidate road section set;

[0043] Candidate road segment scoring module: used to score each candidate road segment in the candidate road segment set in real time and output the real-time scoring result of each candidate road segment;

[0044] Target matching module: used for selecting the optimal current matching segment and current matching point based on the real-time scoring results of each candidate segment and the preset result selection strategy. The current matching point is connected in series with the previous matching point to form a complete trajectory, thereby realizing real-time matching of the online road.

[0045] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the above-mentioned online road matching method based on Beidou positioning.

[0046] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the steps of the above-mentioned online road matching method based on Beidou positioning are implemented.

[0047] The beneficial effects of this method invention are:

[0048] 1) In the process of searching for candidate road segments, the present invention adopts the method of geohash index plus topological search. Compared with the traditional method of querying road segments within a certain distance near the positioning point, the distance calculation search process is reduced, thereby improving the search speed;

[0049] 2) The present invention adds topology search as a supplement, which can successfully find the correct road segment to add to the candidate when the positioning point offset is large, making up for the situation where the candidate edge search is incorrect due to the distance between the positioning point and the correct road segment being too large when setting a specific distance search;

[0050] 3) The present invention can achieve real-time generation of positioning point matching results by scoring candidate road sections for each positioning point in real time.

[0051] Advantages of additional aspects of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0053] Figure 1Schematic diagram of HMM model in the prior art;

[0054] Figure 2 Schematic diagram of Viterbi solution to HMM problem in the prior art;

[0055] Figure 3 It is a schematic diagram of geohash in the prior art;

[0056] Figure 4a This is a conceptual diagram of a road section in the prior art;

[0057] Figure 4b It is a conceptual schematic diagram of another road section in the prior art;

[0058] Figure 5 Schematic diagram of the process of an online road matching method based on Beidou positioning according to an embodiment of the present invention;

[0059] Figure 6a This is a schematic diagram of a road network storage form in the prior art;

[0060] Figure 6b This is a schematic diagram of another road network storage form in the prior art;

[0061] Figure 7 A schematic diagram of a single-point matching process according to an embodiment of the present invention;

[0062] Figure 8 This is a schematic diagram of the overall matching process shown in an embodiment of the present invention;

[0063] Figure 9 This is a schematic diagram of the process of filtering positioning points according to an embodiment of the present invention;

[0064] Figure 10 This is a schematic diagram of geohash search shown in an embodiment of the present invention;

[0065] Figure 11 A schematic diagram of obtaining a path for a candidate edge as shown in an embodiment of the present invention;

[0066] Figure 12 This is a schematic diagram of the matching process for the first scoring point shown in an embodiment of the present invention;

[0067] Figure 13 This is a schematic diagram of scoring other positioning points shown in an embodiment of the present invention;

[0068] Figure 14 Schematic diagram of a module of an online road matching device based on Beidou positioning according to another embodiment of the present invention. DETAILED DESCRIPTION

[0069] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.

[0070] The present invention aims to solve the problem:

[0071] 1) Large deviations in trajectory points can easily lead to incorrect matching results or interruptions: Most matching algorithms select road segments within a certain distance of the anchor point as candidate edges for subsequent matching. When the anchor point deviates beyond the set candidate segment selection range, it may be impossible to add the correct edge to the candidate edge selection. The present invention uses a geohash search combined with a topological search to select candidate edges, accurately finding road segments that are connected to the previous matching segment but are significantly deviated from the anchor point.

[0072] 2) Online real-time matching will have a certain delay, and completely real-time matching may cause incorrect matching results due to the deviation of the current point when the subsequent point is unknown. Therefore, a method that can perform online real-time matching with high accuracy is needed: the present invention can generate positioning results for each positioning point in real time through a road segment scoring mechanism. At the same time, in order to prevent matching errors, a skipping strategy is added. When the positioning point is between two forks in the road, the subsequent point is used to determine the actual position of the vehicle.

[0073] The definitions of abbreviations and key terms related to the present invention are as follows:

[0074] HMM: hidden Markov model, hidden Markov model.

[0075] Redis: A NoSQL database that is a key-value storage system.

[0076] Neo4j: A high-performance graph database that stores data in a network structure consisting of edges and nodes.

[0077] Geohash value: a string that encodes the two-dimensional data of longitude and latitude. The algorithm divides the earth into multiple rectangular blocks, each of which has a unique geohash value. The coordinates within the rectangular block all have the same geohash value, such as Figure 3 As shown in the figure, the more bits the geohash has, the smaller the rectangular blocks will be.

[0078] Positioning point: A Beidou positioning point consists of the current latitude and longitude coordinates and timestamp, P is the set of all trajectory points, that is, p i =(loni ,lat i ,timestamp i )∈Ρ。

[0079] Trajectory: A trajectory is a sequence of positioning points of the same vehicle in chronological order, i.e. T = p1, p2, ..., p k , k is the number of positioning points in the trajectory.

[0080] Section: a section e i It is the smallest edge unit in the road network, which refers to the straight line edge in the road network that does not intersect with other road sections except at the two ends, including the starting point ID, end point ID, length, starting and ending point coordinates, whether it is a one-way street, etc., that is, e i =(start i ,end i ,length i ,oneway i ,geometry i ), where geometry is a list of coordinates of the endpoints through which the edge passes.

[0081] Simplified road segment: a simplified road segment s_e i Refers to an edge in a road network that does not intersect with other road segments except at its ends, and is composed of one or more road segments. The information of a simplified road segment is the same as that of a road segment, but the geometry is a list of coordinates consisting of all the endpoints of the road segment in the simplified road segment. As shown in Figure 4, for a curved road, the entire curve is a simplified road segment (Figure 4(a)), which is composed of multiple road segments (Figure 4(b)). Among them, the road segment is used for specific matching, and each positioning point corresponds to a matching road segment. The simplified road segment is used for topology search and shortest path search to improve computational efficiency.

[0082] Road network: A road network is a directed graph G(V,E), where G is a set of vertices, V is a set of endpoints of simplified road segments, and E is a set of simplified road segments.

[0083] An online road matching method based on Beidou positioning according to an embodiment of the present invention is as follows: Figure 5 As shown, the method includes:

[0084] Initial screening step S10: collecting Beidou positioning data of each positioning point in the vehicle trajectory in real time, filtering the positioning points based on preset filtering conditions, and screening out qualified positioning points;

[0085] Candidate road section selection step S20: for qualified positioning points, a real-time search of a set of candidate road sections is performed by combining a geohash search algorithm and a topological search;

[0086] Candidate road segment scoring step S30: scoring each candidate road segment in the candidate road segment set in real time, and outputting the real-time scoring result of each candidate road segment;

[0087] Target matching step S40: Based on the real-time scoring results of each candidate road segment, the optimal current matching road segment and current matching point are selected based on the preset result selection strategy. The current matching point is connected in series with the previous matching point to form a complete trajectory, thereby realizing real-time matching of the online road.

[0088] Preferably, the above-mentioned initial screening step S10 includes:

[0089] Average speed calculation steps: Calculate the average speed of the positioning point;

[0090] Filter positioning point steps: if the distance between the positioning point and the previous matching point is less than the preset minimum distance, the positioning point is skipped; if the average speed is greater than the preset limit speed, the positioning point is skipped; output the filtered qualified positioning points.

[0091] Preferably, the candidate road section selection step S20 includes:

[0092] Geohash value calculation steps: The geographical area centered on the positioning point is divided into nine rectangular areas, and the unique geohash value of each rectangular area is calculated;

[0093] Perpendicular line screening step: based on the geohash value, the candidate road segments to be screened are searched, and it is determined whether the foot of the perpendicular line from the positioning point to each candidate road segment to be screened is on the candidate road segment to be screened. If so, the candidate road segment to be screened is included in the set of candidate road segments;

[0094] Topology search step: Based on the preset upper limit distance of the topology search, the end point of the matching road segment of the previous positioning point is added to the queue to be searched, and the corresponding simplified road segment stored in the graph database is searched. It is determined whether the perpendicular foot of the positioning point and each road segment in the simplified road segment is on the road segment. If so, the road segment is added to the candidate road segment set. After iteratively searching the search queue, the candidate road segment set that has passed the topology search is output;

[0095] Deduplication step: Based on the candidate road segment set that has undergone vertical line screening and topological search, deduplication is performed and the final candidate road segment set is output.

[0096] Preferably, the candidate road segment scoring step S30 includes:

[0097] First positioning point scoring step: After a first screening based on the angle between the vehicle's travel direction and each candidate road segment, the vertical distance from the positioning point to each candidate road segment is calculated. The shortest road segment corresponding to the shortest vertical distance is selected, and the foot of the positioning point on the shortest road segment is the matching point.

[0098] Subsequent positioning point scoring steps: Based on the matching point and matching road segment information of the previous positioning point, the vertical distance score, angle score and shortest path distance score are calculated for each candidate road segment in the candidate road segment set, and the weighted sum of each score is calculated as the comprehensive score of the candidate road segment.

[0099] Preferably, the target road section matching step S40 includes:

[0100] Sorting and evaluation step: sort each candidate road segment according to the comprehensive score, calculate the difference between the highest score and the second highest score and compare it with the preset minimum value, and skip the positioning point if the difference is less than the preset minimum value;

[0101] Matching step: If the current positioning point is the last positioning point or the score difference is greater than the threshold, the corresponding road segment with the highest comprehensive score is selected as the target matching road segment, and the shortest path distance is supplemented to fill the path between the current matching point and the previous matching point.

[0102] Preferably, the topology search step includes:

[0103] Initialization step: read the matching road segment information of the previous positioning point, and determine the upper limit distance of the topology search and the positioning points in the search queue;

[0104] Iterative topology search steps: For each positioning point in the search queue, search the graph database for a simplified road segment with the qualified positioning point as the starting point, and the perpendicular line from the positioning point to the starting and ending points of the simplified road segment. Determine whether the foot of the perpendicular line is on the connecting line. If so, determine whether the foot of the perpendicular line between the positioning point and each road segment in the simplified road segment is on the road segment. If so, add the road segment to the candidate road segment set. Otherwise, continue the topology search for the next qualified positioning point until the search queue is completed.

[0105] Preferably, the subsequent positioning point scoring step includes:

[0106] Vertical distance score calculation steps: Calculate vertical distance score Among them, d ⊥ is the vertical distance between the current positioning point and the candidate road section, and D1 is the preset vertical distance threshold;

[0107] Angle score calculation steps: Calculate the angle score s2(θ) = |cos(θ)|, where the current positioning point is P i , the previous matching point is P′ i-1 , current positioning point P i The foot of the perpendicular on the candidate road segment is the matching point P′ i , connecting line P′ i-1 P iAngle θ1 with the north direction and the connecting line P′ i-1 P′ i The difference between the angle θ2 and the true north direction is θ;

[0108] Shortest path distance score calculation steps: Calculate the shortest path distance score Among them, d path For the line P′ i-1 P i The length and point P' i To point P′ i-1 The difference in the shortest path distance through the road network, D2 is the preset distance threshold.

[0109] The following describes in detail the specific embodiments of the present invention with reference to the accompanying drawings:

[0110] 1. Beidou positioning trajectory data acquisition

[0111] Beidou positioning trajectory data is collected by vehicle-mounted Beidou positioning terminals. By acquiring positioning data collected and regularly uploaded by the terminal and parsing it according to the protocol format, Beidou positioning data can be obtained. Positioning data includes latitude and longitude information, timestamps, and basic vehicle information. The positioning data for the same vehicle, sorted by time, constitutes the Beidou positioning trajectory.

[0112] 2. Road network preprocessing

[0113] The road network is an abstract form of urban roads, where roads are edges and intersections between roads are points, which together constitute the road network. The purpose of road matching is to match the trajectory positioning point to a specific road, that is, an edge of the road network, and calculate the actual location of the trajectory point accordingly. Therefore, road network-related data is required for calculation in the road matching algorithm. The road network preprocessing step targets urban road network data, adds some information to the ordinary road network data, and stores the road network data in a specific format to improve the efficiency of reading the road network data during matching. Figure 6a It shows how the pre-processed road network is stored. Figure 6b The road network storage format includes the following steps:

[0114] 1) Extract edge and point information from simplified road network data.

[0115] 2) Save the point ID and coordinates as a node in the neo4j database.

[0116] 3) Store each edge (simplified road section) as a point-to-point relationship in the neo4j database, and save information such as the edge length and type.

[0117] 4) Extract edge information from the general road network.

[0118] 5) Calculate the geohash values of the quartiles for each road segment (calculate the geohash at both ends of the road segment and at 1 / 4, 1 / 2, and 4 / 3 respectively).

[0119] 6) Match the simplified road segment ID corresponding to each road segment and store it in the road segment information.

[0120] 7) Use geohash as key and road section information as value to store the road section information in Redis.

[0121] 8) The simplified road section ID is used as the key, and the simplified road section information and the road section information to which it belongs are stored in Redis as the value.

[0122] 3. Road matching algorithm

[0123] The road matching algorithm mainly consists of three parts: candidate edge acquisition, candidate edge scoring, and result selection. Figure 7 Shows the single-point matching process, Figure 8 The overall process of the algorithm is shown. Figure 7 and Figure 8 As shown, the process is:

[0124] Step 1) obtain a Beidou positioning data of the vehicle and determine whether the point is a positioning point that needs to be filtered. If not, proceed to the subsequent steps.

[0125] Step 2) Get the candidate road segments for this point.

[0126] Step 3) Calculate the score of each candidate road segment separately.

[0127] Step 4) Use the result selection strategy to select the final target matching edge.

[0128] Step 5) Concatenate the current matching result with the previous matching result complete travel trajectory of the same vehicle.

[0129] Among them, step 1) needs to filter out extreme abnormal points and dense points. Figure 9 The process of filtering positioning points is as follows:

[0130] 1.1) Calculate the distance between the current positioning point and the previous matching point, divide it by the time between the two points, and get the average speed of the current positioning point.

[0131] 1.2) Determine whether the distance to the previous matching point is too close. If it is less than 150m, skip this point to improve matching efficiency.

[0132] 1.3) Determine whether the speed is greater than the vehicle's speed limit. If so, it indicates that the point is an extreme abnormal point and is skipped.

[0133] Step 2) The selection process of the candidate road section of the positioning point is as follows Figure 10 As shown, the details are as follows:

[0134] 2.1) Calculate all geohash values of the positioning point and the nine-square grid centered on the positioning point. The purpose of the nine-square grid calculation is to avoid the situation where the positioning point and the road section are very close but belong to two geohash values. Figure 10 As shown in the figure, the points are positioning points and the lines are road segments. If only the geohash value of the positioning point is used for retrieval, the road segments in the figure cannot be retrieved.

[0135] 2.2) Read the road segments with the same geohash values calculated in 2.1) from the database as candidate road segments to be screened.

[0136] 2.3) Further filter the road segments in 2.2 by:

[0137] 2.3.1) Draw a perpendicular line from the positioning point to the road section.

[0138] 2.3.2) Determine whether the foot of the perpendicular is on the road segment. If it is on the road segment, add it to the candidate road segment set; if it is outside the road segment, delete it.

[0139] 2.4) If the anchor point is not the first anchor point, then combine the matching information of the previous anchor point to perform a topological search:

[0140] 2.4.1) Read the matching road segment information of the previous positioning point.

[0141] 2.4.2) Calculate the distance from the current positioning point to the midpoint of the previous positioning segment as the upper limit distance of the topology search.

[0142] 2.4.3) Add the end point of the matching road segment of the previous positioning point to the search queue and record the search level of this point as 0.

[0143] 2.4.4) When the queue is not empty, loop execution:

[0144] 2.4.4.1) Get a point from the queue and record the point taken out of the queue as searched.

[0145] 2.4.4.2) Search the graph database for a simplified road segment starting from the point taken from the queue. For each simplified road segment that has not been determined:

[0146] 2.4.4.2.1) Draw a perpendicular line from the positioning point to the line connecting the start and end points of the simplified road section, and determine whether the foot of the perpendicular line is on the line.

[0147] 2.4.4.2.2) If it is on the connecting line, determine whether the foot of the perpendicular between the positioning point and each road segment in the simplified road segment is on the road segment. If so, add the road segment to the candidate road segment set.

[0148] 2.4.4.2.3) If the point is not on the line and the search level is less than 5, compare the distance from the location point to the midpoint of the line connecting the simplified segment with the upper limit distance of the topology search. If the former is smaller, update the upper limit distance to that distance, add the end point of the simplified segment to the queue to be searched, and record the search level of this point as the level of the point removed from the queue + 1.

[0149] 2.5) Remove duplicates from the candidate road segment set and use the result as the final candidate road segment. The overall process of obtaining candidate edges is as follows: Figure 11 shown.

[0150] Step 3) There are two different processes for candidate edge scoring: the scoring process for the first positioning point of the vehicle and the scoring process for non-first positioning points. The matching process for the first positioning point is as follows: Figure 12 shown.

[0151] The scoring and selection process for the first positioning point is as follows:

[0152] 3-1.1) Obtain the first BeiDou positioning data of the vehicle, and when the second positioning data arrives, calculate the vehicle's direction of travel based on the two points.

[0153] 3-1.2) For each road segment in the candidate road segment set:

[0154] 3-1.2.1) If the angle between the direction of the road section and the direction of vehicle travel is obtuse, skip the road section.

[0155] 3-1.2.2) Otherwise, calculate the vertical distance from the first location to the road segment and record the road segment with the shortest distance.

[0156] 3-1.3) Select the shortest segment as the matching segment, and the foot of the perpendicular point of the segment as the matching point.

[0157] For other anchor points, the scoring process is as follows:

[0158] 3-2.1) The last positioning point P is known i matching point P′ i-1 And matching road segment information, for each road segment in the candidate road segment set:

[0159] 3-2.2) Calculate the foot of the perpendicular of the positioning point on the road segment as the matching point P′ i .

[0160] 3-2.3) Calculate the vertical distance d between the positioning point and the road section ⊥, and calculate the vertical distance score

[0161] 3-2.4) Calculate the connection P′ i-1 P i Angle with due north and connecting line P' i-1 P′ i The angle between the north and the south is obtained, and the difference θ between the two is obtained, and the angle score s2(θ)=|cos(θ)| is calculated.

[0162] 3-2.5) Calculate the connection P′ i-1 P i The length of the point P' is calculated using the A* algorithm i To point P' i-1 The shortest path distance in the road network is used to obtain the difference d between the two distances. path , and calculate the shortest path distance score

[0163] 3-2.6) The values of the three scores are all between 0 and 1. Finally, the weighted sum of the three scores is calculated, and the total score is score = w1s1(d ⊥ )+w2s2(θ)+w3s3(d path ), where w1+w2+w3=100.

[0164] Scoring diagram Figure 13 , P′1 is the previous matching point, P2 is the current positioning point, P′ 2-1 and P′ 2-2 are two candidate points respectively. Step 3-2.3) calculates the connection P2P′ 2-1 The length d 1⊥ and connecting P2P′ 2-2 The length d 2⊥ , step 3-2.4 calculates the size of θ1 and θ2, and step 3-2.5 calculates the distance from P′1 to P′ 2-1 The difference between the distance on the road network and the line P'1P2 and the distance from P'1 to P' 2-2 The difference between the distance on the road network and the line P′1P2 is used. Finally, the comprehensive score is calculated using the formula 3-2.6.

[0165] The result selection part of steps 4) and 5) is mainly for non-first positioning points. The result selection is performed after scoring the candidate road sections of the positioning point. The process is as follows:

[0166] 1) Sort the candidate edges by score.

[0167] 2) Compare the difference between the highest score and the second highest score. If the difference is too small, it means that there are two similar candidate road sections for this point. Therefore, it cannot be selected without knowing the next positioning point, so the judgment of this positioning point is skipped.

[0168] 3) If the current positioning point is the last positioning point, or the score difference is greater than the threshold, the road segment with the highest score is selected as the matching road segment, and the shortest path generated during the scoring process is read as the path supplement between the two matching points.

[0169] like Figure 14 As shown, in addition, the present invention provides an online road matching device based on Beidou positioning, the device comprising:

[0170] Preliminary screening module 10: used to collect Beidou positioning data of each positioning point in the vehicle trajectory in real time, filter the positioning points based on preset filtering conditions, and screen out qualified positioning points;

[0171] Candidate road segment selection module 20: for completing real-time search of a set of candidate road segments for the qualified positioning points by combining geohash search algorithm and topological search;

[0172] The candidate road segment scoring module 30 is configured to score each candidate road segment in the candidate road segment set in real time and output a real-time scoring result for each candidate road segment;

[0173] Target matching module 40: for selecting the optimal current matching segment and current matching point based on the real-time scoring results of each candidate segment and a preset result selection strategy, and connecting the current matching point with the previous matching point in series to form a complete trajectory to achieve real-time matching of the online road.

[0174] In addition, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the online road matching method based on Beidou positioning described in any one of the above technical solutions.

[0175] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and runnable on the processor. When the processor executes the program, the steps of an online road matching method based on Beidou positioning described in any one of the above technical solutions are implemented.

[0176] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant description of other embodiments.

[0177] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.

[0178] In the embodiments provided by the present invention, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are merely illustrative. For example, the division of the modules or units is merely a logical function division. In actual implementation, there may be other division methods, 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.

[0179] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0180] In addition, the functional units in the various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0181] If the integrated module / 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.

[0182] Based on this understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, it can implement the steps of the above-mentioned various method embodiments. The computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.

[0183] Compared to existing technologies, this invention utilizes a geohash index combined with topological search, a key technical feature. Furthermore, based on the characteristics of Beidou data, this invention eliminates the step of determining the orientation of the positioning point, as well as the process of determining whether to skip a positioning point based on a threshold, also key technical features of the invention.

[0184] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention, and should all be included in the scope of protection of the present invention.

[0185] The above are merely specific embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and such modifications or substitutions are intended to be within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be subject to the scope of protection of the claims.

Claims

1. An online road matching method based on Beidou positioning, characterized in that: The method comprises: Initial screening step: collect Beidou positioning data of each positioning point in the vehicle trajectory in real time, filter the positioning points based on preset filtering conditions, and select qualified positioning points; Candidate road section selection step: for the qualified positioning points, a geohash search algorithm and a topological search are used to complete a real-time search of a candidate road section set; Candidate road segment scoring step: scoring each candidate road segment in the candidate road segment set in real time, and outputting the real-time scoring result of each candidate road segment; Target matching step: for each candidate road segment, based on the real-time scoring results, the optimal current matching road segment and current matching point are selected based on a preset result selection strategy. The current matching point is connected in series with the previous matching point to form a complete trajectory, thereby achieving real-time matching of the online road; The primary screening step comprises: Average speed calculation step: calculating the average moving speed of the positioning point; Filtering positioning point step: if the distance between the positioning point and the previous matching point is less than a preset minimum distance, the positioning point is skipped; if the average speed is greater than a preset limit speed, the positioning point is skipped; outputting the filtered qualified positioning point; The candidate road section selection step includes: Geohash value calculation step: dividing the geographical area centered on the positioning point into nine rectangular areas, and calculating a unique geohash value for each rectangular area; Perpendicular line screening step: searching for candidate road segments to be screened based on the geohash value, and determining whether the foot of the perpendicular line from the positioning point to each candidate road segment to be screened is on the candidate road segment to be screened; if so, the candidate road segment to be screened is included in the set of candidate road segments; Topology search step: based on the preset upper limit distance of the topology search, the end point of the matching road segment of the previous positioning point is added to the queue to be searched, the corresponding simplified road segment stored in the graph database is searched, and it is determined whether the perpendicular foot of the positioning point and each road segment in the simplified road segment is on the road segment. If so, the road segment is added to the candidate road segment set, the search queue is completed through iterative search, and the candidate road segment set after the topology search is output; Deduplication step: after deduplication based on the candidate road segment set that has been screened by vertical lines and searched by topology, the final candidate road segment set is output; The candidate road segment scoring step includes: The first positioning point scoring step: after a first screening based on the angle between the vehicle's travel direction and each candidate road segment, the vertical distance from the positioning point to each candidate road segment is calculated, and the shortest road segment corresponding to the shortest vertical distance is selected, and the foot of the shortest road segment where the positioning point is located is the matching point; A subsequent positioning point scoring step: based on the matching point of the previous positioning point and the matching road segment information, calculating the vertical distance score, angle score and shortest path distance score for each candidate road segment in the candidate road segment set, and calculating the weighted sum of the scores as the comprehensive score of the candidate road segment; The target matching step comprises: Sorting and evaluating step: sorting each candidate road section according to the comprehensive score, calculating the difference between the highest score and the second highest score and comparing it with a preset minimum value, and skipping the positioning point if the difference is less than the preset minimum value; Matching step: If the current positioning point is the last positioning point or the score difference is greater than a threshold, the corresponding road segment with the highest comprehensive score is selected as the target matching road segment, and the shortest path distance is additionally read to fill in the path between the current matching point and the previous matching point; The subsequent positioning point scoring step includes: Steps to calculate vertical distance score: Calculate vertical distance score ,in, is the vertical distance between the current positioning point and the candidate road section, and D1 is the preset vertical distance threshold; Angle score calculation steps: Calculate the angle score , where the current positioning point is , the previous matching point is , the current positioning point The foot of the perpendicular on the candidate road segment is the matching point , connection Angle from true north 1 and connection Angle from true north The difference between 2 is ; Shortest path distance score calculation steps: Calculate the shortest path distance score ,in, For connection Length and point Arrive The difference in the shortest path distance through the road network, D2 is the preset distance threshold; Finally, the three scores are weighted and summed, and the total score is score= w1 s1(d ⊥ )+w2 s2(θ)+w3 s3(d path ), where w1 +w2 +w3 = 100.

2. The online road matching method based on Beidou positioning according to claim 1, characterized in that: The topology search step includes: Initialization step: reading the matching road section information of the previous positioning point, and determining the upper limit distance of the topology search and the positioning point in the search queue; Iterative topology search step: for each positioning point in the search queue, search the graph database for a simplified road segment with the qualified positioning point as the starting point, and the perpendicular line from the positioning point to the starting and ending points of the simplified road segment, and determine whether the foot of the perpendicular line is on the connecting line; if so, determine whether the foot of the perpendicular line between the positioning point and each road segment in the simplified road segment is on the road segment; if so, add the road segment to the candidate road segment set; otherwise, continue the topology search for the next qualified positioning point until the search of the search queue is completed.

3. An online road matching device based on Beidou positioning, using the online road matching method based on Beidou positioning as claimed in claim 1 or 2, characterized in that: The device comprises: Initial screening module: used to collect Beidou positioning data of each positioning point in the vehicle trajectory in real time, filter the positioning points based on preset filtering conditions, and select qualified positioning points; Candidate road section selection module: for the qualified positioning points, using the geohash search algorithm and topological search to complete the real-time search of the candidate road section set; Candidate road segment scoring module: used to score each candidate road segment in the candidate road segment set in real time and output the real-time scoring result of each candidate road segment; Target matching module: for selecting the best current matching segment and current matching point based on the real-time scoring results of each candidate segment and a preset result selection strategy. The current matching point is connected in series with the previous matching point to form a complete trajectory, thereby achieving real-time matching of online roads. The primary screening step comprises: Average speed calculation step: calculating the average moving speed of the positioning point; Filtering positioning point step: if the distance between the positioning point and the previous matching point is less than a preset minimum distance, the positioning point is skipped; if the average speed is greater than a preset limit speed, the positioning point is skipped; outputting the filtered qualified positioning point; The candidate road section selection step includes: Geohash value calculation step: dividing the geographical area centered on the positioning point into nine rectangular areas, and calculating a unique geohash value for each rectangular area; Perpendicular line screening step: searching for candidate road segments to be screened based on the geohash value, and determining whether the foot of the perpendicular line from the positioning point to each candidate road segment to be screened is on the candidate road segment to be screened; if so, the candidate road segment to be screened is included in the set of candidate road segments; Topology search step: based on the preset upper limit distance of the topology search, the end point of the matching road segment of the previous positioning point is added to the queue to be searched, the corresponding simplified road segment stored in the graph database is searched, and it is determined whether the perpendicular foot of the positioning point and each road segment in the simplified road segment is on the road segment. If so, the road segment is added to the candidate road segment set, the search queue is completed through iterative search, and the candidate road segment set after the topology search is output; Deduplication step: after deduplication based on the candidate road segment set that has been screened by vertical lines and searched by topology, the final candidate road segment set is output; The candidate road segment scoring step includes: The first positioning point scoring step: after a first screening based on the angle between the vehicle's travel direction and each candidate road segment, the vertical distance from the positioning point to each candidate road segment is calculated, and the shortest road segment corresponding to the shortest vertical distance is selected, and the foot of the shortest road segment where the positioning point is located is the matching point; A subsequent positioning point scoring step: based on the matching point of the previous positioning point and the matching road segment information, calculating the vertical distance score, angle score and shortest path distance score for each candidate road segment in the candidate road segment set, and calculating the weighted sum of the scores as the comprehensive score of the candidate road segment; The target matching step comprises: Sorting and evaluating step: sorting each candidate road section according to the comprehensive score, calculating the difference between the highest score and the second highest score and comparing it with a preset minimum value, and skipping the positioning point if the difference is less than the preset minimum value; Matching step: If the current positioning point is the last positioning point or the score difference is greater than a threshold, the corresponding road segment with the highest comprehensive score is selected as the target matching road segment, and the shortest path distance is additionally read to fill in the path between the current matching point and the previous matching point; The subsequent positioning point scoring step includes: Steps to calculate vertical distance score: Calculate vertical distance score ,in, is the vertical distance between the current positioning point and the candidate road section, and D1 is the preset vertical distance threshold; Angle score calculation steps: Calculate the angle score , where the current positioning point is , the previous matching point is , the current positioning point The foot of the perpendicular on the candidate road segment is the matching point , connection Angle from true north 1 and connection Angle from true north The difference between 2 is ; Shortest path distance score calculation steps: Calculate the shortest path distance score ,in, For connection Length and point Arrive The difference in the shortest path distance through the road network, D2 is the preset distance threshold; Finally, the three scores are weighted and summed, and the total score is score= w1 s1(d ⊥ )+w2 s2(θ)+w3 s3(d path ), where w1 +w2 +w3 = 100.

4. 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 online road matching method based on Beidou positioning described in claim 1 or 2 are implemented.

5. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the steps of the online road matching method based on Beidou positioning as described in claim 1 or 2 are implemented.

Citation Information

Patent Citations

  • Map matching method based on road connection relationship

    CN105628033A