From 15c7f77913f72004f0e4e1a147f9d78b596386ff Mon Sep 17 00:00:00 2001 From: Prasanth Nunna Date: Fri, 10 May 2024 15:24:37 +0000 Subject: [PATCH 1/2] Add install steps for ROCm --- docs/source/rocm_installation.mdx | 46 +++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 docs/source/rocm_installation.mdx diff --git a/docs/source/rocm_installation.mdx b/docs/source/rocm_installation.mdx new file mode 100644 index 000000000..476cbae07 --- /dev/null +++ b/docs/source/rocm_installation.mdx @@ -0,0 +1,46 @@ +# ROCm Installation + +Please follow these steps to install bitsandbytes on ROCm. + + + + +For latest installation: + +```bash +git clone https://github.com/TimDettmers/bitsandbytes.git && cd bitsandbytes/ +pip install -r requirements-dev.txt +cmake -DCOMPUTE_BACKEND=hip -S . #Use -DBNB_ROCM_ARCH="gfx90a;gfx942" to target specific gpu arch +make +pip install . +``` + + + + +For ROCm specific versions: + +Install Dependencies: + +```bash +# hipblaslt installation needed only for rocm<6.0 +apt install hipblaslt +pip install --upgrade pip +pip install einops lion_pytorch accelerate +pip install git+https://github.com/ROCm/transformers.git +``` + +Install bitsandbytes from [ROCm](https://github.com/ROCm/bitsandbytes) repo: + +```bash +git clone --recurse https://github.com/ROCm/bitsandbytes +cd bitsandbytes +# Checkout branch as needed +# for rocm 5.7 - rocm5.7_internal_testing +# for rocm 6.x - rocm6.2_internal_testing +git checkout +make hip +python setup.py install +``` + + From d62c83589f6d318369a9d3a3c626eb5221ba079b Mon Sep 17 00:00:00 2001 From: Prasanth Nunna Date: Fri, 10 May 2024 15:28:56 +0000 Subject: [PATCH 2/2] Fix lint error --- docs/source/rocm_installation.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/rocm_installation.mdx b/docs/source/rocm_installation.mdx index 476cbae07..5d4381e7d 100644 --- a/docs/source/rocm_installation.mdx +++ b/docs/source/rocm_installation.mdx @@ -1,6 +1,6 @@ # ROCm Installation -Please follow these steps to install bitsandbytes on ROCm. +Please follow these steps to install bitsandbytes on ROCm.