Fanghua-Yu /SUPIR
SUPIR aims at developing Practical Algorithms for Photo-Realistic Image Restoration In the Wild. Our new online demo is also released at suppixel.ai.
★ 5,703⑂ 480👁 64⑃ 12● 157▤ 0
+2
Daily
5,703
stars
480
forks
64
watchers
12
prs
157
issues
0
releases
README
(CVPR2024) Scaling Up to Excellence: Practicing Model Scaling for Photo-Realistic Image Restoration In the Wild
[Paper]   [Project Page]   [[Online App]](https://supir.suppixel.ai/home)
Fanghua, Yu, Jinjin Gu, Zheyuan Li, Jinfan Hu, Xiangtao Kong, Xintao Wang, Jingwen He, Yu Qiao, Chao Dong
Shenzhen Institute of Advanced Technology; Shanghai AI Laboratory; University of Sydney; The Hong Kong Polytechnic University; ARC Lab, Tencent PCG; The Chinese University of Hong Kong
---
🚀 We're thrilled to announce the official launch of SupPixel AI! Experience the next level of image processing and upscaling with our cutting-edge AI technology based on SUPIR. Explore now at suppixel.ai.
---
🔧 Dependencies and Installation
1. Clone repo
bash
git clone https://github.com/Fanghua-Yu/SUPIR.git
cd SUPIR
2. Install dependent packages
bash
conda create -n SUPIR python=3.8 -y
conda activate SUPIR
pip install --upgrade pip
pip install -r requirements.txt
3. Download Checkpoints
For users who can connect to huggingface, please setting LLAVA_CLIP_PATH, SDXL_CLIP1_PATH, SDXL_CLIP2_CKPT_PTH in CKPT_PTH.py as None. These CLIPs will be downloaded automatically.
Dependent Models
SDXL CLIP Encoder-1
SDXL CLIP Encoder-2
SDXL base 1.0_0.9vae
LLaVA CLIP
LLaVA v1.5 13B
(optional) Juggernaut-XL_v9_RunDiffusionPhoto_v2
Replacement of SDXL base 1.0_0.9vae for Photo Realistic
(optional) Juggernaut_RunDiffusionPhoto2_Lightning_4Steps
Distilling model used in SUPIR_v0_Juggernautv9_lightning.yaml
Models we provided:
SUPIR-v0Q: Baidu Netdisk, Google Drive
Default training settings with paper. High generalization and high image quality in most cases.
SUPIR-v0F: Baidu Netdisk, Google Drive
Training with light degradation settings. Stage1 encoder of SUPIR-v0F remains more details when facing light degradations.
4. Edit Custom Path for Checkpoints
[CKPT_PTH.py] -- LLAVA_CLIP_PATH, LLAVA_MODEL_PATH, SDXL_CLIP1_PATH, SDXL_CLIP2_CACHE_DIR
[options/SUPIR_v0.yaml] -- SDXL_CKPT, SUPIR_CKPT_Q, SUPIR_CKPT_F
---
⚡ Quick Inference
Val Dataset
RealPhoto60: Baidu Netdisk, Google Drive
Usage of SUPIR
Shell
Usage:
-- python test.py [options]
-- python gradio_demo.py [interactive options]
--img_dir Input folder.
--save_dir Output folder.
--upscale Upsampling ratio of given inputs. Default: 1
--SUPIR_sign Model selection. Default: 'Q'; Options: ['F', 'Q']
--seed Random seed. Default: 1234
--min_size Minimum resolution of output images. Default: 1024
--edm_steps Numb of steps for EDM Sampling Scheduler. Default: 50
--s_stage1 Control Strength of Stage1. Default: -1 (negative means invalid)
--s_churn Original hy-param of EDM. Default: 5
--s_noise Original hy-param of EDM. Default: 1.01
--s_cfg Classifier-free Top issues
#42Report good images and images to be improved. 【报告优秀和待改进的图像】51 comments · 2024-02-28#45Using other SDXL turbo models to optimize the generation speed13 comments · 2024-02-28#67It's not working with Pinokio8 comments · 2024-03-06#41Any chance that this will work in comfyui?10 comments · 2024-02-28#28Possibility of decreasing VRAM usage?10 comments · 2024-02-26#20Can not run code. Ubuntu freezes, then execution of code killed. Please advice?10 comments · 2024-02-23#9The SUPIR model release. [SUPIR 开源的计划安排]10 comments · 2024-02-04#155New version soon? Support for more samplers?9 comments · 2025-01-09