Skip to content

Commit

Permalink
Fix to use SDPA instead of xformers
Browse files Browse the repository at this point in the history
  • Loading branch information
kohya-ss committed Oct 30, 2024
1 parent 8c3c825 commit 70a179e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/sd3_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,7 @@ def _forward(self, context, x, c):

if self.x_block.x_block_self_attn:
x_q2, x_k2, x_v2 = x_qkv2
attn2 = attention(x_q2, x_k2, x_v2, self.x_block.attn2.num_heads)
attn2 = attention(x_q2, x_k2, x_v2, self.x_block.attn2.num_heads, mode=self.mode)
x = self.x_block.post_attention_x(x_attn_out, attn2, *x_intermediates)
else:
x = self.x_block.post_attention(x_attn_out, *x_intermediates)
Expand Down

0 comments on commit 70a179e

Please sign in to comment.