<!-- examples/README-videomamba.md -->

# VideoMamba arithmetic reference

Run `python3 examples/videomamba.py --smoke` from the repository root, or
`python3 videomamba.py --smoke` beside the downloaded file. Python 3.10+ is
sufficient; no packages, checkpoints, video files, network, or GPU are needed.
The command checks deterministic invariants and prints sorted JSON.

The five marked regions count valid Conv3d tubelets, compare scan orders,
align scalar forward/backward recurrences, compute normalized feature distance,
and count adjacency preserved by authored masking fixtures. The bidirectional
example ties direction parameters for clarity. Upstream learns separate direction
parameters and also uses input projections, convolution, selective coefficients,
gating, output projection, normalization, residuals, and trained classification.
The 50% mask fixtures illustrate adjacency; they do not implement the paper's
attention mask sampler or its preferred 80% masked pretraining setting.

Reference paper: https://arxiv.org/abs/2403.06977v2
Official code revision: 37355c26d0ae99ca2459f6d4044a5f509031a79f
https://github.com/OpenGVLab/VideoMamba/tree/37355c26d0ae99ca2459f6d4044a5f509031a79f

No training, accuracy reproduction, autograd, or runtime benchmarking is performed.
The source regions are the canonical inputs to the website's code panels.
