Added super-resolution using GFPGAN and CodeFormer#117
Conversation
|
Good work! 👍 |
|
I think some more changes are needed in this PR, as running gradio_app.py won't work anymore. Also, what codeformer package are you using for Python? None has the CodeFormerRestorer class as used in code. And GFPGAN 1.3.0 throws some errors due to conflicts with other dependencies; as a workaround, a version that worked for me was installing via EDIT: this is just an AI hallucinating. Probably the author of the PR didn't even test it, as it doesn't work. |
|
Is implementing Codeformer in the roadmap @chunyu-li ? |
|
why don't you use gfpganv1.4? it can be download from: https://github.com/TencentARC/GFPGAN/releases/download/v1.3.0/GFPGANv1.4.pth |
Enhanced Pipeline with Super-Resolution
How to Run
Set up the environment:
Download the required checkpoints:
GFPGAN: GFPGANv1.3.pth
CodeFormer: codeformer.pth
Place the checkpoints in the checkpoints/ directory.
bash inference.sh --superres [GFPGAN/CodeFormer]
** Summary of Changes**
Here’s a brief explanation of what changes I made to each file:
File:
latentsync/pipelines/lipsync_pipeline.pyapply_superresto apply GFPGAN or CodeFormer.__call__method to calculate the resolution ratio and apply super-resolution if necessary.File:
inference.py--superresto allow users to choose between GFPGAN and CodeFormer.File:
inference.sh--superresparameter.