Trying to install the gpu version of Tensorflow on my machine, but I\'m getting this error when trying \'import tensorflow\'
ImportError
It didn't work for me trying to change dll file versions. After struggling with tensorflow-gpu import error for a couple of weeks, I finally figured out that I needed to make respective directories(CUDA,cuDNN & CUPTI) matched to my %PATH% environment variable. I am using CUDA 9.0, cuDNN v7.0 with Tensorflow 1.11.
C:\> SET PATH=C:\Program Files\NVIDIA GPU Computing
Toolkit\CUDA\v9.0\bin;%PATH%
C:\> SET PATH=C:\Program Files\NVIDIA GPU
Computing Toolkit\CUDA\v9.0\extras\CUPTI\libx64;%PATH%
C:\> SET PATH=C:\tools\cuda\bin;%PATH%
https://www.tensorflow.org/install/gpu
You need to have CUDA_HOME
leading to \cuda
and %CUDA_HOME%\bin
appended to your PATH.
Also, tensorflow as of now only supports cudNN 5.1, please make sure you have that.
It should be noted that starting from version 1.0 up until version 1.2 Tensorflow
needed Cuda8 and cudnnv5.1
. Therefore You need to have cudnnv5.1 installed.
This question was asked on April 24 2017
, This means the OP was trying to install version 1.1.0(at the time, the latest version) which at the time needed cudnnv5.1 and python3.5. So he needed to have cudnnv5.1 to fix his/her problem.
However, if you are trying to install the latest version of Tensorflow
, that is anything greater than 1.3.0, you need cudnnv6.0
+.
If you are getting this error on 1.3.0, then it means you need cudnnv6.0.
put that into your PATH
and you will be fine.