Commit ffdbe98
committed
fix(ltx2): use actual video sequence length for dynamic timestep shift
calculate_shift() was being called with max_image_seq_len as its first
argument (image_seq_len), which collapses mu to a constant max_shift
regardless of resolution or frame count. With use_dynamic_shifting=True
this had no effect. Pass the sample's packed sequence length
(latent_num_frames * latent_height * latent_width) instead, matching the
Flux/SD3 pipelines and the LTX reference (math.prod(latent.shape[2:])).
Fixes #14243
Signed-off-by: Sergio Perez <sergio@checo.cc>1 parent 175fe6b commit ffdbe98
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1276 | 1276 | | |
1277 | 1277 | | |
1278 | 1278 | | |
1279 | | - | |
1280 | 1279 | | |
1281 | 1280 | | |
1282 | 1281 | | |
| |||
1332 | 1331 | | |
1333 | 1332 | | |
1334 | 1333 | | |
| 1334 | + | |
1335 | 1335 | | |
1336 | | - | |
| 1336 | + | |
1337 | 1337 | | |
1338 | 1338 | | |
1339 | 1339 | | |
| |||
0 commit comments