Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
. 2025 Jan 8;20(1):e0312112.
doi: 10.1371/journal.pone.0312112. eCollection 2025.

Detection and recognition of foreign objects in Pu-erh Sun-dried green tea using an improved YOLOv8 based on deep learning

Affiliations

Detection and recognition of foreign objects in Pu-erh Sun-dried green tea using an improved YOLOv8 based on deep learning

Houqiao Wang et al. PLoS One. .

Erratum in

Abstract

The quality and safety of tea food production is of paramount importance. In traditional processing techniques, there is a risk of small foreign objects being mixed into Pu-erh sun-dried green tea, which directly affects the quality and safety of the food. To rapidly detect and accurately identify these small foreign objects in Pu-erh sun-dried green tea, this study proposes an improved YOLOv8 network model for foreign object detection. The method employs an MPDIoU optimized loss function to enhance target detection performance, thereby increasing the model's precision in targeting. It incorporates the EfficientDet high-efficiency target detection network architecture module, which utilizes compound scale-centered anchor boxes and an adaptive feature pyramid to achieve efficient detection of targets of various sizes. The BiFormer bidirectional attention mechanism is introduced, allowing the model to consider both forward and backward dependencies in sequence data, significantly enhancing the model's understanding of the context of targets in images. The model is further integrated with sliced auxiliary super-inference technology and YOLOv8, which subdivides the image and conducts in-depth analysis of local features, significantly improving the model's recognition accuracy and robustness for small targets and multi-scale objects. Experimental results demonstrate that, compared to the original YOLOv8 model, the improved model has seen increases of 4.50% in Precision, 5.30% in Recall, 3.63% in mAP, and 4.9% in F1 score. When compared with the YOLOv7, YOLOv5, Faster-RCNN, and SSD network models, its accuracy has improved by 3.92%, 7.26%, 14.03%, and 11.30%, respectively. This research provides new technological means for the intelligent transformation of automated color sorters, foreign object detection equipment, and intelligent sorting systems in the high-quality production of Yunnan Pu-erh sun-dried green tea. It also provides strong technical support for the automation and intelligent development of the tea industry.

PubMed Disclaimer

Conflict of interest statement

The authors have declared that no competing interests exist.

Figures

Fig 1
Fig 1. Sample data set preparation.
Fig 2
Fig 2. Data enhancement processing.
Fig 3
Fig 3. Data information for the data set label.
Fig 4
Fig 4. 5-Fold cross validation.
Fig 5
Fig 5. Improved YOLOv8 model structure.
Fig 6
Fig 6. MPDIoU structure parameter diagram.
Fig 7
Fig 7. EfficientDet network structure diagram.
Fig 8
Fig 8. EfficientDet network structure diagram.
Fig 9
Fig 9. Network structure of FPN and PANet.
Fig 10
Fig 10. BiFPN network structure.
Fig 11
Fig 11. Overall structure of BiFormer.
Fig 12
Fig 12. The principle of slice-assisted super inference.
Fig 13
Fig 13. Grad-CAM thermal maps related to ablation experiments.
Fig 14
Fig 14. Change curve of loss function of improved model.
Fig 15
Fig 15. Curves of Precision, Recall and equilibrium score F1.
Fig 16
Fig 16. Comparison of detection results of different models.

Similar articles

Cited by

References

    1. Yiqing Z, Protection B. Overview of Chinese Tea Culture Landscape. International Council on Monuments and Sites. 2021; 11; 31.
    1. He Y. Terroir Exploration: A Case Study of Jingmai Mountain Tea Culture Tourism. 2023. http://hdl.handle.net/10579/25646.
    1. Dehui Z. Research Article Application of Control System Based on S7-300 in the Producting of Pu-erh Tea. Advance Journal of Food Science and Technology. 2014; 6(12); 1335–1338.
    1. Ho K, Haufe T, Ferruzzi M, Neilson A. Production and polyphenolic composition of tea. Nutrition Today. 2018; 53(6); 268–278.
    1. Heiss M. L, Heiss R. J. The Tea Enthusiast’s Handbook: A Guide to the World’s Best Teas. Ten Speed Press; 2012.

LinkOut - more resources