aboutsummaryrefslogtreecommitdiff
path: root/modules/upscaler.py
diff options
context:
space:
mode:
authorPhilpax <me@philpax.me>2023-01-05 05:00:58 +0100
committerGitHub <noreply@github.com>2023-01-05 05:00:58 +0100
commit83ca8dd0c96e3cc8dd444e8d980c07718dc647ee (patch)
treecbadd09c9305099db7763532b7aaf909d366d326 /modules/upscaler.py
parentfa931733f6acc94e058a1d3d4655846e33ae34be (diff)
parent5f4fa942b8ec3ed3b15a352903489d6f9e6eb46e (diff)
Merge branch 'AUTOMATIC1111:master' into fix-sd-arch-switch-in-override-settings
Diffstat (limited to 'modules/upscaler.py')
-rw-r--r--modules/upscaler.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/upscaler.py b/modules/upscaler.py
index c4e6e6bd..231680cb 100644
--- a/modules/upscaler.py
+++ b/modules/upscaler.py
@@ -53,10 +53,10 @@ class Upscaler:
def do_upscale(self, img: PIL.Image, selected_model: str):
return img
- def upscale(self, img: PIL.Image, scale: int, selected_model: str = None):
+ def upscale(self, img: PIL.Image, scale, selected_model: str = None):
self.scale = scale
- dest_w = img.width * scale
- dest_h = img.height * scale
+ dest_w = int(img.width * scale)
+ dest_h = int(img.height * scale)
for i in range(3):
shape = (img.width, img.height)