A method for path planning of an unmanned vehicle
By combining graph search and curve fitting algorithms, a raster map is generated, and a bidirectional probabilistic road map and heuristic search algorithm are used to filter paths. Combined with a non-uniform rational B-spline curve smoothing algorithm, the smoothness and stability problems of path planning for autonomous vehicles in complex environments are solved, and safe and efficient path generation is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- YANCHENG INST OF TECH
- Filing Date
- 2026-04-27
- Publication Date
- 2026-06-23
AI Technical Summary
Existing path planning algorithms struggle to quickly generate routes that meet the requirements for smooth vehicle driving while ensuring obstacle avoidance safety, especially in complex environments where they can easily lead to unstable vehicle steering.
Combining graph search and curve fitting algorithms, sampling points are selected by generating a grid map and a bidirectional probabilistic road map algorithm. A heuristic search algorithm is used to stitch together the path, and a non-uniform rational B-spline curve smoothing algorithm is used to eliminate the sharp corners of the polyline path and generate a smooth trajectory.
It improves the efficiency and accuracy of path planning, ensuring that the vehicle avoids obstacles in complex environments while generating a smooth driving trajectory that conforms to vehicle kinematic constraints, thereby enhancing the vehicle's driving consistency and stability.
Smart Images

Figure CN122258946A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of autonomous driving and vehicle navigation control technology, and in particular to a path planning method for unmanned vehicles. Background Technology
[0002] With the integration of artificial intelligence and the automotive industry, autonomous vehicles are increasingly being used in logistics and urban transportation. Path planning, as a core module of autonomous driving systems, is primarily responsible for finding a route from the starting point to the destination within a given physical space without colliding with obstacles. Accurate and efficient path planning is not only crucial for the vehicle to safely reach its destination but is also a fundamental prerequisite for achieving advanced levels of autonomous driving.
[0003] In existing path generation processes, sampling-based and graph search-based algorithms are widely used. Real-world traffic environments typically contain numerous static and dynamic obstacles, resulting in complex structures. When dealing with high-dimensional state spaces, some conventional search algorithms often require traversing a large number of spatial nodes to ensure the reachability of the pathfinding result. Furthermore, many basic pathfinding algorithms directly output trajectories composed of a series of discrete line segments, which often exhibit sharp angles with discontinuous curvature at node intersections. Considering the kinematic and dynamic constraints of autonomous vehicles, directly tracking such polyline paths can easily lead to vehicle shaking and unstable driving during turns. Therefore, how to quickly generate a route that meets the requirements for smooth vehicle driving while ensuring obstacle avoidance safety is a direction of continuous optimization within the industry. Summary of the Invention
[0004] To address the problems existing in the prior art, the present invention aims to provide a path planning method for autonomous vehicles, which extracts the optimal path through the collaborative processing of graph search and curve fitting algorithms, thereby providing autonomous vehicles with a safe and smooth driving trajectory that conforms to kinematic constraints.
[0005] This invention provides a path planning method for autonomous vehicles, comprising the following steps: S1, acquire spatial environment information and generate a raster map representing the environmental state accordingly; S2, Random sampling is performed within the unobstructed area of the grid map to generate a set of sampling points; S3, based on the probabilistic road map algorithm, the sampling points in the sampling point set are searched bidirectionally from the initial point and the target point, and the connection lines intersecting with the obstacle area are excluded during the search process, so as to construct a path set containing multiple valid connections; S4. Use a heuristic search algorithm to traverse and splice the valid connections in the path set to extract the optimal polyline path connecting the initial point and the target point. S5. The optimal polyline path is smoothed using a curve smoothing algorithm to generate the optimal planned path for autonomous vehicles.
[0006] Optionally, steps S1 and S2 specifically include: The spatial environment information is acquired using vehicle-mounted sensors, and the spatial environment is divided into a grid map containing obstacle grids and obstacle-free grids; Create an initially empty set of sampling points, perform point selection operations on the grid map, determine whether the selected sampling points are located on the obstacle grid, and add the sampling points that are not located on the obstacle grid to the set of sampling points.
[0007] Optionally, in step S3, before performing bidirectional search, the initial point of the plan is set as the positive origin, the target point of the plan is set as the negative origin, and the path set is created initially as empty.
[0008] Optionally, the specific process of the bidirectional search includes: Forward search: Starting from the forward origin, search for sampling points in the sampling point set in a direction closer to the reverse origin. Connect the forward origin with the searched sampling points to generate a forward connection. If the forward connection does not contact the obstacle grid, then add the forward connection as a valid connection to the path set. Reverse search: Starting from the reverse origin, search for sampling points in the sampling point set in a direction closer to the forward origin. Connect the reverse origin with the searched sampling points to generate a reverse connection. If the reverse connection does not contact the obstacle grid, then the reverse connection is added to the path set as a valid connection.
[0009] Optionally, after completing one round of search, the sampling points corresponding to the newly added forward connection in the path set are traversed, and they are used as new forward origins to repeat the forward search process; at the same time, the sampling points corresponding to the newly added reverse connection in the path set are traversed, and they are used as new reverse origins to repeat the reverse search process.
[0010] Optionally, when a new forward or reverse connection is added to the path set, the forward search process and the reverse search process are continuously executed alternately until the newly added forward connection and the newly added reverse connection are connected to the same sampling point in the sampling point set. The same sampling point is defined as a duplicate point, and the search ends.
[0011] Optionally, the specific process of step S4 includes: If the path set is determined to be empty, output a message indicating that there is no optimal polyline path. If it is determined that the path set is not empty, then in the path set, the continuous forward connection from the initial point to the repeating point and the continuous reverse connection from the target point to the repeating point are selected in sequence. Connect the selected forward line and the reverse line at the repetition point to obtain at least one polyline path connecting the initial point and the target point.
[0012] Optionally, when multiple polyline paths are obtained by splicing, the geometric length of each polyline path is calculated and compared, and the shortest polyline path is selected as the optimal polyline path.
[0013] Optionally, in step S5, a non-uniform rational B-spline curve smoothing algorithm is used to smooth the optimal polyline path to eliminate sharp corners in the optimal polyline path and generate the optimal planned path that meets the vehicle driving stability requirements and has continuous curvature.
[0014] Optionally, when using the non-uniform rational B-spline curve smoothing algorithm, nodes on the optimal polyline path are extracted as control points. A set of positive parameters, including the number of control points, the position of the control points, and the corresponding weights of each control point, is defined. A target curve function is established by combining the B-spline basis function determined by the non-decreasing node sequence composed of real numbers. The target curve function is then used to generate a smooth curve to fit the optimal polyline path.
[0015] The present invention has achieved the following beneficial effects: This invention generates a two-dimensional raster map by acquiring environmental point cloud data, establishing clear physical obstacle avoidance boundary conditions for subsequent spatial searches. In the path generation stage, a bidirectional probabilistic roadmap algorithm combined with a heuristic search algorithm is used to filter and stitch discrete sampling points. This combination of bidirectional expansion and global cost evaluation improves the efficiency and accuracy of optimizing collision-free polyline paths in complex obstacle spaces. To address the abrupt curvature changes in polyline paths, this invention further utilizes a non-uniform rational B-spline curve smoothing algorithm to extract and fit control points to the extracted optimal polyline path nodes, thereby generating a smooth curve. This smoothing process eliminates the geometric sharp angles between the original trajectory nodes, ensuring that the final output planned route conforms to the mechanical operation constraints of the vehicle's steering actuator. The overall solution ensures that the autonomous vehicle can avoid environmental obstacles while guaranteeing the continuity and stability of the vehicle along the planned route, meeting the low-level vehicle control requirements in practical engineering applications.
[0016] Other features and advantages of the invention will be set forth in the following description, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention may be realized and obtained by means of the structures particularly pointed out in the written description and the accompanying drawings.
[0017] The technical solution of the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. Attached Figure Description
[0018] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a schematic diagram of the overall process of an unmanned vehicle path planning method provided in an embodiment of the present invention; Figure 2 This is a schematic diagram of the initial stage of searching on a grid map using a bidirectional probabilistic roadmap algorithm in an embodiment of the present invention; Figure 3 This is a schematic diagram illustrating the intersection and formation of a connected network in an embodiment of the present invention; Figure 4 This is a schematic diagram of the optimal polyline path extracted using a heuristic algorithm in an embodiment of the present invention; Figure 5 This is a schematic diagram of the optimal planning path after smoothing by non-uniform rational B-spline curves in an embodiment of the present invention. Detailed Implementation
[0019] The preferred embodiments of the present invention will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.
[0020] This invention discloses a path planning method for autonomous vehicles. This method relies on an electronic device or computing platform equipped with a processor, memory, sensor components (such as LiDAR, millimeter-wave radar, and cameras), and a chassis drive-by-wire system. The computing platform executes the various steps of path planning by running a computer program stored in its memory. Figure 1 As shown, this method mainly includes the following technical processes: Step S1: Obtain spatial environment information and generate a raster map representing the environmental state accordingly.
[0021] Specifically, during operation, autonomous vehicles collect real-time data on the physical environment surrounding the vehicle using onboard sensors. In one implementation, the vehicle uses a LiDAR as its primary sensor to acquire 3D point cloud data of the spatial environment. After receiving the 3D point cloud data, the processor preprocesses it. The preprocessing includes voxel grid filtering and statistical outlier removal to filter out buoyancy noise and downsample the data, thereby reducing its dimensionality. In a specific implementation, the leaf size for voxel filtering is set to... This size is determined based on the minimum safe avoidance resolution requirement of the target vehicle for small, conventional obstacles (such as road rocks and traffic cones). In the statistical outlier removal algorithm, each target point is queried... Among the nearest points, The value range is set to The processor calculates the distance from all target points to their respective... The average distance to neighboring points, when the distance to a point is greater than the global average distance plus... When the standard deviation is times (constant) Pick If a point is identified as an outlier noise point caused by raindrops or flying insects, it is removed. The filtered point cloud data is then transformed to a unified global coordinate system or a vehicle local coordinate system based on the sensor extrinsic calibration matrix.
[0022] Further, the processor projects the converted point cloud data onto a two-dimensional plane and generates a grid map using an occupancy grid mapping algorithm. The grid map construction process includes: setting environmental boundaries and resolution parameters, and discretizing the continuous two-dimensional space into a set of two-dimensional matrices composed of row and column indices. Each element in the matrix corresponds to a rectangular region of a specific size in physical space, i.e., a grid. The processor calculates the probability that each grid is occupied by a physical entity based on the distribution density and height information of the projected point cloud. An occupancy probability threshold is set; when the occupancy probability of a grid is greater than or equal to the threshold, the grid is marked as an obstacle grid (logically, a black grid); when the occupancy probability of a grid is less than the threshold, the grid is marked as an obstacle-free grid (logically, a white grid). In this embodiment, the specific value range of the occupancy probability threshold is set to 0.6 to 0.8. The specific implementation of the processor's calculation of occupancy probability is as follows: The number of point cloud data points actually falling within the physical range of a single two-dimensional grid is counted, and the ratio is calculated with the theoretical maximum resolution point cloud count of the sensor at that distance. When this ratio is greater than or equal to a threshold of 0.65, the grid is marked as an obstacle grid. This ratio-based determination, based on physical point cloud density, effectively filters out floating point cloud noise caused by flying insects or rain and snow, ensuring the authenticity of the environmental obstacle avoidance boundary. The final generated grid map includes several grids of the same size, containing two discrete states: obstacle grids and obstacle-free grids, serving as the input data layer for subsequent algorithm execution.
[0023] Step S2: Random sampling is performed within the barrier-free area of the grid map to generate a set of sampling points.
[0024] After acquiring the raster map, the processor determines the two-dimensional sampling space based on the physical size and resolution boundaries of the raster map. An initial set of sampling points is created, which can be represented as a dynamic array or linked list. Upon entering the random sampling logic, the processor uses a random number generation function (such as a pseudo-random number generator or a low-discrepancy sequence like the Halton sequence) to generate coordinate pairs within the two-dimensional sampling space. ,in Let x be the x-coordinate of the sampling point in two-dimensional space. Let be the ordinate of the sampling point in two-dimensional space, and use it as the initial sampling point.
[0025] For each generated initial sampling point, the processor performs collision detection verification. The specific process is as follows: based on the coordinate data of the initial sampling point, the processor calculates the location of that coordinate within the grid using rounding or index mapping. Figure 2 The raster index corresponding to the dimensional matrix ,in This is the row index of the raster. The column index of the grid is used. The attribute value corresponding to the grid index is queried to determine whether the sampled point is located on an obstacle grid. If the grid is marked as an obstacle grid, the initial sampled point is discarded; if the grid is marked as an obstacle-free grid, the sampled point is confirmed to have physical accessibility, and it is added to the sampled point set as a valid data node. The above iterative process of coordinate generation and attribute determination is repeated until the number of elements in the sampled point set reaches a preset sampling scale threshold, thus completing the construction of the sampled point set. The preset sampling scale threshold... It is not a fixed constant, but rather depends on the total physical area of obstacle-free grid cells in the current grid map. This was calculated dynamically. The baseline node distribution density in the real physical space was set as follows: (e.g., per square meter) to (number of nodes), then By establishing a positive correlation between the number of sampling points and the actual passable physical area, the problem of road map disconnection due to insufficient sampling points in narrow dead-end alleys or wasted computing power due to excessive sampling points in open squares is avoided. To accelerate subsequent nearest neighbor search, the processor constructs the generated sampling point set into a K-D-Tree data structure.
[0026] Step S3: Based on the probabilistic road map algorithm, the sampling points in the sampling point set are searched bidirectionally from the initial point and the target point, and the lines intersecting with the obstacle area are excluded during the search process, so as to construct a path set containing multiple valid lines.
[0027] The execution logic of the Bidirectional Probabilistic Path Graph (Bidirectional PRM) algorithm includes the initialization of the graph data structure, forward expansion iteration, reverse expansion iteration, and connectivity determination.
[0028] Before performing a bidirectional search, the processor first obtains the starting and ending coordinates from the upper-level navigation module. The initial planning point is set as the positive origin, and the target planning point is set as the negative origin. Simultaneously, an initially empty path set is created. This path set exists at the lower level as an adjacency list or a graph node set, used to record nodes and their valid connecting edges.
[0029] The specific process of the bidirectional search includes a forward search mechanism and a reverse search mechanism: When performing a forward search: Starting from the forward origin, a query is performed within the constructed KD-Tree. By setting a distance threshold or a K-nearest neighbor parameter, the search is conducted in the direction closer to the reverse origin, targeting the sample points in the sample point set. For example, all adjacent sample points within a preset radius centered on the forward origin are obtained. The preset radius... It is not a fixed constant, but rather based on the physical length of the diagonal of the raster map. Compared with the total number of currently generated sampling points Dynamically determined, its derivation formula is as follows: , where constant coefficient The range of values is to This dynamic association ensures that autonomous vehicles can adaptively adjust their search step size when facing open or dense obstacle environments, ensuring effective connectivity of the roadmap while avoiding computational redundancy caused by blind searches. The positive origin is geometrically connected to adjacent sampled points to generate multiple positive lines. Subsequently, the processor performs line-level collision detection on each positive line. Specifically, the Bresenham's line algorithm can be used to traverse the grid cells traversed by the positive lines. Before performing this traversal detection, the processor pre-calculates the physical contour width parameters of the autonomous vehicle. and preset safety margin Calculate the vehicle's radius of expansion. After calculating the sequence of central grid cells traversed by the basic forward connection using the Bressenham line algorithm, the connection is further extended perpendicularly to both sides of this central grid cell sequence by a distance of [missing information]. The set of neighboring grids covered by the forward connection forms a physical detection corridor. A forward connection is considered safe for vehicle passage only if all grids within the physical detection corridor are unobstructed. If all grids traversed by the forward connection are unobstructed, the forward connection is determined not to contact any obstructed grids, and the forward connection is added to the path set as a valid connection (i.e., an edge in the diagram), with the corresponding adjacent sampling points marked as visited nodes. If the forward connection traverses grids containing obstructed grids, the forward connection is discarded.
[0030] When performing a reverse search, its logic is symmetrical to the forward search. Starting from the reverse origin, search for adjacent sampling points in the sampling point set within the same KD-Tree, moving towards the forward origin. Connect the reverse origin with the searched adjacent sampling points to generate multiple reverse lines. Use the same collision detection algorithm to determine whether the reverse lines contact obstacle grids. If the area traversed by the reverse line is entirely free of obstacle grids, then the reverse line is added to the path set as a valid line. The specific extension process of the forward and reverse searches is as follows... Figure 2 As shown. Combined with Figure 2 As shown in the figure, S in the upper left corner represents the forward origin (initial point), and g in the lower right corner represents the reverse origin (target point). The nodes of the a series (such as a, a2, etc.) pointed to by the dashed arrows emanating from point S represent the first-level adjacent sampling points generated by the forward search; similarly, the nodes of the b series pointed to by the dashed arrows emanating from point g represent the first-level adjacent sampling points generated by the reverse search.
[0031] After completing the initial search initiated by the forward and reverse origins, the algorithm enters the progressive evolution phase. The processor traverses the end sampling points corresponding to the newly added forward connections in the path set, and sequentially uses them as new forward origins. For each new forward origin, the above forward search process is repeated to generate the next level of forward connections. Simultaneously, the processor traverses the end sampling points corresponding to the newly added reverse connections in the path set, and sequentially uses them as new reverse origins. For each new reverse origin, the above reverse search process is repeated to generate the next level of reverse connections.
[0032] During the aforementioned iterative expansion process, the processor incorporates a loop termination condition detection module. When a new forward or reverse connection is added to the path set, the forward search process and the reverse search process are continuously executed alternately. After each newly generated connection, the algorithm performs an intersection operation on the node set generated by the current forward search and the node set generated by the reverse search. A stop command is triggered when it is determined that the end node of the newly added forward connection and the end node of the newly added reverse connection are connected to the same sampling point in the sampling point set. The processor defines this same sampling point as a repeating point and terminates the bidirectional search expansion loop. At this point, at least one connected network from the initial point through the repeating point to the target point has been formed in the graph data structure, specifically as follows: Figure 3 As shown. Figure 3 The progressive evolution is illustrated by the forward search extending from the initial 'a' series nodes to the lower right, reaching the next level nodes such as 'a11, while the reverse search extends from the 'b' series nodes to the upper left, reaching nodes such as 'b31.' Ultimately, these multi-level extended dashed lines successfully connect at a repetitive point in the middle region, forming a complete connected network that bypasses the black obstacle grid.
[0033] Step S4: Use a heuristic search algorithm to traverse and splice the valid connections in the path set to extract the optimal polyline path connecting the initial point and the target point.
[0034] Based on the graph data structure (path set) output in step S3, the processor invokes a heuristic search algorithm (such as the A algorithm or Dijkstra's algorithm). In this embodiment, the A algorithm is used for path optimization.
[0035] First, a connectivity check is performed. If the path set is determined to be empty or there is no path sequence connecting the initial point and the target point in the graph, a system prompt message indicating that there is no optimal polyline path is output. If the path set is determined to be not empty, the path splicing and filtering process begins.
[0036] Since the bidirectional search converges at the repetition point, a connected component is formed in the graph network. Within this connected component, there may be multiple branches that can reach the repetition point. The processor uses a heuristic evaluation function to traverse this path set. Specifically, the heuristic evaluation function is defined as follows: .in, This represents the node currently being searched; The actual cost parameter represents the actual distance traveled from the starting node (forward origin or reverse origin) along the generated valid connection to the current node. The cumulative geometric distance; To heuristically estimate the cost parameters, this embodiment uses Euclidean distance to calculate the current node. The physical straight-line distance to the target node (either the reverse origin or the forward origin). When traversing and connecting lines, the system prioritizes accessing nodes based on given permissions. The set of nodes with the smallest value is used to quickly extract the shortest physical polyline path. Within the path set, a first sub-path set (i.e., continuous forward connections) consisting of valid lines from the initial point to the repeating point is selected sequentially; simultaneously, a second sub-path set (i.e., continuous reverse connections) consisting of valid lines from the target point to the repeating point is selected sequentially. The selected forward and reverse connection sequences are then merged and connected at the repeating point to obtain several complete polyline paths connecting the initial point and the target point.
[0037] To extract the path with the minimum global cost from several polyline paths, the system introduces a cost calculation model. When multiple polyline paths are obtained by concatenating them, the processor traverses these paths and calculates the geometric length of each polyline path. Specifically, for any polyline path, it is decomposed into a sequence of line segments composed of nodes. The distance between adjacent nodes is calculated using the Euclidean distance formula, and the distances of all line segments on a polyline path are summed to obtain the total geometric length of the path. The geometric lengths of all polyline paths are numerically compared, and the polyline path with the smallest length is selected as the optimal polyline path. This optimal polyline path consists of a series of discrete two-dimensional coordinate points, representing the shortest spatial trajectory without collisions, and its effect is as follows: Figure 4 As shown. Observation Figure 4 As can be seen from the visual presentation, although the extracted optimal polyline path (shown as the dotted line running through the space in the figure) successfully avoided the black obstacles in the white unobstructed area, there are obvious and abrupt discontinuous sharp corners at the intersections of its segments. This intuitively reflects the defect that the path may cause uneven steering when directly used for vehicle control.
[0038] Step S5: The optimal polyline path is smoothed using a curve smoothing algorithm to generate the optimal planned path for the autonomous vehicle.
[0039] The optimal polyline path obtained in step S4 has sharp angles with discontinuous geometric curvature at the intersections of its segments. Directly using it as a vehicle tracking command cannot satisfy vehicle dynamics and kinematic constraints. Therefore, a non-uniform rational B-splines (NURBS) curve smoothing algorithm is needed to smooth the optimal polyline path.
[0040] The process of smoothing the optimal polyline path using a non-uniform rational B-spline curve is as follows: The processor extracts the coordinate nodes on the optimal polyline path as a set of control points, and uses this set of control points to fit the spline curve. A set of positive parameters is defined, including the number of control points, the positions of the control points, and the corresponding weights of each control point. Simultaneously, a target curve function is established by combining the B-spline basis function determined by the non-decreasing sequence of real numbers. The target curve function is then used to generate a smooth curve to fit the optimal polyline path.
[0041] The specific formula expression and parameter construction logic are as follows: Non-uniform rational B-spline curve The mathematical expression for it is defined as: The domain is limited to ; in, The target curve function is the smoothed non-uniform rational B-spline curve. These are independent parametric variables of the curve; For parameter variables The lower bound of the domain is usually set. ; For parameter variables The upper limit of the domain is usually set. ; The maximum index of the control point is given, and the total number of control points is given. indivual; The index of the control point is the serial number, and its value range is... ; Let be the order of the B-spline basis functions; For the first The specific coordinates of each control point in a two-dimensional plane or three-dimensional space; For the first Positive weight parameters corresponding to each control point; The parameter is And from the node vector The decision indivual B-order spline basis functions; Let be a node vector consisting of a non-decreasing sequence of real numbers, and its expression is: ; This is the parameter value of the first node. For the first Each node parameter value, The parameter values are for the final node. To ensure that the generated smooth curve accurately matches the response characteristics of the underlying control and steering actuators of the autonomous vehicle, this embodiment sets specific rules for determining the parameters of the non-uniform rational B-spline curve: the order of the B-spline basis function is... Fixed setting To ensure second-order continuity of curvature; the non-decreasing node sequence composed of real numbers The cumulative chord length parameterization method is used, and the parameters are generated proportionally based on the actual geometric distance between adjacent control points on the extracted optimal polyline path. Furthermore, regarding the weight parameters... For local nodes in the polyline path with small included angles and large changes in vehicle steering curvature, assign them... to The high weighting of positive values makes the curve trajectory more closely fit the control point to leave sufficient physical safety margin; for nodes on straight or gentle road sections, the weighting parameters are adjusted accordingly. Set to normal value .
[0042] The B-spline basis functions are not expressed by a single analytical formula, but are calculated based on the DeBoor-Cox recursive definition. The specific recursive logic is as follows: The definition of the zeroth-order B-spline basis function is: when hour, For all other parameter ranges, .in, Indicates the first One zero-order B-spline basis function; Represents a node vector The first in Node parameter values; Represents a node vector The first in Each node parameter value.
[0043] For B-spline basis functions of order greater than zero, the recursive formula is expressed as: ; in, Indicates the first indivual B-order spline basis functions; Indicates the first indivual B-order spline basis functions; Represents a node vector The first in Node parameter values; Represents a node vector The first in Each node parameter value.
[0044] During the actual execution of a computer program, the processor calculates the values of each order of basis functions by iteratively applying the above recursive formula. To prevent the algorithm from being interrupted due to a zero denominator at overlapping nodes, a fuzzy condition is introduced for ease of calculation: that is, during execution... When performing floating-point operations on type `type`, the system logic explicitly assigns the calculation result to a value. .
[0045] The processor, based on the aforementioned target curve function, sets the parameters... exist Discretized sampling is performed within the interval, and the coordinates of the control points, weights, and B-spline basis functions are substituted into the equation to calculate a series of continuous and smooth trajectory point coordinates. The curve formed by connecting these trajectory points eliminates the sharp corners in the optimal polyline path. The output smooth curve satisfies the requirements of positional continuity and curvature continuity, generating the optimal planned path that meets the vehicle driving stability requirements and has continuous curvature. The smoothed trajectory is as follows: Figure 5As shown. Comparison Figure 4 and Figure 5 It can be seen that the optimal planning path after smoothing is ( Figure 5 (As shown by the dashed line) it presents a perfectly smooth curve shape. The original harsh, jagged edges of the broken lines have been completely eliminated, and the entire trajectory safely bypasses the black obstacle while exhibiting curvature continuity that fully conforms to the vehicle's kinematic constraints. The final generated optimal planned path data will be transmitted to the underlying control module for trajectory tracking by the autonomous vehicle's steering actuators and longitudinal drive mechanisms.
[0046] Furthermore, as the operational carrier of this embodiment of the invention, the electronic device implementing this path planning method may include a processor, a storage medium, an input interface, and an output interface. The processor may be a central processing unit (CPU), a microprocessor (MCU), or a graphics processing unit (GPU) specifically designed for parallel computing. The storage medium may include random access memory (RAM) and non-volatile memory (such as flash memory or hard disk), used to permanently or temporarily store spatial environment information data, occupancy grid matrices, sampling point set arrays, path graph adjacency list data, and all the aforementioned computer program instructions related to environmental perception and numerical calculation. The input interface is used to receive serial data streams or Ethernet packets from sensors such as vehicle-mounted radar and cameras; the output interface is used to send the calculated optimal planned path node sequence to the vehicle control unit (VCU) at a specific baud rate or network protocol. Through the combined operation of software instructions and hardware components, a closed-loop data processing process is completed, from environmental perception abstraction to mathematical space search, and then to trajectory smoothing output.
[0047] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.
Claims
1. A path planning method for autonomous vehicles, characterized in that, Includes the following steps: S1, acquire spatial environment information and generate a raster map representing the environmental state accordingly; S2, Random sampling is performed within the unobstructed area of the grid map to generate a set of sampling points; S3, based on the probabilistic road map algorithm, the sampling points in the sampling point set are searched bidirectionally from the initial point and the target point, and the connection lines intersecting with the obstacle area are excluded during the search process, so as to construct a path set containing multiple valid connections; S4. Use a heuristic search algorithm to traverse and splice the valid connections in the path set to extract the optimal polyline path connecting the initial point and the target point. S5. The optimal polyline path is smoothed using a curve smoothing algorithm to generate the optimal planned path for autonomous vehicles.
2. The unmanned vehicle path planning method according to claim 1, characterized in that, Steps S1 and S2 specifically include: The spatial environment information is acquired using vehicle-mounted sensors, and the spatial environment is divided into a grid map containing obstacle grids and obstacle-free grids; Create an initially empty set of sampling points, perform point selection operations on the grid map, determine whether the selected sampling points are located on the obstacle grid, and add the sampling points that are not located on the obstacle grid to the set of sampling points.
3. The unmanned vehicle path planning method according to claim 1, characterized in that, In step S3, before performing bidirectional search, the initial point of the plan is set as the positive origin, the target point of the plan is set as the negative origin, and the path set is created initially as empty.
4. The unmanned vehicle path planning method according to claim 3, characterized in that, The specific process of the bidirectional search includes: Forward search: Starting from the forward origin, search for sampling points in the sampling point set in a direction closer to the reverse origin. Connect the forward origin with the searched sampling points to generate a forward connection. If the forward connection does not contact the obstacle grid, then add the forward connection as a valid connection to the path set. Reverse search: Starting from the reverse origin, search for sampling points in the sampling point set in a direction closer to the forward origin. Connect the reverse origin with the searched sampling points to generate a reverse connection. If the reverse connection does not contact the obstacle grid, then the reverse connection is added to the path set as a valid connection.
5. The unmanned vehicle path planning method according to claim 4, characterized in that, After completing one round of search, the sampling points corresponding to the newly added forward connections in the path set are traversed, and each point is used as a new forward origin to repeat the forward search process; at the same time, the sampling points corresponding to the newly added reverse connections in the path set are traversed, and each point is used as a new reverse origin to repeat the reverse search process.
6. The unmanned vehicle path planning method according to claim 5, characterized in that, When a new forward or reverse connection is added to the path set, the forward search process and the reverse search process are continuously executed alternately until the newly added forward connection and the newly added reverse connection are connected to the same sampling point in the sampling point set. The same sampling point is defined as a duplicate point, and the search ends.
7. The unmanned vehicle path planning method according to claim 6, characterized in that, The specific process of step S4 includes: If the path set is determined to be empty, output a message indicating that there is no optimal polyline path. If it is determined that the path set is not empty, then in the path set, the continuous forward connection from the initial point to the repeating point and the continuous reverse connection from the target point to the repeating point are selected in sequence. Connect the selected forward line and the reverse line at the repetition point to obtain at least one polyline path connecting the initial point and the target point.
8. The unmanned vehicle path planning method according to claim 7, characterized in that, When multiple polyline paths are obtained by splicing them together, the geometric length of each polyline path is calculated and compared, and the shortest polyline path is selected as the optimal polyline path.
9. A path planning method for an unmanned vehicle according to claim 1 or 8, characterized in that, In step S5, a non-uniform rational B-spline curve smoothing algorithm is used to smooth the optimal polyline path to eliminate sharp corners in the optimal polyline path and generate the optimal planned path that meets the vehicle driving stability requirements and has continuous curvature.
10. The unmanned vehicle path planning method according to claim 9, characterized in that, When processing using the non-uniform rational B-spline curve smoothing algorithm, nodes on the optimal polyline path are extracted as control points. A set of positive parameters is defined, including the number of control points, the position of the control points, and the corresponding weights of each control point. A target curve function is established by combining the B-spline basis function determined by the non-decreasing node sequence composed of real numbers. The target curve function is then used to generate a smooth curve to fit the optimal polyline path.