Route planning method and device and storage medium

By determining the shortest path, extending the path point and generating candidate paths in the path planning, the problem of insufficient dynamic data processing and route diversity in the prior art is solved, and a more efficient and practical path planning is achieved.

CN119803506APending Publication Date: 2025-04-11SHENZHEN YISHIHUOLALA TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411998564.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

The existing path planning algorithms have practical problems when processing dynamic data (such as congestion, road closure, etc.), and lack diversity in the middle of the route, resulting in a degradation in performance.

Method used

By determining the shortest path between the target start point and the end point, expanding to obtain the path point set, multiple candidate paths are generated, and the candidate paths are filtered to obtain the target path. This method improves the diversity and dynamicity of route planning by cutting low-level roads, expanding pathway points, and generating candidate pathways.

Benefits of technology

It improves the diversity and practicality of route planning, can effectively process dynamic data, and improves the performance and actual use effect of route planning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119803506A_ABST
    Figure CN119803506A_ABST
Patent Text Reader

Abstract

The invention discloses a route planning method and device and a storage medium, and the method comprises the steps: determining a shortest path between a target starting point and a target ending point; based on the shortest path, an approach point set is obtained through expansion, and the approach point set comprises a plurality of approach points; generating a plurality of candidate paths based on the approach points; and screening the plurality of candidate paths to obtain a target path. According to the embodiment of the invention, the path points are screened, and the path finding operation and the path solving operation are carried out based on the path points, so that the multiple paths are obtained according to the starting point and the terminal point, the path planning diversity is improved, dynamic data are supported, the paths are closer to actual use, and the practicability is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a path planning method, device and storage medium. Background Art

[0002] At present, the contraction hierarchy (CH) or customizable route planning (CRP) algorithm is usually used for route planning. The CH algorithm performs some calculation work in advance, adds short_cut in the data preprocessing, and introduces the concept of hierarchy. In the query, a search based on the layer-up rule is defined, which greatly reduces the search space. Its online performance is significantly improved compared with the traditional Dijkstra and A* algorithms, which can be improved from hundreds of milliseconds to less than ten milliseconds. The core of the CRP algorithm is still the offline preprocessing + online query mode. The algorithm covers all the original details of the road network, including turning and restriction costs, and supports searching for the best path according to multiple standards. The algorithm stores as little data as possible for each standard, can store multiple metrics in memory at the same time, and spends as little time as possible to change the standard. It is more efficient to handle the traversal cost caused by changes in a small part of the road section. The algorithm not only supports the best path, but also provides alternative paths.

[0003] However, since the data is fixed during the preprocessing of the CH algorithm and cannot be updated dynamically, it cannot solve the problem of dynamic data (congestion, road closures, etc.). In actual use, if there are temporary road closures or congested sections that cannot be avoided, it will cause some practical problems. The CRP algorithm can solve the problem of dynamic data, but when calculating the route, due to the hierarchical partitioning characteristics of CRP, the levels and partitions of the route near the starting and ending points are relatively small. In the middle of the route, the partitions and levels become larger, and the distance across the partitions when calculating the route will also become longer, which leads to the route diversity always being concentrated near the starting and ending points, and the lack of diversity in the middle of the route due to crossing partitions. And because the performance requirements for calculating multiple routes are relatively high, the performance of CRP is significantly reduced when calculating multiple routes. Summary of the invention

[0004] Based on this, it is necessary to provide a path planning method, device, computer equipment and storage medium to address the above technical problems, so as to solve at least one of the above problems.

[0005] In a first aspect, the embodiment of the present application is implemented as follows: a route planning method is provided, comprising:

[0006] Determine the shortest path between the target starting point and the target end point;

[0007] Based on the shortest path, a waypoint set is expanded, wherein the waypoint set includes a plurality of waypoints;

[0008] Based on the waypoints, generating a plurality of candidate routes;

[0009] The plurality of candidate paths are screened to obtain a target path.

