Created
July 18, 2016 14:52
-
-
Save empireshades/f8fa214dea19ca9fc5880c9d69ffbff9 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
######### | |
# Steps to enable CUDA (NVIDIA GPU) on a Centos7 box | |
# (This is not a script, just some notes) | |
######### | |
# setup chroot sftp user for workers to be able to drop files: | |
# http://www.thegeekstuff.com/2012/03/chroot-sftp-setup/ | |
######### | |
# CUDA | |
######### | |
# disable selinux | |
sed -i 's/enforcing/disabled/g' /etc/selinux/config /etc/selinux/config | |
# then reboot | |
#shutdown -r now | |
# disable postfix | |
systemctl stop postfix | |
systemctl disable postfix | |
# enable swap | |
/bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024 | |
/sbin/mkswap /var/swap.1 | |
/sbin/swapon /var/swap.1 | |
# library dependencies | |
yum -y install lapack-devel | |
yum install gcc-c++ | |
yum install kernel-devel | |
yum -y install libjpeg-turbo-devel zlib-devel | |
# get epel | |
cd /var/tmp | |
curl -O https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm | |
yum -y install ./epel-release-latest-7.noarch.rpm | |
# update all | |
yum -y update | |
# install other utils | |
yum -y install pciutils | |
# get cuda RPM of rpms for centos 7 | |
# (must be done on GPU enabled host) | |
cd /var/tmp | |
curl -O http://developer.download.nvidia.com/compute/cuda/7.5/Prod/local_installers/cuda-repo-rhel7-7-5-local-7.5-18.x86_64.rpm | |
yum -y install ./cuda-repo-rhel7-7-5-local-7.5-18.x86_64.rpm | |
yum -y install cuda | |
cd /usr/local/cuda-7.5/samples/1_Utilities/deviceQuery | |
make | |
cp -p deviceQuery /root | |
# get tools | |
yum -y install git | |
# install python-virtualenv | |
yum -y install python-virtualenv | |
# create venv | |
cd /root | |
virtualenv deepenv | |
# activate deepenv (within script?) | |
# install pip pkgs | |
pip install numpy | |
pip install Cython | |
pip install scipy | |
# install cudarray (cuda enabled numpy) | |
cd /root | |
git clone https://github.com/andersbll/cudarray | |
cd cudarray | |
make | |
make install | |
python setup.py install | |
yum -y install libjpeg-turbo-devel | |
cd /root | |
git clone https://github.com/andersbll/deeppy | |
cd deeppy | |
python setup.py install |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment