A UAV path planning method and system

By using snake optimization algorithm in drone path planning, the limitations and winding problems of path planning algorithms in the existing technology are solved, and fast and efficient global and local optimal path planning is achieved, which improves the efficiency and accuracy of path planning. sex.

CN115437407BActive Publication Date: 2024-12-31ARMOR ACADEMY OF CHINESE PEOPLES LIBERATION ARMY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211206133.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-30
Publication Date
2024-12-31
Estimated Expiration
2042-09-30

AI Technical Summary

Technical Problem

The existing drone path planning algorithm has certain limitations in global search and local search. It has slow convergence speed and is prone to local optimality, and is prone to entanglement problems in path planning.

Method used

The snake optimization algorithm is used, combined with the pre-set snake optimization algorithm parameters, and global search or local search is carried out. The search strategy is determined by initializing the population and ambient temperature, the path is optimized, the winding problem is solved, and the local optimality is jumped out.

Benefits of technology

It realizes rapid convergence of drone path planning, avoids local optimization, solves the entanglement problem, and can provide better tracks in a short time, improving the efficiency and accuracy of path planning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115437407B_ABST
    Figure CN115437407B_ABST
Patent Text Reader

Abstract

The present invention relates to a method and system for planning a path for an unmanned aerial vehicle, which is characterized by comprising: establishing a flight environment and three-dimensional terrain information of a to-be-planned unmanned aerial vehicle; using a snake optimization algorithm, based on pre-set snake optimization algorithm parameters, and performing a global search or a local search according to the established flight environment and three-dimensional terrain information to obtain a plurality of paths for the to-be-planned unmanned aerial vehicle; selecting the shortest path among the obtained plurality of paths, and re-performing a global search or a local search until a preset number of iterations is reached, and the shortest path at this time is the optimal path for the to-be-planned unmanned aerial vehicle. The present invention can be widely applied to the field of unmanned aerial vehicles.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of unmanned aerial vehicles, and in particular to a method and system for planning a path for an unmanned aerial vehicle. Background Art

[0002] Nowadays, drones are increasingly used in military and civilian fields. They have the advantages of being lightweight, durable, and reducing labor costs. Drone path planning is the planning of the optimal flight trajectory that meets all constraints based on the mission. Its key technical content includes the acquisition and processing of terrain information, the algorithm of the obstacle penetration model, and the trajectory tracking method, among which the core is the algorithm design of path planning.

[0003] At present, the path planning algorithms in the prior art mainly include graph search algorithms, artificial potential field algorithms, intelligent optimization algorithms, and machine learning algorithms, etc. However, the existing path planning algorithms are only applicable to one of the global search or local search when planning the path of a UAV, which has certain limitations, slow convergence speed, and easy to fall into the local optimum. Summary of the invention

[0004] In view of the above problems, the object of the present invention is to provide a UAV path planning method and system that can be applied to global search and local search.

[0005] To achieve the above objectives, the present invention adopts the following technical solutions: In a first aspect, a method for planning a path for a drone is provided, comprising:

[0006] Establish the flight environment and three-dimensional terrain information of the UAV to be planned;

[0007] Using the snake optimization algorithm, based on the pre-set snake optimization algorithm parameters, and according to the established flight environment and three-dimensional terrain information, a global search or a local search is performed to obtain several paths of the UAV to be planned;

[0008] The shortest path among the obtained paths is selected, and the global search or local search is performed again until the preset number of iterations is reached. The shortest path at this time is the optimal path for the UAV to be planned.

[0009] Furthermore, the three-dimensional terrain information includes the map range and peak feature information of the UAV flight environment to be planned, wherein the peak feature information includes the number of peaks, peak center coordinates, peak area, peak height and peak slope.

[0010] Furthermore, the parameters of the snake optimization algorithm include starting point coordinates, number of iterations, number of individuals, food threshold, constant value, population attributes, population position, node position and fitness function, wherein food represents the current optimal path, and individuals in the population represent drones to be planned.

[0011] Furthermore, the snake optimization algorithm is used to perform a global search or a local search based on the pre-set snake optimization algorithm parameters and the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned, including:

[0012] Based on the set snake optimization algorithm parameters, determine the population, environmental temperature and food quantity of the snake optimization algorithm;

[0013] The snake optimization algorithm is adopted. Based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, a global search or a local search is performed according to the established flight environment and three-dimensional terrain information to obtain several paths for the UAV to be planned.

[0014] Further, the snake optimization algorithm parameters are set to determine the population, environmental temperature and food quantity of the snake optimization algorithm, including:

[0015] Based on the set snake optimization algorithm parameters, the population of the snake optimization algorithm is initialized, a uniformly distributed random population is generated, and the generated random population is divided into two groups: male and female;

[0016] Based on the set snake optimization algorithm parameters, the environmental temperature and food quantity of the snake optimization algorithm are determined.

[0017] Furthermore, the snake optimization algorithm is used to perform a global search or a local search based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, according to the established flight environment and three-dimensional terrain information, to obtain several paths of the drone to be planned, including:

[0018] When the amount of food is less than or equal to the food threshold, a global search is performed and the planned drone randomly selects a path;

[0019] When the amount of food is greater than or equal to the food threshold and the ambient temperature is greater than or equal to the temperature threshold, a local search is performed and the planned UAV updates the path in the direction of the optimal path;

[0020] When the amount of food is greater than or equal to the food threshold and the ambient temperature is less than or equal to the temperature threshold, it is in combat mode or mating mode, and a local search is performed, and the planned drone updates the path in the direction of the optimal path;

[0021] Based on the set snake optimization algorithm parameters, according to the established flight environment and three-dimensional terrain information, collision detection penalties are imposed on the individuals in the population that exceed the boundary, and the path before collision detection penalty is replaced by the path after collision detection penalty.

[0022] Furthermore, in the mating mode, if the shortest path is entangled, three points are selected in the shortest path where the entanglement occurs to optimize the entanglement position of the shortest path, and the optimized path replaces the path before optimization, wherein two points are set on both sides of the entanglement position and the other point is set at the entanglement position.

[0023] In a second aspect, a UAV path planning system is provided, comprising:

[0024] The flight environment establishment module is used to establish the flight environment and three-dimensional terrain information of the UAV to be planned;

[0025] The path preliminary selection module is used to use the snake optimization algorithm, based on the pre-set snake optimization algorithm parameters, and perform global search or local search according to the established flight environment and three-dimensional terrain information to obtain several paths for the UAV to be planned;

[0026] The path determination module is used to select the shortest path among the several paths obtained and re-perform a global search or a local search until a preset number of iterations is reached. The shortest path at this time is the optimal path for the UAV to be planned.

[0027] In a third aspect, a processing device is provided, comprising computer program instructions, wherein the computer program instructions, when executed by the processing device, are used to implement the steps corresponding to the above-mentioned drone path planning method.

[0028] In a fourth aspect, a computer-readable storage medium is provided, on which computer program instructions are stored, wherein the computer program instructions, when executed by a processor, are used to implement the steps corresponding to the above-mentioned drone path planning method.

[0029] The present invention adopts the above technical solution, which has the following advantages:

[0030] 1. The present invention adopts the snake optimization algorithm to plan the UAV path, which has a faster convergence speed than other algorithms and is easier to jump out of the local optimum and continue to find a less costly track, which has the advantages of being fast and efficient.

[0031] 2. Since the snake optimization algorithm will randomly cause entanglement problems when directly used in UAV planning, the present invention adopts the optimized snake optimization algorithm, selects three points on the entangled local path, and replaces the optimized path with the three points as the path. This can solve the entanglement problem caused by the snake optimization algorithm in UAV path planning, and can not only achieve global optimality, but also local optimality.

[0032] 3. The present invention can not only provide a better track in a shorter time, but also search for a better track more accurately, which is more desirable in practical applications.

[0033] In summary, the present invention can be widely applied in the field of drone technology. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present invention. Throughout the accompanying drawings, the same reference numerals are used to represent the same components. In the accompanying drawings:

[0035] Figure 1 It is a schematic diagram of a method flow provided by an embodiment of the present invention;

[0036] Figure 2 1 is a schematic diagram of the results of three random UAV path planning using the method of the present invention provided by an embodiment of the present invention, wherein: Figure 2 (a), (b) and (c) are schematic diagrams of the results of three UAV path planning;

[0037] Figure 3 : is a schematic diagram of a fitness curve for three random UAV path planning using the method of the present invention provided by an embodiment of the present invention, wherein: Figure 3 (a), (b) and (c) are schematic diagrams of the fitness curves of three UAV path planning. DETAILED DESCRIPTION

[0038] The exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present invention and to fully convey the scope of the present invention to those skilled in the art.

[0039] It should be understood that the terms used herein are only for the purpose of describing specific example embodiments and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "one", "an" and "said" as used herein may also be meant to include plural forms. The terms "include", "comprise", "contain", and "have" are inclusive, and therefore specify the existence of stated features, steps, operations, elements and / or parts, but do not exclude the existence or addition of one or more other features, steps, operations, elements, parts, and / or combinations thereof. The method steps, processes, and operations described herein are not interpreted as necessarily requiring them to be performed in the specific order described or illustrated, unless the execution order is clearly indicated. It should also be understood that additional or alternative steps may be used.

[0040] Although the terms first, second, third, etc. can be used in the text to describe multiple elements, components, regions, layers and / or sections, these elements, components, regions, layers and / or sections should not be limited by these terms. These terms can only be used to distinguish an element, component, region, layer or section from another region, layer or section. Unless the context clearly indicates, terms such as "first", "second" and other numerical terms do not imply order or sequence when used in the text. Therefore, the first element, component, region, layer or section discussed below can be referred to as the second element, component, region, layer or section without departing from the teaching of the example embodiments.

[0041] The UAV path planning method and system of the embodiment of the present invention adopts the Snake Optimizer (SO) algorithm to plan the three-dimensional path of the UAV, and can solve the entanglement problem of the SO algorithm in the UAV path planning, and can achieve global optimality and local optimality at the same time.

[0042] Specifically, the snake optimization algorithm is inspired by the mating behavior of snakes. Under low temperature and sufficient food conditions, snakes will mate, produce the next generation and eliminate the worst individuals in the group. Otherwise, the snakes will only look for food or eat the remaining food. The snake optimization algorithm is divided into two stages: global exploration and local development. In the global exploration stage, the snake will select a random position to search for food and update its relative position to the object. In the local development stage, the snake will only move in the direction of food (target direction). When there is food but the temperature is too high, the snake will only focus on eating the available food; when there is food but the temperature is too low, mating behavior will occur. The mating process is divided into fighting mode and mating mode. In the fighting mode, each male snake will fight for the best female snake, and each female snake will try to choose the best male snake; in the mating mode, the number of mating male and female snakes is related to the amount of available food. If mating is successful, the female snake will lay eggs and produce a new generation of snakes, which will eliminate the worst snakes in the group. The present invention improves the search efficiency based on the above algorithm, enables the UAV to quickly avoid obstacles, find a suitable flight route, and make the global search more efficient.

[0043] Example 1

[0044] Based on the above description, if Figure 1 As shown, this embodiment provides a method for UAV path planning, comprising the following steps:

[0045] 1) Establish the flight environment of the UAV to be planned and initialize the three-dimensional terrain information. This step is used to set random obstacles for the UAV so that the UAV cannot fly through the mountains.

[0046] Specifically, the three-dimensional terrain information includes the map range (length, width, height) of the UAV flight environment to be planned and the mountain feature information.

[0047] Specifically, the peak feature information is initialized using a struct structure, wherein the peak feature information includes the number of peaks, peak center coordinates, peak area, peak height, and peak slope.

[0048] 2) Set the parameters of the snake optimization algorithm.

[0049] Specifically, the parameters of the snake optimization algorithm include the starting point coordinates, the number of iterations, the number of individuals, the food threshold Threshold, the temperature threshold Threshold2, the constant c value, the population attributes, the population location, the node location and the fitness function (the fitness function is the penalty for the drone. If the drone flies out of the set map range or searches through the mountains, it will be punished). Among them, food represents the current optimal path, and the individuals in the population represent the drones to be planned.

[0050] 3) Based on the set snake optimization algorithm parameters, initialize the population of the snake optimization algorithm, specifically:

[0051] 3.1) Based on the set snake optimization algorithm parameters, initialize the population of the snake optimization algorithm and generate a uniformly distributed random population:

[0052] X i =X min +r×(X max -X min ) (1)

[0053] Among them, X i is the position of the i-th individual in the population; r is a random number that conforms to the normal distribution and satisfies r∈[0,1]; X min is the lower limit variable of the position; X max Upper limit variable for position.

[0054] 3.2) Divide the generated random population into two groups: males and females:

[0055]

[0056] N f =NN m (3)

[0057] Where N is the total number of individuals in the generated random population; N m is the number of male individuals in the generated random population; N f is the number of female individuals in the generated random population.

[0058] 4) Based on the set snake optimization algorithm parameters, determine the environmental temperature and food quantity of the snake optimization algorithm.

[0059] Specifically, the ambient temperature Temp of the snake optimization algorithm is:

[0060]

[0061] Among them, t is the current iteration number; T is the maximum iteration number.

[0062] Specifically, the amount of food Q in the snake optimization algorithm is:

[0063]

[0064] Where c1 is a constant.

[0065] Specifically, as the number of iterations increases, the environmental temperature Temp of the snake optimization algorithm decreases and the amount of food Q increases.

[0066] 5) Using the snake optimization algorithm, based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, according to the established flight environment and three-dimensional terrain information, a global search or a local search is performed to update the population position and obtain several paths of the drone to be planned, specifically:

[0067] 5.1) When the determined amount of food is less than or equal to the food threshold, i.e., Q≤Threshold, the male snake selects a random location to search for food, performs a global search (no food), and the planned drone randomly selects a path:

[0068] X im (t+1)=X rm (t)±c2×A m ×((X max -X min )×r+X min ) (6)

[0069]

[0070] X if =X rf (t+1)±c2×A f ×((X max -X min )×r+X min ) (8)

[0071]

[0072] Among them, X im is the specific position of the ith male snake; X rmis the random position of the male snake; c2 is a constant; A m The ability to find food for male snakes; rm For X rm The fitness value of im is the fitness value of the ith male snake individual; X if is the specific location of the i-th female snake, X rf is the random position of the female snake, A f The ability of female snakes to find food, rf For X rf The fitness value, f if is the fitness value of the i-th female snake individual.

[0073] 5.2) When the determined amount of food is greater than or equal to the food threshold and the determined ambient temperature is greater than or equal to the temperature threshold, that is, Q ≥ Threshold and Temp ≥ Threshold2, the male and female snakes will only move towards the food direction and conduct local search (where there is food and the temperature is high), and the planned drone will update the path in the direction of the optimal path:

[0074] X ij (t+1)=X food ±c3×Temp×r×(X food -X ij (t)) (10)

[0075] Among them, X ij X is the position of all male and female snakes; food is the optimal position of all male and female snakes, and c3 is a constant.

[0076] 5.3) When the determined food quantity is greater than or equal to the food threshold and the determined ambient temperature is less than or equal to the temperature threshold, that is, the food quantity Q>Threshold] and the ambient temperature Temp≤Threshold2, the male snake will be in combat mode or mating mode and conduct a local search (where there is food and the temperature is low) until the planned UAV updates the path in the direction of the optimal path.

[0077] Specifically, in combat mode, the path to be planned for the drone to be updated is:

[0078] X im (t+1)=X im (t)±c3×FM×r×(Q×X fbest -X im (t)) (11)

[0079] X if (t+1)=X if (t)±c3×FF×r×(Q×X mbest -Xif (t)) (12)

[0080]

[0081]

[0082] Among them, X fbest is the best position among all female snakes; FM is the fighting power of male snakes; X mbest is the best position among all male snakes; FF is the fighting power of female snakes; f fbest is the fitness of the best individual among all female snakes; f mbest is the fitness of the best individual among all male snakes, f i is the fitness of the current individual.

[0083] Specifically, in mating mode, the path to be planned for the updated drone is:

[0084] X im (t+1)=X im (t)±c3×M m ×r×(Q×X if (t)-X im (t)) (15)

[0085] X if (t+1)=X if (t)±c3×M f ×r×(Q×X im (t)-X if (t)) (16)

[0086]

[0087]

[0088] Among them, M m M is the mating ability of male snakes; f The mating ability of female snakes.

[0089] Specifically, in the mating mode, when the male snake and the female snake mate to produce the next generation, the worst male snake or female snake is replaced, that is, the worst path is replaced by the path corresponding to the new individual, and the worst path is the longest path among all paths.

[0090] 5.4) Based on the set parameters of the snake optimization algorithm, according to the established flight environment and three-dimensional terrain information, collision detection penalties are imposed on the individuals in the population that are out of bounds, and the paths before collision detection penalties are replaced with the paths after collision detection penalties.

[0091] Specifically, in order to adapt to the characteristics of drone flight, in the process of finding the optimal path, when the path intersects with the established flight environment, the individual corresponding to the path is considered to be out of bounds, and is penalized by the set fitness function, and the path after collision detection penalty replaces the path before collision detection penalty so that the new individual can eliminate it.

[0092] 6) The shortest path among the several paths of the UAV to be planned is selected as the preferred path of the UAV to be planned, and the process goes to step 5) until the preset number of iterations is reached. The preferred path at this time is the optimal path of the UAV to be planned.

[0093] Specifically, if the shortest path is winding, three points are selected in the shortest path where the winding phenomenon occurs (two points are set on both sides of the winding position, and the other point is set at the winding position) to optimize the winding position of the shortest path to obtain the optimized path, and the optimized path is used to replace the path before optimization:

[0094] X mworst =X min +r×(X max -X min ) (19)

[0095] X fworst =X min +r×(X max -X min ) (20)

[0096] Among them, X mworst The worst male snake individual; X fworst The worst female snake.

[0097] like Figure 2 (a), (b) and (c) are schematic diagrams of the results of three random UAV path planning using the method of the present invention. It can be seen that the method of the present invention has good real-time performance, strong obstacle avoidance capability, smooth path, high safety, and strong global and local path planning capabilities.

[0098] like Figure 3 (a), (b) and (c) are schematic diagrams of fitness curves of three random UAV path planning using the method of the present invention. It can be seen that the method of the present invention converges faster.

[0099] Example 2

[0100] This embodiment provides a drone path planning system, including:

[0101] The flight environment establishment module is used to establish the flight environment and three-dimensional terrain information of the UAV to be planned.

[0102] The path preliminary selection module is used to adopt the snake optimization algorithm, based on the pre-set snake optimization algorithm parameters, and perform global search or local search according to the established flight environment and three-dimensional terrain information to obtain several paths for the UAV to be planned.

[0103] The path determination module is used to select the shortest path among the several paths obtained and re-perform a global search or a local search until a preset number of iterations is reached. The shortest path at this time is the optimal path for the UAV to be planned.

[0104] The system provided in this embodiment is used to execute the above-mentioned method embodiments. Please refer to the above-mentioned embodiments for specific processes and detailed contents, which will not be repeated here.

