I tensorflow/stream_executor/dso_loader.cc:105] Couldn'topen CUDA library libcuda.so.1. LD_LIBRARY_PATH: /home/yaoming/pycharm-community/bin:
I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:160] hostname: yaoming-ThinkPad-T470p
I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:185] libcuda reported version is: Not found: was unable to find libcuda.so DSO loaded into this program
I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:189] kernel reported version is: Permission denied: could notopen driver version path for reading: /proc/driver/nvidia/version
I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1080] LD_LIBRARY_PATH: /home/yaoming/pycharm-community/bin:
I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1081] failed to find libcuda.so on this system: Failed precondition: could not dlopen DSO: libcuda.so.1; dlerror: libnvidia-fatbinaryloader.so.375.39: cannot openshared object file: No such fileor directory
解决方法:
bcuda.so.1 is a symlink to a file that is specific to the version of your NVIDIA drivers. It may be pointing to the wrong version or it may not exi# See where the link is pointing.
ls /usr/lib/x86_64-linux-gnu/libcuda.so.1 -la
Make sure it is pointing to the right version.
Compare it with the installed NVIDIA driver.
nvidia-smi
Replace libcuda.so.1 with a link to the correct version/usr/lib/x86_64-linux-gnu
sudo ln -f -s libcuda.so.
Using TensorFlow backend.
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcublas.so locally
I tensorflow/stream_executor/dso_loader.cc:105] Couldn'topen CUDA library libcudnn.so. LD_LIBRARY_PATH:
I tensorflow/stream_executor/cuda/cuda_dnn.cc:3448] Unable to load cuDNN DSO
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcufft.so locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcurand.so locally
X_train shape: (60000, 28, 28, 1)
60000 train samples
2、
You can also add these commands to the end of your ~/.bashrc so they get executed next time you login.
3、确保已经做过以下操作
First of all, please make sure that you have already installed cudnn. The installation should be done separately after the installation of Cuda.
Then you need to find your path of 'libcudnn.so.' by:
sudo find /usr/ -name 'libcudnn.so'
For me, I got /usr/local/cuda-8.0/targets/x86_64-linux/lib.
You need also find your path where the libraries could be found by using the well-loaded library such as libcufft.so
sudo find /usr/ -name 'libcufft.so'
For me, I got /usr/lib.
Now copy the files to right place: