Abstract
State-of-the-art image restoration and spectral reconstruction models often rely on Channel-wise Self-Attention (CSA) to capture global dependencies. However, CSA is computationally expensive and parameter-heavy. We propose Guided Low-rank Multi-Head Self-Attention (GLMHA), which exploits the inherent low-rank nature of attention matrices. By utilizing a lightweight calibration network to guide feature projection, GLMHA reduces computational costs by up to 7.7 GFLOPs and parameters by 370K with negligible performance loss across multiple benchmarks.
Introduction
Image restoration tasks such as deblurring and deraining, along with spectral reconstruction, have seen significant progress through hybrid CNN-Transformer architectures. These models typically employ Channel-wise Self-Attention (CSA), which attends to feature channels rather than spatial patches, offering better efficiency for high-resolution images. Despite this, CSA remains a bottleneck. Existing efficient Transformer variants like Linformer or Performer often fail to provide meaningful gains for the shorter sequences typical in CSA or reduce FLOPs at the cost of increased parameters.
Motivation: The Low-Rank Nature of Attention
The primary motivation for GLMHA stems from the observation that attention matrices in restoration models are highly redundant. Through Singular Value Decomposition (SVD) analysis of models like Restormer and MST++, the authors found that a small fraction of eigenvalues accounts for over 95% of the signal energy.
This empirical evidence suggests that full-rank attention calculations are computationally wasteful, as most information is concentrated in a low-rank subspace. GLMHA aims to exploit this redundancy to build a leaner attention mechanism.
Proposed Method: GLMHA
Guided Low-rank Multi-Head Self-Attention (GLMHA) is designed as a drop-in replacement for CSA. It introduces three key innovations to maintain quality while reducing complexity:
- Calibration Network ($\varphi_{calibrate}$): A small sub-network processing the Query ($Q$) to generate an instance-specific calibration vector. This network uses max-pooling and depth-wise convolutions to identify important features.
- Instance-Guided Weighting: This vector re-weights the input feature map, ensuring semantically critical features are preserved during rank reduction.
- Direct Low-Rank Projection: GLMHA projects the weighted input directly into a lower-dimensional space ($C' < C$), reducing both FLOPs and parameters simultaneously.
Unlike previous methods that compress full-sized matrices, GLMHA avoids generating large intermediate tensors, providing consistent efficiency gains across various sequence lengths.
Experimental Results
GLMHA was integrated into three state-of-the-art base models: Restormer, MST-L, and MST++. Evaluations were conducted across spectral reconstruction (NTIRE 2022), motion deblurring (GoPro), and image deraining (Rain13k).
Key findings include:
- Efficiency Gains: In Restormer for deraining, GLMHA saved 6.46 GFLOPs and 350K parameters.
- Performance Retention: PSNR drops were minimal. For HSI reconstruction, MST++ with GLMHA achieved 34.21 dB compared to the original's 34.32 dB.
- Superiority Over Rivals: GLMHA outperformed Reformer, Linformer, and Performer, which often suffered significant quality degradation (up to 4dB PSNR loss) or failed to reduce parameter counts.
Conclusion
GLMHA demonstrates that the redundancy in channel-wise self-attention can be effectively exploited through guided low-rank projection. By using a calibration network to maintain signal energy, GLMHA offers a more efficient path for high-performance image restoration without the heavy computational burden of traditional attention mechanisms.
Summary updated