[V0 Deprecation] Remove unused context_len and seq_len from M-RoPE (#28395)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
This commit is contained in:
Cyrus Leung
2025-11-11 00:30:06 +08:00
committed by GitHub
parent f080a83511
commit d0e186c16f
13 changed files with 2 additions and 39 deletions

View File

@@ -927,8 +927,6 @@ class Qwen2_5OmniThinkerForConditionalGeneration(
image_grid_thw: list[list[int]] | torch.Tensor,
video_grid_thw: list[list[int]] | torch.Tensor,
second_per_grid_ts: list[float] | None = None,
context_len: int = 0,
seq_len: int | None = None,
audio_feature_lengths: torch.Tensor | None = None,
use_audio_in_video: bool = False,
) -> tuple[torch.Tensor, int]:
@@ -1125,7 +1123,6 @@ class Qwen2_5OmniThinkerForConditionalGeneration(
mrope_position_delta = (
torch.cat(llm_pos_ids_list, dim=1).max() + 1 - len(src_item)
)
llm_positions = llm_positions[:, context_len:seq_len]
return llm_positions, mrope_position_delta