-
Notifications
You must be signed in to change notification settings - Fork 0
Set up CUDA and pycuda on DCC
Thomas Cowart edited this page Sep 28, 2022
·
1 revision
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
./Miniconda3-latest-Linux-x86_64.sh
conda create -n gpu -c conda-forge pycuda python=3
conda activate gpu
conda install -c nvidia cudatoolkit
conda install -c nvidia cuda-libraries-dev
conda install -c nvidia cuda-nvcc
conda install -c nvidia cuda-gdb
# conda install -c conda-forge pycuda # pycuda is required, but should have been installed when the env was created
srun -p gpu-common --gres=gpu:1 --pty bash -i
srun -p gpu-common --gres=gpu:1 [command to run]
All standard srun
arguments, like --mem
, apply. According to https://dcc.duke.edu/dcc/slurm/#gpu-jobs, as of 10/1/2022 you can specify a specific GPU type and count.