mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-11 02:15:17 +00:00
"auto" type is only relevant to the SetUnionControlNetType node.
This commit is contained in:
parent
4151fbfa8a
commit
b2c995f623
@ -1,5 +1,4 @@
|
|||||||
UNION_CONTROLNET_TYPES = {
|
UNION_CONTROLNET_TYPES = {
|
||||||
"auto": -1,
|
|
||||||
"openpose": 0,
|
"openpose": 0,
|
||||||
"depth": 1,
|
"depth": 1,
|
||||||
"hed/pidi/scribble/ted": 2,
|
"hed/pidi/scribble/ted": 2,
|
||||||
|
@ -4,7 +4,7 @@ class SetUnionControlNetType:
|
|||||||
@classmethod
|
@classmethod
|
||||||
def INPUT_TYPES(s):
|
def INPUT_TYPES(s):
|
||||||
return {"required": {"control_net": ("CONTROL_NET", ),
|
return {"required": {"control_net": ("CONTROL_NET", ),
|
||||||
"type": (list(UNION_CONTROLNET_TYPES.keys()),)
|
"type": (["auto"] + list(UNION_CONTROLNET_TYPES.keys()),)
|
||||||
}}
|
}}
|
||||||
|
|
||||||
CATEGORY = "conditioning/controlnet"
|
CATEGORY = "conditioning/controlnet"
|
||||||
@ -14,7 +14,7 @@ class SetUnionControlNetType:
|
|||||||
|
|
||||||
def set_controlnet_type(self, control_net, type):
|
def set_controlnet_type(self, control_net, type):
|
||||||
control_net = control_net.copy()
|
control_net = control_net.copy()
|
||||||
type_number = UNION_CONTROLNET_TYPES[type]
|
type_number = UNION_CONTROLNET_TYPES.get(type, -1)
|
||||||
if type_number >= 0:
|
if type_number >= 0:
|
||||||
control_net.set_extra_arg("control_type", [type_number])
|
control_net.set_extra_arg("control_type", [type_number])
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user