Motion planning method and device of unmanned aerial vehicle, equipment and medium

By generating a set of path points in the UAV motion planning and applying gradient velocity curve planning and trajectory optimization algorithms, the problem of inaccurate time allocation is solved, thereby improving the stability and safety of UAV flight.

CN121346809APending Publication Date: 2026-01-16SHAOGUAN POWER SUPPLY BUREAU OF GUANGDONG POWER GRID CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511772867.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-27
Publication Date
2026-01-16

AI Technical Summary

Technical Problem

Existing technologies often suffer from inaccurate time allocation when generating drone trajectories, leading to distorted trajectories and affecting drone flight stability.

Method used

By acquiring a grid map and a set of obstacles, a path search algorithm is used to generate a set of path points. Combined with a gradient velocity curve planning algorithm and a trajectory optimization algorithm, the time allocation for each path segment is determined, and a smooth and continuous motion trajectory is generated.

Benefits of technology

It improves the accuracy of time allocation, enhances the smoothness and continuity of motion trajectory, and ensures the stability and safety of drone flight.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121346809A_ABST
    Figure CN121346809A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a motion planning method and device of an unmanned aerial vehicle, equipment and a medium. The method comprises the following steps: acquiring a grating map and an obstacle set of a to-be-planned area and an initial position and a target position of an unmanned aerial vehicle; according to the initial position, the target position and the obstacle set, generating a path point set in a grating map by adopting a path search algorithm; acquiring a plurality of path segments according to the path point set; for each path segment, according to a preset maximum acceleration of the unmanned aerial vehicle and a preset maximum speed, determining time distribution of each path segment by adopting a gradient velocity curve planning algorithm; and based on the time distribution of each path segment, generating a motion trajectory of the unmanned aerial vehicle through a trajectory optimization algorithm. The method is used for improving the time distribution precision of each path segment, further improving the smooth continuity of the motion trail obtained through optimization, and guaranteeing the flight stability of the unmanned aerial vehicle.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of path planning, and in particular to a motion planning method and device for a UAV, equipment and a medium. BACKGROUND

[0002] Autonomous navigation and motion planning of a quadrotor UAV in a complex dynamic environment is one of the core research directions in the field of intelligent aircraft. When a quadrotor UAV autonomously navigates in a complex environment, it not only needs to detect obstacles, but also needs to plan and execute a collision-free and dynamically feasible trajectory. Therefore, the UAV needs to complete motion planning in a short time to cope with complex environmental changes and ensure that the UAV can successfully reach the target point to perform a task.

[0003] Since the generated trajectory is a time-parameterized path, when the trajectory is optimized in the back end, an appropriate time needs to be allocated to each segment of the trajectory for solving. The rationality of time allocation seriously affects the planning result. Currently, the same time is usually assigned to each path or the time is allocated according to the Euclidean distance between path points.

[0004] However, this simple and rough allocation method may cause the generated trajectory to be deformed, which is not conducive to the execution of the UAV. SUMMARY

[0005] Embodiments of the present application provide a motion planning method, device, equipment and medium for a UAV to improve the time allocation accuracy of each path segment, thereby improving the smoothness and continuity of the motion trajectory obtained by optimization, and ensuring the stability of UAV flight.

[0006] In a first aspect, embodiments of the present application provide a motion planning method for a UAV, comprising:

[0007] obtaining a grid map of a region to be planned, a set of obstacles, and a starting position and a target position of the UAV;

[0008] According to the starting position, the target position and the set of obstacles, a path point set is generated in the grid map using a path search algorithm;

[0009] According to the path point set, a plurality of path segments are obtained; each path segment includes any two adjacent path points in the path point set;

[0010] For each path segment, a gradient velocity curve planning algorithm is used to determine the time allocation of each path segment according to a preset maximum acceleration of the UAV and a preset maximum speed;

[0011] Based on the time allocation of each path segment, a motion trajectory of the UAV is generated by a trajectory optimization algorithm.

[0012] In one possible implementation, generating a set of path points in the grid map using a path search algorithm based on the starting position, the target position, and the set of obstacles includes:

[0013] Based on the starting position, the target position, and the set of obstacles, a jump point sequence is generated in the grid map using the JPS jump point search algorithm;

[0014] The Bresenham line algorithm is used to detect whether there is an obstacle between the first jump point and the second jump point corresponding to the first jump point; the first jump point is the first jump point in the jump point sequence; the second jump point corresponding to the first jump point is the next jump point after the first jump point.

[0015] If there are no obstacles, continue to check if there are obstacles between the first jump point and the next jump point corresponding to the second jump point. If there are no obstacles, delete the second jump point, record the next jump point corresponding to the second jump point as the new second jump point, and continue to check if there are obstacles between the first jump point and the new second jump point until there are obstacles between the first jump point and the new second jump point. Then, the new second jump point is used as the new first jump point.

[0016] Continue to detect whether there is an obstacle between the new first jump point and the second jump point corresponding to the new first jump point, until the last jump point in the sequence is traversed; the second jump point corresponding to the new first jump point is the next jump point of the new first jump point;

[0017] The retained jump points are determined as path points, thus obtaining the path point set.

[0018] In one possible implementation, obtaining multiple path segments based on the set of path points includes:

[0019] A path segment is defined as a road segment formed by any two adjacent path points in the set of path points.

[0020] In one possible implementation, before generating the UAV's motion trajectory using a trajectory optimization algorithm based on the time allocation for each path segment, the method further includes:

[0021] For each path segment, based on the set of obstacles, an ellipsoid is fitted to the path segment to generate a local safe area that includes the path segment but does not contain obstacles.

[0022] Based on the set of obstacles, the convex polyhedron corresponding to the path segment is obtained through half-space intersection calculation;

[0023] Intersection operations are performed on adjacent convex polyhedra to generate continuous safe corridors.

[0024] In one possible implementation, obtaining the convex polyhedron corresponding to the path segment based on the obstacle set through half-space intersection calculation includes:

