For Windows 10 (With NVidia 840M GPU)
If you have a different GPU check here to make sure your Compute number is > 3.0. My GPU has a 5.0
Mostly following instructions from official install instructions and steps from Stack Overflow Answer
I have found most answers do not combine the full installation from a clean install.
Configure the machine first
- Download and install Anaconda from Download Anaconda-Windows Link
- Installed Anaconda as User (I did not test installing as admin)
- Download cuDNN v5.1 (Jan 20, 2017), for CUDA 8.0
- Requires entering your email address and signing up.
- Unzip this folder and add the
*/cuda/bin
folder to your %PATH%
- Install NVIDIA Cuda Version 8 for Windows 10
- Also ensure this is in your path
- Check for missing DLL: if
where MSVCP140.DLL
returns nothing you may need to either add it to the path or find it here
- Open Anaconda CMD (with admin privilages)
Now install using conda and to test the installation
In Anaconda CMD (using Admin):
conda create -n tensorflow python=3.5 anaconda
activate tensorflow
pip install --ignore-installed --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-1.0.1-cp35-cp35m-win_amd64.whl
In Python:
import tensorflow as tf
hello = tf.constant('Hello, TensorFlow!')
sess = tf.Session()
print(sess.run(hello))
Also use the code in this answer to further confirm you are using the GPU