[0010] In one embodiment, the step of expanding a set of waypoints based on the shortest path includes:

[0011] On the shortest path, cutting low-level roads within a preset range between the target starting point and the target end point to obtain a new shortest path;

[0012] Based on the new shortest path, determine a new starting point and a new end point;

[0013] The waypoints are expanded based on the new starting point and the new end point to obtain the waypoint set.

[0014] In one embodiment, the waypoint expansion is performed based on the new starting point and the new end point to obtain the waypoint set, including:

[0015] The new starting point and the new end point are respectively expanded by a first preset algorithm, and when the expansion weight reaches the optimal path weight, the expansion is stopped to obtain a first path point subset and a second path point subset;

[0016] The waypoint set is determined based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path.

[0017] In one embodiment, determining the waypoint set based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path includes:

[0018] When the distance of the optimal path is greater than a preset distance threshold, obtaining an intersection of the first subset of waypoints and the second subset of waypoints;

[0019] In the optimal path, determining waypoints of high-level roads and generating a third waypoint subset;

[0020] A first union of the third waypoint subset and the intersection is obtained as a waypoint set.

[0021] In one embodiment, determining the waypoint set based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path includes:

[0022] When the distance of the optimal path is less than or equal to the preset distance threshold, the new starting point and the new end point are expanded by a second preset algorithm to obtain a fourth waypoint subset and a fifth waypoint subset;

[0023] A second union of the first waypoint subset, the second waypoint subset, the third waypoint subset and the fourth waypoint subset is obtained as the waypoint set.

[0024] In one embodiment, screening the plurality of candidate paths to obtain a target path includes:

[0025] Recalculate each candidate path to obtain a new path;

[0026] When the weight of the new path is less than the weight of the candidate path, the corresponding candidate path is used as the target path.

[0027] In one embodiment, recalculating each candidate path to obtain a new path includes:

[0028] In each candidate path, starting from the target waypoint, a path segment of a preset distance is intercepted in the starting direction and the ending direction of each candidate path;

[0029] The waypoints on the path segment are used as meeting points to perform bidirectional path finding to obtain the new path.

[0030] In one embodiment, generating a plurality of candidate routes based on the waypoints includes:

[0031] Using the waypoint as a meeting point to perform bidirectional path finding, to obtain a plurality of forward path segments and a reverse path segment;

[0032] The forward path segment and the reverse path segment are spliced ​​at the meeting point to form a plurality of candidate paths.

[0033] In a second aspect, a route planning device includes:

[0034] A shortest path determination unit, used to determine the shortest path between a target starting point and a target end point;

[0035] A waypoint set acquisition unit, configured to expand a waypoint set based on the shortest path, wherein the waypoint set includes a plurality of waypoints;

[0036] a candidate path generating unit, configured to generate a plurality of candidate paths based on the waypoints;

[0037] The target path acquisition unit is used to screen the multiple candidate paths to obtain the target path.

[0038] In a third aspect, a computer device is provided, comprising a memory, a processor, and computer-readable instructions stored in the memory and running on the processor, wherein the processor implements the route planning method as described above when executing the computer-readable instructions.

[0039] In a fourth aspect, a readable storage medium is provided, on which computer-readable instructions are stored, and when the computer-readable instructions are executed by a processor, the route planning method as described above is implemented.

[0040] The above-mentioned route planning method, device, computer equipment and storage medium, the method implementation includes: determining the shortest path between the target starting point and the target end point; based on the shortest path, expanding to obtain a set of waypoints, the set of waypoints includes multiple waypoints; based on the waypoints, generating multiple candidate paths; screening the multiple candidate paths to obtain the target path. In the embodiment of the present application, by screening the waypoints, and performing path finding and path solving operations based on the waypoints, multiple paths are obtained according to the starting point and the end point, the diversity of route planning is improved, and dynamic data is supported, so that the route is closer to actual use and the practicality is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments of the present application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0042] Figure 1 is a flow chart of a route planning method in one embodiment of the present application;

