reliquary-depth-anything-v2-small
Depth Anything V2 Small (ViT-S, ~25M params) ONNX export. Powers Reliquary's Heightmap Generator with relative depth estimation.
Source
ONNX re-export of the upstream model β original credits to the authors:
- Repo: https://github.com/DepthAnything/Depth-Anything-V2
- Paper: "Depth Anything V2" β Yang, Kang, Huang, Xu, Feng, Zhao, NeurIPS 2024. Project page: https://depth-anything-v2.github.io/
- Pretrained weights origin: HuggingFace
depth-anything/Depth-Anything-V2-Small
License
Inherited from upstream β the Small variant is explicitly Apache-2.0 in the Depth Anything V2 repo. Free for commercial and non-commercial use with attribution.
Usage in Reliquary
This model is consumed by Reliquary, a browser-based PBR texture editor. The ONNX file is loaded via ONNX Runtime Web in the browser β no Python or server-side inference.
- Runtime integration point:
src/lib/ai/depthAnything.ts (variant picker) - Input shape / format:
[N, 3, H, W]β RGB normalised. H, W must be multiples of 14 (ViT patch size). Reliquary pads input to the next multiple of 14 before feeding the session. - Output shape / format:
[N, 1, H, W]β relative (disparity-like) depth, larger = closer. Normalise per-image to[0, 1]for heightmap use.
Files
depth_anything_v2_small.onnxβ ONNX graph (1.0 MB)depth_anything_v2_small.onnx.dataβ external weights (94.4 MB, present because the model exceeds the ONNX protobuf size limit)README.mdβ this file
Disclaimer
This is a re-export from the original PyTorch checkpoint to a browser-deployable ONNX format with dynamic input axes. The model weights, architecture, and training methodology are entirely the work of the original authors cited above. This repo is a hosting convenience for Reliquary's browser-side ML β it does NOT modify the model.
For the full conversion pipeline (including version-compat shims for
PyTorch 2.6+, opset selection, dynamic-axes details), see Reliquary's
PYTHON_CONVERSIONS_GUIDE.md.
Model tree for Wszelkiebro/reliquary-depth-anything-v2-small
Base model
depth-anything/Depth-Anything-V2-Small