Skip to content

Commit fb46d21

Browse files
committed
up more
1 parent 445cf58 commit fb46d21

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/diffusers/models/transformers/transformer_ltx.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,5 @@ def apply_rotary_emb(x, freqs):
508508
cos, sin = freqs
509509
x_real, x_imag = x.unflatten(2, (-1, 2)).unbind(-1) # [B, S, H, D // 2]
510510
x_rotated = torch.stack([-x_imag, x_real], dim=-1).flatten(2)
511-
# YiYi TODO: testing only, remove this change before merging
512-
out = (x * cos.to(x.dtype) + x_rotated * sin.to(x.dtype)).to(x.dtype)
511+
out = (x.float() * cos + x_rotated.float() * sin).to(x.dtype)
513512
return out

0 commit comments

Comments
 (0)