[0105] Example 3

[0106] This embodiment provides a processing device corresponding to the drone path planning method provided in this embodiment 1. The processing device can be applicable to a client processing device, such as a mobile phone, a laptop computer, a tablet computer, a desktop computer, etc., to execute the method of embodiment 1.

[0107] The processing device includes a processor, a memory, a communication interface and a bus, and the processor, the memory and the communication interface are connected through the bus to complete mutual communication. The memory stores a computer program that can be run on the processing device, and the processing device executes the drone path planning method provided in this embodiment 1 when running the computer program.

[0108] In some implementations, the memory may be a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk memory.

[0109] In some other implementations, the processor may be a central processing unit (CPU), a digital signal processor (DSP), or other general-purpose processors of various types, which are not limited herein.

[0110] In addition, the logic instructions in the above-mentioned memory can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0111] Those skilled in the art will understand that the structure of the above-mentioned computing device is only a partial structure related to the scheme of the present application, and does not constitute a limitation on the computing device to which the scheme of the present application is applied. The specific computing device may include more or fewer components, or combine certain components, or have a different arrangement of components.

[0112] Example 4

[0113] This embodiment provides a computer program product corresponding to the drone path planning method provided in this embodiment 1. The computer program product may include a computer-readable storage medium on which computer-readable program instructions for executing the drone path planning method described in this embodiment 1 are loaded.

[0114] Computer readable storage media can be tangible devices that hold and store instructions used by instruction execution devices. Computer readable storage media can be, for example, but not limited to, electronic storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any combination thereof.

[0115] The above embodiment provides a computer-readable storage medium, whose implementation principle and technical effect are similar to those of the above method embodiment, and will not be repeated here.

[0116] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0117] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0118] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0119] The above embodiments are only used to illustrate the present invention, wherein the structure, connection mode and manufacturing process of each component may be changed. Any equivalent transformations and improvements based on the technical solution of the present invention should not be excluded from the protection scope of the present invention.

Claims

1. A method for UAV path planning, characterized in that: include: Establishing the flight environment and three-dimensional terrain information of the UAV to be planned, wherein the three-dimensional terrain information includes the map range and peak feature information of the flight environment of the UAV to be planned, wherein the peak feature information includes the number of peaks, peak center coordinates, peak area, peak height and peak slope; A snake optimization algorithm is used, based on pre-set snake optimization algorithm parameters, and a global search or a local search is performed according to the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned. The parameters of the snake optimization algorithm include the coordinates of the starting point, the number of iterations, the number of individuals, the food threshold, the constant value, the population attribute, the population position, the node position and the fitness function, wherein the food represents the current optimal path, and the individuals in the population represent the UAV to be planned; The shortest path among the obtained paths is selected, and global search or local search is performed again until the preset number of iterations is reached. The shortest path at this time is the optimal path for the UAV to be planned; The snake optimization algorithm is used to perform a global search or a local search based on the pre-set snake optimization algorithm parameters and the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned, including: Based on the set snake optimization algorithm parameters, determine the population, environmental temperature and food quantity of the snake optimization algorithm; Using the snake optimization algorithm, based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, and according to the established flight environment and three-dimensional terrain information, a global search or a local search is performed to obtain several paths for the UAV to be planned; The snake optimization algorithm parameters are set to determine the population, environmental temperature and food quantity of the snake optimization algorithm, including: Based on the set snake optimization algorithm parameters, the population of the snake optimization algorithm is initialized, a uniformly distributed random population is generated, and the generated random population is divided into two groups: male and female; Based on the set snake optimization algorithm parameters, determine the environment temperature and food quantity of the snake optimization algorithm; The snake optimization algorithm is used to perform a global search or a local search based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, and the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned, including: When the amount of food is less than or equal to the food threshold, a global search is performed and the planned drone randomly selects a path; When the amount of food is greater than or equal to the food threshold and the ambient temperature is greater than or equal to the temperature threshold, a local search is performed and the planned UAV updates the path in the direction of the optimal path; When the amount of food is greater than or equal to the food threshold and the ambient temperature is less than or equal to the temperature threshold, it is in combat mode or mating mode, and a local search is performed, and the planned drone updates the path in the direction of the optimal path; Based on the set snake optimization algorithm parameters, according to the established flight environment and three-dimensional terrain information, collision detection penalties are imposed on the individuals in the population that exceed the boundary, and the path before collision detection penalty is replaced by the path after collision detection penalty.

2. A method for UAV path planning as claimed in claim 1, characterized in that: In the mating mode, if the shortest path is entangled, three points are selected in the shortest path where the entanglement occurs to optimize the winding position of the shortest path, and the optimized path replaces the path before optimization, wherein two points are set on both sides of the winding position and the other point is set at the winding position.

3. A UAV path planning system, characterized in that: include: A flight environment establishment module is used to establish the flight environment and three-dimensional terrain information of the UAV to be planned, wherein the three-dimensional terrain information includes the map range and peak feature information of the flight environment of the UAV to be planned, wherein the peak feature information includes the number of peaks, the coordinates of the center of the peaks, the area of ​​the peaks, the height of the peaks and the slope of the peaks; The path preliminary selection module is used to use the snake optimization algorithm, based on the pre-set snake optimization algorithm parameters, and perform global search or local search according to the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned. The parameters of the snake optimization algorithm include the starting point coordinates, the number of iterations, the number of individuals, the food threshold, the constant value, the population attribute, the population position, the node position and the fitness function, wherein the food represents the current optimal path, and the individuals in the population represent the UAV to be planned; The path determination module is used to select the shortest path among the obtained paths and re-perform global search or local search until the preset number of iterations is reached. The shortest path at this time is the optimal path for the UAV to be planned; The snake optimization algorithm is used to perform a global search or a local search based on the pre-set snake optimization algorithm parameters and the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned, including: Based on the set snake optimization algorithm parameters, determine the population, environmental temperature and food quantity of the snake optimization algorithm; Using the snake optimization algorithm, based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, and according to the established flight environment and three-dimensional terrain information, a global search or a local search is performed to obtain several paths for the UAV to be planned; The snake optimization algorithm parameters are set to determine the population, environmental temperature and food quantity of the snake optimization algorithm, including: Based on the set snake optimization algorithm parameters, the population of the snake optimization algorithm is initialized, a uniformly distributed random population is generated, and the generated random population is divided into two groups: male and female; Based on the set snake optimization algorithm parameters, determine the environment temperature and food quantity of the snake optimization algorithm; The snake optimization algorithm is used to perform a global search or a local search based on the set snake optimization algorithm parameters and the determined population, ambient temperature and food quantity, and the established flight environment and three-dimensional terrain information to obtain several paths of the UAV to be planned, including: When the amount of food is less than or equal to the food threshold, a global search is performed and the planned drone randomly selects a path; When the amount of food is greater than or equal to the food threshold and the ambient temperature is greater than or equal to the temperature threshold, a local search is performed and the planned UAV updates the path in the direction of the optimal path; When the amount of food is greater than or equal to the food threshold and the ambient temperature is less than or equal to the temperature threshold, it is in combat mode or mating mode, and a local search is performed, and the planned drone updates the path in the direction of the optimal path; Based on the set snake optimization algorithm parameters, according to the established flight environment and three-dimensional terrain information, collision detection penalties are imposed on the individuals in the population that exceed the boundary, and the path before collision detection penalty is replaced by the path after collision detection penalty.

4. A processing device, characterized in that: The method comprises computer program instructions, wherein the computer program instructions are used to implement the steps corresponding to the UAV path planning method according to any one of claims 1 to 2 when executed by a processing device.

5. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer program instructions, wherein the computer program instructions, when executed by a processor, are used to implement the steps corresponding to the UAV path planning method according to any one of claims 1 to 2.