[0043] Figure 2 is a structural schematic diagram of a route planning device in one embodiment of the present application;

[0044] Figure 3 It is a schematic diagram of a computer device in one embodiment of the present application. DETAILED DESCRIPTION

[0045] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0046] In one embodiment, if Figure 1 As shown, a route planning method is provided, comprising the following steps:

[0047] In step S110, the shortest path between the target starting point and the target end point is determined;

[0048] Optionally, the shortest path between the target starting point and the target end point can be calculated by the CH algorithm. The CH algorithm can include two sets of weight graphs, namely, a time weight graph and a distance weight graph. The time weight graph is a graph structure constructed by using nodes to represent key elements such as geographic locations and edges with weights representing time costs. The distance weight graph is a graph structure constructed by using nodes to represent key elements such as geographic locations and edges with weights representing distances.

[0049] Taking the time weight graph as an example, the determination of the shortest path is explained: the time weight graph can be preprocessed first. For example, the nodes in the graph can be shrunk. That is, some nodes can be selected, and the edges connecting the nodes can be simplified in a specific way to form a hierarchical structure. For example, for a time weight graph of a traffic network, those nodes that connect many roads and have relatively stable traffic flow and are less likely to become path bottlenecks may be selected first for shrinking, and their adjacent edges will be rearranged to construct new connection relationships and weight calculation methods between nodes, and finally the entire graph is converted into a structure with hierarchical characteristics. Based on the hierarchical structure formed after preprocessing, you can search downward from the starting point and search upward from the end point at the same time. During the search process, the time weight of the edge will be used to determine which path is better, and gradually approach each other until a path connecting the starting point and the end point is found, that is, the shortest path, that is, the path with the smallest total time cost. Similarly, the shortest path can also be determined through the distance weight graph.

[0050] Among them, the nodes in the time weight graph can represent places, the edges represent the roads connecting the places, etc., and the weight on the edge represents the time required to pass through this road.

[0051] It should be noted that, in addition to the CH algorithm described above, other algorithms such as the Dijkstra algorithm and the Bellman-Ford algorithm may also be used to determine the shortest path between a target starting point and a target end point.

[0052] In step S120, based on the shortest path, a waypoint set is expanded, and the waypoint set includes a plurality of waypoints;

[0053] In the embodiment of the present application, after the shortest path is obtained, since the weight of low-level roads is relatively large and usually does not affect the route diversity, the low-level roads within the preset range near the target starting point and the target end point can be cut off, such as the roads inside the community, etc., and a new road with a new starting point and end point can be obtained, which is recorded as s1 and t1 for subsequent path finding and solution.

[0054] Starting from s1 and t1, a preset algorithm, such as the Dijkstra algorithm, can be executed to expand on the CH time weight graph and collect all the waypoints expanded to, and the expansion is stopped when the expansion weight reaches the optimal route weight. The waypoints collected by expanding s1 and the waypoints collected by expanding t1 can be stored and recorded as set1 and set2 respectively.

[0055] In step S130, a plurality of candidate routes are generated based on the waypoints;

[0056] Optionally, after obtaining the waypoints, the waypoints can be brought into the CRP algorithm, and the CRP algorithm can be used to perform bidirectional pathfinding from the starting point and the end point respectively, using the waypoints as meeting points. During the pathfinding process, the paths explored in the two directions can be tried to "meet" at these waypoints that are regarded as meeting points, so as to construct a reasonable route. Then, based on the constructed multiple routes, according to these meeting points, more than one route that passes through all or part of the waypoints, i.e., candidate paths, can be obtained.

[0057] It should be noted that the depth-first search (DFS) algorithm or the breadth-first search (BFS) algorithm can also be used to generate candidate paths. For example, taking the DFS algorithm as an example, you can start from the starting point and use the depth-first search method to explore the path. Each time you encounter a branch node, give priority to selecting a branch to continue to go deeper. When you encounter the first waypoint, record the part of the path that has been passed, and continue to perform a depth-first search from this waypoint, with the goal of the next waypoint. Repeat this process until you pass all the waypoints and reach the end point. In this process, due to the backtracking characteristics of the depth-first search, multiple different path branches will be generated, and these branches constitute multiple candidate paths.

[0058] In step S140, the plurality of candidate paths are screened to obtain a target path.

[0059] Optionally, for each candidate path, a path of a preset distance, such as 1 km, can be intercepted toward the starting point and the end point starting from the waypoints on the path to form a path segment. Then, based on the waypoints on the path segment, the CRP algorithm, the depth-first search (DFS) algorithm combined with the waypoint restriction method are used to recalculate the path. Then, it can be determined whether the weight of the new path obtained by the recalculation is better than the weight of the candidate path. If so, the candidate path is filtered out. If not, the candidate path is output as the target path.

[0060] In an embodiment of the present application, a route planning method is provided, including: determining the shortest path between a target starting point and a target end point; based on the shortest path, expanding a waypoint set, the waypoint set including multiple waypoints; based on the waypoints, generating multiple candidate paths; screening the multiple candidate paths to obtain a target path. In an embodiment of the present application, by screening waypoints and performing path finding and path solving operations based on the waypoints, multiple paths are obtained according to the starting point and the end point, thereby improving the diversity of route planning, and supporting dynamic data, so that the route is closer to actual use and improves practicality.

[0061] In an embodiment of the present application, the step of expanding a set of waypoints based on the shortest path includes:

[0062] On the shortest path, cutting low-level roads within a preset range between the target starting point and the target end point to obtain a new shortest path;

[0063] Based on the new shortest path, determine a new starting point and a new end point;

[0064] The waypoints are expanded based on the new starting point and the new end point to obtain the waypoint set.

[0065] Optionally, after obtaining the shortest path, since the weight of low-level roads is relatively large and usually does not affect route diversity, the low-level roads within a preset range near the target starting point and the target end point can be cut off, such as roads inside a community, etc. At this time, a new road with a new starting point and end point can be obtained, which is recorded as s1 and t1 for subsequent path finding and solution.

[0066] Starting from s1 and t1, a preset algorithm, such as the Dijkstra algorithm, can be executed to expand on the CH time weight graph. Specifically, all edges connected to the nodes where s1 and t1 are located can be checked, and then the adjacent nodes can be reached along these edges, and these adjacent nodes can be included in the set of nodes that have been expanded. For example, there is a node A in the CH time weight graph, which is connected to nodes B and C through edges. When node A is expanded, nodes B and C will be found and marked as nodes that have been expanded. For the newly expanded nodes, such as the above-mentioned nodes B and C, the above-mentioned operation of checking the connected edges and finding new adjacent nodes along the edges is repeated again, and the exploration range is continuously expanded outward. In the above-mentioned continuous expansion process, all the newly expanded nodes need to be recorded in each step to form a set. This set contains all the nodes that can be reached according to the expansion rules starting from the initial node until the preset expansion stop condition is met, and the expansion stops. This node refers to a waypoint. At this time, the waypoints collected by extending s1 and the waypoints collected by extending t1 can be stored and recorded as set1 and set2 respectively.

[0067] It should be noted that low-grade roads usually refer to those roads that are relatively weak in terms of traffic functions, design standards, and traffic capacity, such as internal roads in residential areas and country roads.

[0068] In one embodiment of the present application, the waypoints are expanded based on the new starting point and the new end point to obtain the waypoint set, including:

[0069] The new starting point and the new end point are respectively expanded by a first preset algorithm, and when the expansion weight reaches the optimal path weight, the expansion is stopped to obtain a first path point subset and a second path point subset;

[0070] The waypoint set is determined based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path.

[0071] It can be understood that the expansion weight refers to a comprehensive cost value representing the current expansion situation that is calculated and accumulated as the expansion process continues, such as a value related to time cost. The optimal route weight refers to a weight value that is determined in advance based on historical information, a given ideal standard, etc., and represents the optimal route. Therefore, when the expansion weight calculated during the expansion process reaches this optimal route weight, it may have covered the key information such as nodes required to build the optimal route. At this time, the optimal path can be obtained, so there is no need to continue the outward expansion operation, and the entire expansion process can be ended. At this time, the first path point subset set1 and the second path point subset set2 can be obtained. Then, according to the distance of the optimal path, the first path point subset set1 and the second path point subset set2 can be used to obtain the path point set.

[0072] It should be noted that the first preset algorithm may also be a breadth-first search (Breadth-First Search, BFS), a Floyd-Warshall algorithm, etc.

[0073] In one embodiment of the present application, determining the set of waypoints based on the distance of the optimal path includes:

[0074] When the distance of the optimal path is greater than a preset distance threshold, obtaining an intersection of the first subset of waypoints and the second subset of waypoints;

[0075] In the optimal path, determining waypoints of high-level roads and generating a third waypoint subset;

[0076] A first union of the third waypoint subset and the intersection is obtained as a waypoint set.

[0077] Optionally, when the distance of the optimal path is greater than a preset distance threshold, for example, greater than 5 kilometers, the intersection between the first subset of waypoints and the second subset of waypoints can be calculated as intersection set3, so that the collected waypoints are more concentrated in the middle of the route. Then, in the optimal path, the points mid, s1-mid and mid-t1 with half the weight can be found, and the Dijkstra algorithm is called to expand on the CH time weight graph respectively, and the expansion points are collected. Then the collected points are taken as a union, the points in the union are traversed, and the attributes of the road they are on are analyzed. If it is a high-level road, it is collected. The collected points and set3 are taken as a union and recorded as set4 as a waypoint set.

[0078] It should be noted that high-grade roads refer to those with strong traffic functions and are the backbone of transportation. They have wide roads and usually have multiple lanes. For example, expressways, first-class highways, urban expressways, etc.

[0079] In one embodiment of the present application, determining the set of waypoints based on the distance of the optimal path includes:

[0080] When the distance of the optimal path is less than or equal to the preset distance threshold, the new starting point and the new end point are expanded by a second preset algorithm to obtain a fourth waypoint subset and a fifth waypoint subset;

[0081] A second union of the first waypoint subset, the second waypoint subset, the third waypoint subset and the fourth waypoint subset is obtained as the waypoint set.

[0082] Optionally, when the distance of the optimal path is less than or equal to a preset distance threshold, for example, less than 1 km, an auxiliary graph is used to collect waypoints. Specifically, a breadth-first search (BFS) can be used to perform an extended search on the CH distance weight graph, and two searches are performed from s1 and t1 respectively. The points extended during the two searches are recorded as set5 and set6. When the extended weight reaches the weight of the shortest path, the search ends. At this time, the union of set1, set2, set5, and set6 is calculated and recorded as set7 as the waypoint set.

[0083] It should be noted that the weight of the shortest path refers to the weight value of the path with the smallest sum of weights among all possible paths from the starting point to the end point in the CH time weight graph. The weight value can represent various practical meanings, such as distance, time, cost, etc.

[0084] It should be noted that the second preset algorithm may also be a Dijkstra algorithm, a Floyd-Warshall algorithm, etc.

[0085] Among them, the CH distance weight graph is used to represent the location relationship and distance information in geographic space or other network environments. Nodes are usually geographical locations, edges represent the connection paths between these nodes, and each edge carries a weight representing the distance.

[0086] In an embodiment of the present application, screening the plurality of candidate paths to obtain a target path includes:

[0087] Recalculate each candidate path to obtain a new path;

[0088] When the weight of the new path is less than the weight of the candidate path, the corresponding candidate path is used as the target path.

