Detection of Varroa destructor Infestation of Honeybees Based on Segmentation and Object Detection Convolutional Neural Networks
Abstract
:1. Introduction
- (1)
- A novel scheme that weakens the background information and distinguishes the key information of honeybees and Varroa destructor is designed. By using image segmentation to isolate the main object in a given image while removing any unnecessary background noise or distractions, the accuracy of the detection is significantly improved, allowing for a more accurate and reliable diagnosis of this harmful parasite in bee populations.
- (2)
- The adaptive feature pooling of the improved Path Aggregation Network (PAN) [20] fuses feature information on different scales, and a coordinate attention (CA) mechanism reduces the feature inconsistency brought on by scale variation. By focusing on global contextual information, it effectively eliminates errors caused by scale differences, making the network better at detecting Varroa destructor.
- (3)
- The data augmentation method that generates images of Varroa mites increases the number of minority class samples, and the dynamic scaling factor is used to make the network more focused on training difficult-to-classify samples.
2. Materials and Methods
2.1. Materials
2.1.1. Image Acquisition
2.1.2. Data Augmentation
2.2. Methods
- (1)
- Image segmentation: Establish an FCN weight model and use it to segment the image obtained in the original image dataset (referred to as dataset 1) between honeybees and backgrounds.
- (2)
- Honeybee image extraction: Perform image processing, such as dilation and masking, on the segmented images with the original images to obtain bee images that exclude the background area. The extracted bee images constitute the object-detection dataset (recorded as dataset 2).
- (3)
- Detection of honeybees and Varroa destructor: Dataset 2 was labeled with Varroa destructor and honeybees; the YOLOX model is trained based on dataset 2, furthermore, add an attention mechanism and improve the loss function to improve the detection accuracy.
- (4)
- Use the segmentation and object-detection collaborative convolutional neural network to analyze actual images, and then obtain the proportion of honeybees infested with Varroa destructor.
2.2.1. The Structure of Segmentation Network
- (1)
- The input for the FCN is the original image of the bees, with a size of 3840 × 2160 pixels.
- (2)
- Backbone is based on the convolutional structure of VGG16, which stacks 5 layers of convolution and pooling to learn the multi-level features of the image. After 5 convolution operations, the feature map size is reduced to 1/32 of the original image.
- (3)
- The fully connected layer of VGG16 is replaced with the equivalent 3 convolutional layers, whose convolution kernel sizes (channels, width, height) are (4096, 7, 7), (4096, 1, 1), and (2, 1, 1). After removing the fully connected layer, the network has no limitation of fixed input and output sizes, so it can segment honeybee images of any size.
- (4)
- After the FC8 layer, the first prediction layer’s feature map was obtained by 2× upsampling. Its coarse-grained features are accurate, but the refined prediction is dissatisfyingly coarse. Therefore, we fused the output feature map of MaxPool4 in backbone with the first prediction layer through a skip architecture. Combining fine layers and coarse layers lets the model make local predictions that respect global structure.
- (5)
- Finally, the fused feature map is restored to the size of the input image by 16× upsampling. Each pixel gets a predicted class while preserving the spatial information of the honeybee, thus completing the segmentation of the honeybee and background. The output is a segmented image, which is the same size as the input image.
2.2.2. Honeybee Image Extraction
2.2.3. YOLOX Model Establishment and Improvement
- (1)
- YOLOX Baseline
- (2)
- Attention mechanism for Varroa destructor details
- (3)
- Improvement of the loss function to mitigate the class imbalance
3. Experimental Results and Discussions
3.1. Experimental Platform and Evaluation Indicators
3.1.1. Experimental Platform
3.1.2. Evaluation Indicators
3.2. Experiment for Honeybees and Varroa destructor Detection
3.2.1. Segmentation Performance Experiment
3.2.2. Target Detection Experiment Results
3.3. Analysis of Improved Algorithm Performance
3.4. Discussion
3.4.1. Experiments on Unclear Characteristics Image
3.4.2. Experiments on Different Light Degrees
3.5. Beehive Experiment
4. Conclusions
- (1)
- This study proposes a convolutional neural network that combines segmentation and object detection for detecting Varroa destructor infestation of honeybees in bee colonies. The mAP of the model is 95.31%, and the F1 score of honeybees and Varroa destructor are 94.83% and 96.85%, respectively. The average frame time is 35 ms, and the detection value for the proportion of honeybees infested with Varroa mites is extremely close to the true value. The model’s performance is better than other detection algorithms providing a useful exploration for the real-time online diagnosis of Varroa destructor infestation levels in bee colonies.
- (2)
- Using the constructed FCN to extract honeybee images can effectively filter out the influence of the background on detection accuracy, allowing the target detection model to focus more on the target and effectively improve the detection accuracy of Varroa destructor.
- (3)
- Adding the CA mechanism and improving the confidence loss function effectively improve the detection accuracy of the model for Varroa destructor. The mAP has increased by 14.08%, while the F1 score for Varroa destructor detection has increased by 8.70%, with only a 1 ms increase in average frame time.
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Potts, S.G.; Biesmeijer, J.C.; Kremen, C.; Neumann, P.; Schweiger, O.; Kunin, W.E. Global pollinator declines: Trends, impacts and drivers. Trends Ecol. Evol. 2010, 25, 345–353. [Google Scholar] [CrossRef] [PubMed]
- Bjerge, K.; Frigaard, C.E.; Mikkelsen, P.H.; Nielsen, T.H.; Misbih, M.; Kryger, P. A computer vision system to monitor the infestation level of Varroa destructor in a honeybee colony. Comput. Electron. Agric. 2019, 164, 104898. [Google Scholar] [CrossRef]
- Martin, S.J.; Ball, B.V.; Carreck, N.L. Prevalence and persistence of deformed wing virus (DWV) in untreated or acaricide-treated Varroa destructor infested honey bee (Apis mellifera) colonies. J. Apic. Res. 2010, 49, 72–79. [Google Scholar] [CrossRef]
- Carreck, N.L.; Ball, B.V.; Martin, S.J. Honey bee colony collapse and changes in viral prevalence associated with Varroa destructor. J. Apic. Res. 2010, 49, 93–94. [Google Scholar] [CrossRef]
- Ramsey, S.D.; Ochoa, R.; Bauchan, G.; Gulbronson, C.; Mowery, J.D.; Cohen, A.; Lim, D.; Joklik, J.; Cicero, J.M.; Ellis, J.D. Varroa destructor feeds primarily on honey bee fat body tissue and not hemolymph. Proc. Natl. Acad. Sci. USA 2019, 116, 1792–1801. [Google Scholar] [CrossRef] [PubMed]
- Locke, B.; Semberg, E.; Forsgren, E.; De Miranda, J.R. Persistence of subclinical deformed wing virus infections in honeybees following Varroa mite removal and a bee population turnover. PLoS ONE 2017, 12, e0180910. [Google Scholar] [CrossRef] [PubMed]
- Guzmán-Novoa, E.; Eccles, L.; Calvete, Y.; Mcgowan, J.; Kelly, P.G.; Correa-Benítez, A. Varroa destructor is the main culprit for the death and reduced populations of overwintered honey bee (Apis mellifera) colonies in Ontario, Canada. Apidologie 2010, 41, 443–450. [Google Scholar] [CrossRef]
- Di Prisco, G.; Pennacchio, F.; Caprio, E.; Boncristiani Jr, H.F.; Evans, J.D.; Chen, Y. Varroa destructor is an effective vector of Israeli acute paralysis virus in the honeybee, Apis mellifera. J. Gen. Virol. 2011, 92, 151–155. [Google Scholar] [CrossRef] [PubMed]
- Gisder, S.; Aumeier, P.; Genersch, E. Deformed wing virus: Replication and viral load in mites (Varroa destructor). J. Gen. Virol. 2009, 90, 463–467. [Google Scholar] [CrossRef] [PubMed]
- Kulhanek, K.; Steinhauer, N.; Wilkes, J.; Wilson, M.; Spivak, M.; Sagili, R.R.; Tarpy, D.R.; McDermott, E.; Garavito, A.; Rennich, K. Survey-derived best management practices for backyard beekeepers improve colony health and reduce mortality. PLoS ONE 2021, 16, e0245490. [Google Scholar] [CrossRef] [PubMed]
- Steinhauer, N.; Saegerman, C. Prioritizing changes in management practices associated with reduced winter honey bee colony losses for US beekeepers. Sci. Total Environ. 2021, 753, 141629. [Google Scholar] [CrossRef] [PubMed]
- Santana, F.S.; Costa, A.H.R.; Truzzi, F.S.; Silva, F.L.; Santos, S.L.; Francoy, T.M.; Saraiva, A.M. A reference process for automating bee species identification based on wing images and digital image processing. Ecol. Inform. 2014, 24, 248–260. [Google Scholar] [CrossRef]
- Babic, Z.; Pilipovic, R.; Risojevic, V.; Mirjanic, G. Pollen bearing honey bee detection in hive entrance video recorded by remote embedded system for pollination monitoring. ISPRS Ann. Photogramm. Remote Sens. Spat. Inf. Sci. 2016, 3, 51. [Google Scholar] [CrossRef]
- Martineau, M.; Conte, D.; Raveaux, R.; Arnault, I.; Munier, D.; Venturini, G. A survey on image-based insect classification. Pattern Recognit. 2017, 65, 273–284. [Google Scholar] [CrossRef]
- Schurischuster, S.; Kampel, M. Image-based classification of honeybees. In Proceedings of the 2020 Tenth International Conference on Image Processing Theory, Tools and Applications (IPTA), Paris, France, 9–12 November 2020; pp. 1–6. [Google Scholar]
- Kaur, M.; Ardekani, I.; Sharifzadeh, H.; Varastehpour, S. A CNN-based identification of honeybees’ infection using augmentation. In Proceedings of the 2022 International Conference on Electrical, Computer, Communications and Mechatronics Engineering (ICECCME), Maldives, Maldives, 16–18 November 2022; pp. 1–6. [Google Scholar]
- Voudiotis, G.; Moraiti, A.; Kontogiannis, S. Deep Learning Beehive Monitoring System for Early Detection of the Varroa Mite. Signals 2022, 3, 506–523. [Google Scholar] [CrossRef]
- Bilik, S.; Kratochvila, L.; Ligocki, A.; Bostik, O.; Zemcik, T.; Hybl, M.; Horak, K.; Zalud, L. Visual diagnosis of the Varroa destructor parasitic mite in honeybees using object detector techniques. Sensors 2021, 21, 2764. [Google Scholar] [CrossRef] [PubMed]
- Liu, W.; Anguelov, D.; Erhan, D.; Szegedy, C.; Reed, S.; Fu, C.-Y.; Berg, A.C. Ssd: Single shot multibox detector. In Proceedings of the Computer Vision–ECCV 2016: 14th European Conference, Amsterdam, The Netherlands, 11–14 October 2016; Proceedings, Part I 14. pp. 21–37. [Google Scholar]
- Liu, S.; Qi, L.; Qin, H.; Shi, J.; Jia, J. Path aggregation network for instance segmentation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA, 18–23 June 2018; pp. 8759–8768. [Google Scholar]
- Long, J.; Shelhamer, E.; Darrell, T. Fully convolutional networks for semantic segmentation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Boston, MA, USA, 7–12 June 2015; pp. 3431–3440. [Google Scholar]
- Ge, Z.; Liu, S.; Wang, F.; Li, Z.; Sun, J. Yolox: Exceeding yolo series in 2021. arXiv 2021, arXiv:2107.08430. [Google Scholar]
- Wang, C.-Y.; Liao, H.-Y.M.; Wu, Y.-H.; Chen, P.-Y.; Hsieh, J.-W.; Yeh, I.-H. CSPNet: A new backbone that can enhance learning capability of CNN. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops, Seattle, WA, USA, 14–19 June 2020; pp. 390–391. [Google Scholar]
- He, K.; Zhang, X.; Ren, S.; Sun, J. Spatial pyramid pooling in deep convolutional networks for visual recognition. IEEE Trans. Pattern Anal. Mach. Intell. 2015, 37, 1904–1916. [Google Scholar] [CrossRef] [PubMed]
- Hou, Q.; Zhou, D.; Feng, J. Coordinate attention for efficient mobile network design. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Nashville, TN, USA, 20–25 June 2021; pp. 13713–13722. [Google Scholar]
- Yan, Y.; Li, J.; Qin, J.; Bai, S.; Liao, S.; Liu, L.; Zhu, F.; Shao, L. Anchor-free person search. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Nashville, TN, USA, 20–25 June 2021; pp. 7690–7699. [Google Scholar]
- Ren, S.; He, K.; Girshick, R.; Sun, J. Faster r-cnn: Towards real-time object detection with region proposal networks. Faster r-cnn: Towards real-time object detection with region proposal networks. IEEE Trans. Pattern Anal. Mach. Intell. 2017, 39, 1137–1149. [Google Scholar] [CrossRef] [PubMed]
- Bochkovskiy, A.; Wang, C.-Y.; Liao, H.-Y.M. Yolov4: Optimal speed and accuracy of object detection. arXiv 2020, arXiv:2004.10934. [Google Scholar]
- Hu, J.; Shen, L.; Sun, G. Squeeze-and-excitation networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA, 18–23 June 2018; pp. 7132–7141. [Google Scholar]
- Woo, S.; Park, J.; Lee, J.-Y.; Kweon, I.S. Cbam: Convolutional block attention module. In Proceedings of the European Conference on Computer Vision (ECCV), Munich, Germany, 8–14 September 2018; pp. 3–19. [Google Scholar]
Dataset Classification | Image Classification | Number of Images |
---|---|---|
Training set | Contains Varroa destructor | 380 |
Does not contain Varroa destructor | 1020 | |
Validation set | Contains Varroa destructor | 107 |
Does not contain Varroa destructor | 293 | |
Test set | Contains Varroa destructor | 55 |
Does not contain Varroa destructor | 145 |
Configuration | Parameter |
---|---|
CPU | Intel Xeon E5-2620 |
Memory | 16G |
GPU | GeForce RTX 2080 Ti |
Accelerated environment | CUDA 10.0 CUDNN 7.1 |
Operating system | Windows 10.0 |
Development environment | Python 3.7.11 Pytorch 1.2.0 |
Model | CBAM | SE | CA | FL | mAP/% | F1/% Honeybee | F1/% Varroa | Avg (FTime)/ms |
---|---|---|---|---|---|---|---|---|
1 | × | × | × | × | 81.48 | 88.01 | 83.79 | 34 |
2 | √ | × | × | × | 88.56 | 90.45 | 91.22 | 38 |
3 | × | √ | × | × | 83.91 | 88.96 | 86.16 | 35 |
4 | × | × | √ | × | 89.94 | 91.45 | 92.49 | 34 |
5 | × | × | × | √ | 94.38 | 94.41 | 94.63 | 34 |
6 | × | × | √ | √ | 95.56 | 94.44 | 97.01 | 35 |
Model | mAP/% | F1/% Honeybee | F1/% Varroa | I/% Detection Value | I/% True Value | Avg (FTime)/ms |
---|---|---|---|---|---|---|
YOLOX | 57.54 | 67.08 | 46.82 | 0.71 | 1.19 | 21 |
YOLOX-b | 82.56 | 88.01 | 83.79 | 0.89 | 23 | |
F-YOLOX-b | 95.31 | 94.83 | 96.85 | 1.13 | 35 | |
YOLOv4 | 30.81 | 58.40 | 41.39 | 0.36 | 73 | |
F-YOLOv4 | 86.83 | 89.79 | 89.17 | 1.01 | 87 | |
Fester RCNN | 46.92 | 77.93 | 10.50 | 0.53 | 44 | |
F-Faster RCNN | 63.81 | 86.99 | 39.53 | 0.77 | 58 |
Beehives | Detection of Infestation Rate | Actual Infestation Rate |
---|---|---|
1 | 0.88% | 0.83% |
2 | 1.35% | 1.25% |
3 | 5.08% | 30.33% |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Liu, M.; Cui, M.; Xu, B.; Liu, Z.; Li, Z.; Chu, Z.; Zhang, X.; Liu, G.; Xu, X.; Yan, Y. Detection of Varroa destructor Infestation of Honeybees Based on Segmentation and Object Detection Convolutional Neural Networks. AgriEngineering 2023, 5, 1644-1662. https://doi.org/10.3390/agriengineering5040102
Liu M, Cui M, Xu B, Liu Z, Li Z, Chu Z, Zhang X, Liu G, Xu X, Yan Y. Detection of Varroa destructor Infestation of Honeybees Based on Segmentation and Object Detection Convolutional Neural Networks. AgriEngineering. 2023; 5(4):1644-1662. https://doi.org/10.3390/agriengineering5040102
Chicago/Turabian StyleLiu, Mochen, Mingshi Cui, Baohua Xu, Zhenguo Liu, Zhenghao Li, Zhenyuan Chu, Xinshan Zhang, Guanlu Liu, Xiaoli Xu, and Yinfa Yan. 2023. "Detection of Varroa destructor Infestation of Honeybees Based on Segmentation and Object Detection Convolutional Neural Networks" AgriEngineering 5, no. 4: 1644-1662. https://doi.org/10.3390/agriengineering5040102
APA StyleLiu, M., Cui, M., Xu, B., Liu, Z., Li, Z., Chu, Z., Zhang, X., Liu, G., Xu, X., & Yan, Y. (2023). Detection of Varroa destructor Infestation of Honeybees Based on Segmentation and Object Detection Convolutional Neural Networks. AgriEngineering, 5(4), 1644-1662. https://doi.org/10.3390/agriengineering5040102