WO2021042519A1 - Assembly path planning method and related device - Google Patents

Assembly path planning method and related device Download PDF

Info

Publication number
WO2021042519A1
WO2021042519A1 PCT/CN2019/117030 CN2019117030W WO2021042519A1 WO 2021042519 A1 WO2021042519 A1 WO 2021042519A1 CN 2019117030 W CN2019117030 W CN 2019117030W WO 2021042519 A1 WO2021042519 A1 WO 2021042519A1
Authority
WO
WIPO (PCT)
Prior art keywords
sampling
path
target
center
new
Prior art date
Application number
PCT/CN2019/117030
Other languages
French (fr)
Chinese (zh)
Inventor
王义文
王健宗
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2021042519A1 publication Critical patent/WO2021042519A1/en

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/26Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network
    • G01C21/34Route searching; Route guidance
    • G01C21/3407Route searching; Route guidance specially adapted for specific applications
    • G01C21/343Calculating itineraries, i.e. routes leading from a starting point to a series of categorical destinations using a global route restraint, round trips, touristic trips

Definitions

  • This application relates to the field of path planning, and specifically relates to an assembly path planning method and related devices.
  • RRT algorithm is a fast random path planning method. Because it uses random sampling planning method, it does not need scene preprocessing, so it can solve the problem of multi-dimensional non-convex space. The path planning problem is widely used to solve the optimal path in the static road network problem.
  • the traditional RRT algorithm adopts a global uniform random sampling strategy, the calculation amount of the algorithm will increase sharply and the efficiency of the algorithm will be reduced; and it cannot get rid of the trouble of local optimal solution, so that the RRT algorithm only has a probability optimal solution.
  • the embodiments of the present application provide an assembly path planning method and related devices, which can accelerate the sampling convergence speed and solve the problem of being easily trapped in a local optimum during the path planning process.
  • the first aspect of the embodiments of the present application discloses an assembly path planning method, the method includes:
  • a second aspect of the present application discloses an assembly path planning device, the assembly path planning device includes:
  • the sampling unit is used to select a sampling area that includes the starting node, and generate T new pose nodes by random numbers in the sampling area, where T is a positive integer, and select the first from the T new pose nodes
  • a sampling center selecting a new sampling area that includes the first sampling center, and repeating the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes
  • the path obtaining unit is configured to connect the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
  • the third aspect of the present application discloses an electronic device, including a processor, a memory, a communication interface, and one or more programs.
  • the one or more programs are stored in the memory and configured to be processed by the processor.
  • the program is executed by a device, and the program includes a method for executing any one of the first aspect.
  • the fourth aspect of the present application discloses a computer non-volatile readable storage medium, the computer storage medium stores a computer program, and the computer program is executed by a processor to implement any one of the first aspect method.
  • the sampling area including the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first sampling center is selected from the T new pose nodes, Select a new sampling area that includes the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the first sampling center The sampling center and the n second sampling centers obtain the first path, and the target path is obtained according to the first path; this assembly path planning method can greatly accelerate the sampling convergence speed and solve the problem that the path planning of the traditional RRT algorithm tends to be trapped locally Optimal problem.
  • FIG. 1 is a schematic flowchart of an assembly path planning method provided by an embodiment of the application
  • Figure 2 is a schematic diagram of partial sampling provided by an embodiment of the application.
  • FIG. 3 is a schematic diagram of an expansion strategy based on accurate collision calculation provided by an embodiment of the application
  • FIG. 4 is a schematic structural diagram of an electronic device provided by an embodiment of this application.
  • Fig. 5 is a schematic structural diagram of an assembly path planning device provided by an embodiment of the application.
  • the electronic devices involved in the embodiments of the present application may include various handheld devices with wireless communication functions, in-vehicle devices, wireless headsets, computing devices or other processing devices connected to wireless modems, as well as various forms of user equipment (user equipment). , UE), mobile station (mobile station, MS), terminal device (terminal device), etc.
  • the electronic device may be, for example, a smart phone, a tablet computer, a headset box, and so on.
  • the devices mentioned above are collectively referred to as electronic devices.
  • FIG. 1 is a schematic flowchart of an assembly path planning method provided by an embodiment of the application, including:
  • S101 Select a sampling area that includes a starting node.
  • this application improves the RRT algorithm and proposes an assembly path planning method based on the improved RRT algorithm, which can solve the problem of traditional RRT Algorithm problem.
  • Knowing a feasible solution space containing the starting node q s and the target node q e (that is, the pre-selected end point), it is necessary to find the closest feasible path from the starting node to the target node in the feasible solution space to
  • the starting node is the sampling center, and an area containing the starting node is selected as the sampling area in the feasible solution space for local sampling, so that a significant local sampling effect can be achieved without falling into the local optimal solution.
  • S102 Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer.
  • T different new pose nodes can be obtained to form an extended random tree, and T can be predetermined Set, for example, 5, 10, 15, 20 and so on.
  • S103 Select a first sampling center from the T new pose nodes, and select a new sampling area that includes the first sampling center.
  • Figure 2 is a schematic diagram of local sampling.
  • the local sampling strategy is adopted to determine the next sampling area through the current sampling center.
  • the current sampling center and the next The distance between the sampling centers therefore, the node q near that is closest to the current sampling center is selected from the T new pose nodes as the first sampling center, and the first sampling center is selected according to the method described in S101 Of the new sampling area.
  • the method of acquiring the sampling center and the sampling area is the same each time.
  • the sampling area is determined according to the current sampling center, the next sampling center is determined in the sampling area, and the method of obtaining the first sampling center is repeated, until Reach the preset maximum sampling times or reach the target node.
  • the first path is obtained by connecting all sampling centers including the start node and the target node.
  • the traditional RRT algorithm uses a global uniform random sampling strategy, the algorithm calculation is huge, the algorithm efficiency is low, and it cannot get rid of the local maximum.
  • the problem of the optimal solution is that only the optimal solution can be obtained.
  • by combining random sampling, partial sampling and end-point sampling the success rate of sampling center expansion of the expanded random tree during iterative sampling is improved, and the success rate of sampling center expansion is improved.
  • the convergence speed of the traditional RRT algorithm is solved, and the problem of local optimal solution is solved.
  • the possible paths are obtained through random sampling, local sampling and end-point sampling at the same time, and the first path, the second path and the third path are obtained. The above three paths are fused to obtain the final target path.
  • the assembly path planning method is applied to a six-degree-of-freedom intelligent robot.
  • the six-degree-of-freedom intelligent robot is a core component that relieves industrial production pressure and improves industrial production efficiency. , Forearm, wrist arm and terminal controller, with compact structure, complex parts and other related characteristics.
  • the embodiment of this application uses a six-degree-of-freedom robot as a carrier to verify whether the improved RRT algorithm can successfully complete the path planning task in a virtual environment through simulation.
  • the simulation result shows that the improved RRT algorithm can be successfully used for complex assemblies (six-degrees of freedom robot).
  • the optimal assembly path of the assembly is obtained.
  • the successful completion of the six-degree-of-freedom robot assembly path planning proves that the improved RRT algorithm is scientific and effective.
  • the sampling area containing the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first one is selected from the T new pose nodes.
  • Sampling center select a new sampling area that includes the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the The first sampling center and the n second sampling centers obtain the first path, and obtain the target path according to the first path; this assembly path planning method can greatly accelerate the sampling convergence speed and solve the traditional RRT algorithm path planning It is easy to fall into the problem of local optimum.
  • the generating T new pose nodes by random numbers in the sampling area is obtained by the following formula:
  • T new pose nodes Repeat the formula T times to obtain T new pose nodes, and record T new pose nodes in the form of a list, where f z is a random number, f z ⁇ (-1, 0) ⁇ (0, 1), f y is the range factor, f y ⁇ (0, 1), q s is the starting node, q e is the target node, q d is the current sampling center, and q rand is the new pose node.
  • Each node parameter in the above formula is a six-dimensional variable, and the six-dimensional includes the X, Y, Z three-dimensional and posture angle coordinate systems in the rectangular space coordinate system
  • Yaw is the yaw angle, which rotates around the Z axis
  • Pitch is the pitch angle
  • Y axis the roll angle
  • the new pose node q rand is at The possible positions in the spatial rectangular coordinate system consist of the point O1 (x1-0.4x2, y1-0.4y2, z1-0.4z2) and the point O2 (x1+0.4x2, y1+0.4y2, z1+0.4z2) as the body pair Inside the rectangular parallelepiped formed by the corners, the rectangular parallelepiped is the sampling area. Obviously, q d is at the center of the rectangular parallelepiped.
  • the posture information (orientation) of the T new posture nodes in the cuboid can be determined according to the coordinates of q d and q s -q e in the posture angle coordinate system.
  • the method further includes:
  • the next sampling center is determined according to the sampling direction and the sampling step length.
  • the obtaining a new sampling direction according to the target node, the first sampling center and the collision point includes:
  • Figure 3 is a schematic diagram of the expansion strategy based on accurate collision calculation, where q s is the starting node and q e is the target node.
  • q rand is the current sampling point
  • q is obtained by calculation.
  • Near is the point closest to q rand in the expansion tree, which is used as the point to be expanded in the next step.
  • the method further includes:
  • the third path is obtained by sampling at the end point.
  • random sampling is to randomly select sampling points in the feasible solution space, which is the basic sampling strategy of the traditional RRT algorithm.
  • End-point sampling is to sample the target node as the sampling point in the feasible solution space.
  • the end-point sampling strategy can expand the random tree Converge quickly to the target node.
  • the obtaining the target path according to the first path includes:
  • performing mathematical processing on the first path, the second path, and the third path to obtain the target path includes: selecting k equidistant abscissas on the abscissa of the planar rectangular coordinate system;
  • k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates
  • the coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  • the final target path can be obtained by averaging the weighting of the first path, the second path, and the third path.
  • k equidistant abscissas ( k1, k2,,, kn)
  • the target path can also be obtained by processing the above three paths in other ways, which is not limited in this application.
  • FIG. 4 is a schematic structural diagram of an electronic device provided by an embodiment of the application. As shown in the figure, it includes a processor, a memory, a communication interface, and one or more programs. In the memory, and configured to be executed by the processor.
  • the program includes instructions for executing the following steps:
  • the program includes instructions for executing the following steps:
  • the next sampling center is determined according to the sampling direction and the sampling step length.
  • the program includes instructions for executing the following steps:
  • the program includes instructions for executing the following steps:
  • the third path is obtained by sampling at the end point.
  • the program includes instructions for executing the following steps:
  • the program includes instructions for executing the following steps:
  • k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates
  • the coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  • the terminal includes hardware structures and/or software modules corresponding to each function.
  • the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software-driven hardware depends on the specific application and design constraint conditions of the technical solution. Professionals and technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered beyond the scope of this application.
  • the embodiments of the present application may divide the terminal into functional units according to the foregoing method examples.
  • each functional unit may be divided corresponding to each function, or two or more functions may be integrated into one processing unit.
  • the above-mentioned integrated unit can be implemented in the form of hardware or software functional unit. It should be noted that the division of units in the embodiments of the present application is illustrative, and is only a logical function division, and there may be other division methods in actual implementation.
  • Fig. 5 is a schematic structural diagram of an assembly path planning device 500 provided by an embodiment of the application.
  • the assembly route planning device 500 includes a sampling unit 501 and a route acquisition unit 502, wherein:
  • the path obtaining unit 502 is configured to connect the start node, the first sampling center, and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
  • the sampling unit 501 generates T new pose nodes in the sampling area through the following formula:
  • T new pose nodes where f z is a random number, f z ⁇ (-1,0) ⁇ (0,1), f y is a range factor, and f y ⁇ ( 0, 1), q s is the starting node, q e is the target node, q d is the current sampling center, and q rand is the new pose node.
  • the assembly path planning device further includes an obstacle avoidance unit 503 for confirming whether there is a collision point on the line between the starting node and the first sampling center, and if the collision point exists, according to The target node, the first sampling center, and the collision point obtain a new sampling direction, determine a sampling step, and determine the next sampling center according to the sampling direction and the sampling step.
  • an obstacle avoidance unit 503 for confirming whether there is a collision point on the line between the starting node and the first sampling center, and if the collision point exists, according to The target node, the first sampling center, and the collision point obtain a new sampling direction, determine a sampling step, and determine the next sampling center according to the sampling direction and the sampling step.
  • the obstacle avoidance unit 503 is specifically configured to:
  • the path obtaining unit 502 is specifically configured to:
  • the third path is obtained by sampling at the end point.
  • the path obtaining unit 502 is specifically configured to:
  • the path obtaining unit 502 is specifically configured to:
  • k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates
  • the coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  • the above-mentioned unit may be used to execute the method described in the above-mentioned embodiment.
  • a sampling area containing the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first sampling center is selected from the T new pose nodes, and A new sampling area including the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the first sampling The center and the n second sampling centers obtain the first path, and the target path is obtained according to the first path; through this assembly path planning method, the sampling convergence speed can be greatly accelerated, and the path planning of the traditional RRT algorithm is easily trapped in the local maximum. Excellent question.
  • the embodiment of the present application also provides a computer non-volatile readable storage medium that stores a computer program for electronic data exchange.
  • the computer program enables the computer to execute any of the assembly path planning methods described in the above method embodiments. Part or all of the steps.
  • the embodiments of the present application also provide a computer program product.
  • the computer program product includes a non-transitory computer non-volatile readable storage medium storing a computer program.
  • the computer program causes a computer to execute the method described in the foregoing method embodiment. Part or all of the steps of any assembly path planning method.

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Automation & Control Theory (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Complex Calculations (AREA)

Abstract

An assembly path planning method and a related device, the method comprising: selecting a sampling region including a start node (101); generating T new pose nodes in the sampling region by means of random numbers (102); selecting a first sampling center from the T new pose nodes, and selecting a new sampling region including the first sampling center (103); repeating the step of acquiring the first sampling center until a preset condition is met, so as to obtain n second sampling centers (104); and connecting the start node, the first sampling center, and the n second sampling centers so as to obtain a first path, and obtaining a target path according to the first path (105). The assembly path planning method greatly accelerates the sampling convergence rate, and solves the problem in which conventional path planning using an RRT (rapidly-exploring random tree) algorithm can easily fall into the trap of locally optimal solutions.

Description

装配路径规划方法及相关装置Assembly path planning method and related device
本申请要求于2019年09月2日提交中国专利局、申请号为2019108245692、申请名称为“装配路径规划方法及相关装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office, the application number is 2019108245692, and the application name is "Assembly Route Planning Method and Related Devices" on September 2, 2019. The entire content of this application is incorporated into this application by reference. .
技术领域Technical field
本申请涉及路径规划领域,具体涉及了一种装配路径规划方法及相关装置。This application relates to the field of path planning, and specifically relates to an assembly path planning method and related devices.
背景技术Background technique
随着大规模工业化生产的兴起,数字化装配技术即虚拟装配技术越来越多的应用于实际工业生产。路径规划是虚拟装配技术的核心,其中,RRT算法作为一种快速随机路径规划方法,因为其采用随机采样的规划方法,所以不需要进行场景预处理,因此可以很好地解决多维非凸空间的路径规划问题,被广泛地应用于静态路网问题中求解最优路径。但是,由于传统RRT算法采用全局均匀随机采样策略,会使得算法计算量急剧增大,降低算法效率;且无法摆脱局部最优解的困扰,使得RRT算法仅存在概率最优解。With the rise of large-scale industrial production, digital assembly technology, that is, virtual assembly technology, is increasingly used in actual industrial production. Path planning is the core of virtual assembly technology. Among them, RRT algorithm is a fast random path planning method. Because it uses random sampling planning method, it does not need scene preprocessing, so it can solve the problem of multi-dimensional non-convex space. The path planning problem is widely used to solve the optimal path in the static road network problem. However, because the traditional RRT algorithm adopts a global uniform random sampling strategy, the calculation amount of the algorithm will increase sharply and the efficiency of the algorithm will be reduced; and it cannot get rid of the trouble of local optimal solution, so that the RRT algorithm only has a probability optimal solution.
发明内容Summary of the invention
本申请实施例提供了一种装配路径规划方法及相关装置,能够加快采样收敛速度,并解决了路径规划过程中易陷于局部最优的问题。The embodiments of the present application provide an assembly path planning method and related devices, which can accelerate the sampling convergence speed and solve the problem of being easily trapped in a local optimum during the path planning process.
本申请实施例第一方面公开了一种装配路径规划方法,所述方法包括:The first aspect of the embodiments of the present application discloses an assembly path planning method, the method includes:
选取包含起始节点的采样区域;Select the sampling area that contains the starting node;
在所述采样区域内通过随机数产生T个新位姿节点,T为正整数;Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer;
从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;Selecting a first sampling center from the T new pose nodes, and selecting a new sampling area that includes the first sampling center;
重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中 心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;Repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes that the last second sampling center among the n second sampling centers is the target node , Or, n=c-1, c is the preset maximum sampling times, n and c are both positive integers;
连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。Connecting the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtaining a target path according to the first path.
本申请第二方面公开了一种装配路径规划装置,所述装配路径规划装置包括:A second aspect of the present application discloses an assembly path planning device, the assembly path planning device includes:
采样单元,用于选取包含起始节点的采样区域,以及在所述采样区域内通过随机数产生T个新位姿节点,T为正整数,以及从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域,以及重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;The sampling unit is used to select a sampling area that includes the starting node, and generate T new pose nodes by random numbers in the sampling area, where T is a positive integer, and select the first from the T new pose nodes A sampling center, selecting a new sampling area that includes the first sampling center, and repeating the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes The last second sampling center among the n second sampling centers is the target node, or n=c-1, c is the preset maximum number of sampling times, and both n and c are positive integers;
路径获取单元,用于连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。The path obtaining unit is configured to connect the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
本申请第三方面公开了一种电子设备,包括处理器、存储器、通信接口,以及一个或多个程序,所述一个或多个程序被存储在所述存储器中,并且被配置由所述处理器执行,所述程序包括用于执行第一方面任一项所述的方法。The third aspect of the present application discloses an electronic device, including a processor, a memory, a communication interface, and one or more programs. The one or more programs are stored in the memory and configured to be processed by the processor. The program is executed by a device, and the program includes a method for executing any one of the first aspect.
本申请第四方面公开了一种计算机非易失性可读存储介质,所述计算机存储介质存储有计算机程序,所述计算机程序被处理器执行,以实现如第一方面任一项所述的方法。The fourth aspect of the present application discloses a computer non-volatile readable storage medium, the computer storage medium stores a computer program, and the computer program is executed by a processor to implement any one of the first aspect method.
本申请实施例的方案中,选取包含起始节点的采样区域;在所述采样区域内通过随机数产生T个新位姿节点;从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心;连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径;通过该装配路径规划方法,能够大大加快采样收敛速度,并解决传统RRT算法路径规划易陷于局部最优的问题。In the solution of the embodiment of the present application, the sampling area including the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first sampling center is selected from the T new pose nodes, Select a new sampling area that includes the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the first sampling center The sampling center and the n second sampling centers obtain the first path, and the target path is obtained according to the first path; this assembly path planning method can greatly accelerate the sampling convergence speed and solve the problem that the path planning of the traditional RRT algorithm tends to be trapped locally Optimal problem.
附图说明Description of the drawings
为了更清楚地说明本申请实施例或背景技术中的技术方案,下面将对本申请实施例或背景技术中所涉及到的附图作简单地介绍。In order to more clearly illustrate the technical solutions in the embodiments of the application or the background art, the following will briefly introduce the drawings involved in the embodiments of the application or the background art.
图1为本申请实施例提供的一种装配路径规划方法的流程示意图;FIG. 1 is a schematic flowchart of an assembly path planning method provided by an embodiment of the application;
图2为本申请实施例提供的局部采样示意图;Figure 2 is a schematic diagram of partial sampling provided by an embodiment of the application;
图3为本申请实施例提供的基于精确碰撞计算的扩展策略示意图;FIG. 3 is a schematic diagram of an expansion strategy based on accurate collision calculation provided by an embodiment of the application;
图4为本申请实施例提供的一种电子设备的结构示意图;4 is a schematic structural diagram of an electronic device provided by an embodiment of this application;
图5为本申请实施例提供的一种装配路径规划装置的结构示意图。Fig. 5 is a schematic structural diagram of an assembly path planning device provided by an embodiment of the application.
具体实施方式detailed description
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚地描述,显然,所描述的实施例是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。In order to enable those skilled in the art to better understand the solutions of the application, the technical solutions in the embodiments of the application will be clearly described below in conjunction with the drawings in the embodiments of the application. Obviously, the described embodiments are of the application. Part of the embodiment, but not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative work should fall within the protection scope of this application.
本申请说明书、权利要求书和附图中出现的术语“第一”、“第二”和“第三”等是用于区别不同的对象,而并非用于描述特定的顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其它步骤或单元。The terms "first", "second", and "third" appearing in the specification, claims, and drawings of this application are used to distinguish different objects, rather than describing a specific sequence. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes unlisted steps or units, or optionally also includes Other steps or units inherent in these processes, methods, products or equipment.
在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。Reference to "embodiments" herein means that a specific feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art clearly and implicitly understand that the embodiments described herein can be combined with other embodiments.
本申请实施例所涉及到的电子设备可以包括各种具有无线通信功能的手 持设备、车载设备、无线耳机、计算设备或连接到无线调制解调器的其他处理设备,以及各种形式的用户设备(user equipment,UE),移动台(mobile station,MS),终端设备(terminal device)等等,电子设备例如可以为智能手机、平板电脑、耳机盒等等。为方便描述,上面提到的设备统称为电子设备。The electronic devices involved in the embodiments of the present application may include various handheld devices with wireless communication functions, in-vehicle devices, wireless headsets, computing devices or other processing devices connected to wireless modems, as well as various forms of user equipment (user equipment). , UE), mobile station (mobile station, MS), terminal device (terminal device), etc. The electronic device may be, for example, a smart phone, a tablet computer, a headset box, and so on. For ease of description, the devices mentioned above are collectively referred to as electronic devices.
下面对本申请实施例进行详细介绍。The following describes the embodiments of the present application in detail.
请参阅图1,图1为本申请实施例提供的一种装配路径规划方法的流程示意图,包括:Please refer to FIG. 1. FIG. 1 is a schematic flowchart of an assembly path planning method provided by an embodiment of the application, including:
S101,选取包含起始节点的采样区域。S101. Select a sampling area that includes a starting node.
其中,在路径规划过程中,因为传统RRT算法容易陷入局部最优解且收敛缓慢,对此,本申请对RRT算法做出改进后,提出基于改进RRT算法的装配路径规划方法,可解决传统RRT算法的问题。Among them, in the path planning process, because the traditional RRT algorithm tends to fall into the local optimal solution and the convergence is slow, this application improves the RRT algorithm and proposes an assembly path planning method based on the improved RRT algorithm, which can solve the problem of traditional RRT Algorithm problem.
已知包含起始节点q s和目标节点q e(即预先选定的终点)的一个可行解空间,需要在该可行解空间内寻找从起始节点到目标节点的最近的一条可行路径,以起始节点为采样中心,在该可行解空间内选取包含起始节点的一个区域作为采样区域进行局部采样,使得在满足不陷入局部最优解的前提下取得显著的局部采样效果。 Knowing a feasible solution space containing the starting node q s and the target node q e (that is, the pre-selected end point), it is necessary to find the closest feasible path from the starting node to the target node in the feasible solution space to The starting node is the sampling center, and an area containing the starting node is selected as the sampling area in the feasible solution space for local sampling, so that a significant local sampling effect can be achieved without falling into the local optimal solution.
S102,在所述采样区域内通过随机数产生T个新位姿节点,T为正整数。S102: Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer.
其中,在每次采样过程中,因为新位姿节点生成公式中随机数的不断变化,通过新位姿节点生成公式,可得到T个不同的新位姿节点,形成扩展随机树,T可预定设定,例如,可取5,10,15,20等。Among them, in each sampling process, because the random number in the new pose node generation formula is constantly changing, through the new pose node generation formula, T different new pose nodes can be obtained to form an extended random tree, and T can be predetermined Set, for example, 5, 10, 15, 20 and so on.
S103,从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域。S103: Select a first sampling center from the T new pose nodes, and select a new sampling area that includes the first sampling center.
其中,如图2所示,图2为局部采样示意图,采用局部采样策略,通过当前采样中心确定下一个采样区域,为了尽可能的缩短目标路径的长度,应尽可能缩短当前采样中心与下一采样中心间的距离,因此从所述T个新位姿节点中选取距离当前采样中心最近的节点q near作为所述第一采样中心,并按照S101所述的方法选取包含所述第一采样中心的所述新采样区域。 Among them, as shown in Figure 2, Figure 2 is a schematic diagram of local sampling. The local sampling strategy is adopted to determine the next sampling area through the current sampling center. In order to shorten the length of the target path as much as possible, the current sampling center and the next The distance between the sampling centers, therefore, the node q near that is closest to the current sampling center is selected from the T new pose nodes as the first sampling center, and the first sampling center is selected according to the method described in S101 Of the new sampling area.
S104,重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数。S104. Repeat the method of obtaining the first sampling center until a preset condition is satisfied, and n second sampling centers are obtained, where the preset condition includes that the last second sampling center among the n second sampling centers is The target node, or n=c-1, c is the preset maximum sampling times, and both n and c are positive integers.
其中,每次获取采样中心和采样区域的方法相同,均为根据当前采样中心确定采样区域,在采样区域内确定下一采样中心,重复执行获取所述第一采样中心的方法即迭代采样,直至达到预设的最大采样次数或者达到所述目标节点。Wherein, the method of acquiring the sampling center and the sampling area is the same each time. The sampling area is determined according to the current sampling center, the next sampling center is determined in the sampling area, and the method of obtaining the first sampling center is repeated, until Reach the preset maximum sampling times or reach the target node.
S105,连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。S105. Connect the start node, the first sampling center, and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
其中,连接包括起始节点和目标节点在内的所有的采样中心即得到第一路径,由于传统RRT算法采用全局均匀随机采样策略,因此算法计算量剧大,算法效率低,且无法摆脱局部最优解的困扰,只能得到概率最优解,在本申请实施例中,通过将随机采样、局部采样与终点采样相结合,提高了扩展随机树在迭代采样时采样中心扩展的成功率,提升了传统RRT算法的收敛速度,并解决了局部最优解的问题,具体的,同时通过随机采样、局部采样与终点采样获取可能的路径,得到第一路径,第二路径和第三路径,将上述三个路径进行融合处理,得到最终的目标路径。Among them, the first path is obtained by connecting all sampling centers including the start node and the target node. Because the traditional RRT algorithm uses a global uniform random sampling strategy, the algorithm calculation is huge, the algorithm efficiency is low, and it cannot get rid of the local maximum. The problem of the optimal solution is that only the optimal solution can be obtained. In the embodiment of the present application, by combining random sampling, partial sampling and end-point sampling, the success rate of sampling center expansion of the expanded random tree during iterative sampling is improved, and the success rate of sampling center expansion is improved. The convergence speed of the traditional RRT algorithm is solved, and the problem of local optimal solution is solved. Specifically, the possible paths are obtained through random sampling, local sampling and end-point sampling at the same time, and the first path, the second path and the third path are obtained. The above three paths are fused to obtain the final target path.
其中,在本申请实施例中,所述装配路径规划方法应用于六自由度智能机器人,六自由度智能机器人作为缓解工业生产压力、提升工业生产效率的核心部件,由底座、腰臂、大臂、小臂、腕臂及末端控制器组成,具有结构紧凑、零部件复杂等相关特点。本申请实施例以六自由度机器人为载体,通过仿真验证改进RRT算法在虚拟环境中能否顺利完成路径规划任务,仿真结果表明,针对复杂装配体(六自由度机器人)运用改进RRT算法可成功获得装配体最优装配路径,同时,六自由度机器人装配路径规划的顺利完成证明改进RRT算法具备算法科学性与有效性。Among them, in the embodiment of the present application, the assembly path planning method is applied to a six-degree-of-freedom intelligent robot. The six-degree-of-freedom intelligent robot is a core component that relieves industrial production pressure and improves industrial production efficiency. , Forearm, wrist arm and terminal controller, with compact structure, complex parts and other related characteristics. The embodiment of this application uses a six-degree-of-freedom robot as a carrier to verify whether the improved RRT algorithm can successfully complete the path planning task in a virtual environment through simulation. The simulation result shows that the improved RRT algorithm can be successfully used for complex assemblies (six-degrees of freedom robot). The optimal assembly path of the assembly is obtained. At the same time, the successful completion of the six-degree-of-freedom robot assembly path planning proves that the improved RRT algorithm is scientific and effective.
可以看出,在本申请实施例中,选取包含起始节点的采样区域;在所述采样区域内通过随机数产生T个新位姿节点;从所述T个新位姿节点中选取第 一采样中心,选取包含所述第一采样中心的新采样区域;重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心;连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径;通过该装配路径规划方法,能够大大加快采样收敛速度,并解决传统RRT算法路径规划易陷于局部最优的问题。It can be seen that in this embodiment of the application, the sampling area containing the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first one is selected from the T new pose nodes. Sampling center, select a new sampling area that includes the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the The first sampling center and the n second sampling centers obtain the first path, and obtain the target path according to the first path; this assembly path planning method can greatly accelerate the sampling convergence speed and solve the traditional RRT algorithm path planning It is easy to fall into the problem of local optimum.
可选的,所述在所述采样区域内通过随机数产生T个新位姿节点通过以下公式得到:Optionally, the generating T new pose nodes by random numbers in the sampling area is obtained by the following formula:
q rand=q d+f zf y(q s-q e) q rand = q d +f z f y (q s -q e )
重复公式T次,得到T个所述新位姿节点,以列表的形式记录T个所述新位姿节点,其中,f z为随机数,f z∈(-1,0)∩(0,1),f y为范围因子,f y∈(0,1),q s为起始节点,q e为目标节点,q d为当前采样中心,q rand为新位姿节点。 Repeat the formula T times to obtain T new pose nodes, and record T new pose nodes in the form of a list, where f z is a random number, f z ∈ (-1, 0)∩(0, 1), f y is the range factor, f y ∈ (0, 1), q s is the starting node, q e is the target node, q d is the current sampling center, and q rand is the new pose node.
其中,上述公式为新位姿节点生成公式,若当前采样中心为起始节点,则q d=q s,因为f y的取值直接影响算法的采样效率,若f y取较小值,则局部求解空间较小,不利于跳出局部值,若f y取较大值,则失去了局部采样的意义,局部采样效果不明显,所以,在本申请中,为了保证较优的采样效果,取f y=0.4,本申请对于f y的具体取值不做限定,上述公式中各节点参数均为六维变量,六维包括直角空间坐标系中的X、Y、Z三维和姿势角坐标系中的Yaw、Pitch、Roll三维,其中,Yaw为偏航角,绕Z轴转动,Pitch为俯仰角,绕Y轴转动,Roll为横滚角,绕X轴转动,通过这六个坐标可以确定一个节点参数的坐标信息和姿态信息(朝向)。令q d在空间直角坐标系中的坐标为(x1,y1,z1),q s-q e在空间直角坐标系中的坐标为(x2,y2,z2),则新位姿节点q rand在空间直角坐标系中可能的位置在由点O1(x1-0.4x2,y1-0.4y2,z1-0.4z2)和点O2(x1+0.4x2,y1+0.4y2,z1+0.4z2)为体对角线所构成的长方体内部,该长方体即为所述采样区域,显然,q d在该长方体的中心,可知,在已知起始节点和目标节点以及当前采样中心的空间坐标时,可以确定下一采样区域,同理,可根据q d和q s-q e在姿势角坐标系中的坐标确定T个所述新位姿节点在该长 方体内部的姿态信息(朝向)。 Among them, the above formula is the new pose node generation formula, if the current sampling center is the starting node, then q d =q s , because the value of f y directly affects the sampling efficiency of the algorithm, if f y takes a smaller value, then The local solution space is small, which is not conducive to jumping out of the local value. If f y takes a larger value, the meaning of local sampling is lost, and the local sampling effect is not obvious. Therefore, in this application, in order to ensure a better sampling effect, take f y =0.4, this application does not limit the specific value of f y . Each node parameter in the above formula is a six-dimensional variable, and the six-dimensional includes the X, Y, Z three-dimensional and posture angle coordinate systems in the rectangular space coordinate system The three dimensions of Yaw, Pitch, and Roll, where Yaw is the yaw angle, which rotates around the Z axis, Pitch is the pitch angle, which rotates around the Y axis, and Roll is the roll angle, which rotates around the X axis, which can be determined by these six coordinates The coordinate information and posture information (orientation) of a node parameter. Suppose the coordinates of q d in the spatial rectangular coordinate system are (x1, y1, z1), and the coordinates of q s -q e in the spatial rectangular coordinate system are (x2, y2, z2), then the new pose node q rand is at The possible positions in the spatial rectangular coordinate system consist of the point O1 (x1-0.4x2, y1-0.4y2, z1-0.4z2) and the point O2 (x1+0.4x2, y1+0.4y2, z1+0.4z2) as the body pair Inside the rectangular parallelepiped formed by the corners, the rectangular parallelepiped is the sampling area. Obviously, q d is at the center of the rectangular parallelepiped. It can be seen that when the spatial coordinates of the starting node and target node and the current sampling center are known, the following For a sampling area, in the same way, the posture information (orientation) of the T new posture nodes in the cuboid can be determined according to the coordinates of q d and q s -q e in the posture angle coordinate system.
已知当前节点q d,重复上式T次,因为f z为随机数,所以将得到T个不同的新位姿节点构成的扩展随机树。 Given the current node q d , repeat the above formula T times, because f z is a random number, so an expanded random tree composed of T different new pose nodes will be obtained.
可见,通过上述公式不仅可在当前采样区域内得到满足要求的足够多的新位姿节点,而且不易陷入局部值。It can be seen that the above formula can not only obtain enough new pose nodes to meet the requirements in the current sampling area, but also it is not easy to fall into local values.
可选的,在所述从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域之后,所述方法还包括:Optionally, after the selecting a first sampling center from the T new pose nodes, and selecting a new sampling area containing the first sampling center, the method further includes:
确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点;Confirm whether there is a collision point on the line connecting the starting node and the first sampling center;
若存在所述碰撞点,根据所述目标节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长;If the collision point exists, obtain a new sampling direction according to the target node, the first sampling center and the collision point, and determine the sampling step length;
根据所述采样方向和所述采样步长确定下一个采样中心。The next sampling center is determined according to the sampling direction and the sampling step length.
其中,所述根据所述目标节点,所述第一采样中心和所述碰撞点得到新的采样方向包括:Wherein, the obtaining a new sampling direction according to the target node, the first sampling center and the collision point includes:
确认方向矢量N1与法向量N2间夹角ω的大小,其中,所述方向矢量N1为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle ω between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
若ω>90°,取所述法向量N2的垂直方向为新的采样方向;If ω>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
若ω<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为新的采样方向。If ω<90°, take the angle bisector direction between the direction vector N1 and the normal vector N2 as the new sampling direction.
其中,由于传统RRT算法在路径规划时易陷于局部最优,因此,本申请实施例采用了当扩展随机树进行扩展时,若扩展节点即第一采样中心或第二采样中心位于障碍区域内部,则通过精确碰撞计算来引导扩展随机树的扩展方向。如图3所示,图3为基于精确碰撞计算的扩展策略示意图,其中,q s为起始节点,q e为目标节点,在扩展采样中,q rand为当前采样点,通过计算得出q near为扩展树中距离q rand最近的点,将其作为下一步将扩展的点,但若采取q near 到q rand的扩展方式,会与障碍区域发生碰撞,碰撞点为q c,则导致新位姿扩展点q new扩展不成功。因此,获取q c与q e之间的方向向量N1与碰撞点q c的法向量N2,且令ω为方向矢量N1与法向量N2的矢量夹角,则有
Figure PCTCN2019117030-appb-000001
Figure PCTCN2019117030-appb-000002
当ω>90°时,如图3环“1”所示,取碰撞点q c的法向量N2的垂直方向为新的采样方向N,且N=N 1sinω;当ω<90°时,如图3“环2”所示,取N1与N2之间的角平分线方向为新的采样方向N,且
Figure PCTCN2019117030-appb-000003
确定采样步长,根据当前采样点q rand、采样方向N和采样步长确定下一个采样中心进行扩展,直至到达终止条件(与障碍物发生碰撞或达到预设最大采样次数)。基于精确碰撞计算与大跨步尝试移出的扩展策略来解决这一问题。
Among them, because the traditional RRT algorithm tends to fall into the local optimum during path planning, the embodiment of the present application adopts when the random tree is expanded for expansion, if the expanded node, that is, the first sampling center or the second sampling center is located inside the obstacle area, Then, accurate collision calculation is used to guide the expansion direction of the expanded random tree. As shown in Figure 3, Figure 3 is a schematic diagram of the expansion strategy based on accurate collision calculation, where q s is the starting node and q e is the target node. In the extended sampling, q rand is the current sampling point, and q is obtained by calculation. Near is the point closest to q rand in the expansion tree, which is used as the point to be expanded in the next step. However, if the expansion method from q near to q rand is adopted, it will collide with the obstacle area. The collision point is q c , which will lead to new The pose extension point q new is not successfully extended. Therefore, to obtain the direction vector N1 between q c and q e and the normal vector N2 of the collision point q c , and let ω be the angle between the direction vector N1 and the normal vector N2, then there is
Figure PCTCN2019117030-appb-000001
Figure PCTCN2019117030-appb-000002
When ω>90°, as shown in the circle “1” in Figure 3, take the vertical direction of the normal vector N2 of the collision point q c as the new sampling direction N, and N=N 1 sinω; when ω<90°, As shown in Figure 3 "Ring 2", take the direction of the angle bisector between N1 and N2 as the new sampling direction N, and
Figure PCTCN2019117030-appb-000003
Determine the sampling step length, and determine the next sampling center to expand according to the current sampling point q rand , sampling direction N and sampling step length until the termination condition is reached (a collision with an obstacle or a preset maximum sampling number is reached). This problem is solved by an expansion strategy based on accurate collision calculations and large-stride attempts.
可见,采用基于精确碰撞计算与大跨步尝试移出的扩展策略,可以缩短算法收敛时间,提高算法扩展效率。It can be seen that the use of an expansion strategy based on accurate collision calculation and large-stride attempts to move out can shorten the algorithm convergence time and improve the efficiency of algorithm expansion.
可选的,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述方法还包括:Optionally, after the first path is obtained by connecting the start node, the first sampling center, and the n second sampling centers, the method further includes:
通过随机采样得到第二路径;Obtain the second path through random sampling;
通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
其中,随机采样是在可行解空间内随机地选取采样点,是传统RRT算法的基本采样策略,终点采样是在可行解空间内将目标节点作为采样点进行采样,终点采样策略可以使扩展随机树快速向目标节点收敛。Among them, random sampling is to randomly select sampling points in the feasible solution space, which is the basic sampling strategy of the traditional RRT algorithm. End-point sampling is to sample the target node as the sampling point in the feasible solution space. The end-point sampling strategy can expand the random tree Converge quickly to the target node.
可见,在本申请中,并行执行随机采样、终点采样以及局部采样三种策略,可得到从起始节点到目标节点的可行路径,分别为第一路径、第二路径和第三路径。It can be seen that in this application, three strategies of random sampling, end-point sampling, and partial sampling are executed in parallel to obtain feasible paths from the start node to the target node, which are the first path, the second path, and the third path, respectively.
可选的,所述根据所述第一路径得到目标路径包括:Optionally, the obtaining the target path according to the first path includes:
对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
其中,对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径包括:在平面直角坐标系的横轴上选取等距离的k个横坐标;Wherein, performing mathematical processing on the first path, the second path, and the third path to obtain the target path includes: selecting k equidistant abscissas on the abscissa of the planar rectangular coordinate system;
确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
其中,可通过对第一路径、第二路径和第三路径进行平均加权处理得到最终的目标路径,具体的,在平面直角坐标系中,在x轴上依次选取等距离的k个横坐标(k1,k2,,,kn),确定第一路径中对应k1,k2,,,kn的纵坐标a1,a2,,,an,确定第二路径中对应k1,k2,,,kn的纵坐标b1,b2,,,bn,确定第三路径中对应k1,k2,,,kn的纵坐标c1,c2,,,cn,对第一路径、第二路径和第三路径在上述各横坐标处的纵坐标进行平均加权处理,得到y1=(a1+b1+c1)/3,y2=(a2+b2+c3)/3,,,yn=(an+bn+cn)/3,得到k个目标采样中心m1(k1,y1),m2(k2,y2),,,mn(kn,yn),依次连接m1,m2,,,mn,得到新的路径,即为目标路径。Among them, the final target path can be obtained by averaging the weighting of the first path, the second path, and the third path. Specifically, in a rectangular coordinate system, k equidistant abscissas ( k1, k2,,, kn), determine the ordinate a1, a2,,, an in the first path corresponding to k1, k2,,, kn, determine the ordinate b1 in the second path corresponding to k1, k2,,, kn , B2,,, bn, determine the ordinates c1, c2,,, cn of the third path corresponding to k1, k2,,, kn, for the first path, the second path, and the third path at each of the above-mentioned abscissas Perform average weighting on the ordinate to get y1=(a1+b1+c1)/3, y2=(a2+b2+c3)/3,,, yn=(an+bn+cn)/3, get k targets Sampling centers m1 (k1, y1), m2 (k2, y2),,, mn (kn, yn), sequentially connect m1, m2,,, mn to obtain a new path, which is the target path.
也可通过其他方式对上述三种路径进行处理得到目标路径,本申请对此不做限定。The target path can also be obtained by processing the above three paths in other ways, which is not limited in this application.
可见,通过将随机采样、局部采样与终点采样相结合,提高了扩展随机树在迭代时节点扩展的成功率,保证了改进RRT算法具有较高的收敛速度。It can be seen that by combining random sampling, local sampling and end-point sampling, the success rate of node expansion during iteration of the expanded random tree is improved, and the improved RRT algorithm has a higher convergence speed.
请参阅图4,图4为本申请实施例提供的一种电子设备的结构示意图,如图所示,包括处理器、存储器、通信接口,以及一个或多个程序,所述程序被存储在所述存储器中,并且被配置由所述处理器执行。Please refer to FIG. 4, which is a schematic structural diagram of an electronic device provided by an embodiment of the application. As shown in the figure, it includes a processor, a memory, a communication interface, and one or more programs. In the memory, and configured to be executed by the processor.
可选的,所述程序包括用于执行以下步骤的指令:Optionally, the program includes instructions for executing the following steps:
选取包含起始节点的采样区域;Select the sampling area that contains the starting node;
在所述采样区域内通过随机数产生T个新位姿节点,T为正整数;Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer;
从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;Selecting a first sampling center from the T new pose nodes, and selecting a new sampling area that includes the first sampling center;
重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;Repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes that the last second sampling center among the n second sampling centers is the target node , Or, n=c-1, c is the preset maximum sampling times, n and c are both positive integers;
连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。Connecting the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtaining a target path according to the first path.
可选的,在所述从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域之后,所述程序包括用于执行以下步骤的指令:Optionally, after the first sampling center is selected from the T new pose nodes, and a new sampling area containing the first sampling center is selected, the program includes instructions for executing the following steps:
确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点;Confirm whether there is a collision point on the line connecting the starting node and the first sampling center;
若存在所述碰撞点,根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长;If the collision point exists, obtain a new sampling direction according to the starting node, the first sampling center and the collision point, and determine the sampling step length;
根据所述采样方向和所述采样步长确定下一个采样中心。The next sampling center is determined according to the sampling direction and the sampling step length.
可选的,在所述根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向方面,所述程序包括用于执行以下步骤的指令:Optionally, in terms of obtaining a new sampling direction according to the starting node, the first sampling center and the collision point, the program includes instructions for executing the following steps:
确认方向矢量N1与法向量N2间夹角ω的大小,其中,所述方向矢量N1为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle ω between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
若ω>90°,取所述法向量N2的垂直方向为新的采样方向;If ω>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
若ω<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为新的采样方向。If ω<90°, take the angle bisector direction between the direction vector N1 and the normal vector N2 as the new sampling direction.
可选的,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述程序包括用于执行以下步骤的指令:Optionally, after the first path is obtained by connecting the starting node, the first sampling center, and the n second sampling centers, the program includes instructions for executing the following steps:
通过随机采样得到第二路径;Obtain the second path through random sampling;
通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
可选的,在所述根据所述第一路径得到目标路径方面,所述程序包括用于 执行以下步骤的指令:Optionally, in terms of obtaining the target path according to the first path, the program includes instructions for executing the following steps:
对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
可选的,在所述对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径方面,所述程序包括用于执行以下步骤的指令:Optionally, in terms of performing mathematical processing on the first path, the second path, and the third path to obtain a target path, the program includes instructions for executing the following steps:
在平面直角坐标系的横轴上选取等距离的k个横坐标;Select k equidistant abscissas on the horizontal axis of the rectangular coordinate system;
确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
上述主要从方法执行过程的角度对本申请实施例的方案进行了介绍。可以理解的是,终端为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所提供的实施例描述的各示例的单元及算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。The foregoing mainly introduces the solution of the embodiment of the present application from the perspective of the method execution process. It can be understood that, in order to implement the above-mentioned functions, the terminal includes hardware structures and/or software modules corresponding to each function. Those skilled in the art should easily realize that in combination with the units and algorithm steps of the examples described in the embodiments provided herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed by hardware or computer software-driven hardware depends on the specific application and design constraint conditions of the technical solution. Professionals and technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered beyond the scope of this application.
本申请实施例可以根据上述方法示例对终端进行功能单元的划分,例如,可以对应各个功能划分各个功能单元,也可以将两个或两个以上的功能集成在一个处理单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。需要说明的是,本申请实施例中对单元的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。The embodiments of the present application may divide the terminal into functional units according to the foregoing method examples. For example, each functional unit may be divided corresponding to each function, or two or more functions may be integrated into one processing unit. The above-mentioned integrated unit can be implemented in the form of hardware or software functional unit. It should be noted that the division of units in the embodiments of the present application is illustrative, and is only a logical function division, and there may be other division methods in actual implementation.
与上述一致的,请参阅图5,图5为本申请实施例提供的一种装配路径规 划装置500的结构示意图。所述装配路径规划装置500包括采样单元501、路径获取单元502,其中:Consistent with the above, please refer to Fig. 5, which is a schematic structural diagram of an assembly path planning device 500 provided by an embodiment of the application. The assembly route planning device 500 includes a sampling unit 501 and a route acquisition unit 502, wherein:
采样单元501,用于选取包含起始节点的采样区域,以及在所述采样区域内通过随机数产生T个新位姿节点,T为正整数,以及从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域,以及重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;The sampling unit 501 is configured to select a sampling area containing the starting node, and generate T new pose nodes by random numbers in the sampling area, where T is a positive integer, and select from the T new pose nodes A first sampling center, selecting a new sampling area that includes the first sampling center, and repeating the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, the preset condition Including the last second sampling center among the n second sampling centers as the target node, or n=c-1, c is the preset maximum number of sampling times, and both n and c are positive integers;
路径获取单元502,用于连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。The path obtaining unit 502 is configured to connect the start node, the first sampling center, and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
可选的,所述采样单元501在所述采样区域内通过以下公式产生T个新位姿节点:Optionally, the sampling unit 501 generates T new pose nodes in the sampling area through the following formula:
q rand=q d+f zf y(q s-q e) q rand = q d +f z f y (q s -q e )
重复上式T次,得到T个所述新位姿节点,其中,f z为随机数,f z∈(-1,0)∩(0,1),f y为范围因子,f y∈(0,1),q s为起始节点,q e为目标节点,q d为当前采样中心,q rand为新位姿节点。 Repeat the above formula T times to obtain T new pose nodes, where f z is a random number, f z ∈(-1,0)∩(0,1), f y is a range factor, and f y ∈( 0, 1), q s is the starting node, q e is the target node, q d is the current sampling center, and q rand is the new pose node.
可选的,所述装配路径规划装置还包括避障单元503,用于确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点,以及若存在所述碰撞点,根据所述目标节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长,以及根据所述采样方向和所述采样步长确定下一个采样中心。Optionally, the assembly path planning device further includes an obstacle avoidance unit 503 for confirming whether there is a collision point on the line between the starting node and the first sampling center, and if the collision point exists, according to The target node, the first sampling center, and the collision point obtain a new sampling direction, determine a sampling step, and determine the next sampling center according to the sampling direction and the sampling step.
可选的,在所述根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向方面,所述避障单元503具体用于:Optionally, in terms of obtaining a new sampling direction according to the starting node, the first sampling center and the collision point, the obstacle avoidance unit 503 is specifically configured to:
确认方向矢量N1与法向量N2间夹角ω的大小,其中,所述方向矢量N1为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle ω between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
若ω>90°,取所述法向量N2的垂直方向为新的采样方向;If ω>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
若ω<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为 新的采样方向。If ω<90°, take the direction of the angular bisector between the direction vector N1 and the normal vector N2 as the new sampling direction.
可选的,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述路径获取单元502具体用于:Optionally, after the first path is obtained by connecting the starting node, the first sampling center, and the n second sampling centers, the path obtaining unit 502 is specifically configured to:
通过随机采样得到第二路径;Obtain the second path through random sampling;
通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
可选的,在所述根据所述第一路径得到目标路径方面,所述路径获取单元502具体用于:Optionally, in terms of obtaining the target path according to the first path, the path obtaining unit 502 is specifically configured to:
对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
可选的,在所述对所述第一路径、所述第二路径和所述第三路径进行数学处理方面,所述路径获取单元502具体用于:Optionally, in terms of performing mathematical processing on the first path, the second path, and the third path, the path obtaining unit 502 is specifically configured to:
在平面直角坐标系的横轴上选取等距离的k个横坐标;Select k equidistant abscissas on the horizontal axis of the rectangular coordinate system;
确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
其中,上述单元可以用于执行上述实施例中所述的方法,具体描述详见实施例的描述,在此不再赘述。The above-mentioned unit may be used to execute the method described in the above-mentioned embodiment. For specific description, please refer to the description of the embodiment, which will not be repeated here.
在本申请实施例中,选取包含起始节点的采样区域;在所述采样区域内通过随机数产生T个新位姿节点;从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心;连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径;通过该装配路径规划方法,能够大大加快采样收敛速度,并解决传统RRT算法路径规划易陷于局部最优的问题。In the embodiment of the present application, a sampling area containing the starting node is selected; T new pose nodes are generated by random numbers in the sampling area; the first sampling center is selected from the T new pose nodes, and A new sampling area including the first sampling center; repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained; connect the start node and the first sampling The center and the n second sampling centers obtain the first path, and the target path is obtained according to the first path; through this assembly path planning method, the sampling convergence speed can be greatly accelerated, and the path planning of the traditional RRT algorithm is easily trapped in the local maximum. Excellent question.
本申请实施例还提供一种计算机非易失性可读存储介质,存储用于电子数据交换的计算机程序,该计算机程序使得计算机执行如上述方法实施例中记载的任何一种装配路径规划方法的部分或全部步骤。The embodiment of the present application also provides a computer non-volatile readable storage medium that stores a computer program for electronic data exchange. The computer program enables the computer to execute any of the assembly path planning methods described in the above method embodiments. Part or all of the steps.
本申请实施例还提供一种计算机程序产品,所述计算机程序产品包括存储了计算机程序的非瞬时性计算机非易失性可读存储介质,该计算机程序使得计算机执行如上述方法实施例中记载的任何一种装配路径规划方法的部分或全部步骤。The embodiments of the present application also provide a computer program product. The computer program product includes a non-transitory computer non-volatile readable storage medium storing a computer program. The computer program causes a computer to execute the method described in the foregoing method embodiment. Part or all of the steps of any assembly path planning method.
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。It should be noted that for the foregoing method embodiments, for the sake of simple description, they are all expressed as a series of action combinations, but those skilled in the art should know that this application is not limited by the described sequence of actions. Because according to this application, some steps can be performed in other order or at the same time. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by this application. In the above-mentioned embodiments, the description of each embodiment has its own focus. For parts that are not described in detail in an embodiment, reference may be made to related descriptions of other embodiments.
以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。As mentioned above, the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: The technical solutions recorded in the embodiments are modified, or some of the technical features are equivalently replaced; these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims (20)

  1. 一种装配路径规划方法,其特征在于,所述方法包括:An assembly path planning method, characterized in that the method includes:
    选取包含起始节点的采样区域;Select the sampling area that contains the starting node;
    在所述采样区域内通过随机数产生T个新位姿节点,T为正整数;Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer;
    从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;Selecting a first sampling center from the T new pose nodes, and selecting a new sampling area that includes the first sampling center;
    重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;Repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes that the last second sampling center among the n second sampling centers is the target node , Or, n=c-1, c is the preset maximum sampling times, n and c are both positive integers;
    连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。Connecting the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtaining a target path according to the first path.
  2. 根据权利要求1所述的方法,其特征在于,所述在所述采样区域内通过随机数产生T个新位姿节点通过以下公式得到:The method according to claim 1, wherein the generating T new pose nodes by random numbers in the sampling area is obtained by the following formula:
    q rand=q d+f zf y(q s-q e) q rand = q d +f z f y (q s -q e )
    重复公式T次,得到T个所述新位姿节点,其中,f z为随机数,f z∈(-1,0)∩(0,1),f y为范围因子,f y∈(0,1),q s为起始节点,q e为目标节点,q d为当前采样中心,q rand为新位姿节点。 Repeat the formula T times to obtain T new pose nodes, where f z is a random number, f z ∈ (-1, 0) ∩ (0, 1), f y is a range factor, and f y ∈ (0 , 1), q s is the starting node, q e is the target node, q d is the current sampling center, and q rand is the new pose node.
  3. 根据权利要求1所述的方法,其特征在于,在所述从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域之后,所述方法还包括:The method according to claim 1, wherein after said selecting a first sampling center from the T new pose nodes and selecting a new sampling area containing the first sampling center, the method further include:
    确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点;Confirm whether there is a collision point on the line connecting the starting node and the first sampling center;
    若存在所述碰撞点,根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长;If the collision point exists, obtain a new sampling direction according to the starting node, the first sampling center and the collision point, and determine the sampling step length;
    根据所述采样方向和所述采样步长确定下一个采样中心。The next sampling center is determined according to the sampling direction and the sampling step length.
  4. 根据权利要求3所述的方法,其特征在于,所述根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向包括:The method according to claim 3, wherein the obtaining a new sampling direction according to the starting node, the first sampling center and the collision point comprises:
    确认方向矢量N1与法向量N2间夹角ω的大小,其中,所述方向矢量N1 为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle ω between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
    若ω>90°,取所述法向量N2的垂直方向为新的采样方向;If ω>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
    若ω<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为新的采样方向。If ω<90°, take the angle bisector direction between the direction vector N1 and the normal vector N2 as the new sampling direction.
  5. 根据权利要求1所述的方法,其特征在于,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述方法还包括:The method according to claim 1, wherein after the first path is obtained by connecting the starting node, the first sampling center, and the n second sampling centers, the method further comprises:
    通过随机采样得到第二路径;Obtain the second path through random sampling;
    通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
  6. 根据权利要求5所述的方法,其特征在于,所述根据所述第一路径得到目标路径包括:The method according to claim 5, wherein the obtaining the target path according to the first path comprises:
    对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
  7. 根据权利要求6所述的方法,其特征在于,所述对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径包括:The method according to claim 6, wherein said performing mathematical processing on said first path, said second path and said third path to obtain a target path comprises:
    在平面直角坐标系的横轴上选取等距离的k个横坐标;Select k equidistant abscissas on the horizontal axis of the rectangular coordinate system;
    确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
    根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  8. 一种装配路径规划装置,其特征在于,所述装配路径规划装置包括:An assembly path planning device, characterized in that the assembly path planning device includes:
    采样单元,用于选取包含起始节点的采样区域,以及在所述采样区域内通过随机数产生T个新位姿节点,T为正整数,以及从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域,以及重复执行获 取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;The sampling unit is used to select a sampling area that includes the starting node, and generate T new pose nodes by random numbers in the sampling area, where T is a positive integer, and select the first from the T new pose nodes A sampling center, selecting a new sampling area that includes the first sampling center, and repeating the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes The last second sampling center among the n second sampling centers is the target node, or n=c-1, c is the preset maximum number of sampling times, and both n and c are positive integers;
    路径获取单元,用于连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。The path obtaining unit is configured to connect the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtain a target path according to the first path.
  9. 根据权利要求8所述的装配路径规划装置,其特征在于,所述装配路径规划装置还包括:8. The assembly path planning device according to claim 8, wherein the assembly path planning device further comprises:
    避障单元,用于确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点,以及若存在所述碰撞点,根据所述目标节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长,以及根据所述采样方向和所述采样步长确定下一个采样中心。The obstacle avoidance unit is used to confirm whether there is a collision point on the line between the start node and the first sampling center, and if the collision point exists, according to the target node, the first sampling center and the first sampling center The collision point obtains a new sampling direction, the sampling step is determined, and the next sampling center is determined according to the sampling direction and the sampling step.
  10. 根据权利要求9所述的装配路径规划装置,其特征在于,在所述根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向方面,所述避障单元具体用于:The assembly path planning device according to claim 9, wherein, in terms of obtaining a new sampling direction according to the starting node, the first sampling center and the collision point, the obstacle avoidance unit specifically Used for:
    确认方向矢量N1与法向量N2间夹角w的大小,其中,所述方向矢量N1为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle w between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
    若w>90°,取所述法向量N2的垂直方向为新的采样方向;If w>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
    若w<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为新的采样方向。If w<90°, take the angle bisector direction between the direction vector N1 and the normal vector N2 as the new sampling direction.
  11. 根据权利要求8所述的装配路径规划装置,其特征在于,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述路径获取单元具体用于:The assembly path planning device according to claim 8, wherein after the first path is obtained by connecting the starting node, the first sampling center, and the n second sampling centers, the path The acquisition unit is specifically used for:
    通过随机采样得到第二路径;Obtain the second path through random sampling;
    通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
  12. 根据权利要求11所述的装配路径规划装置,其特征在于,在所述根据所述第一路径得到目标路径方面,所述路径获取单元具体用于:The assembly path planning device according to claim 11, wherein, in terms of obtaining the target path according to the first path, the path obtaining unit is specifically configured to:
    对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
  13. 根据权利要求12所述的装配路径规划装置,其特征在于,在所述对所述第一路径、所述第二路径和所述第三路径进行数学处理方面,所述路径获取单元具体用于:The assembly path planning device according to claim 12, wherein, in terms of performing mathematical processing on the first path, the second path, and the third path, the path acquisition unit is specifically configured to :
    在平面直角坐标系的横轴上选取等距离的k个横坐标;Select k equidistant abscissas on the horizontal axis of the rectangular coordinate system;
    确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
    根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  14. 一种电子设备,其特征在于,包括处理器、存储器、通信接口,以及一个或多个程序,所述程序被存储在所述存储器中,并且被配置由所述处理器执行,所述程序被配置用于执行以下步骤:An electronic device, characterized by comprising a processor, a memory, a communication interface, and one or more programs, the programs are stored in the memory and configured to be executed by the processor, and the programs are The configuration is used to perform the following steps:
    选取包含起始节点的采样区域;Select the sampling area that contains the starting node;
    在所述采样区域内通过随机数产生T个新位姿节点,T为正整数;Generate T new pose nodes through random numbers in the sampling area, where T is a positive integer;
    从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域;Selecting a first sampling center from the T new pose nodes, and selecting a new sampling area that includes the first sampling center;
    重复执行获取所述第一采样中心的方法,直至满足预设条件,得到n个第二采样中心,所述预设条件包括所述n个第二采样中心中最后一个第二采样中心为目标节点,或者,n=c-1,c为预设最大采样次数,n和c均为正整数;Repeat the method of obtaining the first sampling center until a preset condition is met, and n second sampling centers are obtained, and the preset condition includes that the last second sampling center among the n second sampling centers is the target node , Or, n=c-1, c is the preset maximum sampling times, n and c are both positive integers;
    连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径,根据所述第一路径得到目标路径。Connecting the starting node, the first sampling center and the n second sampling centers to obtain a first path, and obtaining a target path according to the first path.
  15. 根据权利要求14所述的电子设备,其特征在于,在所述从所述T个新位姿节点中选取第一采样中心,选取包含所述第一采样中心的新采样区域之后,所述程序被配置用于执行以下步骤:The electronic device according to claim 14, wherein after the selecting a first sampling center from the T new pose nodes and selecting a new sampling area containing the first sampling center, the program Is configured to perform the following steps:
    确认所述起始节点与所述第一采样中心的连线上是否存在碰撞点;Confirm whether there is a collision point on the line connecting the starting node and the first sampling center;
    若存在所述碰撞点,根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向,确定采样步长;If the collision point exists, obtain a new sampling direction according to the starting node, the first sampling center and the collision point, and determine the sampling step length;
    根据所述采样方向和所述采样步长确定下一个采样中心。The next sampling center is determined according to the sampling direction and the sampling step length.
  16. 根据权利要求15所述的电子设备,其特征在于,在所述根据所述起始节点,所述第一采样中心和所述碰撞点得到新的采样方向方面,所述程序被配置用于执行以下步骤:The electronic device according to claim 15, wherein, in terms of obtaining a new sampling direction according to the starting node, the first sampling center and the collision point, the program is configured to execute The following steps:
    确认方向矢量N1与法向量N2间夹角ω的大小,其中,所述方向矢量N1为所述碰撞点到所述目标节点的方向矢量,所述法向量N2为所述碰撞点的法向量;Confirm the size of the angle ω between the direction vector N1 and the normal vector N2, where the direction vector N1 is the direction vector from the collision point to the target node, and the normal vector N2 is the normal vector of the collision point;
    若ω>90°,取所述法向量N2的垂直方向为新的采样方向;If ω>90°, take the vertical direction of the normal vector N2 as the new sampling direction;
    若ω<90°,取所述方向矢量N1与所述法向量N2之间的角平分线方向为新的采样方向。If ω<90°, take the angle bisector direction between the direction vector N1 and the normal vector N2 as the new sampling direction.
  17. 根据权利要求14所述的电子设备,其特征在于,在所述连接所述起始节点、所述第一采样中心和所述n个第二采样中心获得第一路径之后,所述程序被配置用于执行以下步骤:The electronic device according to claim 14, wherein after the first path is obtained by connecting the starting node, the first sampling center, and the n second sampling centers, the program is configured Used to perform the following steps:
    通过随机采样得到第二路径;Obtain the second path through random sampling;
    通过终点采样得到第三路径。The third path is obtained by sampling at the end point.
  18. 根据权利要求17所述的电子设备,其特征在于,在所述根据所述第一路径得到目标路径方面,所述程序被配置用于执行以下步骤:The electronic device according to claim 17, wherein, in terms of obtaining the target path according to the first path, the program is configured to perform the following steps:
    对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径。Perform mathematical processing on the first path, the second path, and the third path to obtain a target path.
  19. 根据权利要求18所述的电子设备,其特征在于,在所述对所述第一路径、所述第二路径和所述第三路径进行数学处理,得到目标路径方面,所述程序被配置用于执行以下步骤:The electronic device according to claim 18, wherein in the aspect of performing mathematical processing on the first path, the second path, and the third path to obtain a target path, the program is configured to To perform the following steps:
    在平面直角坐标系的横轴上选取等距离的k个横坐标;Select k equidistant abscissas on the horizontal axis of the rectangular coordinate system;
    确定所述第一路径上与所述k个横坐标对应的k个第一纵坐标,确定所述 第二路径上与所述k个横坐标对应的k个第二纵坐标,确定所述第三路径上与所述k个横坐标对应的k个第三纵坐标;Determine the k first ordinates corresponding to the k abscissas on the first path, determine the k second ordinates corresponding to the k abscissas on the second path, and determine the first K third ordinates corresponding to the k abscissas on the three paths;
    根据所述k个第一纵坐标、所述k个第二纵坐标和所述k个第三纵坐标得到与所述k个横坐标对应的k个目标纵坐标,根据所述k个目标纵坐标得到k个目标采样中心,连接所述k个目标采样中心得到所述目标路径。According to the k first ordinates, the k second ordinates, and the k third ordinates, k target ordinates corresponding to the k abscissas are obtained, and according to the k target ordinates The coordinates obtain k target sampling centers, and the k target sampling centers are connected to obtain the target path.
  20. 一种计算机非易失性非易失性可读存储介质,其特征在于,所述计算机非易失性非易失性可读存储介质上存储有计算机程序,该程序被处理器执行时实现权利要求1至7任一项所述的方法。A computer non-volatile non-volatile readable storage medium, characterized in that, a computer program is stored on the computer non-volatile non-volatile readable storage medium, and the program is executed by a processor to realize the rights The method of any one of 1 to 7 is required.
