Numbers, all 60 000 samples
Lossless on every digit, every sample. Encode times measured native on a single thread; the browser demo runs the same encoder at ~8× the latency due to single-threaded WASM.
| Digit | Samples | Avg events | Ratio | Bits / event | Encode |
|---|---|---|---|---|---|
| 0 | 5,923 | 5,444 | 53.4× | 1.35 | 0.65 ms |
| 1 | 6,742 | 2,432 | 36.6× | 1.97 | 0.42 ms |
| 2 | 5,958 | 4,708 | 50.3× | 1.43 | 0.58 ms |
| 3 | 6,131 | 4,703 | 50.4× | 1.43 | 0.58 ms |
| 4 | 5,842 | 3,794 | 44.4× | 1.62 | 0.54 ms |
| 5 | 5,421 | 4,372 | 48.7× | 1.48 | 0.56 ms |
| 6 | 5,918 | 4,215 | 47.7× | 1.51 | 0.55 ms |
| 7 | 6,265 | 3,687 | 45.2× | 1.59 | 0.52 ms |
| 8 | 5,851 | 4,702 | 50.0× | 1.44 | 0.58 ms |
| 9 | 5,949 | 3,927 | 46.1× | 1.56 | 0.52 ms |
| Total | 60,000 | 4,172 | 47.6× | 1.51 | 0.55 ms |
N-MNIST in five minutes
Identical pipeline to the table above. The aggregate numbers are deterministic — repeated runs give bit-for-bit identical outputs.
# 1. Install pip install mfc-codec # 2. Get the N-MNIST training set (~290 MB) # https://www.garrickorchard.com/datasets/n-mnist mkdir -p data/nmnist && cd data/nmnist # unpack the 60,000-sample 'Train' folder here # 3. Run the bundled benchmark python -m mfc.examples.nmnist_bench --data data/nmnist/Train # expected (last line): # total=60000 ratio=47.6x bpe=1.51 encode=0.55ms lossless=true
Run on any modern CPU; the benchmark is single-threaded by design so
numbers compare directly to the paper. For DSEC (automotive 640×480),
use mfc.examples.dsec_load on a Zurich-city snippet — the
paper reports 9.2× / 7.85 bpe on a 500 000-event window.
Tested recordings
- N-MNIST — Orchard et al. — 60 000 samples, 34×34 sensor, all digits.
- DSEC (Zurich automotive) — 640×480 stereo event cameras, 500 000-event windows.
- MVSEC — planned for the next benchmark refresh.
- Synthetic — DVS128 through 1280×720 HD ranges, 100 k to 2 M events per frame, in the paper's Table 2.
Cite this work
@software{mfc_codec_2026,
author = {Solonskii, Aleksei},
title = {Mirror Fractal Codec: Lossless Compression for Neuromorphic Event Camera Streams},
year = {2026},
version = {0.3.29},
doi = {10.5281/zenodo.19704064},
url = {https://codec.mirrorfractal.com}
}
Working on a paper that uses MFC? Drop us a line at info@mirrorfractal.com — we keep an early-access channel for ongoing research and can answer property questions about the codec under the same terms as the paper.