A map matching system based on the level set method
By constructing a continuous probability field and combining GPS observations and road priors, a map matching system based on the level set method is developed to optimize the path matching process. This solves the map matching problem of existing technologies under complex road networks and sparse noise conditions, and achieves high-precision and real-time autonomous driving positioning.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-13
- Publication Date
- 2026-03-13
AI Technical Summary
Existing map matching technologies are insufficient in terms of adapting to multiple scenarios, efficient resource utilization, robust matching under complex road networks and noisy data, and balancing accuracy and efficiency. In particular, they are difficult to meet the real-time and robust requirements of high-precision positioning for autonomous driving systems under complex urban road networks, multi-level interchanges, and sparse GPS data conditions.
A map matching system based on the level set method is adopted. By constructing a continuous probability field of the road network, the optimal path mapping of trajectory points is realized by using level set evolution. Combined with GPS observation, road priors and curvature regularization terms, the path matching process is optimized to avoid the combinatorial explosion problem of discrete matching and achieve high accuracy and real-time performance.
It significantly improves the robustness and accuracy of map matching, maintains efficient computation under complex road topology and sparse noise conditions, meets the real-time requirements of high-precision positioning for autonomous driving systems, and provides low-latency and highly reliable trajectory output.
Smart Images

Figure CN121113102B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of autonomous driving technology, and more specifically to a map matching system based on the level set method. Background Technology
[0002] In the field of autonomous driving technology, high-precision maps are a key support for realizing advanced driver assistance systems (ADAS) and fully autonomous driving functions. However, due to factors such as the high cost of producing high-precision maps, limited coverage, and commercial deployment strategies, in practical applications, vehicles often still rely on widely covered conventional maps for navigation planning. Conventional maps, however, lag significantly behind high-precision maps in terms of accuracy, feature completeness, and structure. Therefore, after obtaining the navigation path from a conventional map, it is necessary to map it to a high-precision map coordinate system using map matching technology to generate a high-precision reference path that can be directly used by the autonomous driving system. This process is crucial for achieving a seamless transition from conventional navigation to ADAS functions.
[0003] Existing map matching methods are mostly based on geometric projection, hidden Markov models, or graph search algorithms, aiming to spatially align vehicle trajectories or navigation paths with high-precision road networks. For example, some methods calculate the projected distance between trajectory points and candidate road segments and use dynamic programming or Viterbi algorithms to solve for the optimal path sequence, achieving good results in simple structured road scenarios. However, in complex urban road networks, multi-level interchanges, dense intersections, or long paths, these methods often face problems such as high computational complexity, poor real-time matching, and sensitivity to changes in path topology, making it difficult to meet the stringent requirements of autonomous driving systems for low-latency and high-reliability matching.
[0004] Chinese invention patent application CN202211079336.2, entitled "Map Matching Method, Control Device, Readable Storage Medium, and Driving Device," proposes to determine the current map matching scenario based on navigation information from the driving device and information about the path to be matched. It then dynamically selects asynchronous matching, segmented parallel matching, or segmented real-time matching methods based on the scenario type and whether online computing conditions are met, thereby improving matching efficiency and scenario adaptability. While this patent addresses the problem of a single matching strategy being insufficient to handle diverse scenarios to some extent, its core focus remains on the organization and scheduling of the matching process. It does not deeply optimize underlying core matching capabilities such as robustness under strong noise and sparse sampling conditions, or ambiguity resolution under complex road topologies. Furthermore, its adaptive degradation and recovery mechanisms under dynamically limited resources are still inadequate.
[0005] Chinese invention patent "Map Matching Method, Device, Medium, and Terminal" (CN201811634366.9) aims to improve the accuracy of map matching by simultaneously determining matching points and roads from both ordinary and high-precision electronic map data, and matching points and lanes from both. It then selects the best matching information based on whether the location point is within the matching lane and distance comparison results. While this patent alleviates the problem of matching failure or accuracy degradation in some scenarios due to relying solely on high-precision maps by integrating the matching results of ordinary and high-precision maps, its matching decision-making process relies on loading large amounts of real-time data and multi-dimensional weight calculations. This presents challenges such as high computational and storage costs and difficulty in ensuring real-time performance when the path is long or the road network is complex. Furthermore, it does not fully consider the dynamic impact of different driving scenarios on the matching strategy.
[0006] In summary, existing map matching technologies still have significant shortcomings in terms of adapting to multiple scenarios, efficient resource utilization, robust matching under complex road networks and noisy data, and balancing accuracy and efficiency. There is an urgent need for a new map matching solution that can achieve a better balance between matching accuracy, computational efficiency, scene coverage and system robustness. Summary of the Invention
[0007] To address the problems of matching ambiguity, trajectory breakage, and excessive computational complexity in traditional discrete map matching methods when dealing with GPS data sparsity, noise interference, and complex road topologies, this invention proposes a map matching system based on the level set method. This invention proposes to construct a continuous probability field representation of the road network and realize the optimal path mapping of trajectory points based on level set evolution, which significantly improves the robustness and accuracy of map matching.
[0008] The system includes: a data preprocessing module, a level set probability field initialization module, a level set evolution module based on GPS observation, an optimal path extraction and post-processing module, and a trajectory output and update module;
[0009] The data preprocessing module preprocesses the input raw GPS trajectory data and road network data to obtain the projected GPS point sequence and road prior mask. ;
[0010] The level set probability field initialization module is based on the road prior mask. Construct the symbolic distance function as the initial level set function ;
[0011] The GPS-based level set evolution module iteratively evolves the initial level set function to obtain a convergent level set function. ;
[0012] The optimal path extraction and post-processing module, based on Extract the zero-level set to obtain the initial geometric path, and then perform short branch pruning and B-spline curve fitting on the initial geometric path to obtain a smooth trajectory point sequence of the geometric layer. ;
[0013] Further targeting By implementing a bidirectional projection and graph matching strategy, discrete road segment sequences at the semantic layer are obtained. ; and Composition of map matching results;
[0014] The trajectory output and update module encapsulates the map matching results into structured trajectory objects. Output.
[0015] Furthermore, the data preprocessing module processes the spatial coordinate components of the raw GPS trajectory data. Through map projection function Convert to planar coordinates : ,in, Indicates the time index value. ;
[0016] The projected GPS point sequence is represented as follows: ;
[0017] The data preprocessing module processes the road network data using a map projection function. After conversion, it is then rendered onto a two-dimensional computational grid. Above, generate a binary road prior mask. For grid Each unit in Its value The formula for calculation is: ,in, Represents each unit The center point, E, represents the set of road segment buffer zones.
[0018] Furthermore, the level set probability field initialization module for the mesh... any point on The sign distance function value Calculated using the following formula:
[0019]
[0020] in, Represents a grid any point on to the road boundary The shortest Euclidean distance, , and Representing grids respectively any point on Located inside the road, at the road boundary, and outside the road;
[0021] The initial level set function Through the Gaussian convolution operation yields: ,in, This represents a two-dimensional Gaussian convolution kernel. Indicates: First, regarding The function itself Perform a Gaussian convolution operation, and then use the result after the Gaussian convolution operation. ,exist Take the value at the location and get .
[0022] Furthermore, the iterative evolution of the level set function specifically involves: the GPS-based level set evolution module iteratively evolving the level set function based on the initial level set function. Second-rate, ,when or change norm Less than the set convergence threshold When the iteration ends, the convergent level set function is obtained. ,in, Indicates the time at which When fixed, the level set function Spatial distribution, hour, = .
[0023] Furthermore, the GPS-based level set evolution module achieves this through: Iterative evolution level set, where Indicates the first The next iteration ; This represents the time step that satisfies the CFL stability condition. express gradient value, Indicates the first The composite velocity field of the next iteration ;
[0024] when or change norm Less than the set convergence threshold hour, For convergent level set functions .
[0025] further, The formula for calculation is: ,in, Indicates GPS observation driving term, , The gain coefficient representing the observed driving strength. This represents the standard deviation of GPS observation errors; Indicates the a priori preservation term of the road. , This represents the gain coefficient that indicates the prior maintenance strength. Indicates the attenuation coefficient. Represents a symbolic function; Represents the curvature regularization term. , This represents the regularization strength coefficient. This represents vector differentiation. express The gradient value.
[0026] Furthermore, the optimal path extraction and post-processing module employs an isosurface extraction algorithm to extract the zero-level set: Traverse the zero level set and select the average value from the convergent level set. The candidate path with the value closest to zero and the largest number of GPS points is used as the initial geometric path. The candidate path represents any continuous geometric curve in the zero-level set.
[0027] convergent level set average The formula for calculating the value is: ,in, The convergence level set average value, Indicates the first Candidate paths, express Upper The coordinates of each sampling point , Indicates the total number of sampling points;
[0028] Number of GPS points The formula for calculation is:
[0029] in, This represents a function that calculates the distance between two points. Indicates the distance threshold. Indicates an indicator function;
[0030] Short branch pruning specifically involves removing branches whose length is less than the short branch threshold. The terminal branch.
[0031] Furthermore, the bidirectional projection and graph matching strategy specifically involves: […]. After discretization, it is projected onto the original road network. The above data is used to generate histograms of road segments and frequencies; then, based on these histograms, the original road network is analyzed. The search is performed with the goal of finding connected road segments, resulting in a discrete road segment sequence at the semantic layer. .
[0032] Furthermore, the trajectory output and update module is also suitable for dual-mode trajectory processing, including batch processing and online incremental processing;
[0033] Batch processing specifically involves: when GPS trajectory data is updated, calling the data preprocessing module, the level set probability field initialization module, the GPS observation-based level set evolution module, and the optimal path extraction and post-processing module to generate... and And encapsulate it into a structured trajectory object. Output;
[0034] The online incremental approach specifically involves using the current level set function as the initial level set function when GPS trajectory data is updated, and driving the level set evolution with the newly added GPS trajectory data.
[0035] The beneficial effects of the system described in this invention are as follows:
[0036] (1) The system described in this invention expresses the road prior and observation uncertainty in a unified manner through a continuous probability field, and uses the evolution of level sets to naturally handle path topology changes, thus avoiding the combinatorial explosion problem of discrete matching.
[0037] (2) The system described in this invention achieves the organic integration of GPS observation, road constraints and spatiotemporal consistency by introducing a multi-component velocity field design.
[0038] (3) The system described in this invention effectively suppresses unreasonable turns and ensures trajectory smoothness based on curvature regularization path optimization. While maintaining theoretical rigor, the system has strong robustness to sparse noise data and can meet the real-time requirements of high-precision positioning for autonomous driving systems.
[0039] (4) The core advantages of the system described in this invention compared to traditional map matching methods based on Hidden Markov Models or graph search are: it uniformly expresses road priors and observation uncertainties through a continuous probability field, and uses level set evolution to naturally handle path topology changes, avoiding the combinatorial explosion problem of discrete matching; it introduces a multi-component velocity field design to achieve the organic integration of GPS observation, road constraints, and spatiotemporal consistency; and its path optimization based on curvature regularization effectively suppresses unreasonable turns and ensures trajectory smoothness. While maintaining theoretical rigor, this method has strong robustness to sparse noise data and can meet the real-time requirements of high-precision positioning for autonomous driving systems. Attached Figure Description
[0040] Figure 1 This is a flowchart illustrating the multi-mode processing and data flow described in this invention.
[0041] Figure 2 This is a detailed diagram illustrating the level set evolution driving mechanism described in this invention;
[0042] Figure 3 This is a flowchart of the path post-processing and association decision-making process described in this invention. Detailed Implementation
[0043] The technical solution of the present invention will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0044] This embodiment provides a map matching system based on the level set method. The system constructs a level set initialization field in the form of a signed distance function based on prior road network data, transforming discrete road information into a probability distribution representation in continuous space. Subsequently, a level set evolution mechanism integrating multi-source observation information is designed, where the velocity field includes GPS observation driving terms, road prior preservation terms, and spatiotemporal consistency constraint terms. The dynamic update of the level set function is controlled by partial differential equations to achieve adaptive optimization of the probability field. Based on this, zero level sets are extracted from the converged level set function as optimal path candidates, and curvature regularization and multi-scale verification are used to ensure the rationality and continuity of the paths. To meet the needs of different application scenarios, this invention designs a dual-mode mechanism for both data processing and result publishing: at the system operation level, it supports a "batch processing mode" for historical data and an "online incremental mode" for real-time applications; at the data output level, it provides low-latency "asynchronous streaming output" and globally consistent "periodic snapshot output." Its overall architecture and multi-mode data processing flow are as follows: Figure 1 As shown.
[0045] The system includes: a data preprocessing module, a level set probability field initialization module, a level set evolution module based on GPS observation, an optimal path extraction and post-processing module, and a trajectory output and update module;
[0046] The data preprocessing module is responsible for standardizing the input raw GPS trajectory data and road network data to unify the spatial reference, eliminate noise, and construct a computational grid, providing an accurate and consistent input basis for the subsequent construction and evolution of the level set probability field.
[0047] The following explanation uses a typical vehicle trajectory map matching scenario. Assume a vehicle is traveling through an urban road network, and its onboard GPS device records a sequence of trajectory points that is noisy and sparse in overpass areas. ,in, Indicates the first Latitude and longitude coordinates recorded at all times Indicates the time index value. ; This represents the total number of times in the input GPS trajectory point sequence. The value is determined based on the input GPS trajectory point sequence. This trajectory exhibits significant deviations from the road network on the electronic map, especially at complex intersections, making it difficult to directly determine its true path.
[0048] The core inputs to the data preprocessing module also include: road network data in vector format. ,in, Represents road network nodes (intersections and turning points). It represents the directed or undirected road segments connecting nodes, forming a topological description of the driving environment.
[0049] First, coordinate system unification and gridding are required: The original GPS data uses the WGS-84 geographic coordinate system, while road network data may exist in different projected coordinate systems. To achieve accurate spatial calculations, all data must be transformed to the same projected coordinate system (such as UTM): For any GPS point... We take its spatial coordinate components Through map projection function Convert it to planar coordinates :
[0050] (1)
[0051] The projected GPS point sequence is as follows: .
[0052] Road network all nodes This projection transformation is then performed similarly. Subsequently, the target processing region is defined and discretized into a regular two-dimensional computational grid. The grid is composed of It consists of 1 unit, each unit Corresponding geographical region:
[0053] (2)
[0054] in For grid The coordinates of the lower left corner of the region For grid Resolution, resolution This is a key adjustable parameter, and its selection requires a trade-off between computational efficiency and map matching accuracy requirements, typically ranging from 5 to 20 meters. In this embodiment, it is set as follows: Meters, this value is within the experimentally verified optimal range (5 to 20 meters). If While the meter-sized grid retains high geometric detail, its excessively large computational grid leads to a significant increase in the computational load for subsequent level set evolution, resulting in decreased real-time performance. A resolution of 10 meters would result in an overly coarse mesh, unable to accurately depict the fine structures of interchange ramps, significantly reducing matching accuracy. Using a 10-meter resolution effectively balances computational efficiency and accuracy requirements.
[0055] Secondly, the prior road information is rasterized. This involves transforming the discrete road network... Render to computational grid Above, generate a binary road prior mask. For grids Each unit in Its value It is determined by the following formula: where, E represents the center point of each unit, and E represents the set of (segment) buffer zones;
[0056] (3)
[0057] The buffer width can be set according to the road grade, for example, 15 meters for highways and 10 meters for urban arterial roads, to more accurately reflect the actual physical width of the road and its occupancy in the grid. This road prior mask. This is the fundamental basis for subsequently constructing the initial field of the level set.
[0058] Finally, the data preprocessing module outputs to the computational grid. Strictly aligned, coordinate system-unified data: projected GPS point sequence and road prior mask These high-quality normalized data lay a solid foundation for the initialization of the level set probability field, which is a key prerequisite for the system described in this invention to achieve high-precision map matching.
[0059] The level set probability field initialization module is responsible for transforming the preprocessed discrete road prior information into a continuous probability field rich in geometric information. This field will serve as the initial state and structural constraints for subsequent evolution processes. The core task of this module is to construct a signed distance function as the initial level set function, embedding the topological and geometric attributes of the roads into a continuous computational space.
[0060] First, based on the road prior mask Calculate the symbolic distance function. For the computational grid... Let any point on the plane have rectangular coordinates as... Sign distance function In computational grid The following definition applies to each unit: The value represents the Euclidean distance from the center point of the cell to the nearest road boundary, and is assigned a sign depending on whether it is located inside or outside the road. Specifically, for the grid... any point on The sign distance function value It is given by the following formula:
[0061] (4)
[0062] in Point to the road boundary (Right now The shortest Euclidean distance from 0 to 1 or from 1 to 0. The area is defined as inside the road. The region is defined as outside the road. This calculation can be implemented using an efficient Gaussian distance transform algorithm. The resulting... This constitutes an ideal initial interface with a zero level set. It accurately represents the road boundary. The gradient is negative inside the road and positive outside, while the gradient of the function itself is... The property that the value is always equal to 1 in most regions provides an important guarantee for subsequent stable evolution.
[0063] Considering the accuracy errors in actual road network data and the reliability differences between roads of different grades, this invention further models the uncertainty and enhances the prior knowledge of the initial symbolic distance function. This is achieved through... Performing Gaussian convolution smooths the initial field and blurs the absolute road boundaries, thus creating a probabilistic transition zone in the boundary region, rather than an "either / or" step change. This process directly yields the initial level set function for subsequent evolution:
[0064] (5)
[0065] in, This represents a two-dimensional Gaussian convolution kernel. express Standard deviation in the spatial domain. It can be set to the standard deviation of GPS observation error. Related, for example , This is a scaling factor, ensuring that the uncertainty of the map prior matches the uncertainty of the sensor observations in magnitude. In this embodiment, it is based on the measured GPS error standard deviation. Rice, take ,in It is within the optimal range (1.0 to 1.5). In formula (5), Indicates: First, regarding The function itself Perform a Gaussian convolution operation, and then use the result after the Gaussian convolution operation. ,exist Take the value at the location and get .
[0066] The above operations construct a probabilistic transition zone at the road boundary, giving the system of this invention a certain degree of tolerance for map deviations and lateral vehicle offsets. If If too small, the transition zone is narrow, the path constraint is too strong, and the flexibility is insufficient; if If the mask is too large, the transition zone will be too wide, weakening the prior constraints and making it prone to deviation when GPS data quality is poor. Furthermore, to reflect the prior confidence levels of different road grades, the original mask can be modified before Gaussian convolution. Weighting can be applied, for example, giving highways a higher weight and rural roads a lower weight, so that high-grade roads have a more significant and stable "attraction" ability in the initial field.
[0067] Finally, the level set probability field initialization module outputs an optimized and uncertainty-modeled initial level set function. This function not only accurately encodes the geometric topology of the road network but also incorporates a quantitative assessment of the reliability of prior knowledge through smoothing processes. This lays a solid foundation for a level set evolution process that can robustly respond to GPS observations while faithfully reflecting the basic structure of the road network. The quality of this initial field directly determines the rationality and accuracy of subsequent matching results.
[0068] The GPS-based level set evolution module is the core component of the system described in this invention for achieving high-precision map matching. Its task is to drive the dynamic evolution of the initial level set probability field, enabling the final zero level set to optimally fit the vehicle's actual driving path while considering both prior constraints of the road network and the physical rationality of the trajectory. This process is achieved by solving a partial differential equation controlled by GPS observation data, prior road knowledge, and geometric smoothness constraints.
[0069] The evolutionary process follows the basic framework of the standard level set evolution equation, the core expression of which is:
[0070] (6)
[0071] in It is over time and space The changing level set function. At the start of evolution. Its initial conditions are It is a velocity field defined on the computational grid, which determines the evolution velocity and direction at each point in the level set interface, i.e., the zero level set. It is a level set function The spatial gradient magnitude. In specific implementations, to clearly distinguish the spatiotemporal characteristics of level set functions, the system described in this invention adopts the following notation conventions: This represents the complete spatiotemporal dependency function, while This indicates at a fixed time. The spatial distribution of level set functions, this distinction will provide significant convenience in the formulation of spatial derivative calculations.
[0072] The essence of formula (6) is to make the interface of the level set move along its normal direction with a velocity. Motion. To achieve accurate and robust path inference, the system described in this invention designs a composite velocity field. It consists of three cooperating components: GPS observation driving term Road prior maintenance item and curvature regularization term ,Right now .
[0073] GPS observation driver This is the main driving force of the evolution process, its role being to transform the spatial location information of GPS trajectory points into an attractive force on the level set interface, drawing the level set interface towards the GPS observation point. This term is constructed as a Gaussian potential energy field centered on the GPS point, with its intensity decreasing with distance. For the preprocessed GPS sequence any point in The driving field it generates is in the form of a Gaussian function. For the entire preprocessed GPS sequence transformed to a planar coordinate system... The driving term is a linear superposition of the contributions from each point, specifically expressed as:
[0074] (7)
[0075] in, The gain coefficient representing the observed driving strength. This is used to control the degree of influence of GPS data on the evolutionary process; The standard deviation of GPS observation error determines the spatial scale of the influence range of each GPS point. This term causes the level set function to decrease in value ("dipping") in areas where GPS points are densely packed, thus guiding the zero level set to converge towards these areas.
[0076] Road prior maintenance item Its role is to act as a structured constraint, preventing the evolutionary process from deviating excessively from the known road network. Based on prior road knowledge, it generates road constraints, enhancing the algorithm's robustness when GPS data is extremely sparse or noisy. This term is designed to be related to the initial level set function. The associated resilience provides resilience towards the initial road interface:
[0077] (8)
[0078] in, This represents the gain coefficient that indicates the prior maintenance strength. ; Indicates the attenuation coefficient. It controls the rate at which the restoring force decays with distance from the initial interface; The sign function is defined by the fact that when the evolution interface deviates from the initial road interface, this term will generate a force that pulls it back to the initial interface. The further the deviation, the stronger this force becomes (but it is modulated by exponential decay), thus effectively constraining the path search range within a reasonable road space.
[0079] Curvature regularization term The aim is to improve the geometric smoothness of the evolution interface, suppress noise and non-physical topological changes (such as the generation of small burrs or voids), and ensure that the final extracted path is smooth and reasonable. This term relates to the curvature of the level set function. Proportional:
[0080] (9)
[0081] This formula is the theoretical definition of the curvature term, where, This represents the spatial distribution of the level set function at the current time. This represents the regularization strength coefficient. , This represents vector differentiation operations; in the subsequent numerical implementation, curvature... Based on the current time step level set function Perform calculations. Curvature The value is positive at convex areas and negative at concave areas. This term causes high-curvature convex regions to contract inward and high-curvature concave regions to expand outward. By calculating the interface curvature, a smoothing force is generated, ultimately smoothing the entire interface. Its effect is similar to minimizing the total curvature of the interface under the action of surface tension.
[0082] The above consists of multi-source information ( , and The level set evolution mechanism driven by ) has the following core principles and iterative process as follows: Figure 2 As shown.
[0083] Gain coefficients The proportions are crucial. This embodiment uses the optimal proportions that have been tested extensively. Under this configuration, GPS observations serve as the primary driver, road priors provide reliable constraints in sparse regions, and curvature terms ensure path smoothness. The evolution process is numerically solved using the finite difference method until the maximum number of iterations or the convergence threshold is met. The final convergence field is obtained. Its zero-level set has formed a smooth "valley line" that closely matches the GPS points and follows the road network topology.
[0084] In terms of numerical solution, the evolution equations are discretized using the finite difference method. To clearly describe the numerical implementation, a discrete time step is defined. The level set function on is ,Right now The gradient term is discretized using an explicit Euler scheme in time and an upwind difference scheme in space. This ensures the numerical stability of the computation. The evolution process occurs in discrete time steps. In progress, among which This refers to the time step that satisfies the CFL (Convergence Fact Check) stability condition. CFL is a convergence criterion used in computational fluid dynamics to determine the convergence of a computation. Specifically, the dependency domain of the difference equation must contain the dependency domain of the corresponding differential equation. In its simplest form, this can be understood as the solution speed during time progression must be greater than the speed of physical disturbance propagation; only in this way can all physical disturbances be captured. Each iteration includes the following calculations: First, based on... Level set function at time Calculate the velocity field and gradient Then, the entire field is updated using formula (10):
[0085] (10).
[0086] The evolution process continues until the preset maximum number of iterations is reached. ( or the change norm of the level set function Less than the set convergence threshold In this embodiment At this point, the level set function is considered to have converged, and the evolution process terminates. For convergent level set functions (Total probability field) The size of the computational grid and the convergence threshold are preset, typically between 200 and 1000.
[0087] The optimal path extraction and post-processing module undertakes the crucial task of transforming the evolved, converged continuous probability field into a discretized, structured path sequence that can ultimately be used by downstream systems. This module aims to extract the optimal path from the final level set function. This module accurately reconstructs the most likely path for vehicles, ensuring its topological correctness, geometric smoothness, and consistency with prior road network data. The quality of this processing directly determines the output quality of the entire map matching algorithm. To achieve this goal, this module follows a detailed processing flow that includes geometric extraction and semantic association, such as... Figure 3 As shown.
[0088] The first step in path extraction is to extract the evolutionary convergent level set function. The system identifies candidate paths representing the center of the road. The system described in this invention employs an isosurface extraction algorithm, specifically a two-dimensional variant of the moving cube algorithm—the moving square algorithm—to accurately extract contour lines with a function value of zero, i.e., the zero-level set. The above square algorithm calculates the value by traversing the computational grid. For each cell in the algorithm, the intersection points of the isosurface and cell edges are determined by linear interpolation based on the combination of positive and negative signs of the function values at the cell vertex. These intersections are then connected to form one or more continuous polylines composed of vertices. These polylines constitute the geometric representation of the candidate paths. In this embodiment, two main candidate paths were extracted in a complex interchange area. and .
[0089] Due to the evolutionary nature of level sets, the extracted zero-level set may be a continuous main path, or it may generate several transient branches at complex intersections or areas with sparse GPS data. To handle the potential multi-branch situation, the system described in this invention evaluates each candidate path using the following two quantitative indicators. The rationality ( The index value represents the candidate path. ): convergence level set average Value and number of GPS points;
[0090] convergent level set average The value is calculated using formula (11) for all candidates on each path. Mean of function values at each sampling point:
[0091] (11)
[0092] The system described in this invention uses The value of is used to evaluate the rationality of the path. The closer this value is to zero, the closer the path is to the "valley" of the probability field, and the higher the confidence level. , This represents the index value of the sampling point on each candidate path. This represents the coordinates of the sampling points on each candidate path;
[0093] In this embodiment, the result is obtained by formula (11). , . The value is closer to zero, indicating that it is located at the "bottom" of the probability field.
[0094] The number of GPS points is calculated using formula (12) to determine the distance path. a certain distance threshold Total number of GPS track points within:
[0095] The system described in this invention uses The value is used to quantify the degree of agreement between the path and the observed data, where This is an indicator function that returns 1 if the condition is true and 0 otherwise. This represents a function that calculates the distance between two points; in this embodiment, a distance threshold is used. Within meters, statistics were obtained There are significantly more nearby GPS points.
[0096] The system described in this invention comprehensively considers the above two indicators and selects the convergence level set average. The path with the value closest to zero and the most GPS points is selected as the optimal main path. For average The path with the value closest to zero and the most GPS points is therefore determined as the primary path (initial geometric path).
[0097] After obtaining the initial geometric path, topology cleaning and optimization, i.e., geometric optimization, must be performed to eliminate small, meaningless branches caused by noise or computational errors, and to ensure the connectivity and rationality of the path. The system described in this invention applies skeletonization and branch pruning operations from mathematical morphology. Skeletonization refines the path to a single pixel width without altering its topology, eliminating variations in contour thickness. Subsequently, branch pruning identifies and removes branches shorter than a branch threshold. The terminal branches are typically unstable structures generated during evolution rather than true paths. In this embodiment... meters, within the optimal range ( This process effectively eliminates spurious branches (length < 40 meters) generated by numerical calculations, while retaining practically meaningful short-distance road structures (such as ramps). This process can be iterated until the path network stabilizes. For the main path itself, to further improve its smoothness and conformity to vehicle kinematics, B-spline curve fitting is used for smoothing. A B-spline curve is defined by a set of control points and a node vector. Its curve shape is indirectly affected by the control points, and the changes are limited to local variations. This allows it to effectively smooth noise without drastic deformation due to fluctuations in individual data points, ensuring the stability of the fitting. Given the extracted (sampled) discrete path point set... ( (Representing the sampling points on each candidate path), a cubic B-spline curve is fitted using the least squares method. This allows the curve to approximate the original point while possessing second-order continuity. (Continuous) means that the fitted path is continuous in curvature, which is more in line with the actual motion pattern of the vehicle, thus obtaining a smooth and natural vehicle trajectory (smooth geometric trajectory).
[0098] The geometrically optimized continuous path needs to be mapped back to the original discrete road network to generate a specific road segment sequence.
[0099] The system described in this invention employs a bidirectional projection and graph matching strategy. First, it designs a system that combines projection and graph matching. Discretize the data into dense sampling points and project each point onto the original road network. Go up and find the nearest section of road. The road segments to which all sampling points are projected and their frequencies are statistically analyzed, forming a road segment-frequency statistical histogram. Subsequently, based primarily on this histogram and considering the connectivity between road segments, the road network map is... Perform an optimal path search. The goal of this search is to find a sequence of connected path segments. This ensures that the sequence best matches the projection statistics spatially and is topologically connected. This can be achieved by constructing a cost function that considers the projection frequency of road segments as weights while penalizing path jumps (i.e., non-adjacent road segments in the sequence) and solving it using dynamic programming or the A* algorithm. This step ensures that the final output not only geometrically approximates GPS observations and probability field inferences but also strictly adheres to the topological rules of the real road network, representing a physically feasible and legal path.
[0100] Finally, the optimal path extraction and post-processing module outputs a structured map matching result. This result contains two levels of information: the first is a smooth trajectory point sequence at the geometric level. The first part contains high-precision planar coordinates, suitable for visualization or precision-sensitive applications requiring continuous coordinates; the second part is a discrete road segment sequence at the semantic layer. The information, including the entrance / exit points on each road segment, directly corresponds to map data, facilitating road network-based navigation, guidance, and traffic analysis. These two representations together constitute the final output of the system described in this invention, providing comprehensive and reliable positioning input for the decision-making and planning module of the autonomous driving system. In this embodiment, the output sequence accurately corresponds to the vehicle's actual driving behavior of "going straight - turning right - entering the ramp."
[0101] Trajectory Output and Update Module
[0102] As the final stage of the entire map matching process, the trajectory output and update module bears the crucial responsibility of transforming optimized path information into standardized, interpretable, and directly usable structured data for downstream tasks. It also manages the system's state maintenance and incremental update mechanisms under different operating modes. The module's design fully considers the multiple requirements of autonomous driving systems for data real-time performance, integrity, and reliability, aiming to provide a trajectory output solution that combines low latency and high reliability.
[0103] The structured encapsulation of output data is a fundamental function of this module. Structured encapsulation refers to constructing a trajectory class, whose fields are the matching results obtained by the path extraction and post-processing module. The system described in this invention encapsulates the matching results into a complete trajectory object. (Final matching result). This trajectory object It contains information from multiple dimensions to ensure a comprehensive description of the target vehicle's spatiotemporal state. Specifically, the trajectory... The core data fields include: real-time updated trajectory confidence. This value integrates the path probability field strength, the goodness of fit between GPS observations and the path, and the smoothness of historical states during the matching process. Its calculation can be expressed as:
[0104] (13)
[0105] in Weighting coefficients ( , and (These represent the weighting coefficients of the corresponding parameters). This represents the function for calculating the average value. The correlation coefficient is used to measure the correlation between two variables. Represents a smooth function. For the set of path points, A state sequence; a motion state sequence strictly ordered by timestamps. Each of the states It must contain at least three-dimensional position coordinates. Velocity vector and heading angle It can be extended to higher-order motion quantities such as acceleration and angular velocity; and to path sequences. The corresponding list of associated road segment IDs.
[0106] This embodiment ultimately outputs a structured trajectory object. Because the matching path has a high degree of consistency with the prior road network and the trajectory is smooth, the confidence level is calculated. The results indicate that the method is reliable and verify the effectiveness of the present invention.
[0107] As can be seen from this embodiment, the system and optimal parameter range described in this invention can systematically transform the original GPS trajectory, which has noise and sparsity problems, into a geometrically accurate, topologically correct, and semantically clear matching path under a high-precision map coordinate system, fully verifying the effectiveness, robustness, and practicality of this invention.
[0108] At the system operation level, this invention supports two typical processing modes to adapt to different application scenarios: batch processing mode and online incremental mode.
[0109] Batch processing mode is suitable for offline analysis and high-precision map creation of historical trajectory data. In this mode, when GPS trajectory data is updated, the system loads the complete GPS trajectory sequence O and road network data G, and executes the complete process from initialization, evolution to output. It obtains the globally optimal matching path through a single processing step. This mode does not emphasize real-time performance, but prioritizes ensuring matching accuracy and global consistency.
[0110] The online incremental mode is designed to meet the needs of real-time applications such as autonomous driving. In this mode, the system does not start calculating from scratch each time, but maintains a dynamic level set function state. When the new GPS point Upon arrival, the system is in the current level set function state. As the initial field, and with The primary driver performs a finite number (usually a small number) of rapid level set evolutions, quickly updating the probability field and extracting the latest path. This process can be formally represented as:
[0111] (14)
[0112] in It is the number of iterations in the online evolution. This represents a function that encapsulates the numerical solution process for level set evolution. It outputs an updated level set function based on the input level set function, observation data, velocity field, and number of iterations. Indicates at time step The level set function, i.e., the state before evolution, has the following in the online incremental mode: This mechanism greatly reduces computational latency, enabling continuous, real-time tracking of vehicle positions, while maintaining the spatiotemporal smoothness of the trajectory by utilizing the evolution results from the previous moment.
[0113] To adapt to the diverse needs of downstream modules (such as path planning, behavior prediction, and control execution), this invention designs two complementary data output modes: asynchronous streaming output mode and periodic snapshot output mode.
[0114] Asynchronous streaming output mode is designed for applications with extremely high real-time requirements. In this mode, the system immediately publishes incremental update information after processing each frame (or each GPS point). This incremental information packet typically contains three types of data: first, the latest status of all active trajectories in the current frame; second, the latest status of all active trajectories in the current frame. Secondly, there is the initialization notification for newly added trajectories, containing their ID, initial state, and confidence level; thirdly, there is the termination notification for disappeared trajectories, indicating their ID and last known state. This method of transmitting scene changes with minimal delay provides near-instantaneous feedback for the real-time control loop.
[0115] The periodic snapshot output mode focuses on providing the decision-making module with a more comprehensive and context-rich global scenario situation. This mode outputs snapshots at preset time intervals. Triggered at 100 milliseconds (e.g.), a complete snapshot of the entire tracking region at the current moment is published. This snapshot not only includes the complete state of all active targets, but also includes additional deep metadata, such as the state estimation covariance matrix obtained based on Kalman filters or similar estimation algorithms. It is used to quantify the uncertainty of state quantities such as position and velocity; and may contain target information that has recently (e.g., within the past few seconds) entered a dormant state and the reasons for its dormancy (e.g., being blocked, signal loss), providing richer evidence for risk assessment and prediction.
[0116] Ultimately, this module publishes structured trajectory information to the entire system through a standardized data interface. Its design fully considers modularity and scalability; the level of detail in the output data, the selection of output modes, and the switching of operating modes can all be flexibly adjusted through configuration files. This ensures that the invention can be seamlessly integrated into various types of autonomous driving architectures or location service platforms, providing them with stable, reliable, and accurate map matching services.
Claims
1. A map matching system based on the level set method, characterized in that, The system includes: a data preprocessing module, a level set probability field initialization module, a level set evolution module based on GPS observation, an optimal path extraction and post-processing module, and a trajectory output and update module; The data preprocessing module preprocesses the input raw GPS trajectory data and road network data to obtain the projected GPS point sequence and road prior mask. ; The level set probability field initialization module is based on the road prior mask. Construct the symbolic distance function as the initial level set function ; The GPS-based level set evolution module iteratively evolves the initial level set function to obtain a convergent level set function. ; The optimal path extraction and post-processing module, based on Extract the zero-level set to obtain the initial geometric path, and then perform short branch pruning and B-spline curve fitting on the initial geometric path to obtain a smooth trajectory point sequence of the geometric layer. ; Further targeting By implementing a bidirectional projection and graph matching strategy, discrete road segment sequences at the semantic layer are obtained. ; and Composition of map matching results; The trajectory output and update module encapsulates the map matching results into structured trajectory objects. Output.
2. The map matching system based on the level set method according to claim 1, characterized in that, The data preprocessing module converts the spatial coordinate components of the raw GPS trajectory data. Through map projection function Convert to planar coordinates : ,in, Indicates the time index value. ; The projected GPS point sequence is represented as follows: ; The data preprocessing module processes the road network data using a map projection function. After conversion, it is then rendered onto a two-dimensional computational grid. Above, generate a binary road prior mask. For grid Each unit in Its value The formula for calculation is: ,in, Represents each unit The center point, E, represents the set of road segment buffer zones.
3. A map matching system based on the level set method according to claim 2, characterized in that, The level set probability field initialization module for the grid any point on The sign distance function value Calculated using the following formula: in, Represents a grid any point on to the road boundary The shortest Euclidean distance, , and Representing grids respectively any point on Located inside the road, at the road boundary, and outside the road; The initial level set function Through the Gaussian convolution operation yields: ,in, This represents a two-dimensional Gaussian convolution kernel. Indicates: First, regarding The function itself Perform a Gaussian convolution operation, and then use the result after the Gaussian convolution operation. ,exist Take the value at the location and get .
4. A map matching system based on the level set method according to claim 3, characterized in that, The iterative evolution of the level set function specifically involves: a level set evolution module based on GPS observations iteratively evolving the level set function based on an initial level set function. Second-rate, ,when or change norm Less than the set convergence threshold When the iteration ends, the convergent level set function is obtained. ,in, Indicates the time at which When fixed, the level set function Spatial distribution, hour, = .
5. A map matching system based on the level set method according to claim 4, characterized in that, The GPS-based level set evolution module uses: Iterative evolution level set, where Indicates the first The next iteration ; This represents the time step that satisfies the CFL stability condition. express gradient value, Indicates the first The composite velocity field of the next iteration ; when or change norm Less than the set convergence threshold hour, For convergent level set functions .
6. A map matching system based on the level set method according to claim 5, characterized in that, The formula for calculation is: ,in, Indicates GPS observation driving term, , The gain coefficient representing the observed driving strength. This represents the standard deviation of GPS observation errors; Indicates the a priori preservation term of the road. , This represents the gain coefficient that indicates the prior maintenance strength. Indicates the attenuation coefficient. Represents a symbolic function; Represents the curvature regularization term. , This represents the regularization strength coefficient. This represents vector differentiation. express The gradient value.
7. A map matching system based on the level set method according to claim 6, characterized in that, The optimal path extraction and post-processing module uses an isosurface extraction algorithm to extract the zero-level set. Traverse the zero level set and select the average value from the convergent level set. The candidate path with the value closest to zero and the largest number of GPS points is used as the initial geometric path. The candidate path represents any continuous geometric curve in the zero-level set. convergent level set average The formula for calculating the value is: ,in, The convergence level set average value, Indicates the first Candidate paths, express Upper The coordinates of each sampling point , Indicates the total number of sampling points; Number of GPS points The formula for calculation is: in, This represents a function that calculates the distance between two points. Indicates the distance threshold. Indicates an indicator function; Short branch pruning specifically involves removing branches whose length is less than the short branch threshold. The terminal branch.
8. A map matching system based on the level set method according to claim 7, characterized in that, The bidirectional projection and graph matching strategy specifically involves: […]. After discretization, it is projected onto the original road network. The above data is used to generate histograms of road segments and frequencies; then, based on these histograms, the original road network is analyzed. The search is performed with the goal of finding connected road segments, resulting in a discrete road segment sequence at the semantic layer. .
9. A map matching system based on the level set method according to claim 8, characterized in that, The trajectory output and update module is also suitable for dual-mode trajectory processing, including batch processing and online incremental processing. Batch processing specifically involves: when GPS trajectory data is updated, calling the data preprocessing module, the level set probability field initialization module, the GPS observation-based level set evolution module, and the optimal path extraction and post-processing module to generate... and And encapsulate it into a structured trajectory object. Output; The online incremental approach specifically involves using the current level set function as the initial level set function when GPS trajectory data is updated, and driving the level set evolution with the newly added GPS trajectory data.
Citation Information
Patent Citations
Map matching method and device, medium and terminal
CN111380540A
Map matching method, control device, readable storage medium and driving device
CN115824232A
Route smoothing
CN103975223A
Remote sensing image road network automatic extraction method with navigation data assistance
CN106778605A