NMRF
A stereo network from the CUHK T-Stone Robotics Institute that treats matching as Markov random field inference. Commercially usable.
Commercial use: yes.
| variant | input | backend | time (ms) | peak memory (MiB, allocated / reserved) |
|---|---|---|---|---|
nmrf-sceneflow | Middlebury 2014 half (994x1482) | original (fp32) original portable kernels portable + torch.compile TensorRT fp16 | 445 313 216 196 161 184 | 2300 / 2426 1656 / 2054 1510 / 1552 1022 / 1112 854 / 1104 826 (engine) |
Details
- Original code: https://github.com/aeolusguan/NMRF at
a50bd8f407ae - Code licence: MIT (permissive); files:
LICENSE - Weights licence: MIT (assumed from code)
- Licence evidence: https://github.com/aeolusguan/NMRF/blob/a50bd8f407ae481c38f95cf141e1b5256e962cb7/README.md#L103
- Training data: Freiburg SceneFlow (FlyingThings3D, Driving, Monkaa)
- Kernel libraries:
fastbb - Variants:
nmrf-sceneflow - Outputs: disparity
- Input size: any H x W >= 9, padded to a multiple of 8
- Tested up to (portable, fp16, RTX 5060 Ti 16 GB):
nmrf-sceneflow3000x4000 (11.0 GiB peak allocated, 13.3 reserved) nmrf-sceneflow994x1482, first call: portable + torch.compile 85 s (cold Inductor cache), TensorRT fp16 142 s (ONNX + engine).nmrf-scenefloworiginal 994x1482: torch.autocast(fp16) around the forwardnmrf-sceneflowload / first call: original 0.21 s / 0.766 s (375x1242), portable 0.1 s / 0.218† s, kernels 0.07† s / 0.197† s- † measured in the speed sweep after the portable load (or an earlier size) in the same process: file cache and kernels are warm, so the time is lower than a fresh start.
- Protocol, median of 5 after 3 warm-up, uint8 CUDA input (synthetic for bench_inputs sizes), card defaults; gc before each load; peak = max over the first call and the timed calls
Measured
Original = the original code named under Details, same checkpoint and protocol.
| variant | dataset | original fp32 | original fp16 | portable | kernels | note |
|---|---|---|---|---|---|---|
nmrf-sceneflow | ETH3D two-view train, bad > 1 px % / EPE | 3.78 / 0.311 | 3.81 / 0.312 | 3.81 / 0.311 | 3.81 / 0.311 | |
nmrf-sceneflow | Middlebury 2014 trainingH, bad > 2 px % / EPE | 13.36 / 2.920 | 13.35 / 2.914 | 13.35 / 2.915 | 13.35 / 2.915 |
Measured on NVIDIA GeForce RTX 5060 Ti, torch 2.14.1+cu130, fastforks 468fba10, 2026-11-05.
Parity
CPU, float32: max |diff| <= 0.05 vs the original. GPU, float16 (the default), portable and kernels: mean |diff| <= 0.05 px and p99 <= 0.5 px. On real pairs up to 720x1280 the limits are mean 0.1 / p99 1.5 (precision-sensitive there, see Limitations).
| variant | kernels error vs original, mean / p99 | GPU, torch | kernels used |
|---|---|---|---|
nmrf-sceneflow | 0.00236 / 0.03745 | RTX 5060 Ti, torch 2.14.1+cu130 | fastbb@7d058322634d:sm_120 |