Created
April 17, 2020 23:04
-
-
Save alvarovm/d49333d8e7f680ae10774e3134e977c5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Installing Tensorflow2.1 and Pytorch1.4 | |
| |
#On Cooley, I installed everything from source or with pip. Several packages from softenv are also included: | |
+gcc-7.1.0 | |
+cmake-3.3.0 | |
| |
| |
#Python | |
#Python is version 3.6.10, installed from source with optimizations: | |
export INSTALL_TOP=/soft/datascience/DL_frameworks/installation/ | |
./configure --prefix=$INSTALL_TOP --enable-shared --enable-optimizations | |
| |
#MPICH | |
#Mpich is installed from source, version 3.2.1 | |
./configure --prefix=$INSTALL_TOP | |
make -j 24; make install | |
| |
#HDF5 | |
#I also installed HDF5 from source, version 1.10.5. I did not use a parallel build. | |
./configure --enable-shared --prefix=$INSTALL_TOP | |
make -j 24; make install | |
| |
# After installation, I symlink'd pip3 to pip and python3 to python. Then, upgrade pip with `pip install --upgrade pip`. | |
| |
#Installing numpy: | |
pip install numpy | |
| |
#Install mpi4py | |
CC=mpicc CXX=mpicxx pip install mpi4py | |
| |
#Installing tensorflow | |
pip install tensorflow_gpu==2.1 | |
| |
#Installing torch | |
pip install torch==1.4 | |
| |
#Installing horovod | |
git clone https://github.com/horovod/horovod.git | |
git submodule update --init | |
CC=mpicc CXX=mpicxx HOROVOD_CUDA_HOME=$CUDA_DIR HOROVOD_WITH_PYTORCH=1 HOROVOD_WITH_TENSORFLOW=1 python setup.py build | |
CC=mpicc CXX=mpicxx HOROVOD_CUDA_HOME=$CUDA_DIR HOROVOD_WITH_PYTORCH=1 HOROVOD_WITH_TENSORFLOW=1 python setup.py install | |
| |
# (above, CUDA_DIR is set in the setup script but is $INSTALL_TOP/cuda) | |
| |
# Additional packages installed via pip: | |
pip install Pillow tensorboardX | |
| |
load setup.sh: | |
#!/bin/bash | |
unset LD_PRELOAD | |
export INSTALL_DIR=/soft/datascience/DL_frameworks/installation/ | |
export CUDA_DIR=${INSTALL_DIR}/cuda/cuda-10.1.243/ | |
export LD_LIBRARY_PATH=${CUDA_DIR}/lib:${CUDA_DIR}/lib64:${LD_LIBRARY_PATH} | |
export PATH=${CUDA_DIR}/bin:$PATH | |
export LD_LIBRARY_PATH=${INSTALL_DIR}/lib/:${INSTALL_DIR}/lib64/:$LD_LIBRARY_PATH | |
export PATH=${INSTALL_DIR}/bin/:$PATH | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment