Path planning starting point selection method and device, and electronic device
Patent Information
- Application Number
- CN202311280478.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-28
- Publication Date
- 2026-10-30
- Estimated Expiration
- 2043-09-28
AI Technical Summary
[0003]现有AGV路径规划方法通常假设移动对象处于拓扑地图的节点上等理想位置,然而在真实场景下由于人工干预、任务需求、移动对象异常等原因,会导致AGV处于非理想位置,此时若规划起点选择不恰当,会导致移动对象规划失败或行走较长的非固定路径,引入碰撞等风险
[0016]上述方案,通过获取移动对象的位姿参数以及路径地图,路径地图含有多个路径段,路径段用于连通两个路径节点,基于移动对象的位姿参数,计算移动对象相对每个路径段的路径段移动代价,从每个路径段中选取出路径段移动代价满足预设条件的路径段,将被选中的路径段对应的路径节点作为候选起点,以提高选取候选起点的准确性,避免因起点选择不恰当导致移动对象行走较长的非固定路径或需要大范围旋转引入碰撞风险的问题,然后,对候选起点进行路径规划验证,将验证通过的候选起点作为目标起点,以在起点选择不恰当导致规划失败后可更换起点,提高起点选择的效率。
Smart Images

Figure CN117419721B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of path planning technology, and in particular to a method, apparatus and electronic device for selecting the starting point of path planning. Background Technology
[0002] In factories, to reduce problems such as collisions, congestion and management difficulties caused by Automated Guided Vehicles (AGVs) traveling on non-fixed paths, a topology map of the AGV's possible paths is usually created based on the actual factory environment. Path planning is then carried out based on the topology map, and finally, positioning markers and AGV positioning devices are used to guide the AGV to follow the preset route to complete the task.
[0003] Existing AGV path planning methods typically assume that the moving object is in an ideal position, such as a node on the topology map. However, in real-world scenarios, due to factors such as human intervention, task requirements, and abnormalities of the moving object, the AGV may be in a non-ideal position. If the starting point is not chosen appropriately, the moving object may fail to plan or travel a long non-fixed path, introducing risks such as collisions. Summary of the Invention
[0004] This application provides at least one method for selecting the starting point of path planning, a device for selecting the starting point of path planning, and an electronic device.
[0005] The first aspect of this application provides a method for selecting a starting point in path planning, comprising: obtaining the pose parameters of a moving object and a path map, the path map containing multiple path segments, the path segments being used to connect two path nodes; calculating the path segment movement cost of the moving object relative to each path segment based on the pose parameters of the moving object; selecting path segments from each path segment whose path segment movement cost meets preset conditions, and using the path nodes corresponding to the selected path segments as candidate starting points; performing path planning verification on the candidate starting points, and using the verified candidate starting points as the target starting point.
[0006] In one embodiment, the pose parameters include the position and orientation of the moving object; based on the pose parameters of the moving object, the path segment movement cost of the moving object relative to each path segment is calculated, including: calculating the distance between the position of the moving object and the position of the path segment to obtain the distance cost; and calculating the rotation angle cost of the orientation of the moving object relative to the path segment; based on the distance cost and the angle cost, the path segment movement cost corresponding to the path segment is obtained.
[0007] In one embodiment, calculating the rotation angle cost of the pose of a moving object relative to a path segment includes: obtaining the path direction of the path segment; determining the rotation angle of the moving object relative to the path segment based on the path direction of the path segment and the pose of the moving object, thereby obtaining the rotation angle cost.
[0008] In one embodiment, the path segment movement cost of the moving object relative to each path segment is calculated based on the pose parameters of the moving object, including: obtaining the path nodes contained in the path map and obtaining the target range of the selected point corresponding to the moving object; selecting the path nodes located within the target range of the selected point to obtain a preliminary set of path nodes; determining all path segments associated with each path node in the preliminary set of path nodes to obtain a set of path segments; and calculating the path segment movement cost of the moving object relative to each path segment in the set of path segments based on the pose parameters of the moving object.
[0009] In one embodiment, selecting path segments whose path segment movement costs satisfy preset conditions from each path segment, and using the path nodes corresponding to the selected path segments as candidate starting points, includes: calculating the distance between each path node in the initial screening path node set and the moving object to obtain the node movement cost corresponding to each path node in the initial screening path node set; selecting path segments whose path segment movement costs and node movement costs satisfy preset conditions from the path segment set, and using the path nodes corresponding to the selected path segments as candidate starting points.
[0010] In one embodiment, selecting path segments from the path segment set whose path segment movement cost and node movement cost satisfy preset conditions, and using the path nodes corresponding to the selected path segments as candidate starting points, includes: selecting path nodes from the initial screening path node set whose node movement costs satisfy preset conditions; using path segments in the path segment set associated with the selected path nodes as candidate path segments; sorting each candidate path segment based on the path segment movement cost; selecting each candidate path segment based on the sorting result; and using the path nodes corresponding to the selected candidate path segments as candidate starting points.
[0011] In one embodiment, the path node corresponding to the selected path segment is used as a candidate starting point, including: obtaining the path direction of the selected path segment and obtaining each path node corresponding to the selected path segment to obtain a pre-selected starting point; and selecting a candidate starting point from each pre-selected starting point based on the distance between the moving object and each pre-selected starting point and the path direction of the selected path segment.
[0012] In one embodiment, the path planning verification of candidate starting points is performed, and the verified candidate starting points are used as target starting points. This includes: obtaining the endpoint location corresponding to the path planning task; performing path planning based on the candidate starting points, endpoint locations, and path map; if the path planning is successful, it is determined that the verification is passed, and the candidate starting point is used as the target starting point.
[0013] A second aspect of this application provides a starting point selection device for path planning, comprising: an acquisition module for acquiring pose parameters of a moving object and a path map, the path map containing multiple path segments, the path segments connecting two path nodes; a calculation module for calculating the path segment movement cost of the moving object relative to each path segment based on the pose parameters of the moving object; a selection module for selecting path segments from each path segment whose path segment movement cost meets preset conditions, and using the path nodes corresponding to the selected path segments as candidate starting points; and a verification module for verifying the path planning of the candidate starting points, and using the verified candidate starting points as the target starting point.
[0014] A third aspect of this application provides an electronic device, including a memory and a processor, wherein the processor is configured to execute program instructions stored in the memory to implement the above-described path planning starting point selection method.
[0015] The fourth aspect of this application provides a computer-readable storage medium having program instructions stored thereon, which, when executed by a processor, implement the above-described method for selecting the starting point of path planning.
[0016] The above scheme obtains the pose parameters of the moving object and a path map. The path map contains multiple path segments, which connect two path nodes. Based on the pose parameters of the moving object, the path segment movement cost of the moving object relative to each path segment is calculated. Path segments whose path segment movement costs meet preset conditions are selected from each path segment. The path nodes corresponding to the selected path segments are used as candidate starting points to improve the accuracy of candidate starting point selection and avoid the problem of the moving object traveling a long non-fixed path or needing a large range of rotation due to inappropriate starting point selection, which introduces the risk of collision. Then, path planning is verified on the candidate starting points, and the candidate starting points that pass the verification are used as target starting points. This allows the starting point to be changed if the planning fails due to inappropriate starting point selection, thereby improving the efficiency of starting point selection.
[0017] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this application. Attached Figure Description
[0018] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with this application and, together with the specification, serve to explain the technical solutions of this application.
[0019] Figure 1 This is a schematic diagram of an implementation environment for an exemplary embodiment of the path planning starting point selection method of this application;
[0020] Figure 2 This is a flowchart of an exemplary embodiment of the path planning starting point selection method of this application;
[0021] Figure 3 This is an exemplary embodiment of the present application illustrating two cases of calculating the nearest point between a moving object and a path segment;
[0022] Figure 4 This is a schematic diagram illustrating path node filtering in an exemplary embodiment of this application;
[0023] Figure 5 This is an exemplary embodiment of the data structure for initially screening the set of path nodes and the set of path segments, as shown in this application.
[0024] Figure 6 This is an exemplary embodiment of the present application illustrating a scenario where the distance cost is 0;
[0025] Figure 7 This is a schematic diagram illustrating the path directions contained in a path segment as shown in an exemplary embodiment of this application;
[0026] Figure 8 This is a schematic diagram illustrating the determination of a rotation angle, as shown in an exemplary embodiment of this application;
[0027] Figure 9 This is a block diagram illustrating a path planning start point selection device in an exemplary embodiment of this application;
[0028] Figure 10 This is a schematic diagram of the structure of an electronic device shown in an exemplary embodiment of this application;
[0029] Figure 11 This is a schematic diagram illustrating the structure of a computer-readable storage medium, as shown in an exemplary embodiment of this application. Detailed Implementation
[0030] The embodiments of this application will now be described in detail with reference to the accompanying drawings.
[0031] In the following description, specific details such as particular system architectures, interfaces, and technologies are presented for illustrative purposes rather than for limiting purposes, in order to provide a thorough understanding of this application.
[0032] In this document, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " generally indicates that the preceding and following related objects have an "or" relationship. Furthermore, "many" in this document means two or more. Moreover, the term "at least one" in this document means any combination of at least two of any one or more of a plurality of objects. For example, including at least one of A, B, and C can mean including any one or more elements selected from the set consisting of A, B, and C.
[0033] Please see Figure 1 , Figure 1 This is a schematic diagram of an implementation environment involved in the path planning start point selection method in this application. For example... Figure 1 As shown, the implementation environment includes a mobile object 110 and a server 120, which can be directly or indirectly connected via wired or wireless communication.
[0034] The mobile object 110 can move within a corresponding mobile scenario based on a path map. The mobile object 110 can be an automated guided vehicle (AGV) or other mobile devices; this application does not impose any limitations on this. The mobile object 110 can refer to one of multiple mobile objects; this embodiment only uses mobile object 110 as an example. Those skilled in the art will understand that the number of mobile objects can be more or less. For example, there may be only one mobile object, or there may be dozens or hundreds, or even more. In this case, the implementation environment of the path planning starting point selection method also includes other mobile objects. This application does not limit the number of mobile objects or the type of equipment.
[0035] Server 120 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.
[0036] Optionally, server 120 may be responsible for selecting the starting point of the primary path planning, and mobile object 110 may be responsible for selecting the starting point of the secondary path planning; or server 120 may be responsible for selecting the starting point of the secondary path planning, and mobile object 110 may be responsible for selecting the starting point of the primary path planning; or server 120 or mobile object 110 may each be responsible for selecting the starting point of the path planning independently.
[0037] For example, the mobile object 110 sends a path planning start point selection instruction to the server 120. The path planning start point selection instruction carries the pose parameters of the mobile object 110. The server 120 calculates the path segment movement cost of the mobile object 110 relative to the path segment in the path map based on the pose parameters sent by the mobile object 110 and the pre-stored path map. The server 120 takes the path node corresponding to the path segment whose path segment movement cost meets the preset condition as the candidate start point. After the path planning verification of the candidate start point is passed, the server 120 takes the candidate start point as the target start point and sends the target start point to the mobile object 110. The mobile object 110 moves according to the target start point to return to the ideal position marked in the path map and performs subsequent path planning.
[0038] It is understood that in the specific embodiments of this application, data such as pose parameters and path maps are involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.
[0039] Please refer to Figure 2 The diagram illustrates a flowchart of a path planning start-point selection method according to an embodiment of this application. This method can be applied to a computer device, which refers to an electronic device capable of data computation and processing. For example, the executing entity for each step could be... Figure 1 The mobile object 110 or server 120 in the illustrated operating environment. It should be understood that this method can also be applied to other exemplary implementation environments and specifically executed by devices in other implementation environments. This embodiment does not limit the implementation environment to which this method is applicable.
[0040] The following section will describe in detail the path planning starting point selection method proposed in this application embodiment, using the server as the specific execution entity.
[0041] like Figure 2 As shown, in an exemplary embodiment, the starting point selection method for path planning includes at least steps S210 to S240, which are described in detail below:
[0042] Step S210: Obtain the pose parameters of the moving object and the path map. The path map contains multiple path segments, which are used to connect two path nodes.
[0043] The pose parameters indicate the position and orientation of the moving object in a preset coordinate system. The path map guides the movement of the moving object; it can be a topological map consisting of path nodes and path segments connecting two path nodes.
[0044] Here's an example illustrating how to obtain the pose parameters of a moving object:
[0045] For example, the pose parameters of a moving object can be obtained by deploying a positioning device on the moving object, such as a lidar scanning device or an image acquisition device. The moving object's pose parameters are obtained by scanning or acquiring images of the environment in which it is located, and then sent to the server based on the analysis of the scanning or image acquisition results.
[0046] For example, the pose parameters of a moving object can be obtained by having a pose parameter acquisition device relative to the moving object device. The pose parameter acquisition device is used to acquire the pose parameters of the moving object. For example, the pose parameters of the moving object can be acquired based on LiDAR scanning, image acquisition, or other methods, and then the pose parameters are sent to the server.
[0047] Alternatively, wireless carrier positioning technology, radio frequency identification (RFID) positioning technology, etc., can also be used to locate mobile objects, and this application does not limit this.
[0048] Here's an example illustrating how to obtain a route map:
[0049] For example, the server may store path maps, which can be retrieved by querying. For instance, the server stores a corresponding path map for each type of moving object. In addition to receiving the pose parameters of the moving object, the server also receives the type identifier of the moving object, and queries the path map that matches the moving object based on the type identifier.
[0050] In some implementations, after obtaining a path map matching the moving object based on the above embodiments, the path map can be extracted based on the pose parameters of the moving object, and the extracted path map can be used as the final path map. For example, the server pre-divides the stored path map into multiple regions, obtaining multiple region maps. The server determines the regions adjacent to the moving object based on the pose parameters of the moving object, extracts and combines the region maps corresponding to these regions as the final path map, thereby reducing the subsequent computational workload and improving computational efficiency.
[0051] Step S220: Based on the pose parameters of the moving object, calculate the path segment movement cost of the moving object relative to each path segment.
[0052] The path segment movement cost is used to indicate the resources required for a moving object to move to the path segment. For example, the resources consumed can be time, movement distance, power consumption, etc. The specific resources can be flexibly selected according to the actual application situation, and this application does not limit them.
[0053] Calculate the path segment movement cost of the moving object relative to the path segment by using the pose parameters of the moving object.
[0054] The standard for calculating the cost of moving along a path segment can be: the resources required for the moving object to move to the nearest point on the path segment. Please refer to [link to relevant documentation]. Figure 3 , Figure 3 This illustrates two cases for calculating the nearest point between a moving object and a path segment, such as... Figure 3 As shown, there are two positional relationships between a moving object and a path segment: one where the moving object is within the path segment, determined by the projection of the moving object relative to the path segment falling between or on two path nodes; and the other where the moving object is outside the path segment, determined by the projection of the moving object relative to the path segment falling on the extension of the path segment. Figure 3 Taking the scenario shown as an example, if the moving object is within the path segment, the closest point between the moving object and the path segment is the position of the path segment where the projection of the moving object's reference point relative to the path segment is located; if the moving object is outside the path segment, the closest point between the moving object and the path segment is a path node of the path segment that is closest to the moving object.
[0055] The reference point for the moving object can be the center of gravity, centroid, etc. of the moving object, and this application does not limit this.
[0056] Step S230: Select path segments from each path segment whose path segment movement cost meets the preset conditions, and use the path nodes corresponding to the selected path segments as candidate starting points.
[0057] The preset conditions can be pre-set or flexibly generated according to the actual situation, such as the number of path segments in the path map, the pose parameters of the moving object, etc., to flexibly determine the preset conditions.
[0058] For example, a path segment that meets the preset conditions can be a path segment whose movement cost is less than a movement cost threshold, or a path segment that meets the preset conditions can be a path segment with the minimum movement cost. This application does not limit this.
[0059] Select path segments whose movement costs meet preset conditions, and use the path nodes corresponding to the selected path segments as candidate starting points.
[0060] Step S240: Perform path planning verification on the candidate starting points, and use the verified candidate starting points as the target starting points.
[0061] Among them, the path planning verification is used to check whether the candidate starting point can achieve the current path planning task. If it can, it is judged as a successful verification and the candidate starting point is used as the target starting point.
[0062] In some implementations, the candidate starting point is verified by path planning, and the verified candidate starting point is used as the target starting point. This includes: obtaining the endpoint location corresponding to the path planning task; performing path planning based on the candidate starting point, endpoint location, and path map; if the path planning is successful, it is determined that the verification is passed, and the candidate starting point is used as the target starting point.
[0063] The destination is the position that the moving object needs to reach in the current path planning task.
[0064] For example, the locations of candidate start and end points on the route map are determined, and all paths from the candidate start points to the end points are obtained based on the route map to obtain candidate routes. Further, a route of at least one day is selected from the above candidate routes as the target route based on a preset route selection strategy.
[0065] In this application embodiment, the criterion for determining whether path planning is successful is to determine whether there is a candidate path or whether there is a target path, etc. The specific criterion can be flexibly selected according to the actual application scenario, and this application does not limit it.
[0066] If the path planning verification of the candidate starting point is deemed successful, then the candidate starting point is taken as the target starting point.
[0067] Optionally, if there are multiple candidate starting points, each candidate starting point can be evaluated sequentially based on a preset selection strategy until the candidate starting point that is first verified as having passed path planning is selected as the target starting point. For example, each candidate starting point can be ranked based on at least one of the following criteria: distance between the candidate starting point and the moving object, path segments associated with the candidate starting point, and location of the candidate starting point on the path map. The ranking results are then used to evaluate each candidate starting point sequentially. Selecting the target starting point in this way yields path nodes that more easily allow the moving object to return to its ideal location on the path map.
[0068] Alternatively, path planning can be performed separately for each candidate starting point, and the target starting point can be determined based on the path planning results for each candidate starting point. For example, the target starting point can be selected from these candidate starting points based on at least one criterion, such as the number of candidate paths for the candidate starting point or the time required for the moving object to traverse the target path. This method of selecting the target starting point focuses more on the travel efficiency of the moving object on the target path obtained through subsequent path planning, thus improving the accuracy of path planning.
[0069] Alternatively, a comprehensive judgment can be made on each candidate starting point in conjunction with the above embodiments. For example, each candidate starting point can be scored based on at least one of the following criteria: the distance between the candidate starting point and the moving object, the path segment associated with the candidate starting point, and the location of the candidate starting point on the path map. Then, each candidate starting point can be scored based on at least one of the following criteria: the number of candidate paths for the candidate starting point and the time required for the moving object to traverse the target path. The comprehensive score of each candidate starting point is obtained by combining the results of the first and second scores, and the candidate starting point with the highest comprehensive score is selected as the target starting point to obtain a starting point position with higher overall performance.
[0070] In some implementations, if the path planning verification of a candidate starting point fails, the candidate starting point is deleted, and the next candidate starting point to be verified is selected for path planning verification, until a candidate starting point passes the path planning verification.
[0071] After obtaining the target starting point, the server can send the target starting point to the moving object so that the moving object can move to the target starting point; alternatively, after obtaining the target starting point, the server can obtain the target path based on the target starting point and the path planning task, and send both the target path and the target starting point to the moving object so that the moving object can move to the target starting point and move according to the target path. This application does not impose any restrictions on this.
[0072] In some implementations, the path segment movement cost of the moving object relative to each path segment is calculated based on the pose parameters of the moving object, including: obtaining the path nodes contained in the path map and obtaining the target range of the selected point corresponding to the moving object; selecting the path nodes located within the target range of the selected point to obtain a preliminary set of path nodes; determining all path segments associated with each path node in the preliminary set of path nodes to obtain a set of path segments; and calculating the path segment movement cost of the moving object relative to each path segment in the set of path segments based on the pose parameters of the moving object.
[0073] The selection of target areas can be determined based on the location of the moving object on the path map.
[0074] By selecting path nodes within the target area, a preliminary set of path nodes is obtained. This preliminary screening of the path nodes in the path map reduces the number of path segments in the path segment set, thereby reducing the workload of subsequent calculations and improving computational efficiency.
[0075] For example, please refer to Figure 4 , Figure 4 An exemplary embodiment of this application illustrates a path node filtering diagram, as follows: Figure 4As shown, the path map contains several path nodes. The area in the path map that is no more than the maximum selection radius from the moving object can be used as the selection target range. Path nodes located within the selection target range are selected to obtain the initial set of path nodes containing nodes a1, a2, a3, and a4.
[0076] Next, all path segments associated with each path node in the initial path node set are identified, resulting in a path segment set. For example, node a1 is associated with road segments b1, b2, and b5; node a2 is associated with road segments b2, b3, b4, and b6; node a3 is associated with road segments b5 and b7; and node a4 is associated with road segments b6, b7, and b8. All path segments associated with each path node are added to the path segment set, with deduplication performed during the addition process.
[0077] In some implementations, based on the above embodiments, selecting path segments whose path segment movement costs meet preset conditions from each path segment, and using the path nodes corresponding to the selected path segments as candidate starting points, includes: calculating the distance between each path node in the initial screening path node set and the moving object to obtain the node movement cost corresponding to each path node in the initial screening path node set; selecting path segments whose path segment movement costs and node movement costs meet preset conditions from the path segment set, and using the path nodes corresponding to the selected path segments as candidate starting points.
[0078] Among them, the node movement cost is used to indicate the resources required for a moving object to move to a path node. For example, the resources consumed can be time, movement distance, power consumption, etc. The specific resources can be flexibly selected according to the actual application situation, and this application does not limit them.
[0079] For example, in this embodiment, the node movement cost corresponding to the path node is obtained based on the distance between the path node and the moving object. This can be done by directly using the distance between the path node and the moving object as the node movement cost corresponding to the path node, or by normalizing the distance between the path node and the moving object to obtain the node movement cost corresponding to the path node. This application does not limit this.
[0080] Then, path segments whose path segment movement costs and node movement costs meet the preset conditions are selected from the path segment set. The path nodes corresponding to the selected path segments are used as candidate starting points to comprehensively consider the movement costs of path nodes and path segments relative to the moving objects in the path map, thereby improving the accuracy of starting point selection.
[0081] In some implementations, selecting path segments whose path segment movement costs and node movement costs satisfy preset conditions from the path segment set, and using the path nodes corresponding to the selected path segments as candidate starting points, includes: selecting path nodes whose node movement costs satisfy preset conditions from the initial screening path node set, and using the path segments associated with the selected path nodes in the path segment set as candidate path segments; sorting each candidate path segment based on the path segment movement cost, selecting each candidate path segment based on the sorting result; and using the path nodes corresponding to the selected candidate path segments as candidate starting points.
[0082] First, select path nodes whose node movement cost meets the preset conditions from the initial set of path nodes. The path nodes that meet the preset conditions can be path nodes whose node movement cost is less than the movement cost threshold, or path nodes whose node movement cost is the smallest. This application does not limit this.
[0083] Then, the path segments associated with the selected path node are obtained as candidate path segments. Each candidate path segment is sorted based on the path segment movement cost. Each candidate path segment is selected based on the sorting result. The selection method can be to select the path segment whose path segment movement cost is less than the movement cost threshold, or to select the path segment with the smallest path segment movement cost. This application does not limit this method.
[0084] For example, please refer to Figure 5 , Figure 5 This application provides a data structure for initially screening the set of path nodes and the set of path segments, such as... Figure 5 As shown, the initial set of path nodes and the set of path segments are stored together. Each member is a data unit, and each member corresponds to a path node. Each member stores the node number (such as node name), node movement cost, and set of connected path segments of its corresponding path node. The set of connected path segments stores multiple path segments associated with the path node. Each path segment corresponds to an adjacent node number and a path segment movement cost.
[0085] For example, with Figure 4 Taking the scenario shown as an example, the data storage method of node a1 is introduced. The node number of node a1 is a1, the node movement cost is the distance between node a1 and the moving object, and the set of connected path segments corresponding to node a1 contains path segments b1, b2 and b5. Among them, the adjacent point numbers of path segment b1 include a1 and a5, the adjacent point numbers of path segment b2 include a1 and a2, and the adjacent point numbers of path segment b5 include a1 and a3.
[0086] in, Figure 5When adding a new member, if there is a path segment in the set of connected path segments corresponding to the member that overlaps with a path segment in the set of connected path segments corresponding to an already added member, then when adding the member, the addition of that path segment is cancelled to avoid the same path segment existing in multiple objects, thereby reducing the amount of computation.
[0087] The following example further illustrates how the path segment movement cost is calculated:
[0088] In some implementations, the pose parameters include the position and orientation of the moving object; based on the pose parameters of the moving object, the path segment movement cost of the moving object relative to each path segment is calculated, including: calculating the distance between the position of the moving object and the position of the path segment to obtain the distance cost; and calculating the rotation angle cost of the orientation of the moving object relative to the path segment; based on the distance cost and the angle cost, the path segment movement cost corresponding to the path segment is obtained.
[0089] First, calculate the distance between the position of the moving object and the position of the path segment to obtain the distance cost.
[0090] The distance between the position of the moving object and the position of the path segment can be the Euclidean distance, such as... Figure 3 As shown, if the moving object is within the path segment, the distance cost is the distance from the moving object to the nearest point on the path segment; if the moving object is outside the path segment, the distance cost is the shortest distance from the moving object to the path nodes at both ends of the path segment. Wherein, as... Figure 6 As shown, if the moving object is on a path segment or at the endpoint of a path segment, the distance cost is 0; when the distance between the moving object and the path segment or the endpoint of the path segment is less than the positioning error of the moving object, the moving object is considered to be on the path segment or at the endpoint of the path segment.
[0091] Secondly, calculate the rotation angle cost of the moving object's pose relative to the path segment.
[0092] In some implementations, calculating the rotation angle cost of the moving object's pose relative to the path segment includes: obtaining the path direction of the path segment; determining the rotation angle of the moving object relative to the path segment based on the path direction of the path segment and the pose of the moving object, thereby obtaining the rotation angle cost.
[0093] Please see Figure 7 , Figure 7 This is a schematic diagram illustrating the path directions contained in the path segment shown in this application, such as... Figure 7 As shown, taking path node 1 of the path segment as the reference, the path direction of the path segment includes one-way out, one-way in, and two-way. Based on the path direction of the path segment and the pose of the moving object, the rotation angle of the moving object relative to the path segment is determined.
[0094] For example, based on the different orientations of the moving object's head as it traverses a path segment, the path can be categorized into forward direction, backward direction, and direction unrestricted. Based on this definition, the rotation angle is determined by the path direction of the path segment and the moving object's posture, as follows: Figure 8 As shown:
[0095] The path segment is unidirectional and the moving object is moving in the forward direction. The angle between the direction of the moving object's head and the ray direction from node 2 to node 1 is taken as the rotation angle θ.
[0096] The path segment is unidirectional and the moving object is moving backward. The angle between the direction of the moving object's tail and the ray direction from node 2 to node 1 is taken as the rotation angle θ.
[0097] The path segment is unidirectional and the moving object is moving in the forward direction. The rotation angle θ is the angle between the direction of the moving object's head and the ray direction from node 1 to node 2.
[0098] The path segment is unidirectional and the moving object is moving backward. The angle between the direction of the moving object's tail and the ray direction from node 1 to node 2 is taken as the rotation angle θ.
[0099] Specifically, if the path segment is bidirectional or the direction of the moving object is unrestricted, the smaller of the angles formed by the axis of the moving object and the path segment is taken as the rotation angle θ.
[0100] For example, after obtaining the rotation angle, the rotation angle cost is calculated based on the rotation angle. The calculation method can be as follows: calculate the time T that the moving object takes from triggering the rotation action to completing the rotation angle θ; then calculate the maximum distance D that the moving object can travel within time T, and the rotation angle cost = D.
[0101] It is understood that other calculation methods can also be used to calculate the rotation angle cost based on the rotation angle. For example, the rotation angle can be normalized to obtain the rotation angle cost. This application does not limit the calculation method of the rotation angle cost.
[0102] Furthermore, based on the distance cost and angle cost, the path segment movement cost corresponding to the path segment is obtained.
[0103] For example, the path segment movement cost can be obtained by weighted summation of distance cost and angle cost. The weight values of the weighted summation can be preset or flexibly selected according to the actual application scenario. For example, based on the above embodiment, the weight values corresponding to distance cost and angle cost can be flexibly selected according to the number of path nodes in the initial path node set, the number of path segments in the path segment set, the number of path segments associated with the selected path node, and the coordinates or type of the endpoint position in the current path planning task to be executed.
[0104] In some implementations, the path nodes corresponding to the selected path segment are used as candidate starting points, including: obtaining the path direction of the selected path segment and obtaining each path node corresponding to the selected path segment to obtain a pre-selected starting point; and selecting a candidate starting point from each pre-selected starting point based on the distance between the moving object and each pre-selected starting point and the path direction of the selected path segment.
[0105] As described above, if a path segment contains two path nodes, then the two path nodes corresponding to a selected path segment are used as pre-selected starting points. Based on the distance between the moving object and each pre-selected starting point and the path direction of the selected path segment, candidate starting points are selected from each pre-selected starting point.
[0106] For example, if the moving object is outside the path segment, the path node closer to the moving object at both ends is selected as the candidate starting point; if the moving object is inside the path segment and on a path node of the path segment, the path node where the moving object is located is selected as the candidate starting point; if the moving object is inside the path segment and the connectivity direction of the path segment is unidirectional, the path node pointed to by the connectivity direction is selected as the candidate starting point; if the moving object is inside the path segment and the connectivity direction of the path segment is bidirectional, the path node with the lower correction cost is selected as the candidate starting point. The correction cost can be obtained based on the direct distance between the path node and the moving object. For example, the correction cost is equal to the Manhattan distance from the path node to the moving object, assuming the coordinates of the moving object are (x...). a y a The coordinates of the path nodes are (x, y). b y b The formula for calculating Manhattan distance is: Manhattan distance = |x a -x b |+|y a -y b | where the reference coordinate system used for the coordinates can be parallel or perpendicular to the path segment.
[0107] The path planning starting point selection method provided in this application obtains the pose parameters of a moving object and a path map containing multiple path segments. Path segments are used to connect two path nodes. Based on the pose parameters of the moving object, the path segment movement cost of the moving object relative to each path segment is calculated. From each path segment, path segments whose path segment movement costs meet preset conditions are selected. The path nodes corresponding to the selected path segments are used as candidate starting points to improve the accuracy of candidate starting point selection and avoid the problem of the moving object traveling a long non-fixed path or needing a large range of rotation to introduce collision risks due to inappropriate starting point selection. Then, path planning is verified on the candidate starting points, and the candidate starting points that pass the verification are used as target starting points. This allows the starting point to be changed if the planning fails due to inappropriate starting point selection, thereby improving the efficiency of starting point selection.
[0108] Figure 9 This is a block diagram illustrating a path planning start-point selection device according to an exemplary embodiment of this application. Figure 9 As shown, the exemplary path planning start point selection device 900 includes: an acquisition module 910, a calculation module 920, a selection module 930, and a verification module 940. Specifically:
[0109] The acquisition module 910 is used to acquire the pose parameters of the moving object and the path map. The path map contains multiple path segments, which are used to connect two path nodes.
[0110] The calculation module 920 is used to calculate the path segment movement cost of the moving object relative to each path segment based on the pose parameters of the moving object.
[0111] The selection module 930 is used to select path segments whose movement costs meet preset conditions from each path segment, and the path nodes corresponding to the selected path segments are used as candidate starting points.
[0112] The verification module 940 is used to verify the path planning of candidate starting points and to use the candidate starting points that pass the verification as the target starting points.
[0113] In the above-described exemplary path planning starting point selection device, the pose parameters of the moving object and a path map are obtained. The path map contains multiple path segments, which are used to connect two path nodes. Based on the pose parameters of the moving object, the path segment movement cost of the moving object relative to each path segment is calculated. Path segments whose path segment movement costs meet preset conditions are selected from each path segment. The path nodes corresponding to the selected path segments are used as candidate starting points to improve the accuracy of candidate starting point selection and avoid the problem of the moving object traveling a long non-fixed path or needing to rotate a large range due to inappropriate starting point selection, which introduces the risk of collision. Then, the candidate starting points are verified for path planning. The candidate starting points that pass the verification are used as target starting points so that the starting point can be changed after the planning fails due to inappropriate starting point selection, thereby improving the efficiency of starting point selection.
[0114] The functions of each module can be found in the implementation example of the starting point selection method for path planning, and will not be repeated here.
[0115] Please see Figure 10 , Figure 10This is a schematic diagram of the structure of an embodiment of the electronic device of this application. The electronic device 1000 includes a memory 1001 and a processor 1002. The processor 1002 is used to execute program instructions stored in the memory 1001 to implement the steps in any of the above-described path planning start point selection method embodiments. In a specific implementation scenario, the electronic device 1000 may include, but is not limited to, a microcomputer or a server. In addition, the electronic device 1000 may also include mobile devices such as laptops and tablets, which are not limited here.
[0116] Specifically, processor 1002 controls itself and memory 1001 to implement the steps in any of the above-described path planning start-point selection method embodiments. Processor 1002 may also be referred to as a Central Processing Unit (CPU). Processor 1002 may be an integrated circuit chip with signal processing capabilities. Processor 1002 may also be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. A general-purpose processor may be a microprocessor or any conventional processor. Furthermore, processor 1002 may be implemented using integrated circuit chips.
[0117] Please see Figure 11 , Figure 11 This is a schematic diagram of a computer-readable storage medium according to an embodiment of the present application. The computer-readable storage medium 1100 stores program instructions 1110 that can be executed by a processor. The program instructions 1110 are used to implement the steps in any of the above-described embodiments of the path planning starting point selection method.
[0118] In some embodiments, the functions or modules of the apparatus provided in this disclosure can be used to perform the methods described in the above method embodiments. The specific implementation can be referred to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0119] The description of the various embodiments above tends to emphasize the differences between the various embodiments. The similarities or similarities between them can be referred to, and for the sake of brevity, they will not be repeated here.
[0120] In the several embodiments provided in this application, it should be understood that the disclosed methods and apparatus can be implemented in other ways. For example, the apparatus implementations described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of devices or units may be electrical, mechanical, or other forms.
[0121] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
Claims
1. A method for selecting the starting point in path planning, characterized in that, The method includes: Obtain the pose parameters and path map of the moving object. The path map contains multiple path segments, which are used to connect two path nodes. Obtain the path nodes contained in the path map, and obtain the target range of the selected point corresponding to the moving object; Select path nodes located within the target selection area to obtain a preliminary set of path nodes; Determine all path segments associated with each path node in the initial screening path node set to obtain a path segment set; Based on the pose parameters of the moving object, calculate the path segment movement cost of the moving object relative to each path segment in the path segment set; Calculate the distance between each path node in the initial screening path node set and the moving object to obtain the node movement cost corresponding to each path node in the initial screening path node set; From the set of path segments, select path segments whose path segment movement cost and node movement cost satisfy preset conditions, and use the path nodes corresponding to the selected path segments as candidate starting points. The candidate starting points are verified through path planning, and the candidate starting points that pass the verification are used as the target starting points.
2. The method according to claim 1, characterized in that, The pose parameters include the position and orientation of the moving object; The step of calculating the path segment movement cost of the moving object relative to each path segment in the path segment set based on the pose parameters of the moving object includes: Calculate the distance between the position of the moving object and the position of the path segment to obtain the distance cost; as well as, Calculate the rotation angle cost of the moving object's pose relative to the path segment; Based on the distance cost and the angle cost, the path segment movement cost corresponding to the path segment is obtained.
3. The method according to claim 2, characterized in that, The calculation of the rotation angle cost of the pose of the moving object relative to the path segment includes: Obtain the path direction of the path segment; Based on the path direction of the path segment and the posture of the moving object, the rotation angle of the moving object relative to the path segment is determined, and the rotation angle cost is obtained.
4. The method according to claim 1, characterized in that, The step of selecting path segments from the set of path segments whose path segment movement costs and node movement costs satisfy preset conditions, and using the path nodes corresponding to the selected path segments as candidate starting points, includes: Path nodes whose node movement costs meet preset conditions are selected from the initial set of path nodes, and path segments associated with the selected path nodes in the set of path segments are selected as candidate path segments. Each candidate path segment is sorted based on the path segment movement cost, and each candidate path segment is selected based on the sorting result; The path nodes corresponding to the selected candidate path segments are used as candidate starting points.
5. The method according to claim 1, characterized in that, The step of selecting the path node corresponding to the chosen path segment as the candidate starting point includes: Obtain the path direction of the selected path segment and obtain each path node corresponding to the selected path segment to obtain the pre-selected starting point; Candidate starting points are selected from each pre-selected starting point based on the distance between the moving object and each pre-selected starting point and the path direction of the selected path segment.
6. The method according to claim 1, characterized in that, The step of verifying the path planning for the candidate starting points and using the verified candidate starting points as the target starting points includes: Obtain the destination location corresponding to the path planning task; Path planning is performed based on the candidate starting point, the destination location, and the path map; If the path planning is successful, it is considered verified and the candidate starting point is taken as the target starting point.
7. A starting point selection device for path planning, characterized in that, include: The acquisition module is used to acquire the pose parameters of the moving object and the path map. The path map contains multiple path segments, which are used to connect two path nodes. The calculation module is used to obtain the path nodes contained in the path map and to obtain the target range of the selected point corresponding to the moving object. Select path nodes located within the target area to obtain a preliminary set of path nodes; determine all path segments associated with each path node in the preliminary set of path nodes to obtain a set of path segments; calculate the path segment movement cost of the moving object relative to each path segment in the set of path segments based on the pose parameters of the moving object. The selection module is used to calculate the distance between each path node in the initial screening path node set and the moving object, and to obtain the node movement cost corresponding to each path node in the initial screening path node set. From the set of path segments, select path segments whose path segment movement cost and node movement cost satisfy preset conditions, and use the path nodes corresponding to the selected path segments as candidate starting points. The verification module is used to verify the path planning of the candidate starting points and to take the candidate starting points that pass the verification as the target starting points.
8. An electronic device, characterized in that, It includes a memory and a processor, the processor being configured to execute program instructions stored in the memory to implement the method of any one of claims 1 to 6.
Citation Information
Patent Citations
Systems and methods for path planning
US20260227796A1