[0025] Based on the preset bounding box of the path segment, the obstacles within the bounding box are obtained, resulting in a set of sub-obstacles;

[0026] Based on the set of sub-obstacles, the convex polyhedron corresponding to the path segment is obtained through half-space intersection calculation.

[0027] In one possible implementation, generating the UAV's motion trajectory using a trajectory optimization algorithm based on the time allocation results for each path segment includes:

[0028] Based on the geometric constraints of the safety corridor, the time constraints of the time allocation for each path segment, and the physical performance constraints of the UAV, a trajectory optimization algorithm is used to generate the motion trajectory of the UAV.

[0029] In one possible implementation, generating the motion trajectory of the UAV using a trajectory optimization algorithm includes:

[0030] For each path segment, the Bézier curve optimization method is used, with multiple initial control points between two path points in the path segment;

[0031] Based on the geometric constraints of the safety corridor, the time constraints of the time allocation of the path segment, and the physical performance constraints of the UAV, the initial control point is adjusted to obtain multiple optimal control points.

[0032] Substituting the multiple optimal control points into the Bézier curve equation, we obtain the piecewise curve corresponding to the path segment;

[0033] The motion trajectory of the UAV is obtained by splicing the segmented curves corresponding to different path segments in the order of the path segments.

[0034] Secondly, embodiments of this application provide a motion planning device for an unmanned aerial vehicle (UAV), comprising:

[0035] The first acquisition module is used to acquire the grid map of the area to be planned, the set of obstacles, and the starting and target positions of the drone;

[0036] The first generation module is used to generate a set of path points in the grid map based on the starting position, the target position, and the set of obstacles, using a path search algorithm.

[0037] The second acquisition module is used to acquire multiple path segments based on the set of path points; each path segment includes any two adjacent path points in the set of path points.

[0038] The determination module is used to determine the time allocation for each path segment based on the preset maximum acceleration and preset maximum speed of the UAV, using a gradient velocity curve planning algorithm.

[0039] The optimization module is used to generate the motion trajectory of the UAV based on the time allocation of each path segment using a trajectory optimization algorithm.

[0040] In one possible implementation, the first generation module is specifically used for:

[0041] Based on the starting position, the target position, and the set of obstacles, a jump point sequence is generated in the grid map using the JPS jump point search algorithm;

[0042] The Bresenham line algorithm is used to detect whether there is an obstacle between the first jump point and the second jump point corresponding to the first jump point; the first jump point is the first jump point in the jump point sequence; the second jump point corresponding to the first jump point is the next jump point after the first jump point.

[0043] If there are no obstacles, continue to check if there are obstacles between the first jump point and the next jump point corresponding to the second jump point. If there are no obstacles, delete the second jump point, record the next jump point corresponding to the second jump point as the new second jump point, and continue to check if there are obstacles between the first jump point and the new second jump point until there are obstacles between the first jump point and the new second jump point. Then, the new second jump point is used as the new first jump point.

[0044] Continue to detect whether there is an obstacle between the new first jump point and the second jump point corresponding to the new first jump point, until the last jump point in the sequence is traversed; the second jump point corresponding to the new first jump point is the next jump point of the new first jump point;

[0045] The retained jump points are determined as path points, thus obtaining the path point set.

[0046] In one possible implementation, the second acquisition module is specifically used for:

[0047] A path segment is defined as a road segment formed by any two adjacent path points in the set of path points.

[0048] In one possible implementation, the apparatus further includes a second generation module, comprising:

[0049] The first generation unit is used to perform ellipsoid fitting on the path segment based on the set of obstacles for each path segment, and generate a local safe area that includes the path segment but does not contain obstacles.

[0050] The calculation unit is used to obtain the convex polyhedron corresponding to the path segment based on the set of obstacles through half-space intersection calculation;

[0051] The second generation unit is used to perform intersection operations on adjacent convex polyhedra to generate continuous safety corridors.

[0052] In one possible implementation, the computing unit is specifically used for:

[0053] Based on the preset bounding box of the path segment, the obstacles within the bounding box are obtained, resulting in a set of sub-obstacles;

[0054] Based on the set of sub-obstacles, the convex polyhedron corresponding to the path segment is obtained through half-space intersection calculation.

[0055] In one possible implementation, the optimization module is specifically used for:

[0056] Based on the geometric constraints of the safety corridor, the time constraints of the time allocation for each path segment, and the physical performance constraints of the UAV, a trajectory optimization algorithm is used to generate the motion trajectory of the UAV.

[0057] In one possible implementation, the optimization module is specifically used for:

[0058] For each path segment, the Bézier curve optimization method is used, with multiple initial control points between two path points in the path segment;

[0059] Based on the geometric constraints of the safety corridor, the time constraints of the time allocation of the path segment, and the physical performance constraints of the UAV, the initial control point is adjusted to obtain multiple optimal control points.

[0060] Substituting the multiple optimal control points into the Bézier curve equation, we obtain the piecewise curve corresponding to the path segment;

[0061] The motion trajectory of the UAV is obtained by splicing the segmented curves corresponding to different path segments in the order of the path segments.

[0062] Thirdly, embodiments of this application provide a drone device, including: a memory and a processor;

[0063] The memory stores computer-executed instructions;

[0064] The processor executes computer execution instructions stored in the memory, causing the processor to perform the first aspect and / or various possible implementations of the first aspect as described above.

[0065] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the first aspect and / or various possible implementations of the first aspect.

[0066] Fifthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the first aspect and / or various possible implementations of the first aspect.

[0067] The motion planning method, apparatus, device, and medium for unmanned aerial vehicles (UAVs) provided in this application embodiment acquire a grid map of the area to be planned, a set of obstacles, and the starting and target positions of the UAV. Based on the starting position, the target position, and the set of obstacles, a path point set is generated in the grid map using a path search algorithm. Multiple path segments are obtained based on the path point set; each path segment includes any two adjacent path points from the path point set. For each path segment, a gradient velocity curve planning algorithm is used to determine the time allocation for each path segment based on a preset maximum acceleration and a preset maximum velocity of the UAV. Based on the time allocation for each path segment, a trajectory optimization algorithm is used to generate the motion trajectory of the UAV. This improves the accuracy of the time allocation for each path segment, thereby enhancing the smoothness and continuity of the optimized motion trajectory and ensuring the flight stability of the UAV. Attached Figure Description

[0068] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0069] Figure 1 A flowchart illustrating the motion planning method for an unmanned aerial vehicle (UAV) provided in Embodiment 1 of this application;

[0070] Figure 2 This is a flowchart illustrating a specific motion planning method for an unmanned aerial vehicle (UAV) provided in Embodiment 2 of this application.

[0071] Figure 3 A schematic diagram illustrating the principle of the Bresenham algorithm provided in this application;

[0072] Figure 4 A schematic diagram illustrating the framework of a specific motion planning method for an unmanned aerial vehicle (UAV) provided in this application;

[0073] Figure 5 This is a schematic diagram of the structure of a motion planning device for an unmanned aerial vehicle (UAV) provided in Embodiment 3 of this application;

[0074] Figure 6 This is a schematic diagram of the structure of a motion planning device for an unmanned aerial vehicle (UAV) provided in Embodiment 4 of this application;

[0075] Figure 7 A schematic diagram of the structure of the unmanned aerial vehicle (UAV) equipment provided in this application.

[0076] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0077] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0078] It should be noted that the method provided in this solution can be integrated into the embedded control system of the UAV, or it can be executed in computer equipment to provide the UAV with a smooth and reasonable flight path.

[0079] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0080] Figure 1 This is a flowchart illustrating the motion planning method for an unmanned aerial vehicle (UAV) provided in Embodiment 1 of this application, as shown below. Figure 1 As shown, the method provided in this embodiment includes:

[0081] S101. Obtain the grid map of the area to be planned, the obstacle set, and the starting and target positions of the drone.

[0082] The area to be planned refers to the area where drone movement planning is required, such as the area for power facility inspection.

[0083] The starting position of the drone refers to the starting point of the drone's flight, and the target position of the drone refers to the destination planned for this flight. The grid map refers to the discretization of a continuous physical space into multiple grids of fixed size. The obstacle set refers to the obstacles included in the area to be planned, used to indicate the position of each obstacle in the grid map.

[0084] In practical applications, sensors such as LiDAR installed on the drone typically scan and obtain a grid map of the area to be planned, as well as a set of obstacles. The drone's starting and target positions can be obtained manually by the user.

[0085] S102. Based on the starting position, target position, and obstacle set, a path search algorithm is used to generate a set of path points in the grid map.

[0086] In this step, starting from the initial position, a path search algorithm is used to search for nodes in the grid map, gradually finding multiple path points that do not pass through any obstacles and whose destination is the target position, and then obtaining the path point combination.

[0087] S103. Obtain multiple path segments based on the set of path points.

[0088] Each path segment includes any two adjacent path points from the set of path points.

[0089] In this step, two consecutive path points and the line connecting the trajectory points are defined as a path segment.

[0090] S104. For each path segment, based on the preset maximum acceleration and maximum speed of the UAV, a gradient velocity curve planning algorithm is used to determine the time allocation for each path segment.

[0091] The maximum acceleration and preset maximum speed of the drone are set according to the drone's physical performance, and may be slightly lower than the drone's hardware limits.

[0092] It should be understood that a trapezoidal velocity curve can be designed based on the drone's maximum acceleration and preset maximum speed. The displacement of the path segment can be obtained by integrating the trapezoidal velocity curve over time. Therefore, given the straight-line distance between two path points, the optimal time allocation for the drone on that path segment can be deduced from the trapezoidal velocity curve.

[0093] Specifically, the velocity curve for this body type consists of three parts:

[0094] The first part is the uniform acceleration stage: the acceleration is constant, the velocity is a linear function of time, and the displacement is a parabolic function of time; the second part is the uniform velocity stage: the acceleration is 0, the velocity is constant, and the displacement is a linear function of time; the third part is the deceleration stage: the acceleration is a constant negative value, the velocity decreases linearly, and the displacement is a quadratic polynomial of time.

[0095] Specifically, the displacement calculation formulas for each stage within the motion time range [0, T] are as follows:

[0096] During the uniform acceleration phase: ;

[0097] During the uniform velocity phase: ;

[0098] During the uniform deceleration phase: ;

[0099] Accordingly, the straight-line distance of the i-th path segment is known to be... Then, the time allocation T for the shortest path i is... i for:

[0100]

[0101] Among them, V m Indicates the maximum speed of the drone; acc m X represents the maximum acceleration of the drone; i This represents the straight-line distance between two path points within a path segment.

[0102] Furthermore, it should be understood that the trapezoidal velocity curve follows the motion rule of continuous and gradual change of velocity with path characteristics. Combined with the dynamic limits of the UAV hardware, the optimal motion time allocation for this segment can be determined to meet the requirements of speed and rationality of the planned motion.

[0103] S105. Based on the time allocation of each path segment, the motion trajectory of the UAV is generated through a trajectory optimization algorithm.

[0104] In this step, based on the time constraints of the time allocation for each path segment, the trajectory optimization algorithm is used to generate the UAV's motion trajectory, so that the trajectory corresponding to each path segment can be completed within the corresponding time allocation when the UAV executes the motion trajectory.

[0105] The trajectory optimization algorithm may be, for example, a B-spline curve optimization algorithm or a polynomial trajectory optimization algorithm, and this application does not impose specific restrictions on it.

