diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-05-31 16:15:21 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-31 16:15:21 +0000 |
commit | 52b8752e6201e24c783f674f8dc0681027e10ea9 (patch) | |
tree | 30470f64d84cadc4140023c0bf34c35bb68f79b0 /modules/upscaler.py | |
parent | 00dfe27f59727407c5b408a80ff2a262934df495 (diff) | |
parent | 78a602ae8c006077ca93913576335a3a33dba7cb (diff) | |
download | stable-diffusion-webui-gfx803-52b8752e6201e24c783f674f8dc0681027e10ea9.tar.gz stable-diffusion-webui-gfx803-52b8752e6201e24c783f674f8dc0681027e10ea9.tar.bz2 stable-diffusion-webui-gfx803-52b8752e6201e24c783f674f8dc0681027e10ea9.zip |
Merge branch 'dev' into report-error
Diffstat (limited to 'modules/upscaler.py')
-rw-r--r-- | modules/upscaler.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/upscaler.py b/modules/upscaler.py index 7b1046d6..3c82861d 100644 --- a/modules/upscaler.py +++ b/modules/upscaler.py @@ -53,8 +53,8 @@ class Upscaler: def upscale(self, img: PIL.Image, scale, selected_model: str = None): self.scale = scale - dest_w = int(img.width * scale) - dest_h = int(img.height * scale) + dest_w = round((img.width * scale - 4) / 8) * 8 + dest_h = round((img.height * scale - 4) / 8) * 8 for _ in range(3): shape = (img.width, img.height) |