Skip to main content

GPU on Maxwell

Introduction

Sometimes your job takes forever to run and then you realise that you can utilise Maxwell GPU or sometimes some of the software that you use can only run on GPU. Today I'm gonna show you how we can use GPU on Maxwell.

Maxwell GPUs

Here are the summary of the available GPU on Maxwell

NodeNameGPU TypeGPU CodeNumber of GPUsMemory (GB)Number of CPUsPartition
agpu001NVIDIA A100A100351548a100_full
agpu002NVIDIA A100A100351548a100_full
agpu003NVIDIA A100A100351548a100_full
agpu004NVIDIA A100A100451532a100_full
egpu001NVIDIA Tesla V100-PCIE-32GBTesla_V100-PCIE-32GB218440spot-compute,spot-gpu
cgpu001NVIDIA GeForce RTX 2080 TiNVIDIA_GeForce_RTX_2080_Ti218440uoa-gpu,spot-compute,spot-gpu,uoa-gpu-priority

To check it yourself, you can run scontrol show nodes | grep -E "Gres=|Partitions=" on the terminal and it will return the available GPUs (non-null) alongside it's partition.

To use the GPU, you can add both the --gres and --partition parameters to your sbatch script. It should look like this:

#!/bin/bash

# Any bash parameters that you want
#SBATCH --ntasks=1
#SBATCH --mem=16G
#SBATCH --job-name=jupyter-notebook
#SBATCH --output=jupyter-notebook.log

#SBATCH --gres=gpu:A100:1
#SBATCH --partition=a100_full

module load cudatoolkit
module load mamba
source ~/.bash_profile
source ~/.bashrc

--gres (Generic Resource) parameter specifies the type and the number of GPUs required, so in this case I will be using NVIDIA A100 GPU and the number of GPUs that I will be using is 1, for the types and number of GPUs that you can use, please refer to the GPU Code and Number of GPUs column on the table respectively. For the --partition please refer to the Partition column