> ## Documentation Index
> Fetch the complete documentation index at: https://docs.generalrobotics.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# zoedepth

> Estimate depth from single RGB image

Estimate depth from single RGB image.

## Parameters

<ParamField body="image_input" type="ImageInput" required>
  RGB image as file path, URL, PIL Image, or numpy array.
</ParamField>

<ParamField body="timeout" type="float | None">
  Optional timeout in seconds for the HTTP request.
</ParamField>

## Returns

np.ndarray: Depth map as numpy array (H, W) with dtype float32.
Values represent metric depth in meters.

## Example

```python theme={null}
from grid_cortex_client import CortexClient, ModelType
import numpy as np
from PIL import Image
client = CortexClient()
image = np.array(Image.open("cat.jpg"))
depth = client.run(ModelType.ZOEDEPTH, image_input=image)
print(depth.shape)  # (480, 640)
```

The server returns the depth map as `float16` on the wire; the client converts it to `float32`.

## Example Output

<img src="https://mintcdn.com/scaledfoundations/lgZgGQWKvUIw0C7n/assets/images/cortex/zoedepth-output.jpg?fit=max&auto=format&n=lgZgGQWKvUIw0C7n&q=85&s=dbd87a8ed7545ba071363256181075e8" alt="ZoeDepth input and depth map output" width="1136" height="552" data-path="assets/images/cortex/zoedepth-output.jpg" />

```python theme={null}
from grid_cortex_client import CortexClient
from PIL import Image

client = CortexClient()
image = Image.open("scene.jpg")  # 640x480 RGB
depth = client.run(model_id="zoedepth", image_input=image)

print(depth.shape, depth.dtype)
# (480, 640) float32

print(f"min={depth.min():.4f}, max={depth.max():.4f}, mean={depth.mean():.4f}")
# min=1.5889, max=10.2891, mean=4.6381  (meters)
```


## Related topics

- [zoedepth](/models/cortex/zoedepth.md)
- [GRID Cortex Client](/models/cortex.md)
- [AsyncCortexClient](/python-api/grid-cortex-client/asynccortexclient.md)
- [CortexClient](/python-api/grid-cortex-client/cortexclient.md)
- [CortexHubClient](/python-api/grid-cortex-client/cortexhubclient.md)
