Fix some controlnet bug
This commit is contained in:
+1
-1
@@ -296,7 +296,7 @@ class applyKolorsUnet:
|
||||
|
||||
|
||||
def is_kolors_model(model):
|
||||
unet_config = model.model.model_config.unet_config
|
||||
unet_config = model.model.model_config.unet_config if hasattr(model, 'model') else None
|
||||
if unet_config and "adm_in_channels" in unet_config and unet_config["adm_in_channels"] == 5632:
|
||||
return True
|
||||
else:
|
||||
|
||||
@@ -23,7 +23,11 @@ class easyControlnet:
|
||||
control_net = patch_controlnet(model, control_net)
|
||||
else:
|
||||
if control_net is None:
|
||||
control_net = easyCache.load_controlnet(control_net_name, scale_soft_weights, use_cache)
|
||||
if easyCache is not None:
|
||||
control_net = easyCache.load_controlnet(control_net_name, scale_soft_weights, use_cache)
|
||||
else:
|
||||
controlnet_path = folder_paths.get_full_path("controlnet", control_net_name)
|
||||
control_net = comfy.controlnet.load_controlnet(controlnet_path)
|
||||
|
||||
# union controlnet
|
||||
if union_type is not None:
|
||||
|
||||
Reference in New Issue
Block a user