
depth_anything_v1_vitl
Depth estimation180 ops318.7K params
A depth-estimation network that pairs a ViT-Large transformer encoder with a convolutional decoder.
Depth estimation · 180 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
How this diagram was made
menagerie.classics.depth_anything_dpt:build_vitl: build({}) DPT-Large is a dense prediction transformer (DPT): a network that makes a prediction for every pixel of an image, here a depth estimate from a single photo, with a transformer as the basic building block of its encoder. The paper's case for the design is that a transformer backbone processes representations at a constant and relatively high resolution and has a global receptive field at every stage.
In the paper, the ViT-Large encoder has 24 transformer layers, a patch size of 16 and a feature size of 1024. Tokens from layers 5, 12, 18 and 24 are reassembled into image-like feature maps at four resolutions. A convolutional decoder then combines consecutive stages with RefineNet-based fusion blocks, upsampling by a factor of two at each one, so the final representation has half the resolution of the input image.
For depth, the paper trains on a meta-dataset it calls MIX 6, which contains about 1.4 million images, using a scale- and shift-invariant trimmed loss on inverse depth. In zero-shot transfer to datasets not seen during training, the paper reports an average relative improvement over MiDaS, which it calls the best published architecture, of more than 23% for DPT-Hybrid and 28% for DPT-Large. It lists DPT-Large at 343 million parameters, about 3 times larger than MiDaS, and says its latency remains competitive because its wide and comparatively shallow structure allows a high degree of parallelism.
Key idea. DPT replaces the convolutional backbone of dense prediction networks with a vision transformer and reassembles its tokens into multi-resolution feature maps for a convolutional decoder.
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
@misc{ranftl2021visiontransformersdenseprediction,
title={Vision Transformers for Dense Prediction},
author={René Ranftl and Alexey Bochkovskiy and Vladlen Koltun},
year={2021},
eprint={2103.13413},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2103.13413},
}