Starter Kit – Raspberry Pi 5 (GenX320) - Python dependencies
Installation of Python dependencies
OpenEB and Metavision SDK provide
Python API and
code samples. For using them, you will need to install Python and some additional libraries.
We recommend using Python with
virtualenv as described in
OpenEB README to avoid conflicts with other installed Python packages:
First, install virtualenv along with development tools:
- sudo apt -y install python3.11-venv python3.11-dev
Next, create a virtual environment:
- python3 -m venv ~/prophesee/py3venv --system-site-packages
- ~/prophesee/py3venv/bin/python -m pip install pip --upgrade
Install the necessary dependencies
If you installed using our custom image, then you need to download our file with dependencies and install them:
- wget -O requirements_openeb.txt https://github.com/prophesee-ai/openeb/blob/main/utils/python/requirements_openeb.txt?raw=true
- ~/prophesee/py3venv/bin/python -m pip install -r requirements_openeb.txt
If you installed from the source code, then install the dependencies with this command:
- ~/prophesee/py3venv/bin/python -m pip install -r ~/openeb/utils/python/requirements_openeb.txt
Optionally, you can run the activate
command to modify your shell's environment variables,
setting the virtual environment's Python interpreter and scripts as the default for your current session:
- source ~/prophesee/py3venv/bin/activate
Running Python samples
Now, Python samples are ready to be run, for example:
python /usr/local/share/metavision/sdk/core/python_samples/metavision_simple_viewer/metavision_simple_viewer.py
As a Prophesee customer, get access to your personal ticketing tool, application notes, product manuals, SDK Download Center and more resources.