ahrm / UnstableFusion

A Stable Diffusion desktop frontend with inpainting, img2img and more!
GNU General Public License v3.0
1.26k stars 84 forks source link

Added support for GFPGAN face restoration library. #37

Closed ZeroCool940711 closed 2 years ago

ZeroCool940711 commented 2 years ago

Added GFPGAN to restore faces, here is a quick comparison of the results with and without GFPGAN:

image image

I just used the reimagine button with GFPGAN and the result got a lot better, the face proportions got better and the eyes look a lot better as well

ahrm commented 2 years ago

Thanks. Please make this an optional feature so that people without GFPGAN are still able to run the program.

ZeroCool940711 commented 2 years ago

@ahrm I wanted to make it optional and have a checkbox on the GUI for it but I have no idea how to do it, I'm not good with Pyqt5, sorry I couldn't do it better, also, even those without gfpgan will still be able to run it, the first time the code runs it will download gfpgan from the URL I put in there which is from the official GitHub repo for GFPGAN and then it will place it on the root folder where the code is inside a folder called gfpgan.