ROCm
Definition¶
AMD ROCm™ is an open software stack including drivers, development tools, and APIs that enable GPU programming from low-level kernel to end-user applications. ROCm is optimized for Generative AI and HPC applications, and is easy to migrate existing code into.
Install instructions¶
PyTorch¶
To install pytorch, load Python (see: https://scicomp.ethz.ch/wiki/Python) then follow the instructions on https://pytorch.org/ .
PyTorch and Tensorflow for ROCm 6.3.2¶
For setting up a venv with pytorch and tensorflow for ROCm 6.3.2
module load stack/2024-06 python/3.12.8 eth_proxy
srun --ntasks=1 --cpus-per-task=4 --time=4:00:00 --mem-per-cpu=4g --pty bash
change to the directory where you would like to setup your venv
python -m venv --system-site-packages rocm632_python
source ./rocm632_python/bin/activate
OPENBLAS=$OPENBLAS_EULER_ROOT/lib/libopenblas.so pip install --force-reinstall --no-binary numpy numpy==1.26.4
pip install torch==2.4.0 torchaudio==2.4.0 torchvision==0.19.0 pytorch-triton-rocm==3.0.0 -fhttps://repo.radeon.com/rocm/manylinux/rocm-rel-6.3.2
pip install tensorflow-rocm==2.17.0 -fhttps://repo.radeon.com/rocm/manylinux/rocm-rel-6.3.2