Commit 7ea6bb03 authored by comfyanonymous's avatar comfyanonymous
Browse files

Print warning when controlnet can't be applied instead of crashing.

parent dcec1047
......@@ -255,7 +255,10 @@ def apply_control(h, control, name):
if control is not None and name in control and len(control[name]) > 0:
ctrl = control[name].pop()
if ctrl is not None:
h += ctrl
try:
h += ctrl
except:
print("warning control could not be applied", h.shape, ctrl.shape)
return h
class UNetModel(nn.Module):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment