Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AMD GPU #245

Open
MidnightKittenCat opened this issue Apr 1, 2023 · 8 comments
Open

AMD GPU #245

MidnightKittenCat opened this issue Apr 1, 2023 · 8 comments

Comments

@MidnightKittenCat
Copy link

Will amd gpu's be supported?

@gururise
Copy link
Contributor

gururise commented Apr 3, 2023

Will amd gpu's be supported?

Pretty sure this issue has to get solved first in the bitsandbytes library before this will work on an AMD GPU, but I could be wrong.

@MidnightKittenCat
Copy link
Author

Will amd gpu's be supported?

Pretty sure this issue has to get solved first in the bitsandbytes library before this will work on an AMD GPU, but I could be wrong.

I see, I've been having issues trying to get ROcM installed on Ubuntu, been following tutorials all day.

Would you be able to guide me through it and which version to use? (Using ubuntu from the ms store) thanks! (off topic)

@gururise
Copy link
Contributor

gururise commented Apr 3, 2023

ROCM has come a long way and pytorch has good support for it.

Really, the easiest way to use it is to install one of the docker containers:
https://hub.docker.com/r/rocm/pytorch

You can follow this video (starting at step 2) and keeping in mind an older version of the docker container was being used:
https://youtu.be/d_CgaHyA_n4?t=151

There is also a version of bitsandbytes for rocm that works (i've tried it):
https://github.com/broncotc/bitsandbytes-rocm

If you can get that installed and running, you might be able to train a model on an AMD card without having to wait for official AMD support in the bitsandbytes library.

@MidnightKittenCat
Copy link
Author

ROCM has come a long way and pytorch has good support for it.

Really, the easiest way to use it is to install one of the docker containers: https://hub.docker.com/r/rocm/pytorch

You can follow this video (starting at step 2) and keeping in mind an older version of the docker container was being used: https://youtu.be/d_CgaHyA_n4?t=151

There is also a version of bitsandbytes for rocm that works (i've tried it): https://github.com/broncotc/bitsandbytes-rocm

If you can get that installed and running, you might be able to train a model on an AMD card without having to wait for official AMD support in the bitsandbytes library.

Which docker image would I use for a radeon rx 6700xt?

@gururise
Copy link
Contributor

gururise commented Apr 6, 2023

Which docker image would I use for a radeon rx 6700xt?

Grab the latest pytorch one here:
https://hub.docker.com/r/rocm/pytorch

I had good success with: rocm5.4.1_ubuntu20.04_py3.7_pytorch_1.12.1

Also, it looks like the BitsAndBytes lib has been patched to fully work on rocm here:
https://github.com/Titaniumtown/bitsandbytes-rocm/tree/patch-2

So use the patched repo to install bitsandbytes for rocm.

Let me know if you get this working on your AMD card..

@gururise
Copy link
Contributor

gururise commented Apr 6, 2023

One more tip, you since you are on a 6700xt, you'll probably have to set this ENV variable to fake your GPU:
HSA_OVERRIDE_GFX_VERSION=10.3.0

@ttio2tech
Copy link

There is a video guide that includes bitsandbytes installation for AMD ROCm bitsandbytes

@sfxworks
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants