Skip to content

Commit

Permalink
add restoreformer and codeformer inference codes
Browse files Browse the repository at this point in the history
  • Loading branch information
xinntao committed Sep 12, 2022
1 parent 8d2447a commit 126c55c
Show file tree
Hide file tree
Showing 8 changed files with 1,655 additions and 9 deletions.
4 changes: 3 additions & 1 deletion README.md
Expand Up @@ -35,7 +35,9 @@ It leverages rich and diverse priors encapsulated in a pretrained face GAN (*e.g

:triangular_flag_on_post: **Updates**

- :fire::fire::white_check_mark: Add **[V1.3 model](https://github.com/TencentARC/GFPGAN/releases/download/v1.3.0/GFPGANv1.3.pth)**, which produces **more natural** restoration results, and better results on *very low-quality* / *high-quality* inputs. See more in [Model zoo](#european_castle-model-zoo), [Comparisons.md](Comparisons.md)
- :white_check_mark: Add CodeFormer ([CC BY-NC-SA 4.0 License](https://creativecommons.org/licenses/by-nc-sa/4.0/)) and RestoreFormer.
- :white_check_mark: Add [V1.4 model](https://github.com/TencentARC/GFPGAN/releases/download/v1.3.0/GFPGANv1.4.pth), which produces slightly more details and better identity than V1.3.
- :white_check_mark: Add **[V1.3 model](https://github.com/TencentARC/GFPGAN/releases/download/v1.3.0/GFPGANv1.3.pth)**, which produces **more natural** restoration results, and better results on *very low-quality* / *high-quality* inputs. See more in [Model zoo](#european_castle-model-zoo), [Comparisons.md](Comparisons.md)
- :white_check_mark: Integrated to [Huggingface Spaces](https://huggingface.co/spaces) with [Gradio](https://github.com/gradio-app/gradio). See [Gradio Web Demo](https://huggingface.co/spaces/akhaliq/GFPGAN).
- :white_check_mark: Support enhancing non-face regions (background) with [Real-ESRGAN](https://github.com/xinntao/Real-ESRGAN).
- :white_check_mark: We provide a *clean* version of GFPGAN, which does not require CUDA extensions.
Expand Down

4 comments on commit 126c55c

@sudharshan6167
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PS V:\GFPGAN> python.exe .\inference_gfpgan.py

V:\GFPGAN\inference_gfpgan.py:64: UserWarning: Here is going to run --bg_upsampler-realesrgan in CPU (not CUDA) power.

warnings.warn('Here is going to run --bg_upsampler-realesrgan in CPU (not CUDA) power.') V:\GFPGAN\inference_gfpgan.py:67: UserWarning: This is because installed version of PyTorch is 1.13.0+cpu'.

warnings.warn('This is because installed version of V:\GFPGAN\inference_gfpgan.py:69: UserWarning: If PyTorch has Compute Platform 'CUDA 11.6' support, the version will be

displayed like 1.12.1+cul16` warnings.warn('If PyTorch has Compute Platform CUDA 11.6' support,

V:\GFPGAN\inference_gfpgan.py:71: UserWarning: If you are sure to have CUDA enabled device, you can try to install CUDA capable PyTorch. Visit https://pytorch.org/get-started/locally/ and check START LOCALLY section. warnings.warn('If you are sure to have CUDA enabled device, '

V:\GFPGAN\inference_gfpgan.py:75: UserWarning: In 12 Nov 2022, this is useful to install CUDA powered PyTorch: pip3 inst all torch==1.12.1+cu116 --index-url https://download.pytorch.org/whl/cu116

warnings.warn('In 12 Nov 2022, this is useful to install CUDA powered PyTorch: V:\GFPGAN\inference_gfpgan.py:77: UserWarning: If you already have PyTorch installed, it needs to be uninstalled. try: p ip3 uninstall torch warnings.warn('If you already have PyTorch installed, it needs to be uninstalled. try:

V:\GFPGAN\inference_gfpgan.py:82: UserWarning: To print PyTorch version by yourself, try: python -c "import torch; print

(torch.version)"

warnings.warn('To print PyTorch version by yourself, try: V:\GFPGAN\inference_gfpgan.py:85: UserWarning: To verify if PyTorch can detect CUDA, try: python -c "import torch; print (torch.cuda.is_available())"

warnings.warn('To verify if PyTorch can detect CUDA, try:

V:\GFPGAN\inference_gfpgan.py:88: UserWarning: The unoptimized RealESRGAN is slow on CPU. We do not use it. If you reall y want to use it, please modify the corresponding codes.

warnings.warn('The unoptimized RealESRGAN is slow on CPU. We do not use it. '

C:\Users\DXT5\AppData\Roaming\Python\Python39\site-packages\torchvision\models_utils.py:208: UserWarning: The parameter 'pretrained' is deprecated since 0.13 and may be removed in the future, please use 'weights' instead. warnings.warn(

C:\Users\DXT5\AppData\Roaming\Python\Python39\site-packages\torchvision\models_utils.py:223: UserWarning: Arguments oth er than a weight enum or 'None' for 'weights' are deprecated since 0.13 and may be removed in the future. The current be havior is equivalent to passing weights=None'.

warnings.warn(msg)

Processing 00.jpg ...

@Sifatmm
Copy link

@Sifatmm Sifatmm commented on 126c55c Jul 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uploading 20230705_224459.jpg…

@Sifatmm
Copy link

@Sifatmm Sifatmm commented on 126c55c Jul 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

20230705_224523

@Ra84274
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PhotoRoom-20240125_063202

Please sign in to comment.