aboutsummaryrefslogtreecommitdiff
path: root/modules/sd_models.py
diff options
context:
space:
mode:
authorAUTOMATIC <16777216c@gmail.com>2022-09-30 22:16:03 +0300
committerAUTOMATIC <16777216c@gmail.com>2022-09-30 22:16:03 +0300
commit2b03f0bbda1229dff6e7ab6f656b28587eba8308 (patch)
tree1884e07a560daf5dc10be0e7e0d8d3e08b8ce3ce /modules/sd_models.py
parent3a876b16a92a23e5536d828c9217fda998e5d9c1 (diff)
if --ckpt option is specified, load that model
Diffstat (limited to 'modules/sd_models.py')
-rw-r--r--modules/sd_models.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/sd_models.py b/modules/sd_models.py
index ab014efb..2539f14c 100644
--- a/modules/sd_models.py
+++ b/modules/sd_models.py
@@ -69,6 +69,7 @@ def list_models():
h = model_hash(cmd_ckpt)
title, short_model_name = modeltitle(cmd_ckpt, h)
checkpoints_list[title] = CheckpointInfo(cmd_ckpt, title, h, short_model_name)
+ shared.opts.sd_model_checkpoint = title
elif cmd_ckpt is not None and cmd_ckpt != shared.default_sd_model_file:
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: