基于改进YOLOv5的自然场景下异常变色松树检测方法

    Detecting discolored pine trees under natural scenes using improved YOLOv5

    • 摘要: 针对林区松材线虫病异常变色松树零星病枝难以识别、漏检率高、检测速度慢等问题,该研究提出一种基于自适应多尺度特征融合的轻量化目标检测方法。首先,将YOLOv5s的Backbone部分替换为EfficientNetv2-S以压缩模型参数量和计算复杂度,其次,添加CBAM(convolution block attention module)注意力模块加强网络对目标病害的关注度,然后,引入加权双向多尺度特征融合网络(bidirectional feature pyramid network,BiFPN)增强不同尺度特征图之间的融合程度,最后采用SIoU(shape intersection over union)损失函数提升模型收敛速度与回归精度。结果显示,改进算法在建模区的精确率、召回率和mAP0.5(IoU阈值为0.5时的平均精度均值)分别达到了92.95%、94.88%和94.21%,比原模型分别提高4.31、5.60和5.13个百分点,参数量、计算量分别为原YOLOv5s的77.07%和35.81%,实现了模型的轻量化;与SSD、Faster R-CNN和YOLO系列目标检测模型相比,改进模型的综合检测性能更优,帧率和权重文件大小分别为136.05 帧/s和11.90 MB。在未建模区域8、9号样地中改进算法对变色松树的平均精度分别为92.70%、92.60%,枯死松树分别为93.94%、96.83%。在8号样地中对枯死松树的召回率达到95.88%。该检测方法适用于自然场景下异常变色松树的快速准确检测,对提高松材线虫病防控智能化水平具有重要现实意义。

       

      Abstract: Pine wilt disease (PWD) is known as the cancer of pine trees, however, the detection of discolored dead trees often results in false detection and missed detection. In this study, an adaptive multi-scale feature fusion network was proposed to optimize the recognition accuracy for the PWD. The backbone part of the lightweight network (EfficientNetv2) was used as the feature extraction. The spatial pyramid pooling fusion (SPPF) module in YOLOv5s was retained to compress the number of model parameters, to reduce the amount of computation; Secondly, the convolution block attention module (CBAM) was added to YOLOv5s to strengthen the attention to target disease, and the PANet was replaced with BiFPN to optimize the accuracy of discolored dead trees. The feature weight information was introduced to enhance the fusion of features at different scales. Finally, the CIoU loss function was replaced by the SIoU loss function to improve the model accuracy. Direction matching between the real and predicted frames was considered to enhance the model’s convergence. The results showed that the accuracy, recall and mAP0.5 of the improved algorithm in the modeling area reached 92.95%, 94.88% and 94.21%, respectively, which was 4.31%, 5.60%, and 5.13% higher than that of the original model. The number of parameters and computation were reduced by 22.93% and 64.19%, which were 77.07% and 35.81% of the original YOLOv5s, respectively. At the same time, the network processing speed of the improved YOLOv5s model was increased by 45.66% to 136.05 frames/s, and the model was more real-time. The ablation test proved that each improvement measure based on YOLOv5s improved the performance of the original model, and all four measures were necessary. Compared with SSD, Faster R-CNN and YOLO series object detection models, the improved model showed significant advantages in terms of recall rate, detection speed, number of parameters and model weight. The improved model showed 95.25% and 93.17% of the single-class average detection accuracy (AP) for abnormally discolored pine trees and dead pine trees, respectively. In addition, the frame rate and weight file size of the improved model were 136.05 frames/s and 11.90 MB, respectively, and the F1 score was 93.91%. The average detection accuracy of the improved algorithm for two types of targets in the natural forest area was 1.07% higher than that in the modeling area. The recall rate of dead pine trees in plot 8 reached 95.88%, which was 1.00% higher than that in the modeled area. After the detection of the two types of targets in the test area, the average F1 score of the model was 93.68%, which was roughly equivalent to the modeling area. This detection method was suitable for the rapid and accurate detection of abnormal discolored pine trees in natural scenes, which was of great practical significance for improving the intelligent level of pine wood nematode disease prevention and control.

       

    /

    返回文章
    返回