Python Examples
Recommended Installation
For python, we use 3.8.5, but any later 3+ version will probably work.
Create a virtualenv:
pip install venv
python3 -m venv eeg_venv
# activate the venv according to your OS
# Windows example:
. ./eeg_venv/scripts/Activate
pip install -r requirements.txtThis file provides a function to make Petal Metrics API calls.
This script contains an example of a Petal Metrics API call without connecting to any active LSL streams. You will need a valid developer API key to access.
python api_standalone.py -k $API_KEYThis script demonstrates how to receive an LSL stream and call the Petal API in an endless loop. You will need a valid developer API key to access.
python api_lsl_call_loop.py -n SimulatedEEGStream -k $API_KEYLast updated
Was this helpful?