Abstract:
In order to further address the issues of perch target detection accuracy in underwater environments that were caused by small targets and complex backgrounds, and to resolve the frequent ID error switching during multi-target tracking due to occlusion and nonlinear motion, a fish individual motion feature extraction method based on the improved YOLOv8 (You Only Look Once 8) and ByteTrack was proposed in this study.The main process of the behavior state analysis method based on the motion characteristics of underwater fish was as follows: Firstly, the target fish body was detected and located in real time according to the motion information of the fish individual. On this basis, the multi-target tracking algorithm was combined to track each target, in order to obtain the corresponding motion trajectory and position change information. Finally, the required fish body motion characteristics were extracted through basic mathematical calculations to quantify and analyze the behavior state of the fish.In this study, the improved YOLOv8 real-time target detector was used to realize the detection of free-moving fish individuals. The lightweight YOLOv8n was used as the target detection module of the fish individual motion feature extraction method. At the same time, in order to further reduce the model size and improve the detection accuracy and speed of the model, the basic network of YOLOv8n was optimized. The full-dimensional dynamic convolution ODConv was used to replace the down-sampling convolution of the backbone network of the YOLOv8n model, and Wise-IoUv3 Loss was used to replace the bounding box regression loss function CIoU_Loss of the YOLOv8n model.Then, the ByteTrack algorithm was optimized in terms of motion model and data association. The extended Kalman filter (EKF) and linear Kalman filter (KF) were combined to adapt to the possible nonlinear motion and accelerated changes of the target fish body, which improved the prediction accuracy for complex motion patterns. The post-processing strategy of Gaussian trajectory interpolation was introduced to enhance the robustness of the algorithm in dealing with occlusion and motion blur, reducing the occurrence of wrong identity switches, lowering the IDs error switches caused by occlusion, and stabilizing the tracking performance of the tracker.The experimental results showed that the improved YOLOv8 algorithm reduced the model size and parameters by about two-thirds respectively, and the accuracy and recall rate were increased by 0.4 percentage points and 0.5 percentage points respectively. It exhibited high detection accuracy and good robustness and real-time performance. The average MOTA (Multiple Object Tracking Accuracy) of the improved ByteTrack algorithm was 88.7%, and the MOTP (Multiple Object Tracking Precision) was 83.8%. The average IDs of each test video was only 37, and the FPS (Frames Per Second) was 98, which fully met the real-time tracking requirements. This method shows stable real-time tracking ability of perch individuals in actual aquaculture scenarios, which has important practical application value for non-contact aquaculture monitoring. By accurately monitoring the behavior patterns and movement characteristics of fish, we can not only evaluate the health status of fish in real time, but also provide a scientific basis for the optimization of aquaculture environment. The results showed that the improved YOLOv8 and ByteTrack individual motion feature extraction model proposed in this paper demonstrated strong feature extraction and generalization abilities, accurately identifying most of the objects to be tested even in complex scenes. The aforementioned research results indicated that the improved method in this paper could significantly enhance the target detection effect of the existing model in complex scenes and increase the accuracy of target detection and counting, thereby providing technical support to improve the production efficiency and reduce the production costs of large-scale cultured bass. In the future, the method of this study is expected to be further extended to data collection and analysis in more behavioral states, and even combined with three-dimensional spatial information and multi-modal data to achieve more comprehensive fish behavior analysis and aquaculture environment monitoring.