Lightweight YOLOv5s-Based Machine Vision System for Real-Time Potato Defect Detection
DOI:
https://doi.org/10.6911/Keywords:
Lightweight; YOLOv5; potato defects; real-time detection.Abstract
To solve the drawbacks of traditional potato defect detection, such as heavy manual dependence, low efficiency, strong subjectivity and poor adaptability to complex scenarios, this study proposes a real-time machine vision detection system based on improved lightweight YOLOv5s. In this research, the YOLOv5s model is lightweightly modified, and GhostNet is used to replace the original CSPDarknet backbone network, which reduces model complexity while retaining the core feature extraction capability. The experimental results show that on the self-built dataset covering four types of potato defects including damage, sprouting, scab and dry rot, the Precision, Recall and mean Average Precision (mAP) of the improved YOLOv5s model reach 94.2%, 92.2% and 95.7% respectively, with the model size reduced by 26%. For the real-time detection of potato defects, the BoT-SORT multi-object tracking algorithm is integrated into the YOLOv5 detection framework. Compared with classic multi-object tracking algorithms including SORT, DeepSORT and ByteTrack, BoT-SORT achieves the best overall performance and obtains optimal values in three core evaluation metrics of HOTA, MOTA and IDF1, which are 95.3%, 99.7% and 98.8% correspondingly. Additional experimental verification demonstrates that when the conveyor belt speed is no higher than 62 mm/s, the improved lightweight model maintains a detection accuracy of no less than 94.3% and a tracking accuracy of 100%, and its operating speed fully meets the requirements of real-time detection. The designed system comprehensively balances detection accuracy, lightweight performance and real-time performance, which provides a reliable reference for meeting the practical demands of online real-time potato defect detection.
Downloads
References
[1] Zhang H, Fen X U, Yu W U, et al. Progress of potato staple food research and industry development in China[J]. Journal of integrative agriculture, 2017, 16(12): 2924-2932.
[2] Fleming S A, Morris J R. Perspective: potatoes, quality carbohydrates, and dietary patterns[J]. Advances in Nutrition, 2024, 15(1): 100138.
[3] Liao H, Wang G, Jin S, et al. HCRP-YOLO: A lightweight algorithm for potato defect detection[J]. Smart Agricultural Technology, 2025, 10: 100849.
[4] Garhwal A S, Pullanagari R R, Li M, et al. Hyperspectral imaging for identification of Zebra Chip disease in potatoes[J]. Biosystems Engineering, 2020, 197: 306-317.
[5] López-Maestresalas A, Keresztes J C, Goodarzi M, et al. Non-destructive detection of blackspot in potatoes by Vis-NIR and SWIR hyperspectral imaging[J]. Food Control, 2016, 70: 229-241.
[6] Al Riza D F, Widodo S, Yamamoto K, et al. External defects and severity level evaluation of potato using single and multispectral imaging in near infrared region[J]. Information Processing in Agriculture, 2024, 11(1): 80-90.
[7] El-Mesery H S, Mao H, Abomohra A E. Applications of Non-destructive Technologies for Agricultural and Food Products Quality Inspection. Sensors, 2019.
[8] Zeng T, Li S, Song Q, et al. Lightweight tomato real-time detection method based on improved YOLO and mobile deployment[J]. Computers and electronics in agriculture, 2023, 205: 107625.
[9] Peng K, Ma W, Lu J, et al. Application of machine vision technology in citrus production[J]. Applied Sciences, 2023, 13(16): 9334.
[10] Elmasry G, Cubero S, Moltó E, et al. In-line sorting of irregular potatoes by using automated computer-based machine vision system[J]. Journal of Food Engineering, 2012, 112(1-2): 60-68.
[11] Yang L, Mu D, Xu Z, et al. Apple Surface Defect Detection Based on Gray Level Co-Occurrence Matrix and Retinex Image Enhancement[J]. Applied Sciences, 2023, 13(22): 12481.
[12] Barnes M, Duckett T, Cielniak G, et al. Visual detection of blemishes in potatoes using minimalist boosted classifiers[J]. Journal of Food Engineering, 2010, 98(3): 339-346.
[13] Kok Z H, Shariff A R M, Alfatni M S M, et al. Support vector machine in precision agriculture: a review[J]. Computers and Electronics in Agriculture, 2021, 191: 106546.
[14] Tan A, Zhou G, He M. Surface defect identification of Citrus based on KF-2D-Renyi and ABC-SVM[J]. Multimedia Tools and Applications, 2021, 80(6): 9109-9136.
[15] Kamilaris A, Prenafeta-Boldú F X. Deep learning in agriculture: A survey[J]. Computers and electronics in agriculture, 2018, 147: 70-90.
[16] Lecun Y, Bengio Y, Hinton G. Deep learning[J]. nature, 2015, 521(7553): 436-444.
[17] Li M, Zhang Z, Lei L, et al. Agricultural greenhouses detection in high-resolution satellite images based on convolutional neural networks: Comparison of faster R-CNN, YOLO v3 and SSD[J]. Sensors, 2020, 20(17): 4938.
[18] Jiang P, Ergu D, Liu F, et al. A Review of Yolo algorithm developments[J]. Procedia computer science, 2022, 199: 1066-1073.
[19] Yu Y, Zhang K, Yang L, et al. Fruit detection for strawberry harvesting robot in non-structural environment based on Mask-RCNN[J]. Computers and electronics in agriculture, 2019, 163: 104846.
[20] Dai G, Hu L, Fan J, et al. A deep learning-based object detection scheme by improving YOLOv5 for sprouted potatoes datasets[J]. IEEE Access, 2022, 10: 85416-85428.
[21] Badgujar C M, Poulose A, Gan H. Agricultural object detection with You Only Look Once (YOLO) Algorithm: A bibliometric and systematic literature review[J]. Computers and Electronics in Agriculture, 2024, 223: 109090.
[22] Xu X, Zhou B, Li W, et al. A method for detecting persimmon leaf diseases using the lightweight YOLOv5 model[J]. Expert Systems with Applications, 2025, 284: 127567.
[23] Wang D, He D. Channel pruned YOLO V5s-based deep learning approach for rapid and accurate apple fruitlet detection before fruit thinning[J]. Biosystems Engineering, 2021, 210: 271-281.
[24] Huangfu Z, Li S, Yan L. Ghost-YOLO v8: An Attention-Guided Enhanced Small Target Detection Algorithm for Floating Litter on Water Surfaces[J]. Computers, Materials and Continua, 2024, 80(3): 3713-3731.
[25] Manzoor S H, Zhang Z, Li H, et al. Optimized Yolov5s-Im for real-time apple flower detection in drone-based pollination[J]. Smart Agricultural Technology, 2025, 12: 101150.
[26] Aharon N, Orfaig R, Bobrovsky B-Z. BoT-SORT: Robust associations multi-pedestrian tracking[J]. arXiv preprint arXiv:2206.14651, 2022.
[27] Petersson M, Kifle Solomon N. Object Tracking Evaluation: BoT-SORT & ByteTrack with YOLOv8: A Comparison of Accuracy and Computational Efficiency, 2024.
Downloads
Published
Issue
Section
License
Copyright (c) 2026 World Scientific Research Journal

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.




