Research on Weld Defect Recognition Method Based on Mask R-CNN
Main Article Content
Abstract
Automatic detection of weld defects is of great significance to ensuring the quality of industrial products and engineering safety. To address the challenges of low contrast, large defect scale variation, complex background noise, and limited sample data in ultrasonic weld defect images, an improved Mask R-CNN instance segmentation model is proposed. First, the original ResNet+FPN backbone network is replaced with the RSU7 multi-scale feature extraction module to enhance the model’s ability to capture details of tiny defects through a nested U-structure and residual connections. Second, the CBAM attention mechanism is connected in series between the backbone network and the region proposal network to suppress background noise and highlight defect regions in both channel and spatial dimensions. Experiments are conducted on an ultrasonic weld defect dataset containing only 105 images. The results show that the improved model achieves a mean average precision (mAP) of 0.7564, which is 4.2% higher than that of the baseline Mask R-CNN (ResNet50+FPN). The coefficient of variation (CV) is 2.26%, indicating better training stability than the comparison models. The maximum AP drop rate under image disturbance is only 9.1%, demonstrating strong robustness. The proposed method realizes high-precision and high-stability defect detection and segmentation in small-sample scenarios, providing an effective technical solution for industrial ultrasonic welding quality inspection.
Article Details

This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
References
Method Based on VGG Network [J]. Computer Knowledge and Technology, 2024, 20(17): 6-10.
Chen Y, Shen H, Zhang G, et al. Identification of weld defects from ultrasonic signals using GASF and an improved DCGAN-ResNet network[J]. Nondestruct Test Eval, 2025, 40(7): 2841-2867.
Yao J, Liu H, Ye J. Enhanced EfficientNet-B0 with dual attention mechanisms for food category classification in X-ray images[J]. J Nondestruct Eval, 2026, 45(2): 55. DOI: 10.1007/s10921-026-01348-4.
Ren Hui, Xia Jing, Lu Jinling, et al. Fault Diagnosis Method for Photovoltaic Modules Based on Infrared Imaging and Improved MobileNet-V3 [J]. Acta Energia-Sinica, 2023, 44(8): 238-245.
Yu Zeyu, Yuan Hongqiang, Wei Xiaolong, et al. Deep Learning-Based Ultrasonic Defect Identification Method for Pipeline Welds [J]. Science and Technology and Engineering, 2022, 22(30): 13288-13292.
Ding Shanze, Ma Xiaochun, Zhang Dezhi, et al. Ultrasonic Identification of Weld Defects Based on Convolutional Neural Network [J]. Acoustics and Vibration, 2024, 13(1): 110-118.
Xu Xiangqian, Li Xing, Zhang Yong'an. Improved YOLOv5 Weld Surface Defect Detection Algorithm [J]. Journal of Xi'an Shiyou University (Natural Science Edition), 2025, 40(4): 98-106.
Xiang L, Xianjin F, Gaoming Y, et al. TransU²-Net: An effective medical image segmentation framework based on transformer and U²-Net[J]. IEEE J Transl Eng Health Med, 2023, 11: 441-450.
Ou Pan, Lu Kui, Zhang Zheng, et al. Target Recognition and Spatial Positioning Based on Mask RCNN [J]. Computer Measurement and Control, 2019, 27(6): 172-176.
Jiang Z, Fu J, Zeng T, et al. Defect R-CNN: A novel high-precision method for CT image defect detection[J]. Appl Sci, 2025, 15(9): 4825.