we propose EfficientDerain for high-efficiency single-image deraining

Overview

EfficientDerain

we propose EfficientDerain for high-efficiency single-image deraining

Requirements

  • python 3.6
  • pytorch 1.6.0
  • opencv-python 4.4.0.44
  • scikit-image 0.17.2

Datasets

Pretrained models

Here is the urls of pretrained models (includes v3_rain100H, v3_rain1400, v3_SPA, v4_rain100H, v4_rain1400, v4_SPA) :

direct download: http://www.xujuefei.com/models_effderain.zip

google drive: https://drive.google.com/file/d/1OBAIG4su6vIPEimTX7PNuQTxZDjtCUD8/view?usp=sharing

baiduyun: https://pan.baidu.com/s/1kFWP-b3tD8Ms7VCBj9f1kw (pwd: vr3g)

Train

  • The code shown corresponds to version v3, for v4 change the value of argument "rainaug" in file "./train.sh" to the "true" (You need to unzip the "Streaks_Garg06.zip" in the "./rainmix")
  • Change the value of argument "baseroot" in file "./train.sh" to the path of training data
  • Edit the function "get_files" in file "./utils" according to the format of the training data
  • Execute
sh train.sh

Test

  • The code shown corresponds to version v3
  • Change the value of argument "load_name" in file "./test.sh" to the path of pretained model
  • Change the value of argument "baseroot" in file "./test.sh" to the path of testing data
  • Edit the function "get_files" in file "./utils" according to the format of the testing data
  • Execute
sh test.sh

Results

The specific results can be found in “./results/data/DERAIN.xlsx

GT vs RCDNet

GT vs EfDeRain

Input vs GT

GT vs RCDNet

GT vs EfDeRain

Input vs GT

GT vs v1

GT vs v2

GT vs v3

GT vs v4

GT vs v1

GT vs v2

GT vs v3

GT vs v4

Bibtex

@inproceedings{guo2020efficientderain,
      title={EfficientDeRain: Learning Pixel-wise Dilation Filtering for High-Efficiency Single-Image Deraining}, 
      author={Qing Guo and Jingyang Sun and Felix Juefei-Xu and Lei Ma and Xiaofei Xie and Wei Feng and Yang Liu},
      year={2021},
      booktitle={AAAI}
}
Comments
  • Update result2test.py

    Update result2test.py

    It arises an error (ImportError: cannot import name 'compare_ssim' from 'skimage.measure') while running "result2test.py". The error is because of the fact skimage.measure.compare_ssim has been removed in skimage 0.18.

    To fix the issue, a line in the code in respective file needs to be changed from "from skimage.measure import compare_ssim, compare_psnr" to "from skimage.metrics import structural_similarity".

    opened by xenbaloch 2
  • About rain100H Dataset

    About rain100H Dataset

    Hi,I have a question about dataset. For rain100H dataset,Why is there a large number of images simultaneously existing in the training set and the test set ? Is this training on the test set?

    opened by yanlongbinluck 2
  • Hello, What did I miss,Why didn't I  get the same results as  v3_rain100H.pth?

    Hello, What did I miss,Why didn't I get the same results as v3_rain100H.pth?

    I'm using ”train.sh” just like the file I just downloaded. Can you provide some information on how to train the same test results with thedatasets you specify??

    opened by Jackyinuo 2
  • Need help with a 'Value error'!

    Need help with a 'Value error'!

    Well, that's not an issue with the code or anything. It's more like a help. I'm new with this thing, I tried to use and run your code in Pycharm(fulfilling the requirements), but when I try to run train.py, I'm getting an error "ValueError: num_samples should be a positive integer value, but got num_samples=0". I need help regarding it, where I'm doing wrong? Thank you!

    A bit more description: I tried to use the code as it is, and in models folder, I put the material downloaded from provided link "direct download: http://www.xujuefei.com/models_effderain.zip". Is there some wrong with the data path?

    opened by xenbaloch 1
  • cannot import name 'compare_ssim' from 'skimage.measure'

    cannot import name 'compare_ssim' from 'skimage.measure'

    Traceback (most recent call last): File "./validation.py", line 8, in from skimage.measure import compare_ssim ImportError: cannot import name 'compare_ssim' from 'skimage.measure' (C:\Users\whu_c\anaconda3\envs\yolov5\lib\site-packages\skimage\measure_init_.py)

    what's the problem

    opened by job2003 1
  • There is something wrong with test.py

    There is something wrong with test.py

    Thanks for your code. But I found test.py is empty. I have downloaded it several times, but it doesn't work. Shall we write test.py? Or there is something with my PC and net. THANK U A LOT.

    opened by niudaohong 1
  • Training accuracy problem

    Training accuracy problem

    Hello, thank you for releasing the code.

    But according to the train.sh you provided, the accuracy of PSNR obtained by training the rain100H dataset is only about 23~24, and the SSIM is about 0.77. I don’t know what went wrong.

    Can you give me some advice? Thanks again for your work

    opened by wycm2022 1
  • Update validation.py

    Update validation.py

    It arises an error (ImportError: cannot import name 'compare_ssim' from 'skimage.measure') while running "validation.py". The error is because of the fact skimage.measure.compare_ssim has been removed in skimage 0.18.

    To fix the issue, a line in the code in respective file needs to be changed from "from skimage.measure import compare_ssim, compare_psnr" to "from skimage.metrics import structural_similarity".

    opened by xenbaloch 0
  • map_location with device CPU should be provided in case --no-gpu option is used by the executer

    map_location with device CPU should be provided in case --no-gpu option is used by the executer

    https://github.com/tsingqguo/efficientderain/blob/465759da2428a4263eeee6ab464a0135fca2900c/utils.py#L26

    torch.load(opt.load_name, map_location=torch.device('cpu'))

    opened by harshlunia7 0
  • Is it possible with one model to derain ?

    Is it possible with one model to derain ?

    Dear friends, Thanks for your good work ! We have one question: Is it possible for one model to for all kinds of test set ? For your source code, for different test set, we need load different model. Best regards,

    opened by delldu 1
  • colorful stain in the predicted picture and question about loss

    colorful stain in the predicted picture and question about loss

    colorful stain comes around in the birght side of the predicted picture

    Firstly, really thank you for your code implementation and brilliant idea. I am using it for my project. However, I encountered some problems here. Any help is appreciated!!

    As shown the picture below, left is input, middle is predicted, right is gt. The model mysteriously conjures up some bright color in some places especially the white area. Did it happened to you? How can I solve it? Or it's basically the inherent problem of the model? Even if I did some normalization to input images, it couldn't get any improvement.

                transform_list += [transforms.Normalize((0.3908, 0.3859, 0.3637), (0.2434, 0.2473, 0.2440))]
    

    image Here is the loss curve. The above issue almost happened from the beginning epoches. I let it run for almost 1000 epoches. Loss didn't change since 100th epoch. Why loss converges so quickly? Can the model learn from the stagnate loss? I don't understand. How many epoches did you run before? Is there any trick to train the model? image Here is my model parameters.

    python ./train.py ^
    --baseroot "./datasets/video_collection_25/" ^
    --load_name "" ^
    --multi_gpu "false" ^
    --save_path "./models/models_video_coll_25_04072000" ^
    --sample_path "./samples_kuhn/models_video_coll_25_04072000" ^
    --save_mode "epoch" ^
    --save_by_epoch 10 ^
    --save_by_iter 100000 ^
    --lr_g 0.0002 ^
    --b1 0.5 ^
    --b2 0.999 ^
    --weight_decay 0.0 ^
    --train_batch_size 110 ^
    --train_batch_size 16 ^
    --epochs 2000 ^
    --lr_decrease_epoch 500 ^
    --num_workers 0 ^
    --crop_size 128 ^
    --no_gpu "false" ^
    --rainaug "false" ^
    --gpu_ids 0 ^
    --no_flip
    

    By the way, I added the visualizer module for your model using visdom. Would you like me to upload?

    opened by dongwhfdyer 2
Owner
Qing Guo
Presidential Postdoctoral Fellow with the Nanyang Technological University. Research interests are computer vision, image processing, deep learning.
Qing Guo
We propose a new method for effective shadow removal by regarding it as an exposure fusion problem.

Auto-exposure fusion for single-image shadow removal We propose a new method for effective shadow removal by regarding it as an exposure fusion proble

Qing Guo 146 Dec 31, 2022
Propose a principled and practically effective framework for unsupervised accuracy estimation and error detection tasks with theoretical analysis and state-of-the-art performance.

Detecting Errors and Estimating Accuracy on Unlabeled Data with Self-training Ensembles This project is for the paper: Detecting Errors and Estimating

Jiefeng Chen 13 Nov 21, 2022
Video Instance Segmentation with a Propose-Reduce Paradigm (ICCV 2021)

Propose-Reduce VIS This repo contains the official implementation for the paper: Video Instance Segmentation with a Propose-Reduce Paradigm Huaijia Li