[0106] The motion planning method for unmanned aerial vehicles (UAVs) provided in this application involves acquiring a grid map of the area to be planned, a set of obstacles, and the UAV's starting and target positions. Based on the starting position, target position, and obstacle set, a path point set is generated in the grid map using a path search algorithm. Multiple path segments are obtained from the path point set; each path segment includes any two adjacent path points from the path point set. For each path segment, a gradient velocity curve planning algorithm is used to determine the time allocation for each path segment based on a preset maximum acceleration and a preset maximum velocity of the UAV. Based on the time allocation for each path segment, a trajectory optimization algorithm is used to generate the UAV's motion trajectory. This method improves the accuracy of the time allocation for each path segment, thereby enhancing the smoothness and continuity of the optimized motion trajectory, reducing the risk of aircraft vibration, and ensuring the flight stability of the UAV.

[0107] Figure 2 This is a flowchart illustrating a specific motion planning method for a UAV provided in Embodiment 2 of this application. Based on the above embodiments, this embodiment provides a detailed description of the implementation of the above embodiments, including:

[0108] S201. Obtain the grid map of the area to be planned, the obstacle set, and the starting and target positions of the drone.

[0109] S202. Based on the starting position, target position, and obstacle set, a path search algorithm is used to generate a set of path points in the grid map.

[0110] Specifically, step S202 includes the following steps 2.1 to 2.2:

[0111] Step 2.1: Based on the starting position, target position, and obstacle set, generate a jump point sequence in the grid map using the JPS jump point search algorithm.

[0112] Specifically, the JPS jump point search algorithm is a pathfinding algorithm designed for equidistant grids. It mainly includes two steps: First, expansion. In the grid map, starting from the starting point (i.e., the initial position), the heuristic evaluation value of all neighboring nodes of the node is calculated, and the neighboring nodes are added to a list. Then, optimization. The node with the smallest heuristic evaluation value is selected from the list for the next round of expansion. By continuously repeating the two steps of expansion and optimization, the optimal path from the starting point to the destination can be found.

[0113] It should be understood that the JPS jump point search algorithm finds the critical jump points in the path. Only these jump points are evaluated and selected, while redundant nodes between jump points are filtered out. This significantly reduces the number of nodes that need to be evaluated and selected, greatly improving the algorithm's efficiency. Furthermore, the JPS jump point search algorithm uses neighbor pruning to avoid adjacent parent-child nodes processing common neighbors, thus preventing the generation of multiple equivalent paths.

[0114] Step 2.2: Use the Bresenham line algorithm to detect whether there is an obstacle between the first jump point and the second jump point corresponding to the first jump point; the first jump point is the first jump point in the jump point sequence; the second jump point corresponding to the first jump point is the next jump point after the first jump point.

[0115] Step 2.3: If there are no obstacles, continue to check whether there are obstacles between the first jump point and the next jump point corresponding to the second jump point. If there are no obstacles, delete the second jump point, record the next jump point corresponding to the second jump point as the new second jump point, and continue to check whether there are obstacles between the first jump point and the new second jump point until there are obstacles between the first jump point and the new second jump point. Then, use the new second jump point as the new first jump point.

[0116] Step 2.4: Continue to check whether there is an obstacle between the new first jump point and the second jump point corresponding to the new first jump point, until the last jump point in the sequence is traversed; the second jump point corresponding to the new first jump point is the next jump point of the new first jump point.

[0117] In steps 2.1 to 2.4 above, the Bresenham line algorithm is used to detect collisions between two jump points. Based on the idea that if there are no obstacles between the current node's parent node (i.e., the node preceding the current node) and its neighboring node (the node following the current node), the current node is discarded, and redundant nodes are eliminated by directly connecting the current node's parent node and this neighboring node.

[0118] Specifically, the Bresenham line algorithm is used for collision detection between two jump points, including: first, determining the grid coordinates of the two jump points in the grid map; then, the Bresenham line algorithm generates grid cells that are closest to the line point by point by tracking the deviation (i.e., error term) between the ideal line (i.e., the line connecting the two jump points) and the actual grid, thus obtaining a grid sequence; for each grid cell in the generated grid sequence, its status in the grid map is checked (i.e., whether there is an obstacle at the grid location).

[0119] The process of obtaining the grid sequence based on the error term includes:

[0120] Starting from the starting point (i.e., the jump point closer to the starting position among the two jump points), the next step is determined sequentially by deciding whether to move in the x-direction or the y-direction. The error term is obtained by calculating the intersection of the ideal straight line and the grid perpendicular line, as well as the distance from the grid point to the intersection point. Then, based on the sign of the error term, the grid closest to the intersection point is determined and used as a grid representing the straight line. Specifically, in the process of iteratively determining the grid sequence based on the error term, when the absolute value of the slope of the ideal straight line is less than 1, it iterates along the x-axis direction, and when the absolute value is greater than 1, it iterates along the y-axis direction.

[0121] It should be understood that the algorithm steps for iterating along the x-axis and iterating along the y-axis differ only in notation. Here, we will take iterating along the x-axis as an example for analysis:

[0122] Figure 3 The schematic diagram of the Bresenham algorithm provided in this application is as follows: Figure 3 As shown, the coordinates of the starting point (i.e., the jump point closer to the starting position among the two jump points) are set to... The coordinates of the endpoint (the jump point farther from the starting position) are: The equation of the ideal straight line is The slope calculation formula is: .

[0123] Let the current grid map coordinates be The next grid map coordinates are at and Choose between them. First, calculate the coordinates of the intersection point. The calculation formula is:

[0124]

[0125] Then, calculate the distance error terms between the two candidate points and the intersection point respectively. and for:

[0126]

[0127]

[0128] By comparison and The size of the error term is used to include the grid corresponding to the smaller error term in the grid.

[0129] It should be understood that the path obtained based on the Bresenham straight line algorithm is straighter and more direct, avoiding the accumulation of multiple path points that would affect subsequent data processing.

[0130] Step 2.5: Determine the retained jump points as path points to obtain the path point set.

[0131] In this step, all the retained jump points together constitute the path point set.

[0132] The methods provided in steps 2.1 to 2.5 of this implementation, after planning a feasible path using JPS, use the Bresenham line algorithm for collision detection. By using the JPS-Bresenham line algorithm to reduce redundant nodes in the path, delete redundant nodes, and retain only key nodes, the path search efficiency is improved, and the burden on backend optimization is reduced.