[0089] Optionally, for each candidate path, a CRP algorithm, a depth-first search (DFS) algorithm, etc. can be used to recalculate the path, and then it can be determined whether the weight of the new path obtained by the recalculation is better than the weight of the candidate path. If so, the candidate path is filtered out, if not, the candidate path is output as the target path.

[0090] In an embodiment of the present application, recalculating each candidate path to obtain a new path includes:

[0091] In each candidate path, starting from the target waypoint, a path segment of a preset distance is intercepted in the starting direction and the ending direction of each candidate path;

[0092] The waypoints on the path segment are used as meeting points to perform bidirectional path finding to obtain the new path.

[0093] Optionally, for each candidate path, a path of a preset distance, such as 1 km, can be intercepted toward the starting point and the end point from the waypoints on the path to form a path segment, and then the path can be recalculated based on the waypoints on the path segment using the CRP algorithm, the depth-first search (DFS) algorithm, etc. For example, the waypoints can be brought into the CRP algorithm, and the CRP algorithm can be used to perform bidirectional pathfinding from the starting point and the end point respectively using the waypoints as meeting points. During the pathfinding process, the paths explored in the two directions can be managed to "meet" at these waypoints that are regarded as meeting points, so as to construct a new path.

[0094] In an embodiment of the present application, generating a plurality of candidate paths based on the waypoints includes:

[0095] Using the waypoint as a meeting point to perform bidirectional path finding, to obtain a plurality of forward path segments and a reverse path segment;

[0096] The forward path segment and the reverse path segment are spliced ​​at the meeting point to form a plurality of candidate paths.

[0097] Optionally, starting from the starting point, a preset search rule, such as a breadth-first search or a heuristic search method, can be used to expand outward. During the expansion process, factors such as the distance, time, and traffic conditions of the path can be considered. When expanding to the first waypoint, the waypoint can be recorded as the meeting point of the forward search, and the meeting point can be recorded, such as the path length, the nodes passed, etc. Similarly, a reverse search can be performed for the end point, and the meeting point of the reverse search can be recorded. When the forward search and the reverse search meet at a certain waypoint (that is, the waypoint is marked by searches in both the forward and reverse directions at the same time), an attempt can be made to construct a complete path passing through the waypoint. This path is composed of the part that reaches the waypoint by the forward search, that is, the forward path segment, and the part that reaches the waypoint by the reverse search, that is, the reverse path segment, which is a candidate path. Since there are multiple waypoints, the above-mentioned two-way path finding and meeting point matching process can be repeated to obtain multiple candidate paths.

[0098] In the embodiment of the present application, by screening waypoints and performing pathfinding and path solving operations based on the waypoints, multiple paths can be obtained according to the starting point and the end point, thereby improving the diversity of route planning. The point information expanded on the CH map can be used to restore the route using the CRP algorithm. Combining the advantage of CRP supporting dynamic data, the route is closer to actual use and the practicality is improved. When extending the waypoints, different logics can be respectively corresponded according to the route distance, which ensures the output effect of multiple routes while also ensuring the performance of the long-distance multi-route algorithm. The purpose of planning multiple routes is achieved, while also taking into account performance and route effects.

[0099] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0100] In one embodiment, a route planning device is provided, which corresponds one-to-one to the route planning method in the above embodiment. Figure 2 As shown, the route planning device includes a shortest path determination unit 10, a waypoint set acquisition unit 20, a candidate path generation unit 30 and a target path acquisition unit 40. Each functional module is described in detail as follows:

[0101] The shortest path determination unit 10 is used to determine the shortest path between the target starting point and the target end point;

[0102] A waypoint set acquisition unit 20, configured to expand a waypoint set based on the shortest path, wherein the waypoint set includes a plurality of waypoints;

[0103] A candidate path generating unit 30, configured to generate a plurality of candidate paths based on the waypoints;

