Skip to content

Commit 5725b50

Browse files
patrickvonplatensayakpaul
authored andcommitted
[Torch compile] Fix torch compile for controlnet (#4795)
Fix torch compile for controlnete
1 parent e3380c0 commit 5725b50

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/diffusers/models/controlnet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -723,7 +723,7 @@ def forward(
723723
class_emb = self.class_embedding(class_labels).to(dtype=self.dtype)
724724
emb = emb + class_emb
725725

726-
if "addition_embed_type" in self.config:
726+
if self.config.addition_embed_type is not None:
727727
if self.config.addition_embed_type == "text":
728728
aug_emb = self.add_embedding(encoder_hidden_states)
729729

0 commit comments

Comments
 (0)