From e172564eeaa3e1d61319f94b31c82b1c98fe1dcb Mon Sep 17 00:00:00 2001 From: TTPlanetPig <152850462+TTPlanetPig@users.noreply.github.com> Date: Sat, 10 Aug 2024 01:40:05 +0800 Subject: [PATCH] Update controlnet.py to fix the default controlnet weight as constant (#4285) --- comfy/controlnet.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comfy/controlnet.py b/comfy/controlnet.py index 4e4638e3..3d17d2f3 100644 --- a/comfy/controlnet.py +++ b/comfy/controlnet.py @@ -423,7 +423,7 @@ def load_controlnet_hunyuandit(controlnet_data): latent_format = comfy.latent_formats.SDXL() extra_conds = ['text_embedding_mask', 'encoder_hidden_states_t5', 'text_embedding_mask_t5', 'image_meta_size', 'style', 'cos_cis_img', 'sin_cis_img'] - control = ControlNet(control_model, compression_ratio=1, latent_format=latent_format, load_device=load_device, manual_cast_dtype=manual_cast_dtype, extra_conds=extra_conds, strength_type=StrengthType.LINEAR_UP) + control = ControlNet(control_model, compression_ratio=1, latent_format=latent_format, load_device=load_device, manual_cast_dtype=manual_cast_dtype, extra_conds=extra_conds, strength_type=StrengthType.CONSTANT) return control def load_controlnet(ckpt_path, model=None):