Abstract:Affected by factors such as water attenuation and scattering, underwater optical images suffer from severe color distortion, blurriness, and other issues, resulting in a significant decline in quality and poor target resolution,which in turn is not conducive to carrying out underwater target detection tasks.To address the above problems, in order to improve the accuracy of underwater target detection and reduce the incidence of misdetection and missed detection, this paper proposes an underwater target detection algorithm based on improved YOLOv8n: ESA-YOLOv8. Firstly, the algorithm introduces the ESP module in C2f to improve the Bottleneck structure, the ESP module optimizes network efficiency and reduces the number of model parameters and computations in YOLOv8n;secondly, a small target detection layer is added to improve the detection capability of underwater small targets; finally, the lightweight up-sampling operator CARAFE and the attention mechanism ECA are successively introduced into the neck network to improve the target detection accuracy and realize the enhancement of up-sampling feature fusion.The experimental results show that on the underwater biological dataset DUO,the ESA-YOLOv8 algorithm designed in this paper achieves a mAP@0.5 of 84.7% and a mAP@0.5:0.95 of 65.5%, with a reduction in model parameters. These results represent an improvement of 1.7% and 1.8%, respectively, compared to the base model YOLOv8n.The high accuracy detection results and the reduction in the number of model parameters demonstrate the effectiveness of the improved YOLOv8n and its potential application in underwater target detection.