[0133] Optionally, a hybrid path search strategy can be introduced during the path search phase, combining the advantages of JPS jump point search and the Rapidly-exploring Random Tree (RRT) algorithm. For example, in complex environments, a global path can be generated first using RRT, then JPS jump point search can be used to eliminate local redundancy in the path, while the Bresenham algorithm can be used to further simplify the distribution of path points.

[0134] It should be understood that this technique balances global search capability with local optimization efficiency through a hybrid path search strategy. For example, in complex dynamic obstacle scenarios, RRT can quickly generate feasible paths, while the combination of JPS jump point search and the Bresenham algorithm can significantly reduce redundant nodes in the path; in scenarios with known static obstacles, the hybrid strategy can avoid the sampling redundancy problem of RRT and improve path search efficiency. This multi-stage redundancy elimination mechanism achieves more efficient path generation in complex environments.

[0135] S203. Determine a path segment as any two adjacent path points in the path point set.

[0136] S204: For each path segment, based on the preset maximum acceleration and maximum speed of the UAV, a gradient velocity curve planning algorithm is used to determine the time allocation for each path segment.

[0137] S205. For each path segment, based on the obstacle set, perform ellipsoid fitting on the path segment to generate a local safe area that includes the path segment but does not contain any obstacles.

[0138] The methods in steps S205 to S207 of this scheme are used to construct safe corridors for each path segment so that the generated motion trajectory is within the safe driving range, thereby avoiding collisions between the drone and obstacles.

[0139] Specifically, let the set of obstacles in free space be denoted as . The piecewise linear path P from the drone's starting position to the target position is represented as: ,in It is a point in free space. It is a directed line segment (i.e., a path segment) in free space.

[0140] First, for each line segment L, find an ellipsoid that contains the line segment. Furthermore, the ellipsoid does not contain a set of obstacles. The points in the ellipsoid. The ellipsoid is represented as:

[0141]

