GPU devices to use with Stan using OpenCL

I am interested in trying to run Stan using a GPU, as is described, for example, in this article: https://mc-stan.org/cmdstanr/articles/opencl.html.

In terms of GPU devices, however, will any OpenCL compatible GPU work? I may be able to get an NVIDIA RTX A6000, which is Cuda, DirectCompute, and OpenCL compatible. I assume this will work, but am I wrong, and/or is there a list of recommended and not recommended GPU devices that I should be aware of?

1 Like

Yes you should be fine with that GPU. I’ve personally worked with Stan across AMD, Nvidia, and Intel (integrated) GPUs without much issue (on a mix of Windows, Linux, and WSL systems). @rok_cesnovar do you know if there any edge-cases/issues working with higher-end workstation GPUs?

The majority of GPU compatibility issues will be with Mac systems, since they’ve deprecated OpenCL in favour of their Metal framework

2 Likes

@andrjohns Thanks a lot. In case it makes a difference, I will be exclusively using Linux.

I haven’t heard of any issues with newer GPUs. There are some edge cases with ancient GPUs that have low max thread-block sizes. But if your GPU was made post-2008, you should be good to go.

2 Likes