mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-12-06 02:30:30 -08:00
Merge pull request #14216 from wfjsw/state-dict-ref-comparison
change state dict comparison to ref compare
This commit is contained in:
parent
f8871dedcf
commit
eb52c803b8
1 changed files with 1 additions and 1 deletions
|
|
@ -215,7 +215,7 @@ class LoadStateDictOnMeta(ReplaceHelper):
|
||||||
would be on the meta device.
|
would be on the meta device.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if state_dict == sd:
|
if state_dict is sd:
|
||||||
state_dict = {k: v.to(device="meta", dtype=v.dtype) for k, v in state_dict.items()}
|
state_dict = {k: v.to(device="meta", dtype=v.dtype) for k, v in state_dict.items()}
|
||||||
|
|
||||||
original(module, state_dict, strict=strict)
|
original(module, state_dict, strict=strict)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue