TL;DR
Annotating video shadow datasets frame-by-frame is an incredibly tedious and expensive task. This paper introduces the Spatio-Temporal Interpolation Consistency Training (STICT) framework, a semi-supervised approach that transfers shadow knowledge from labeled static images to unlabeled videos. By enforcing novel spatial, temporal, and scale consistency constraints during training, the model delivers highly accurate and temporally smooth video shadow maps with zero computational overhead during inference.
What Problem Does This Paper Address?
While deep learning has significantly advanced image shadow detection, video shadow detection (VSD) lags behind due to a severe bottleneck: the lack of large-scale annotated video datasets.
Directly applying a model trained on labeled images to video frames typically fails. It leads to high generalization errors because video scenes often differ from static image datasets. More importantly, processing frames individually ignores the time dimension, causing severe temporal inconsistency—manifesting as distracting flickering and unstable shadow boundaries in the output video. The authors tackle this challenge by finding a way to effectively leverage abundant, unlabeled video data alongside existing labeled image datasets.
Methods
The authors propose the Spatio-Temporal Interpolation Consistency Training (STICT) framework, which operates on a Mean-Teacher learning scheme consisting of a student network and an exponential moving average (EMA) teacher network.
The core components include:
- Spatial ICT: Traditional interpolation consistency training mixes images in the RGB space, which destroys pixel-level semantic layouts. Instead, the authors propose interpolating uncorrelated pixels within the feature space. They introduce a Local Correlation Shuffle (LCS) module to find the most uncorrelated pixels within a local neighborhood, smoothing the decision boundaries for pixel-wise classification.
- Temporal ICT: To enforce temporal smoothness without requiring video labels, the framework warps consecutive frames along the time-axis using optical flow to generate an interpolated middle frame. The student network is then penalized if its prediction on the actual middle frame deviates from the teacher's interpolated prediction.
- Scale-Aware Network (SANet): Shadows in videos change scale dynamically. SANet acts as the single-frame backbone, utilizing an Encoder-Decoder-Refiner structure equipped with a Feature Fusion Module (FFM) and a Detail Attentive Module (DAM). A scale-consistency constraint minimizes discrepancy across multi-scale predictions.
Datasets
The framework was trained and evaluated using three primary datasets:
- SBU: A large-scale annotated image shadow benchmark (4,089 training images) used as the source of labeled data.
- ViSha: The first large-scale video shadow detection dataset, containing 120 videos (11,685 frames).
- VISAD (Video Shadow Detection dataset): A new, challenging dataset introduced by the authors. It comprises 81 videos sourced from existing computer vision benchmarks (like BDD-100K and DAVIS), split into Driving Scenes (DS) and Moving Object Scenes (MOS). The authors densely annotated 33 of these videos manually to provide a robust evaluation benchmark.
Key Insights and Ideas
- Training-Time Constraints vs. Inference-Time Overhead: Unlike methods that use recurrent units or multi-frame feature fusion during deployment (which slows down processing), STICT applies temporal constraints only during training. At test time, the student network processes each frame independently, achieving real-time performance (15ms per frame) with zero temporal-processing overhead.
- Feature-Space vs. RGB-Space Mixing: For dense, pixel-wise tasks like shadow detection, mixing raw images in the RGB space creates semantically meaningless artifacts. Shuffling and interpolating at the feature map level preserves semantic integrity while effectively forcing the model to learn robust class boundaries.
Key Results
Despite using completely unlabeled videos during training, STICT achieved performance competitive with, and occasionally superior to, fully supervised state-of-the-art (SOTA) methods.
- On the VISAD Moving Object Scenes (MOS) dataset: STICT significantly outperformed alternative methods, reducing the Mean Absolute Error (MAE) by 29.3% and the Balance Error Rate (BER) by 10.3% compared to the second-best performing method.
- Ablation Studies: Removing either the Spatial or Temporal ICT components led to a clear degradation in performance, proving that both spatial boundary smoothing and optical-flow-based temporal consistency are vital to the framework's success.
Limitations and Future Work
The authors note a few scenarios where the unsupervised knowledge transfer falls short:
- Extreme Illumination Contrast: The model struggles in scenes with very high lighting contrast.
- Self-Shadows vs. Cast Shadows: It occasionally misclassifies an object's self-shadow as a cast shadow.
- Soft Shadows: Faded or soft-edged shadows are frequently missed.
These limitations stem from the domain gap between the SBU image dataset (which contains these complex shadow patterns with specific annotations) and the target video datasets, marking a clear direction for future domain-adaptation research.
Summary updated