Abstract
This study aimed at the problems of dense distribution and different sizes of pests in cantaloupe fields, as well as the complex and variable characteristics of some pests. To improve the detection accuracy of pests in cantaloupe leaves, a multi-strategy dynamic feature fusion detection algorithm is proposed, which provides a reference for technological paths for pest control in cantaloupe fields. First, the Melon Cantaloupe Pest dataset, containing five types of cantaloupe pests from the Robotflow website, was used and processed for image culling and expansion. Second, the YOLOv12 model is improved by (1) adding the EMA attention mechanism at the end of its backbone network, (2) changing the fusion strategy of the Concat layer in the Neck network as well as the Detect layer in the Head network, (3) introducing the WIoU v3 loss function, and (4) improving the C3k2 module. The experiments showed that the model proposed in this study achieved 85.06%, 86.76%, 79.94%, 54.15% and 83.08% for mAP50, P, R, mAP50-95, and F(1), respectively. It outperformed all other comparative models in four metrics except the R. Additionally, compared to the original YOLOv12 model, the four metrics of the improved model were improved by 3.48%, 3.17%, 2.5%, 3.45% and 3.04%, while the number of parameters was reduced. In addition, ablation experiments as well as generalization experiments on rice pest and corn pest datasets were conducted in this study. The improved model proposed in this paper effectively enhances the performance of pest detection in different scenarios.