Skip to content

Latest commit

 

History

History
120 lines (76 loc) · 3.46 KB

python_installation.md

File metadata and controls

120 lines (76 loc) · 3.46 KB

Installation Instructions for Python

Windows

Requirements:

  1. Python 3
  2. MSVC
  3. A CUDA capable GPU from NVIDIA with compute capability greater or equal to 3.0
  4. CUDA Toolkit

Tested on

Software Version
Windows 10
Python 3.7 3.8
CUDA 10.1
MSVC 19.24

Simple Instructions

  1. Install Python and pip (recommended: conda environment), MSVC and CUDA
  2. run pip install pytigre --user
  3. or download from repo and run python setup.py install --user.

A succesfull installation should be able to execute the script at TIGRE/Python/example.py

Step by Step Instructions:

  1. Install MS Visual Studio Build Tools with Windows SDK.

  2. Install Python 3 + pip. Recommended: use a virtual conda environment.

  3. Install CUDA. Make sure the CUDA_PATH and PATH environment variable are set accordingly.

  4. Get TIGRE pip install pytigre --user or inside a conda environment (recommended) pip install pytigre

  5. Try demo 3. If it runs succesfully then you are good to go.

Note: It is known that the package cannot be imported using a pure Python 3.8 installation, i.e. not using a conda environment. Please try a pure installation of Python 3.7 or consider using a conda environment.

Linux

Requirements:

  1. Python 2.7
  2. gcc
  3. A CUDA capable GPU from NVIDIA with compute capability greater or equal to 3.0
  4. CUDA Toolkit

Tested on

Software Version
Ubuntu 16.04 17.10
Python 2.7
CUDA 8.0 9.2
gcc 7.6.0

Simple Instructions

  1. Install python, gcc, pip and CUDA
  2. run pip install pytigre --user
  3. or download from repo and run python setup.py install --user.

A succesfull installation should be able to execute the script at TIGRE/Python/example.py

Step by Step Instructions:

For Ubuntu

  1. Install python 2.7 and pip

    sudo apt update
    sudo apt upgrade
    sudo apt install python2.7 python-pip
    
  2. Install CUDA

    Installing CUDA in linux (specially one with a GUI) can be a challenge. Please follow NVIDIAs instructions carefully.
    CUDA download link

  3. Install gcc

    gcc shoudl already be installed in your linux, as it is part of the linux distribution.
    If you need to install an older version of gcc, read here.

  4. Get TIGRE

    pip install pytigre --user

  5. Try demo 3. If it runs succesfully then you are good to go.

Instead, if you rather compile from source, download/clone the repository and then run

cd TIGRE/Python/ python setup.py install --user

Install in this case will make a copy of pytigre to your python distribution. Therefore the develop command is more useful when modifying the source files and developing the software.

python setup.py develop --user

if this fails, then try:

export CUDAHOME=yourcudahome, e.g. default is export CUDAHOME=/usr/local/cuda python setup.py install --user