[0142] It is A symmetric positive definite matrix, representing a sphere ( () is a variation of. ,in It is the rotation matrix from the map coordinate system to the elliptical coordinate system, a diagonal matrix. The diagonal elements represent the corresponding lengths of the semi-axis of the ellipsoid. , This represents the center of the ellipsoid. Then, based on the given line segment... and obstacle set Obtain the symmetric positive definite matrix and the center of the ellipsoid .

[0143] The calculation of the ellipsoid involves two steps: the first step is to form a sphere with a radius equal to half the path length, a center at the midpoint of the path, and a fixed x-axis. Align the ellipsoid. Then find the obstacle closest to the center within the ellipsoid, shrink the y-axis, and repeat this process until the ellipsoid contains no obstacles. The second step is to stretch the z-axis of the ellipsoid to obtain the largest possible ellipsoid. The obstacle point that contacts the largest ellipsoid is denoted as... .

[0144] S206. Based on the set of obstacles, the convex polyhedron corresponding to the path segment is obtained through half-space intersection calculation.

[0145] In this step, we will continue to construct the convex polyhedron corresponding to the path segment based on the obstacle set and through half-space intersection calculation.

[0146] Specifically, this step requires generating a convex polyhedron around each line segment in P. The i-th line segment is represented as... each The generated convex polyhedron is represented as The set of convex polyhedra is represented as:

[0147]

[0148] Specific generation methods include:

[0149] For each line segment (i.e., path segment), the corresponding ellipsoid is represented as: The point of contact between the ellipsoid and the obstacle At this point, a half-plane tangent to the ellipsoid is formed using this point as the tangent point, creating a half-space containing the ellipsoid. ,in, and Two key parameters used to define the half-space, after calculation Then, gather the obstacles. All obstacles outside the middle half-space are removed, and then the ellipsoid is expanded until it touches another obstacle. To form a new ellipsoid This forms a new half-plane and creates a new half-space. Continue this process until the obstacle set is complete. When completely removed, a half-space set is obtained. ,this The intersection of the two half-spaces forms a convex polyhedron, represented as:

[0150]

[0151] in, b is the matrix used to define the convex polyhedron; b is the vector used to define the convex polyhedron.

[0152] In each iteration, due to the j-th half-space With ellipsoid Tangent and point From this, the key parameters of the j-th half-space can be calculated. and :

[0153]

[0154]

[0155] in, It is a matrix The element in the j-th column, It is a vector The j-th element in.

[0156] Furthermore, in one possible implementation, this step can be achieved using steps 6.1 to 6.2 as follows:

[0157] Step 6.1: Based on the preset bounding box of the path segment, obtain the obstacles within the bounding box to obtain a set of sub-obstacles.

[0158] The size of the preset bounding box can be set according to the geometric characteristics of the path segment (such as length) and the distribution density of obstacles, and this application does not impose any restrictions on it.

[0159] In this step, obstacles located within the bounding box need to be included in the sub-obstacle set for half-space intersection calculation.

[0160] Step 6.2: Based on the set of sub-obstacles, obtain the convex polyhedron corresponding to the path segment through half-space intersection calculation.

[0161] In this step, based on the obstacles in the sub-obstacle set, the same convex polyhedron construction method as described above will be used to obtain the convex polyhedron corresponding to each path segment.

[0162] It should be understood that constructing a polyhedron for each line segment requires searching all points in the obstacle set "O" at least twice to check the intersections of obstacles with the inflated ellipsoid, which is computationally very resource-intensive. Therefore, this implementation reduces the number of obstacle points to be checked by adding a bounding box to each path segment. Each time the inflated ellipsoid intersects an obstacle, only the obstacle points within the bounding box need to be checked. This not only reduces the number of obstacle points to be checked and improves algorithm efficiency, but also avoids the effect of the inflated ellipsoid moving too far away from the line segment, causing the trajectory to deviate too far from the original path.

[0163] S207. Perform an intersection operation on adjacent convex polyhedra to generate a continuous safe corridor.

[0164] In this step, two consecutive polyhedra should be controlled. and Need to include The non-empty subsets intersect to generate continuous safe corridors, thereby ensuring the continuity of the trajectory.

[0165] Specifically, the obtained continuous safety corridors can be represented as: .

[0166] It should be understood that the method provided in steps S205 to S07 of this embodiment constructs a safe flight corridor by expanding an ellipsoid and intersecting a convex polyhedron, providing geometric constraints for the subsequent path optimization process to ensure trajectory safety.

[0167] S208. Based on the time allocation of each path segment, the motion trajectory of the UAV is generated through a trajectory optimization algorithm.

[0168] Specifically, this includes: generating the drone's motion trajectory through trajectory optimization algorithms based on geometric constraints of the safety corridor, time constraints of time allocation for each path segment, and physical performance constraints of the drone.

[0169] It should be understood that the geometric constraints based on the safety corridor are used to ensure that the generated motion trajectory falls entirely within the safe range, so as to ensure that the UAV does not touch obstacles. At the same time, the time constraints based on the time allocation of each path segment are used to ensure that the UAV completes the corresponding path segment within the allocated time, ensuring that the flight rhythm of each path segment matches the overall mission time plan, thereby meeting the overall timeliness requirements of the flight mission. The constraints based on the physical performance of the UAV are used to ensure that the dynamic indicators such as speed, acceleration, and jerk corresponding to the generated motion trajectory are always within the limits of the UAV's hardware performance, avoiding flight loss of control, fuselage shaking, or damage to onboard equipment due to the exceeding of power parameters.

[0170] In one possible implementation, steps 8.1 to 8.4 can be used:

[0171] Step 8.1: For each path segment, use the Bézier curve optimization method to establish multiple initial control points between two path points in the path segment.

[0172] In this step, the number of initial control points will be determined based on the pre-selected order of the Bézier curve, and for each path segment, a corresponding number of initial control points will be randomly generated between two points in that path segment.

[0173] Step 8.2: Based on the geometric constraints of the safe corridor, the time constraints of the time allocation of the path segment, and the physical performance constraints of the UAV, the initial control points are adjusted to obtain multiple optimal control points.

[0174] Physical performance constraints refer to constraints determined based on the hardware performance of the UAV, such as the UAV's maximum acceleration, maximum speed, jerk limits, and (shock) limits.

[0175] It should be understood that, due to the convex hull property of Bézier curves, as long as the control points of the Bézier curve are restricted to the safe flight corridor, the corresponding generated Bézier curve will also be within the safe flight corridor. Due to the Hodograph property of the Bézier curve optimization method, the high-order physical constraints of the UAV can be easily converted into mathematical constraints on the control points to achieve the matching of trajectory and physical characteristics. Since the time allocation of the path segment requires the trajectory to complete the movement within a preset time, and the parameters of the Bézier curve are dimensionless normalized parameters, it is necessary to convert the actual time constraints into parameterized constraints of the control points through time normalization to achieve accurate matching between trajectory and time allocation.

[0176] Step 8.3: Substitute multiple optimal control points into the Bézier curve equation to obtain the piecewise curve corresponding to the path segment.

[0177] Specifically, a Bézier curve is defined by a set of control points, and the equation of an nth-order Bézier curve is:

[0178]

[0179]

[0180] in This represents the Bézier curve expression corresponding to the j-th path segment. These are Bernstein basis functions, where n is the order of the polynomial. This represents the coefficient of the i-th basis function corresponding to the j-th trajectory segment, i.e., the control point. Furthermore, a Bézier curve is a special polynomial that can be mapped to an ordinary polynomial in a certain way.

[0181] In this step, by substituting multiple optimal control points into the Bézier curve equation, the piecewise curve corresponding to the path segment can be obtained.

[0182] Step 8.4: Piece together the segmented curves corresponding to different path segments in the order of the path segments to obtain the movement trajectory of the UAV.

[0183] In practical applications, it is necessary to splice the segmented curves corresponding to different path segments in the order of the path segments, and it is required that the two motion trajectories be directly connected at the splicing position, so as to obtain a smooth motion trajectory of the UAV.

[0184] It should be understood that traditional piecewise polynomial trajectory optimization methods, due to the inconvenience of adding global safety and dynamic feasibility constraints, can only apply constraints to a few points on the trajectory. After calculating the trajectory, the extreme values ​​of the trajectory are solved, and multiple iterations are needed to determine whether safety and dynamic feasibility constraints are violated to find a suitable trajectory or detect infeasibility. This results in slow optimization speed, which is undoubtedly unreliable for UAVs with high real-time requirements. The method provided in this implementation uses Bézier curves for curve optimization, which only requires applying the corresponding safety and dynamic feasibility constraints to the control points. This effectively reduces the algorithm complexity and thus significantly improves the real-time performance of path planning.

[0185] The UAV motion planning method provided in this application addresses the problem of redundant nodes in traditional algorithms by combining the JPS jump point search algorithm and the Bresenham line detection algorithm, significantly reducing the computational load of subsequent processes such as safe corridor construction, time allocation calculation, and path optimization. Simultaneously, this scheme constructs a continuous safe flight corridor based on the intersection of ellipsoidal expansion and convex polyhedrons, ensuring the trajectory always remains within the safe area and improving the safety of the generated trajectory. Furthermore, a bounding box mechanism is used to reduce the obstacle detection range, improving computational efficiency. Regarding dynamic feasibility, this embodiment also employs a Bézier curve optimization method, utilizing its convex hull and Hodograph properties to directly apply high-order constraints such as velocity, acceleration, and geometric position, ensuring a smooth trajectory that meets the UAV's dynamic requirements. In summary, to reduce computational resource consumption, this scheme decomposes motion planning into four stages: path search, safe corridor construction, time allocation calculation, and trajectory optimization. It reduces overall complexity through localization (such as the bounding box mechanism) and parameterization methods (such as Bézier curves), meeting real-time requirements.

[0186] Figure 4 A schematic diagram illustrating the framework of a specific motion planning method for a UAV provided in this application is shown below. Figure 4 As shown, the architecture includes: front-end map building and JPS-Bresenham-based path search, safe corridor construction and time allocation, and back-end trajectory optimization based on Bézier curves. Specifically, the front-end first constructs a complex real-world environment, then performs path search based on a grid map, searching for a collision-free path given the UAV's starting and target positions; convex space construction refers to constructing convex safe corridors using path points generated by the front-end, where adjacent safe corridors need to overlap to increase the degrees of freedom in the solution space, and then selecting an appropriate method to allocate appropriate time for each path segment; the back-end utilizes the convex characteristics of the safe corridors, using Bézier curves to parameterize the time of each trajectory to ensure that the trajectory is completely confined within the safe flight corridor.

[0187] Based on the above-mentioned methodological architecture, it is possible to ensure that the UAV can quickly complete motion planning in obstacle environments, meeting the requirements of real-time performance, rationality, safety, and efficiency in UAV motion planning.

[0188] Figure 5 This is a schematic diagram of the motion planning device for an unmanned aerial vehicle (UAV) provided in Embodiment 3 of this application. Figure 5 As shown, the motion planning device 30 for a drone provided in this embodiment includes:

[0189] The first acquisition module 301 is used to acquire the grid map of the area to be planned, the set of obstacles, and the starting position and target position of the UAV;

[0190] The first generation module 302 is used to generate a set of path points in the grid map based on the starting position, the target position, and the set of obstacles using a path search algorithm.

[0191] The second acquisition module 303 is used to acquire multiple path segments based on the path point set; each path segment includes any two adjacent path points in the path point set.

[0192] The determination module 304 is used to determine the time allocation for each path segment based on the preset maximum acceleration and preset maximum speed of the UAV, using a gradient velocity curve planning algorithm.

[0193] The optimization module 305 is used to generate the UAV's motion trajectory based on the time allocation of each path segment using a trajectory optimization algorithm.

[0194] The motion planning device 30 for the UAV provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described in detail here.

[0195] Figure 6 This is a schematic diagram of the structure of a motion planning device for an unmanned aerial vehicle (UAV) provided in Embodiment 4 of this application, as shown below. Figure 6 As shown, based on the above embodiments, the motion planning device 30 for the UAV provided in this embodiment further includes:

[0196] The second generation module 306 includes:

[0197] The first generation unit is used to perform ellipsoid fitting on the path segment based on the obstacle set for each path segment, and generate a local safe area that includes the path segment but does not contain obstacles.

[0198] The calculation unit is used to obtain the convex polyhedron corresponding to the path segment by calculating the intersection of the half-space based on the obstacle set;

[0199] The second generation unit is used to perform intersection operations on adjacent convex polyhedra to generate continuous safety corridors.

[0200] In one possible implementation, the first generation module 302 is specifically used for:

[0201] Based on the starting position, target position, and obstacle set, a jump point sequence is generated in the grid map using the JPS jump point search algorithm;

[0202] The Bresenham line algorithm is used to detect whether there is an obstacle between the first jump point and the second jump point corresponding to the first jump point; the first jump point is the first jump point in the jump point sequence; the second jump point corresponding to the first jump point is the next jump point after the first jump point;

[0203] If there are no obstacles, continue to check if there are obstacles between the first jump point and the next jump point corresponding to the second jump point. If there are no obstacles, delete the second jump point, record the next jump point corresponding to the second jump point as the new second jump point, and continue to check if there are obstacles between the first jump point and the new second jump point until there are obstacles between the first jump point and the new second jump point. Then, the new second jump point is used as the new first jump point.

[0204] Continue checking whether there is an obstacle between the new first jump point and the corresponding second jump point, until the last jump point in the sequence is traversed; the second jump point corresponding to the new first jump point is the next jump point of the new first jump point.

[0205] The retained jump points are identified as path points, resulting in a set of path points.

[0206] In one possible implementation, the second acquisition module 303 is specifically used for:

[0207] A path segment is defined as a road segment formed by any two adjacent path points in the path point set.

[0208] In one possible implementation, the computing unit is specifically used for:

[0209] Based on the predefined bounding box of the path segment, obtain the obstacles within the bounding box and obtain a set of sub-obstacles;

[0210] Based on the set of sub-obstacles, the convex polyhedron corresponding to the path segment is obtained by calculating the intersection of the half-space.

[0211] In one possible implementation, the optimization module 305 is specifically used for:

[0212] Based on the geometric constraints of the safety corridor, the time constraints of the time allocation for each path segment, and the physical performance constraints of the UAV, a trajectory optimization algorithm is used to generate the motion trajectory of the UAV.

[0213] In one possible implementation, the optimization module 305 is specifically used for:

[0214] For each path segment, the Bézier curve optimization method is used, with multiple initial control points between two path points in the path segment;

[0215] Based on the geometric constraints of the safe corridor, the time constraints of the time allocation of the path segment, and the physical performance constraints of the UAV, the initial control point is adjusted to obtain multiple optimal control points.

[0216] Substituting multiple optimal control points into the Bézier curve equation yields the piecewise curves corresponding to the path segments;

[0217] By splicing together the segmented curves corresponding to different path segments in the order of the path segments, the motion trajectory of the drone is obtained.

[0218] The motion planning device 30 for the UAV provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described in detail here.

[0219] Figure 7 A schematic diagram of the structure of the unmanned aerial vehicle (UAV) equipment provided in this application. Figure 5 As shown, the unmanned aerial vehicle (UAV) device 40 provided in this embodiment includes at least one processor 401 and a memory 402. Optionally, the device 40 further includes a communication component 403. The processor 401, memory 402, and communication component 403 are connected via a bus 404.

[0220] In a specific implementation, at least one processor 401 executes computer execution instructions stored in memory 402, causing at least one processor 401 to perform the above-described method.

[0221] The specific implementation process of processor 401 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.

[0222] In the above embodiments, it should be understood that the processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this invention can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules within the processor.

[0223] The memory may include read-only memory and random access memory. The memory may be volatile or non-volatile, or may include both. Non-volatile memory may include read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which serves as an external cache. Many forms of RAM are available by way of example, but not limitation. Examples include Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced Synchronous DRAM (ESDRAM), Sync Link DRAM (SLDRAM), and Direct Rambus RAM (DR RAM).

[0224] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.

[0225] This application also provides a computer program product, including a computer program that, when executed, implements the above-described method.

[0226] This application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the above-described method.

[0227] The aforementioned readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as SRAM, EEPROM, EPROM, PROM, ROM, magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.

[0228] An exemplary readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can reside within an ASIC. Alternatively, the processor and the readable storage medium can exist as discrete components in a device.

[0229] The division of units is merely a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.

[0230] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0231] In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0232] If a function is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.

