MVSAnywhere (fastforks)
MVSAnywhere (Izquierdo et al. 2025): zero-shot multi-view stereo, the depth of a reference view from posed, calibrated source views. A view-agnostic MLP cost volume (warped matching features + camera metadata, softmax over the views) is encoded by a DINOv2 ViT-B fused with a second DINOv2's image features and decoded by a DPT head; the depth range comes from the camera baselines and is refined once.
This repo is the model card only: it holds no weights. fastforks downloads the authors' weights from the links below and checks them against the SHA-256 in the model card. Code: https://github.com/kleinicke/fastforks. Kernels for the kernels backend: https://huggingface.co/fastforks/kernels. Original code: https://github.com/nianticlabs/mvsanywhere at 5bd49bb.
Task: multiview. Tier: stable. Outputs: depth, mask, sky, depth_range. Backends: portable, kernels.
Input: several images of one scene (posed and calibrated for multi-view stereo, unposed otherwise). Output: depth maps and, where the model predicts them, cameras and 3-D points.
Variants
Weights are the authors' files (not hosted here). SHA-256 shortened to 12 hex digits; the full hashes are in card.toml.
| variant | weights (author link) | SHA-256 | weights licence | commercial use |
|---|---|---|---|---|
mvsanywhere@1 |
mvsanywhere_hero.ckpt | 00878bab903b |
LicenseRef-noncommercial AND CC-BY-NC-SA-4.0 (assumed from code) | no |
Licence
Original-code strings, recorded as they are (research-use package; check them before any other use). Code: LicenseRef-noncommercial AND CC-BY-NC-SA-4.0. Files: LICENSE, LICENSE-antialiased-cnns.md.
Code licence: LicenseRef-noncommercial AND CC-BY-NC-SA-4.0; the authors do not state a separate weights licence.
Training data: Synthetic data per the paper (arXiv 2411.14390): Hypersim, TartanAir, BlendedMVG, MatrixCity, VKITTI2, Dynamic Replica, MVS-Synth, SAIL-VOS 3D; DINOv2 / Depth Anything V2 initialisation.
- Licence note: Niantic's non-commercial licence covers the code and the checkpoint; the BlurPool stem comes from Adobe's antialiased-cnns (CC-BY-NC-SA-4.0).
Licence evidence: https://github.com/nianticlabs/mvsanywhere/blob/5bd49bb/LICENSE and README.md (the checkpoint is published under the repository's licence)
Input size
any H x W >= 1, resized or padded inside the model
Tested up to (portable, fp16, RTX 5060 Ti 16 GB): mvsanywhere 3000x4000 (3.0 GiB peak allocated, 4.2 reserved)
Speed and memory
Multiview, synthetic
| model | input | time (ms): original fp32 | original | portable | kernels | kernels speed-up: vs original | vs portable | peak memory (MiB, allocated / reserved): original | portable | kernels |
|---|---|---|---|---|---|---|---|---|---|---|
mvsanywhere |
448x672 | 273 | 219 | 93.2 | 35.2 | 6.2x | 2.7x | 1504 / 1576 | 931 / 1226 | 702 / 760 |
Startup and first call
| model | load (s): original | portable | kernels | first call (s): original | portable | kernels |
|---|---|---|---|---|---|---|
mvsanywhere |
3.21 (448x672) | 1.88 (448x672) | 1.76 (448x672) | 1.04 (448x672) | 0.22 (448x672) | 0.48 (448x672) |
torch.compile and TensorRT
| model | input | time: portable | compile | TensorRT fp16 | kernels | preparation: compile (cold first call) | ONNX + engine build | peak MiB (alloc / reserved): portable | compile | kernels | TensorRT (engine + torch) |
|---|---|---|---|---|---|---|---|---|---|---|---|
mvsanywhere |
448x672 | 93.2 ms | 70.8 ms | planned for 0.2.1 | 35.2 ms | 153 s | β | 931 / 1226 | 818 / 860 | 702 / 760 | β |
Fixed-size speed and peak memory, all models
| model | mode | 480x640 | 720x1280 | 1080x1920 | 12 MP 3000x4000 |
|---|---|---|---|---|---|
mvsanywhere |
portable | 107.5 ms / 969 / 1500 | 75.8 ms / 954 / 1398 | 77.4 ms / 1166 / 1756 | 124.0 ms / 3110 / 4342 |
mvsanywhere |
kernels | 40.6 ms / 769 / 1006 | 31.0 ms / 838 / 1068 | 32.5 ms / 1049 / 1414 | 57.1 ms / 2908 / 4006 |
Fixed-size cells: time (ms) / peak allocated / peak reserved memory (MiB).
Hardware, protocol and caveats: benchmarks (RTX 5060 Ti 16 GB, sm_120). Original = the original code named above at the precision of portable (fp16, or (fp32) where fp16 is unsupported or not finite); original fp32 = its default fp32 run. Peak memory is the torch allocator's.
Accuracy
On public datasets
640x512 crops, the 7 most co-visible views as sources; GT = depth rendered from the structured-light points. AbsRel / delta1 over GT pixels, after per-image median scaling unless the model takes the cameras (calibrated MVS: cameras, error in mm; PatchMatchNet also the depth range 425-935 mm, MVSAnywhere its own range from the camera baselines). Original = the original code named under Details, same checkpoint and protocol.
| variant | dataset | original fp32 | original fp16 | portable | kernels | note |
|---|---|---|---|---|---|---|
mvsanywhere |
DTU scans 1, 9, 24, 33, 75, view 24 + 7 sources, AbsRel / delta1 % / MAE mm | 0.0077 / 99.82 / 5.57 | 0.0110 / 99.84 / 7.85 | 0.0078 / 99.82 / 5.60 | 0.0077 / 99.82 / 5.59 |
Measured on NVIDIA GeForce RTX 5060 Ti, torch 2.14.1+cu130, fastforks 555d7b79, 2026-11-06.
Parity with the original code
Every variant is checked against reference outputs of the original code at its pinned commit. CPU, float32: max |diff| <= 0.002 vs the original. GPU, float16 (the default), portable and kernels: mean |diff| <= 0.1 % and p99 <= 0.5 % of the reference's median |value| (absolute error of the output depth).
Usage
from fastforks import multiview
# non-commercial weights: run with FASTFORKS_NONCOMMERCIAL=1 in the environment
model = multiview.load("mvsanywhere") # mode="auto": the preferred backend from recorded measurements
result = model(["ref.jpg", "src1.jpg", "src2.jpg"], intrinsics=K, cam_to_world=c2w) # views[0] = reference
result.depth # [1, H, W] float32 tensor; K [N, 3, 3] pixels, c2w [N, 4, 4] OpenCV camera-to-world
result.backend # what ran, e.g. Backend(mode='portable', device='cuda:0', dtype='float16')
Install with pip install fastforks (see https://github.com/kleinicke/fastforks). Other variants: mvsanywhere.
Kernels backend
multiview.load("mvsanywhere", mode="kernels") runs our CUDA kernels (fastbb, igev, cutlass_conv, cudnn_hacc, mvsanywhere, dpt_fused). It needs a prebuilt kernel for your GPU architecture (downloaded from https://huggingface.co/fastforks/kernels on first use) and a recent NVIDIA driver; if there is none it raises BackendUnavailableError with the reason and never falls back silently. mode="auto" picks kernels when it can run and logs the choice.