Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #cloud-config
- package_upgrade: true
- packages:
- - wget
- - tar
- - git
- - build-essential
- - software-properties-common
- - cmake
- - python-dev
- - python-pip
- - Xorg
- runcmd:
- - [ wget, "http://us.download.nvidia.com/XFree86/Linux-x86_64/352.93/NVIDIA-Linux-x86_64-352.93.run", -O, /root/NVIDIA-Linux-x86_64-352.93.run ]
- - [ modprobe, -r, nouveau ]
- - [ sed, -i, -e, 's/quiet/quiet rdblacklist=nouveau/g', /etc/default/grub ]
- - echo 'blacklist nouveau' >/etc/modprobe.d/disable-nouveau.conf
- - [ chmod, u+x, /root/NVIDIA-Linux-x86_64-352.93.run ]
- - [ fallocate, -l, 1G, /swapfile ]
- - [ chmod, 600, /swapfile ]
- - [ mkswap, /swapfile ]
- - [ swapon, /swapfile ]
- - echo "/swapfile none swap sw 0 0" > /etc/fstab
- - [ pip, install, --upgrade, pip ]
- - [ pip, install, Cython ]
- final_message: "The system is finally up, after $UPTIME seconds"
- write_files:
- - path: /root/install-gpu-driver.sh
- permissions: 744
- content: |
- sh /root/NVIDIA-Linux-x86_64-352.93.run -s
- nvidia-smi -pm 1
- nvidia-smi -am 1
- - path: /root/install-disvis.sh
- permissions: 744
- content: |
- apt-get -y install libffi-dev libfftw3-dev libfftw3-double3 libfftw3-long3 libfftw3-single3
- cd /usr/include
- wget http://www.pd.infn.it/~verlato/GPU/opencl-files.tgz
- tar zxvf opencl-files.tgz
- rm -f opencl-files.tgz
- pip install mako
- pip install numpy
- pip install pyfftw
- pip install pyopencl==2015.1
- cd /root
- git clone https://github.com/clMathLibraries/clFFT.git
- git clone https://github.com/haddocking/disvis.git
- git clone https://github.com/geggo/gpyfft.git
- cd /root/clFFT/src
- cmake CMakeLists.txt
- make install
- cd /root/gpyfft
- git checkout b462420e19a534d832a9925f01109e80d3431de2
- python setup.py install
- cd /root/disvis
- python setup.py install
- cd /home
- wget http://www.pd.infn.it/~verlato/GPU/appl-files.tgz
- tar zxvf appl-files.tgz
- rm -f appl-files.tgz
- # Testing DisVis (~20s on Tesla K20m)
- # /home/run-disvisGPU.sh
- # nvidia-smi --query-accounted-apps=pid,gpu_serial,gpu_name,gpu_utilization,time --format=csv
- - path: /root/install-powerfit.sh
- permissions: 744
- content: |
- apt-get -y install libxml2-dev libxslt1-dev libffi-dev libfftw3-dev libfftw3-double3 libfftw3-long3 libfftw3-single3
- cd /usr/include
- wget http://www.pd.infn.it/~verlato/GPU/opencl-files.tgz
- tar zxvf opencl-files.tgz
- rm -f opencl-files.tgz
- pip install mako
- pip install numpy
- pip install scipy
- pip install virtualenv
- pip install pyfftw
- pip install pyopencl==2015.1
- cd /root
- git clone https://github.com/clMathLibraries/clFFT.git
- git clone https://github.com/haddocking/powerfit.git
- git clone https://github.com/geggo/gpyfft.git
- cd /root/clFFT/src
- cmake CMakeLists.txt
- make install
- cd /root/gpyfft
- git checkout b462420e19a534d832a9925f01109e80d3431de2
- python setup.py install
- cd /root/powerfit
- python setup.py install
- cd /home
- wget http://www.pd.infn.it/~verlato/GPU/appl-files.tgz
- tar zxvf appl-files.tgz
- rm -f appl-files.tgz
- # Testing PowerFit (~90s on Tesla K20m)
- # /home/run-powerfitGPU.sh
- # nvidia-smi --query-accounted-apps=pid,gpu_serial,gpu_name,gpu_utilization,time --format=csv
- users:
- - name: ubuntu
- sudo: ALL=(ALL) NOPASSWD:ALL
- lock-passwd: true
- ssh-import-id: ubuntu
- ssh-authorized-keys:
- - ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAuNBEiH455kxaEr8tWEjdqICI4PDnOus7hTx0Qvix05pySKQuQlSoALk8UsPSHSgFZj9ATpgFFSepACn0hnHu9DISGHn6aIWE8snUc5UctWMlzNoutTngooSjYQxRPZTfHcntjgd5T0Amfqgn1PjO8qaseKLmsR87FhG7Pfe6yodnxqFXu2rzhFYbzkB9MdkFGplCjCT+8+YaGyThxEvB33YHP5hNzCtdqrJ/ojGUgPRZ9QwxrJLgwMOe6EKrngJsVQUfF82CvpQltH82mPDEWCBtLUOx+Mo/PFrvcDMZbgbIEIp9kOPeRLD3jRGObYuANJYaVoxir9N9N2TFbbcDHQ== verlato@prod-ui-02.pd.infn.it
- power_state:
- mode: reboot
- message: Bye Bye
- timeout: 600
- condition: True
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement