Reputation: 41
when I finished installing tensorflow (GPU_support,linux 14.04,python3.4) with virtualenv environment,under the instructions of the official website, i validated the installation with the command :python; import tensorflow; but there is an error:
import tensorflow as tf
Traceback (most recent call last):
File "/home/fangfang/tensorflow/lib/python3.4/site-packages/tensorflow/python/pywrap_tensorflow.py", line 58, in <module>
from tensorflow.python.pywrap_tensorflow_internal import *
File "/home/fangfang/tensorflow/lib/python3.4/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 28, in <module>
_pywrap_tensorflow_internal = swig_import_helper()
File "/home/fangfang/tensorflow/lib/python3.4/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 24, in swig_import_helper
_mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)
File "/home/fangfang/tensorflow/lib/python3.4/imp.py", line 243, in load_module
return load_dynamic(name, filename, file)
***ImportError: /home/fangfang/tensorflow/lib/python3.4/site-packages/tensorflow/python/../libtensorflow_framework.so: undefined symbol: cudnnSetRNNDescriptor_v6
***Upvotes: 4
Views: 2433
Reputation: 305
I had this same error, and so hopefully this solution will work for you...
What version of CuDNN are you using? I found that versions of tensorflow-gpu
> 1.2 would fail to load while I had CuDNN v5.1.10 installed.
At the time I'm writing this, Tensorflow docs say you must have CuDNN v6. https://www.tensorflow.org/install/install_linux#nvidia_requirements_to_run_tensorflow_with_gpu_support
So I just removed the old CuDNN binaries and headers:
$ sudo rm /usr/local/cuda/include/cudnn.h
$ sudo rm /usr/local/cuda/lib64/libcudnn.so
$ sudo rm /usr/local/cuda/lib64/libcudnn.so.5.1.10
and any other remnants of v5.1.10. Then just download and copy the new v6 headers and binaries into those same locations.
This is a useful command to check your CuDNN version:
$ cat /usr/local/cuda/include/cudnn.h | grep CUDNN_MAJOR -A 2
Upvotes: 3