Improving YOLOv8n Robustness via Deformation-Aware Augmentation and Class Balancing for Plastic Resin Code Classification - Nyoman Sarasuartha Mahajaya; I Gusti Made Ngurah Desnanjaya (CV Edujavare Publishing, 2026)
Computer vision-based plastic resin code classification is an important component in supporting automated plastic waste sorting systems. However, deep learning models often experience performance degradation when plastic objects undergo physical deformation, such as dents, folds, or damage. In addition, class imbalance may cause models to be biased toward majority classes and perform poorly on minority classes. This study aims to improve the robustness of YOLOv8n for plastic resin code classification through a combination of deformation-aware augmentation and class balance. The WaDaBa dataset was used, consisting of 4,000 plastic images categorized into five classes, namely PET, PE-HD, PP, PS, and Others, with four physical deformation levels: intact, mild, moderate, and severe. The experiment was conducted using four scenarios: YOLOv8n baseline, YOLOv8n with class balance, YOLOv8n with deformation-aware augmentation, and the proposed YOLOv8n combining both strategies. The evaluation metrics include Accuracy, Macro-F1, Weighted-F1, per-class recall, accuracy across deformation levels, latency, and FPS. The experimental results show that the proposed YOLOv8n achieved the best overall performance, with an Accuracy of 76.82%, Macro-F1 of 0.7026, Weighted-F1 of 0.7613, latency of 4.87 ms per image, and throughput of 205.2 FPS. Compared with the baseline, the proposed method improved Accuracy by 4.37 points and Macro-F1 by 0.0715. Furthermore, accuracy under severe deformation increased from 70.59% to 73.53%. These findings indicate that the combination of deformation-aware augmentation and class balance can improve YOLOv8n robustness without sacrificing inference efficiency.