This commit is contained in:
David 2025-11-06 03:04:50 +00:00 committed by GitHub
commit 08c28cca03
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -99,10 +99,10 @@ class ControlNet(nn.Module):
super().__init__()
assert use_spatial_transformer == True, "use_spatial_transformer has to be true"
if use_spatial_transformer:
assert context_dim is not None, 'Fool!! You forgot to include the dimension of your cross-attention conditioning...'
assert context_dim is not None,
if context_dim is not None:
assert use_spatial_transformer, 'Fool!! You forgot to use the spatial transformer for your cross-attention conditioning...'
assert use_spatial_transformer,
# from omegaconf.listconfig import ListConfig
# if type(context_dim) == ListConfig:
# context_dim = list(context_dim)