Instructions to use apple/DepthPro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Depth Pro
How to use apple/DepthPro with Depth Pro:
# Download checkpoint pip install huggingface_hub hf download apple/DepthPro --local-dir checkpoints
import depth_pro # Load model and preprocessing transform model, transform = depth_pro.create_model_and_transforms() model.eval() # Load and preprocess an image. image, _, f_px = depth_pro.load_rgb("example.png") image = transform(image) # Run inference. prediction = model.infer(image, f_px=f_px) # Results: 1. Depth in meters depth = prediction["depth"] # Results: 2. Focal length in pixels focallength_px = prediction["focallength_px"] - Notebooks
- Google Colab
- Kaggle
License clarification for the model weights: Apple Sample Code License (GitHub README) vs AMLR (this page), commercial use?
#13
by askiamohamed22 - opened
Hello,
The README of the GitHub repository apple-aiml-research/ml-depth-pro says the model weights are released under the terms of the repository's LICENSE (Apple Sample Code License). This page, and apple/DepthPro-hf and apple/DepthPro-mixin, show "License: apple-amlr", which restricts use to research purposes. The weights appear to be the same checkpoint.
Could you please clarify:
Which license applies to the released weights, including the copies on Hugging Face?
Is commercial use allowed (for example, running the model inside a paid software service)?
If the AMLR applies, is there a process to request a commercial license?
Thank you for your work and for any clarification.