Autonomous Underwater Vehicle (AUV) is an important tool for deep sea resource exploration. With the urgent demand for deep sea resource, multi-AUV cluster exploration has gradually become the research focus in the field of deep sea resource exploration. Multi-AUV task planning is a research focus of multi-AUV cluster detection. In this paper, multi AUV task planning is divided into two parts: task allocation in the upper layer and local path planning in the lower layer. In the problem of multi-AUV upper layer task allocation in large-scale marine environment, For the existing task allocation model, only the problem of homogeneous AUV cluster and single dive task allocation is considered, this paper proposes a multi dive task allocation model suitable for AUV heterogeneous cluster, the model considered the energy constraints of AUV, the engineering cost of AUV multiple round-trip mother ship charging, the efficiency difference between heterogeneous cluster individuals, the diversity of tasks, real path cost and current disturbance. In order to improve the efficiency of solving the problem model, an optimization algorithm based on discrete particle swarm optimization is proposed. The algorithm introduces matrix coding to describe the speed and position of particles and task loss model to evaluate the quality of particles, improves the process of updating particles, optimizes the number of dives and task execution time, and realizes efficient task allocation. After multi-AUV cluster obtains the task sequence, the lower layer local path planning algorithm is needed to ensure the safety of AUV during the task execution. In this paper, an improved algorithm of flow avoiding obstacles for multi-AUV local path planning in deep sea environment is proposed. A fast parameter self-adaptive adjustment strategy is designed under the constraints of safe distance and path length, which can meet the needs of multi-AUV cooperation for the calculation complexity of local path planning algorithm. The algorithm of AUV passing through the overlapping area of obstacles is designed. The disturbance of moving AUV to the initial flow field is added to the original model, which solves the problem of interaction between AUVs in complex environment. The local path planning function of multi-AUV cluster in the environment of deep sea multi complex obstacles is realized. Finally, in order to verify the proposed task allocation algorithm in a more realistic environment, a multi-AUV task allocation simulation environment is built based on ROS and the existing underwater robot simulation environment, which lays a solid foundation for the future task planning algorithm engineering application.