-
Notifications
You must be signed in to change notification settings - Fork 322
TensorFlow with GPU acceleration on Mac #474
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
Comments
Hi, thanks for filing. I think it's great that Apple provides a build of Tensorflow optimized for some Mac computers. Users interested in using that build should follow the install instructions at the link and then point reticulate at the intended python, e.g, by starting their R session with Sys.setenv(RETICULATE_PYTHON="~/tensorflow-metal/bin/python") However, I don't think it's a good idea for this package to default to using the apple-provided build when installing tensorflow through the R packages a) I just tried those install instructions at that link on a x86 Mac (w/o an AMD GPU) and, no surprise to me, it didn't work. I don't have an ARM or AMD-GPU Mac at the moment so my ability to debug/maintain this will be limited. related: #465 |
Thanks for the detailed feedback, @t-kalinowski. Makes sense, and I'm thankful for the practical info. Just as a side info (not to reopen the issue), my understanding is that the binary is built by Google themselves in what seems to be a more permanent opening towards non-CUDA GPUs using their new PluggableDevices feature, which enables them to bypass the issue of supporting more GPUs without re-writing their core compute code. |
Interesting, thank you for clarifying. However, after taking a closer look, I'm not sure that's right. Perhaps there is some other information you can share? I am making inferences based on these clues: |
You are right, @t-kalinowski, thanks - my mistake. Google did the PluggableDevices, and individual hardware providers like Apple, Intel would build the respective plugins. Thanks again for correcting & sorry for any additional trouble. |
The development version of remotes::install_github("rstudio/tensorflow")
reticulate::install_miniconda()
tensorflow::install_tensorflow() Please file an issue if you encounter errors! |
Hi all,
This is a feature request. Google recently launched a plugin to TensorFlow that enables Metal-based GPU acceleration on Macs (both the AMD GPU and Apple silicon) (https://developer.apple.com/metal/tensorflow-plugin/). Perhaps it would be possible to implement it on the RStudio TensorFlow package.
Theoretically,
reticulate
would need to create an environment with python 3.8. If it's Apple silicon, then it could be either v3.8 or 3.9I would be willing to do a PR if someone from the team could give me any pointers/advice.
The text was updated successfully, but these errors were encountered: