This is an implementation of the MSPFN model proposed in the paper (Multi-Scale Progressive Fusion Network for Single Image Deraining) with TensorFlow.
- Python 3
- TensorFlow 1.12.0
- OpenCV
- tqdm
- glob
- sys
The repetitive samples of rain streaks in a rain image as well as its multi-scale versions (multi-scale pyramid images) may carry complementary information (e.g., similar appearance) to characterize target rain streaks. We explore the multi-scale representation from input image scales and deep neural network representations in a unified framework, and propose a multi-scale progressive fusion network (MSPFN) to exploit the correlated information of rain streaks across scales for single image deraining.
If you prepare your own dataset, please follow the following form: |--train_data
|--rainysamples
|--file1
:
|--file2
:
|--filen
|--cleansamples
|--file1
:
|--file2
:
|--filen
Then you can produce the corresponding '.npy' in the '/train_data/npy' file.
$ python preprocessing.py
Download training dataset ((raw images)Baidu Cloud, (Password:4qnh) (.npy)Baidu Cloud, (Password:gd2s)), or prepare your own dataset like above form.
Run the following commands:
cd ./model
python train_MSPFN.py
Download the pretrained models (Baidu Cloud, (Password:u5v6)) (Google Drive).
Download the testing dataset (R100H, R100L, TEST100, TEST1200, TEST2800) (Google Drive).
Run the following commands:
cd ./model/test
python test_MSPFN.py
The deraining results will be in './test/test_data/MSPFN'. We only provide the baseline for comparision. There exits the gap (0.1-0.2db) between the provided model and the reported values in the paper, which originates in the subsequent fine tuning of hyperparameters, training process and constrains.
Download the pretrained models.
Put your dataset in './test/test_data/'.
Run the following commands:
cd ./model/test
python test_MSPFN.py
The deraining results will be in './test/test_data/MSPFN'.
@InProceedings{Kui_2020_CVPR,
author = {Jiang, Kui and Wang, Zhongyuan and Yi, Peng and Huang, Baojin and Luo, Yimin and Ma, Jiayi and Jiang, Junjun},
title = {Multi-Scale Progressive Fusion Network for Single Image Deraining},
booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
month = {June},
year = {2020}
}