depth-estimation 0.1.2__tar.gz → 0.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {depth_estimation-0.1.2/src/depth_estimation.egg-info → depth_estimation-0.1.3}/PKG-INFO +33 -8
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/README.md +32 -7
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/pyproject.toml +1 -1
- {depth_estimation-0.1.2 → depth_estimation-0.1.3/src/depth_estimation.egg-info}/PKG-INFO +33 -8
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/LICENSE +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/setup.cfg +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/cli.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/configuration_utils.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/base_dataset.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/diode.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/folder.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/hub.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/kitti.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/nyu_depth_v2.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/data/transforms.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/evaluate.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/metrics.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/profiling.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/export.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/losses.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/modeling_utils.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/auto/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/auto/modeling_auto.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/auto/processing_auto.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v1/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v1/configuration_depth_anything_v1.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v1/modeling_depth_anything_v1.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v2/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v2/configuration_depth_anything_v2.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v2/modeling_depth_anything_v2.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v3/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v3/configuration_depth_anything_v3.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_anything_v3/modeling_depth_anything_v3.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_pro/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_pro/configuration_depth_pro.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_pro/modeling_depth_pro.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/marigold_dc/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/marigold_dc/configuration_marigold_dc.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/marigold_dc/modeling_marigold_dc.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/midas/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/midas/configuration_midas.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/midas/modeling_midas.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/moge/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/moge/configuration_moge.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/moge/modeling_moge.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/omnivggt/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/omnivggt/configuration_omnivggt.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/omnivggt/modeling_omnivggt.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/pixel_perfect_depth/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/pixel_perfect_depth/configuration_ppd.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/pixel_perfect_depth/modeling_ppd.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/vggt/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/vggt/configuration_vggt.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/vggt/modeling_vggt.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/zoedepth/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/zoedepth/configuration_zoedepth.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/zoedepth/modeling_zoedepth.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/output.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pipeline_utils.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pipelines/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pipelines/depth_estimation.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/processing_utils.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pruning.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/quantization.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/registry.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/trainer.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/training_args.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/video.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/viz/__init__.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/viz/animate.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/viz/composite.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/viz/display.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/viz/error.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/SOURCES.txt +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/dependency_links.txt +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/entry_points.txt +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/requires.txt +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/top_level.txt +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_auto.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_cli.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_config.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_data.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_evaluation.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_export_onnx.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_inference_all_models.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_inference_image.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_losses.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_model.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_package.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_pipeline.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_processor.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_pruning.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_quantization.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_training.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_transforms.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_video.py +0 -0
- {depth_estimation-0.1.2 → depth_estimation-0.1.3}/tests/test_viz.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: depth_estimation
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.3
|
|
4
4
|
Summary: A Transformers-style Python library for monocular depth estimation — inference, evaluation, and fine-tuning
|
|
5
5
|
Author: shriarul5273
|
|
6
6
|
License-Expression: MIT
|
|
@@ -58,21 +58,41 @@ Dynamic: license-file
|
|
|
58
58
|
|
|
59
59
|
<h3 align="center">A unified Python library for monocular depth estimation</h3>
|
|
60
60
|
|
|
61
|
-
<h3 align="center">Inference · Video
|
|
61
|
+
<h3 align="center">Inference · Video · Training · Evaluation · ONNX Export · Pruning · Quantization</h3>
|
|
62
62
|
|
|
63
63
|
---
|
|
64
64
|
|
|
65
|
-
`depth_estimation` is
|
|
65
|
+
`depth_estimation` is a unified model framework for monocular depth estimation. It provides one consistent API across **12 model families and 28 variants**, so you can swap models, compare them, fine-tune them, and prepare them for deployment without rewriting your pipeline.
|
|
66
66
|
|
|
67
|
-
It covers the
|
|
67
|
+
It covers the workflow end-to-end: run inference with one line, process video, visualize results, evaluate standard benchmarks, fine-tune on custom depth data, optimize models, and export them to ONNX.
|
|
68
|
+
|
|
69
|
+
> **Latest release: v0.1.3 — Documentation Refresh.** It adds clearer installation paths, a documentation index, updated deployment guidance, and corrected ONNX verification dependencies. Read the [release notes](https://github.com/shriarul5273/depth_estimation/blob/main/docs/release_notes.md) or view the [GitHub release](https://github.com/shriarul5273/depth_estimation/releases/tag/v0.1.3).
|
|
68
70
|
|
|
69
71
|
## Installation
|
|
70
72
|
|
|
71
73
|
```bash
|
|
72
|
-
|
|
74
|
+
# Core library
|
|
75
|
+
pip install --upgrade depth-estimation
|
|
76
|
+
|
|
77
|
+
# ONNX export
|
|
78
|
+
pip install "depth-estimation[export]"
|
|
79
|
+
|
|
80
|
+
# Export verification and ONNX quantization
|
|
81
|
+
pip install "depth-estimation[export]" onnxruntime
|
|
73
82
|
```
|
|
74
83
|
|
|
75
|
-
See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for
|
|
84
|
+
Python 3.10–3.12 is supported. For GPU execution of exported models, replace `onnxruntime` with `onnxruntime-gpu`. See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for the complete dependency guide.
|
|
85
|
+
|
|
86
|
+
## Documentation
|
|
87
|
+
|
|
88
|
+
| Goal | Guide |
|
|
89
|
+
|---|---|
|
|
90
|
+
| Choose a model | [Models](https://github.com/shriarul5273/depth_estimation/blob/main/docs/models.md) |
|
|
91
|
+
| Run video or visualize results | [Video](https://github.com/shriarul5273/depth_estimation/blob/main/docs/video.md) · [Visualization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/viz.md) |
|
|
92
|
+
| Load data, evaluate, or fine-tune | [Data](https://github.com/shriarul5273/depth_estimation/blob/main/docs/data.md) · [Evaluation](https://github.com/shriarul5273/depth_estimation/blob/main/docs/evaluation.md) · [Training](https://github.com/shriarul5273/depth_estimation/blob/main/docs/training.md) |
|
|
93
|
+
| Prepare a model for deployment | [ONNX export](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) · [Pruning](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) · [Quantization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/quantization.md) |
|
|
94
|
+
| Use the command line | [CLI reference](https://github.com/shriarul5273/depth_estimation/blob/main/docs/cli.md) |
|
|
95
|
+
| Extend the library | [Adding a model](https://github.com/shriarul5273/depth_estimation/blob/main/docs/adding_a_model.md) |
|
|
76
96
|
|
|
77
97
|
---
|
|
78
98
|
|
|
@@ -119,7 +139,7 @@ depth-estimate predict image.jpg --model depth-anything-v2-vitb
|
|
|
119
139
|
Switch from Depth Anything to DepthPro to MoGe by changing a single string. Preprocessing, postprocessing, and output format are identical across all models.
|
|
120
140
|
|
|
121
141
|
**2. The full depth workflow in one place.**
|
|
122
|
-
Most libraries stop at inference. This one covers training, evaluation
|
|
142
|
+
Most libraries stop at inference. This one also covers video, training, benchmark evaluation, dataset loading, pruning, quantization, and ONNX export, so you don't have to stitch together separate tools.
|
|
123
143
|
|
|
124
144
|
**3. Modular, single-file model design.**
|
|
125
145
|
Each model lives in one self-contained file. No hidden abstractions. If you need to understand or modify a model, there's exactly one place to look. New models self-register — `AutoDepthModel` and `pipeline()` resolve them automatically.
|
|
@@ -127,6 +147,9 @@ Each model lives in one self-contained file. No hidden abstractions. If you need
|
|
|
127
147
|
**4. Designed for research.**
|
|
128
148
|
Trainable models with backbone freeze schedules, proper batch-level metric accumulation (no mean-of-means), and a `compare()` function that shows a formatted table across models.
|
|
129
149
|
|
|
150
|
+
**5. Built for reliable deployment.**
|
|
151
|
+
Export verification checks ONNX output against PyTorch, quantization verifies accuracy by default, and unsupported model paths fail early with actionable errors.
|
|
152
|
+
|
|
130
153
|
---
|
|
131
154
|
|
|
132
155
|
## Supported Models
|
|
@@ -320,7 +343,7 @@ export_onnx(model, "depth_anything_v2_vitb.onnx", input_size=518, verify=True)
|
|
|
320
343
|
depth-estimate export --model depth-anything-v2-vitb --output model.onnx --verify
|
|
321
344
|
```
|
|
322
345
|
|
|
323
|
-
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge
|
|
346
|
+
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge`, with model-specific limitations documented in the compatibility table. `zoedepth` and `marigold-dc` are **not exportable** because both wrap opaque external pipelines; `export_onnx()` fails early with a clear error. Export requires `pip install "depth-estimation[export]"`; using `verify=True` additionally requires `onnxruntime` or `onnxruntime-gpu`. See [docs/export.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) for the full supported-models table and GPU setup.
|
|
324
347
|
|
|
325
348
|
</details>
|
|
326
349
|
|
|
@@ -339,6 +362,8 @@ model.export_onnx("pruned.onnx", verify=True) # pruned models export like any o
|
|
|
339
362
|
|
|
340
363
|
Pure PyTorch (`torch.nn.utils.prune`) — no special hardware or SDK. See [docs/pruning.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) for prune-aware fine-tuning and what pruning does/doesn't buy you (it zeros weights, it doesn't shrink tensors).
|
|
341
364
|
|
|
365
|
+
For a complete prune → fine-tune → export → quantize workflow, see [`examples/optimize.py`](https://github.com/shriarul5273/depth_estimation/blob/main/examples/optimize.py).
|
|
366
|
+
|
|
342
367
|
</details>
|
|
343
368
|
|
|
344
369
|
<details>
|
|
@@ -11,21 +11,41 @@
|
|
|
11
11
|
|
|
12
12
|
<h3 align="center">A unified Python library for monocular depth estimation</h3>
|
|
13
13
|
|
|
14
|
-
<h3 align="center">Inference · Video
|
|
14
|
+
<h3 align="center">Inference · Video · Training · Evaluation · ONNX Export · Pruning · Quantization</h3>
|
|
15
15
|
|
|
16
16
|
---
|
|
17
17
|
|
|
18
|
-
`depth_estimation` is
|
|
18
|
+
`depth_estimation` is a unified model framework for monocular depth estimation. It provides one consistent API across **12 model families and 28 variants**, so you can swap models, compare them, fine-tune them, and prepare them for deployment without rewriting your pipeline.
|
|
19
19
|
|
|
20
|
-
It covers the
|
|
20
|
+
It covers the workflow end-to-end: run inference with one line, process video, visualize results, evaluate standard benchmarks, fine-tune on custom depth data, optimize models, and export them to ONNX.
|
|
21
|
+
|
|
22
|
+
> **Latest release: v0.1.3 — Documentation Refresh.** It adds clearer installation paths, a documentation index, updated deployment guidance, and corrected ONNX verification dependencies. Read the [release notes](https://github.com/shriarul5273/depth_estimation/blob/main/docs/release_notes.md) or view the [GitHub release](https://github.com/shriarul5273/depth_estimation/releases/tag/v0.1.3).
|
|
21
23
|
|
|
22
24
|
## Installation
|
|
23
25
|
|
|
24
26
|
```bash
|
|
25
|
-
|
|
27
|
+
# Core library
|
|
28
|
+
pip install --upgrade depth-estimation
|
|
29
|
+
|
|
30
|
+
# ONNX export
|
|
31
|
+
pip install "depth-estimation[export]"
|
|
32
|
+
|
|
33
|
+
# Export verification and ONNX quantization
|
|
34
|
+
pip install "depth-estimation[export]" onnxruntime
|
|
26
35
|
```
|
|
27
36
|
|
|
28
|
-
See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for
|
|
37
|
+
Python 3.10–3.12 is supported. For GPU execution of exported models, replace `onnxruntime` with `onnxruntime-gpu`. See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for the complete dependency guide.
|
|
38
|
+
|
|
39
|
+
## Documentation
|
|
40
|
+
|
|
41
|
+
| Goal | Guide |
|
|
42
|
+
|---|---|
|
|
43
|
+
| Choose a model | [Models](https://github.com/shriarul5273/depth_estimation/blob/main/docs/models.md) |
|
|
44
|
+
| Run video or visualize results | [Video](https://github.com/shriarul5273/depth_estimation/blob/main/docs/video.md) · [Visualization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/viz.md) |
|
|
45
|
+
| Load data, evaluate, or fine-tune | [Data](https://github.com/shriarul5273/depth_estimation/blob/main/docs/data.md) · [Evaluation](https://github.com/shriarul5273/depth_estimation/blob/main/docs/evaluation.md) · [Training](https://github.com/shriarul5273/depth_estimation/blob/main/docs/training.md) |
|
|
46
|
+
| Prepare a model for deployment | [ONNX export](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) · [Pruning](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) · [Quantization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/quantization.md) |
|
|
47
|
+
| Use the command line | [CLI reference](https://github.com/shriarul5273/depth_estimation/blob/main/docs/cli.md) |
|
|
48
|
+
| Extend the library | [Adding a model](https://github.com/shriarul5273/depth_estimation/blob/main/docs/adding_a_model.md) |
|
|
29
49
|
|
|
30
50
|
---
|
|
31
51
|
|
|
@@ -72,7 +92,7 @@ depth-estimate predict image.jpg --model depth-anything-v2-vitb
|
|
|
72
92
|
Switch from Depth Anything to DepthPro to MoGe by changing a single string. Preprocessing, postprocessing, and output format are identical across all models.
|
|
73
93
|
|
|
74
94
|
**2. The full depth workflow in one place.**
|
|
75
|
-
Most libraries stop at inference. This one covers training, evaluation
|
|
95
|
+
Most libraries stop at inference. This one also covers video, training, benchmark evaluation, dataset loading, pruning, quantization, and ONNX export, so you don't have to stitch together separate tools.
|
|
76
96
|
|
|
77
97
|
**3. Modular, single-file model design.**
|
|
78
98
|
Each model lives in one self-contained file. No hidden abstractions. If you need to understand or modify a model, there's exactly one place to look. New models self-register — `AutoDepthModel` and `pipeline()` resolve them automatically.
|
|
@@ -80,6 +100,9 @@ Each model lives in one self-contained file. No hidden abstractions. If you need
|
|
|
80
100
|
**4. Designed for research.**
|
|
81
101
|
Trainable models with backbone freeze schedules, proper batch-level metric accumulation (no mean-of-means), and a `compare()` function that shows a formatted table across models.
|
|
82
102
|
|
|
103
|
+
**5. Built for reliable deployment.**
|
|
104
|
+
Export verification checks ONNX output against PyTorch, quantization verifies accuracy by default, and unsupported model paths fail early with actionable errors.
|
|
105
|
+
|
|
83
106
|
---
|
|
84
107
|
|
|
85
108
|
## Supported Models
|
|
@@ -273,7 +296,7 @@ export_onnx(model, "depth_anything_v2_vitb.onnx", input_size=518, verify=True)
|
|
|
273
296
|
depth-estimate export --model depth-anything-v2-vitb --output model.onnx --verify
|
|
274
297
|
```
|
|
275
298
|
|
|
276
|
-
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge
|
|
299
|
+
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge`, with model-specific limitations documented in the compatibility table. `zoedepth` and `marigold-dc` are **not exportable** because both wrap opaque external pipelines; `export_onnx()` fails early with a clear error. Export requires `pip install "depth-estimation[export]"`; using `verify=True` additionally requires `onnxruntime` or `onnxruntime-gpu`. See [docs/export.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) for the full supported-models table and GPU setup.
|
|
277
300
|
|
|
278
301
|
</details>
|
|
279
302
|
|
|
@@ -292,6 +315,8 @@ model.export_onnx("pruned.onnx", verify=True) # pruned models export like any o
|
|
|
292
315
|
|
|
293
316
|
Pure PyTorch (`torch.nn.utils.prune`) — no special hardware or SDK. See [docs/pruning.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) for prune-aware fine-tuning and what pruning does/doesn't buy you (it zeros weights, it doesn't shrink tensors).
|
|
294
317
|
|
|
318
|
+
For a complete prune → fine-tune → export → quantize workflow, see [`examples/optimize.py`](https://github.com/shriarul5273/depth_estimation/blob/main/examples/optimize.py).
|
|
319
|
+
|
|
295
320
|
</details>
|
|
296
321
|
|
|
297
322
|
<details>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: depth_estimation
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.3
|
|
4
4
|
Summary: A Transformers-style Python library for monocular depth estimation — inference, evaluation, and fine-tuning
|
|
5
5
|
Author: shriarul5273
|
|
6
6
|
License-Expression: MIT
|
|
@@ -58,21 +58,41 @@ Dynamic: license-file
|
|
|
58
58
|
|
|
59
59
|
<h3 align="center">A unified Python library for monocular depth estimation</h3>
|
|
60
60
|
|
|
61
|
-
<h3 align="center">Inference · Video
|
|
61
|
+
<h3 align="center">Inference · Video · Training · Evaluation · ONNX Export · Pruning · Quantization</h3>
|
|
62
62
|
|
|
63
63
|
---
|
|
64
64
|
|
|
65
|
-
`depth_estimation` is
|
|
65
|
+
`depth_estimation` is a unified model framework for monocular depth estimation. It provides one consistent API across **12 model families and 28 variants**, so you can swap models, compare them, fine-tune them, and prepare them for deployment without rewriting your pipeline.
|
|
66
66
|
|
|
67
|
-
It covers the
|
|
67
|
+
It covers the workflow end-to-end: run inference with one line, process video, visualize results, evaluate standard benchmarks, fine-tune on custom depth data, optimize models, and export them to ONNX.
|
|
68
|
+
|
|
69
|
+
> **Latest release: v0.1.3 — Documentation Refresh.** It adds clearer installation paths, a documentation index, updated deployment guidance, and corrected ONNX verification dependencies. Read the [release notes](https://github.com/shriarul5273/depth_estimation/blob/main/docs/release_notes.md) or view the [GitHub release](https://github.com/shriarul5273/depth_estimation/releases/tag/v0.1.3).
|
|
68
70
|
|
|
69
71
|
## Installation
|
|
70
72
|
|
|
71
73
|
```bash
|
|
72
|
-
|
|
74
|
+
# Core library
|
|
75
|
+
pip install --upgrade depth-estimation
|
|
76
|
+
|
|
77
|
+
# ONNX export
|
|
78
|
+
pip install "depth-estimation[export]"
|
|
79
|
+
|
|
80
|
+
# Export verification and ONNX quantization
|
|
81
|
+
pip install "depth-estimation[export]" onnxruntime
|
|
73
82
|
```
|
|
74
83
|
|
|
75
|
-
See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for
|
|
84
|
+
Python 3.10–3.12 is supported. For GPU execution of exported models, replace `onnxruntime` with `onnxruntime-gpu`. See [docs/dependencies.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/dependencies.md) for the complete dependency guide.
|
|
85
|
+
|
|
86
|
+
## Documentation
|
|
87
|
+
|
|
88
|
+
| Goal | Guide |
|
|
89
|
+
|---|---|
|
|
90
|
+
| Choose a model | [Models](https://github.com/shriarul5273/depth_estimation/blob/main/docs/models.md) |
|
|
91
|
+
| Run video or visualize results | [Video](https://github.com/shriarul5273/depth_estimation/blob/main/docs/video.md) · [Visualization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/viz.md) |
|
|
92
|
+
| Load data, evaluate, or fine-tune | [Data](https://github.com/shriarul5273/depth_estimation/blob/main/docs/data.md) · [Evaluation](https://github.com/shriarul5273/depth_estimation/blob/main/docs/evaluation.md) · [Training](https://github.com/shriarul5273/depth_estimation/blob/main/docs/training.md) |
|
|
93
|
+
| Prepare a model for deployment | [ONNX export](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) · [Pruning](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) · [Quantization](https://github.com/shriarul5273/depth_estimation/blob/main/docs/quantization.md) |
|
|
94
|
+
| Use the command line | [CLI reference](https://github.com/shriarul5273/depth_estimation/blob/main/docs/cli.md) |
|
|
95
|
+
| Extend the library | [Adding a model](https://github.com/shriarul5273/depth_estimation/blob/main/docs/adding_a_model.md) |
|
|
76
96
|
|
|
77
97
|
---
|
|
78
98
|
|
|
@@ -119,7 +139,7 @@ depth-estimate predict image.jpg --model depth-anything-v2-vitb
|
|
|
119
139
|
Switch from Depth Anything to DepthPro to MoGe by changing a single string. Preprocessing, postprocessing, and output format are identical across all models.
|
|
120
140
|
|
|
121
141
|
**2. The full depth workflow in one place.**
|
|
122
|
-
Most libraries stop at inference. This one covers training, evaluation
|
|
142
|
+
Most libraries stop at inference. This one also covers video, training, benchmark evaluation, dataset loading, pruning, quantization, and ONNX export, so you don't have to stitch together separate tools.
|
|
123
143
|
|
|
124
144
|
**3. Modular, single-file model design.**
|
|
125
145
|
Each model lives in one self-contained file. No hidden abstractions. If you need to understand or modify a model, there's exactly one place to look. New models self-register — `AutoDepthModel` and `pipeline()` resolve them automatically.
|
|
@@ -127,6 +147,9 @@ Each model lives in one self-contained file. No hidden abstractions. If you need
|
|
|
127
147
|
**4. Designed for research.**
|
|
128
148
|
Trainable models with backbone freeze schedules, proper batch-level metric accumulation (no mean-of-means), and a `compare()` function that shows a formatted table across models.
|
|
129
149
|
|
|
150
|
+
**5. Built for reliable deployment.**
|
|
151
|
+
Export verification checks ONNX output against PyTorch, quantization verifies accuracy by default, and unsupported model paths fail early with actionable errors.
|
|
152
|
+
|
|
130
153
|
---
|
|
131
154
|
|
|
132
155
|
## Supported Models
|
|
@@ -320,7 +343,7 @@ export_onnx(model, "depth_anything_v2_vitb.onnx", input_size=518, verify=True)
|
|
|
320
343
|
depth-estimate export --model depth-anything-v2-vitb --output model.onnx --verify
|
|
321
344
|
```
|
|
322
345
|
|
|
323
|
-
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge
|
|
346
|
+
Verified working for `depth-anything-v1/v2/v3`, `depth-pro`, and `moge`, with model-specific limitations documented in the compatibility table. `zoedepth` and `marigold-dc` are **not exportable** because both wrap opaque external pipelines; `export_onnx()` fails early with a clear error. Export requires `pip install "depth-estimation[export]"`; using `verify=True` additionally requires `onnxruntime` or `onnxruntime-gpu`. See [docs/export.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/export.md) for the full supported-models table and GPU setup.
|
|
324
347
|
|
|
325
348
|
</details>
|
|
326
349
|
|
|
@@ -339,6 +362,8 @@ model.export_onnx("pruned.onnx", verify=True) # pruned models export like any o
|
|
|
339
362
|
|
|
340
363
|
Pure PyTorch (`torch.nn.utils.prune`) — no special hardware or SDK. See [docs/pruning.md](https://github.com/shriarul5273/depth_estimation/blob/main/docs/pruning.md) for prune-aware fine-tuning and what pruning does/doesn't buy you (it zeros weights, it doesn't shrink tensors).
|
|
341
364
|
|
|
365
|
+
For a complete prune → fine-tune → export → quantize workflow, see [`examples/optimize.py`](https://github.com/shriarul5273/depth_estimation/blob/main/examples/optimize.py).
|
|
366
|
+
|
|
342
367
|
</details>
|
|
343
368
|
|
|
344
369
|
<details>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/configuration_utils.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/__init__.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/evaluate.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/metrics.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/evaluation/profiling.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/auto/__init__.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/auto/modeling_auto.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/depth_pro/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/midas/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/moge/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/moge/modeling_moge.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/omnivggt/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/vggt/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/vggt/modeling_vggt.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/models/zoedepth/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pipelines/__init__.py
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation/pipelines/depth_estimation.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/entry_points.txt
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/requires.txt
RENAMED
|
File without changes
|
{depth_estimation-0.1.2 → depth_estimation-0.1.3}/src/depth_estimation.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|