Fix from_vanilla call for ControlNetAdvanced so it does not break ComfyUI memory management system; parent model patcher has to be tracked properly now

This commit is contained in:
Jedrzej Kosinski
2024-11-14 11:49:56 -06:00
parent 7f84e973d6
commit b9c53b79c9
+1
View File
@@ -129,6 +129,7 @@ class ControlNetAdvanced(ControlNet, AdvancedControlBase):
global_average_pooling=v.global_average_pooling, compression_ratio=v.compression_ratio, latent_format=v.latent_format, load_device=v.load_device,
manual_cast_dtype=v.manual_cast_dtype)
v.copy_to(to_return)
to_return.control_model_wrapped = v.control_model_wrapped.clone()
return to_return