Commit c3db3447 authored by comfyanonymous's avatar comfyanonymous
Browse files

Fix ConditioningZeroOut when there is no pooled output.

parent d1600738
...@@ -232,8 +232,9 @@ class ConditioningZeroOut: ...@@ -232,8 +232,9 @@ class ConditioningZeroOut:
c = [] c = []
for t in conditioning: for t in conditioning:
d = t[1].copy() d = t[1].copy()
if "pooled_output" in d: pooled_output = d.get("pooled_output", None)
d["pooled_output"] = torch.zeros_like(d["pooled_output"]) if pooled_output is not None:
d["pooled_output"] = torch.zeros_like(pooled_output)
n = [torch.zeros_like(t[0]), d] n = [torch.zeros_like(t[0]), d]
c.append(n) c.append(n)
return (c, ) return (c, )
......
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