BBW YOLO: Intelligent Detection Algorithms for Aluminium Profile Material Surface Defects
Abstract
1. Introduction
2. Methodology
2.1. Channel Information Fusion Mechanisms
2.2. Dynamic Sparse-Attention Mechanism
2.3. Loss Function Optimization
2.4. Improved YOLOv8 Structure
2.5. StyleGAN2-ADA
3. Experimental Analysis
3.1. Pre-Experimental Work
3.1.1. Data Collection and Dataset Construction
3.1.2. Experimental Platform and Parameters
3.1.3. Evaluation Indicators
3.2. Performance Comparison of Different Models
3.3. Performance Comparison of Different Defect Types
3.4. Ablation Experiment
3.5. Comparison of Different Models of Attention Mechanisms
3.6. Model Performance
3.6.1. Model Lightweight Analysis
3.6.2. Precision and Recall Analysis
3.6.3. Real-Time Performance Analysis
3.6.4. Comparison of Model Visualization Detection
4. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Tang, Y.; Liu, R.; Wang, S. YOLO-SUMAS: Improved Printed Circuit Board Defect Detection and Identification Research Based on YOLOv8. Micromachines 2025, 16, 509. [Google Scholar] [CrossRef] [PubMed]
- Zhao, X.; Lyu, Q.; Zeng, H.; Ling, Z.; Zhai, Z.; Lyu, H.; Riffat, S.; Chen, B.; Wang, W. A Defect Detection Algorithm for Optoelectronic Detectors Utilizing GLV-YOLO. Micromachines 2025, 16, 267. [Google Scholar] [CrossRef] [PubMed]
- Saravanan, C. Color image to grayscale image conversion. In Proceedings of the Second International Conference on Computer Engineering and Applications, Bali, Indonesia, 19–21 March 2010; IEEE: New York, NY, USA, 2010; Volume 2, pp. 196–199. [Google Scholar] [CrossRef]
- Yan, Z.; Zhang, B.; Wang, D. An FPGA-Based YOLOv5 Accelerator for Real-Time Industrial Vision Applications. Micromachines 2024, 15, 1164. [Google Scholar] [CrossRef] [PubMed]
- Tsanakas, J.A.; Ha, L.D.; Al Shakarchi, F. Fault diagnosis of photovoltaic modules through image processing and Canny edge detection on field thermographic measurements. Int. J. Sustain. Energy 2015, 34, 351–372. [Google Scholar] [CrossRef]
- Zhu, S.; Zhang, R.; An, Y.; Liu, H. An image segmentation algorithm in image processing based on threshold segmentation. In Proceedings of the Third International IEEE Conference on Signal-Image Technologies and Internet-Based System, Shanghai, China, 16–19 December 2007; IEEE: New York, NY, USA, 2007; pp. 673–678. [Google Scholar] [CrossRef]
- Ren, S.; He, K.; Girshick, R.; Sun, J. Faster R-CNN: Towards real-time object detection with region proposal networks. IEEE Trans. Pattern Anal. Mach. Intell. 2016, 39, 1137–1149. [Google Scholar] [CrossRef]
- Liu, W.; Anguelov, D.; Erhan, D.; Szegedy, C.; Reed, S.; Fu, C.Y.; Berg, A.C. SSD: Single shot multibox detector. In Proceedings of the 14th European Conference on Computer Vision (ECCV), Amsterdam, The Netherlands, 11–14 October 2016; Springer: Cham, Switzerland, 2016; pp. 21–37. [Google Scholar] [CrossRef]
- Redmon, J.; Divvala, S.; Girshick, R.; Farhadi, A. You only look once: Unified, real-time object detection. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Las Vegas, NV, USA, 27–30 June 2016; IEEE: New York, NY, USA, 2016; pp. 779–788. [Google Scholar] [CrossRef]
- Lin, T.Y.; Goyal, P.; Girshick, R.; He, K.; Dollár, P. Focal loss for dense object detection. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), Honolulu, HI, USA, 21–26 July 2017; IEEE: New York, NY, USA, 2017; pp. 2980–2988. [Google Scholar] [CrossRef]
- Song, Z.; Zou, S.; Zhou, W.; Huang, Y.; Shao, L.; Yuan, J.; Gou, X.; Jin, W.; Wang, Z.; Chen, X.; et al. Clinically applicable histopathological diagnosis system for gastric cancer detection using deep learning. Nat. Commun. 2020, 11, 4294. [Google Scholar] [CrossRef] [PubMed]
- Kabir, H.; Wu, J.; Dahal, S.; Joo, T.; Garg, N. Automated estimation of cementitious sorptivity via computer vision. Nat. Commun. 2024, 15, 9935. [Google Scholar] [CrossRef] [PubMed]
- Wei, J.; Liang, J.; Song, J.; Zhou, P. YOLO-PBESW: A Lightweight Deep Learning Model for the Efficient Identification of Indomethacin Crystal Morphologies in Microfluidic Droplets. Micromachines 2024, 15, 1136. [Google Scholar] [CrossRef] [PubMed]
- Li, X.L.; Yang, Y.H.; Chu, M.X. Steel plate surface defect detection based on improved RetinaNet-GHM algorithm. Electron. Meas. Technol. 2023, 46, 100–105. [Google Scholar] [CrossRef]
- Wang, G.Y.; Yu, N.G. SSD-Faster Net: A hybrid network for industrial defect inspection. arXiv 2022, arXiv:2207.00589. [Google Scholar] [CrossRef]
- Wang, G.Q.; Zhang, X.; Li, Z.; Chen, J. A high-precision and lightweight detector based on a graph convolution network for strip surface defect detection. Adv. Eng. Inform. 2024, 59, 102280. [Google Scholar] [CrossRef]
- Zhao, C.; Shu, X.; Yan, X.; Liu, Y. RDD-YOLO: A modified YOLO for detection of steel surface defects. Measurement 2023, 214, 112776. [Google Scholar] [CrossRef]
- Zheng, H.; Liu, Y.; Chen, J.; Wang, Z. MD-YOLO: Surface defect detector for industrial complex environments. Opt. Lasers Eng. 2024, 178, 108170. [Google Scholar] [CrossRef]
- Lu, M.; Liu, Y.; Wang, Z.; Chen, J. WSS-YOLO: An improved industrial defect detection network for steel surface defects. Measurement 2024, 236, 115060. [Google Scholar] [CrossRef]
- Wang, G.Q.; Li, Z.; Zhang, X.; Chen, J. YOLO-MSAPF: Multi-scale alignment fusion with parallel feature filtering model for high precision weld defect detection. IEEE Trans. Instrum. Meas. 2023, 72, 5022914. [Google Scholar] [CrossRef]
- Tan, M.; Pang, R.; Le, Q.V. EfficientDet: Scalable and efficient object detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Seattle, WA, USA, 13–19 June 2020; IEEE: New York, NY, USA, 2020; pp. 10781–10790. [Google Scholar] [CrossRef]
- Zhu, L.; Wang, X.; Ke, Z.; Zhang, W.; Lau, R. BiFormer: Vision transformer with bi-level routing attention. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), Vancouver, BC, Canada, 17–24 June 2023; IEEE: New York, NY, USA, 2023; pp. 10323–10333. [Google Scholar] [CrossRef]
- Zheng, Z.; Wang, P.; Liu, W.; Li, J.; Ye, R.; Ren, D. Distance-IoU loss: Faster and better learning for bounding box regression. In Proceedings of the AAAI Conference on Artificial Intelligence, New York, NY, USA, 7–12 February 2020; AAAI Press: Palo Alto, CA, USA, 2020; Volume 34, pp. 12993–13000. [Google Scholar] [CrossRef]
- Zhang, Y.F.; Ren, W.; Zhang, Z.; Jia, Z.; Wang, L.; Tan, T. Focal and efficient IoU loss for accurate bounding box regression. Neurocomputing 2022, 506, 146–157. [Google Scholar] [CrossRef]
- Tong, Z.; Chen, Y.; Xu, Z.; Yu, R. Wise-IoU: Bounding box regression loss with dynamic focusing mechanism. arXiv 2023, arXiv:2301.10051. [Google Scholar] [CrossRef]
- Woodland, M.; Uzun, D.; Johnston, P.; Tan, K.L.; Giger, M.L. Evaluating the performance of StyleGAN2-ADA on medical images. In Proceedings of the International Workshop on Simulation and Synthesis in Medical Imaging, Strasbourg, France, 27 September 2022; Springer: Cham, Switzerland, 2022; pp. 44–53. [Google Scholar] [CrossRef]
- Litjens, G.; Kooi, T.; Bejnordi, B.E.; Setio, A.A.A.; Ciompi, F.; Ghafoorian, M.; Van Der Laak, J.A.; Van Ginneken, B.; Sánchez, C.I. A survey on deep learning in medical image analysis. Med. Image Anal. 2017, 42, 60–88. [Google Scholar] [CrossRef] [PubMed]
- Voulodimos, A.; Doulamis, N.; Doulamis, A.; Protopapadakis, E. Deep learning for computer vision: A brief review. Comput. Intell. Neurosci. 2018, 2018, 7068349. [Google Scholar] [CrossRef] [PubMed]
- Tian, Y.; Zhang, Y. A comprehensive survey on regularization strategies in machine learning. Inf. Fusion 2022, 80, 146–166. [Google Scholar] [CrossRef]
BBW YOLO Algorithm: |
---|
1: Parameters: number of iterations, small batch training, learning rate, weight decay. Data preprocessing: image classification, cropping, data enhancement. 2: Inputs: training and validation sets, test set. 3: Loading: feature-extraction networks. Feature-fusion network with multi-scale output prediction. 4: Validation: algorithmic environment 500 iterations of training, -th iteration of training (): training network: a: Feature extraction: CBS × 5, C2f × 4, SPPF. b: Feature fusion: CBS × 2, C2f × 4, upsample, BiFPN_2, BiFormer. c: Localization error, classification error, confidence error, total error. . verification network: a: Model test effect . b: Calculate , and , :0.95, . c: Adjusting learning rates and updating training strategies. Save the training results of the th: weights , mould . update: , . Save training model: . 5: Output prediction: identification, localization, classification. 6: Plotting: result curves, saving the optimal model , outputs. End of training |
Model Type | StyleGAN2-ADA | P/% | mAP@0.5/% | mAP@0.5:0.95/% |
---|---|---|---|---|
YOLOV8 | 67.23 | 61.92 | 46.47 | |
BBW YOLO | 71.56 | 76.90 | 49.11 | |
YOLOV8 | + | 82.10 | 76.82 | 53.66 |
BBW YOLO | + | 87.51 | 81.77 | 58.36 |
Models | Parameters /Million | FLOPs /G | Model Volume /MB | P /% | R /% | mAP@0.5 /% | FPS f/s |
---|---|---|---|---|---|---|---|
YOLOv3 | 103.69 | 283 | 207.8 | 83.92 | 76.45 | 80.27 | 77.1 |
YOLOv5 | 46.13 | 107.9 | 92.8 | 82.72 | 74.75 | 79.25 | 90.2 |
YOLOv6 | 4.23 | 11.9 | 8.7 | 80.75 | 68.5 | 72.06 | 236.3 |
YOLOv7 | 37.28 | 105.2 | 74.8 | 80.12 | 72.23 | 79.94 | 100.9 |
YOLOv9 | 25.53 | 103.7 | 51.6 | 77.42 | 69.01 | 72.1 | 127.4 |
RT-DERT | 20.18 | 58.6 | 40.5 | 76.67 | 62.2 | 65.14 | 122.1 |
YOLOv8 | 3.01 | 8.2 | 6.3 | 82.51 | 72.59 | 76.82 | 201.3 |
RDD-YOLO [15] | 3.01 | 8.2 | 8.5 | 80.27 | 69.86 | 77.45 | 163.4 |
WSS-YOLO [17] | 3.69 | 486.4 | 477.2 | 89.25 | 74.94 | 82.32 | 34.2 |
BBW YOLO | 3.03 | 8.3 | 6.3 | 87.51 | 75.24 | 81.77 | 292.3 |
Defect Type | P/% | mAP@0.5:0.95/% | ||
---|---|---|---|---|
YOLOv8 | BBW YOLO | YOLOv8 | BBW YOLO | |
Electrically Nonconductive | 83.3 | 86.7 | 64.9 | 68.1 |
Scratching | 65.1 | 69.7 | 29 | 32.9 |
Edge-exposed | 91.6 | 99.2 | 43.9 | 46.1 |
Orange Peel | 93.1 | 94.3 | 83.6 | 90.4 |
Base Exposure | 90.1 | 91.3 | 56.9 | 65.5 |
Splashing | 83.1 | 89.2 | 55.3 | 55.5 |
Paint-bubbling | 63.2 | 74.7 | 23.5 | 37.4 |
Pitting | 82.2 | 83.7 | 56.6 | 61.1 |
Discoloration | 98.1 | 99.2 | 92.7 | 96.1 |
Dirt Inclusion | 75.3 | 87.1 | 30.9 | 31.0 |
All defects | 82.5 | 87.5 | 53.7 | 58.4 |
Models | BiFPN | BiFormer | WIoU v3 | P /% | R /% | mAP@0.5:0.95 /% | FPS |
---|---|---|---|---|---|---|---|
YOLOv8 | 82.51 | 72.59 | 53.66 | 201.3 | |||
Model 1 | √ | 83.84 | 76.42 | 58.81 | 243.9 | ||
Model 2 | √ | 85.81 | 75.27 | 61.52 | 174.8 | ||
Model 3 | √ | 83.22 | 78.19 | 54.73 | 300.2 | ||
Model 4 | √ | √ | 85.42 | 72.42 | 55.39 | 231.7 | |
Model 5 | √ | √ | 84.78 | 74.42 | 57.75 | 278.4 | |
Model 6 | √ | √ | 85.87 | 75.31 | 63.12 | 286.1 | |
BBW YOLO | √ | √ | √ | 87.51 | 75.24 | 58.36 | 292.3 |
Models | Parameters /Million | P /% | R /% | mAP@0.5:0.95 /% | FPS |
---|---|---|---|---|---|
+SE | 3.04 | 85.18 | 73.25 | 56.81 | 290.1 |
+CBAM | 3.09 | 85.03 | 74.23 | 53.93 | 284.9 |
+CA | 3.04 | 81.23 | 72.91 | 57.99 | 289.2 |
+ECA | 3.03 | 85.38 | 74.82 | 57.46 | 270.3 |
+BiFormer | 3.03 | 87.51 | 75.24 | 58.36 | 292.3 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Yin, Z.; Li, H.; Qi, B.; Shan, G. BBW YOLO: Intelligent Detection Algorithms for Aluminium Profile Material Surface Defects. Coatings 2025, 15, 684. https://doi.org/10.3390/coatings15060684
Yin Z, Li H, Qi B, Shan G. BBW YOLO: Intelligent Detection Algorithms for Aluminium Profile Material Surface Defects. Coatings. 2025; 15(6):684. https://doi.org/10.3390/coatings15060684
Chicago/Turabian StyleYin, Zijuan, Haichao Li, Bo Qi, and Guangyue Shan. 2025. "BBW YOLO: Intelligent Detection Algorithms for Aluminium Profile Material Surface Defects" Coatings 15, no. 6: 684. https://doi.org/10.3390/coatings15060684
APA StyleYin, Z., Li, H., Qi, B., & Shan, G. (2025). BBW YOLO: Intelligent Detection Algorithms for Aluminium Profile Material Surface Defects. Coatings, 15(6), 684. https://doi.org/10.3390/coatings15060684