A robot path generation method, system and storage medium
Patent Information
- Application Number
- CN202211136169.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-19
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2042-09-19
AI Technical Summary
当场景比较复杂时,新规划的局部路径可能会与原来剩下的全局路径出现重叠的情况,一旦形成了重叠的路径,机器人如果按照新的路径跟随,就会出现多走一段,白白多走了重叠的那一段,既浪费了机器人的能源,也会让人感觉机器人很不智能的情况
[0049] The beneficial effects of the present invention are: the robot path generation method, system and storage medium provided by the present invention can re-plan the path by selecting local target points and combining it with the original path, thus avoiding re-planning the path to a certain extent and reducing the calculation time. At the same time, it detects the overlap of paths, which reduces the time of path planning to a certain extent, reduces the resource consumption of path planning, and improves work efficiency.
Smart Images

Figure CN115542896B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of robot path planning, and in particular to a robot path generation method, system and storage medium. Background Art
[0002] As robots are increasingly used, the navigation of mobile robots has gradually become an important issue. In most cases, the navigation framework can be divided into path planning and motion control. Path planning refers to planning a path to avoid obstacles, while motion control refers to moving along a collision-free path. Once the robot encounters an obstacle, the original path may be blocked and it cannot continue to move, so the path needs to be replanned.
[0003] However, when the robot faces large scenes (such as airports, train stations, underground garages, etc.), the robot's computing resources are limited, and modules with high resource consumption such as vision and SLAM make navigation resources extremely scarce. As mentioned above, navigation mainly includes planning and control. Since control must be real-time and fast, it is also difficult to optimize its calculation. The only way is to find a way to optimize path planning. How to quickly re-plan the path becomes the key to successful navigation.
[0004] When the robot replans a path to bypass obstacles, if the target point is far away from the current position of the robot, replanning the path will take a long time and is unnecessary because the robot cannot determine whether there are obstacles on the part of the path that is far away from the robot. If the path is replanned directly, most of the replanned path will overlap with the previous path. Therefore, when replanning the path, generally a point on the path is selected as the local target point; the robot does not need to replan the part of the global path after the local target point and can directly use it as the new path.
[0005] There are also disadvantages to reselecting the target point on the path for planning. When the scene is complex, the newly planned local path may overlap with the original remaining global path. Once an overlapping path is formed, if the robot follows the new path, it will walk an extra section, which is a waste of the robot's energy and makes people feel that the robot is not intelligent. Summary of the invention
[0006] In view of the shortcomings of the prior art, the present invention provides a robot path generation method, system and storage medium. When an obstacle is detected on the path (initial path), the local path is replanned by selecting a local target point on the path, and the local path is spliced with the original path (initial path), and overlap detection is performed. In the path planning of large scenes, the planning time is saved to a certain extent and the resource consumption of planning is reduced.
[0007] In order to achieve the purpose of the present invention, the present invention provides a robot path generation method, comprising the following steps:
[0008] S1: Get the cost map, convert the location point of the initial path into the serial number of the cost map, and determine whether there is an obstacle on the initial path according to the serial number value. If there is, mark the serial number of the obstacle and save it in the obstacle array;
[0009] S2: Select local target points according to the obstacle array and plan local paths according to the local target points;
[0010] S3: Segment the initial path according to the local target points, and concatenate the segmented initial path with the local path to form a global path;
[0011] S4: Overlap detection of global paths;
[0012] S5: performing path smoothing on the global path after overlap detection.
[0013] Preferably, the specific steps of step S3 are:
[0014] The initial path is divided according to the local target point, the path between the local target point and the end point of the initial path is taken as the first path, the path between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path.
[0015] Preferably, the specific steps of step S4 include:
[0016] S41: Perform overlap detection on each position point on the global path;
[0017] S411: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to save the output path results; where int1 is the serial number under the global path, int2 is the serial number in the x direction of the world coordinate system, and int3 is the serial number in the y direction of the world coordinate system.
[0018] S412: Transform each position point on the global path P i =(x i,y i ), and its transformation formula is:
[0019] px i =n*x i
[0020] py i =n*y i
[0021] Where n is the detection resolution, x i For P i x coordinate in the world coordinate system, y i P i The y coordinate in the world coordinate system;
[0022] S413: Create and initialize array P1, traverse the data in array P0, and determine whether there are any data in array P1 that are equal to px at the same time i and py i data, namely P j =(k,x j ,y j ) j Is it equal to Px? i , Px j Is it equal to P yj If it exists, it means that path overlap is detected, and the process goes to step S414; if it does not exist, the data is saved in array P1, and steps S412-S414 are repeated until each position point in P0 is detected.
[0023] S414: If path overlap is detected, P in array P1 is j Delete the data to Pm, where m is the last element of P1, and return to step S412.
[0024] Preferably, the specific steps of step S2 are:
[0025] Obtain the serial number of the obstacle of the second preset value according to the obstacle array, use the serial number of the obstacle of the second preset value as the serial number of the local target point, obtain the coordinates of the local target point in the initial path, and re-plan the local path according to the local target point and the end point of the initial path.
[0026] Preferably, the specific steps of judging whether there is an obstacle on the initial path according to the sequence number value in step S1 are:
[0027] The cost value on the cost map is retrieved by serial number, and the serial number with a cost value greater than the threshold is marked as an obstacle. When the corresponding cost value retrieved by the serial number is greater than the threshold, it is determined that an obstacle exists.
[0028] Preferably, the present invention further provides a robot path generation system, comprising: an acquisition and conversion module: acquiring a cost map and converting the position points of the initial path into sequence numbers of the cost map;
[0029] Obstacle judgment module: judge whether there are obstacles on the initial path according to the sequence number value;
[0030] Obstacle storage module: When the obstacle judgment module determines that there is an obstacle on the initial path, the obstacle number is saved;
[0031] Local path generation module: selects local target points according to the data of the obstacle storage module and generates a local path;
[0032] Global path generation module: segment the initial path according to the local target points, and generate a global path by splicing the segmented initial path with the local path;
[0033] Overlap detection module: performs overlap detection on the generated global paths;
[0034] Path smoothing module: performs path smoothing operations on the global path after overlap detection.
[0035] Preferably, the global path generation module specifically includes:
[0036] The initial path is divided according to the local target point, the path between the local target point and the end point of the initial path is taken as the first path, the path between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path.
[0037] Preferably, the local path generation module specifically includes:
[0038] The serial number of the obstacle with the second preset value is obtained according to the data of the obstacle array, and the serial number of the obstacle with the second preset value is used as the serial number of the local target point, and the coordinates of the local target point in the initial path are obtained, and the local path is replanned according to the local target point and the end point of the initial path.
[0039] Preferably, the overlap detection module specifically includes:
[0040] Overlap detection submodule: performs overlap detection on each position point on the global path generated by the global path generation module;
[0041] First submodule: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to save the output path results; where int1 is the serial number under the global path, int2 is the serial number in the x direction of the world coordinate system, and int3 is the serial number in the y direction of the world coordinate system.
[0042] Second submodule: Transform each position point on the global path P i =(x i ,y i ), and its transformation formula is:
[0043] px i =n*x i
[0044] py i =n*y i
[0045] Where n is the detection resolution, x i For P i x coordinate, y coordinate in the world coordinate system i P i The y coordinate in the world coordinate system;
[0046] The third submodule: create a new array P1 and initialize it, traverse the data in array P0, and determine whether there are any data in array P1 that are equal to px at the same time i and py i data, namely P j =(k,x j ,y j ) j Is it equal to Px? i , Px j Is it equal to P yj If it exists, it means that path overlap is detected, and the fourth submodule is entered; if it does not exist, the data is saved in array P1, and the operations of the second submodule, the third submodule and the fourth submodule are repeatedly executed until each position point in P0 is detected;
[0047] The fourth submodule: If path overlap is detected, P in array P1 is j Delete the data to Pm, where m is the last element of P1, and return the second submodule.
[0048] Preferably, the present invention further provides a computer-readable storage medium, on which at least one computer program is stored, and when the computer program is executed by a processor, the steps of the path generation method in any one of the above embodiments are implemented.
[0049] The beneficial effects of the present invention are as follows: the robot path generation method, system and storage medium provided by the present invention re-plan the path by selecting local target points and combining them with the original path, thereby avoiding re-planning the path to a certain extent, reducing the amount of calculation, and performing overlap detection on the path at the same time, thereby reducing the path planning time to a certain extent, reducing the resource consumption of path planning, and improving work efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] The above and other purposes, features and advantages of the present invention will become more clear by more specific description of the preferred embodiments of the present invention shown in the accompanying drawings. The same reference numerals indicate the same parts in all the accompanying drawings, and the accompanying drawings are not deliberately scaled to the actual size, and the focus is on illustrating the main purpose of the present invention.
[0051] Figure 1 A schematic diagram of a flow chart of a robot path generation method provided by an embodiment of the present invention;
[0052] Figure 2 A schematic diagram of a specific process of a robot path generation method and device provided by an embodiment of the present invention;
[0053] Figure 3 A schematic diagram of a flow chart of determining whether there are obstacles on a path in a robot path generation method provided in an embodiment of the present invention;
[0054] Figure 4 A schematic diagram of a specific process of overlap detection provided by an embodiment of the present invention; DETAILED DESCRIPTION
[0055] The technical solution of the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it, but the embodiments are not intended to limit the present invention.
[0056] Please refer to Figure 1-4 , an embodiment of the present invention provides a robot path generation method, comprising the following steps:
[0057] S1: Get the cost map, convert the location point of the initial path into the serial number of the cost map, and determine whether there is an obstacle on the initial path according to the serial number value. If there is, mark the serial number of the obstacle and save it in the obstacle array;
[0058] S2: Select local target points according to the obstacle array, and plan local paths according to the local target points (the local path here is to use the planning algorithm to re-plan a local path starting from the current position of the robot (local target point). The newly planned local path will bypass the currently detected obstacles to avoid the path being interrupted by obstacles).
[0059] S3: Segment the initial path according to the local target points, and concatenate the segmented initial path with the local path to form a global path;
[0060] S4: Overlap detection of global paths;
[0061] S5: performing path smoothing on the global path after overlap detection.
[0062] After the overlap detection, there will be a large change in curvature, so the path needs to be smoothed before outputting to the controller. Commonly used path smoothing methods can be applied here, such as Bezier curve smoothing, cubic spline smoothing, Floyd smoothing, etc.
[0063] Please refer to Figure 1-4 The robot path generation method, system and storage medium provided by the present invention, when the robot encounters an obstacle, first searches for a feasible local target point on the initial path, replans the local path with the selected point as the target point, and then splices the local path to the original initial path to form a global path. After splicing, it automatically detects whether the path overlaps. Once overlap occurs, the overlapping part is deleted. After deletion, the path is smoothed to form a path without obstacles.
[0064] The beneficial effects of the present invention are as follows: the robot path generation method, system and storage medium provided by the present invention, when an obstacle is detected on the path (initial path), re-plan the local path by selecting a local target point on the path, and splicing the local path with the original path (initial path), and performing overlap detection, in the path planning of large scenes, saves planning time to a certain extent and reduces planning resource consumption.
[0065] Please refer to Figure 1-4 In a preferred embodiment, the specific steps of step S3 are:
[0066] The initial path is segmented according to the local target point, and the path between the local target point and the end point of the initial path is taken as the first path (since the local target point is selected according to the obstacle array, when the path is segmented, there are basically no obstacles on the first path, while there are still obstacles on the second path, so the second path needs to be deleted. When the global path is superimposed, since the existence of the first path is not considered during the local path planning, overlap detection is required when the first path and the local path are spliced), the distance between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path;
[0067] For example: Let the initial path be P global, first pass the local target point to the initial path P global Divide into two halves, and record the path from the local target point to the end point of the initial path as the first half of the path (the first path), that is, P front =[P igoal+1 , P igoal+2 ..., P n ]The path from the initial path starting point to the local target point is the second half of the path (the second path), P back =[P0,P i ...P igoal ], and then the second half of the path P back Delete the local path and the first half of the path P front The global path P can be obtained by splicing new .
[0068] Please refer to Figure 1 and 3 In a preferred embodiment, the specific steps of step S4 include:
[0069] S41: Perform overlap detection on each position point on the global path (the purpose of overlapping detection is to prevent the robot from taking repeated paths, thereby wasting a certain amount of time. When overlapping paths are detected, the path can be cut. Assuming that section A and section B on the global path overlap, section A or section B can be deleted.
[0070] S411: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to save the output path results; where int1 is the serial number under the global path, int2 is the serial number in the x direction of the world coordinate system, and int3 is the serial number in the y direction of the world coordinate system.
[0071] S412: Transform each position point on the global path P i =(x i ,y i ), and its transformation formula is:
[0072] px i =n*x i
[0073] py i =n*y i
[0074] Where n is the detection resolution (the resolution can be adjusted according to different scenarios to achieve the purpose of accuracy), x i For P i x coordinate in the world coordinate system, y i P i The y coordinate in the world coordinate system;
[0075] S413: Create and initialize array P1, and traverse the data in array P0 (the iteration point is represented by P i ), determine whether there are two values in array P1 that are equal to px at the same time i and py i data, namely P j =(k,x j ,y j ) j Is it equal to Px? i , Px j Is it equal to P yj If it exists, it means that the path overlap is detected, and the process goes to step S414; if it does not exist, the data is saved in array P1, and steps S412-S414 are repeated until each position point on the global path is detected;
[0076] The so-called same data refers to a position point in array P0 pi =(i, px i ,py i ) and a point p in P1 j =(k, px j ,py j ) j Is it equal to px? i ,py j Is it equal to py i ;
[0077] S414: If path overlap is detected (if there is the same data (px i =px j And py i =py j and ik>m), it means that path overlap is detected), then the position points after j in array P1 (which can also be freely set as needed) are deleted, that is, P1=[P j ,……P end ] to delete and return to step S412.
[0078] Please refer to Figure 1-3 In a further preferred embodiment, the specific steps of step S2 are:
[0079] The sequence number of the obstacle of the second preset value is obtained according to the obstacle array (in the selection of the local target point, generally speaking, the larger the sequence number, the closer it is to the obstacle, so it is necessary to select the largest sequence number in the obstacle array, which represents the obstacle closest to the target point (the end point of the initial path). The second preset value described here is the sequence value of the obstacle closest to the end point of the initial path + 40 as the sequence number of the local target point. Only one embodiment is described in this application. The selection criteria of the local target point can be freely set by the user, and the selected local target point is not unique), and the sequence number of the obstacle of the second preset value is used as the sequence number of the local target point, and the coordinates of the local target point in the initial path are obtained, and the local path is replanned according to the local target point and the end point of the initial path.
[0080] Please refer to Figure 1-3 In a further preferred embodiment, the specific steps of judging whether there is an obstacle on the initial path according to the sequence number value in step S1 are:
[0081] The cost value on the cost map is retrieved by serial number (the cost map is implemented in the form of a two-dimensional array, and the cost value of the corresponding coordinates of the point can be queried by serial number), and the serial number with a cost value greater than the threshold is marked as an obstacle (the threshold here can be set freely. Assuming that the cost value of the location point under normal circumstances is 0 to 255, the cost value of the obstacle can be set to 100-255, that is, the threshold is set to 100, which can be freely defined). When the corresponding cost value retrieved by the serial number is greater than the threshold, it is determined that there is an obstacle.
[0082] The cost map in this application is a grid map. The information from the sensor will mark the obstacles on the cost map through transformation. The value of each grid represents the distance from the obstacle. Generally, the closer the distance to the obstacle, the greater the cost value. Using the open source move_base navigation framework, the cost map can be easily obtained.
[0083] Each costmap has origin information and resolution information. Each coordinate in the world coordinate system can obtain its corresponding serial number value on the costmap through the mapping relationship. If the serial number value exceeds the size of the costmap, it can be considered as idle or obstacle, which can be customized according to the needs of the user.
[0084] In actual operation, it is not necessary to convert the entire path. In order to speed up the judgment, the path that exceeds a certain length may be considered idle, because the remote path has little effect on the current state of the robot.
[0085] Please refer to Figure 1-4,In a preferred embodiment, the present invention also provides a robot path generation system, including: an acquisition and conversion module: for acquiring a cost map, and converting the position points of the initial path into the serial numbers of the cost map;
[0086] Obstacle judgment module: judge whether there are obstacles on the initial path according to the sequence number value;
[0087] Obstacle storage module: When the obstacle judgment module determines that there is an obstacle on the initial path, the obstacle number is saved;
[0088] Local path generation module: selects local target points according to the data of the obstacle storage module and generates a local path;
[0089] Global path generation module: segment the initial path according to the local target points, and generate a global path by splicing the segmented initial path with the local path;
[0090] Overlap detection module: performs overlap detection on the generated global paths;
[0091] Path smoothing module: performs path smoothing operations on the global path after overlap detection.
[0092] Please refer to Figure 1-4 In a further preferred embodiment, the global path generation module specifically includes:
[0093] The initial path is divided according to the local target point, the path between the local target point and the end point of the initial path is taken as the first path, the path between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path.
[0094] Please refer to Figure 1-2 In a preferred embodiment, the local path generation module specifically includes:
[0095] The serial number of the obstacle with the second preset value is obtained according to the data of the obstacle array, and the serial number of the obstacle with the second preset value is used as the serial number of the local target point, and the coordinates of the local target point in the initial path are obtained, and the local path is replanned according to the local target point and the end point of the initial path.
[0096] Please refer to Figure 1-3 In a preferred embodiment, the overlap detection module specifically includes:
[0097] Overlap detection submodule: performs overlap detection on each position point on the global path generated by the global path generation module;
[0098] First submodule: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to save the output path results; where int1 is the serial number under the global path, int2 is the serial number in the x direction of the world coordinate system, and int3 is the serial number in the y direction of the world coordinate system.
[0099] Second submodule: Transform each position point on the global path P i =(xi, yi), the transformation formula is:
[0100] px i =n*x i
[0101] py i =n*y i
[0102] Where n is the detection resolution, x i For P i x coordinate in the world coordinate system, y i P i The y coordinate in the world coordinate system;
[0103] The third submodule: create and initialize array P1, and traverse the data in array P0 (the iteration point is represented by P i ), determine whether there are two values in array P1 that are equal to px at the same time i and py i data, namely P j =(k,x j ,y j ) j Is it equal to Px? i , Px j Is it equal to P yj If it exists, it means that the path overlap is detected, and the fourth submodule is entered; if it does not exist, the data is saved in the array P1, and the operations of the second submodule, the third submodule and the fourth submodule are repeatedly executed until each position point in P0 is detected, and finally P1 contains the new path;
[0104] The fourth submodule: If path overlap is detected, P in array P1 is j Delete the data to Pm, where m is the last element of P1, and return the second submodule.
[0105] Please refer to Figure 1-4 In a preferred embodiment, the present invention further provides a computer-readable storage medium, on which is stored at least one computer program, which, when executed by a processor, implements the steps of the path generation method of any one of the above embodiments.
[0106] The storage medium may include: Read Only Memory (ROM), Random Access Memory (RAM), a magnetic disk or an optical disk, etc.
[0107] The beneficial effects of the present invention are as follows: the present invention provides a robot path generation method, system and storage medium. When an obstacle is detected on a path (initial path), the local path is replanned by selecting a local target point on the path, and the local path is spliced with the original path (initial path), and overlap detection is performed. In the path planning of a large scene, the planning time is saved to a certain extent, and the resource consumption of the planning is reduced.
[0108] Compared with the prior art, the robot path generation method, system and storage medium provided by the present application also have the following significant features:
[0109] 1. For scenes where the target point is far away, making full use of the previously planned path can avoid replanning the entire path and greatly reduce the amount of calculation;
[0110] 2. The proposed path overlap detection method can modify the resolution according to different scenarios, thereby achieving the goal of balancing accuracy and computational complexity;
[0111] 3. The path smoothing method is not limited. Different path smoothing methods can be used to achieve different effects, and the algorithm can be easily replaced within the framework.
[0112] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A robot path generation method, characterized in that: The steps include: S1: Get the cost map, convert the location point of the initial path into the serial number of the cost map, and determine whether there is an obstacle on the initial path according to the serial number value. If there is, mark the serial number of the obstacle and save it in the obstacle array; S2: Select local target points according to the obstacle array and plan local paths according to the local target points; The specific steps of step S2 are: Obtain the sequence number of the obstacle of the second preset value according to the obstacle array, use the sequence number of the obstacle of the second preset value as the sequence number of the local target point, obtain the coordinates of the local target point in the initial path, and re-plan the local path according to the local target point and the current position of the robot; S3: Segment the initial path according to the local target points, and concatenate the segmented initial path with the local path to form a global path; S4: Overlap detection of global paths; The specific steps of step S4 include: S41: Perform overlap detection on each position point on the global path; S411: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to store the output path results; wherein int1 is the serial number under the global path, int2 is the serial number in the x direction under the world coordinate system, and int3 is the serial number in the y direction under the world coordinate system; S412: Transform each position point on the global path P i =(x i ,y i ), the transformation formula is: , where n is the detection resolution, x i For P i x coordinate in the world coordinate system, y i P i The y coordinate in the world coordinate system; S413: Create a new array P1 and initialize it, traverse the data in array P0, and determine whether there are any data in array P1 that are equal to px at the same time. i and py i data, namely P j =(k,x j ,y j ) in Px j Is it equal to Px? i , Px j Is it equal to Py j If it exists, it means that the path overlap is detected, and the process goes to step S414; if it does not exist, the data is saved in array P1, and steps S412-S414 are repeated until each position point in P0 is detected; S414: If path overlap is detected, P in array P1 is j Delete the data from Pm to Pm, where m is the last element of P1, and return to step S412; S5: performing path smoothing on the global path after overlap detection.
2. The path generation method according to claim 1, characterized in that: The specific steps of step S3 are: The initial path is divided according to the local target point, the path between the local target point and the end point of the initial path is taken as the first path, the path between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path.
3. The path generation method according to claim 1, characterized in that: The specific steps of judging whether there is an obstacle on the initial path according to the sequence number value in step S1 are: The cost value on the cost map is retrieved by serial number, and the serial number with a cost value greater than the threshold is marked as an obstacle. When the corresponding cost value retrieved by the serial number is greater than the threshold, it is determined that an obstacle exists.
4. A robot path generation system, characterized in that: include: Acquisition and conversion module: acquires the cost map and converts the location points of the initial path into the serial number of the cost map; Obstacle judgment module: judge whether there are obstacles on the initial path according to the sequence number value; Obstacle storage module: When the obstacle judgment module determines that there is an obstacle on the initial path, the obstacle number is saved; Local path generation module: selects local target points according to the data of the obstacle storage module and generates a local path; The local path generation module specifically includes: Obtain the sequence number of the obstacle of the second preset value according to the data of the obstacle array, use the sequence number of the obstacle of the second preset value as the sequence number of the local target point, obtain the coordinates of the local target point in the initial path, and re-plan the local path according to the local target point and the end point of the initial path; Global path generation module: segment the initial path according to the local target points, and generate a global path by splicing the segmented initial path with the local path; Overlap detection module: performs overlap detection on the generated global paths; The overlap detection module specifically includes: Overlap detection submodule: performs overlap detection on each position point on the global path generated by the global path generation module; First submodule: Create a new array P0<int1,int2,int3> , and initialize array P0, the array P0 is used to store the output path results; wherein int1 is the serial number under the global path, int2 is the serial number in the x direction under the world coordinate system, and int3 is the serial number in the y direction under the world coordinate system; Second submodule: Transform each position point on the global path P i =(x i ,y i ), the transformation formula is: , where n is the detection resolution, x i For P i x coordinate in the world coordinate system, y i P i The y coordinate in the world coordinate system; The third submodule: create a new array P1 and initialize it, traverse the data in array P0, and determine whether there are any data in array P1 that are equal to px at the same time i and py i data, namely P j =(k,x j ,y j ) in Px j Is it equal to Px? i , Px j Is it equal to Py j If it exists, it means that path overlap is detected, and the fourth submodule is entered; if it does not exist, the data is saved in array P1, and the operations of the second submodule, the third submodule and the fourth submodule are repeatedly executed until each position point in P0 is detected; The fourth submodule: If path overlap is detected, P in array P1 is j Delete the data to Pm, where m is the last element of P1, and return to the second submodule; Path smoothing module: performs path smoothing operations on the global path after overlap detection.
5. The path generation system according to claim 4, characterized in that: The global path generation module specifically includes: The initial path is divided according to the local target point, the path between the local target point and the end point of the initial path is taken as the first path, the path between the starting point of the initial path and the local target point is taken as the second path, and the first path and the local path are spliced to form a global path.
6. A computer-readable storage medium, characterized in that: At least one computer program is stored on the computer medium, and when the computer program is executed by the processor, the steps of the path generation method according to any one of claims 1 to 3 are implemented.