Comparative Analysis of YOLOv5n and YOLOv8n Deep Learning Models for Precision Detection of Klowong Defects in Batik Fabric - Hamidi, Rifqi Restu; Herliansyah, Muhammad Kusumawan; Atmaja, Denny Sukma Eka; Sudiarso, Andi (Universitas Pendidikan Nasional, 2025)
This study presents a comparative analysis of two deep learning object detection models, YOLOv5n and YOLOv8n, for the precies identification of Klowong defects in batik fabric. The evaluation was carried out using a custom dataset consisting of 3,138 annotated images, with 921 allocated for testing and containing 1,295 defect instances across nine defect classes. The main findings show that YOLOv8n outperforms YOLOv5n in both speed and accuracy. YOLOv8n achieved a higher F1-score of 0.87 at a lower confidence threshold (0.297), compared to YOLOv5n’s F1-score of 0.86 at a higher threshold (0.46). In addition, YOLOv8n reduced training time significantly (0.320 hours vs. 0.868 hours) and delivered much faster inference speed (2.9 ms/image), nearly three times quicker than YOLOv5n. Although both models performed well in detecting common defects, YOLOv8n showed more stable results on complex defect types. These improvements make YOLOv8n more suitable for real-time applications in batik production environments. Its efficiency and accuracy support the development of fast and reliable automated quality control systems in traditional textile industries. This research emphasizes the importance of using modern lightweight architectures like YOLOv8n to enhance defect detection performance in practical manufacturing settings.