This repository contains the PyTorch based official implementation of the paper titled:
Cascaded Local Implicit Transformer for Arbitrary-Scale Super-Resolution CVPR 2023.
- Python >= 3.7.0
- PyTorch >= 1.8.0
Stage1: python train.py --config configs/train/train_edsr_baseline_lit.yaml --name lit_edsr
Stage2: python train.py --config configs/train/train_edsr_baseline_clit2.yaml --name clit_edsr2
Stage3: python train.py --config configs/train/train_edsr_baseline_clit3.yaml --name clit_edsr3
Stage1: python train.py --config configs/train/train_rdn_lit.yaml --name lit_rdn
Stage1: python train.py --config configs/train/train_rdn_clit2.yaml --name clit_rdn2
Stage1: python train.py --config configs/train/train_rdn_clit3.yaml --name clit_rdn3
Stage1: python train.py --config configs/train/train_swinir_lit.yaml --name lit_swinir
Stage2: python train.py --config configs/train/train_swinir_clit2.yaml --name clit_swinir2
Stage3: python train.py --config configs/train/train_swinir_clit3.yaml --name clit_swinir3
Ex: train the stage2 CLIT using edsr-baseline model
pre_train: save/lit_edsr/epoch-last.pth
bash eval.sh "put the model name here"
bash eval_swinir.sh "put the model name here"
python demo.py --model save/lit_rdn/epoch-last.pth --img_path assests/0868x4.png --scale 6
Inputs | Attention Heads |
---|---|
Method (SSIM) |
x2 | x3 | x4 | x6 | x12 | x18 | x24 | x30 |
---|---|---|---|---|---|---|---|---|
EDSR-Baseline-CLIT | 0.9397 | 0.8790 | 0.8266 | 0.7503 | 0.6439 | 0.6006 | 0.5771 | 0.5629 |
RDN-CLIT | 0.9418 | 0.8829 | 0.8319 | 0.7564 | 0.6497 | 0.6053 | 0.5804 | 0.5657 |
SwinIR-CLIT | 0.9436 | 0.8859 | 0.8357 | 0.7608 | 0.6534 | 0.6080 | 0.5830 | 0.5675 |
Method (SSIM) |
x2 | x3 | x4 | x6 | x8 |
---|---|---|---|---|---|
RDN-CLIT | 0.9474 | 0.9101 | 0.8760 | 0.8053 | 0.7451 |
SwinIR-CLIT | 0.9482 | 0.9117 | 0.8787 | 0.8131 | 0.7521 |
Method (SSIM) |
x2 | x3 | x4 | x6 | x8 |
---|---|---|---|---|---|
RDN-CLIT | 0.9023 | 0.8227 | 0.7619 | 0.6748 | 0.6184 |
SwinIR-CLIT | 0.9030 | 0.8262 | 0.7656 | 0.6789 | 0.6210 |
Method (SSIM) |
x2 | x3 | x4 | x6 | x8 |
---|---|---|---|---|---|
RDN-CLIT | 0.8962 | 0.8003 | 0.7304 | 0.6404 | 0.5876 |
SwinIR-CLIT | 0.8975 | 0.8029 | 0.7341 | 0.6443 | 0.5907 |
Method (SSIM) |
x2 | x3 | x4 | x6 | x8 |
---|---|---|---|---|---|
RDN-CLIT | 0.9298 | 0.8568 | 0.7942 | 0.6918 | 0.6224 |
SwinIR-CLIT | 0.9335 | 0.8651 | 0.8051 | 0.7070 | 0.6369 |
This repo is built on LIIF and LTE. Thanks the authors for their contributions and generosity.