Add better error message for common error. (#10846)

This commit is contained in:
comfyanonymous 2025-11-23 01:55:22 -08:00 committed by GitHub
parent d89c29f259
commit cbd68e3d58
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -413,7 +413,8 @@ class ControlNet(nn.Module):
out_middle = []
if self.num_classes is not None:
assert y.shape[0] == x.shape[0]
if y is None:
raise ValueError("y is None, did you try using a controlnet for SDXL on SD1?")
emb = emb + self.label_emb(y)
h = x