高级检索+

复杂背景下基于改进YOLOv8n的轻量化葡萄叶片病害识别方法

Detecting grape leaf diseases using improved lightweight YOLOv8n under complex backgrounds

  • 摘要: 针对现有葡萄叶片病害识别模型易受复杂背景干扰且参数量较大的问题,该研究提出一种面向复杂背景的轻量化葡萄叶片病害识别模型DaEMC-YOLO。该模型以YOLOv8n为基准,在主干网络中引入可变形注意力机制,通过自适应学习采样偏移,动态关注葡萄叶片病害的关键判别特征,增强特征表达与目标定位能力。在颈部构建多分支混洗调制特征融合金字塔网络,促进跨尺度信息交互与动态增强。同时采用通道优化策略,精简特征融合及检测输出通道,在保证检测性能的同时降低参数量与计算开销。试验结果表明,改进后的模型mAP0.5:0.95达到88.43%,较基准模型提高2.03个百分点;参数量和模型权重分别降至1.89 M和4.0 MB,较基准模型分别减少37.21%和33.33%。此外,该模型在Jetson Orin NX Super平台的推理速度达27.83帧/s,显存占用仅0.18 GB,能够实现实时推理并保持较低的资源消耗。该模型具有较高检测精度与良好轻量化性能,可为复杂背景下葡萄叶片病害识别提供重要参考。

     

    Abstract: Real-time detection of leaf diseases is often required in grape cultivation. In this study, a lightweight model, named DaEMC-YOLO, was proposed to detect grape leaf diseases under complex backgrounds. Excessive interference parameters were reduced from complex backgrounds and decreased. YOLOv8n was selected as the baseline. Three improvements were also introduced. (1) The fourth-stage backbone feature layer was incorporated with deformable attention. Adaptive sampling offsets were learned using bilinear interpolation. Feature sampling was redirected to leaf targets, according to leaf morphology, with emphasis on disease cues and localization, and suppressed background responses. (2) The neck incorporated the MBSMFFPN to promote cross-scale interaction. Enhanced upsampling combined interpolation and depthwise convolution. Modulation fusion weighted shallow boundaries and deep semantics, while cross-stage convolution combined depthwise convolutions, channel shuffling, and concatenation for multi-scale representation. (3) Feature-fusion and detection-head channels were reduced from 256 to 192 to reduce parameters, computation, and storage to retain detection performance. Ablation results revealed that the better complementary effects were achieved after evaluation. Deformable attention raised the mAP from 86.40% to 87.42%, while only increasing the parameter count by 0.03 M, indicating efficient foreground discrimination. MBSMFFPN then raised the mAP to 87.76%, while the parameter count was reduced to 2.18 M, computation to 7.3, and model size to 4.5 MB. The concurrent changes indicated that the fusion path reduced redundant processing for cross-scale interaction. The mAP increased to 88.43% after channel reduction, whereas the model was reduced to 1.89 M parameters, 6.0, and 4.0 MB. Together, the three improvements increased accuracy by 2.03 percentage points, while parameters and model size were reduced by 37.21% and 33.33%, respectively, indicating the trade-off after detection. DaEMC-YOLO achieved the highest mAP and the smallest model scale. Specifically, YOLOv10n and YOLOv12n surpassed it by 2.93 percentage points and 3.67 percentage points, respectively, while the larger YOLOv8s surpassed it by 1.02 percentage points. Compared with single-shot and two-stage detectors, the mAP increased by 19.39 percentage points and 20.48 percentage points, respectively, using far fewer parameters. The category also showed that there was an uneven difficulty pattern. The highest average precision was achieved for black rot, downy mildew, and Esca, whereas healthy leaves and leaf blight remained 1.04 percentage points and 0.08 percentage points below their best values. Complex backgrounds therefore made healthy leaves harder to distinguish, although the model remained competitive over all categories. Grad-CAM connected the numerical gains with feature attention. YOLOv8n distributed responses over leaves and surrounding backgrounds, whereas DaEMC-YOLO concentrated on leaf targets and weakened non-target responses. Channel-width experiments showed that there was a non-monotonic relationship between width and accuracy: More channels failed to consistently improve the accuracy of the detection. The 192-channel configuration produced the highest mAP, which supported a moderate feature capacity rather than unrestricted channel expansion. The moderate channel allocation preserved useful feature capacity to avoid unnecessary computational expansion during edge inference. Deployment experiments were performed on the Jetson Orin NX Super platform. Structural compression was translated into practical efficiency. The inference speed of DaEMC-YOLO reached 27.83 frames/s, while the inference time shortened to 35.93 ms/img, and memory usage was reduced to 0.18 GB. Compared with YOLOv8n, there was a 13.55% frame-rate increase, an 11.94% inference-time reduction, and an 18.18% memory reduction. The DaEMC-YOLO can be expected to improve foreground-focused detection with controlled network redundancy on resource-constrained edge devices.

     

/

返回文章
返回