Skip to content

Instantly share code, notes, and snippets.

@petrbela
Last active June 13, 2017 20:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save petrbela/e1542b9ec5453c55a57b7e034771e154 to your computer and use it in GitHub Desktop.
Save petrbela/e1542b9ec5453c55a57b7e034771e154 to your computer and use it in GitHub Desktop.
Install TF + CUDA on Mac

Notes from installing CUDA and TensorFlow on a MacBook Pro 15" 2013 with GeForce 650M

  1. Download CUDA and run installer (see notes)
  2. Go to System Preferences > CUDA and update driver version if prompted.
  3. Make sure deviceQuery lists your GPU
  4. Add cuda to syspath
    export PATH=$PATH:/usr/local/cuda/bin
  5. Download CuDNN (TF on pip currently compiled for version 5.x), unpack and move to /usr/local/cuda
  6. pip install tensorflow tensorflow-gpu
  7. Make sure TF can see the GPU
    $ python
    >>> from tensorflow.python.client import device_lib
    >>> print device_lib.list_local_devices()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment