diff options
author | AUTOMATIC <16777216c@gmail.com> | 2023-01-28 13:23:49 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2023-01-28 13:23:49 +0000 |
commit | 5d14f282c2812888275902be4b552681f942dbfd (patch) | |
tree | cbe5bebb63ddd921879604b093f2c46e71d3a0a8 /modules/sd_models.py | |
parent | f8feeaaedb890de1e36eeb2ad387f0eb3abafd54 (diff) | |
download | stable-diffusion-webui-gfx803-5d14f282c2812888275902be4b552681f942dbfd.tar.gz stable-diffusion-webui-gfx803-5d14f282c2812888275902be4b552681f942dbfd.tar.bz2 stable-diffusion-webui-gfx803-5d14f282c2812888275902be4b552681f942dbfd.zip |
fixed a bug where after switching to a checkpoint with unknown hash, you'd get empty space instead of checkpoint name in UI
fixed a bug where if you update a selected checkpoint on disk and then restart the program, a different checkpoint loads, but the name is shown for the the old one.
Diffstat (limited to 'modules/sd_models.py')
-rw-r--r-- | modules/sd_models.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/modules/sd_models.py b/modules/sd_models.py index b2d48a51..c45ddf83 100644 --- a/modules/sd_models.py +++ b/modules/sd_models.py @@ -231,12 +231,10 @@ def get_checkpoint_state_dict(checkpoint_info: CheckpointInfo, timer): def load_model_weights(model, checkpoint_info: CheckpointInfo, state_dict, timer):
- title = checkpoint_info.title
sd_model_hash = checkpoint_info.calculate_shorthash()
timer.record("calculate hash")
- if checkpoint_info.title != title:
- shared.opts.data["sd_model_checkpoint"] = checkpoint_info.title
+ shared.opts.data["sd_model_checkpoint"] = checkpoint_info.title
if state_dict is None:
state_dict = get_checkpoint_state_dict(checkpoint_info, timer)
|