切换中文
Research·Computer Application | Views : 430 Downloads: 642 CSCD: 0
  • Export

  • Share

  • Collection

  • Album

    • Casting Surface Defect Detection Model Based on CCD-YOLOv5 Algorithm

    • 在铸件表面缺陷检测领域,研究者提出了基于改进YOLOv5算法的检测模型,通过数据增强和网络结构优化,显著提升了检测准确率、召回率和mAP@0.5值,有效提高了综合识别检测效果。
    • YAN Zhilin

      12 ,

      ZHONG Shoucheng

      2 ,

      SUN Jin

      2 ,

      XIAO Jie

      2
    • Vol. 44, Issue 8, Pages: 1083-1089(2024)   

      Published: 20 August 2024

    • DOI: 10.15980/j.tzzz.2024.08.013     

    Scan for full text

  • Quote

    PDF

  • YAN Z L,ZHONG S C,SUN J,et al. Casting surface defect detection model based on CCD-YOLOv5 algorithm[J]. Special Casting & Nonferrous Alloys,2024,44(8):1 083-1 089. DOI: 10.15980/j.tzzz.2024.08.013.
  •  
  •  

    The impact of surface defects in castings on product quality and production safety was introduced, emphasizing the importance of precise identification and classification of defects. Traditional manual detection methods have problems such as low efficiency and instability. In recent years, the application of deep learning algorithms in the field of defect detection has gradually received attention. The article reviews the deep convolutional neural network model constructed by Jia Minping et al., the improved AlexNet proposed by Zhao Peng et al., the cascaded autoencoder structure proposed by YUN JP et al., the convolutional denoising autoencoder based on fully connected layers proposed by Luo Yuetong et al., and the improvements made to the YOLOv3 model by WANG L and DUAN L. These studies have made some progress in improving detection accuracy and efficiency, but there are still challenges such as a small sample size, multiple parameters, and large computational complexity. This study optimized the algorithm model through data preprocessing, sample image expansion, and Mosaic data augmentation to improve the comprehensive detection effect of surface defects in castings.

    1. Dataset preprocessing work

    The preprocessing of the dataset for the surface defect detection model of castings was introduced, including sample size expansion and image enhancement techniques. To solve the problem of overfitting caused by insufficient sample size, the sample image is expanded through operations such as flipping, rotating, and color grading to improve the robustness and generalization ability of the model. At the same time, using Mosaic data augmentation methods, especially 9-Mosaic technology, multiple images are randomly selected for cropping, rotation, and stitching, effectively enriching sample diversity, increasing the number of small target samples, simulating complex environments, reducing the model's hardware performance requirements, and improving training effectiveness.

    Research on Improving YOLOv5 Model Method

    We conducted in-depth research on the improvement method of the casting surface defect detection model based on CCD-YOLOv5 algorithm. Firstly, the native YOLOv5 detection model is introduced, which is a single-stage object detection algorithm that generates target candidate regions through grid partitioning and performs classification and localization simultaneously in the neural network. The YOLOv5 series models have improved detection efficiency and accuracy through various improvements, such as increasing image resolution and introducing data augmentation. YOLOv5s was specifically chosen as the base model due to its lightweight and wide range of applications.

    Surface defect detection test for castings

    Introduced the experimental environment, experimental indicators, and ablation test of the casting surface defect detection model based on CCD-YOLOv5 algorithm. The experimental environment configuration includes Python, Pycharm, Pytorch framework, as well as dataset preparation and enhancement. We used cross validation for model training, set parameters such as input image size, batch size, optimizer, and introduced an early stopping strategy. The experimental indicators include accuracy, recall, and class average accuracy (mAP), and the model performance is evaluated through P-R curves and AP values. In the ablation experiment, the performance improvement of the improved model was verified by introducing C2f module, CA attention mechanism module, and decoupling head module. The improved CCD-YOLOv5 model has shown improvements in accuracy, recall, and mAP values, but its recognition performance for certain defect types still needs to be optimized. The analysis of the accuracy recall curve shows that the model performs well in feature extraction and target localization, but there are still challenges when dealing with multiple types and small target features.

    4 Conclusion

    A casting surface defect detection method based on improved YOLOv5 was proposed, which improves sample richness through data augmentation and 9-Mosaic enhancement strategy, improves model structure to achieve lightweight and gradient information enrichment, introduces CA attention mechanism to reduce redundant information interference, enhances feature expression, replaces coupling head module with decoupling head module to enhance global information acquisition. The improved model performs better in detection accuracy and efficiency.

    * The above content is automatically generated by AI and is for reference only. This website does not assume any commercial or legal responsibility for the consequences arising from the use of the following content on this website.

    Alert me when the article has been cited
    Submit

    Related Author

    Bai Rui 太原科技大学材料科学与工程学院
    Hu Yong 太原科技大学材料科学与工程学院
    Jin Zefa 宁夏大学材料与新能源学院
    Liu Hongquan 栋梁铝业有限公司
    Yan Zhijie 中北大学材料科学与工程学院;特殊环境先进金属材料山西省重点实验室
    Wang Mengxue 北方民族大学电气信息工程学院
    Mu Chunyang 北方民族大学机电工程学院;北方民族大学宁夏智能信息与大数据处理重点实验室
    Ma Xing 北方民族大学电气信息工程学院;北方民族大学宁夏智能信息与大数据处理重点实验室

    Related Institution

    School of Materials Science and Engineering, Taiyuan University of Science and Technology
    School of Materials and New Energy, Ningxia University
    Dongliang Aluminium Co., Ltd.
    School of Materials Science and Engineering, North University of China
    Shanxi Key Laboratory of Advanced Metal Materials for Special Environments
    0