Source-linked AI summary
Deep Learning Based Steel Pipe Weld Defect Detection
Dingming Yang, Yanrong Cui, Zeyu Yu, Hongqiang Yuan
TL;DR
Defects in steel pipes are a concern addressed by the paper. The paper applies the single-stage YOLOv5 object-detection algorithm to steel-pipe weld defects and compares it with Faster R-CNN. 97.8% accuracy, mAP@0.5=98.7%, and 0.12s single-image detection time are reported for YOLOv5x testing.
Problem
Defects in steel pipes are a concern addressed by the paper.
Method
The paper applies the single-stage YOLOv5 object-detection algorithm to steel-pipe weld defects and compares it with Faster R-CNN.
Results
97.8% accuracy, mAP@0.5=98.7%, and 0.12s single-image detection time are reported for YOLOv5x testing.
Takeaways & Limitations
YOLOv5 completes multiclass steel-pipe weld-defect detection while meeting the stated criteria for real-time detection.
Takeaways & Limitations
With a limited dataset, defects not represented in the dataset cannot be correctly identified.
Abstract
from arXiv · showhide
Steel pipes are widely used in high-risk and high-pressure scenarios such as oil, chemical, natural gas, shale gas, etc. If there is some defect in steel pipes, it will lead to serious adverse consequences. Applying object detection in the field of deep learning to pipe weld defect detection and identification can effectively improve inspection efficiency and promote the development of industrial automation. Most predecessors used traditional computer vision methods applied to detect defects of steel pipe weld seams. However, traditional computer vision methods rely on prior knowledge and can only detect defects with a single feature, so it is difficult to complete the task of multi-defect classification, while deep learning is end-to-end. In this paper, the state-of-the-art single-stage object detection algorithm YOLOv5 is proposed to be applied to the field of steel pipe weld defect detection, and compared with the two-stage representative object detection algorithm Faster R-CNN. The experimental results show that applying YOLOv5 to steel pipe weld defect detection can greatly improve the accuracy, complete the multi-classification task, and meet the criteria of real-time detection.
Introduction
Steel-pipe weld defects matter in high-risk applications, but existing inspection approaches face accuracy, multiclassification, and real-time constraints. The paper applies YOLOv5 to address these limitations.
- Introduction: Defects in steel pipes can cause serious adverse consequences in high-risk and high-pressure applications.Relevant applications include oil, chemical, natural-gas, and shale-gas scenarios.
- Introduction: X-ray testing is a major nondestructive method, but identifying weld-defect type and location still requires manual participation.This limitation motivates automated object detection for weld inspection.
- Introduction: Deep-learning object detection is presented as an end-to-end alternative that can improve detection efficiency and promote industrial automation.The introduction contrasts its development in recognition accuracy and detection time with traditional computer vision.
- Introduction: Traditional computer-vision methods rely on prior knowledge and struggle with multiclassification because different defects have different features.Earlier work included OSTU + MSVM-rbf, which achieved 95.23% accuracy on multiclass weld-defect detection.
- Introduction: YOLOv5 is applied to steel-pipe weld defect detection to address reported accuracy, multiclassification, and detection-time shortcomings.The paper positions this as an object-detection approach for improving inspection efficiency and supporting industrial automation.
Materials and Methods
The methods section describes YOLOv5 as a single-stage detector with multiple model sizes and efficiency-oriented components. Its architecture includes augmentation, feature-extraction, feature-fusion, and localization techniques.
- Materials and Methods: The methods position YOLOv5 within the YOLO single-stage detection line developed from YOLOv1 through YOLOv4.Earlier versions addressed category count, accuracy, small-object detection, and detection efficiency in succession.
- Materials and Methods: YOLOv5 provides four model sizes—YOLOv5s, YOLOv5m, YOLOv5l, and YOLOv5x—with larger models increasing accuracy and single-image detection time.The section presents YOLOv5 as more flexible and faster than YOLOv4 for deployment, despite slightly lower performance.
- Materials and Methods: YOLOv5 uses Mosaic data enhancement, adaptive anchor calculation, adaptive image scaling, Focus and CSP structures, FPN+PAN, and GIoU_Loss.These components are distributed across the input, backbone, neck, and prediction stages.
- Materials and Methods: YOLOv5 is proposed for steel-pipe weld-defect detection as the paper’s central detection method.Figure 1 depicts the YOLOv5s network structure.
Image acquisition device
The dataset is acquired through a real-time X-ray imaging system that converts weld-penetration measurements into digital image sequences. Processing yields labeled images covering eight steel-pipe weld-defect types.
- Image acquisition device: The imaging system captures X-ray images of rotating welded pipes and transfers digital image sequences to a computer for processing and display.The system combines pipe movement, an X-ray machine, a digital panel detector, an image-capture card, and display components.
- Image acquisition device: The detector absorbs X-ray photons passing through the weld and converts their attenuation information into electronic data.The resulting data support digital image formation for weld inspection.
- Image acquisition device: Hardware limits the system to capturing and processing 8 X-ray images per second.This constraint is explicitly attributed to hardware performance.
- Acquisition of dataset: The collected dataset contains eight defect types: Blowhole, Undercut, Broken arc, Crack, Overlap, Slag inclusion, Lack of fusion, and Hollow bead.The examples and dataset profile concern these eight categories.
Data preprocessing
Data preprocessing analyzes defect geometry and image characteristics before training. The pipeline converts X-ray images to grayscale and examines bounding-box distributions for anomalous samples and aspect ratios.
- Data preprocessing: X-ray images are converted to single-channel grayscale images, compressing 2/3 of pixel data and accelerating training.The preprocessing uses the black-and-white nature of X-ray pictures to reduce input data.
- Data preprocessing: Scatter plots of bounding-box centers and dimensions are used to inspect defect placement, aspect ratios, and abnormal data.Matplotlib is used to draw the plots for preprocessing reference and training-parameter setting.
- Data preprocessing: Most bounding boxes are wider than tall, while cracked-defect boxes have a distinct shape pattern.The analysis is presented through Figure 4.
- Data preprocessing: Most defects are close to square, and their displacement is generally horizontal; Overlap defects move from bottom right to top left.The scatter distribution is relatively even, with few abnormal samples.
Motion deblurring
The paper addresses motion blur caused by relative camera–pipe movement and long exposure during weld imaging. It estimates blur direction and distance, deconvolves the image, and augments training data to improve feature diversity and generalization.
- Motion deblurring: Motion blur arises from relative movement between the X-ray camera and steel pipe, compounded by long single-frame exposure.
- Motion deblurring: The method uses Hough Transform detection of the weld-edge line to estimate motion direction, then derives blur distance from camera frame rate and pipe rotation speed.
- Motion deblurring: The estimated blur kernel is used to deconvolve the original blurry image and produce a deblurred result.
- Data augmentation: Because CNNs require many samples, the original data is expanded to nine times its size using light, rotation, cutout, noise, flipping, color, resize, and cropping transformations.
- Data augmentation: The augmentation process is reported to reduce overfitting and improve network generalization.
Experiments
The experiments train YOLOv5 on an augmented grayscale weld-defect dataset and evaluate it with detection-quality and speed metrics. Precision, recall, F1, and interpolated average precision provide complementary performance measures.
- Experiments: The dataset is augmented, converted to single-channel grayscale, and split into training and validation sets at an 8:2 ratio before YOLOv5 training.
- Experiments: The evaluation uses recall, precision, F1 score, mean average precision, and single-image detection time.
- Evaluation metrics: Precision measures the proportion of true positives among identified weld-defect images, while false positives are incorrectly identified defects.
- Evaluation metrics: Recall measures correctly identified weld defects relative to all steel-pipe weld defects, with false negatives representing missed or background errors.
- Evaluation metrics: F1 is used when both precision and recall must be high, while interpolated average precision captures global performance beyond single-point metrics.
Identify results and data analysis
YOLOv5 detects eight weld-defect categories with generally high precision, recall, and F1 scores. Its best model reaches 99.02% mAP, while small and dense blowhole patterns remain a weaker case and extended training shows overfitting.
- Identify results and data analysis: The detections provide relatively good defect positions and classification confidence, including for Broken defects with substantially different appearances.
- Identify results and data analysis: Undercut performs well despite relatively few samples, while visually subtle Slag inclusion defects remain difficult to distinguish from the background and resemble Undercut.
- Identify results and data analysis: Except for blowhole defects, category precision ranges from 0.962 to 1.00, recall from 0.99 to 1.00, and F1 from 0.998 to 1.00.
- Identify results and data analysis: Blowhole accuracy is lower because its targets are small and a single pipe can contain densely distributed pores.
- Identify results and data analysis: 99.02% mAP is reached at epoch 218, compared with 98.71% after 633 epochs, indicating overfitting with prolonged training.
- Identify results and data analysis: The best saved training model is described as suitable for actual steel-pipe weld-defect detection in industrial production.
Performance comparison of weld defect detection algorithm for steel pipe
The comparison evaluates YOLOv5 against Faster R-CNN and traditional defect-detection algorithms using convergence behavior, accuracy, and single-image detection time. YOLOv5 is reported as more accurate and faster than Faster R-CNN, while deep-learning methods outperform traditional approaches overall.
- Convergence comparison: Compared with Faster R-CNN, YOLOv5 has faster convergence in precision and total loss and greater stability after convergence.
- Algorithm comparison: Deep-learning defect-detection algorithms outperform traditional computer-vision methods in both performance and single-image detection time.
- Algorithm comparison: Among the compared traditional methods, GAN+CFM takes the longest time and OSTU+MSVM-rbf has the lowest accuracy.
- Algorithm comparison: YOLOv5 is superior to Faster R-CNN in both accuracy and single-image detection time, satisfying the paper’s engineering-speed requirement.
- Algorithm comparison: Faster R-CNN forms region proposals before classification and position correction, requiring multiple detection and classification runs and therefore operating more slowly.
Conclusion
The study applies YOLOv5 to steel pipe weld-defect detection, combining preprocessing enhancements with comparative evaluation to support accurate, real-time industrial inspection. It reports strong accuracy and detection speed while acknowledging limited coverage of defects absent from the dataset.
- 97.8% accuracy (mAP@0.5=98.7%) was achieved with YOLOv5 for steel pipe weld-defect detection.
- 0.12s per picture was recorded for YOLOv5x testing, meeting real-time detection requirements on the reported GPU.
- Combining traditional preprocessing with YOLOv5 Mosaic augmentation increased dataset size and reduced training overfitting.
- Comparisons with previous defect-detection algorithms demonstrated YOLOv5 advantages for model deployment and engineering under comprehensive indicators.
- The study provides methods and ideas for real-time automatic steel-pipe weld-defect detection in industrial production environments.
- With a limited dataset, defects absent from the training data cannot be correctly identified, motivating expert-system or few-shot updating approaches.