Abstract
Shadow removal is a fundamental task in computer vision, traditionally reliant on paired datasets that are difficult to acquire and often contain misalignments. We present a novel self-supervised framework that leverages a conditional mask to jointly learn shadow removal and addition. By enforcing a bijective mapping between shadowed and shadow-free domains, our method achieves state-of-the-art performance on unsupervised benchmarks and rivals supervised approaches.
Introduction
Shadows significantly impact image analysis tasks by altering local illumination and texture. While supervised deep learning has advanced shadow removal, the requirement for perfectly aligned "shadowed" and "shadow-free" image pairs limits scalability and real-world applicability. This paper discusses a self-supervised approach developed by researchers at ETH Zurich that bypasses the need for paired training data.
The Challenge of Paired Data
The primary bottleneck in shadow removal is the scarcity of high-quality paired data. Capturing the same scene with and without shadows requires static environments and precise timing, yet even minor changes like foliage movement or solar progression introduce inconsistencies. Existing unsupervised methods often produce blurry results or artifacts due to the lack of a strong supervisory signal.
Proposed Method: The $S^3$ Framework
The authors propose a framework based on the CycleGAN architecture, modified to incorporate spatial conditioning via shadow masks. The system consists of two primary generators:
- $G_f$ (Shadow Removal): Maps a shadowed image $v$ to a shadow-free estimate $\hat{u}$.
- $G_s$ (Shadow Addition): Maps a shadow-free image $u$ and a binary mask $m$ to a shadowed estimate $\hat{v}$.
Self-Supervised Shadow ($S^3$) Loss
The core innovation is the use of a mask buffer to provide random shadow shapes during training. This forces $G_s$ to learn the physics of shadow placement. The model is optimized using a Perceptual Ensemble Loss:
- Color Loss: Maintains low-frequency color consistency using Gaussian blurring.
- Content & Style Losses: Utilizes features from a pre-trained VGG-16 network to ensure underlying objects and textures remain unchanged.
- Mask Loss: Enforces bijectivity by ensuring the shadow removed in the "forward" step matches the shadow added in the "reconstruction" step.
Experiments and Results
The model was evaluated on the ISTD and USR benchmarks. On the ISTD dataset, the proposed method achieved a Root Mean Square Error (RMSE) of 7.58 in the Lab color space, significantly outperforming the previous unsupervised state-of-the-art, MaskShadowGAN (28.34 RMSE).
Qualitatively, the results demonstrate sharper textures and fewer artifacts compared to standard CycleGAN implementations. Notably, the unsupervised model outperformed several established supervised methods (such as DSC and DeShadowNet), suggesting that the diversity of shadows seen during self-supervised training aids generalization better than limited, potentially misaligned paired data.
Conclusion
This self-supervised approach demonstrates that paired data is not a prerequisite for high-fidelity shadow removal. By treating shadow removal as a bijective task and utilizing perceptual losses, the model achieves superior generalization and visual quality. Future work will focus on handling more complex, non-homogeneous shadows and extending the framework to real-time video sequences where temporal consistency is required.
Summary updated