PCT/CN2019/117030 2019-09-02 2019-11-11 Assembly path planning method and related device WO2021042519A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910824569.2A CN110646006A (en) 2019-09-02 2019-09-02 Assembly path planning method and related device
CN201910824569.2 2019-09-02

Publications (1)

Publication Number Publication Date
WO2021042519A1 true WO2021042519A1 (en) 2021-03-11

Family

ID=69009998

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/117030 WO2021042519A1 (en) 2019-09-02 2019-11-11 Assembly path planning method and related device

Country Status (2)

Country Link
CN (1) CN110646006A (en)
WO (1) WO2021042519A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113985884A (en) * 2021-10-29 2022-01-28 国网山东省电力公司经济技术研究院 Power inspection robot path planning method and system and robot

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111220786A (en) * 2020-03-09 2020-06-02 生态环境部华南环境科学研究所 Method for rapidly monitoring organic pollution of deep water sediments
CN112344938B (en) * 2020-10-31 2022-07-19 安徽中科源起科技有限公司 Space environment path generation and planning method based on pointing and potential field parameters
CN112987799B (en) * 2021-04-16 2022-04-05 电子科技大学 Unmanned aerial vehicle path planning method based on improved RRT algorithm

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102375416A (en) * 2010-08-13 2012-03-14 同济大学 Human type robot kicking action information processing method based on rapid search tree
CN102708242A (en) * 2012-05-07 2012-10-03 上海飞机制造有限公司 Method and device for solving disassembling path of product pipe piece
CN106695802A (en) * 2017-03-19 2017-05-24 北京工业大学 Improved RRT<*> obstacle avoidance motion planning method based on multi-degree-of-freedom mechanical arm
US20170241790A1 (en) * 2016-02-24 2017-08-24 Honda Motor Co., Ltd. Path plan generating apparatus for mobile body
CN110083165A (en) * 2019-05-21 2019-08-02 大连大学 A kind of robot paths planning method under complicated narrow environment

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108983780A (en) * 2018-07-24 2018-12-11 武汉理工大学 One kind is based on improvement RRT*The method for planning path for mobile robot of algorithm
CN109886279B (en) * 2019-01-24 2023-09-29 平安科技(深圳)有限公司 Image processing method, device, computer equipment and storage medium
CN109877836B (en) * 2019-03-13 2021-06-08 浙江大华技术股份有限公司 Path planning method and device, mechanical arm controller and readable storage medium
CN110181515B (en) * 2019-06-10 2020-12-01 浙江工业大学 Double-mechanical-arm cooperative assembly operation path planning method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102375416A (en) * 2010-08-13 2012-03-14 同济大学 Human type robot kicking action information processing method based on rapid search tree
CN102708242A (en) * 2012-05-07 2012-10-03 上海飞机制造有限公司 Method and device for solving disassembling path of product pipe piece
US20170241790A1 (en) * 2016-02-24 2017-08-24 Honda Motor Co., Ltd. Path plan generating apparatus for mobile body
CN106695802A (en) * 2017-03-19 2017-05-24 北京工业大学 Improved RRT<*> obstacle avoidance motion planning method based on multi-degree-of-freedom mechanical arm
CN110083165A (en) * 2019-05-21 2019-08-02 大连大学 A kind of robot paths planning method under complicated narrow environment

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113985884A (en) * 2021-10-29 2022-01-28 国网山东省电力公司经济技术研究院 Power inspection robot path planning method and system and robot

