mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-12-15 06:41:00 -08:00
make it possible to use fractional values for SD upscale.
This commit is contained in:
parent
ef27a18b6b
commit
4dbde228ff
2 changed files with 4 additions and 4 deletions
|
|
@ -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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue