diff options
author | yajun <yajun_zheng@qq.com> | 2023-08-23 06:31:38 +0000 |
---|---|---|
committer | yajun <yajun_zheng@qq.com> | 2023-08-23 06:31:38 +0000 |
commit | f29b4cd7cb4d59c8e4dcac1cebb63bfb5b884395 (patch) | |
tree | c7c7e8c2d65e3e809d2f0c4152a861a5645b44c5 /modules/realesrgan_model.py | |
parent | 68f336bd994bed5442ad95bad6b6ad5564a5409a (diff) | |
download | stable-diffusion-webui-gfx803-f29b4cd7cb4d59c8e4dcac1cebb63bfb5b884395.tar.gz stable-diffusion-webui-gfx803-f29b4cd7cb4d59c8e4dcac1cebb63bfb5b884395.tar.bz2 stable-diffusion-webui-gfx803-f29b4cd7cb4d59c8e4dcac1cebb63bfb5b884395.zip |
tell RealESRGANer which device to run on, could be cuda, M1, or other GPU
Diffstat (limited to 'modules/realesrgan_model.py')
-rw-r--r-- | modules/realesrgan_model.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/realesrgan_model.py b/modules/realesrgan_model.py index 0700b853..02841c30 100644 --- a/modules/realesrgan_model.py +++ b/modules/realesrgan_model.py @@ -55,6 +55,7 @@ class UpscalerRealESRGAN(Upscaler): half=not cmd_opts.no_half and not cmd_opts.upcast_sampling,
tile=opts.ESRGAN_tile,
tile_pad=opts.ESRGAN_tile_overlap,
+ device=self.device,
)
upsampled = upsampler.enhance(np.array(img), outscale=info.scale)[0]
|