DV Lab 39 Nov 23, 2022
To propose and implement a multi-class classification approach to disaster assessment from the given data set of post-earthquake satellite imagery.

To propose and implement a multi-class classification approach to disaster assessment from the given data set of post-earthquake satellite imagery.

Kunal Wadhwa 2 Jan 5, 2022
Semi-supervised Video Deraining with Dynamical Rain Generator (CVPR, 2021, Pytorch)

S2VD Semi-supervised Video Deraining with Dynamical Rain Generator (CVPR, 2021) Requirements and Dependencies Ubuntu 16.04, cuda 10.0 Python 3.6.10, P

Zongsheng Yue 53 Nov 23, 2022
[CVPR 2021] Monocular depth estimation using wavelets for efficiency

Single Image Depth Prediction with Wavelet Decomposition Michaël Ramamonjisoa, Michael Firman, Jamie Watson, Vincent Lepetit and Daniyar Turmukhambeto

Niantic Labs 205 Jan 2, 2023
Model Zoo for AI Model Efficiency Toolkit

We provide a collection of popular neural network models and compare their floating point and quantized performance.

Qualcomm Innovation Center 137 Jan 3, 2023
Code of the paper "Performance-Efficiency Trade-offs in Unsupervised Pre-training for Speech Recognition"

SEW (Squeezed and Efficient Wav2vec) The repo contains the code of the paper "Performance-Efficiency Trade-offs in Unsupervised Pre-training for Speec

ASAPP Research 67 Dec 1, 2022
Code associated with the paper "Deep Optics for Single-shot High-dynamic-range Imaging"

Deep Optics for Single-shot High-dynamic-range Imaging Code associated with the paper "Deep Optics for Single-shot High-dynamic-range Imaging" CVPR, 2

Stanford Computational Imaging Lab 40 Dec 12, 2022
Official implementation of "SinIR: Efficient General Image Manipulation with Single Image Reconstruction" (ICML 2021)

SinIR (Official Implementation) Requirements To install requirements: pip install -r requirements.txt We used Python 3.7.4 and f-strings which are in

null 47 Oct 11, 2022
Accurate 3D Face Reconstruction with Weakly-Supervised Learning: From Single Image to Image Set (CVPRW 2019). A PyTorch implementation.

Accurate 3D Face Reconstruction with Weakly-Supervised Learning: From Single Image to Image Set —— PyTorch implementation This is an unofficial offici

Sicheng Xu 833 Dec 28, 2022
E2EC: An End-to-End Contour-based Method for High-Quality High-Speed Instance Segmentation

E2EC: An End-to-End Contour-based Method for High-Quality High-Speed Instance Segmentation E2EC: An End-to-End Contour-based Method for High-Quality H

zhangtao 146 Dec 29, 2022
AOT-GAN for High-Resolution Image Inpainting (codebase for image inpainting)

AOT-GAN for High-Resolution Image Inpainting Arxiv Paper | AOT-GAN: Aggregated Contextual Transformations for High-Resolution Image Inpainting Yanhong

Multimedia Research 214 Jan 3, 2023
A fast poisson image editing implementation that can utilize multi-core CPU or GPU to handle a high-resolution image input.

Poisson Image Editing - A Parallel Implementation Jiayi Weng (jiayiwen), Zixu Chen (zixuc) Poisson Image Editing is a technique that can fuse two imag

Jiayi Weng 110 Dec 27, 2022
《Deep Single Portrait Image Relighting》(ICCV 2019)

Ratio Image Based Rendering for Deep Single-Image Portrait Relighting [Project Page] This is part of the Deep Portrait Relighting project. If you find

null 62 Dec 21, 2022
CoReNet is a technique for joint multi-object 3D reconstruction from a single RGB image.

CoReNet CoReNet is a technique for joint multi-object 3D reconstruction from a single RGB image. It produces coherent reconstructions, where all objec

Google Research 80 Dec 25, 2022
《Single Image Reflection Removal Beyond Linearity》(CVPR 2019)

Single-Image-Reflection-Removal-Beyond-Linearity Paper Single Image Reflection Removal Beyond Linearity. Qiang Wen, Yinjie Tan, Jing Qin, Wenxi Liu, G

Qiang Wen 51 Jun 24, 2022
Official PyTorch code of Holistic 3D Scene Understanding from a Single Image with Implicit Representation (CVPR 2021)

Implicit3DUnderstanding (Im3D) [Project Page] Holistic 3D Scene Understanding from a Single Image with Implicit Representation Cheng Zhang, Zhaopeng C

Cheng Zhang 149 Jan 8, 2023