Should We Encode Rain Streaks in Video as Deterministic or Stochastic?

Wei Wei, Lixuan Yi, Qi Xie, Qian Zhao, Deyu Meng, Zongben Xu

TL;DR

Most video rain removal techniques treat rain as a deterministic pattern with fixed physical properties. This paper proposes a paradigm shift by modeling rain as a stochastic process using a Patch-based Mixture of Gaussians (P-MoG). This approach allows the system to adapt to diverse rain types—from light drizzle to heavy storms—without requiring supervised pre-training on specific datasets.

What Problem Does This Paper Address?

Rain streaks are a significant challenge for outdoor computer vision systems, degrading the performance of object tracking, surveillance, and autonomous driving. The core difficulty in Rain Streak Removal from Video (RSRV) lies in effectively separating the rain from the "clean" video layers: the static background and the moving foreground objects.

Traditional methods typically suffer from two main limitations:

  1. Rigid Physical Models: They often assume rain consists of thin, vertical lines. These models fail when faced with wind-blown rain or misty conditions.
  2. Over-fitting: Modern deep learning approaches require massive amounts of annotated "rainy vs. clean" data. Consequently, they perform well on specific trained rain types but struggle with the infinite variety of real-world weather conditions.

The authors propose a different question: instead of pre-defining what rain looks like, can a system learn the statistical distribution of rain directly from a specific video?

Methods

The proposed unified model decomposes a video into three distinct layers: Background, Moving Objects, and Rain Streaks.

The model decomposes the input video into three layers: a low-rank background, a stochastic rain layer, and a smooth moving object layer.
  • The Rain Layer (Stochastic Modeling): This is the core innovation. Instead of a deterministic mask, rain is modeled as a Patch-based Mixture of Gaussians (P-MoG). By treating patches of rain as samples from a probability distribution, the model can represent multiple "modes" of rain simultaneously (e.g., thick streaks and fine mist).
  • The Background Layer: This is modeled using low-rank matrix factorization. Since the background in surveillance video is largely static, it possesses a simple, low-dimensional structure.
  • The Moving Object Layer: To capture foreground movement, the authors utilize 3D Total Variation (3DTV). This enforces spatiotemporal smoothness, ensuring that moving objects maintain consistent shapes across consecutive frames.

The model is optimized using an Expectation-Maximization (EM) algorithm. The "E-step" estimates which Gaussian component a rain patch belongs to, while the "M-step" updates the parameters for the rain, background, and foreground layers.

Key Insights and Ideas

Covariance as Shape

A primary insight of the paper is the visualization of the learned Gaussian covariance matrices. The model naturally learns components that correspond to physical reality without manual intervention.

Visualization of the learned P-MoG components. The covariance matrices capture different physical characteristics, such as oriented streaks or blocky raindrops.

As shown in the visualization, different components capture different aspects of the scene: one might represent blocky raindrops, another captures thin oriented streaks, and a third identifies random camera noise. This flexibility allows the model to adapt to the specific "texture" of the rain in any given video.

Rain as the "Residual"

By strictly defining the mathematical properties of the background (low-rank) and foreground (smooth/continuous), the model forces the "messy," stochastic elements—the rain—into the P-MoG layer. This unsupervised approach means the system learns the specific characteristics of the rain from the input video itself, removing the need for pre-collected rainy datasets.

Key Results

  • Quantitative Superiority: In synthetic tests using the CDNET database, the P-MoG method consistently outperformed state-of-the-art deterministic and deep learning methods across metrics like SSIM (Structural Similarity) and FSIM (Feature Similarity).
  • Visual Fidelity: Qualitatively, the method excels at preserving the textures of moving objects. While other methods often "smudge" the foreground or leave ghosting artifacts, P-MoG keeps moving objects sharp while removing more rain.
  • Implicit Denoising: Because the model is stochastic, it treats camera noise similarly to light rain. This effectively denoises the video during the deraining process. This is why it occasionally scores lower on PSNR (Peak Signal-to-Noise Ratio) if the ground truth contains noise—it is actually producing a result cleaner than the original "clean" baseline.

Limitations and Future Work

While powerful, the current model has limitations. It relies on low-rank structures for the background, which assumes a static camera. If the camera pans or tilts, the background model currently struggles. Additionally, while the EM algorithm is efficient, it is not yet optimized for real-time processing. Future research may explore online strategies to handle long videos and adaptations for moving camera platforms.

Summary updated

BibTeX
@inproceedings{wei2017should,
  author = {Wei Wei and Lixuan Yi and Qi Xie and Qian Zhao and Deyu Meng and Zongben Xu},
  title = {{Should We Encode Rain Streaks in Video as Deterministic or Stochastic?}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2017},
  doi = {10.1109/iccv.2017.275},
}
Figure