Optional depth adapters

panorai.depth is a compatibility layer, not a bundled model collection. Importing it registers four loader names without importing Torch, Open3D, or an upstream implementation:

from panorai.depth import ModelRegistry

assert set(ModelRegistry.list_models()) == {
    "dav2", "m3dv2", "dust3r", "zoe"
}

The panorai[depth] extra installs common adapter dependencies only. Install the selected upstream project separately, pin its source/checkpoint for reproducibility, and review its terms before loading it.

Adapter boundary

Key

PanorAi loader

Upstream terms

Distribution behavior

dav2

load_dav2_model

Apache-2.0 code; weights may differ

Depth Anything V2 source and checkpoints are not bundled.

m3dv2

load_m3dv2_model

BSD-2-Clause code; check weights

Metric3D source, configs and checkpoints are not bundled.

dust3r

load_dust3r_model

CC BY-NC-SA 4.0

DUSt3R/CroCo are non-commercial/share-alike and never included in the MIT PanorAi artifacts.

zoe

load_zoe_model

Apache-2.0 code; check model card

The adapter uses a separately installed Transformers backend.

If an upstream import is unavailable or incompatible, the loader raises DepthAdapterUnavailableError with the upstream URL and license context. It never substitutes another model silently. PanorAi does not claim numerical equivalence until an exact upstream revision and checkpoint have independent integration evidence.

Deep 3.0 artifact paths below panorai.depth.DepthAnythingV2, panorai.depth.Dust3r, panorai.depth.Metric3D and panorai.depth.ZoeDepth_not_used, plus the research custom_data, trainers and training trees, were experimental/internal and have been removed from the source tree and release artifacts.

Lightweight compatibility adapters for optional depth models.

The upstream model implementations are not distributed by PanorAi 3.1. All loader names and registry keys remain discoverable without importing Torch, Open3D, or an upstream model package.

exception panorai.depth.DepthAdapterUnavailableError

An optional upstream depth implementation is unavailable or incompatible.

class panorai.depth.ModelRegistry

Discover and invoke optional depth adapters without importing backends.

classmethod get_config(name)

Return a copy of the adapter defaults.

classmethod get_loader(name)

Return the registered callable without invoking optional imports.

classmethod list_models()

Return registered adapter keys in deterministic order.

classmethod load(name, **overrides)

Load a model through its adapter using defaults plus overrides.

classmethod register(name, default_args=None)

Register one loader and a defensive copy of its default arguments.

panorai.depth.load_dav2_model(checkpoint_path=None, encoder='vits', dataset='vkitti', max_depth=80, device='mps', return_model=False)

Load a separately installed Depth Anything V2 implementation.

panorai.depth.load_dust3r_model(checkpoint_path='naver/DUSt3R_ViTLarge_BaseDecoder_512_dpt', device='mps', size=512, return_model=False, max_depth=80)

Load a separately installed DUSt3R implementation.

panorai.depth.load_m3dv2_model(backbone='ViT-Large', cfg_file=None, ckpt_file=None, device='mps')

Load a separately installed Metric3D implementation.

panorai.depth.load_zoe_model(return_model=False, **kwargs)

Load ZoeDepth through the separately installed Transformers backend.