Automatic dispatching method and system of drones based on logistics cabinets
By assigning a limited execution time period to each task, and combining tree search and particle swarm iterative search, the long completion time problem under the conflict of drone docking schemes is solved, and the rapid acquisition of efficient drone planning schemes is achieved and distribution efficiency is improved.
Patent Information
- Application Number
- CN202211391347.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-08
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2042-11-08
AI Technical Summary
In the prior art, the maximum completion time of feasible planning schemes obtained is longer considering that there is no conflict in the drone docking scheme.
By assigning a limited execution time period to each task in the distribution task set, and combining tree search and particle swarm iterative search methods, each drone's flight plan is planned one by one, and the release time and deadline of each task are updated to find the planning plan with the smallest completion time.
Quickly obtaining the planning scheme with the smallest completion time reduces the time and calculation cost of obtaining the planning scheme and improves the delivery efficiency of drones.
Smart Images

Figure CN115689226B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of drone dispatching, and in particular to a method and system for automatic dispatching of drones based on logistics cabinets. Background Art
[0002] With the continuous advancement of science and technology, particularly the widespread adoption of technologies like 5G communications, and the rapidly increasing demand for package delivery, the application of drones in the logistics industry continues to grow. Drone delivery offers advantages such as speed, safety, low cost, and flexible scheduling, and can fill the gaps in traditional air transport capacity. Therefore, the coordinated delivery of packages using drones and logistics lockers is an inevitable trend in the future of the logistics industry, offering high practical value and broad application prospects. Several companies have already successfully applied this model to urban express delivery, food delivery, and other transportation scenarios.
[0003] With the rapid growth in user demand for package delivery, users are becoming more demanding. Timeliness is one of the most common user requirements. Given a given batch of package deliveries, and with limited drone and logistics locker resources, the planning process for each drone must ensure that each drone completes all tasks in the shortest possible time, while also ensuring that there are no conflicts between drones' docking plans.
[0004] However, when considering that there is no conflict in the UAV's docking plan, the existing method obtains a long maximum completion time for the feasible planning plan. Summary of the Invention
[0005] (1) Technical problems solved
[0006] In response to the shortcomings of the existing technology, this application provides a method and system for automatic scheduling of drones based on logistics cabinets to solve the problem that the maximum completion time of feasible planning schemes obtained by existing methods in the existing technology is long when there is no conflict in the docking plans of drones.
[0007] (2) Technical solution
[0008] To achieve the above objectives, this application is implemented through the following technical solutions:
[0009] In a first aspect of the present application, a method for automatic dispatching of drones based on logistics cabinets is provided, the method comprising:
[0010] S1. Obtain initial scheduling information;
[0011] S2, initialize the restricted period set group P; wherein, the restricted period set group P is represented by N PA task restriction execution time period set group is composed of a set of restriction time periods. p b represents the bth restricted time period set;
[0012] S3. Copy the restricted period set group P to obtain the copied restricted period set group P′, and create a new restricted period set p B ; Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B ;
[0013] S4, iterate; wherein, the number of iterations is initialized to i=1;
[0014] S5. Traverse the restricted period set group P; wherein, initialize the restricted period set index b=1;
[0015] S6. Determine b≤N P Is it established? If so, go to S7; otherwise, go to S12;
[0016] S7, based on the restricted period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ;
[0017] S8, judge O b ′≤O b Is it established? If so, go to S10; if not, go to S9; b ′ represents p b ′The maximum completion time of the corresponding planning scheme;
[0018] S9, update p b ′=p b ;
[0019] S10, judgment O B ≤O b Is it true? If so, update b=b+1 and go to S6; if not, go to S11;
[0020] S11. Update p B =p b , update b=b+1, go to S6;
[0021] S12, update the number of iterations i = i + 1, determine whether i ≤ NI is true, if so, go to S13; otherwise go to S14; where N I Indicates the maximum number of iterations;
[0022] S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, and go to S5;
[0023] S14, output p B Corresponding planning scheme.
[0024] Optionally, the parameters of the initialization restricted period set group P in S2 include:
[0025] S201, initialize b=1;
[0026] S202. Judgment b≤N P Is it established? If so, go to S203; otherwise, go to S3;
[0027] S203, initialize p b The release time of each task is 0 and the deadline is A;
[0028] S204, initialization improvement amplitude boundary
[0029] S205, initialization Randomly generate N T between [0, M S ] period, as the improvement of each task’s release time; Indicates p b The set of improvement magnitudes of task release time in the middle task;
[0030] S206, initialization Randomly generate N T between [0, M S ] period as the improvement corresponding to the deadline of each task; Indicates p b The set of improvement magnitudes of task deadlines;
[0031] S207. Update b=b+1, and go to S202.
[0032] Optionally, the S7 is based on the restricted period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ,include:
[0033] S701. Obtaining a restricted time period set p b, initial scheduling information; wherein, the initial scheduling information includes: delivery task set T, logistics cabinet set L, logistics drone set D and the docking location information of each drone;
[0034] S702: Initialize the set of nodes to be branched C to be an empty set, the planning scheme S to be an empty set, create a search tree R for each drone, and create a conflict time period set F for each logistics cabinet;
[0035] Among them, R j Indicates logistics drone d j The corresponding search tree, 1≤j≤N D , N D represents the number of drones in the logistics drone set D; F k represents the conflict time set of the k-th logistics cabinet, 1≤k≤N L , N L represents the number of logistics cabinets in the logistics cabinet set L;
[0036] S703, traverse the drones; wherein, initialize the drone number j=1;
[0037] S704, determine j≤N D Is it established? If so, go to S705; otherwise, go to S714;
[0038] S705, set up the drone j The initial docked logistics cabinet is the root node, and a search tree R is created. j , add the root node to R j ; Among them, d j The take-off time of the initial docked logistics cabinet is 0;
[0039] S706, adding the root node to the set of nodes to be branched C;
[0040] S707, determine the search tree R j Is the number of nodes greater than N? R If yes, go to S710; otherwise go to S708;
[0041] S708, determine whether the set of nodes to be branched C is an empty set, if so, go to S710; otherwise, go to S709;
[0042] S709, branch the first node F in the branch node set C, and go to S707; S710, calculate d j In the search tree R j The docking time period on the logistics cabinet corresponding to each node is set as d j The final stopover time for the logistics cabinet is A;
[0043] S711. Calculate search tree R j The effective delivery time ratio of each node above; where the effective delivery time ratio represents the ratio of the time consumed by the actual delivery task to the time consumed to complete the entire delivery plan for a given drone planning plan;
[0044] S712, select the node with the largest effective delivery time ratio, according to the search tree R j The branch from the root node to this node is converted to obtain drone d j Planning Scheme S j , S j Add to planning scheme S;
[0045] S713, S j The non-virtual tasks contained in S are deleted from the task set T. j The corresponding drone d j The docking period of each logistics cabinet is added to the conflict period set of the corresponding logistics cabinet, the set of nodes to be branched C is cleared, j=j+1 is updated, and the process goes to S704;
[0046] S714, output planning scheme S;
[0047] S715. Calculate the maximum completion time O of the planning scheme S. b , determine whether all tasks in the task set T are executed in the planning scheme, if so, go to S8; otherwise, go to S716;
[0048] S716: At the maximum completion time O b A preset time period H is added to the task set T so that all tasks in the planning scheme are executed.
[0049] Optionally, branching the first node F in the set of nodes to be branched C in S709 includes:
[0050] S70901. Obtain the restricted time period set p b , search tree R j , set of nodes to be branched C, set of nodes to be branched F, set of tasks T, set of logistics cabinets L, and set of logistics drones D;
[0051] S70902, traverse the logistics cabinet set L; wherein, initialize the logistics cabinet number k=1;
[0052] S70903, judge k≤N L Is it true? If so, go to S70904; otherwise, go to S70922;
[0053] S70904: Determine whether the logistics cabinet is the one corresponding to the branch node F. If so, update k=k+1 and go to S70903; otherwise, go to S70905.
[0054] S70905、Computing UAV d j After docking at the logistics cabinet corresponding to node F, the time E required to complete the previous task is C ;
[0055] S70906: Determine whether there is a logistics cabinet corresponding to node F in the task set T. k If the task at the end point exists, go to S70907; otherwise, go to S70916.
[0056] S70907. Determine whether the task is included in the branch from the root node to node F. If so, go to S70916; otherwise, go to S70908.
[0057] S70908, Judgment Is it true? If so, go to S70909; otherwise, go to S70910. Indicates p b The release time of the jth task is corresponding to
[0058] S70909, command the drone to j The take-off time on the logistics cabinet corresponding to node F Transfer S70911; among them, Indicates drone d j Time of loading of cargo;
[0059] S70910, Update UAV d j The take-off time on the logistics cabinet corresponding to node F
[0060] S70911, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M 、Drone arrives at the logistics cabinet k Time E L ;
[0061] S70912, judge E M ≤E L Is it true? If so, go to S70914; otherwise, go to S70913;
[0062] S70913, Update E L =E M , according to E L Backpropagation and update of drone dj Take-off time E on the logistics cabinet corresponding to node F T ;
[0063] S70914, judgment Is it true? If so, go to S70915; otherwise, go to S70916; Indicates drone d j Time of unloading of cargo;
[0064] S70915, based on logistics cabinet l k , create a child node connected to node F, add the child node to the set of nodes to be branched, update k=k+1, and go to S70903;
[0065] S70916, determine whether node F is the root node and R j The task completed by node F is a virtual task. If so, update k=k+1 and go to S70903; otherwise, go to S70917;
[0066] S70917, create a virtual task; wherein the starting point of the virtual task is the logistics cabinet corresponding to node F, and the end point is the logistics cabinet l k , and set the drone d j The time for loading and unloading cargo when executing this task is 0;
[0067] S70918, command drone d j Departure time E T =E C ;
[0068] S70919, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M , and drones arriving at the logistics cabinet l k Time E L ;
[0069] S70920, judgment E M ≤E L Is it true? If so, go to S70915; otherwise, go to S70921;
[0070] S70921, Update E L =E M , and according to E L Backpropagation and update of drone d j Take-off time E on the logistics cabinet corresponding to node F T , transfer to S70915;
[0071] S70922. Delete node F from the set of nodes to be branched C.
[0072] S70923, output search tree R j .
[0073] Optionally, in S13, the task release and deadline of each restricted time period set in the restricted time period set group P are updated, and the process proceeds to S5, including:
[0074] S1301, update time improvement range boundary
[0075] S1302, update the time improvement range to obtain the updated and in, Indicates p b The improvement of the release time of the jth task in ; Indicates p b The improvement in the deadline of the jth task in ;
[0076] S1303, traverse the restricted period set group P; wherein, initialize the restricted period set index b=1;
[0077] S1304. Judgment b≤N P Is it established? If so, go to S1305; otherwise, go to S5;
[0078] S1305, traverse p b The task in the task limit execution time period; wherein, initialization j=1;
[0079] S1306, determine j≤N T Is it established? If so, go to S1307; if not, go to S1310;
[0080] S1307, update p b The release time of the jth task in
[0081] S1308, update p b The deadline for the jth task in
[0082] S1309, update j=j+1, and go to S1306;
[0083] S1310 , update b=b+1, and go to S1304 .
[0084] Optionally, in S1302, the time improvement amplitude is updated to obtain the updated and include:
[0085] S130201, traverse the restricted time period set group P; wherein, initialize the restricted time period set index b=1;
[0086] S130202, judge b≤N P Is it established? If so, go to S130203; otherwise, go to S130213;
[0087] S130203, traverse p b The task in the task limit execution time period; wherein, initialize j = 1; S130204, judge j ≤ N T Is it established? If so, go to S130205; otherwise, go to S130212;
[0088] S130205, randomly generate decimals r1 and r2, and update p based on formula 1 b The improvement of the release time of the jth task in
[0089] Wherein, r1 and r2 are between (0, 1); the formula 1 is:
[0090]
[0091] S130206, Judgment Is it true? If so, go to S130207, otherwise update
[0092] S130207, Judgment Is it true? If so, go to S130208, otherwise update
[0093] S130208, randomly generate decimals r3 and r4, and update p based on formula 2 b The improvement in the deadline of the jth task in
[0094] Wherein, the decimals r3 and r4 are between (0, 1); the formula 2 is:
[0095]
[0096] S130209, Judgment Is it true? If so, go to S1302010; otherwise, update
[0097] S130210, Judgment Is it true? If so, go to S130211; otherwise, update
[0098] S130211, update j=j+1, and go to step S130204;
[0099] S130212, update b=b+1, go to S130202;
[0100] S130213, output updated and
[0101] In a second aspect of the present application, a drone automatic dispatching system based on a logistics cabinet is provided, the system comprising:
[0102] A first acquisition module is used to execute S1 and obtain initial scheduling information;
[0103] The first initialization module is used to execute S2, initialize the restricted period set group P; wherein the restricted period set group P represents N P A task restriction execution time period set group is composed of a set of restriction time periods. p b represents the bth restricted time period set;
[0104] The first copy module is used to execute S3, copy the restricted period set group P, obtain the copied restricted period set group P', and create a new restricted period set p B ; Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B ;
[0105] A first iteration module is configured to execute S4 and perform iterations, wherein the number of iterations is initialized to i=1;
[0106] The first traversal module is used to execute S5 and traverse the restricted time period set group P; wherein the restricted time period set index b is initialized to 1;
[0107] The first judgment module is used to execute S6 and judge whether b≤N P If yes, then go to the second acquisition module to execute S7; otherwise, go to the fourth judgment module to execute S12;
[0108] The second acquisition module is used to execute S7, based on the limit period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ;
[0109] The second judgment module is used to execute S8 and judgeb ′≤O b Is it established? If so, go to S10; if not, go to the first update module and execute S9; b ′ represents p b ′The maximum completion time of the corresponding planning scheme;
[0110] The first update module is used to execute S9, update p b ′=p b ;
[0111] The third judgment module is used to execute S10 and judge B ≤O b Is it true? If so, update b=b+1 and go to the first judgment module to execute S6; if not, go to the second update module to execute S11;
[0112] The second update module is used to execute S11 and update p B =p b , update b=b+1, and go to the first judgment module to execute S6;
[0113] The fourth judgment module is used to execute S12, update the number of iterations i=i+1, and judge i≤N I Is it true? If so, go to the third update module to execute S13; otherwise, go to the first output module to execute S14; where N I Indicates the maximum number of iterations;
[0114] The third updating module is used to execute S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, and then transfer to the first traversal module to execute S5;
[0115] The first output module is used to execute S14 and output p B Corresponding planning scheme.
[0116] Optionally, the first initialization module includes:
[0117] A first initialization submodule is used to execute S201 and initialize b=1;
[0118] The first judgment submodule is used to execute S202 and judge whether b≤N P Is it established? If so, go to the second initialization submodule to execute S203; otherwise, go to the first copy module to execute S3;
[0119] The second initialization submodule is used to execute S203, initialize p b The release time of each task is 0 and the deadline is A;
[0120] The third initialization submodule is used to execute S204 and initialize the improvement amplitude boundary.
[0121] The fourth initialization submodule is used to execute S205 and initialize Randomly generate N T between [0, M S ] period, as the improvement of each task’s release time; Indicates p b The set of improvement magnitudes of task release time in the middle task;
[0122] The fifth initialization submodule is used to execute S206 and initialize Randomly generate N T between [0, M S ] as the improvement corresponding to the deadline of each task; Indicates p b The set of improvement magnitudes of task deadlines;
[0123] The first updating submodule is used to execute S207, update b=b+1, and then transfer to the first judging submodule to execute S202.
[0124] In a third aspect of the present application, an electronic device is provided, comprising a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0125] Memory for storing computer programs;
[0126] The processor is used to implement any of the above-mentioned steps of the automatic scheduling method of drones based on logistics cabinets when executing the program stored in the memory.
[0127] In a fourth aspect of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, any of the above-mentioned steps of the automatic scheduling method of drones based on logistics cabinets is implemented.
[0128] (3) Beneficial effects
[0129] This application provides a method and system for automatic dispatching of drones based on logistics cabinets, which has the following beneficial effects compared with the existing technology:
[0130] In the technical solution provided by this application, S1, obtain initial scheduling information; S2, initialize the restricted period set group P; S3, copy the restricted period set group P, obtain the copied restricted period set group P', and create a new restricted period set p B; S4, iterate; S5, traverse the restricted time period set group P; S6, determine b≤N P Is it established? If so, go to S7; otherwise go to S12; S7, based on the restricted time period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ; S8, judge O b ′≤O b Is it true? If so, go to S10; if not, go to S9; S9, update p b ′=p b ; S10, judge O B ≤O b Is it true? If so, update b=b+1 and go to S6; if not, go to S11; S11, update p B =p b , update b = b + 1, go to S6; S12, update the number of iterations i = i + 1, judge i ≤ N I Is it true? If so, go to S13; otherwise go to S14; S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, go to S5; S14, output p B Corresponding planning scheme.
[0131] Based on the above processing, by assigning a restricted execution time period to each task in the delivery task set and planning the flight plan of each drone one by one through the heuristic method of tree search, it is ensured that there are no conflicts in the docking plan of each drone. Then, based on the particle swarm iterative search method, the release time and deadline of each task are updated separately during each iteration to find a restricted execution time period that is more suitable for each task and a corresponding planning scheme with the minimum maximum completion time. Based on the combination of tree search and particle swarm iterative search, the planning scheme with the minimum maximum completion time can be quickly obtained, reducing the time cost and computational cost of obtaining the planning scheme, and effectively shortening the maximum completion time of the obtained planning scheme, greatly improving the quality of the obtained planning scheme and improving the delivery efficiency of the drone. BRIEF DESCRIPTION OF THE DRAWINGS
[0132] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0133] Figure 1 A flowchart of a method for automatic dispatching of drones based on logistics cabinets provided in an embodiment of the present application;
[0134] Figure 2 A flowchart of a tree search based on effective delivery time ratio provided in an embodiment of the present application;
[0135] Figure 3 A branch exploration flow chart based on task execution time limit provided in an embodiment of the present application;
[0136] Figure 4 A flowchart of a calculation task execution time period provided in an embodiment of the present application;
[0137] Figure 5 A structural diagram of a drone automatic dispatching system based on a logistics cabinet provided in an embodiment of the present application;
[0138] Figure 6 A structural diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0139] To make the objectives, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention are clearly and completely described. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without inventive effort are within the scope of protection of the present invention.
[0140] The embodiment of the present application provides a method and system for automatic scheduling of drones based on logistics cabinets, which solves the problem in the prior art that the maximum completion time of feasible planning schemes obtained is long when there is no conflict in the drone's docking scheme. Based on the combination of tree search and particle swarm iterative search, a planning scheme with the shortest maximum completion time can be quickly obtained, which reduces the time cost and computing cost of obtaining the planning scheme, and effectively shortens the maximum completion time of the obtained planning scheme, greatly improving the quality of the obtained planning scheme and improving the delivery efficiency of the drone.
[0141] The technical solution in the embodiments of the present application is to solve the above technical problems, and the overall idea is as follows:
[0142] In a collaborative delivery model involving drones and logistics cabinets, the top of the cabinet serves as a landing platform for drones. Drones can automatically load packages onto the top of the cabinet and then automatically unload them once they reach the designated cabinet. During a delivery mission, drones carry cargo from the origin to the destination, linking the routes between the multiple cabinets they visit in an orderly fashion to form a path. A feasible planning scheme includes a flight path for each drone. Drones need to load and unload cargo and replace batteries at the cabinets. A single cabinet can only accommodate one drone at a time. Overlapping drone docking times at the same cabinet creates a conflict, so feasible planning schemes include drone docking plans at the cabinets.
[0143] In response to users' requirements for timeliness in package delivery, the purpose of this invention is to: for a given batch of tasks, how to arrange the delivery path and detailed docking time period of each drone, without conflicts between drones when docking, and complete the delivery of all packages with the minimum maximum completion time.
[0144] To achieve this, this application assigns a time limit to each task in the delivery task set and plans each drone's flight plan individually using a tree search heuristic. Then, using a particle swarm iterative search approach, each task's release time and deadline are updated during each iteration to find a plan that best suits each task's time limit and minimizes its maximum completion time.
[0145] In order to better understand the above technical solution, the above technical solution will be described in detail below with reference to the accompanying drawings and specific implementation methods.
[0146] The drone and logistics cabinet collaborative delivery method provided in the embodiment of the present application is applied to T delivery tasks N D logistics drones N L Logistics cabinets Instant delivery scenario. Among them, t i represents the i-th delivery task, 1≤i≤N T , d j represents the j-th drone, 1≤j≤N D , l k Represents the kth logistics cabinet, 1≤k≤N L .
[0147] The i-th delivery task t i Corresponding to a delivery logistics cabinet and a receiving logistics cabinet Delivery mission means using logistics drone to deliver the delivery mission t i of packages from its delivery logistics cabinet Delivered to its receiving logistics cabinet
[0148] jth drone d j It can only be docked on the logistics cabinet and cannot be parked on the ground or other places. j Initially docked at the logistics cabinet UAV d j Only one delivery task is carried out at a time, that is, only one delivery package is carried.
[0149] The task release time indicates the time when the task is received. All tasks can only be executed after their corresponding task release time.
[0150] The task deadline indicates the time when the task is set to expire. All tasks must be completed before their corresponding task deadline.
[0151] The task execution limit time period, referred to as the limit period, represents the time period from the task release time to the task deadline time.
[0152] The set of task restricted execution time periods, referred to as restricted time period set, means that the length of the restricted time period of each task is N T dataset.
[0153] The task restricted execution time period group, referred to as the restricted time period group, is composed of N P The set of restricted time periods constitutes a task restricted execution time period set group. p b Represents the bth restricted time period set.
[0154] In addition, in the embodiment provided by the present application, when the particle swarm algorithm is used to update the release time and start time of each task, each task release time and deadline respectively corresponds to a time improvement range. Indicates p b The set of improvement magnitudes of task release time in Indicates p b The improvement of the release time of the jth task in Indicates p b The set of improvement magnitudes of task deadlines in the medium task, Indicates p b The improvement in the deadline of the jth task, and 1≤b≤N P , 1≤j≤N D .
[0155] See also Figure 1 , Figure 1 This is a flow chart of a method for automatically dispatching drones based on logistics cabinets provided in an embodiment of the present application. Figure 1 As shown, the automatic dispatching method of drones includes:
[0156] S1. Obtain initial scheduling information.
[0157] The initial scheduling information includes: the delivery task set T, the logistics cabinet set L, the logistics drone set D, and the docking location information of each drone.
[0158] S2. Initialize the restricted time period set group P.
[0159] Among them, the restricted period group P is represented by N P A task restriction execution time period set group is composed of a set of restriction time periods. p b Represents the bth restricted period set; the task restricted execution time period set represents the time period from the task release time to the task deadline time; the task release time represents the time when the task is received, and the task deadline time represents the time when the task becomes invalid.
[0160] S3. Copy the restricted period set group P to obtain the copied restricted period set group P′, and create a new restricted period set p B .
[0161] Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B .
[0162] S4. Perform iteration; wherein, the number of iterations is initialized to i=1.
[0163] S5. Traverse the restricted period set group P; wherein, initialize the restricted period set index b=1.
[0164] S6. Determine b≤N P Is it true? If so, go to S7; otherwise, go to S12.
[0165] S7, based on the restricted period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b .
[0166] S8, judge O b ′≤Ob Is it established? If so, go to S10; if not, go to S9; b ′ represents p b ′ is the maximum completion time of the corresponding planning scheme.
[0167] S9, update p b ′=p b .
[0168] S10, judgment O B ≤O b Is it true? If so, update b=b+1 and go to S6; if not, go to S11.
[0169] S11. Update p B =p b , update b=b+1, and go to S6.
[0170] S12, update the number of iterations i = i + 1, and determine i ≤ N I Is it true? If so, go to S13; otherwise, go to S14; where N I Indicates the maximum number of iterations.
[0171] S13: Update the task release and deadline of each restricted time period set in the restricted time period set group P, and go to S5.
[0172] S14, output p B Corresponding planning scheme.
[0173] Based on the above processing, by assigning a restricted execution time period to each task in the delivery task set and planning the flight plan of each drone one by one through a tree search heuristic method, it is ensured that there are no conflicts in the docking plan of each drone. Then, based on the particle swarm iterative search method, the release time and deadline of each task are updated separately during each iteration to find a planning scheme with a restricted execution time period that is more suitable for each task and the corresponding minimum maximum completion time. Based on the combination of tree search and particle swarm iterative search, the planning scheme with the minimum maximum completion time can be quickly obtained, reducing the time and computational cost of obtaining the planning scheme, and effectively shortening the maximum completion time of the obtained planning scheme, greatly improving the quality of the obtained planning scheme and improving the delivery efficiency of the drone.
[0174] For step S2, initializing the restricted time period set group P includes:
[0175] S201. Initialize b=1.
[0176] S202. Judgment b≤N P Is it true? If so, go to S203; otherwise, go to S3.
[0177] S203, initialize p b The release time of each task is 0 and the deadline is A.
[0178] S204, initialization improvement amplitude boundary
[0179] S205, initialization Randomly generate N T between [0, M S ] period, as the improvement of each task’s release time; Indicates p b The set of improvement magnitudes of task release time in .
[0180] S206, initialization Randomly generate N T between [0, M S ] as the improvement corresponding to the deadline of each task; Indicates p b A collection of task deadline improvements.
[0181] S207. Update b=b+1, and go to S202.
[0182] For step S203 , the deadline A is a very large value.
[0183] Based on the above process, a restricted execution time period is assigned to each task in the delivery task set. The restricted execution time period consists of two attributes: release time and deadline time.
[0184] For step S3, each restricted period set p in the copied restricted period set group P′ b ′ is used to record the attribute value of the b-th constraint period set in P, which has the smallest maximum completion time among the planning solutions obtained in the iterative process. This attribute value includes the release time and the deadline.
[0185] New restricted period set p B It is used to record the attribute value of the constraint period set with the minimum maximum completion time among all the planning solutions obtained in the constraint period set during the iteration process. Similarly, this attribute value includes the release time and deadline time.
[0186] Furthermore, in step S3, it is obvious that p B The maximum completion time of the planning scheme is O B =A.
[0187] The effective delivery time ratio refers to the ratio of the time consumed in the actual delivery task to the time consumed in completing the entire delivery plan in a given drone planning plan.
[0188] Search Tree R j The effective delivery time ratio of the middle node represents the search tree R j For each node in the , there is only one branch from the root node to the node, and this branch corresponds to the drone d j A planning scheme, the effective delivery time ratio of the planning scheme is the effective delivery time ratio of the node.
[0189] The time period during which the drone stops at the logistics cabinet represents the time from the drone d j Arrival at the logistics cabinet, to the drone d j The time period from the take-off of the logistics cabinet to the end includes three parts: unloading time, detention time, and loading time.
[0190] See also Figure 2 , Figure 2 This is a flowchart of a tree search based on effective delivery time ratio provided in an embodiment of the present application. Figure 2 As shown, in step S7, based on the limit period set p b , initial scheduling information and tree search method to obtain p b The planning scheme includes:
[0191] S701. Obtaining a restricted time period set p b , initial scheduling information.
[0192] S702. Initialize the set of nodes to be branched C as an empty set, the planning scheme S as an empty set, create a search tree R for each drone, and create a conflict period set F for each logistics cabinet.
[0193] Among them, R j Indicates logistics drone d j The corresponding search tree, 1≤j≤N D , N D represents the number of drones in the logistics drone set D; F k represents the conflict time set of the k-th logistics cabinet, 1≤k≤N L , N L Represents the number of logistics cabinets in the logistics cabinet set L.
[0194] S703, traverse the drones; wherein, initialize the drone number j=1.
[0195] S704, determine j≤N D Is it true? If so, go to S705; otherwise, go to S714.
[0196] S705, set up the drone j The initial docked logistics cabinet is the root node, and a search tree R is created. j , add the root node to R j ; Among them, d j The take-off time of the initial docked logistics cabinet is 0.
[0197] S706: Add the root node to the set C of nodes to be branched.
[0198] S707, determine the search tree R j Is the number of nodes greater than N? R If so, go to S710; otherwise, go to S708.
[0199] S708 , determine whether the set of nodes to be branched C is an empty set. If so, go to S710 , otherwise go to S709 .
[0200] S709 , branch the first node F in the set of nodes to be branched C, and go to S707 .
[0201] For details, see Figure 3 , Figure 3 This is a branch exploration flow chart based on task-limited execution time period provided in the embodiment of the present application. Figure 3 As shown, in step S709, branching the first node F in the set of nodes to be branched C includes:
[0202] S70901. Obtain the restricted time period set p b , search tree R j , set of nodes to be branched C, set of nodes to be branched F, set of tasks T, set of logistics cabinets L and set of logistics drones D.
[0203] S70902. Traverse the logistics cabinet set L; wherein, initialize the logistics cabinet number k=1.
[0204] S70903, judge k≤N L Is it true? If so, go to S70904; otherwise, go to S70922.
[0205] S70904. Determine whether the logistics cabinet is the logistics cabinet corresponding to the branch node F. If so, update k=k+1 and go to S70903; otherwise, go to S70905.
[0206] S70905、Computing UAV d j After docking at the logistics cabinet corresponding to node F, the time E required to complete the previous task is C .
[0207] S70906: Determine whether there is a logistics cabinet corresponding to node F in the task set T. k If the task at the end point exists, go to S70907; otherwise, go to S70916.
[0208] S70907. Determine whether the task is included in the branch from the root node to node F. If so, go to S70916; otherwise, go to S70908.
[0209] S70908, Judgment Is it true? If so, go to S70909; otherwise, go to S70910. Indicates p b corresponds to the release time of the jth task.
[0210] S70909, command the drone to j The take-off time on the logistics cabinet corresponding to node F Transfer to S70911. Among them, Indicates drone d j Time to load cargo.
[0211] S70910, Update UAV d j The take-off time on the logistics cabinet corresponding to node F
[0212] S70911, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M 、Drone arrives at the logistics cabinet k Time E L .
[0213] S70912, judge E M ≤E L Is it true? If so, go to S70914; otherwise, go to S70913.
[0214] S70913, Update E L =E M , according to E L Backpropagation and update of drone d j Take-off time E on the logistics cabinet corresponding to node F T .
[0215] S70914, judgment Is it true? If so, go to S70915; otherwise, go to S70916. Indicates drone d j Time of unloading of cargo.
[0216] S70915, based on logistics cabinet l k , create a child node connected to node F, add the child node to the set of nodes to be branched, update k=k+1, and go to S70903.
[0217] S70916, determine whether node F is the root node and R j The task completed by the middle node F is a virtual task. If so, update k=k+1 and go to S70903; otherwise, go to S70917.
[0218] S70917, create a virtual task; wherein the starting point of the virtual task is the logistics cabinet corresponding to node F, and the end point is the logistics cabinet l k , and set the drone d j The time for loading and unloading cargo when performing this task is 0.
[0219] S70918, command drone d j Departure time E T =E C .
[0220] S70919, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M , and drones arriving at the logistics cabinet l k Time E L .
[0221] S70920, judgment E M ≤E L Is it true? If so, go to S70915; otherwise, go to S70921.
[0222] S70921, Update E L =E M , and according to E L Backpropagation and update of drone d j Take-off time E on the logistics cabinet corresponding to node F T , transfer to S70915.
[0223] S70922: Delete node F from the set of nodes to be branched C.
[0224] S70923, output search tree R j .
[0225] Based on the above processing, the process of branching the first node F in the set of nodes to be branched C is completed.
[0226] In addition, in step S709, the process of calculating the take-off time, arrival time and task completion time of the UAV when performing the task can be found in Figure 4 , Figure 4 This is a flow chart of a computing task execution time period provided by an embodiment of the present application. Figure 4 As shown, the steps of calculating the task execution time period include:
[0227] Step a: Initialize the takeoff time to the completion time of the previous task.
[0228] Step b: determine whether the task is a virtual task. If not, go to step c; if yes, go to step f.
[0229] Step c: Determine whether the task has been released based on the task release time. If not, go to step d; if so, go to step e.
[0230] Step d: Update the take-off time to the mission release time.
[0231] Step e: Update the take-off time to the current take-off time plus the cargo loading time.
[0232] Step f: Calculate the time it takes for the UAV to arrive at the mission receiving site.
[0233] Step g: Determine whether the drone can land. If not, go to step h; if yes, go to step k.
[0234] Step h: Update the arrival time of the drone according to the conflict time set of the arrived logistics cabinet.
[0235] Step i: Calculate the completion time of the task = arrival time + cargo unloading time.
[0236] Step j: Backward calculate and update the take-off time of the UAV.
[0237] Step k: Output the take-off time, arrival time, and mission completion time of the UAV performing the mission.
[0238] S710, calculate d j In the search tree R j The docking time period on the logistics cabinet corresponding to each node is set as d j The final stop time for the logistics cabinet is A.
[0239] S711. Calculate search tree R j The effective delivery time ratio of each node above; where the effective delivery time ratio represents the ratio of the time consumed by the actual delivery task to the time consumed to complete the entire delivery plan for a given drone planning plan.
[0240] S712, select the node with the largest effective delivery time ratio, according to the search tree R i The branch from the root node to this node is converted to obtain drone d j Planning Scheme S j , S j Add to planning scheme S.
[0241] S713, S j The non-virtual tasks contained in S are deleted from the task set T. j The corresponding drone d j The docking period on each logistics cabinet is added to the conflict period set of the corresponding logistics cabinet, the set of nodes to be branched C is cleared, j=j+1 is updated, and the process goes to S704.
[0242] S714. Output planning scheme S.
[0243] Furthermore, in step S7, it is determined that p b The maximum completion time O of the planning scheme b ,include:
[0244] S715. Calculate the maximum completion time O of the planning scheme S. b , determine whether all tasks in the task set T are executed in the planning scheme. If so, go to S8; otherwise, go to S716.
[0245] S716: At the maximum completion time O b A preset time period H is added to the task set T so that all tasks in the planning scheme are executed.
[0246] For step S716, the preset time period H is a very long time length so that the maximum completion time O b After adding the preset time period H, all tasks in the task set T are executed in the planning scheme.
[0247] In the embodiment provided in this application, the time from the drone landing on the logistics cabinet to the drone taking off again from the logistics cabinet is called the drone's docking time on the logistics cabinet. It can be seen that the docking time consists of three parts: unloading time, waiting time, and loading time.
[0248] In the examples provided in this application, Indicates p B The release time of the jth task is corresponding to Indicates p B The deadline of the jth task is corresponding to Indicates p b The release time of the jth task is corresponding to Indicates pb The deadline of the jth task is in Indicates p b ′ corresponds to the release time of the jth task; Indicates p b ′ corresponds to the deadline of the jth task.
[0249] Specifically, in step S13, the task release and deadline of each restricted time period set in the restricted time period set group P are updated, and then the process goes to S5, including:
[0250] S1301, update time improvement range boundary
[0251] S1302, update the time improvement range to obtain the updated and in, Indicates p b The improvement of the release time of the jth task in ; Indicates p b The improvement in the deadline of the jth task.
[0252] S1303: traverse the restricted period set group P. Initialize the restricted period set index b=1.
[0253] S1304. Judgment b≤N P Is it true? If so, go to S1305; otherwise, go to S5.
[0254] S1305, traverse p b The tasks in the task limit execution time period. In which, j=1 is initialized.
[0255] S1306, determine j≤N T Is it true? If so, go to S1307; if not, go to S1310.
[0256] S1307, update p b The release time of the jth task in
[0257] S1308, update p b The deadline for the jth task in
[0258] S1309 , update j=j+1, and go to S1306 .
[0259] S1310 , update b=b+1, and go to S1304 .
[0260] In step S1302, the time improvement amplitude is updated to obtain the updated and include:
[0261] S130201. Traverse the restricted time period set group P. Initialize the restricted time period set index b=1.
[0262] S130202, judge b≤N P Is it true? If so, go to S130203; otherwise, go to S130213.
[0263] S130203, traverse p b The tasks in the task limit execution time period. In which, j=1 is initialized.
[0264] S130204. Judgment j≤N T Is it true? If so, go to S130205; otherwise, go to S130212.
[0265] S130205, randomly generate decimals r1 and r2, and update p based on formula 1 b The improvement of the release time of the jth task in
[0266] Wherein, r1 and r2 are located between (0, 1); the formula 1 is.
[0267]
[0268] S130206, Judgment Is it true? If so, go to S130207, otherwise update
[0269] S130207, Judgment Is it true? If so, go to S130208, otherwise update
[0270] S130208, randomly generate decimals r3 and r4, and update p based on formula 2 b The improvement in the deadline of the jth task in
[0271] Wherein, the decimals r3 and r4 are between (0, 1); the formula 2 is:
[0272]
[0273] S130209, Judgment Is it true? If so, go to S1302010; otherwise, update
[0274] S130210, Judgment Is it true? If so, go to S130211, otherwise update
[0275] S130211. Update j=j+1 and go to step S130204.
[0276] S130212. Update b=b+1, and go to S130202.
[0277] S130213, output updated and
[0278] Based on the same inventive concept, the present application also provides a drone and logistics cabinet collaborative delivery device, see Figure 5 , Figure 5 This is a structural diagram of a UAV automatic dispatching system based on a logistics cabinet provided in an embodiment of the present application. Figure 5 As shown, the system includes:
[0279] The first acquisition module 501 is used to execute S1 and obtain initial scheduling information; the initial scheduling information includes: a delivery task set T, a logistics cabinet set L, a logistics drone set D, and the docking location information of each drone.
[0280] The first initialization module 502 is used to execute S2, initialize the restricted period set group P; wherein the restricted period set group P represents the N P A task restriction execution time period set group is composed of a set of restriction time periods. p b represents the bth restricted time period set; the task restricted execution time period set represents the time period from the task release time to the task deadline time; the task release time represents the time when the task is received, and the task deadline time represents the time when the task becomes invalid.
[0281] The first copy module 503 is used to execute S3, copy the restricted period set group P, obtain the copied restricted period set group P', and create a new restricted period set p B ; Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B .
[0282] The first iteration module 504 is configured to execute S4 and perform iteration, wherein the number of iterations i is initialized to 1.
[0283] The first traversal module 505 is configured to execute S5 and traverse the restricted time period set group P. The restricted time period set index b is initialized to 1.
[0284] The first judgment module 506 is used to execute S6 and judge whether b≤N P If so, the process goes to the second obtaining module 507 to execute S7; otherwise, the process goes to the fourth judging module 512 to execute S12.
[0285] The second acquisition module 507 is used to execute S7, based on the limit period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b .
[0286] The second judgment module 508 is used to execute S8 and judge b ′≤O b Is it established? If so, go to S10; if not, go to the first update module 509 to execute S9; b ′ represents p b ′ is the maximum completion time of the corresponding planning scheme.
[0287] The first updating module 509 is used to execute S9, update p b ′=p b .
[0288] The third judgment module 510 is used to execute S10, judge B ≤O b If yes, then update b=b+1 and go to the first judgment module 506 to execute S6; if no, then go to the second updating module 511 to execute S11.
[0289] The second updating module 511 is used to execute S11, update p B =p b , update b=b+1, and go to the first judgment module 506 to execute S6.
[0290] The fourth judgment module 512 is used to execute S12, update the number of iterations i=i+1, and judge i≤N I If yes, then go to the third update module 513 to execute S13; otherwise go to the first output module to execute S14. I Indicates the maximum number of iterations.
[0291] The third updating module 513 is configured to execute S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, and transfer the process to the first traversal module 505 to execute S5.
[0292] The first output module 514 is used to execute S14 and output p B Corresponding planning scheme.
[0293] The present application also provides an electronic device. Figure 6 , Figure 6 This is a structural diagram of an electronic device provided in an embodiment of the present application. Figure 6 As shown, it includes a processor 601, a communication interface 602, a memory 603 and a communication bus 604, wherein the processor 601, the communication interface 602, and the memory 603 communicate with each other through the communication bus 604.
[0294] Memory 603, used for storing computer programs;
[0295] The processor 601 is used to implement any of the above-mentioned logistics cabinet-based drone automatic scheduling methods when executing the program stored in the memory 603.
[0296] In another embodiment provided in the present application, a computer-readable storage medium is also provided, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned methods for automatic scheduling of drones based on logistics cabinets are implemented.
[0297] In another embodiment provided in the present application, a computer program product containing instructions is also provided. When the computer is run on a computer, the computer executes any one of the automatic drone scheduling methods based on logistics cabinets in the above embodiments.
[0298] In summary, compared with the existing technology, the present invention has the following beneficial effects:
[0299] Based on the above processing, by assigning a restricted execution time period to each task in the delivery task set and planning the flight plan of each drone one by one through the heuristic method of tree search, it is ensured that there are no conflicts in the docking plan of each drone. Then, based on the particle swarm iterative search method, the release time and deadline of each task are updated separately during each iteration, so as to find a restricted execution time period that is more suitable for each task and the corresponding planning scheme with the minimum maximum completion time. Based on the combination of tree search and particle swarm iterative search, the planning scheme with the minimum maximum completion time can be quickly obtained, reducing the time and computational cost of obtaining the planning scheme, and effectively shortening the maximum completion time of the obtained planning scheme, greatly improving the quality of the obtained planning scheme and improving the delivery efficiency of the drone.
[0300] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a..." does not exclude the presence of additional identical elements in the process, method, article, or device comprising the element.
[0301] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for automatic dispatching of drones based on logistics cabinets, characterized in that: The method comprises: S1. Obtain initial scheduling information; S2, initialize the restricted period set group P; wherein, the restricted period set group P is represented by N P A task restriction execution time period set group is composed of a set of restriction time periods. p b represents the bth restricted time period set; S3. Copy the restricted period set group P to obtain the copied restricted period set group P′, and create a new restricted period set p B ; Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B ; S4, iterate; wherein, the number of iterations is initialized to i=1; S5. Traverse the restricted period set group P; wherein, initialize the restricted period set index b=1; S6. Determine b≤N P Is it established? If so, go to S7; otherwise, go to S12; S7, based on the restricted period set p b , the initial scheduling information and the tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ; S8, judge O b ′≤O b Is it established? If so, go to S10; if not, go to S9; b ′ represents p b ′The maximum completion time of the corresponding planning scheme; S9, update p b ′=p b ; S10, judgment O B ≤O b Is it true? If so, update b=b+1 and go to S6; if not, go to S11; S11. Update p B =p b , update b=b+1, go to S6; S12, update the number of iterations i = i + 1, and determine i ≤ N I Is it true? If so, go to S13; otherwise, go to S14; where N I Indicates the maximum number of iterations; S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, and go to S5; S14, output p B Corresponding planning scheme.
2. The method according to claim 1, characterized in that The parameters of the initialization restriction period set group P in S2 include: S201, initialize b=1; S202. Judgment b≤N P Is it established? If so, go to S203; otherwise, go to S3; S203, initialize p b The release time of each task is 0 and the deadline is A; S204, initialization improvement amplitude boundary S205, initialization Randomly generate N T between [0, M S ] period, as the improvement of each task’s release time; Indicates p b The set of improvement magnitudes of task release time in the middle task; S206, initialization Randomly generate N T between [0, M S ] period as the improvement corresponding to the deadline of each task; Indicates p b The set of improvement magnitudes of task deadlines; S207. Update b=b+1, and go to S202.
3. The method according to claim 1, characterized in that In S7, based on the restricted time period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ,include: S701. Obtaining a restricted time period set p b , initial scheduling information; wherein, the initial scheduling information includes: delivery task set T, logistics cabinet set L, logistics drone set D and the docking location information of each drone; S702: Initialize the set of nodes to be branched C to be an empty set, the planning scheme S to be an empty set, create a search tree R for each drone, and create a conflict time period set F for each logistics cabinet; Among them, R j Indicates logistics drone d j The corresponding search tree, 1≤j≤N D , N D represents the number of drones in the logistics drone set D; F k represents the conflict time set of the k-th logistics cabinet, 1≤k≤N L , N L represents the number of logistics cabinets in the logistics cabinet set L; S703, traverse the drones; wherein, initialize the drone number j=1; S704, determine j≤N D Is it established? If so, go to S705; otherwise, go to S714; S705, set up the drone j The initial docked logistics cabinet is the root node, and a search tree R is created. j , add the root node to R j ; Among them, d j The take-off time of the initial docked logistics cabinet is 0; S706, adding the root node to the set of nodes to be branched C; S707, determine the search tree R j Is the number of nodes greater than N? R If yes, go to S710; otherwise go to S708; S708, determine whether the set of nodes to be branched C is an empty set, if so, go to S710; otherwise, go to S709; S709: Branch the first node F in the branch node set C, and go to S707; S710, calculate d j In the search tree R j The docking time period on the logistics cabinet corresponding to each node is set as d j The final stopover time for the logistics cabinet is A; S711. Calculate search tree R j The effective delivery time ratio of each node above; where the effective delivery time ratio represents the ratio of the time consumed by the actual delivery task to the time consumed to complete the entire delivery plan in a given drone planning plan; S712, select the node with the largest effective delivery time ratio, according to the search tree R j The branch from the root node to this node is converted to obtain drone d j Planning Scheme S j , S j Add to planning scheme S; S713, S j The non-virtual tasks contained in S are deleted from the task set T. j The corresponding drone d j The docking period of each logistics cabinet is added to the conflict period set of the corresponding logistics cabinet, the set of nodes to be branched C is cleared, j=j+1 is updated, and the process goes to S704; S714, output planning scheme S; S715. Calculate the maximum completion time O of the planning scheme S. b , determine whether all tasks in the task set T are executed in the planning scheme, if so, go to S8; otherwise, go to S716; S716: At the maximum completion time O b A preset time period H is added to the task set T so that all tasks in the planning scheme are executed.
4. The method according to claim 3, characterized in that The step S709 of branching the first node F in the set of nodes to be branched C includes: S70901. Obtain the restricted time period set p b , search tree R j , set of nodes to be branched C, set of nodes to be branched F, set of tasks T, set of logistics cabinets L, and set of logistics drones D; S70902, traverse the logistics cabinet set L; wherein, initialize the logistics cabinet number k=1; S70903, judge k≤N L , is it established? If so, go to S70904; otherwise, go to S70922; S70904: Determine whether the logistics cabinet is the one corresponding to the branch node F. If so, update k=k+1 and go to S70903; otherwise, go to S70905. S70905、Computing UAV d j After docking at the logistics cabinet corresponding to node F, the time E required to complete the previous task is C ; S70906: Determine whether there is a logistics cabinet corresponding to node F in the task set T. k If the task at the end point exists, go to S70907; otherwise, go to S70916. S70907. Determine whether the task is included in the branch from the root node to node F. If so, go to S70916; otherwise, go to S70908. S70908, Judgment Is it true? If so, go to S70909; otherwise, go to S70910. Indicates p b The release time of the jth task is corresponding to S70909, command the drone to j The take-off time on the logistics cabinet corresponding to node F Transfer S70911; among them, Indicates drone d j Time of loading of cargo; S70910, Update UAV d j The take-off time on the logistics cabinet corresponding to node F S70911, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M 、Drone arrives at the logistics cabinet k Time E L ; S70912, judge E M ≤E L Is it true? If so, go to S70914; otherwise, go to S70913; S70913, Update E L =E M , according to E L Backpropagation and update of drone d j Take-off time E on the logistics cabinet corresponding to node F T ; S70914, judgment Is it true? If so, go to S70915; otherwise, go to S70916; Indicates drone d j Time of unloading of cargo; S70915, based on logistics cabinet l k , create a child node connected to node F, add the child node to the set of nodes to be branched, update k=k+1, and go to S70903; S70916, determine whether node F is the root node and R j The task completed by node F is a virtual task. If so, update k=k+1 and go to S70903; otherwise, go to S70917; S70917, create a virtual task; wherein the starting point of the virtual task is the logistics cabinet corresponding to node F, and the end point is the logistics cabinet l k , and set the drone d j The time for loading and unloading cargo when executing this task is 0; S70918, command drone d j Departure time E T =E C ; S70919, computing logistics cabinet l k The latest end time E of all conflicting periods in the conflicting period set M , and drones arriving at the logistics cabinet l k Time E L ; S70920, judgment E M ≤E L Is it true? If so, go to S70915; otherwise, go to S70921; S70921, Update E L =E M , and according to E L Backpropagation and update of drone d j Take-off time E on the logistics cabinet corresponding to node F T , transfer to S70915; S70922. Delete node F from the set of nodes to be branched C. S70923, output search tree R j .
5. The method according to claim 1, wherein In said S13, the task release and deadline of each restricted period set in the restricted period set group P are updated, and then the process proceeds to S5, which includes: S1301, update time improvement range boundary S1302, update the time improvement range to obtain the updated and in, Indicates p b The improvement of the release time of the jth task in ; Indicates p b The improvement in the deadline of the jth task in ; S1303, traverse the restricted period set group P; wherein, initialize the restricted period set index b=1; S1304. Judgment b≤N P Is it established? If so, go to S1305; otherwise, go to S5; S1305, traverse p b The task in the task limit execution time period; wherein, initialization j=1; S1306, determine j≤N T Is it established? If so, go to S1307; if not, go to S1310; S1307, update p b The release time of the jth task in S1308, update p b The deadline for the jth task in S1309, update j=j+1, and go to S1306; S1310 , update b=b+1, and go to S1304 .
6. The method according to claim 5, characterized in that In S1302, the time improvement amplitude is updated to obtain the updated and include: S130201, traverse the restricted time period set group P; wherein, initialize the restricted time period set index b=1; S130202, judge b≤N P Is it established? If so, go to S130203; otherwise, go to S130213; S130203, traverse p b The task in the task limit execution time period; wherein, initialization j=1; S130204. Judgment j≤N T Is it established? If so, go to S130205; otherwise, go to S130212; S130205, randomly generate decimals r1 and r2, and update p based on formula 1 b The improvement of the release time of the jth task in Wherein, r1 and r2 are between (0, 1); the formula 1 is: S130206, Judgment Is it true? If so, go to S130207; otherwise, update S130207, Judgment Is it true? If so, go to S130208; otherwise, update S130208, randomly generate decimals r3 and r4, and update p based on formula 2 b The improvement in the deadline of the jth task in Wherein, the decimals r3 and r4 are between (0, 1); the formula 2 is: S130209, Judgment Is it true? If so, go to S1302010; otherwise, update S130210, Judgment Is it true? If so, go to S130211, otherwise update S130211, update j=j+1, and go to S130204; S130212, update b=b+1, go to S130202; S130213, output updated and 7. An automatic drone dispatching system based on logistics cabinets, characterized in that: The system comprises: A first acquisition module is used to execute S1 and obtain initial scheduling information; The first initialization module is used to execute S2, initialize the restricted period set group P; wherein the restricted period set group P represents N P A task restriction execution time period set group is composed of a set of restriction time periods. p b represents the bth restricted time period set; The first copy module is used to execute S3, copy the restricted period set group P, obtain the copied restricted period set group P', and create a new restricted period set p B ; Among them, initialize p B The release time of each task is 0, the deadline is A, A is the preset time, set p B The maximum completion time of the planning scheme is O B ; A first iteration module is configured to execute S4 and perform iterations, wherein the number of iterations is initialized to i=1; The first traversal module is used to execute S5 and traverse the restricted time period set group P; wherein the restricted time period set index b is initialized to 1; The first judgment module is used to execute S6 and judge whether b≤N P If yes, then go to the second acquisition module to execute S7; otherwise, go to the fourth judgment module to execute S12; The second acquisition module is used to execute S7, based on the limit period set p b , initial scheduling information and tree search method to obtain p b planning scheme and determine p b The maximum completion time O of the planning scheme b ; The second judgment module is used to execute S8 and judge b ′≤O b Is it established? If so, go to S10; if not, go to the first update module and execute S9; b ′ represents p b ′The maximum completion time of the corresponding planning scheme; The first update module is used to execute S9, update p b ′=p b ; The third judgment module is used to execute S10 and judge B ≤O b Is it true? If so, update b=b+1 and go to the first judgment module to execute S6; if not, go to the second update module to execute S11; The second update module is used to execute S11 and update p B =p b , update b=b+1, and go to the first judgment module to execute S6; The fourth judgment module is used to execute S12, update the number of iterations i=i+1, and judge i≤N I Is it true? If so, go to the third update module to execute S13; otherwise, go to the first output module to execute S14; where N I Indicates the maximum number of iterations; The third updating module is used to execute S13, update the task release and deadline of each restricted time period set in the restricted time period set group P, and then transfer to the first traversal module to execute S5; The first output module is used to execute S14 and output p B Corresponding planning scheme.
8. The system according to claim 7, characterized in that The first initialization module includes: A first initialization submodule is used to execute S201 and initialize b=1; The first judgment submodule is used to execute S202 and judge whether b≤N P Is it established? If so, go to the second initialization submodule to execute S203; otherwise, go to the first copy module to execute S3; The second initialization submodule is used to execute S203, initialize p b The release time of each task is 0 and the deadline is A; The third initialization submodule is used to execute S204 and initialize the improvement amplitude boundary. The fourth initialization submodule is used to execute S205 and initialize Randomly generate N T between [0, M S ] period, as the improvement of each task’s release time; Indicates p b The set of improvement magnitudes of task release time in the middle task; The fifth initialization submodule is used to execute S206 and initialize Randomly generate N T between [0, M S ] period as the improvement corresponding to the deadline of each task; Indicates p b The set of improvement magnitudes of task deadlines; The first updating submodule is used to execute S207, update b=b+1, and then transfer to the first judging submodule to execute S202.
9. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; Memory for storing computer programs; A processor, configured to implement the method steps described in any one of claims 1 to 6 when executing a program stored in a memory.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps of any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Solving algorithm of unmanned aerial vehicle distribution network optimization for urban instant distribution
CN114511272A
Unmanned aerial vehicle patrol path planning method for national parks and natural reserves
CN115185303A