This is the Pytorch implementation for "A general model compression method for image restoration network".
The SWConv is depicted as follows:
The SWConv-F is depicted as follows:
The SW-DnCNN, SW-RCAN and SW-DnCNN-3 are implemented in SWDnCNN.py, SWRCAN.py and SWDnCNN3.py, respectively. The original networks can be replaced by the corresponding ones for retraining and test.