[0233] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.

[0234] Finally, it should be noted that other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein, and is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.

Claims

1. A method for motion planning of a UAV, the method comprising: The method comprises the following steps: acquiring a grid map of a region to be planned, an obstacle set, and a starting position and a target position of a UAV; generating a path point set in the grid map according to the starting position, the target position, and the obstacle set by using a path search algorithm; acquiring a plurality of path segments according to the path point set; each path segment comprises any two adjacent path points in the path point set; for each path segment, determining a time allocation of each path segment by using a gradient velocity curve planning algorithm according to a preset maximum acceleration of the UAV and a preset maximum speed; generating a motion trajectory of the UAV by using a trajectory optimization algorithm based on the time allocation of each path segment.

2. The method of claim 1, wherein, The step of generating the path point set in the grid map according to the starting position, the target position, and the obstacle set by using the path search algorithm comprises the following steps: generating a jump point sequence in the grid map by using a JPS jump point search algorithm according to the starting position, the target position, and the obstacle set; detecting whether there is an obstacle between a first jump point and a second jump point corresponding to the first jump point by using a Bresenham straight line algorithm; the first jump point is a first jump point in the jump point sequence; the second jump point corresponding to the first jump point is a next jump point of the first jump point; if there is no obstacle, continuing to detect whether there is an obstacle between the first jump point and a next jump point corresponding to the second jump point, if there is no obstacle, deleting the second jump point, recording the next jump point corresponding to the second jump point as a new second jump point, and continuing to detect whether there is an obstacle between the first jump point and the new second jump point until there is an obstacle between the first jump point and the new second jump point, and taking the new second jump point as a new first jump point; continuing to detect whether there is an obstacle between the new first jump point and a second jump point corresponding to the new first jump point until a last jump point in the jump point sequence is traversed; the second jump point corresponding to the new first jump point is a next jump point of the new first jump point; determining the retained jump points as path points to obtain the path point set.

