mv-lab / swin2sr

3 Million Runs! AI Photorealistic Image Super-Resolution and Restoration

  • Public
  • 3.5M runs
  • GitHub
  • Paper
  • License



Run time and cost

This model runs on Nvidia T4 GPU hardware. Predictions typically complete within 26 seconds. The predict time for this model varies significantly based on the inputs.


Swin2SR: SwinV2 Transformer for Compressed Image Super-Resolution and Restoration @ AIM ECCV 2022

Marcos V. Conde, Ui-Jin Choi, Maxime Burchi, Radu Timofte

Computer Vision Lab, CAIDAS, University of Würzburg and MegaStudyEdu, South Korea

This work is inspired by the amazing SwinIR by Jingyun Liang, as a possible improvement.

This is the official repository and PyTorch implementation of Swin2SR. We provide the supplementary material, code, pretrained models and demos. Swin2SR represents a possible improvement of the famous SwinIR by Jingyun Liang (kudos for such an amazing contribution ✋). Our model achieves state-of-the-art performance in:

swin2sr teaser

swin2sr teaser



Compression plays an important role on the efficient transmission and storage of images and videos through band-limited systems such as streaming services, virtual reality or videogames. However, compression unavoidably leads to artifacts and the loss of the original information, which may severely degrade the visual quality. For these reasons, quality enhancement of compressed images has become a popular research topic. While most state-of-the-art image restoration methods are based on convolutional neural networks, other transformers-based methods such as SwinIR, show impressive performance on these tasks.

In this paper, we explore the novel Swin Transformer V2, to improve SwinIR for image super-resolution, and in particular, the compressed input scenario. Using this method we can tackle the major issues in training transformer vision models, such as training instability, resolution gaps between pre-training and fine-tuning, and hunger on data. We conduct experiments on three representative tasks: JPEG compression artifacts removal, image super-resolution (classical and lightweight), and compressed image super-resolution. Experimental results demonstrate that our method, Swin2SR, can improve the training convergence and performance of SwinIR, and is a top-5 solution at the “AIM 2022 Challenge on Super-Resolution of Compressed Image and Video”.

Citation and Acknowledgement

  title={{S}win2{SR}: SwinV2 Transformer for Compressed Image Super-Resolution and Restoration},
  author={Conde, Marcos V and Choi, Ui-Jin and Burchi, Maxime and Timofte, Radu},
  booktitle={Proceedings of the European Conference on Computer Vision (ECCV) Workshops},

  title={SwinIR: Image Restoration Using Swin Transformer},
  author={Liang, Jingyun and Cao, Jiezhang and Sun, Guolei and Zhang, Kai and Van Gool, Luc and Timofte, Radu},
  journal={arXiv preprint arXiv:2108.10257},

This project is released under the Apache 2.0 license. The codes are heavily based on Swin Transformer and SwinV2 Transformer by Ze Liu. We also refer to codes in KAIR, BasicSR and SwinIR. Please also follow their licenses. Thanks for their awesome works.


Marcos Conde ( and Ui-Jin Choi ( are the contact persons. Please add in the email subject “swin2sr”.