Evaluation of Inference Performance of Deep Learning Models for Real-Time Weed Detection in an Embedded Computer
Abstract
:1. Introduction
2. Materials and Methods
2.1. Data Collection
2.2. Data Labeling
2.3. Train–Test Split
2.4. Data Augmentation
2.5. Training
2.5.1. YOLOv4
2.5.2. EfficentDet
2.5.3. CenterNet
2.6. Platforms
2.7. Evaluation Metrics
2.8. Mobile Optimized Solution
3. Results
3.1. Model Comparisons
Confusion Matrices
3.2. Inference Time
3.3. Frames Per Second (fps)
3.4. Improvement with YOLOv4-Tiny
4. Discussion
5. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Oerke, E.C. Crop Losses to Pests. J. Agric. Sci. 2006, 144, 31–43. [Google Scholar] [CrossRef]
- Gianessi, L.P.; Reigner, N.P. The Value of Herbicides in U.S. Crop Production. Weed Technol. 2007, 21, 559–566. [Google Scholar] [CrossRef]
- Buhler, D.D.; Liebman, M.; Obrycki, J.J. Theoretical and Practical Challenges to an IPM Approach to Weed Management. Weed Sci. 2000, 48, 274–280. [Google Scholar] [CrossRef]
- Rueda-Ayala, V.; Rasmussen, J.; Gerhards, R. Mechanical Weed Control. In Precision Crop Protection—the Challenge and Use of Heterogeneity; Springer: Dordrecht, The Netherlands, 2010; pp. 279–294. [Google Scholar]
- Timmons, F.L. A History of Weed Control in the United States and Canada. Weed Sci. 1970, 18, 294–307. [Google Scholar] [CrossRef]
- Hamill, A.S.; Holt, J.S.; Mallory-Smith, C.A. Contributions of Weed Science to Weed Control and Management 1. Weed Technol. 2004, 18, 1563–1565. [Google Scholar] [CrossRef]
- Powles, S.B.; Preston, C.; Bryan, I.B.; Jutsum, A.R. Herbicide Resistance: Impact and Management. Adv. Agron. 1996, 58, 57–93. [Google Scholar] [CrossRef]
- Shaner, D.L. Lessons Learned from the History of Herbicide Resistance. Weed Sci. 2014, 62, 427–431. [Google Scholar] [CrossRef]
- Culliney, T.W. Benefits of Classical Biological Control for Managing Invasive Plants. Crit. Rev. Plant Sci. 2005, 24, 131–150. [Google Scholar] [CrossRef]
- Gerhards, R.; Oebel, H. Practical Experiences with a System for Site-Specific Weed Control in Arable Crops Using Real-Time Image Analysis and GPS-Controlled Patch Spraying. Weed Res. 2006, 46, 185–193. [Google Scholar] [CrossRef]
- Utstumo, T.; Urdal, F.; Brevik, A.; Dørum, J.; Netland, J.; Overskeid, Ø.; Berge, T.W.; Gravdahl, J.T. Robotic In-Row Weed Control in Vegetables. Comput. Electron. Agric. 2018, 154, 36–45. [Google Scholar] [CrossRef]
- Bawden, O.; Kulk, J.; Russell, R.; McCool, C.; English, A.; Dayoub, F.; Lehnert, C.; Perez, T. Robot for Weed Species Plant-Specific Management. J. Field Robot. 2017, 34, 1179–1199. [Google Scholar] [CrossRef]
- Sori, H.; Inoue, H.; Hatta, H.; Ando, Y. Effect for a Paddy Weeding Robot in Wet Rice Culture. J. Robot. Mechatron. 2018, 30, 198–205. [Google Scholar] [CrossRef]
- Shapira, U.; Herrmann, I.; Karnieli, A.; Bonfil, D.J. Field Spectroscopy for Weed Detection in Wheat and Chickpea Fields. Int. J. Remote Sens. 2013, 34, 6094–6108. [Google Scholar] [CrossRef]
- Longchamps, L.; Panneton, B.; Samson, G.; Leroux, G.D.; Thériault, R. Discrimination of Corn, Grasses and Dicot Weeds by Their UV-Induced Fluorescence Spectral Signature. Precis. Agric. 2010, 11, 181–197. [Google Scholar] [CrossRef]
- Zheng, Y.; Zhu, Q.; Huang, M.; Guo, Y.; Qin, J. Maize and Weed Classification Using Color Indices with Support Vector Data Description in Outdoor Fields. Comput. Electron. Agric. 2017, 141, 215–222. [Google Scholar] [CrossRef]
- Nguyen Thanh Le, V.; Apopei, B.; Alameh, K. Effective Plant Discrimination Based on the Combination of Local Binary Pattern Operators and Multiclass Support Vector Machine Methods. Inf. Process. Agric. 2019, 6, 116–131. [Google Scholar] [CrossRef]
- Zhu, W.; Zhu, X. The Application of Support Vector Machine in Weed Classification. In Proceedings of the 2009 IEEE International Conference on Intelligent Computing and Intelligent Systems, Shanghai, China, 20–22 November 2009; Volume 4. [Google Scholar]
- Chechliński, Ł.; Siemiątkowska, B.; Majewski, M. A System for Weeds and Crops Identification—Reaching over 10 Fps on Raspberry Pi with the Usage of Mobilenets, Densenet and Custom Modifications. Sensors 2019, 19, 3787. [Google Scholar] [CrossRef]
- dos Santos Ferreira, A.; Matte Freitas, D.; Gonçalves da Silva, G.; Pistori, H.; Theophilo Folhes, M. Weed Detection in Soybean Crops Using ConvNets. Comput. Electron. Agric. 2017, 143, 314–324. [Google Scholar] [CrossRef]
- Asad, M.H.; Bais, A. Weed Detection in Canola Fields Using Maximum Likelihood Classification and Deep Convolutional Neural Network. Inf. Process. Agric. 2020, 7, 535–545. [Google Scholar] [CrossRef]
- Peteinatos, G.G.; Reichel, P.; Karouta, J.; Andújar, D.; Gerhards, R. Weed Identification in Maize, Sunflower, and Potatoes with the Aid of Convolutional Neural Networks. Remote Sens. 2020, 12, 4185. [Google Scholar] [CrossRef]
- Allmendinger, A.; Spaeth, M.; Saile, M.; Peteinatos, G.G.; Gerhards, R. Precision Chemical Weed Management Strategies: A Review and a Design of a New CNN-Based Modular Spot Sprayer. Agronomy 2022, 12, 1620. [Google Scholar] [CrossRef]
- Sahin, H.; Yalınkılıc, M. Using Electric Current as a Weed Control Method. Eur. J. Eng. Technol. Res. 2017, 2, 59. [Google Scholar] [CrossRef]
- Mwitta, C.; Rains, G.C.; Prostko, E. Evaluation of Diode Laser Treatments to Manage Weeds in Row Crops. Agronomy 2022, 12, 2681. [Google Scholar] [CrossRef]
- Sivakumar, A.N.V.; Li, J.; Scott, S.; Psota, E.; Jhala, A.J.; Luck, J.D.; Shi, Y. Comparison of Object Detection and Patch-Based Classification Deep Learning Models on Mid-to Late-Season Weed Detection in UAV Imagery. Remote Sens. 2020, 12, 2136. [Google Scholar] [CrossRef]
- Chen, D.; Lu, Y.; Li, Z.; Young, S. Performance Evaluation of Deep Transfer Learning on Multi-Class Identification of Common Weed Species in Cotton Production Systems. Comput. Electron. Agric. 2022, 198, 107091. [Google Scholar] [CrossRef]
- Bochkovskiy, A.; Wang, C.-Y.; Liao, H.-Y.M. YOLOv4: Optimal Speed and Accuracy of Object Detection. arXiv 2020, arXiv:2004.10934. [Google Scholar]
- Tan, M.; Pang, R.; Le, Q.V. EfficientDet: Scalable and Efficient Object Detection. In Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA, 14–19 June 2020; pp. 10778–10787. [Google Scholar]
- Duan, K.; Bai, S.; Xie, L.; Qi, H.; Huang, Q.; Tian, Q. CenterNet: Keypoint Triplets for Object Detection. In Proceedings of the IEEE International Conference on Computer Vision, Seoul, Republic of Korea, 27 October–2 November 2019; pp. 6568–6577. [Google Scholar]
- Everingham, M.; Van Gool, L.; Williams, C.K.I.; Winn, J.; Zisserman, A. The Pascal Visual Object Classes (VOC) Challenge. Int. J. Comput. Vis. 2010, 88, 303–338. [Google Scholar] [CrossRef]
- Redmon, J.; Divvala, S.; Girshick, R.; Farhadi, A. You Only Look Once: Unified, Real-Time Object Detection. In Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA, 27–30 June 2016. [Google Scholar]
- Shorten, C.; Khoshgoftaar, T.M. A Survey on Image Data Augmentation for Deep Learning. J. Big Data 2019, 6, 60. [Google Scholar] [CrossRef]
- Zhuang, F.; Qi, Z.; Duan, K.; Xi, D.; Zhu, Y.; Zhu, H.; Xiong, H.; He, Q. A Comprehensive Survey on Transfer Learning. Proc. IEEE 2021, 109, 43–76. [Google Scholar] [CrossRef]
- Redmon, J. Darknet: Open Source Neural Networks in C. Available online: https://pjreddie.com/darknet/ (accessed on 4 February 2021).
- Lin, T.Y.; Maire, M.; Belongie, S.; Hays, J.; Perona, P.; Ramanan, D.; Dollár, P.; Zitnick, C.L. Microsoft COCO: Common Objects in Context. In Proceedings of the 13th European Conference on Computer Vision–ECCV 2014, Zurich, Switzerland, 6–12 September 2014; Volume 8693. [Google Scholar]
- Abadi, M.; Barham, P.; Chen, J.; Chen, Z.; Davis, A.; Dean, J.; Devin, M.; Ghemawat, S.; Irving, G.; Isard, M.; et al. TensorFlow: A System for Large-Scale Machine Learning. In Proceedings of the 12th USENIX Symposium on Operating Systems Design and Implementation, OSDI 2016, Savannah, GA, USA, 2–4 November 2016. [Google Scholar]
- François Chollet Keras, 2015. Available online: https://github.com/keras-team/keras (accessed on 24 November 2022).
- TensorFlow. TensorFlow 2 Model Zoo. Available online: https://github.com/tensorflow/models/blob/master/research/object_detection/g3doc/tf2_detection_zoo.md (accessed on 14 March 2022).
- Rao, Y.; He, L.; Zhu, J. A Residual Convolutional Neural Network for Pan-Shaprening. In Proceedings of the RSIP 2017—International Workshop on Remote Sensing with Intelligent Processing, Shanghai, China, 18–21 May 2017. [Google Scholar]
- Padilla, R.; Netto, S.L.; Da Silva, E.A.B.; Netto, S.L. A Survey on Performance Metrics for Object-Detection Algorithms Compression of Power Systems Signals View Project A Survey on Performance Metrics for Object-Detection Algorithms. In Proceedings of the 2020 International Conference on Systems, Signals and Image Processing (IWSSIP), Niteroi, Brazil, 1–3 July 2020. [Google Scholar]
- McLaughlin, N.; Del Rincon, J.M.; Miller, P. Data-Augmentation for Reducing Dataset Bias in Person Re-Identification. In Proceedings of the AVSS 2015—12th IEEE International Conference on Advanced Video and Signal Based Surveillance, Karlsruhe, Germany, 25–28 August 2015. [Google Scholar]
- Jia, Y.; Wang, H.; Chen, W.; Wang, Y.; Yang, B. An Attention-Based Cascade R-CNN Model for Sternum Fracture Detection in X-ray Images. CAAI Trans. Intell. Technol. 2022, 7, 658–670. [Google Scholar] [CrossRef]
YOLOv4 | EfficientDet | CenterNet | |
---|---|---|---|
Number of stages | One-stage | One-stage | One-stage |
Backbone | CSPDarknet53 | EfficientNetB0 | Resnet101 |
Number of layers | 53 | 237 | 101 |
Object detection method | Anchor-based | Anchor-based | Anchor-free |
Input size | 416 × 416 | 512 × 512 | 512 × 512 |
Metric | YOLOv4 | CenterNet | EfficientDet |
---|---|---|---|
mAP@ IoU = 0.5–0.95 | 0.616 | 0.706 | 0.713 |
mAP@ IoU = 0.5 | 0.934 | 0.938 | 0.974 |
mAP@ IoU = 0.75 | 0.703 | 0.809 | 0.819 |
Average recall | 0.660 | 0.714 | 0.708 |
Weed Species | YOLOv4 | CenterNet | EfficientDet |
---|---|---|---|
Smallflower morningglory | 0.994 | 0.998 | 0.990 |
Sicklepod | 1.000 | 0.998 | 1.000 |
Pitted morningglory | 0.899 | 0.990 | 1.000 |
Ivyleaf morningglory | 0.998 | 0.987 | 1.000 |
Florida pusley | 1.000 | 1.000 | 1.000 |
Florida beggarweed | 1.000 | 1.000 | 0.998 |
Texas panicum | 0.999 | 0.999 | 1.000 |
Crabgrass | 0.997 | 0.991 | 0.999 |
Crowfoot grass | 0.808 | 0.957 | 1.000 |
Goosegrass | 1.000 | 0.967 | 1.000 |
Palmer amaranth | 0.712 | 0.911 | 0.926 |
Yellow nutsedge | 0.763 | 0.653 | 0.940 |
Purple nutsedge | 0.794 | 0.0006 | 0.0007 |
Platform | YOLOv4 | CenterNet | EfficientDet |
---|---|---|---|
Deep learning computer | 18 | 44 | 66 |
Jetson Xavier AGX | 80 | 140 | 102 |
Platform | YOLOv4 | CenterNet | EfficientDet |
---|---|---|---|
Deep learning computer | 51 | 40 | 22 |
Jetson Xavier AGX | 14 | 8 | 12 |
Metric | YOLOv4-Tiny | YOLOv4 |
---|---|---|
Precision | 0.81 | 0.95 |
Recall | 0.88 | 0.89 |
mAP @ IoU = 0.5 | 0.89 | 0.934 |
Inference on Jetson Xavier AGX (ms) | 24.5 | 80 |
FPS on Jetson Xavier AGX | 52 | 14 |
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. |
© 2024 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
Mwitta, C.; Rains, G.C.; Prostko, E. Evaluation of Inference Performance of Deep Learning Models for Real-Time Weed Detection in an Embedded Computer. Sensors 2024, 24, 514. https://doi.org/10.3390/s24020514
Mwitta C, Rains GC, Prostko E. Evaluation of Inference Performance of Deep Learning Models for Real-Time Weed Detection in an Embedded Computer. Sensors. 2024; 24(2):514. https://doi.org/10.3390/s24020514
Chicago/Turabian StyleMwitta, Canicius, Glen C. Rains, and Eric Prostko. 2024. "Evaluation of Inference Performance of Deep Learning Models for Real-Time Weed Detection in an Embedded Computer" Sensors 24, no. 2: 514. https://doi.org/10.3390/s24020514
APA StyleMwitta, C., Rains, G. C., & Prostko, E. (2024). Evaluation of Inference Performance of Deep Learning Models for Real-Time Weed Detection in an Embedded Computer. Sensors, 24(2), 514. https://doi.org/10.3390/s24020514