TL;DR
This paper introduces an improved Faster R-CNN model for detecting defects in automotive body-in-white (BIW) resistance spot welds. By optimizing anchor box selection and introducing a novel network pruning technique, the model achieves over 90% accuracy and recall at a speed of 15 ms per image, making it suitable for real-time industrial quality control.
What Problem Does This Paper Address?
Ensuring the quality of resistance spot welds is critical for the structural integrity and safety of automotive bodies. Traditional manual visual inspection is labor-intensive, subjective, and prone to errors, especially in the harsh industrial environments of auto manufacturing (vibration, dust, varying lighting). While non-visual methods like ultrasonic or X-ray testing exist, they can be costly or complex. This paper addresses the need for an automated, accurate, and efficient visual inspection system for detecting surface defects in these welds, particularly for small and subtle anomalies that can impact weld quality.
Methods
The core of this work is an enhanced Faster R-CNN architecture. The authors introduce two main innovations:
- Improved Anchor Box Selection: Instead of relying on all anchor boxes generated by the Region Proposal Network (RPN), they prioritize high-confidence anchor boxes. This refinement helps the RPN more accurately locate the welding spots, especially when dealing with small objects.
- Lightweight Network Pruning: To accelerate processing and reduce computational load for industrial deployment, a structured pruning approach is employed. This involves iteratively removing redundant convolutional and fully connected layers, as well as reducing parameters in hidden layers. The goal is to find an optimal balance between model size, speed, and detection accuracy.
The model also utilizes the Smooth L1 loss function for bounding box regression, which offers a good trade-off between the stability of L2 loss and the constant gradient of L1 loss, particularly beneficial for accurate localization.
Datasets
The study utilized a custom dataset of 1000 images of resistance spot welds collected from an automotive assembly line. This dataset was split into 800 images for training and 200 for testing. The images have a resolution of 4032 × 3024 pixels. A significant challenge noted is the imbalance between normal and abnormal spots (abnormal spots being less than 0.1% in typical production, though their dataset had ~10%). Data augmentation techniques were applied to mitigate this imbalance.
Key Insights and Ideas
- High-confidence anchors are key for small object detection: Focusing RPN proposals on high-confidence anchors significantly improves the ability to accurately locate small welding spots, which are often the most critical to detect for quality control.
- Pruning can yield a faster, more efficient model without sacrificing accuracy: The structured pruning approach demonstrates that significant parameter reduction is possible, leading to a much faster inference time (15 ms) while maintaining or even improving detection accuracy (92.5% mAP). This is crucial for real-time industrial applications.
- Smooth L1 loss is a robust choice for localization: The paper highlights the benefits of Smooth L1 loss for bounding box regression, showing its effectiveness in achieving precise defect localization compared to standard L1 or L2 losses.
- Overfitting can be mitigated by targeted pruning: In scenarios with limited or imbalanced data, aggressive pruning of network parameters can paradoxically reduce overfitting by simplifying the model and making it less sensitive to noise in the training data.
Key Results
The proposed improved Faster R-CNN model achieved:
- Accuracy: 92.50% mAP (mean Average Precision) and 90.40% Recall (bad), outperforming classical Faster R-CNN (90.11% mAP, 88.60% Recall) and other models like SSD and CNN-Lenet5.
- Speed: An inference time of 15 ms per image (approximately 66 FPS), meeting industrial real-time requirements.
- Parameter Reduction: The pruning process significantly reduced the model's parameter count, with the final optimized model having 25.5 M parameters and a processing time of 0.025s per frame.
Limitations and Future Work
Limitations:
- Data Scarcity and Imbalance: The authors acknowledge that the dataset, while custom-collected, is still insufficient and imbalanced, which can lead to over-fitting and recognition errors, especially for subtle defects.
- Surface Defects Only: The current model is primarily designed for detecting surface welding spot defects and may not be effective for detecting volumetric defects.
Future Work:
- Data Improvement: Enhance the data management system, increase the dataset size and diversity, and explore advanced data augmentation techniques.
- Speed Optimization: Investigate further speed improvements by exploring lightweight backbones (e.g., MobileNet, EfficientNet) or optimizing the RPN.
- Multi-Scale Detection: Improve the model's capability to detect defects of varying sizes, potentially by incorporating Feature Pyramid Networks (FPN).
- Multi-Modal Validation: Integrate visual inspection with other validation techniques like metallography, destructive testing, ultrasonic, or X-ray inspection for a more comprehensive quality control framework.
Summary updated