[0104] The target path acquisition unit 40 is used to screen the multiple candidate paths to obtain a target path.

[0105] In one embodiment of the present application, the waypoint set acquisition unit 20 is further configured to:

[0106] On the shortest path, cutting low-level roads within a preset range between the target starting point and the target end point to obtain a new shortest path;

[0107] Based on the new shortest path, determine a new starting point and a new end point;

[0108] The waypoints are expanded based on the new starting point and the new end point to obtain the waypoint set.

[0109] In one embodiment of the present application, the waypoint set acquisition unit 20 is further configured to:

[0110] The new starting point and the new end point are respectively expanded by a first preset algorithm, and when the expansion weight reaches the optimal path weight, the expansion is stopped to obtain a first path point subset and a second path point subset;

[0111] The waypoint set is determined based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path.

[0112] In one embodiment of the present application, the waypoint set acquisition unit 20 is further configured to:

[0113] When the distance of the optimal path is greater than a preset distance threshold, obtaining an intersection of the first subset of waypoints and the second subset of waypoints;

[0114] In the optimal path, determining waypoints of high-level roads and generating a third waypoint subset;

[0115] A first union of the third waypoint subset and the intersection is obtained as a waypoint set.

[0116] In one embodiment of the present application, the waypoint set acquisition unit 20 is further configured to:

[0117] When the distance of the optimal path is less than or equal to the preset distance threshold, the new starting point and the new end point are expanded by a second preset algorithm to obtain a fourth waypoint subset and a fifth waypoint subset;

[0118] A second union of the first waypoint subset, the second waypoint subset, the third waypoint subset and the fourth waypoint subset is obtained as the waypoint set.

[0119] In an embodiment of the present application, the target path acquisition unit 40 is further configured to:

[0120] Recalculate each candidate path to obtain a new path;

[0121] When the weight of the new path is less than the weight of the candidate path, the corresponding candidate path is used as the target path.

[0122] In an embodiment of the present application, the target path acquisition unit 40 is further configured to:

[0123] In each candidate path, starting from the target waypoint, a path segment of a preset distance is intercepted in the starting direction and the ending direction of each candidate path;

[0124] The waypoints on the path segment are used as meeting points to perform bidirectional path finding to obtain the new path.

[0125] In one embodiment of the present application, the candidate path generation unit 30 is further configured to:

[0126] Using the waypoint as a meeting point to perform bidirectional path finding, to obtain a plurality of forward path segments and a reverse path segment;

[0127] The forward path segment and the reverse path segment are spliced ​​at the meeting point to form a plurality of candidate paths.

[0128] In the embodiment of the present application, by screening waypoints and performing pathfinding and path solving operations based on the waypoints, multiple paths can be obtained according to the starting point and the end point, thereby improving the diversity of route planning. The point information expanded on the CH map can be used to restore the route using the CRP algorithm. Combining the advantage of CRP supporting dynamic data, the route is closer to actual use and the practicality is improved. When extending the waypoints, different logics can be respectively corresponded according to the route distance, which ensures the output effect of multiple routes while also ensuring the performance of the long-distance multi-route algorithm. The purpose of planning multiple routes is achieved, while also taking into account performance and route effects.

[0129] For the specific definition of the route planning device, please refer to the definition of the route planning method above, which will not be repeated here. Each module in the above route planning device can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0130] In one embodiment, a computer device is provided. The computer device may be a terminal device, and its internal structure diagram may be as follows: Figure 3 As shown. The computer device includes a processor, a memory, and a network interface connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a readable storage medium. The readable storage medium stores computer-readable instructions. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer-readable instructions are executed by the processor, a route planning method is implemented. The readable storage medium provided in this embodiment includes a non-volatile readable storage medium and a volatile readable storage medium.

[0131] In an embodiment of the present application, a computer device is provided, including a memory, a processor, and computer-readable instructions stored in the memory and executable on the processor, and when the processor executes the computer-readable instructions, the steps of the route planning method described above are implemented.

