Introduction
In automated robotic welding, accurate seam tracking is essential. However, industrial environments present significant challenges for computer vision, including blinding arc light, flying sparks, and thick smoke. While deep learning models offer robustness against such noise, they often face a "speed vs. accuracy" trade-off. Heavyweight models like TransUNet provide high accuracy but are too computationally expensive for real-time industrial use, while existing lightweight models often sacrifice precision.
DSNet (Dynamic Squeeze Network) is proposed to bridge this gap. It is a lightweight hybrid CNN-Transformer architecture designed for high-speed, high-accuracy segmentation on entry-level hardware.
DSNet Architecture
The core of DSNet lies in its efficiency-focused design, which utilizes three primary innovations to achieve state-of-the-art performance.
Dynamic Squeeze Encoder (DSE)
Unlike traditional encoders that expand channel dimensions in deeper layers—often leading to feature redundancy—the DSE employs a "Dynamic Squeeze" strategy. It expands channels in shallow layers to capture rich spatial details but squeezes them in deeper stages. This approach maintains feature diversity while significantly reducing the parameter count.
Dynamic Squeeze Attention (DSA)
Weld seams are typically long and thin. To exploit this geometry, the authors developed the DSA module. It uses strip convolutions (1x3 and 3x1 kernels) as linear priors, guiding the network to focus on elongated features rather than generic shapes.
Central Aggregation
To incorporate global context without the high computational cost of standard Transformers, DSNet applies a Multi-Head Self-Attention module only at the bottleneck (the lowest resolution). This ensures the model benefits from long-range dependencies where the token count is minimal.
Experimental Evaluation
The model was evaluated on two specific targets:
- Weld Seam Segmentation: A dataset of 193 images, including real-world captures featuring intense arc light and smoke.
- Road Crack Segmentation: A dataset of 151 images used to test generalizability, as cracks share the strip-like geometry of weld seams.
Experiments were conducted on an NVIDIA GTX 1050Ti to demonstrate viability for low-cost industrial edge controllers.
Results and Key Insights
DSNet achieves a superior balance of speed and accuracy compared to nearly 20 state-of-the-art methods.
- Performance: The model achieved an 87.64% Dice score and 78.01% IoU on the weld seam dataset while running at 100 FPS.
- Efficiency: Compared to TransUNet, DSNet has 54x fewer parameters and is 33x faster. It also outperformed lightweight models like UNeXt (82 FPS) and SeaFormer (29 FPS) in both speed and accuracy.
- The Redundancy Paradox: Analysis showed that squeezing hidden dimensions in deep layers actually forced the model to learn more distinct, useful features, countering the common practice of continuous channel expansion.
Conclusion
DSNet demonstrates that a specialized "squeeze" strategy and linear priors can enable high-performance real-time segmentation on budget hardware. Future work includes implementing dynamic convolutions to adjust dimensionality based on noise levels and integrating the model into closed-loop robotic control systems for live production testing.
Summary updated