performance: use tiling for upscaling for better use of memory

pull/188/head
Bryce 2 years ago committed by Bryce Drennan
parent 5db67f9a0d
commit 00408d176f

@ -296,7 +296,7 @@ def imagine_cmd(
model_config_path,
prompt_library_path,
version, # noqa
make_gif
make_gif,
)

@ -17,7 +17,7 @@ def realesrgan_upsampler():
)
url = "https://github.com/xinntao/Real-ESRGAN/releases/download/v0.1.0/RealESRGAN_x4plus.pth"
model_path = get_cached_url_path(url)
upsampler = RealESRGANer(scale=4, model_path=model_path, model=model, tile=0)
upsampler = RealESRGANer(scale=4, model_path=model_path, model=model, tile=512)
device = get_device()
if "mps" in device:

Loading…
Cancel
Save