3. The method according to claim 1 or 2, characterized in that, The step of acquiring the plurality of path segments according to the path point set comprises the following step: determining a path segment formed by any two adjacent path points in the path point set as a path segment.

4. The method of claim 1, wherein, Before the step of generating the motion trajectory of the UAV by using the trajectory optimization algorithm based on the time allocation of each path segment, the method further comprises the following steps: for each path segment, performing ellipsoid fitting on the path segment based on the obstacle set to generate a local safety area containing the path segment and not containing the obstacle; based on the obstacle set, obtaining a convex polyhedron corresponding to the path segment by using half-space intersection calculation; performing intersection operation on adjacent convex polyhedrons to generate a continuous safety corridor.

5. The method of claim 4, wherein, The step of obtaining the convex polyhedron corresponding to the path segment based on the obstacle set by using the half-space intersection calculation comprises the following steps: acquiring obstacles in a bounding box preset for the path segment to obtain a sub-obstacle set; Based on the sub-obstacle set, a convex polyhedron corresponding to the path segment is obtained through a half-space intersection calculation.

6. The method according to claim 4 or 5, characterized in that, The time allocation result of each path segment is used to generate a motion trajectory of the UAV through a trajectory optimization algorithm, including: Based on the geometric constraint of the safety corridor, the time constraint of the time allocation of each path segment, and the physical performance constraint of the UAV, a trajectory optimization algorithm is used to generate the motion trajectory of the UAV.

7. The method of claim 6, wherein, The trajectory optimization algorithm used to generate the motion trajectory of the UAV includes: For each path segment, a Bezier curve optimization method is used to adjust a plurality of initial control points between the two path points of the path segment. Based on the geometric constraint of the safety corridor, the time constraint of the time allocation of the path segment, and the physical performance constraint of the UAV, the initial control points are adjusted to obtain a plurality of optimal control points. The plurality of optimal control points are brought into a Bezier curve equation to obtain a segmented curve corresponding to the path segment. The segmented curves corresponding to different path segments are spliced in the order of the path segments to obtain the motion trajectory of the UAV.

8. A motion planning device of a drone, characterized by, It includes: A first acquisition module is configured to acquire a grid map of a region to be planned, an obstacle set, and a starting position and a target position of a UAV. A generation module is configured to generate a path point set in the grid map using a path search algorithm according to the starting position, the target position, and the obstacle set. A second acquisition module is configured to acquire a plurality of path segments according to the path point set; each path segment includes any two adjacent path points in the path point set. A determination module is configured to determine the time allocation of each path segment using a gradient velocity curve planning algorithm according to a preset maximum acceleration of the UAV and a preset maximum speed for each path segment. An optimization module is configured to generate a motion trajectory of the UAV through a trajectory optimization algorithm based on the time allocation of each path segment.

9. A drone device, comprising: It includes: A memory and a processor; The memory stores computer execution instructions; The processor executes the computer execution instructions stored in the memory, so that the processor executes the method of any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer execution instructions, and the computer execution instructions are executed by the processor to implement the method of any one of claims 1-7.