Tomato Leaf Disease Identification Method Based on Improved YOLOX
Abstract
:1. Introduction
- (1)
- A sample adaptive penalty coefficient is proposed, and a sample adaptive cross-entropy loss function is presented as the confidence loss of YOLOX.
- (2)
- A tomato leaf disease identification model based on YOLOX-MobileNetV3 is designed, allowing lightweight feature extraction.
- (3)
- The validated model was deployed on a Jetson Nano-embedded device. The model was shown to match the requirements for real-time, high-precision detection on embedded devices while also providing a viable option for tomato leaf disease identification.
2. Materials and Methods
2.1. Data Sources
2.2. Data Enhancement
2.3. Improved YOLOX Identification Method
2.3.1. Backbone Lightweighting
2.3.2. Loss Function Improvement
2.3.3. Improved Network Model Structure
2.4. Model Training
2.4.1. Model Evaluation Indicators
2.4.2. Experimental Operating Platform
2.4.3. Parameter Settings
3. Results and Discussion
3.1. Analysis and Comparison of Results
3.1.1. Analysis of Identification Results
3.1.2. Loss Function Comparison Experiments
3.1.3. Ablation Experiments
3.1.4. Backbone Comparison Experiment
3.2. Tomato Leaf Disease Detection Effect in Embedded Devices
4. Conclusions
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
References
- Hassan, S.M.; Jasinski, M.; Leonowicz, Z.; Jasinska, E.; Maji, A.K. Plant Disease Identification Using Shallow Convolutional Neural Network. Agronomy 2021, 11, 2388. [Google Scholar] [CrossRef]
- Fuentes, A.; Yoon, S.; Kim, S.C.; Park, D.S. A robust deep-learning-based detector for real-time tomato plant diseases and pests recognition. Sensors 2017, 17, 2022. [Google Scholar] [CrossRef] [PubMed]
- Xiong, Y.; Liang, L.; Wang, L.; She, J.; Wu, M. Identification of cash crop diseases using automatic image segmentation algorithm and deep learning with expanded dataset. Comput. Electron. Agric. 2020, 177, 105712. [Google Scholar] [CrossRef]
- Minaee, S.; Boykov, Y.Y.; Porikli, F.; Plaza, A.J.; Kehtarnavaz, N.; Terzopoulos, D. Image segmentation using deep learning: A survey. IEEE Trans. Pattern Anal. Mach. Intell. 2021, 44, 3523–3542. [Google Scholar] [CrossRef] [PubMed]
- Zhao, Z.Q.; Zheng, P.; Xu, S.T.; Wu, X. Object detection with deep learning: A review. IEEE Trans. Neural Netw. Learn. Syst. 2019, 30, 3212–3232. [Google Scholar] [CrossRef]
- Chen, X.; Wan, M.J.; Ma, C. Recognition of small targets in remote sensing image using multi-scale feature fusion-based shot multi-box detector. Opt. Precis. Eng. 2021, 29, 2672–2682. [Google Scholar] [CrossRef]
- Wu, Z.; Hou, B.; Ren, B.; Ren, Z.; Wang, S.; Jiao, L. A deep detection network based on interaction of instance segmentation and object detection for SAR images. Remote Sens. 2021, 13, 2582. [Google Scholar] [CrossRef]
- Ghosal, S.; Blystone, D.; Singh, A.K.; Ganapathysubramanian, B.; Singh, A.; Sarkar, S. An explainable deep machine vision framework for plant stress phenotyping. Proc. Natl. Acad. Sci. USA 2018, 115, 4613–4618. [Google Scholar] [CrossRef]
- Liang, Y.; Qiu, R.Z.; Li, Z.P. Identification method of major rice pests based on YOLO v5 and multi-source datasets. Trans. Chin. Soc. Agric. Mach. 2022, 53, 250–258. [Google Scholar] [CrossRef]
- Yu, X.D.; Yang, M.J.; Zhang, H.Q. Research and application of crop ciseases cetection method based on transfer learning. Trans. Chin. Soc. Agric. Mach. 2020, 51, 252–258. [Google Scholar] [CrossRef]
- Ouhami, M.; Hafiane, A.; Es-Saady, Y.; Hajji, E.M.; Canals, R. Computer vision, IoT and data fusion for crop disease detection using machine learning: A survey and ongoing research. Remote Sens. 2021, 13, 2486. [Google Scholar] [CrossRef]
- Abbas, A.; Jain, S.; Gour, M.; Vankudothu, S. Tomato plant disease detection using transfer learning with C-GAN synthetic images. Comput. Electron. Agric. 2021, 187, 106279. [Google Scholar] [CrossRef]
- Zhang, K.; Wu, Q.; Chen, Y. Detecting soybean leaf disease from synthetic image using multi-feature fusion faster R-CNN. Comput. Electron. Agric. 2021, 183, 106064. [Google Scholar] [CrossRef]
- Saeed, A.; Abdel-Aziz, A.A.; Mossad, A.; Abdelhamid, M.A.; Alkhaled, A.Y.; Mayhoub, M. Smart Detection of Tomato Leaf Diseases Using Transfer Learning-Based Convolutional Neural Networks. Agriculture 2023, 13, 139. [Google Scholar] [CrossRef]
- Karthik, R.; Hariharan, M.; Anand, S.; Mathikshara, P.; Johnson, A.; Menaka, R. Attention embedded residual CNN for disease detection in tomato leaves. Appl. Soft Comput. 2020, 86, 105933. [Google Scholar] [CrossRef]
- Sozzi, M.; Cantalamessa, S.; Cogato, A.; Kayad, A.; Marinello, F. Automatic bunch detection in white grape varieties using YOLOv3, YOLOv4, and YOLOv5 deep learning algorithms. Agronomy 2022, 12, 319. [Google Scholar] [CrossRef]
- Wu, D.; Lv, S.; Jiang, M.; Song, H. Using channel pruning-based YOLO v4 deep learning algorithm for the real-time and accurate detection of apple flowers in natural environments. Comput. Electron. Agric. 2020, 178, 105742. [Google Scholar] [CrossRef]
- Li, R.; Wu, Y. Improved YOLO v5 Wheat Ear Detection Algorithm Based on Attention Mechanism. Electronics 2022, 11, 1673. [Google Scholar] [CrossRef]
- 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 European Conference on Computer Vision, Amsterdam, The Netherlands, 11–14 October 2016; pp. 21–37. [Google Scholar]
- Liu, Y.; Gao, G.Q. Identification of multiple leaf diseases using improved SqueezeNet model. Trans. Chin. Soc. Agric. Eng. 2021, 37, 187–195. [Google Scholar] [CrossRef]
- Guo, X.Q.; Fan, T.J.; Shu, X. Tomato leaf diseases recognition based on improved Multi–Scale AlexNet. Trans. Chin. Soc. Agric. Eng. 2019, 35, 162–169. [Google Scholar] [CrossRef]
- Lin, T.; Goyal, P.; Girshick, R.; He, K.; Dollár, P. Focal Loss for Dense Object Detection. IEEE Trans. Pattern Anal. Mach. Intell. 2020, 42, 318–327. [Google Scholar] [CrossRef] [PubMed]
- Li, X.; Su, H.; Liu, G. Insulator Defect Recognition Based on Global Detection and Local Segmentation. IEEE Access 2020, 8, 59934–59946. [Google Scholar] [CrossRef]
- Zhu, J.; Park, T.; Isola, P.; Efros, A.A. Unpaired Image-to-Image Translation Using Cycle-Consistent Adversarial Networks. In Proceedings of the 2017 IEEE International Conference on Computer Vision (ICCV), Venice, Italy, 22–29 October 2017; pp. 2242–2251. [Google Scholar]
- Howard, A.; Sandler, M.; Chu, G.; Chen, L.C.; Chen, B.; Tan, M.; Wang, W.; Zhu, Y.; Pang, R.; Vasudevan, V.; et al. Searching for Mobilenetv3. In Proceedings of the IEEE/CVF International Conference on Computer Vision on Seoul, Seoul, Republic of Korea, 27 October–2 November 2019; pp. 1314–1324. [Google Scholar]
- Sandler, M.; Howard, A.; Zhu, M.; Zhmoginov, A.; Chen, L.C. Mobilenetv2: Inverted Residuals and Linear Bottlenecks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, CA, USA, 18–23 June 2018; pp. 4510–4520. [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, CA, 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]
- Ren, S.; He, K.; Girshick, R.; Sun, J. Faster R-CNN: Towards Real-Time Object Detection with Region Proposal Networks. IEEE Trans. Neural Netw. 2017, 39, 1137–1149. [Google Scholar] [CrossRef] [PubMed]
- Han, K.; Wang, Y.; Tian, Q.; Guo, J.; Xu, C.; Xu, C. GhostNet: More features from cheap operations. In Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA, 14–19 June 2020; pp. 1577–1586. [Google Scholar]
- Tan, M.; Pang, R.; Le, Q.V. Efficientdet: Scalable and Efficient Object Detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA, 13–19 June 2020; pp. 10781–10790. [Google Scholar]
Types of Leaf Diseases | Original Dataset | Sample Balance | Data Enhancement |
---|---|---|---|
Bacterial spot | 2127 | 2127 | 7445 |
Early blight | 1000 | 2000 | 7000 |
Healthy | 1590 | 1590 | 5565 |
Late blight | 1909 | 1909 | 6682 |
Leaf mold | 1000 | 2000 | 7000 |
Septoria leaf spot | 1771 | 1771 | 6199 |
Two-spotted spider mite | 1676 | 1676 | 5866 |
Target spot | 1404 | 2000 | 7000 |
Mosaic virus | 1000 | 2000 | 7000 |
Yellow leaf curl virus | 5357 | 2200 | 7700 |
All | 18,834 | 19,273 | 67,457 |
Input | Operator | SE | #Out | Exp Size | S | NL |
---|---|---|---|---|---|---|
2242 × 3 | Conv2d | - | 16 | - | 2 | HS |
1122 × 16 | bneck, 3 × 3 | - | 16 | 16 | 1 | RE |
1122 × 16 | bneck, 3 × 3 | - | 24 | 64 | 2 | RE |
562 × 24 | bneck, 3 × 3 | - | 24 | 72 | 1 | RE |
562 × 24 | bneck, 5 × 5 | ✓ | 40 | 72 | 2 | RE |
282 × 40 | bneck, 5 × 5 | ✓ | 40 | 120 | 1 | RE |
282 × 40 | bneck, 5 × 5 | ✓ | 40 | 120 | 1 | RE |
282 × 40 | bneck, 3 × 3 | - | 80 | 240 | 2 | HS |
142 × 80 | bneck, 3 × 3 | - | 80 | 200 | 1 | HS |
142 × 80 | bneck, 3 × 3 | - | 80 | 184 | 1 | HS |
142 × 80 | bneck, 3 × 3 | - | 80 | 184 | 1 | HS |
142 × 80 | bneck, 3 × 3 | ✓ | 112 | 480 | 1 | HS |
142 × 112 | bneck, 3 × 3 | ✓ | 112 | 672 | 1 | HS |
142 × 112 | bneck, 5 × 5 | ✓ | 160 | 672 | 2 | HS |
72 × 160 | bneck, 5 × 5 | ✓ | 160 | 960 | 1 | HS |
72 × 160 | bneck, 5 × 5 | ✓ | 160 | 960 | 1 | HS |
72 × 160 | Conv2d 1 × 1 | - | 960 | - | 1 | HS |
72 × 960 | pool, 7 × 7 | - | - | - | 1 | - |
12 × 960 | Conv2d 1 × 1, NBN | - | 1280 | - | 1 | HS |
12 × 1280 | Conv2d 1 × 1, NBN | - | k | - | 1 | - |
Network Model | Backbone | CBAM | LBCE−β | mAP/% | FLOPs/109 | Size/Mb | FPS |
---|---|---|---|---|---|---|---|
YOLOX | CSPDarkNet53 | - | - | 97.10 | 26.78 | 68.53 | 87.49 |
✓ | - | 97.62 | 26.82 | 69.20 | 86.43 | ||
- | ✓ | 97.68 | 26.78 | 68.53 | 87.49 | ||
MobileNetV3 | - | - | 95.61 | 14.84 | 44.22 | 134.77 | |
✓ | - | 96.47 | 14.85 | 44.31 | 129.87 | ||
- | ✓ | 97.32 | 14.84 | 44.22 | 134.76 | ||
✓ | ✓ | 98.56 | 14.85 | 44.31 | 131.41 |
Network Model | mAP/% | FLOPs/109 | Size/Mb | FPS |
---|---|---|---|---|
Faster RCNN | 98.77 | 78.16 | 315.32 | 25.11 |
RetinaNet | 96.13 | 83.28 | 278.11 | 26.87 |
YOLOX-GhostNet | 97.82 | 13.56 | 46.77 | 102.25 |
YOLOX-EfficientNet | 97.06 | 11.63 | 47.78 | 81.57 |
YOLOX-MobileNetV3 | 98.56 | 14.85 | 44.31 | 131.41 |
Network Model | Time Spent in the Build Phase/s | FPS |
---|---|---|
YOLOX | 27.16 | 2.13 |
YOLOX-MobilenetV3 | 22.83 | 3.57 |
YOLOX-MobilenetV3-TensorRT(FP32) | 13.41 | 7.14 |
YOLOX-MobilenetV3-TensorRT(FP16) | 5.43 | 11.11 |
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, W.; Zhai, Y.; Xia, Y. Tomato Leaf Disease Identification Method Based on Improved YOLOX. Agronomy 2023, 13, 1455. https://doi.org/10.3390/agronomy13061455
Liu W, Zhai Y, Xia Y. Tomato Leaf Disease Identification Method Based on Improved YOLOX. Agronomy. 2023; 13(6):1455. https://doi.org/10.3390/agronomy13061455
Chicago/Turabian StyleLiu, Wenbo, Yongsen Zhai, and Yu Xia. 2023. "Tomato Leaf Disease Identification Method Based on Improved YOLOX" Agronomy 13, no. 6: 1455. https://doi.org/10.3390/agronomy13061455
APA StyleLiu, W., Zhai, Y., & Xia, Y. (2023). Tomato Leaf Disease Identification Method Based on Improved YOLOX. Agronomy, 13(6), 1455. https://doi.org/10.3390/agronomy13061455