[0132] In an embodiment of the application, a readable storage medium is provided, wherein the readable storage medium stores computer-readable instructions, and when the computer-readable instructions are executed by a processor, the steps of the route planning method as described above are implemented.

[0133] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing related hardware through computer-readable instructions, and the computer-readable instructions can be stored in a non-volatile readable storage medium or a volatile readable storage medium. When the computer-readable instructions are executed, they may include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0134] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0135] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. A route planning method, characterized in that: The method comprises: Determine the shortest path between the target starting point and the target end point; Based on the shortest path, a waypoint set is expanded, wherein the waypoint set includes a plurality of waypoints; Based on the waypoints, generating a plurality of candidate routes; The plurality of candidate paths are screened to obtain a target path.

2. The route planning method according to claim 1, characterized in that: The step of expanding a waypoint set based on the shortest path includes: On the shortest path, cutting low-level roads within a preset range between the target starting point and the target end point to obtain a new shortest path; Based on the new shortest path, determine a new starting point and a new end point; The waypoints are expanded based on the new starting point and the new end point to obtain the waypoint set.

3. The route planning method according to claim 2, characterized in that: The step of expanding the waypoints based on the new starting point and the new end point to obtain the waypoint set includes: The new starting point and the new end point are respectively expanded by a first preset algorithm, and when the expansion weight reaches the optimal path weight, the expansion is stopped to obtain a first path point subset and a second path point subset; The waypoint set is determined based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path.

4. The route planning method according to claim 3, characterized in that: The determining of the waypoint set based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path includes: When the distance of the optimal path is greater than a preset distance threshold, obtaining an intersection of the first subset of waypoints and the second subset of waypoints; In the optimal path, determining waypoints of high-level roads and generating a third waypoint subset; A first union of the third waypoint subset and the intersection is obtained as a waypoint set.

5. The route planning method according to claim 3, characterized in that: The determining of the waypoint set based on the first waypoint subset, the second waypoint subset, and the distance of the optimal path includes: When the distance of the optimal path is less than or equal to the preset distance threshold, the new starting point and the new end point are expanded by a second preset algorithm to obtain a fourth waypoint subset and a fifth waypoint subset; A second union of the first waypoint subset, the second waypoint subset, the third waypoint subset and the fourth waypoint subset is obtained as the waypoint set.

6. The path planning method according to claim 1, characterized in that: The screening of the plurality of candidate paths to obtain a target path includes: Recalculate each candidate path to obtain a new path; When the weight of the new path is less than the weight of the candidate path, the corresponding candidate path is used as the target path.

7. The path planning method according to claim 6, characterized in that: The recalculating each candidate path to obtain a new path includes: In each candidate path, starting from the target waypoint, a path segment of a preset distance is intercepted in the starting direction and the ending direction of each candidate path; The waypoints on the path segment are used as meeting points to perform bidirectional path finding to obtain the new path.

8. The path planning method according to claim 1, characterized in that: The generating a plurality of candidate paths based on the waypoints comprises: Using the waypoint as a meeting point to perform bidirectional path finding, to obtain a plurality of forward path segments and a reverse path segment; The forward path segment and the reverse path segment are spliced ​​at the meeting point to form a plurality of candidate paths.

9. A route planning device, characterized in that: The device comprises: A shortest path determination unit, used to determine the shortest path between a target starting point and a target end point; A waypoint set acquisition unit, configured to expand a waypoint set based on the shortest path, wherein the waypoint set includes a plurality of waypoints; a candidate path generating unit, configured to generate a plurality of candidate paths based on the waypoints; The target path acquisition unit is used to screen the multiple candidate paths to obtain the target path.

10. A readable storage medium having computer readable instructions stored thereon, characterized in that: When the computer-readable instructions are executed by a processor, the route planning method according to any one of claims 1 to 7 is implemented.