Visual Defect Detection in Printed Circuit Boards using YOLO Architectures: A Comparison on the DeepPCB Dataset
Abstract
The detection of defects in Printed Circuit Boards (PCBs) remains a significant challenge in modern electronic manufacturing systems, where the need to reduce costs and improve product reliability has stimulated the development and application of new computational intelligence models. In this context, the YOLO architecture-based family has evolved through multiple versions, establishing itself as one of the leading solutions for automatic defect detection in visual inspection systems within the electronics industry. Based on this fact, the present work compared the YOLOv5 and YOLOv8 architectures for tasks focused on automatic fault detection in printed circuit boards. The methodology employed consisted of evaluating the computer vision models YOLOv5 and YOLOv8 using the DeepPCB image dataset in a GPU-enabled execution environment and comparing their precision, recall, F1-score, and mAP across different IoU thresholds. In addition, a qualitative assessment was conducted to evaluate the generalization and inference capabilities of both architectures, using images not included during the training stage. The results obtained revealed a clear contrast between the two architectures. YOLOv5m achieved the best overall balance between precision, recall, and detection stability, while YOLOv8s demonstrated superior defect localization capability under varying IoU thresholds. Overall, both computer vision models exhibited competitive performance in the DeepPCB dataset. Finally, it is concluded that YOLOv5 remains a suitable alternative for traditional visual inspection processes focused on the electronics industry due to its efficiency and scalability in quality control tasks, while YOLOv8 represents a competitive option when higher precision is prioritized in defect localization.
References
Q. Ling, and N. A. M. Isa, “Printed Circuit Board Defect Detection Methods Based on Image Processing, Machine Learning and Deep Learning: A Survey,” IEEE Access, vol. 11, pp. 15921-15944, Feb. 2023. http://doi.org/10.1109/ACCESS.2023.3245093
Y. Zhou, M. Yuan, J. Zhang, G. Ding, and S. Qin, “Review of vision-based defect detection research and its perspectives for printed circuit board,” J. Manuf. Syst., vol. 70, pp. 557–578, Oct. 2023. https://doi.org/10.1016/j.jmsy.2023.08.019
S. Alawandi, K. Mallibhat, U. Kudachi, and A. Beedanal, “PCB defects: A unified survey of trends, detection techniques, and limitations through systematic literature review,” J. Electron. Test., vol. 41, pp. 709-787, Dec. 2025. https://doi.org/10.1007/s10836-025-06198-y
X. Yu, H. Sun, Y. He, J. Peng, X. Zeng, and L. Chen, “Robust classification method for printed circuit board defects based on virtual and real space cooperative diffusion model,” Eng. Appl. Artif. Intell., vol. 169, p. 114126, Apr. 2026. https://doi.org/10.1016/j.engappai.2026.114126
C. Zhang, G. Shi, H. Li, M. Yang, Y. Li, and Z. Bing, “Circuit board welding defect detection based on industrial IoVT,” IEEE Internet Things J., vol. 13, no. 7, pp. 14003-14018, Apr. 2026. https://doi.org/10.1109/JIOT.2026.3651257
Fineline, “Proceso de fabricación de PCB – Fineline Global,” fineline-global.com. Accessed: Mar. 21, 2026. [Online]. Available: https://www.fineline-global.com/es/knowledge-centre/pcb-manufacturing-process/
PCBWay Assitant 03, “Proceso de producción y nuestros equipos,” pcbway.es. Accessed: Mar. 21, 2026. [Online]. Available: https://www.pcbway.es/pcb-service.html?step=10
S. Tang, “tangsanli5201/DeepPCB,” GitHub.com. Accessed: Feb. 21, 2026. [Online]. Available: https://github.com/tangsanli5201/DeepPCB
S. Lv et al., “A dataset for deep learning based detection of printed circuit board surface defect,” Sci. Data, vol. 11, p. 811, Jul. 2024. https://doi.org/10.1038/s41597-024-03656-8
X. Chen, Y. Wu, X. He, and W. Ming, “A comprehensive review of deep learning-based PCB defect detection,” IEEE Access, vol. 11, pp. 139017-139038, Dec. 2023. https://doi.org/10.1109/ACCESS.2023.3339561
X. Wu, Y. Ge, Q. Zhang, and D. Zhang, “PCB defect detection using deep learning methods,” in IEEE 24th International Conference on Computer Supported Cooperative Work in Design (CSCWD), Dalian, China, 2021, pp. 873-876. http://doi.org/10.1109/CSCWD49262.2021.9437846
Z. He, Y. Wu, Y. Lv, and Y. He, “PCB-Faster-RCNN: An Improved Object Detection Algorithm for PCB Surface Defects,” Appl. Sci., vol. 15, no. 24, p. 12881, Dec. 2025. https://doi.org/10.3390/app152412881
Z. Li, and X. Liu, “Soldering Defect Segmentation Method for PCB on Improved UNet,” Appl. Sci., vol. 14, no. 16, p. 7370, Aug. 2024. https://doi.org/10.3390/app14167370
Z. Gao, Y. Li, and S. Yuan, “DECNet: An efficient improved model for printed circuit board surface defect detection,” Signal, Image Video Process., vol. 20, no. 4, p. 188, Mar. 2026. https://doi.org/10.1007/s11760-026-05175-y
F. Jiang, H. Chen, S. Wei, and C. Chen, “Performance Analysis of Printed Circuit Board Defect Detection with Hybrid CNN Feature Extraction and Clustering,” Eng, vol. 7, no. 1, p. 41, Jan. 2026. https://doi.org/10.3390/eng7010041
J. Shi, J. Yang, and Y. Zhang, “Research on Steel Surface Defect Detection Based on YOLOv5 with Attention Mechanism,” Electronics, vol. 11, no. 22, p. 3735, Nov. 2022. https://doi.org/10.3390/electronics11223735
Z. Yang, D. Li, L. Hou, and W. Nai, “A Comprehensive Performance Evaluation of YOLO Series Algorithms in Automatic Inspection of Printed Circuit Boards,” Machines, vol. 14, no. 1, p. 94, Jan. 2026. https://doi.org/10.3390/machines14010094
V. Adibhatla, H.-C. Chih, C.-C. Hsu, J. Cheng, M. F. Abbod, and J.-S. Shieh, “Defect detection in printed circuit boards using You-Only-Look-Once convolutional neural networks,” Electronics, vol. 9, no. 9, p. 1547, Sep. 2020. https://doi.org/10.3390/electronics9091547
J. Xu, L. Shi, W. Yang, X. Zhu, J. Li, and Y. Wang, “YOLO-CMDS: An enhanced method for PCB defect detection,” Integration, vol. 109, p. 102732, Jul. 2026. https://doi.org/10.1016/j.vlsi.2026.102732
H. Peng, W. Yang, and B. Yu, “YOLO-UMS: Multi-Scale Feature Fusion Based on YOLO Detector for PCB Surface Defect Detection,” Sensors, vol. 26, no. 2, p. 689, Jan. 2026. https://doi.org/10.3390/s26020689
Z. Wang, P. Yuan, and X. Zhang, “YOLO-CD: A lightweight real-time PCB defect detection model for edge deployments,” J. Real-Time Image Proc., vol. 23, p. 46, Jan. 2026. https://doi.org/10.1007/s11554-025-01847-z
V. Kumar Ancha, V. Gonuguntla, and R. Vaddi “CSPGhost-YOLO: A lightweight and robust model for real-time mixed PCB defect detection system,” Measurement, vol. 266, p. 120521, Mar. 2026. https://doi.org/10.1016/j.measurement.2026.120521
X. Zuo, N. Zhao, K. Wang, and J. Hu, “MDEB-YOLO: A Lightweight Multi-Scale Attention Network for Micro-Defect Detection on Printed Circuit Boards,” Micromachines, vol. 17, no. 2, p. 192, Jan. 2026. https://doi.org/10.3390/mi17020192
Y. Li et al., “FMW-YOLO: A Frequency-Enhanced and Multi-Scale Context-Aware Framework for PCB Defect Detection,” Micromachines, vol. 17, no. 5, p. 531, Apr. 2026. https://doi.org/10.3390/mi17050531
S. Singh, “Leveraging YOLO object detection for accurate and efficient visual recognition,” labellerr.com. Accessed: Jun. 21, 2026. [Online]. Available: https://www.labellerr.com/blog/why-is-the-yolo-algorithm-important/
G. Jocher, “Ultralytics. Box, cls, and dfl loss gain #10375,” github.com. Accessed: Jun. 21, 2026. [Online]. Available: https://github.com/ultralytics/ultralytics/issues/10375
P. García Mesa, “Understanding YOLOv5 Loss: A Comprehensive Analysis,” medium.com. Accessed: Jun. 21, 2026. [Online]. Available: https://pgmesa.medium.com/understanding-yolov5-loss-a-comprehensive-analysis-ffe35e6203e0
G. Naidu, T. Zuva, and E. M. Sibanda, “A review of evaluation metrics in machine learning algorithms,” Artificial Intelligence Application in Networks and Systems, R. Silhavy and P. Silhavy, Eds., Cham, Switzerland: Springer, 2023, pp. 15-25. https://doi.org/10.1007/978-3-031-35314-7_2
Ultralytics, “Performance Metrics Deep Dive,” ultralytics.com/. Accessed: Jun. 21, 2026. [Online]. Available: https://docs.ultralytics.com/guides/yolo-performance-metrics/
Downloads
Copyright (c) 2026 TecnoLógicas

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
| Article metrics | |
|---|---|
| Abstract views | 324 |
| Galley views | 187 |
| PDF Views | 149 |
| HTML views | 4 |
| Other views | 34 |





