Hi! Before attending this workshop, we would like to make sure you have Anaconda (python) installed in your computer with the required software up and running. Please, don't forget to bring your laptop on the 1st of April.
First, check if you have Anaconda Navigator (windows) or Anaconda (mac). If not, go to part 1 below. Otherwise, open Anaconda Prompt (windows) or the terminal (mac) and type:
python --version
If you get:
Python 3.X.X
Skip to part 2
-
Go to https://www.anaconda.com/products/individual and download the Individual (open source) package for your OS system (windows, Mac or Linux)
-
Select your installation folder, hit next and for Advanced Options select Register Anaconda3 as my default Python 3.X
- First things first, you need to create or choose an existing folder where you'll store the software. I chose this one:
C:\Users\ScientISST\SBE
- Then, open Anaconda Prompt (windows) or the terminal (mac) and create a virtual environment:
conda create --name scientisst-sbe-env
(don't close the terminal yet)
- Activate your conda environment by running:
conda activate scientisst-sbe-env
- To download the required packages, you need to install pip by running:
conda install pip
Note: from now on, when installing the packages, if the following appears:
Procced ([y]/n)?
Just type "y" and hit enter to continue.
- To download our respository, you need to install Git:
conda install git
- Now we can add the python packages that we'll need:
conda install numpy==1.16.5
conda install pandas
pip install pyserial
pip install biosppy
pip install pylsl
conda install pyqtograph
- Remember that folder we created before? We need it to install the ScientISST Sense API. Run:
git clone https://github.com/scientisst/scientisst-sense-api-python.git <path to your folder>
So, in my case I run:
git clone https://github.com/scientisst/scientisst-sense-api-python.git "C:\Users\ScientISST\SBE"
If you're using mac and want to know your folder's path, you can open a new terminal and drag the folder over it. The output string on the terminal is your path.
-
Close the Anaconda Prompt (windows) or terminal (mac) and Anaconda.
-
Reopen Anaconda and, on the top bar, select your environment:
- Once inside the environment, scroll to the Jupyter Notebook, install it and launch it!
Let's check if everything's working!
In the Jupyter Notebook (web browser), navigate to your folder and add a new python file inside. Run the following:
from biosppy import storage
from biosppy.signals import ecg
signal, mdata = storage.load_txt('./examples/ecg.txt')
This should output the error:
- FileNotFoundError: [Errno 2] No such file or directory: (...)
Now run the following:
%run sense.py
This should say:
- error: No paired device found
Don't worry, it just means we have no files and devices nearby right now. That's all. See you in the workshop!