Commit Graph

9 Commits

Author SHA1 Message Date
brkirch
bdaa36c844 When device is MPS, use CPU for GFPGAN instead
GFPGAN will not work if the device is MPS, so default to CPU instead.
2022-09-30 23:53:25 -04:00
AUTOMATIC
d1f098540a remove unwanted formatting/functionality from the PR 2022-09-30 11:42:40 +03:00
d8ahazard
0dce0df1ee Holy $hit.
Yep.

Fix gfpgan_model_arch requirement(s).
Add Upscaler base class, move from images.
Add a lot of methods to Upscaler.
Re-work all the child upscalers to be proper classes.
Add BSRGAN scaler.
Add ldsr_model_arch class, removing the dependency for another repo that just uses regular latent-diffusion stuff.
Add one universal method that will always find and load new upscaler models without having to add new "setup_model" calls. Still need to add command line params, but that could probably be automated.
Add a "self.scale" property to all Upscalers so the scalers themselves can do "things" in response to the requested upscaling size.
Ensure LDSR doesn't get stuck in a longer loop of "upscale/downscale/upscale" as we try to reach the target upscale size.
Add typehints for IDE sanity.
PEP-8 improvements.
Moar.
2022-09-29 17:46:23 -05:00
d8ahazard
740070ea9c Re-implement universal model loading 2022-09-26 09:29:50 -05:00
AUTOMATIC
d4205e66fa gfpgan: just download the damn model 2022-09-23 10:26:00 +03:00
AUTOMATIC
843b2b64fc Instance of CUDA out of memory on a low-res batch, even with --opt-split-attention-v1 (found cause) #255 2022-09-12 18:40:06 +03:00
AUTOMATIC
6a9b33c848 codeformer support 2022-09-07 12:32:28 +03:00
AUTOMATIC
595c827bd3 option to unload GFPGAN after using 2022-09-03 17:28:30 +03:00
AUTOMATIC
345028099d split codebase into multiple files; to anyone this affects negatively: sorry 2022-09-03 12:08:45 +03:00