# Advancing Multi-UAV Inspection Dispatch Based on Bilevel Optimization and GA-NSGA-II
## 1 Introduction
Since path planning is based on UAV battery capacity for task segmentation, it can accommodate various types and performance levels of UAVs, demonstrating strong versatility. Additionally, the method is applicable to multiple types of tasks, including fault detection and routine inspection. This is because its underlying assumptions cover the power lines between transmission towers and the towers themselves, and the planning process has already accounted for the time required for UAVs to locate fault points and take photos at the towers. Therefore, this method can be widely applied to various task scenarios. While many existing methods can effectively address multi-UAV task assignment in small-scale scenarios, significant challenges remain in large-scale scenarios. For example, how to achieve rational task assignment among multi-UAVs while ensuring the shortest total travel distance is still an urgent problem to be solved. To address this challenge, this paper proposes an innovative bilevel optimization algorithm based on GA-NSGA-II for multi-UAV task assignment and path planning for large-scale power grid inspections. The main innovations are as follows:  
1. Power line segmentation: the extensive power grid lines are divided into several unit tasks based on external constraints and UAV battery capacity for subsequent optimization. 2. Multi-UAV task assignment based on the NSGA-II algorithm: the chromosome encoding strategy of the NSGA-II algorithm is innovatively applied to allocate the segmented unit tasks to each UAV. 3. Path optimization with the adaptive genetic algorithm based on the elitist preservation strategy: for the inspection unit tasks allocated to each UAV, an adaptive genetic algorithm based on the elitist preservation strategy is innovatively used to optimize the inspection sequence and direction of the unit tasks. 4. The GA-NSGA-II bilevel optimization algorithm: An innovative bilevel optimization framework combining the adaptive genetic algorithm with the elitist preservation strategy and NSGA-II is proposed. This framework aims to minimize the total inspection distance of UAVs while ensuring balanced task distribution among them. The specific procedure of the entire algorithm is as follows: First, according to the proposed constraints and UAV battery capacity, the power grid lines are segmented into several unit tasks. Next, these unit tasks are allocated to different UAVs using the chromosome encoding strategy of the NSGA-II algorithm. Subsequently, in the inner optimization layer, the adaptive genetic algorithm based on the elitist preservation strategy is employed to optimize the sequence and direction of the unit tasks assigned to each UAV, thereby minimizing the UAV's flight distance. Finally, in the outer layer, the genetic selection mechanism of the NSGA-II algorithm is used to screen for the optimal results that meet the conditions. The rest of this paper is as follows: Section 2 formulates the problem to establish the multi-objective optimization model. Section 3 introduces the proposed algorithm in detail. Section 4 gives the experiments and analysis. Section 5 concludes the paper.