高级检索+

轻量化改进YOLOv8n的荔枝病虫害检测方法

Detecting litchi pests and disease using lightweight improved YOLOv8n

  • 摘要: 荔枝病虫害智能检测是果园智慧管理的重要环节。为提高自然环境下荔枝病虫害的检测精度,兼顾模型部署至边缘设备的检测性能,该研究提出了一种基于改进YOLOv8n的荔枝病虫害轻量化检测方法。首先,在荔枝果园自然环境下采集6种病虫害图片构建自建数据集。其次,使用轻量级跨尺度特征融合模块(CNN-based cross-scale feature fusion,CCFM)改进颈部网络结构,减小模型的参数量、体量大小和计算量;在颈部网络引入轻量级动态上采样器(DySample),补偿模型轻量化造成的精度损失。再次,在YOLOv8n骨干网络部分引入感受野注意力卷积(receptive-field attention convolution,RFAConv),更细致地提取荔枝病虫害特征,减小自然环境因素对模型检测的干扰,且进一步提升模型精确度。最后,使用Inner-MPDIoU(Combining Inner-IoU with MPDIoU)损失函数代替原损失函数,优化预测框与真实框存在宽高比相同但具体尺寸不同情况的损失。试验结果表示,改进后模型参数量、体量大小和计算量相比于原YOLOv8n基准模型分别降低了33.3%、30.6%和16.0%,同时精确率、召回率、平均精度均值分别提升了2.1、9.1、4.5个百分点。将改进后的模型分别部署至Jetson系列的 Nano和Orin NX开发板上,并使用 TensorRT加速模型,加速后的模型检测速度分别达到35.8和67.7帧/s,能够满足实时检测的要求。真实环境测试结果显示,改进后的模型减少了漏检、误检,更适用于在果园环境下精准识别荔枝病虫害,可为病虫害智能检测设备的开发部署和现场应用提供参考。

     

    Abstract: Litchi is one of the highly favorite fruits in China, due to its tender, succulent, and sweet pulp. It is essential to the rapid and accurate identification of the pests and diseases in litchi orchards. However, the natural factors (such as lighting conditions and wind) can significantly interfere with the detection of the litchi pests and diseases in real-world environments of the litchi orchard. Additionally, the advanced detection models are often required for the stable yields, due to the limited computing of edge devices. In this study, an improved lightweight YOLOv8n model was proposed to identify the litchi pests and diseases using the YOLOv8n network framework. Firstly, the neck network of the YOLOv8n architecture was enhanced to implement a lightweight cross-scale feature fusion module (CNN - based Cross - Scale Feature Fusion, CCFM). There was the effective reduction in the number of model parameters, computational complexity, and model size. Meanwhile, a lightweight dynamic upsampler (DySample) was introduced into the neck network, in order to offset the potential accuracy loss that caused by the lightweight design. Secondly, the Receptive-Field Attention Convolution (RFAConv) was integrated into the backbone network of YOLOv8n. Furthermore, the more refined RFAConv with the lightweight was used to extract the features of the litchi pests and diseases in natural environments. There was the relatively small interference of the natural environmental factors on the model detection. Finally, the Inner-MPDIoU (combining Inner - IoU with MPDIoU) loss function was employed to replace the original loss function. The same aspect ratio but different specific sizes were observed in the predicted and ground truth bounding boxes. Experimental results demonstrated that the improved model was achieved a reduction of 33.3%, 30.6%, and 16.0% in the number of the parameters, model size, and computational amount, respectively, compared with the original YOLOv8n benchmark model. Meanwhile, the precision, recall, and mean average precision increased by 2.1 percentage points, 9.1 percentage points, and 4.5 percentage points, respectively. The improved model was deployed on Jetson Nano and Jetson Orin NX development boards, where the TensorRT was used to accelerate the detection. There were the detection speeds of 35.8 frames per second and 67.7 frames per second, respectively, fully meeting the requirements of the real-time detection. The improved model was significantly reduced the missed detections and false positives, more suitable for the precise identification of the litchi pests and diseases in natural environments. Moreover, the improved model with the fewer parameters and higher detection speed was deployed on the fixed camera devices in orchard. The real-time image acquisition was obtained to accurately identify the types, occurrence areas, and damage levels of the pests and diseases in litchi orchards. Dynamic early warnings were also offered for the timely decision-making support. The intelligent control systems of plant protection drones were integrated for the real-time perception of the pest and disease distributions. The "on-demand supply" of the pesticides was realized to precisely plan the flight paths and spraying strategies of the drones. The spraying dosage increased in the high-incidence areas. The lightly affected areas were reduced to avoid the pesticide waste and environmental pollution that caused by the traditional "full - coverage" spraying. The finding can provide the technical support for the efficient and safe production of the litchi industry. A strong reference and practice can also be offered for the intelligent prevention and control of the crops pests and diseases in smart agriculture.

     

/

返回文章
返回