--- library_name: pytorch license: other tags: - android pipeline_tag: depth-estimation --- ![](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/web-assets/model_demo.png) # Depth-Anything: Optimized for Qualcomm Devices Depth Anything is designed for estimating depth at each point in an image. This is based on the implementation of Depth-Anything found [here](https://github.com/huggingface/transformers/tree/main/src/transformers/models/depth_anything). This repository contains pre-exported model files optimized for Qualcomm® devices. You can use the [Qualcomm® AI Hub Models](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/depth_anything) library to export with custom configurations. More details on model performance across various devices, can be found [here](#performance-summary). Qualcomm AI Hub Models uses [Qualcomm AI Hub Workbench](https://workbench.aihub.qualcomm.com) to compile, profile, and evaluate this model. [Sign up](https://myaccount.qualcomm.com/signup) to run these models on a hosted Qualcomm® device. ## Getting Started There are two ways to deploy this model on your device: ### Option 1: Download Pre-Exported Models Below are pre-exported model assets ready for deployment. | Runtime | Precision | Chipset | SDK Versions | Download | |---|---|---|---|---| | ONNX | float | Universal | QAIRT 2.45, ONNX Runtime 1.27.1 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/releases/v0.59.0/depth_anything-onnx-float.zip) | ONNX | w8a16 | Universal | QAIRT 2.45, ONNX Runtime 1.27.1 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/releases/v0.59.0/depth_anything-onnx-w8a16.zip) | QNN_DLC | float | Universal | QAIRT 2.45 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/releases/v0.59.0/depth_anything-qnn_dlc-float.zip) | QNN_DLC | w8a16 | Universal | QAIRT 2.45 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/releases/v0.59.0/depth_anything-qnn_dlc-w8a16.zip) | TFLITE | float | Universal | QAIRT 2.45 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/depth_anything/releases/v0.59.0/depth_anything-tflite-float.zip) For more device-specific assets and performance metrics, visit **[Depth-Anything on Qualcomm® AI Hub](https://aihub.qualcomm.com/models/depth_anything)**. ### Option 2: Export with Custom Configurations Use the [Qualcomm® AI Hub Models](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/depth_anything) Python library to compile and export the model with your own: - Custom weights (e.g., fine-tuned checkpoints) - Custom input shapes - Target device and runtime configurations This option is ideal if you need to customize the model beyond the default configuration provided here. See our repository for [Depth-Anything on GitHub](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/depth_anything) for usage instructions. ## Model Details **Model Type:** Model_use_case.depth_estimation **Model Stats:** - Model checkpoint: DepthAnything_Small - Input resolution: 518x518 - Number of parameters: 24.7M - Model size (float): 94.3 MB ## Performance Summary | Model | Runtime | Precision | Chipset | Inference Time (ms) | Peak Memory Range (MB) | Primary Compute Unit |---|---|---|---|---|---|--- | Depth-Anything | ONNX | float | Snapdragon® X2 Elite | 19.086 ms | 5 - 5 MB | NPU | Depth-Anything | ONNX | float | Snapdragon® X Elite | 49.118 ms | 48 - 48 MB | NPU | Depth-Anything | ONNX | float | Snapdragon® 8 Gen 3 Mobile | 35.642 ms | 0 - 469 MB | NPU | Depth-Anything | ONNX | float | Snapdragon® 8 Gen 1 Mobile | 86.214 ms | 3 - 480 MB | NPU | Depth-Anything | ONNX | float | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 47.425 ms | 0 - 55 MB | NPU | Depth-Anything | ONNX | float | Qualcomm® QCS8450 | 86.214 ms | 3 - 480 MB | NPU | Depth-Anything | ONNX | float | Qualcomm® Dragonwing™ IQ-9075 | 55.351 ms | 3 - 9 MB | NPU | Depth-Anything | ONNX | float | Qualcomm® Dragonwing™ IQ-X7181 | 49.118 ms | 48 - 48 MB | NPU | Depth-Anything | ONNX | float | Qualcomm® Dragonwing™ Q-8750 | 24.427 ms | 2 - 366 MB | NPU | Depth-Anything | ONNX | float | Snapdragon® 8 Elite Mobile | 24.427 ms | 2 - 366 MB | NPU | Depth-Anything | ONNX | float | Snapdragon® 8 Elite Gen 5 Mobile | 18.494 ms | 2 - 370 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® X2 Elite | 12.149 ms | 4 - 4 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® X Elite | 27.706 ms | 27 - 27 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® 8 Gen 3 Mobile | 18.986 ms | 3 - 513 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® 8 Gen 1 Mobile | 39.084 ms | 3 - 513 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® Dragonwing™ QCS6490 | 107.209 ms | 2 - 5 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 27.105 ms | 0 - 34 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® QCS8450 | 39.084 ms | 3 - 513 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® Dragonwing™ IQ-9075 | 27.906 ms | 2 - 5 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® Dragonwing™ IQ-X7181 | 27.706 ms | 27 - 27 MB | NPU | Depth-Anything | ONNX | w8a16 | Qualcomm® Dragonwing™ Q-8750 | 14.139 ms | 3 - 420 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® 8 Elite Mobile | 14.139 ms | 3 - 420 MB | NPU | Depth-Anything | ONNX | w8a16 | Snapdragon® 8 Elite Gen 5 Mobile | 11.582 ms | 1 - 426 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® X2 Elite | 20.128 ms | 3 - 3 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® X Elite | 51.263 ms | 3 - 3 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® 8 Gen 3 Mobile | 38.593 ms | 2 - 510 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® 8 Gen 1 Mobile | 92.024 ms | 3 - 485 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® Dragonwing™ QCS8275 | 142.253 ms | 1 - 388 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 50.965 ms | 3 - 6 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® SA8775P | 56.655 ms | 1 - 372 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® SA8650P | 56.655 ms | 1 - 372 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® SA8255P | 56.655 ms | 1 - 372 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® QCS8450 | 92.024 ms | 3 - 485 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® Dragonwing™ IQ-9075 | 56.952 ms | 3 - 9 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® Dragonwing™ IQ-X7181 | 51.263 ms | 3 - 3 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® Dragonwing™ Q-8750 | 24.77 ms | 3 - 386 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® SA7255P | 142.253 ms | 1 - 388 MB | NPU | Depth-Anything | QNN_DLC | float | Qualcomm® SA8295P | 82.581 ms | 0 - 363 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® 8 Elite Mobile | 24.77 ms | 3 - 386 MB | NPU | Depth-Anything | QNN_DLC | float | Snapdragon® 8 Elite Gen 5 Mobile | 19.692 ms | 3 - 384 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Snapdragon® X2 Elite | 70.118 ms | 2 - 2 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Snapdragon® X Elite | 137.8 ms | 2 - 2 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Snapdragon® 8 Gen 3 Mobile | 113.136 ms | 0 - 2299 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® Dragonwing™ QCS8275 | 258.781 ms | 2 - 2002 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 160.356 ms | 2 - 4 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® SA8775P | 141.295 ms | 2 - 2000 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® SA8650P | 141.295 ms | 2 - 2000 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® SA8255P | 141.295 ms | 2 - 2000 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® Dragonwing™ IQ-9075 | 136.754 ms | 1 - 5 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® Dragonwing™ IQ-X7181 | 137.8 ms | 2 - 2 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® Dragonwing™ Q-8750 | 93.522 ms | 2 - 2015 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Qualcomm® SA7255P | 258.781 ms | 2 - 2002 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Snapdragon® 8 Elite Mobile | 93.522 ms | 2 - 2015 MB | NPU | Depth-Anything | QNN_DLC | w8a16 | Snapdragon® 8 Elite Gen 5 Mobile | 81.583 ms | 2 - 2016 MB | NPU | Depth-Anything | TFLITE | float | Snapdragon® 8 Gen 3 Mobile | 38.779 ms | 1 - 518 MB | NPU | Depth-Anything | TFLITE | float | Snapdragon® 8 Gen 1 Mobile | 92.599 ms | 2 - 491 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® Dragonwing™ QCS8275 | 142.42 ms | 1 - 396 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 51.5 ms | 1 - 6 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® SA8775P | 57.021 ms | 1 - 395 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® SA8650P | 57.021 ms | 1 - 395 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® SA8255P | 57.021 ms | 1 - 395 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® QCS8450 | 92.599 ms | 2 - 491 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® Dragonwing™ IQ-9075 | 64.611 ms | 1 - 58 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® Dragonwing™ Q-8750 | 24.685 ms | 1 - 395 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® SA7255P | 142.42 ms | 1 - 396 MB | NPU | Depth-Anything | TFLITE | float | Qualcomm® SA8295P | 82.521 ms | 1 - 370 MB | NPU | Depth-Anything | TFLITE | float | Snapdragon® 8 Elite Mobile | 24.685 ms | 1 - 395 MB | NPU | Depth-Anything | TFLITE | float | Snapdragon® 8 Elite Gen 5 Mobile | 19.687 ms | 0 - 390 MB | NPU ## License * The license for the original implementation of Depth-Anything can be found [here](https://github.com/huggingface/transformers/blob/main/LICENSE). ## References * [Depth Anything: Unleashing the Power of Large-Scale Unlabeled Data](https://arxiv.org/abs/2401.10891) * [Source Model Implementation](https://github.com/huggingface/transformers/tree/main/src/transformers/models/depth_anything) ## Community * Join [our AI Hub Slack community](https://aihub.qualcomm.com/community/slack) to collaborate, post questions and learn more about on-device AI. * For questions or feedback please [reach out to us](mailto:ai-hub-support@qti.qualcomm.com).