From 8f1b3153180da3b626529a7d077eac63d4b2e5e4 Mon Sep 17 00:00:00 2001 From: AUTOMATIC <16777216c@gmail.com> Date: Fri, 30 Sep 2022 09:46:52 +0300 Subject: [PATCH] fix bugs in the PR --- modules/sd_models.py | 2 +- modules/upscaler.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/sd_models.py b/modules/sd_models.py index 3f3f6b7c..4b9000a4 100644 --- a/modules/sd_models.py +++ b/modules/sd_models.py @@ -96,7 +96,7 @@ def list_models(): print(f"Checkpoint in --ckpt argument not found (Possible it was moved to {model_path}: {cmd_ckpt}", file=sys.stderr) for filename in model_list: h = model_hash(filename) - title = modeltitle(filename, h) + title, model_name = modeltitle(filename, h) checkpoints_list[title] = CheckpointInfo(filename, title, h, model_name) def get_closet_checkpoint_match(searchString): diff --git a/modules/upscaler.py b/modules/upscaler.py index d698282f..7b51844f 100644 --- a/modules/upscaler.py +++ b/modules/upscaler.py @@ -60,7 +60,7 @@ class Upscaler: break img = self.do_upscale(img, selected_model) if img.width != dest_w or img.height != dest_h: - img = img.resize(dest_w, dest_h, resample=LANCZOS) + img = img.resize((dest_w, dest_h), resample=LANCZOS) return img