基于改进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%,实现了模型的轻量化;改进模型的帧率和权重文件分别为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 well known as the cancer of pine trees. However, the false and missed detection of discolored dead trees has often confined the large-scale production in recent years. In this study, an adaptive multi-scale feature fusion network was proposed to optimize the recognition accuracy of the PWD. The backbone layer of the lightweight network (EfficientNetv2) was used to extract the feature. The spatial pyramid pooling fusion (SPPF) module in YOLOv5s was retained to compress the number of parameters, in order to reduce the amount of computation; Secondly, the convolution block attention module (CBAM) was added into the YOLOv5s. The attention was then strengthened on the target disease. The PANet was replaced with the BiFPN, particularly for the high accuracy of detection on the discolored dead trees. The feature weight was also introduced to enhance the fusion of features at different scales. Finally, the SIoU loss function was replaced with the CIoU one, in order to improve the accuracy of the model. Direction matching between the real and predicted frames was considered to enhance the convergence of model. The results showed that the accuracy, recall and mAP0.5 of the improved model in the modeling area reached 92.95%, 94.88% and 94.21%, respectively, which were 4.31, 5.60, and 5.13 percentage point higher than those of the original one. 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 increased by 45.66% to 136.05 frames/s, indicating the more real-time model. The ablation test proved that each measure with the YOLOv5s was improved the performance of the original model, where all four measures were necessary. Compared with the SSD, Faster R-CNN and YOLO series models, the improved model of object detection performed better in the recall rate, detection speed, the number of parameters and weights. The improved model was achieved with the 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 model for two types of targets in the natural forest area was 94.02%, which was 1.07% higher than that in the modeling area. The recall rate of dead pine trees reached 95.88% in the Plot 8, which was 1.00% higher than that in the modeled area. Furthermore, the average F1 score of the model was 93.68% for the two types of targets in the test area, which was roughly equivalent to the modeling area. It was of great practical significance for this rapid and accurate detection of abnormal discolored pine trees in natural scenes. This finding can also provide a strong reference to improve the intelligent prevention and control of pine wood nematode diseases.

       

    /

    返回文章
    返回