Skip to content

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.

mp: Fix checkpoint saving (#12268)

rattusef73070ea422
diff --git a/comfy/model_patcher.py b/comfy/model_patcher.py
index cdf289395..d888dbcfb 100644
--- a/comfy/model_patcher.py
+++ b/comfy/model_patcher.py
@@ -1400,7 +1400,7 @@ class ModelPatcher:
continue
key = "diffusion_model." + k
unet_state_dict[k] = LazyCastingParam(self, key, comfy.utils.get_attr(self.model, key))
- return self.model.state_dict_for_saving(unet_state_dict)
+ return self.model.state_dict_for_saving(unet_state_dict, clip_state_dict=clip_state_dict, vae_state_dict=vae_state_dict, clip_vision_state_dict=clip_vision_state_dict)
def __del__(self):
self.unpin_all_weights()