Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
ComfyUI
Commits
b2c995f6
Commit
b2c995f6
authored
Jul 22, 2024
by
comfyanonymous
Browse files
"auto" type is only relevant to the SetUnionControlNetType node.
parent
4151fbfa
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
comfy/cldm/control_types.py
comfy/cldm/control_types.py
+0
-1
comfy_extras/nodes_controlnet.py
comfy_extras/nodes_controlnet.py
+2
-2
No files found.
comfy/cldm/control_types.py
View file @
b2c995f6
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
,
...
...
comfy_extras/nodes_controlnet.py
View file @
b2c995f6
...
@@ -4,7 +4,7 @@ class SetUnionControlNetType:
...
@@ -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:
...
@@ -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
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment