Add EdgePad ONNX models and original model card
Browse filesFiles changed (5)
- LICENSE+23
- README.md+140-3
- zipdepth_edgepad_384.onnxAdded+3
- zipdepth_wide_512x288.onnxAdded+3
- zipdepth_wide_672x384.onnxAdded+3
1234567891011121314151617181920212223MIT LicenseCopyright (c) 2026 Fabio Tosi (ZipDepth, the weights these models derive from)Copyright (c) 2026 The Nightfall authors (the fine-tuned weights and theexported graphs)Permission is hereby granted, free of charge, to any person obtaining a copyof this software and associated documentation files (the "Software"), to dealin the Software without restriction, including without limitation the rightsto use, copy, modify, merge, publish, distribute, sublicense, and/or sellcopies of the Software, and to permit persons to whom the Software isfurnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in allcopies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS ORIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THEAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHERLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THESOFTWARE.
12345---license: otherlicense_name: mitlicense_link: LICENSE---123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142---license: mitpipeline_tag: depth-estimationtags:- depth-estimation- monocular-depth- zipdepth- edgepad- onnx---# EdgePad depth models (ZipDepth for mobile GPUs)This repository mirrors the **PC ONNX** EdgePad depth models published by the**Nightfall team**. The model research, fine-tuning, graph optimization, andexports were created by Nightfall and are credited to its authors and toFabio Tosi, the author of ZipDepth.The model-card text below is based closely on the original release notes,with only small changes to describe the files mirrored here.## About these modelsThe monocular depth models Nightfall uses for AI 3D are published for anyoneto use: TFLite for phones and headsets (Nightfall runs them on Quest), andONNX for PCs (Nightfall Meteor runs them there). They are MIT licensed; see[`LICENSE`](LICENSE).All of them are **EdgePad** builds of[ZipDepth](https://github.com/fabiotosi92/ZipDepth) by Fabio Tosi (MIT): a6.1M-parameter convolutional network distilled from Depth Anything V2 Large,with no attention or transformer operations, which is what allows it to runentirely on a mobile GPU. There are two generations:- **Square EdgePad** (shipped in Nightfall v0.7.x): ZipDepth's own Standardcheckpoint, **not retrained**, exported through exact graph rewrites so thewhole network runs on the GPU.- **Widescreen EdgePad** (Nightfall's next release): a light fine-tune of thesame checkpoint for 16:9 video and steadier depth from frame to frame,exported at exact 16:9 sizes.## Files in this mirror| File | Generation | Input | Output | SHA-256 || --- | --- | --- | --- | --- || `zipdepth_edgepad_384.onnx` | Square | 384x384 | 384x384 | `78efcf08caded436c626af0b7b5980db47bc07653ec549a59b7e48e73b3e035f` || `zipdepth_wide_512x288.onnx` | Widescreen | 512x288 | 512x288 | `197d598f50ee3270b12831096dbab260c6bd5979bab13b87f01a28fad0268274` || `zipdepth_wide_672x384.onnx` | Widescreen | 672x384 | 672x384 | `f812b10b10309c6759266cbe888fa9c0f70668350fdf69e7eda9cc0412ca1a21` |Sizes are width x height. These are the PC ONNX exports used by NightfallMeteor. This Hugging Face mirror currently contains the three ONNX files above;the original release also provides TFLite exports for mobile and headset use.## Using them- **Input:** RGB as float32 in 0 to 1 (`pixel / 255`). ImageNet mean andstandard deviation are applied inside the graph. The ONNX model takes NCHW`[1, 3, H, W]` named `image`. Resize the frame to the model input size;Nightfall uses an area filter.- **Output:** relative inverse depth: larger is nearer, with no fixed scale oroffset. Normalise each frame before use. Nightfall stretches between low andhigh percentiles and smooths the result over time. The ONNX models output thefull-size map, already unpacked and clamped.## Square EdgePad: optimisation onlyThe weights are ZipDepth's Standard checkpoint (`zipdepth_base.pth`), unchanged,including its learned convex reconstruction head, which proved essential forclean full-screen geometry in the headset. Every change in the Square EdgePadexport is to the graph and is mathematically exact:1. **Materialised attention broadcasts.** ZipDepth's strip, channel, andglobal-context attention broadcast small tensors across the feature map.These tensors are expanded before the operation for GPU-delegatecompatibility.2. **Small reductions.** Large spatial average pools are split into exact 2xand 3x stages.3. **Packed reconstruction head.** The head's 5-dimensional softmax anddepth-to-space tail becomes four ordinary 9-channel softmax branches, the36-channel mask convolution becomes four 9-channel convolutions, and theweighted sums become fixed 1x1 convolutions.4. **EdgePad.** The head's replicate padding is rebuilt from edge slices andconcatenation so the whole graph can run without splitting and copyingintermediate tensors back to the CPU.Against the original Standard graph, Nightfall reports correlation`0.9999999999999908` and normalised mean absolute error `3.6e-8`.## Widescreen EdgePad: a light fine-tuneOne checkpoint (SHA-256`2dc8fddcef9ef22f45b6a1573b9cf66de0f39b1b5172e4284dd693790bd6309e`)was trained from ZipDepth's Standard checkpoint in two short stages. Only thedecoder was trained: 154,005 of 6.1 million parameters. The encoder isZipDepth's.- **Stage 1** (5,000 steps): shapes alternated between 384x384, 256x256,224x224, and 512x288, so one set of weights serves every size. Training used2,000 frames from 25 videos: gameplay/YouTube, film, live-action/CG, andanimation. Labels were the original Square EdgePad-384 output, Video DepthAnything Small for frame-to-frame consistency, and Marigold V2 for spatialdetail on selected keyframes. A texture-leakage term at weight 0.5discourages copying image texture into depth.- **Stage 2** (1,000 steps at learning rate `5e-5`): decoder-only training forthe exact 16:9 sizes.The model has no memory and processes each frame independently; temporalbehaviour was learned only through the losses.Nightfall's held-out video results against the untouched ZipDepth export atthe same size:| Model | Compared with | Flicker on static scenes | Flow-warped error | Frame-to-frame change || --- | --- | --- | --- | --- || 512x288 | stock 512x288 | -8.6% | -5.8% | -8.4% || 320x180 | stock 224x224 | -42.4% | -43.9% | -39.2% |The trade-off is about 11% higher texture leakage than the stock 224x224 modelat 320x180. Nightfall notes that the 320x180 model is also visibly lessdetailed than the 384x384 model, as its size implies.Nightfall reports that the TFLite exports match their ONNX sources withcorrelation `0.99999` and pass LiteRT's GPU compatibility check withoutwarnings. Meteor's ONNX files are the same weights with the 2x2 unpacking andclamp added to the graph and the weights embedded. The 672x384 file is anexport of the same checkpoint at a larger size and was not part of theheld-out evaluation above.## Credits and licences- **ZipDepth:** Fabio Tosi, MIT. These models are derivatives of its weights;its copyright notice is retained in [`LICENSE`](LICENSE).- **Teacher models** used only to make training labels, not included here:Video Depth Anything Small (Apache-2.0) and Marigold V2 (Apache-2.0; builton Qwen-Image-Edit-2509, Apache-2.0).- **Fine-tuning, graph optimisation, and exports:** Nightfall's model researchteam. Sincere thanks to **tB0nE and all Nightfall contributors** for makingthese models and the detailed release notes available.This Hugging Face repository is a mirror provided for convenient access. Allcredit for the original models and release documentation belongs to theNightfall team and Fabio Tosi.
123version https://git-lfs.github.com/spec/v1oid sha256:78efcf08caded436c626af0b7b5980db47bc07653ec549a59b7e48e73b3e035fsize 24608261123version https://git-lfs.github.com/spec/v1oid sha256:197d598f50ee3270b12831096dbab260c6bd5979bab13b87f01a28fad0268274size 24625797123version https://git-lfs.github.com/spec/v1oid sha256:f812b10b10309c6759266cbe888fa9c0f70668350fdf69e7eda9cc0412ca1a21size 24624796LICENSE+23
README.md+140-3
zipdepth_edgepad_384.onnxAdded+3
zipdepth_wide_512x288.onnxAdded+3
zipdepth_wide_672x384.onnxAdded+3