Currently, we only support
Linux operating systems.
users have the possibility to install and use
Windows Subsystem for Linux (WSL).For MacOs users, we strongly recommend to follow the bellow steps before the installation.
Open your bash/zsh script file with editor on your computer.
If you are using bash shellvim ~/.bashrc
If you are using zsh shellvim ~/.zshrc
Write in your .bashrc/.zshrc file with following line.
Save this change and restart your terminal to apply the change.
There are fundamentally two different approaches to install
- Install via Conda
- This is the easiest way for personal computers.
- Install via Venv/VirtualEnv
- This is compatible with ComputeCanada cluster environment.
Approach 1: Conda¶
Step 1: Create new Conda Env called IvadoMedEnv (may taken 5 to 15 minutes)¶
conda env create --file environment.yml
Approach 2: Venv¶
Step 1: Setup Python Virtual Environment.¶
ivadomed requires Python >= 3.6 and <3.9. We recommend
working under a virtual environment, which could be set as follows:
virtualenv venv-ivadomed source venv-ivadomed/bin/activate
If the default Python version installed in your system does not fit the version requirements, you might need to specify a version of Python associated with your virtual environment:
virtualenv venv-ivadomed --python=python3.6
Step 2: Install PyTorch 1.5 and TorchVision (CPU)¶
pip install -r requirements.txt
(Optional) Alternative Step 2: Install PyTorch 1.5 and TorchVision (GPU)¶
If you have a GPU and it has CUDA already setup etc, do the follow or use whatever CUDA version you have.
pip install -r requirements_gpu.txt
Step 3: Install from release (recommended)¶
ivadomed and its requirements from
pip install --upgrade pip pip install ivadomed
(Optional) Alternative Step 3 for Developers: Install from source¶
Bleeding-edge developments are available on the project’s master branch on Github. Installation procedure is the following:
git clone https://github.com/neuropoly/ivadomed.git cd ivadomed pip install -e .
(Optional) Step 4 for Developers Install pre-commit hooks¶
pre-commit to enforce a limit on file size.
After you’ve installed
ivadomed, install the hooks:
pip install -r requirements_dev.txt pre-commit install