nemo_automodel.components.models.kimi_linear.flops
nemo_automodel.components.models.kimi_linear.flops
Architecture FLOPs for Kimi Linear 48B A3B training.
Module Contents
Functions
API
Estimate training work for independent, fully supervised sequences.
Counts linear projections, active SwiGLU experts, routers, the LM head, causal MLA attention (using the conventional S2 / 2 approximation), KDA convolutions and the chunkwise delta-rule kernel. KDA’s forward kernel count per head is 6Sd2 + 3SCd + SC**2, with C=64. Forward plus backward is estimated as three times forward work (six times MACs). Norms, activations, embedding lookup, optimizer work and activation recomputation are excluded. Packed document boundaries are unavailable through this interface: seq_len is treated as one document, so packed MLA work is overestimated. This is an architecture estimate, not executed FLOPs.
Parameters:
Complete model configuration before pipeline partitioning.
Number of independent sequences in the global batch.
Tokens per sequence; defaults to max_position_embeddings.
Returns: float
Estimated forward and backward FLOPs across the global batch.