Skip to content

Installation

If you just want to install encord-agents in your current environment, you can run:

python -m pip install encord-agents

You can optionally include additional dependencies used for working with visual files such as Images, Videos, Image Groups / Sequences by running:

python -m pip install encord-agents[vision]

Info

We recommend installing this for most use cases, as our methods are optimized for fast, easy handling of visual files. It is optional to support serverless setups where you wish to avoid bundle size, or Agents that do not need visual data — such as those working only with labels, priorities, text, PDFs, or audio.

Warning

This Project requires python >= 3.10. If you do not have Python 3.10, we recommend using, e.g., pyenv to manage your Python versions.


We recommend installing the Encord agents library in an isolated environment. There are several options available.

Venv

  1. Create a new virtual environment. In this example, we name it agents-venv but you can choose any name you see fit.
python -m venv agents-venv
  1. Next, activate your virtual environment. This ensures that any modules you install remain isolated and that all previously installed modules in the environment are available for use in Python.
source agents-venv/bin/activate
  1. Once activated, the environment name is displayed before the cursor in your terminal.
example
(agents-venv) $
  1. Install the encord-agents library.
python -m pip install encord-agents

Poetry

If you already have a Poetry project, you can add encord-agents to that project:

poetry add encord-agents

Conda

  1. Create a conda environment.
conda create -n agents python>=3.10
  1. We suggest activating your conda environment.
conda activate agents
  1. Once activated, the environment name is displayed before the cursor in your terminal.
example
(agents) $
  1. Install the encord-agents library.
python -m pip install encord-agents

Dependencies

The dependencies for encord-agents are kept lightweight, with the largest dependencies being numpy with opencv-python-headless also included in encord-agents[vision]. To see the full list of dependencies, go here.