Also Published As

Publication number Publication date
CN110646006A (en) 2020-01-03

Similar Documents

Publication Publication Date Title
WO2021042519A1 (en) Assembly path planning method and related device
CN108537841B (en) Robot picking method and device and electronic equipment
KR20220062622A (en) Data processing methods and related devices
CN110751039B (en) Multi-view 3D human body posture estimation method and related device
CN107563295B (en) Multi-Kinect-based all-dimensional human body tracking method and processing equipment
CN112784739B (en) Model training method, key point positioning method, device, equipment and medium
CN110599586A (en) Semi-dense scene reconstruction method and device, electronic equipment and storage medium
CN110991526A (en) Non-iterative point cloud matching method, medium, terminal and device
CN110082713A (en) Localization method, terminal device and storage medium
CN109844774A (en) A kind of parallel deconvolution calculation method, single engine calculation method and Related product
JP2021122736A5 (en)
CN104346797A (en) Key pixel point matching method and device, and image matching method and device
CN110111249A (en) A kind of acquisition of tunnel inner wall picture mosaic image and generation method and system
CN109523634A (en) Optimize the method and device of grid
CN115437372A (en) Robot path planning method and device, electronic equipment and storage medium
CN110414663A (en) The convolution implementation method and Related product of neural network
CN115107021A (en) Mechanical arm path planning rapid prototyping system
Matsushita et al. Behavior of independent-minded particle swarm optimization
CN112991463A (en) Camera calibration method, device, equipment, storage medium and program product
JP6492779B2 (en) Mapping information generating program, mapping information generating method, and mapping information generating apparatus
Ni et al. An optimized POSIT algorithm based on mean convergence
CN111144212B (en) Depth image target segmentation method and device
CN113327328B (en) Three-dimensional point cloud data compaction method
CN117876439A (en) Calibration method, device, equipment and storage medium for center point of mechanical arm end tool
CN113843800A (en) Optimization method for solving mechanical arm working space by improved Monte Carlo method

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19944378

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19944378

Country of ref document: EP

Kind code of ref document: A1