Chili Ripeness Level Detection with YOLOv8 and Fuzzy Logic for Harvest Decision Making

Authors

  • Ninda Yulia Dwi Rahmawati Universitas Negeri Semarang
  • Febry Putra Rochim Universitas Negeri Semarang

DOI:

https://doi.org/10.23960/jtepl.v14i5.1807-1818
Abstract View: 130

Keywords:

Chili, Fuzzy Logic, Harvest Decision, Object Detection, YOLOv8

Abstract

Conventional chili harvesting relies on subjective human judgment, resulting in inconsistencies that necessitate a computer vision-based automation system. This study develops a decision support system integrating YOLOv8 for object detection and Mamdani fuzzy logic to assess chili ripeness levels. The YOLOv8 model was trained on 5,598 annotated chili images divided into three ripeness categories: ripe, unripe, and defective (rotten, diseased, or physically damaged), using an 80:20 training-testing split. YOLOv8 classification results serve as inputs to a fuzzy inference system that outputs three linguistic harvest decisions: delay, partial, or full harvest. Experimental evaluation indicates that YOLOv8 achieved 91.2% accuracy, 89.6% precision, and 87.3% recall on the test set. The fuzzy logic system obtained 88% accuracy in harvest decision-making on unseen data, demonstrating output consistency across repeated inferences. Overlapping triangular membership functions enable the fuzzy system to manage intra-class variations and image noise, thereby improving adaptability. These results confirm the feasibility of integrating YOLOv8 and fuzzy logic to support reliable and adaptive automated harvest decisions in chili farming, with potential application in precision agriculture.

Downloads

Download data is not yet available.

Author Biographies

Ninda Yulia Dwi Rahmawati, Universitas Negeri Semarang

Department of Electrical Engineering, Faculty of Engineering

Febry Putra Rochim, Universitas Negeri Semarang

Department of Electrical Engineering, Faculty of Engineering

References

Aishwarya, M.P., & Reddy, A.P. (2024). Dataset of chilli and onion plant leaf images for classification and detection. Data in Brief, 54, 110524. https://doi.org/10.1016/j.dib.2024.110524

Archana, R., & Jeevaraj, P.S.E. (2024). Deep learning models for digital image processing: A review. Artif Intell Rev, 57, 11. https://doi.org/10.1007/s10462-023-10631-z

Badgujar, C.M., Poulose, A., & Gan, H. (2024). Agricultural object detection with You Only Look Once (YOLO) algorithm: A bibliometric and systematic literature review. Computers and Electronics in Agriculture, 223, 109090. https://doi.org/10.1016/j.compag.2024.109090

Benos, L., Tagarakis, A.C., Dolias, G., Berruto, R., Kateris, D., & Bochtis, D. (2021). Machine learning in agriculture: A comprehensive updated review. Sensors, 21(11), 1–55. https://doi.org/10.3390/s21113758

Camacho, J.C., & Morocho-Cayamcela, M.E. (2023). Mask R-CNN and YOLOv8 comparison to perform tomato maturity recognition task. In Communications in Computer and Information Science (Vol. 1885, pp. 382–396). Springer. https://doi.org/10.1007/978-3-031-45438-7_26

Chen, Y., Xu, H., Chang, P., Huang, Y., Zhong, F., Jia, Q., Chen, L., Zhong, H., & Liu, S. (2024). CES-YOLOv8: Strawberry maturity detection based on the improved YOLOv8. Agronomy, 14(7), 1353. https://doi.org/10.3390/agronomy14071353

Cordeiro, L.dos-S., Nääs, I.de-A., & Okano, M.T. (2025). Smart postharvest management of strawberries: YOLOv8-driven detection of defects, diseases, and maturity. AgriEngineering, 7(8), 246. https://doi.org/10.3390/agriengineering7080246

Gamani, A.-R.A., Arhin, I., & Asamoah, A.K. (2024). Performance evaluation of YOLOv8 model configurations, for instance segmentation of strawberry fruit development stages in an open field environment. arXiv. https://doi.org/10.48550/arXiv.2408.05661

Gao, X., Ding, J., Zhang, R., & Xi, X. (2025). YOLOv8n-CA: Improved YOLOv8n model for tomato fruit recognition at different stages of ripeness. Agronomy, 15(1), 188. https://doi.org/10.3390/agronomy15010188

Gómez, A.C., Bejarano, L.A., & Espitia, H.E. (2025). Model for agricultural production in Colombia using a neuro-fuzzy inference system. Computers, 14(5), 168. https://doi.org/10.3390/computers14050168

He, L., Wu, D., Zheng, X., Xu, F., Lin, S., Wang, S., Ni, F., & Zheng, F. (2025). RLK-YOLOv8: Multi-stage detection of strawberry fruits throughout the full growth cycle in greenhouses based on large kernel convolutions and improved YOLOv8. Frontiers in Plant Science, 16, 1552553. https://doi.org/10.3389/fpls.2025.1552553

Joshi, H. (2024). Edge-AI for agriculture: Lightweight vision models for disease detection in resource-limited settings. arXiv. https://doi.org/10.48550/arXiv.2412.18635

Liang, X., Jia, H., Wang, H., Zhang, L., Li, D., Wei, Z., You, H., Wan, X., Li, R., Li, W., & Yang, M. (2025). ASE-YOLOv8n: A method for cherry tomato ripening detection. Agronomy, 15(5), 1088. https://doi.org/10.3390/agronomy15051088

Liu, K.E., Ma, J., Lai, E.M.-K., Data Science, & Artificial Intelligence. (2018). A dynamic fuzzy rule and attribute management framework for fuzzy inference systems in high-dimensional data. Artificial Intelligence, 1(1), 1–23. https://doi.org/10.48550/arXiv.2504.19148

Ma, Y., & Zhang, S. (2025). YOLOv8-CBSE: An enhanced computer vision model for detecting the maturity of chili pepper in the natural environment. Agronomy, 15(3), 537. https://doi.org/10.3390/agronomy15030537

Moya, V., Quito, A., Pilco, A., Vásconez, J.P., & Vargas, C. (2024). Crop detection and maturity classification using a YOLOv5-based image analysis. Emerging Science Journal, 8(2), 496–512. https://doi.org/10.28991/ESJ-2024-08-02-08

Nagpal, R., Long, S., Jahagirdar, S., Liu, W., Fazackerley, S., Lawrence, R., & Singh, A. (2023). An application of deep learning for sweet cherry phenotyping using YOLO object detection. arXiv, 1-18. https://doi.org/10.48550/arXiv.2302.06698

Rohaeti, E., Muzayanah, K., Septaningsih, D.A., & Rafi, M. (2019). Fast analytical method for authentication of chili powder from synthetic dyes using UV-Vis spectroscopy in combination with chemometrics. Indonesian Journal of Chemistry, 19(3), 668–674. https://doi.org/10.22146/ijc.36297

Saatchi, R. (2024). Fuzzy logic concepts, developments and implementation. Information (Switzerland), 15(10), 656. https://doi.org/10.3390/info15100656

Saktriawindarta, R., & Kusrini, K. (2024). Metode klasifikasi tingkat kematangan buah dan sayuran: Tinjauan sistematis. G-Tech: Jurnal Teknologi Terapan, 8(4), 2344–2354. https://doi.org/10.70609/gtech.v8i4.5067

Sapkota, R., Ahmed, D., & Karkee, M. (2024). Comparing YOLOv8 and Mask R-CNN for instance segmentation in complex orchard environments. Artificial Intelligence in Agriculture, 13, 84–99. https://doi.org/10.1016/j.aiia.2024.07.001

Schneider, F., Swiatek, J., & Jelali, M. (2024). Detection of growth stages of chilli plants in a hydroponic grower using machine vision and YOLOv8 deep learning algorithms. Sustainability, 16(15), 6420. https://doi.org/10.3390/su16156420

Shorten, C., & Khoshgoftaar, T.M. (2019). A survey on image data augmentation for deep learning. Journal of Big Data, 6(1), 60. https://doi.org/10.1186/s40537-019-0197-0

Shrivastava, A., Pfister, T., Tuzel, O., Susskind, J., Wang, W., & Webb, R. (2017). Learning from simulated and unsupervised images through adversarial training. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (pp. 2242–2251). IEEE. https://doi.org/10.1109/CVPR.2017.241

Sun, H., Zheng, Q., Yao, W., Wang, J., Liu, C., Yu, H., & Chen, C. (2025). An improved YOLOv8 model for detecting four stages of tomato ripening and its application deployment in a greenhouse environment. Agriculture, 15(9), 1–33. https://doi.org/10.3390/agriculture15090936

Terven, J., Córdova-Esparza, D.M., & Romero-González, J.A. (2023). A comprehensive review of YOLO architectures in computer vision: From YOLOv1 to YOLOv8 and YOLO-NAS. Machine Learning and Knowledge Extraction, 5(4), 1680–1716. https://doi.org/10.3390/make5040083

Vincent, D.R., Deepa, N., Elavarasan, D., Srinivasan, K., Chauhdary, S.H., & Iwendi, C. (2019). Sensors driven AI-based agriculture recommendation model for assessing land suitability. Sensors, 19(17), 3667. https://doi.org/10.3390/s19173667

Wang, L., Zhao, Y., Xiong, Z., Wang, S., Li, Y., & Lan, Y. (2022). Fast and precise detection of litchi fruits for yield estimation based on the improved YOLOv5 model. Frontiers in Plant Science, 13, 965425. https://doi.org/10.3389/fpls.2022.965425

Wang, S., Xiang, J., Chen, D., & Zhang, C. (2024). A method for detecting tomato maturity based on deep learning. Applied Sciences, 14(23), 1–24. https://doi.org/10.3390/app142311111

Xu, D., Ren, R., Zhao, H., & Zhang, S. (2024). Intelligent detection of muskmelon ripeness in greenhouse environment based on YOLO-RFEW. Agronomy, 14(6), 1091. https://doi.org/10.3390/agronomy14061091

Zophie, J., & Triharminto, H.H. (2020). Implemetasi algoritma You Only Look Once ( YOLO ) menggunakan web camera untuk mendeteksi objek statis dan dinamis. JurnalTNIAngkatan Udara, 1(1), 98-109.

Zheng, S., Jia, X., He, M., Zheng, Z., Lin, T., & Weng, W. (2024). Tomato recognition method based on the YOLOv8-Tomato model in complex greenhouse environments. Agronomy, 14(8), 1764. https://doi.org/10.3390/agronomy14081764

Zhu, L., & Spachos, P. (2021). Support vector machine and YOLO for a mobile food grading system. Internet of Things, 13, 100359. https://doi.org/10.1016/j.iot.2021.100359

Downloads

Published

2025-10-16

How to Cite

Rahmawati, N. Y. D., & Rochim, F. P. (2025). Chili Ripeness Level Detection with YOLOv8 and Fuzzy Logic for Harvest Decision Making. Jurnal Teknik Pertanian Lampung (Journal of Agricultural Engineering), 14(5), 1807–1818. https://doi.org/10.23960/jtepl.v14i5.1807-1818