Add pydocstyle to the ruff rules (#52136)

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Signed-off-by: Harry Mellor <hej.mellor@gmail.com>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Harry Mellor
2026-09-16 16:44:29 +00:00
committed by GitHub
co-authored by Claude Opus 5
parent 804e5377aa
commit 8c1557a79c
2002 changed files with 15024 additions and 14269 deletions
+7 -2
View File
@@ -185,15 +185,20 @@ def triton_bf16_mla_sparse_interface(
d_v: int = 512,
block_dpe: int = 64,
) -> tuple[torch.Tensor, torch.Tensor, torch.Tensor]:
"""
out : [num_tokens, num_heads_q, d_v]
"""Out : [num_tokens, num_heads_q, d_v]
max_logits : [num_tokens, num_heads_q]
lse : logsumexp, [num_tokens, num_heads_q]
Args:
q: Query tensor, [num_tokens, num_heads_q, dim_qk].
kv: Latent KV cache tensor.
indices: Sparse KV indices selected for each query token.
sm_scale: Softmax scale applied to the QK product.
d_v: Size of the value dimension.
block_dpe: Size of positional embedding portion of dim_qk.
Set to 0 when q/kv contain only the nope latent (e.g. DSv4
prefill where RoPE is not split out).
"""
num_tokens, num_heads_q, dim_qk = q.shape
_, num_heads_kv, _ = kv.shape