Dynamic task allocation method and device for multiple unmanned aerial vehicles, terminal equipment and storage medium
By monitoring the remaining energy and mission execution status of drones, dynamically adjusting the task queue, and using game algorithms and ride-sharing order-grabbing logic to redistribute tasks, the problems of low drone utilization and mission completion efficiency are solved, and more efficient mission execution is achieved.
Patent Information
- Application Number
- CN202510778691.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-11
- Publication Date
- 2025-09-12
AI Technical Summary
The existing drone task allocation system results in low drone utilization and task completion efficiency when faced with emergencies. After some drones complete their tasks, other drones still have unfinished tasks.
By monitoring the remaining energy of the drone, when the last task is completed, the task queue is dynamically adjusted to assign candidate tasks to drones with sufficient remaining energy, optimize the flight path to improve energy utilization and task completion efficiency, and use game algorithms and ride-sharing order-grabbing logic to redistribute tasks.
It improves the overall utilization rate of drones and the efficiency of mission completion, reduces the number of drones running in vain, and achieves more efficient mission execution.
Smart Images

Figure CN120631019A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of unmanned aerial vehicle (UAV) control, and in particular to a method, device, terminal equipment, and storage medium for dynamic task allocation of multiple UAVs. Background Art
[0002] With technological advancements, drones have been widely used in agriculture, logistics, equipment inspection, and other fields due to their advantages of low labor intensity, high efficiency, and low overall costs. With the increasing complexity of mission requirements and the rapid development of drone technology, drone operations have gradually evolved from single-machine operations to multi-machine collaborative operations. Compared to single-machine operations, multi-machine collaborative operations possess stronger perception and mission execution capabilities. In drone operations, a task allocation system is typically used to allocate tasks to each drone's task queue, allowing each drone to execute tasks according to its own task queue.
[0003] Although the current task allocation system considers factors such as task completion efficiency and task completion time when allocating tasks, the actual task execution time may change due to various emergencies during the execution of drone tasks. It often happens that when some drones complete all tasks and fly back to the airport to wait for flight, other drones still have many tasks left to complete, resulting in low drone utilization and task completion efficiency. Summary of the Invention
[0004] The present invention provides a method, apparatus, terminal device and storage medium for dynamic task allocation of multiple unmanned aerial vehicles (UAVs). The method can solve the problems of low utilization rate and task completion efficiency of current UAVs.
[0005] An embodiment of the present invention provides a method for dynamic task allocation of multiple UAVs, including:
[0006] Obtaining a task queue of each UAV consisting of a plurality of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed;
[0007] During the UAV mission, when a target UAV is detected to have completed the last target mission to be performed, the remaining energy of the target UAV is determined;
[0008] When it is determined that the remaining energy is greater than the target flight energy requirement required for the target UAV to fly to the preset target destination airport, the pending tasks of several UAVs other than the target UAV are selected as candidate tasks;
[0009] generating candidate routes for each candidate task and determining candidate flight energy requirements for each candidate route based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport location of the target destination airport;
[0010] determining, based on the remaining energy, the candidate flight energy requirements of the candidate paths, and the candidate task energy requirements of the candidate tasks, a candidate task that can be performed by the target UAV as a reallocated task;
[0011] The reallocated task is added to the target task queue of the target UAV, and the target candidate path corresponding to the reallocated task is sent to the target UAV, so that the target UAV performs the reallocated task.
[0012] Furthermore, obtaining a task queue of each drone consisting of a plurality of tasks to be executed includes:
[0013] Obtaining several mission locations to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone;
[0014] Clustering the tasks to be executed according to the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones;
[0015] According to the initial energy and task pre-grouping of several UAVs, task allocation and path planning are carried out with the goal of minimizing the flight path of each UAV, and a task queue and planned flight path for each UAV are generated.
[0016] Furthermore, determining a candidate task that can be performed by the target UAV as the reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks includes:
[0017] Calculating the total energy requirement of each candidate task according to the candidate flight energy requirements required by each candidate path and the candidate task energy requirements of the candidate task;
[0018] taking a candidate task corresponding to a total energy demand greater than the remaining energy as a first task, and obtaining a task priority of the first task;
[0019] The task scores of the first tasks are calculated according to the task priorities and the total energy demand, and the first task with the highest task score is used as the reallocated task.
[0020] Furthermore, after sending the target candidate path corresponding to the reallocated task to the target UAV, the method further includes:
[0021] Obtaining the first UAV originally corresponding to the reallocated task and the real-time location of the first UAV;
[0022] removing the reallocated task from the first task queue of the first UAV;
[0023] Based on the first task locations of several tasks to be executed in the first task queue, the first terminal airport corresponding to the first drone, and the real-time location, path replanning is performed with the goal of minimizing the sum of flight paths to generate a replanned flight path for the first drone.
[0024] Furthermore, the method for dynamic task allocation of multiple UAVs described in any of the above embodiments of the invention further includes:
[0025] Obtaining flight parameters and real-time locations of each of the drones;
[0026] Predicting whether each of the UAVs has a collision risk in the future based on the flight parameters, the real-time position, and the flight path of each UAV; wherein the flight path is the planned flight path, the target candidate path, or the replanned flight path;
[0027] When it is determined that there is a collision risk between several second drones at a future moment, the flight parameters of each of the second drones are optimized with the goal of minimizing the collision risk, target flight parameters of each of the second drones are generated, and the flight parameters are sent to the corresponding second drones.
[0028] An embodiment of the present invention further provides a device for dynamic task allocation of multiple UAVs, comprising:
[0029] A task data acquisition module is used to obtain a task queue of each UAV consisting of a number of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed;
[0030] The UAV monitoring module is used to monitor a target UAV when it completes the last target to be executed task during the UAV mission execution process and determine the remaining energy of the target UAV;
[0031] a candidate task determination module, configured to, when determining that the remaining energy is greater than a target flight energy requirement for the target UAV to fly to a preset target destination airport, select the pending tasks of several UAVs other than the target UAV as candidate tasks;
[0032] a candidate path planning module, configured to generate candidate paths for each candidate task and determine candidate flight energy requirements for each candidate path based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport locations of the target destination airports;
[0033] a candidate task evaluation module, configured to determine a candidate task that can be performed by the target UAV as a reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks;
[0034] The task reallocation module is used to add the reallocated task to the target task queue of the target UAV and send the target candidate path corresponding to the reallocated task to the target UAV so that the target UAV executes the reallocated task.
[0035] Furthermore, the task data acquisition module acquires a task queue of each drone consisting of a number of tasks to be executed, including:
[0036] Obtaining several mission locations to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone;
[0037] Clustering the tasks to be executed according to the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones;
[0038] According to the initial energy and task pre-grouping of several UAVs, task allocation and path planning are carried out with the goal of minimizing the flight path of each UAV, and a task queue and planned flight path for each UAV are generated.
[0039] Furthermore, the candidate task evaluation module determines a candidate task that can be performed by the target UAV as the reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks, including:
[0040] Calculating the total energy requirement of each candidate task according to the candidate flight energy requirements required by each candidate path and the candidate task energy requirements of the candidate task;
[0041] taking a candidate task corresponding to a total energy demand greater than the remaining energy as a first task, and obtaining a task priority of the first task;
[0042] The task scores of the first tasks are calculated according to the task priorities and the total energy demand, and the first task with the highest task score is used as the reallocated task.
[0043] The present application also provides a terminal device, including:
[0044] one or more processors;
[0045] a memory, coupled to the processor, for storing one or more programs;
[0046] When the one or more programs are executed by the one or more processors, the one or more processors implement a dynamic task allocation method for multiple UAVs as described in the above-mentioned embodiment of the invention.
[0047] The present application also provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the method for dynamic task allocation of multiple drones as described in the above-mentioned embodiment of the invention is implemented.
[0048] The following beneficial effects are achieved by implementing the present invention:
[0049] The present invention provides a method, apparatus, terminal device, and storage medium for dynamic task allocation of multiple unmanned aerial vehicles (UAVs). The method monitors the task execution status of each UAV. When a target UAV is monitored to have completed its last target pending task, the method determines the remaining energy of the target UAV. When it is determined that the remaining energy is greater than the target flight energy demand required for the target UAV to fly to a preset target destination airport, the method determines that the target UAV may be able to complete the pending tasks of other UAVs. Referring to the rules for hitchhiking, the pending tasks of other UAVs are obtained as candidate tasks. The flight energy demand and candidate task energy demand required for the target UAV to perform the candidate task are further calculated. Then, a candidate task that can be performed by the target UAV is determined as a reallocated task. Finally, the reallocated task is added to the target UAV's target task queue, and the target candidate path corresponding to the reallocated task is sent to the target UAV. It can be understood that this reallocated task is also the last target pending task of the current target UAV. Therefore, after completing the reallocated task, the target UAV will be re-evaluated to see whether it can continue to complete other pending tasks, so as to maximize the utilization rate of the UAV and the task completion efficiency, thereby solving the problem of low utilization rate and task completion efficiency of current UAVs. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] In order to more clearly illustrate the technical solution of the present application, the following is a brief introduction to the drawings required for use in the implementation. Obviously, the drawings described below are only some implementation methods of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0051] Figure 1 This is a flowchart of a method for dynamic task allocation of multiple drones provided in one embodiment of the present application;
[0052] Figure 2 This is a structural diagram of a dynamic task allocation device for multiple UAVs provided in one embodiment of the present application;
[0053] Figure 3 This is a schematic diagram of the structure of a terminal device provided in one embodiment of the present application;
[0054] Figure 4 This is a simplified topological map of distributed airports and mission locations provided in a certain embodiment of the present application. DETAILED DESCRIPTION
[0055] To make the objectives, technical solutions, and advantages of this application more clear, the technical solutions in this application will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of this application.
[0056] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this application belongs; the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the terms "including" and "having" and any variations thereof in the specification and claims of this application and the above-mentioned figure descriptions are intended to cover non-exclusive inclusions.
[0057] In the description of the embodiments of this application, the technical terms "first" and "second" are used only to distinguish different objects and should not be understood to indicate or imply relative importance or implicitly specify the quantity, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, the meaning of "plurality" is more than two, unless otherwise clearly and specifically defined.
[0058] References herein to "embodiments" mean that a particular feature, structure, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present application. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute an independent or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0059] In the description of the embodiments of this application, the term "and / or" is simply a description of the association relationship between associated objects, indicating that three relationships can exist. For example, A and / or B can represent the following three situations: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this document generally indicates that the associated objects are in an "or" relationship.
[0060] In the description of the embodiments of the present application, the term "multiple" refers to more than two (including two). Similarly, "multiple groups" refers to more than two groups (including two groups), and "multiple pieces" refers to more than two pieces (including two pieces).
[0061] In the description of the embodiments of the present application, unless otherwise expressly specified or limited, technical terms such as "installed," "connected," "connected," and "fixed" should be understood in a broad sense. For example, they can refer to fixed connections, detachable connections, or integration; mechanical connections or electrical connections; direct connections or indirect connections through an intermediate medium; internal connections between two components or interactions between two components. Those skilled in the art can understand the specific meanings of the above terms in the embodiments of the present application based on specific circumstances.
[0062] See also Figure 1 To solve the problems in the prior art, an embodiment of the present invention provides a method for dynamic task allocation of multiple UAVs, including:
[0063] S1. Obtaining a task queue of each UAV consisting of a plurality of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed;
[0064] In a preferred embodiment of the present invention, the tasks to be executed that are initially assigned in the drone task queue and the task energy requirements for completing each task to be executed are obtained, wherein the energy requirement is the power of the drone. Furthermore, the task energy requirement is evaluated based on the time required to complete the task, the function to be activated, and the performance parameters of the required application. For example, in a cruising operation scenario, the power consumed by the drone to activate the camera and radar detector is different due to different light conditions.
[0065] Preferably, the step of obtaining a task queue of each drone consisting of a plurality of tasks to be executed includes:
[0066] S11, obtaining the mission locations of several missions to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone;
[0067] S12. Clustering the tasks to be executed based on the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones;
[0068] S13. Based on the initial energy and task pre-grouping of the plurality of UAVs, task allocation and path planning are performed with the goal of minimizing the flight path of each UAV, thereby generating a task queue for each UAV and planning a flight path.
[0069] In a preferred embodiment of the present invention, in order to improve the energy utilization rate of the drone as much as possible, that is, to use energy as much as possible to perform tasks rather than to transfer task locations, this embodiment clusters the tasks to be performed according to the distributed airports and task locations where the drones are initially parked.
[0070] Specifically, such as Figure 4 As shown in the figure, there are four distributed airports. Clustering reveals two mission points near Airport 1, one mission point near Airport 2, two missions near Airport 3, and seven missions near Airport 4. In this scenario, two drones are charging at Airport 1 and Airport 2, respectively. Based on task balance, we create Airport Group 1 (Airport 1 + Airport 2 + Airport 3) and Airport Group 2 (Airport 4). Therefore, Drone 1 is assigned to Airport Group 1 and performs the missions for Airports 1-3 within Airport Group 1. Drone 2 is assigned to Airport Group 2 and performs the missions for Airport 4.
[0071] Furthermore, the method of performing task allocation and path planning based on the initial energy and task pre-grouping of the plurality of drones with the goal of minimizing the flight path of each drone, generating a task queue for each drone and planning a flight path, includes:
[0072] The tasks are pre-grouped as initial task queues for corresponding UAVs, and path planning is performed with the goal of minimizing flight paths based on the initial energy sources of the UAVs and the initial task queues, to generate initial paths for each UAV to execute the initial task queues;
[0073] Traversing the drones, taking the currently traversed drone as a third drone, and determining whether there are any pending tasks for other drones on the initial path of the third drone;
[0074] When it is determined that there are pending tasks of other drones on the initial path of the third drone, the pending tasks of the other drones are used as the tasks that can be taken by the currently traversed drone, and the drone corresponding to the task that can be taken is used as the fourth drone;
[0075] Using a game algorithm, based on the initial paths of the third and fourth drones, multiple factors such as road conflicts, distance, and task priority are evaluated to determine whether the preemptible task can be assigned to the third drone, and the final planned flight path is generated.
[0076] Specifically, refer to Figure 4To improve the drone's energy efficiency, we refer to the ride-sharing logic to reduce idle drone travel. Initially, under the constraints of the drone's initial energy, based on the tasks within Airport Group 1, we obtain a preliminary path for Drone 1: "Airport 1 - Task 2 - Task 3 - Airport 2." This means that Drone 1's initial energy is insufficient to complete all tasks within Airport Group 1. Similarly, assigning tasks from Airport Group 2 to Drone 2 results in an initial path of "Airport 2 - Task 4 - Task 5 - Airport 4." Drone 2 ultimately lands at Airport 4.
[0077] Similarly, according to the ride-sharing model, Task 3 will be along the way when UAV 2 is flying to Airport 4. Therefore, through the grabbing order model, UAV 2 grabs Task 3 to carry out the operation. Therefore, the task allocation is readjusted to obtain UAV 1's flight path as "Airport 1-Task 2-Airport 2", and UAV 2's flight path as "Airport 2-Task 3-Task 4-Task 5-Airport 4". According to the UAV's endurance, UAV 1 can pick up Task 1 and carry out the operation, but UAV 2's battery is insufficient to carry out Task 5. Therefore, according to the task priority and the UAV's endurance, when the priority of Task 3 is greater than the priority of Task 5, the planned flight path of UAV 1 is readjusted to "Airport 1-Task 2-Task 1-Airport 2", and the planned flight path of UAV 2 is "Airport 2-Task 3-Task 4-Airport 4".
[0078] S2. During the UAV mission execution process, when a target UAV is detected to have completed the last target mission to be executed, determining the remaining energy of the target UAV;
[0079] In a preferred embodiment of the present invention, when the target UAV arrives at the task location of the last target task to be performed in its own task queue, it can be determined that the target UAV is performing the last target task to be performed. At this time, real-time monitoring of the target UAV is started. When it is determined that the target UAV has completed the last target task to be performed, the remaining energy of the target UAV is determined.
[0080] S3. When it is determined that the remaining energy is greater than the target flight energy requirement for the target UAV to fly to the preset target destination airport, the pending tasks of several UAVs other than the target UAV are selected as candidate tasks;
[0081] In a preferred embodiment of the present invention, when it is determined that the remaining energy is greater than the target flight energy requirement required for the target UAV to fly to the preset target destination airport, the target UAV's energy is not exhausted when flying back to the target destination airport. In order to maximize the energy utilization rate and overall mission completion efficiency of the target UAV, the pending tasks of other UAVs are obtained as candidate tasks to determine whether the target UAV can assist other UAVs in completing the tasks.
[0082] S4. Generating candidate routes for each candidate task and determining candidate flight energy requirements for each candidate route based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport location of the target destination airport;
[0083] In a preferred embodiment of the present invention, after obtaining the pending tasks of other UAVs as candidate tasks, the target mission location of the target pending mission where the target UAV is currently located is used as the starting point, the target destination airport is used as the end point, and the candidate mission locations of each candidate task are used as waypoints in sequence to perform path planning, generate candidate paths for each candidate task, and determine the candidate flight energy requirements for each candidate path.
[0084] S5. Determine a candidate task that can be performed by the target UAV as a reallocated task based on the remaining energy, the candidate flight energy requirements required by each candidate path, and the candidate task energy requirements of the candidate tasks;
[0085] Preferably, determining a candidate task that can be performed by the target UAV as the reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks includes:
[0086] S51, calculating the total energy requirement of each candidate task according to the candidate flight energy requirement required by each candidate path and the candidate task energy requirement of the candidate task;
[0087] S52: selecting a candidate task corresponding to a total energy demand greater than the remaining energy as a first task;
[0088] S53 , calculating the task scores of the first tasks according to the preset task priorities and total energy requirements of the first tasks, and taking the first task with the highest task score as the reallocated task.
[0089] In a preferred embodiment of the present invention, the total energy demand consumed by the UAV to complete each candidate task is calculated based on the candidate flight energy demand required for each candidate path and the candidate task energy demand of the candidate task; the first task that the candidate task target UAV is capable of performing corresponds to the total energy demand that is greater than the remaining energy.
[0090] In the case where there are multiple first tasks, the task score of each first task is calculated in a weighted manner according to the preset task priority and total energy demand of the first tasks. Specifically, a candidate task with a greater total energy demand and a higher priority is assigned a higher task score to maximize the energy utilization of the target UAV.
[0091] S6. Add the reallocated task to the target task queue of the target UAV, and send the target candidate path corresponding to the reallocated task to the target UAV, so that the target UAV performs the reallocated task.
[0092] Preferably, after sending the target candidate path corresponding to the reallocated task to the target UAV, the method further includes:
[0093] S61: Obtain the first UAV originally corresponding to the reallocated task and the real-time location of the first UAV;
[0094] S62: removing the reallocated task from the first task queue of the first UAV;
[0095] S63: Based on the first task locations of the plurality of pending tasks in the first task queue, the first terminal airport corresponding to the first UAV, and the real-time location, path replanning is performed with the goal of minimizing the sum of the flight paths to generate a replanned flight path for the first UAV.
[0096] In a preferred embodiment of the present invention, since the task queue of the first UAV changes, there is no need to reassign tasks. Therefore, the path of the first UAV is replanned based on the remaining tasks to be executed in the first UAV queue.
[0097] Preferably, the method for dynamic task allocation of multiple UAVs described in any one of the above-mentioned embodiments of the invention further includes:
[0098] S7. Obtaining flight parameters and real-time positions of each of the UAVs;
[0099] S8. Predicting whether each of the UAVs has a collision risk in the future based on the flight parameters, the real-time position, and the flight path of each UAV; wherein the flight path is the planned flight path, the target candidate path, or the replanned flight path;
[0100] S9. When it is determined that there is a collision risk between several second drones at a future time, optimize the flight parameters of each of the second drones with the goal of minimizing the collision risk, generate target flight parameters for each of the second drones, and send the flight parameters to the corresponding second drones.
[0101] In a preferred embodiment of the present invention, the flight parameters include: flight speed and flight altitude. First, a safety sphere is defined for each drone with the safety distance of the drone as the radius. Within a fixed time period, a spline curve fitting trajectory is used to predict the future trajectory of the safety sphere corresponding to the drone based on the flight parameters, the real-time position and the flight path of each drone, and detect whether there is a spatiotemporal overlap of the spheres. Spatiotemporal overlap means that the safety spheres of any two or more drones overlap at the same time. When the conflict model detects that a conflict occurs, the flight parameters of each second drone are optimized with the goal of minimizing the collision risk, and the target flight parameters of each second drone are generated. Specifically, in this embodiment, the following constraints are also followed: tasks with high priority maintain the original trajectory, and tasks with low priority adjust the flight trajectory.
[0102] In summary, this embodiment provides a method for dynamic task allocation for multiple drones. By monitoring the task execution status of each drone, when a target drone is detected executing the last target pending task, the method determines the remaining energy of the target drone after completing the target pending task based on the target task energy requirement of the target pending task. If the remaining energy is determined to be greater than the target flight energy requirement required for the target drone to fly to a preset target destination airport, it can be determined that the target drone may be able to complete the pending tasks of other drones. The method then further calculates the flight energy requirement and candidate task energy requirement required for the target drone to execute the candidate task, and then determines a candidate task that the target drone can execute as a reallocated task. Finally, the reallocated task is added to the target drone's target task queue, and the target candidate path corresponding to the reallocated task is sent to the target drone. It can be understood that this reallocated task serves as the last target pending task for the target drone. Therefore, after executing this reallocated task, it will be re-evaluated whether it can continue to complete the pending tasks, thereby maximizing drone utilization and task completion efficiency, thereby solving the current problem of low drone utilization and task completion efficiency.
[0103] See Figure 2 , is a multi-UAV dynamic task allocation device provided by one embodiment of the present invention, comprising:
[0104] A task data acquisition module is used to obtain a task queue of each UAV consisting of a number of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed;
[0105] The UAV monitoring module is used to monitor a target UAV when it completes the last target to be executed task during the UAV mission execution process and determine the remaining energy of the target UAV;
[0106] a candidate task determination module, configured to, when determining that the remaining energy is greater than a target flight energy requirement for the target UAV to fly to a preset target destination airport, select the pending tasks of several UAVs other than the target UAV as candidate tasks;
[0107] a candidate path planning module, configured to generate candidate paths for each candidate task and determine candidate flight energy requirements for each candidate path based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport locations of the target destination airports;
[0108] a candidate task evaluation module, configured to determine a candidate task that can be performed by the target UAV as a reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks;
[0109] The task reallocation module is used to add the reallocated task to the target task queue of the target UAV and send the target candidate path corresponding to the reallocated task to the target UAV so that the target UAV executes the reallocated task.
[0110] Furthermore, the task data acquisition module acquires a task queue of each drone consisting of a number of tasks to be executed, including:
[0111] Obtaining several mission locations to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone;
[0112] Clustering the tasks to be executed according to the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones;
[0113] According to the initial energy and task pre-grouping of several UAVs, task allocation and path planning are carried out with the goal of minimizing the flight path of each UAV, and a task queue and planned flight path for each UAV are generated.
[0114] Furthermore, the candidate task evaluation module determines a candidate task that can be performed by the target UAV as the reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks, including:
[0115] Calculating the total energy requirement of each candidate task according to the candidate flight energy requirements required by each candidate path and the candidate task energy requirements of the candidate task;
[0116] taking a candidate task corresponding to a total energy demand greater than the remaining energy as a first task, and obtaining a task priority of the first task;
[0117] The task scores of the first tasks are calculated according to the task priorities and the total energy demand, and the first task with the highest task score is used as the reallocated task.
[0118] See also Figure 3 , an embodiment of the present application further provides a terminal device, including:
[0119] one or more processors;
[0120] a memory, coupled to the processor, for storing one or more programs;
[0121] When the one or more programs are executed by the one or more processors, the one or more processors implement the dynamic task allocation method for multiple UAVs as described above.
[0122] The processor is used to control the overall operation of the terminal device to complete all or part of the steps of the above-mentioned method for dynamic task allocation for multiple drones. The memory is used to store various types of data to support the operation of the terminal device. This data may include, for example, instructions for any application or method operating on the terminal device, as well as application-related data. The memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0123] In an exemplary embodiment, the terminal device can be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to execute a dynamic task allocation method for multiple UAVs as described in any of the above embodiments, and achieve the same technical effect as the above method.
[0124] In another exemplary embodiment, a computer-readable storage medium including a computer program is further provided. When executed by a processor, the computer program implements the steps of the method for dynamic task allocation for multiple unmanned aerial vehicles described in any of the aforementioned embodiments. For example, the computer-readable storage medium may be the aforementioned memory including the computer program. The computer program may be executed by a processor of a terminal device to implement the method for dynamic task allocation for multiple unmanned aerial vehicles described in any of the aforementioned embodiments, thereby achieving the same technical effects as the aforementioned methods.
[0125] The above is a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A method for dynamic task allocation of multiple UAVs, characterized in that: include: Obtaining a task queue of each UAV consisting of a plurality of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed; During the UAV mission, when a target UAV is detected to have completed the last target mission to be performed, the remaining energy of the target UAV is determined; When it is determined that the remaining energy is greater than the target flight energy requirement required for the target UAV to fly to the preset target destination airport, the pending tasks of several UAVs other than the target UAV are selected as candidate tasks; generating candidate routes for each candidate task and determining candidate flight energy requirements for each candidate route based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport location of the target destination airport; determining, based on the remaining energy, the candidate flight energy requirements of the candidate paths, and the candidate task energy requirements of the candidate tasks, a candidate task that can be performed by the target UAV as a reallocated task; The reallocated task is added to the target task queue of the target UAV, and the target candidate path corresponding to the reallocated task is sent to the target UAV, so that the target UAV performs the reallocated task.
2. The method for dynamic task allocation of multiple UAVs according to claim 1, wherein: The step of obtaining a task queue of each drone consisting of a plurality of tasks to be executed includes: Obtaining several mission locations to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone; Clustering the tasks to be executed according to the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones; According to the initial energy and task pre-grouping of several UAVs, task allocation and path planning are carried out with the goal of minimizing the flight path of each UAV, and a task queue and planned flight path for each UAV are generated.
3. The method for dynamic task allocation of multiple UAVs according to claim 2, wherein: The determining, based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks, a candidate task that can be performed by the target UAV as the reallocated task includes: Calculating the total energy requirement of each candidate task according to the candidate flight energy requirements required by each candidate path and the candidate task energy requirements of the candidate task; taking a candidate task corresponding to a total energy demand greater than the remaining energy as a first task, and obtaining a task priority of the first task; The task scores of the first tasks are calculated according to the task priorities and the total energy demand, and the first task with the highest task score is used as the reallocated task.
4. The method for dynamic task allocation of multiple UAVs according to claim 3, wherein: After sending the target candidate path corresponding to the reallocated task to the target UAV, the method further includes: Obtaining the first UAV originally corresponding to the reallocated task and the real-time location of the first UAV; removing the reallocated task from the first task queue of the first UAV; Based on the first task locations of the plurality of tasks to be executed in the first task queue, the first terminal airport corresponding to the first UAV, and the real-time location, path replanning is performed with the goal of minimizing the sum of the flight paths to generate a replanned flight path for the first UAV.
5. The method for dynamic task allocation of multiple UAVs according to claim 4, wherein: Also includes: Obtaining flight parameters and real-time locations of each of the drones; Predicting whether each of the UAVs has a collision risk in the future based on the flight parameters, the real-time position, and the flight path of each UAV; wherein the flight path is the planned flight path, the target candidate path, or the replanned flight path; When it is determined that there is a collision risk between several second drones at a future moment, the flight parameters of each of the second drones are optimized with the goal of minimizing the collision risk, target flight parameters of each of the second drones are generated, and the flight parameters are sent to the corresponding second drones.
6. A dynamic task allocation device for multiple drones, characterized in that: include: A task data acquisition module is used to obtain a task queue of each UAV consisting of a number of tasks to be performed and a task energy requirement required to complete each of the tasks to be performed; The UAV monitoring module is used to monitor a target UAV when it completes the last target to be executed task during the UAV mission execution process and determine the remaining energy of the target UAV; a candidate task determination module, configured to, when determining that the remaining energy is greater than a target flight energy requirement for the target UAV to fly to a preset target destination airport, select the pending tasks of several UAVs other than the target UAV as candidate tasks; a candidate path planning module, configured to generate candidate paths for each candidate task and determine candidate flight energy requirements for each candidate path based on the candidate task locations of the candidate tasks, the target task locations of the target to-be-performed tasks, and the airport locations of the target destination airports; a candidate task evaluation module, configured to determine a candidate task that can be performed by the target UAV as a reallocated task based on the remaining energy, the candidate flight energy requirements required by each of the candidate paths, and the candidate task energy requirements of the candidate tasks; The task reallocation module is used to add the reallocated task to the target task queue of the target UAV and send the target candidate path corresponding to the reallocated task to the target UAV so that the target UAV executes the reallocated task.
7. The multi-UAV dynamic task allocation device according to claim 6, characterized in that: The task data acquisition module acquires a task queue of each UAV consisting of a number of tasks to be executed, including: Obtaining several mission locations to be executed, the airport locations of several distributed airports where drones are parked, and the initial energy of each drone; Clustering the tasks to be executed according to the distances between the task locations and the respective airport locations, and generating task pre-groups corresponding to the respective drones; According to the initial energy and task pre-grouping of several UAVs, task allocation and path planning are carried out with the goal of minimizing the flight path of each UAV, and a task queue and planned flight path for each UAV are generated.
8. The multi-UAV dynamic task allocation device according to claim 7, characterized in that: The candidate task evaluation module determines a candidate task that can be performed by the target UAV as a reallocated task based on the remaining energy, the candidate flight energy requirements required by each candidate path, and the candidate task energy requirements of the candidate task, including: Calculating the total energy requirement of each candidate task according to the candidate flight energy requirements required by each candidate path and the candidate task energy requirements of the candidate task; taking a candidate task corresponding to a total energy demand greater than the remaining energy as a first task, and obtaining a task priority of the first task; The task scores of the first tasks are calculated according to the task priorities and the total energy demand, and the first task with the highest task score is used as the reallocated task.
9. A terminal device, characterized in that: include: one or more processors; a memory, coupled to the processor, for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the dynamic task allocation method for multiple UAVs as described in any one of claims 1 to 5.
10. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for dynamic task allocation of multiple UAVs as described in any one of claims 1 to 5 is implemented.