> For the complete documentation index, see [llms.txt](https://docs.eyepop.ai/developer-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.eyepop.ai/developer-documentation/sdks/python.md).

# Python

Call EyePop from Python

The EyePop Python SDK calls the inference and data APIs from Python. Install it, set an API key, and run a Pop against an image, video, or stream.

```shell
pip install eyepop
```

Requires Python 3.12 or newer.

### Your first prediction

```python
from eyepop import EyePopSdk
from eyepop.worker.worker_types import InferenceComponent, Pop

pop = Pop(components=[
    InferenceComponent(ability="eyepop.person:latest")
])

with EyePopSdk.sync_worker(pop=pop) as endpoint:
    result = endpoint.upload("photo.jpg").predict()
    print(result)
```

`upload()` queues the file and `predict()` blocks until the result is ready. A single image yields one prediction; a video or multi-frame container yields one per frame, so call `predict()` in a loop until it returns `None`.

Pass the Pop when you open the session so EyePop can schedule the right compute before any media is processed.

### Next steps

* [Configuration](/developer-documentation/sdks/python/configuration.md) — credentials and environment variables
* [Running Inference](/developer-documentation/sdks/python/inference.md) — files, streams, URLs, video, and image groups
* [Composable Pops](/developer-documentation/sdks/python/composable-pops.md) — chain models into a pipeline
* [Data Endpoint](/developer-documentation/sdks/python/data-endpoint.md) — datasets, VLM inference, and evaluation
