Defect detection in textile manufacturing: Improving findings using YOLOv5 versions

  • Rodolfo Seidel IFES
  • Cláudio Alberto Waiandt IFES
  • Hilário Seibel Júnior IFES


Currently one of the main challenges in identifying textile defects is related to the detection manual, mainly due to the complexity of irregular shapes and small objects. Finding ways to automate this detection has been studied by several authors. Thus this article expands and improves the findings and conclusions in the work, entitled ’Textile defect Detection using YOLOv5 on AITEX dataset’. This study deepened the investigation with native data augmentation, transfer learning and base rebalancing techniques, in addition to new metrics that allowed us to present results that corroborate and expand previous findings. Previous research laid the foundation for this study and provided crucial insights that guided further exploration of the issues. With the results obtained, it was concluded that the versions of YOLOv5 with the new techniques used adapted very well to the new context, enhancing their performance.

Palavras-chave: YOLOv5, AITEX, Detection of textile defects, Bounding boxes, IoU, Annotation of objects, Transfer learning


A. M. Cavalcanti and G. F. dos Santos, “A indústria têxtil no brasil: uma análise da importância da competitividade frente ao contexto mundial,” Revista Exacta, vol. 20, 2022. [Online]. Available: [link].

ABIT, “Perfil do setor,” 2022. [Online]. Available: [link]

R. Seidel, H. S. Júnior, and K. Komati, “Textile defect detection using yolov5 on aitex dataset,” in Anais do XIX Encontro Nacional de Inteligência Artificial e Computacional. Porto Alegre, RS, Brasil: SBC, 2022, pp. 763–774. [Online]. Available: [link].

A. M. G. Conceição, “Critérios de classificação de tecidos quanto à qualidade,” 1998. [Online]. Available: [link].

Sebrae, “Moda, o que esperar da indústria têxtil em 2023,” 2023. [Online]. Available: [link].

J. Silvestre-Blanes, T. Albero Albero, I. Miralles, R. Pérez-Llorens, and J. Moreno, “Aitex fabric image database,” 2019. [Online]. Available: [link]

J. S. Blanes, T. Albero, I. Miralles, R. Pérez-Llorens, and J. Moreno, “A public fabric database for defect detection methods and results,” Autex Research Journal, vol. 19, no. 4, pp. 363–374, 2019. [Online]. Available:

I. Zulkarnain, R. R. Nurmalasari, and F. N. Azizah, “Table information extraction using data augmentation on deep learning and image processing,” in 2022 16th International Conference on Telecommunication Systems, Services, and Applications (TSSA), 2022, pp. 1–6.

U. Kulkarni, M. S. M, A. Shanbhag, A. A. Ayachit, P. Kulkarni, S. Halemani, and S. S. Kadappanavar, “Signboard detection using yolov5 with transfer learning,” in 2023 IEEE 8th International Conference for Convergence in Technology (I2CT), 2023, pp. 1–7.

G. Jocher, A. Chaurasia, A. Stoken, J. Borovec, NanoCode012, Y. Kwon, TaoXie, J. Fang, Imyhxy, K. Michael, Lorna, A. V, D. Montes, J. Nadar, Laughing, Tkianai, YxNONG, P. Skalski, Z. Wang, A. Hogan, C. Fati, L. Mammana, AlexWang1900, D. Patel, D. Yiwei, F. You, J. Hajek, L. Diaconu, and M. Thanh Minh, “ultralytics/yolov5: v6.1 - TensorRT, TensorFlow Edge TPU and OpenVINO Export and Inference,” Zenodo, Feb. 2022.

G. Jocher, L. Changyu, A. Hogan, L. Y. , changyu98, P. Rai, and T. Sullivan, “ultralytics/yolov5: Initial Release,” Zenodo, Jun. 2020.

T.-Y. Lin, M. Maire, S. Belongie, J. Hays, P. Perona, D. Ramanan, P. Dollár, and C. L. Zitnick, “Microsoft coco: Common objects in context,” in European conference on computer vision. Springer, 2014, pp. 740–755.

T. Liu and S. Chen, “Yolov4-dcn-based fabric defect detection algorithm,” in 2022 37th Youth Academic Annual Conference of Chinese Association of Automation (YAC), 2022, pp. 710–715.

S. Yohanandan, “map (mean average precision) might confuse you!” 2020. [Online]. Available: [link].

Z. Zou, K. Chen, Z. Shi, Y. Guo, and J. Ye, “Object detection in 20 years: A survey,” Proceedings of the IEEE, 2023.

Z. Gevorgyan, “Siou loss: More powerful learning for bounding box regression,” arXiv preprint arXiv:2205.12740, 2022.

A. Ç. Seçkin and M. Seçkin, “Detection of fabric defects with intertwined frame vector feature extraction,” Alexandria Engineering Journal, vol. 61, no. 4, pp. 2887–2898, 2022.

L. Zheng, X. Wang, Q. Wang, S. Wang, and X. Liu, “A fabric defect detection method based on improved yolov5,” in 2021 7th International Conference on Computer and Communications (ICCC). IEEE, 2021, pp. 620–624.

C.-Y. Wang, I.-H. Yeh, and H.-Y. M. Liao, “You only learn one representation: Unified network for multiple tasks,” arXiv preprint arXiv:2105.04206, 2021.

L. Rong-qiang, L. Ming-hui, S. Jia-chen, and L. Yi-bin, “Fabric defect detection method based on improved u-net,” in Journal of Physics: Conference Series, vol. 1948, no. 1. IOP Publishing, 2021, p. 012160.
SEIDEL, Rodolfo; WAIANDT, Cláudio Alberto; SEIBEL JÚNIOR, Hilário. Defect detection in textile manufacturing: Improving findings using YOLOv5 versions. In: WORKSHOP DE VISÃO COMPUTACIONAL (WVC), 18. , 2023, São Bernardo do Campo/SP. Anais [...]. Porto Alegre: Sociedade Brasileira de Computação, 2023 . p. 66-71. DOI: