[Mypy] Fix mypy typing for N/O models (#54142)

Signed-off-by: Taneem Ibrahim <taneem.ibrahim@gmail.com>
This commit is contained in:
Taneem Ibrahim
2026-09-18 12:50:01 +01:00
committed by GitHub
parent e562003adb
commit 2b8a5495a8
19 changed files with 321 additions and 143 deletions
@@ -222,12 +222,18 @@ class MambaStateShapeCalculator:
@classmethod
def append_replayssm_ring(
cls,
base_shapes: tuple[tuple[int, ...], ...],
base_shapes: tuple[tuple[int, int], tuple[int, int, int]],
n_groups: int,
tp_world_size: int,
logical_window: int,
backend: MambaBackendEnum,
) -> tuple[tuple[int, ...], ...]:
) -> tuple[
tuple[int, int],
tuple[int, int, int],
tuple[int, int, int],
tuple[int, int],
tuple[int, int, int],
]:
"""Append the physical ReplaySSM ring shapes.
``base_shapes[1]`` is ``(nheads // tp, head_dim, state_size)``;