Urban environment unmanned aerial vehicle intelligent obstacle avoidance method based on autonomous learning
By fusing data from visual sensors, millimeter-wave radar, and lidar, and using an improved RRT algorithm, the problems of lack of dynamic response in global planning and lack of global guidance in local planning for UAVs in urban environments have been solved, enabling UAVs to achieve efficient and stable obstacle avoidance in urban environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-26
- Publication Date
- 2026-03-27
AI Technical Summary
Existing drone obstacle avoidance technologies suffer from a lack of dynamic response capability in global planning and a lack of global guidance in local planning in urban environments, resulting in poor path quality, unstable decision-making, and difficulty in meeting real-time and safety requirements.
Data is collected simultaneously using visual sensors, millimeter-wave radar, and lidar to construct a 3D obstacle grid map. Combined with a hierarchical planning strategy and an improved Rapidly Expanding Random Tree (RRT) algorithm, real-time path planning is performed through guided sampling and multi-objective evaluation functions, enabling local planning to be guided by the global system and real-time correction of the global path.
It improves the obstacle avoidance performance of drones in urban environments, generates more reasonable, efficient and stable flight paths, ensures the real-time performance and safety of the paths, and enhances robustness and adaptability in complex environments.
Smart Images

Figure CN121742497A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of drone obstacle avoidance technology, and in particular to an intelligent obstacle avoidance method for drones in urban environments based on autonomous learning. Background Technology
[0002] With the rapid development of drone technology, drones are being used more and more widely in urban logistics, power line inspection, emergency rescue and other fields. However, the urban environment is characterized by dense high-rise buildings, complex airspace, and the random appearance of dynamic obstacles such as flocks of birds or other drones, which makes the congestion of urban airspace more and more obvious, and puts forward higher requirements for the autonomous obstacle avoidance capabilities of drones.
[0003] Currently, obstacle avoidance in drones often relies on a single sensor for environmental perception. Pure vision solutions are easily affected by lighting and weather, with significantly reduced perception capabilities at night or in rainy or foggy conditions. Millimeter-wave radar lacks sufficient resolution, making it difficult to identify small obstacles such as power lines. While lidar offers high accuracy, its high cost and computational power consumption limit its large-scale application. Static obstacle avoidance methods based on global planning depend on a high-precision prior 3D environment map (usually including building outlines), enabling the planning of a theoretically optimal or suboptimal path from the starting point to the destination during offline or initialization phases. However, this method cannot handle sudden obstacles in the environment that are not present in the prior map. The dynamic obstacle avoidance method, marked with symbols, involves computationally intensive and time-consuming global replanning, making it difficult to meet the real-time requirements of UAV flight. Local reaction-based dynamic obstacle avoidance methods rely solely on real-time perception data from onboard sensors, enabling rapid generation of local avoidance trajectories upon detecting obstacle threats, thus exhibiting strong real-time performance. However, due to the lack of a global perspective, it is prone to local optima, resulting in frequent path detours, severe jitter (i.e., "glitching"), and even deadlock (such as spinning within a U-shaped obstacle). The resulting paths are often redundant in length and lack smoothness, severely impacting mission efficiency and flight stability. Although some research has attempted to combine global and local planning to form a two-layer "global-local" architecture, these generally suffer from rigid integration and poor coordination. For example, the commonly used "track-switch-return" pattern tracks the global path normally, and immediately switches to a pure local reaction algorithm for obstacle avoidance once the sensor detects an obstacle. After obstacle avoidance, it attempts to return to the original global path. However, this approach suffers from decision oscillations, information fragmentation, and path degradation. Summary of the Invention
[0004] The purpose of this invention is to provide an intelligent obstacle avoidance method for urban UAVs based on autonomous learning. By deeply coordinating prior static knowledge and real-time dynamic perception, an adaptive fusion mechanism is designed that enables local planning to be guided by the global system and the global path to be corrected locally in real time. This solves the defects of existing technologies, such as the lack of dynamic response capability in global planning and the lack of global guidance in local planning, which leads to poor path quality and unstable decision-making, thereby improving the autonomous obstacle avoidance performance of urban UAVs.
[0005] To achieve the above objectives, this invention proposes an intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning, comprising the following steps: Step S1: Simultaneously collect urban environmental data using visual sensors, millimeter-wave radar, and lidar; preprocess and fuse the collected data to construct a three-dimensional obstacle grid map containing known static obstacles and initial environmental information. Step S2: Use a hierarchical planning strategy for flight path planning, including the following steps: Step S21: Under static conditions, based on The algorithm uses a grid map as the environment model, sets the starting point as the initial position of the UAV and the ending point as the position of the mission target, calculates the node cost through an evaluation function, and generates the globally optimal static flight path. Step S22: During flight, a dynamic safety space is defined around the current globally optimal static flight path. Multiple sensors continuously monitor the airspace. When a new obstacle is detected in the dynamic safety space, an improved Rapidly Expanding Random Tree (RRT) algorithm is used for real-time replanning to quickly generate a local obstacle avoidance path. This path replaces the corresponding segment in the current globally optimal static flight path, forming an updated globally optimal static flight path. The RRT algorithm improvement method is as follows: A guided sampling strategy is adopted to guide the random sampling points of the RRT towards the prospective point or the final target point of the globally optimal static flight path. Collision constraint detection is applied to the expansion of new nodes of the RRT random tree with obstacles in the 3D obstacle grid map. Step S3: Construct a multi-objective evaluation function that includes indicators such as path length, planning time, path smoothness, and safety margin, quantitatively evaluate the planning results, and dynamically adjust the path planning parameters based on the evaluation results.
[0006] Preferably, in step S1, the real-time sensor data comes from a fusion perception system of lidar and visual sensors.
[0007] Preferably, in step S21, the evaluation function formula is: ; in, f ( n ) is the current node n Total path costg ( n (This refers to the actual cost already incurred.) h ( n ) is a heuristic function, which is the estimated cost from the current node to the target node.
[0008] Preferably, in step S22, the dynamic safe space includes the estimation of the motion state of dynamic obstacles and short-term trajectory prediction. The minimum distance between the UAV and the obstacle is set as the safe space radius. When the distance between the UAV and the obstacle is greater than the safe space radius, it is determined to be safe.
[0009] Preferably, the safety space radius is not less than the distance threshold between the nodes of the random tree and the target point in the RRT algorithm.
[0010] Preferably, in step S22, the guided sampling strategy is implemented through a probability distribution, with a first probability selecting a forward point as a sampling point on the globally optimal static flight path, a second probability selecting the final target point as a sampling point, and a third probability randomly sampling in free space, wherein the first probability and the second probability are both greater than the third probability.
[0011] Preferably, in step S22, the collision constraint detection is a two-level detection: first, the new node is detected to have a conflict with the obstacles in the three-dimensional obstacle grid map. If there is a conflict, it is abandoned directly; if there is no conflict, the new node is detected to have a conflict with the newly added obstacles in the dynamic safe space.
[0012] Preferably, in step S3, the multi-objective evaluation function formula is: ; in, F For multi-objective evaluation functions, k 1 represents the path optimization weight. c For path optimization parameters, k 2 represents the path length weight. d This is the path length parameter. k 3 represents the path safety weight. s For path safety parameters, k 4 represents the planning error weight. e For planning error parameters, k 5 represents the time weight for planning. t To plan time parameters, k 6 represents the spatial weight of the plan. v To plan spatial parameters.
[0013] Preferably, the values of the path optimization parameter, path length parameter, path safety parameter, planning error parameter, planning time parameter, and planning spatial parameter are values greater than 0 and less than 1, with higher values resulting in higher evaluation.
[0014] Preferably, in step S3, the dynamically adjusted path planning parameters include the safety space radius and the step size of the improved fast expanding random tree (RRT) algorithm.
[0015] Therefore, this invention proposes an intelligent obstacle avoidance method for UAVs in urban environments based on autonomous learning, the benefits of which are as follows: (1) This invention integrates static knowledge, dynamic perception and local action information by combining prior map hard constraints and global path soft guidance, so that local planning is no longer blind and greatly improves the overall rationality and efficiency of planning.
[0016] (2) The present invention is achieved through The algorithm guarantees the macroscopic optimality of the baseline path. The improved RRT algorithm generates smoother and more natural local paths under guidance, avoiding severe jitter and invalid detours, thus improving the quality of path planning. At the same time, two-level collision detection ensures safety.
[0017] (3) This invention improves the RRT algorithm to achieve real-time path detection and fast path planning. By dynamically updating rather than switching the global path, it ensures the continuous and stable state of the system, avoids the jump of control instructions and decision oscillation, and improves the real-time performance and stability of path planning.
[0018] (4) The present invention introduces an online evaluation and optimization mechanism, which enables the system to self-adjust based on real-time flight performance and environmental complexity, thereby enhancing its robustness and adaptability in different urban scenarios. Attached Figure Description
[0019] Figure 1 A flowchart of an intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning; Figure 2 This is a schematic diagram of obstacle space and path in a simulated static environment; Figure 3 This is a schematic diagram of the path planning results for dynamic obstacle avoidance in vertical convergence conflict, where: (a) is climbing vertical convergence, and (b) is descending vertical convergence; Figure 4 This is a schematic diagram of the path planning results for dynamic obstacle avoidance in a head-on collision. Figure 5 A schematic diagram of the path planning results for dynamic obstacle avoidance in the conflict between overtaking and being overtaken, where: (a) represents overtaking, and (b) represents being overtaken; Figure 6 This is a schematic diagram of the path planning results for dynamic obstacle avoidance in a planar convergence conflict, where: (a) is the left convergence and (b) is the right convergence. Detailed Implementation
[0020] The technical solution of the present invention will be further described below with reference to the accompanying drawings and embodiments.
[0021] Unless otherwise defined, the technical or scientific terms used in this invention shall have the ordinary meaning as understood by one of ordinary skill in the art to which this invention pertains.
[0022] Example 1 like Figure 1 As shown, this invention provides an intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning, comprising the following steps: Step S1: Simultaneously collect urban environmental data using visual sensors, millimeter-wave radar, and lidar. Preprocess and fuse the collected data to construct a 3D obstacle grid map containing known static obstacles and initial environmental information. Real-time sensor data originates from a fusion perception system combining lidar and visual sensors. Specifically: like Figure 2 As shown, a grid map is created in Matlab to simulate an urban environment: The drone's dimensions are assumed to be 1m × 1m × 0.5m; the distance margin between the drone and obstacles is not calculated; the drone is assumed to travel at a constant speed; the grid map size is 500 × 500 × 500; each obstacle's position and length are assumed to be random; the starting position is [10, 10, 1], and the ending position is [450, 450, 40]; no-fly zones are not considered; all obstacles are static.
[0023] Determine performance evaluation metrics, including: search time, path length, return on investment, and turning angle.
[0024] Determine the search time: Start a stopwatch timer using the `tic` function, combine the MATLAB function with the `toc` function to measure the elapsed time, the `tic` function records the current time, and the `toc` function uses the recorded value to calculate the elapsed time; the `toc` function reads the elapsed time from the stopwatch, and at this time, the MATLAB function reads the time elapsed since the stopwatch timer was started by calling the `tic` function; MATLAB reads the internal time when the `toc` function is executed and displays the time elapsed since the last call to the `tic` function without output, in seconds, and outputs the recorded time of each algorithm as the search time.
[0025] Determining path length: Based on a 3D raster map, the path is a curve composed of multiple raster points. The length of the curve can be represented by the sum of the Euclidean distances between the raster points, using the following formula: ; in, D The distance between adjacent grid points. i For the grid point number, m This represents the number of adjacent grid point pairs in the path.x i+1 To delete grid points i +1 to the horizontal coordinate of the space, x i To delete grid points i The horizontal coordinate of space, y i+1 To delete grid points i +1 spatial ordinate, y i To delete grid points i The spatial ordinate, z i+1 To delete grid points i +1 spatial vertical coordinate, z i To delete grid points i The spatial vertical coordinate.
[0026] Determine the rate of return: The rate of return is the probability of a successful search, which can be expressed as the ratio of the number of feasible grids to the total number of grids searched, using the following formula: ; in, P For the rate of return, n successful To successfully iterate the corresponding number of feasible grid cells, n The total number of grid cells searched is denoted as . The number of feasible grid cells is counted during the iteration of each algorithm, and the count is incremented by one for each successful iteration. The total number of grid cells searched is incremented by a different number for each iteration due to the different search methods of each algorithm.
[0027] Determine the turning angle: The path consists of grid points, so each grid point ( x i , y i , z i ) and the next grid point ( x i+1 , y i+1 , z i+1 Treat it as a vector V i Turning angle It can be derived from two adjacent vectors V i and V i+1 The included angle between them represents the turning angle. It can be represented as: ; ; Five simulations were performed following the above process, that is, ten sets of obstacle space models were randomly generated to simulate the situation in different locations in the urban environment.
[0028] Step S2: Use a hierarchical planning strategy for flight path planning, including the following steps: Step S21: Under static conditions, based on The algorithm uses a grid map as the environment model, sets the starting point as the initial position of the UAV and the ending point as the position of the mission objective, calculates the node cost through an evaluation function, and generates the globally optimal static flight path. The evaluation function formula is as follows: ; in, f ( n ) is the current node n Total path cost g ( n (This refers to the actual cost already incurred.) h ( n () is a heuristic function, which is the estimated cost from the current node to the target node; Step S22: During flight, compared to static obstacle avoidance, the dynamic obstacle avoidance map has a smaller range. Therefore, the UAV cannot be approximated as a point. The influence of the UAV's size must be considered. The UAV cannot be allowed to brush past obstacles while avoiding them. In this experiment, a safety radius of 2m is assumed. A dynamic safety space is defined around the current globally optimal static flight path. Multiple sensors continuously monitor the airspace. When a new obstacle is detected in the dynamic safety space, the improved Rapid Extended Random Tree (RRT) algorithm is used for real-time replanning to quickly generate a local obstacle avoidance path. This path replaces the corresponding segment in the current globally optimal static flight path, forming an updated globally optimal static flight path. The RRT algorithm improvement method is as follows: A guided sampling strategy is adopted to guide the random sampling points of the RRT towards the prospective point or final target point of the globally optimal static flight path. Collision constraint detection is applied to the expansion of new nodes of the RRT random tree with obstacles in the 3D obstacle grid map. The dynamic safe space includes motion state estimation and short-term trajectory prediction of dynamic obstacles. The minimum distance between the UAV and the obstacle is set as the safe space radius. When the distance between the UAV and the obstacle is greater than the safe space radius, it is considered safe. The safe space radius is not less than the distance threshold between the node of the random tree in the RRT algorithm and the target point. Due to the limited map range and low obstacle density, the target threshold in the RRT algorithm is set to 1m for more accurate simulation results. The guided sampling strategy is implemented through probability distribution. The first probability is to select the look-ahead point as the sampling point on the globally optimal static flight path, the second probability is to select the final target point as the sampling point, and the third probability is to randomly sample in free space. The first and second probabilities are both greater than the third probability. Collision constraint detection is a two-level detection: first, it detects the conflict between the new node and the obstacle in the 3D obstacle grid map. If there is a conflict, it is directly abandoned; if there is no conflict, it continues to detect the conflict between the new node and the newly added obstacle in the dynamic safe space.
[0029] During flight, the obstacles that need to be avoided in dynamic obstacle avoidance are all unexpected situations. Therefore, it is impossible to model based on prior maps, and we can only rely on sensors for perception. The detection range of millimeter-wave radar is usually between 150m and 250m, while the detection range of lidar is between 200m and 300m. However, due to the obstruction of complex structures in the urban environment, this experiment adopted the most extreme distance possible, namely a range of 100m.
[0030] Assume a dynamic obstacle starts from an initial position, flies in a straight line at a constant speed, and its velocity is determined by the velocity along the X-axis. V x velocity in the Y-axis direction V y velocity on the Z-axis V z Composition, speed of dynamic obstacles V Size can be represented as: ; The direction of velocity can be represented by a vector ( V x , V y , V z () indicates the trajectory of a dynamic obstacle.
[0031] Since the size of obstacles such as flocks of birds or drone swarms can vary depending on the number and species of birds, as well as the number and spacing of drones in the swarm, the size of dynamic obstacles is usually uncertain. Therefore, we assume that the dynamic obstacle in this experiment is a sphere with a radius of 5m. In addition, five static obstacles of spheres are added to the map as interference, with their positions being (30,20,30), (20,60,40), (70,60,50), (40,80,20), and (60,30,80) and their radii being 10m, 8m, 9m, 7m, and 9m, respectively.
[0032] Since drones operate in urban environments, they mainly adopt a layered airspace structure. Therefore, when drones cruise in urban environments, they mostly fly at the same altitude. Assuming the size of the drone is a 1m×1m×1m grid, it starts from the set starting point (10,50,50) and flies towards the target point (90,50,50) at a set speed of 15 meters per second.
[0033] Step S3: Construct a multi-objective evaluation function that includes indicators such as path length, planning time, path smoothness, and safety margin. Quantitatively evaluate the planning results and dynamically adjust the path planning parameters based on the evaluation results. The formula for the multi-objective evaluation function is: ; in, F For multi-objective evaluation functions, k 1 represents the path optimization weight. c For path optimization parameters, k 2 represents the path length weight. d This is the path length parameter. k 3 represents the path safety weight. s For path safety parameters, k 4 represents the planning error weight. e For planning error parameters, k 5 represents the time weight for planning. t To plan time parameters, k 6 represents the spatial weight of the plan. v The planning space parameters include path optimization parameters, path length parameters, path safety parameters, planning error parameters, planning time parameters, and planning space parameters. The values of these parameters are greater than 0 and less than 1. The larger the value, the higher the evaluation. The dynamically adjusted path planning parameters include the safety space radius and the step size of the improved fast expanding random tree (RRT) algorithm.
[0034] The generated paths and performance indicators were recorded, and the results were analyzed, including simulation results under static conditions and simulation results during flight. The simulation results under static conditions are shown in Tables 1-5, specifically: Table 1. Simulation results of the first path planning experiment, i.e., path 1.
[0035] Table 2. Simulation results of the first path planning experiment, i.e., path 2.
[0036] Table 3. Simulation results of the first path planning experiment, i.e., path 3.
[0037] Table 4. Simulation results of the first path planning experiment, i.e., path 4.
[0038] Table 5. Simulation results of the first path planning experiment, i.e., path 5.
[0039] Table 6 Evaluation Results
[0040] As can be seen from Table 6, overall, The algorithm has the highest average rating, and the generated paths are superior to RRT and ant colony algorithms.
[0041] Depend on Figure 2 It can be concluded that The path is roughly the same as that of ant colony generation, but most of the parameters of the ant colony are missing. However, the ant colony algorithm has several drawbacks. It produces many "gaps" when turning, which explains why the paths generated by the ants, while appearing smooth, have relatively large maximum turning angles, with many exceeding 45 degrees. Future solutions may combine it with other algorithms to smooth out these "gaps." Furthermore, because the ant colony algorithm is a biomimetic algorithm, it is inherently complex with more parameters, leading to a significant increase in search time and a substantial decrease in real-time performance.
[0042] compared to Compared to ant colonies, the RRT algorithm's path generation appears quite coarse, often exhibiting significant ups and downs when encountering tall obstacles. This is due to the nature of its randomly generated trees. The generated paths are considerably longer, resulting in a lower reward rate compared to... The algorithm and ant colony algorithm also have low speeds, but their search time is relatively short compared to... The RRT algorithm significantly reduces the number of paths compared to the ant colony algorithm, so although the paths generated by the RRT algorithm are not optimal and are even quite coarse, its real-time performance is far superior. And ant colony algorithm.
[0043] In three-dimensional space, there are three degrees of freedom, resulting in a wide variety of collision patterns between UAVs and dynamic obstacles. This experiment verifies the real-time obstacle avoidance performance of the RRT algorithm through simulations of several commonly used collision patterns.
[0044] When a drone is flying horizontally, the flight path of a target obstacle crosses the horizontal plane of the drone's flight. Collisions are categorized into vertical convergence collisions when the obstacle is ascending and horizontal convergence collisions when the obstacle is descending. The positions of the dynamic obstacle are set to (90, 50, 10) and (90, 50, 90) respectively. To ensure a collision between the dynamic obstacle and the drone, the distance from the drone's starting position to the collision point is 40 meters. Assuming a speed of 15 meters per second, the speeds of the dynamic obstacle are set to (-15, 0, 15) and (-15, 0, -15) respectively. The results are as follows... Figure 3 As shown.
[0045] When the drone is flying horizontally, the target obstacle is located within ±10 degrees of its azimuth in front of the drone. Assuming the drone and the dynamic obstacle are moving towards each other, and the obstacle's initial position is (90, 50, 50) and its speed is (-15, 0, 0), the result is as follows: Figure 4 As shown.
[0046] Overtaking occurs when the drone is behind a dynamic obstacle, and their relative headings are within ±10 degrees. To ensure a successful collision with the obstacle before the drone reaches the target point in its straight flight, assuming the obstacle's position is (30, 50, 50) and its speed is (10, 0, 0), the result is as follows. Figure 5 As shown in (a); when being overtaken, the dynamic obstacle is located within a ±90 degree angle behind the drone, approaching from behind. Therefore, assuming the obstacle's initial position is (0, 50, 50), the dynamic obstacle's speed must be greater than the drone's speed to be overtaken, hence the speed is (20, 0, 0), as shown in (a). Figure 5 As shown in (b).
[0047] The convergence is divided into convergence from the left and convergence from the right. The dynamic obstacles are located in front of the left and front of the right of the drone, respectively. Assuming the positions of the dynamic obstacles are (50, 10, 50) and (50, 90, 50), and their speeds are (0, 15, 0) and (0, -15, 0), respectively, the results are as follows: Figure 6 As shown.
[0048] Table 7 shows the search time and success rate of the improved RRT algorithm, specifically: Table 7 Search time and success rate of the improved RRT algorithm
[0049] In the result image, the red circle represents the drone's starting position, the green circle represents the target position, the pink curve represents the path generated by the RRT algorithm, the green curve represents the branches in the random tree generated during the RRT algorithm operation (excluding the final path), the blue sphere represents the dynamic obstacles at the initial position, the blue straight line represents the velocity vector of the dynamic obstacles, and the red sphere represents the static obstacles that act as interference.
[0050] As shown in Table 7, in all obstacle avoidance scenarios with different conflict modes, the RRT algorithm successfully enabled the UAV to avoid dynamic obstacles during cruise without being interfered with by static obstacles, achieving a very high success rate. The search time in this simulation was 0.1632 seconds, which is slightly longer than the search time for static obstacles, but still maintains good real-time performance. Furthermore, the search time varies little between each iteration, demonstrating the algorithm's strong stability. The RRT algorithm exhibits strong obstacle avoidance capabilities against dynamic obstacles.
[0051] Simulation results show that no single sensor can meet all needs in complex urban environments. Fusion of multiple sensors—vision, millimeter-wave radar, and lidar—to leverage their respective strengths and compensate for their weaknesses is the only way to achieve robust, accurate, all-weather environmental and speed perception. Using multiple sensors allows for full utilization of their complementary advantages. Ideally, using vision sensors, millimeter-wave radar, and lidar together would achieve the most accurate detection; however, considering cost and computing power, a combination of vision sensors and millimeter-wave radar is preferable. When facing static obstacles such as buildings, preliminary path planning can be performed using a priori urban map. The algorithm obtains the optimal main flight path. Although this paper does not select typical local path planning algorithms for analysis, it can still make real-time obstacle avoidance adjustments when facing dynamic obstacles at the local level. During the UAV's flight, RRT is used for rapid dynamic obstacle avoidance planning. Whenever the sensors detect a new obstacle or the environment changes (i.e., the obstacle space changes), the RRT algorithm is used to regenerate the path based on the new map. Due to its rapid expansion characteristics, RRT can quickly generate paths, although the path quality is poor, it is sufficient to ensure flight safety.
[0052] It is worth noting that all contents not described in detail in this invention are existing technologies and are well known to those skilled in the art.
[0053] Therefore, the present invention proposes an intelligent obstacle avoidance method for UAVs in urban environments based on autonomous learning. This method uses incremental perception fusion to construct a dynamic environment model, adopts improved real-time replanning (RRT) with guided sampling and prior constraints, and closed-loop parameter optimization based on multi-index evaluation functions to generate flight paths with global approximate optimality, local real-time safety, and overall trajectory smoothness in urban low-altitude environments where dense static and dynamic obstacles coexist. This improves the robust obstacle avoidance capability of path planning to adapt to environmental complexity.
[0054] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the technical solutions of the present invention, and these modifications or equivalent substitutions cannot cause the modified technical solutions to deviate from the spirit and scope of the technical solutions of the present invention.
Claims
1. A method for intelligent obstacle avoidance of unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning, characterized in that: Includes the following steps: Step S1: Simultaneously collect urban environmental data using visual sensors, millimeter-wave radar, and lidar; preprocess and fuse the collected data to construct a three-dimensional obstacle grid map containing known static obstacles and initial environmental information. Step S2: Use a hierarchical planning strategy for flight path planning, including the following steps: Step S21: Under static conditions, based on The algorithm uses a grid map as the environment model, sets the starting point as the initial position of the UAV and the ending point as the position of the mission target, calculates the node cost through an evaluation function, and generates the globally optimal static flight path. Step S22: During flight, a dynamic safety space is defined around the current globally optimal static flight path. Multiple sensors continuously monitor the airspace. When a new obstacle is detected in the dynamic safety space, an improved Rapidly Expanding Random Tree (RRT) algorithm is used for real-time replanning to quickly generate a local obstacle avoidance path. This path replaces the corresponding segment in the current globally optimal static flight path, forming an updated globally optimal static flight path. The RRT algorithm improvement method is as follows: A guided sampling strategy is adopted to guide the random sampling points of the RRT towards the prospective point or the final target point of the globally optimal static flight path. Collision constraint detection is applied to the expansion of new nodes of the RRT random tree with obstacles in the 3D obstacle grid map. Step S3: Construct a multi-objective evaluation function that includes indicators such as path length, planning time, path smoothness, and safety margin, quantitatively evaluate the planning results, and dynamically adjust the path planning parameters based on the evaluation results.
2. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S1, the real-time sensor data comes from the fusion perception system of lidar and visual sensor.
3. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S21, the evaluation function formula is: ; in, f ( n ) is the current node n Total path cost g ( n (This refers to the actual cost already incurred.) h ( n ) is a heuristic function, which is the estimated cost from the current node to the target node.
4. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S22, the dynamic safe space includes the estimation of the motion state of dynamic obstacles and short-term trajectory prediction. The minimum distance between the UAV and the obstacle is set as the radius of the safe space. When the distance between the UAV and the obstacle is greater than the radius of the safe space, it is determined to be safe.
5. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 4, characterized in that: The safe space radius is not less than the distance threshold between the nodes of the random tree and the target point in the RRT algorithm.
6. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S22, the guided sampling strategy is implemented through a probability distribution. The first probability is to select a forward point as a sampling point on the globally optimal static flight path, the second probability is to select the final target point as a sampling point, and the third probability is to randomly sample in free space. The first and second probabilities are both greater than the third probability.
7. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S22, the collision constraint detection is a two-level detection: first, the new node is detected to have a conflict with the obstacles in the 3D obstacle grid map. If there is a conflict, it is abandoned directly; if there is no conflict, the new node is detected to have a conflict with the newly added obstacles in the dynamic safe space.
8. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S3, the multi-objective evaluation function formula is: ; in, F For multi-objective evaluation functions, k 1 represents the path optimization weight. c For path optimization parameters, k 2 represents the path length weight. d This is the path length parameter. k 3 represents the path safety weight. s For path safety parameters, k 4 represents the planning error weight. e For planning error parameters, k 5 represents the time weight for planning. t To plan time parameters, k 6 represents the spatial weight of the plan. v To plan spatial parameters.
9. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 8, characterized in that: The values of path optimization parameters, path length parameters, path safety parameters, planning error parameters, planning time parameters, and planning space parameters are all values greater than 0 and less than 1. The larger the value, the higher the evaluation.
10. The intelligent obstacle avoidance method for unmanned aerial vehicles (UAVs) in urban environments based on autonomous learning according to claim 1, characterized in that: In step S3, the dynamically adjusted path planning parameters include the safety space radius and the step size of the improved fast expanding random tree (RRT) algorithm.