首页 > 解决方案 > tensorflow不使用gpu错误无法加载动态库'libcudnn.so.8'

问题描述

我无法解决这个问题:

我有 GTX-1050。

(base) (venv) wojtek@wojtek-GF63-8RC:~/_mgr/Lenet$ python train_network.py --dataset images --model 90_180_270_plus_originalne
2021-05-04 02:29:38.383821: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:937] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero
2021-05-04 02:29:38.389729: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libcudnn.so.8'; dlerror: libcudnn.so.8: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /usr/local/cuda-11.2/lib64:/usr/local/cuda/lib64::/usr/local/cuda/lib64:/usr/local/cuda/extras/CUPTI/lib64
2021-05-04 02:29:38.389752: W tensorflow/core/common_runtime/gpu/gpu_device.cc:1765] Cannot dlopen some GPU libraries. Please make sure the missing libraries mentioned above are installed properly if you would like to use GPU. Follow the guide at https://www.tensorflow.org/install/gpu for how to download and setup the required libraries for your platform.
Skipping registering GPU devices...
Num GPUs Available:  0

英伟达 smi 输出:

(base) (venv) wojtek@wojtek-GF63-8RC:~/_mgr/Lenet$ nvidia-smi
Tue May  4 02:32:09 2021       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 465.19.01    Driver Version: 465.19.01    CUDA Version: 11.3     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  NVIDIA GeForce ...  On   | 00000000:01:00.0 Off |                  N/A |
| N/A   74C    P0    N/A /  N/A |    488MiB /  4042MiB |      5%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|    0   N/A  N/A      1211      G   /usr/lib/xorg/Xorg                 47MiB |
|    0   N/A  N/A      1371      G   /usr/bin/gnome-shell               88MiB |
|    0   N/A  N/A      1674      G   /usr/lib/xorg/Xorg                309MiB |
|    0   N/A  N/A      1852      G   /usr/bin/gnome-shell               16MiB |
|    0   N/A  N/A      2206      G   ...AAAAAAAA== --shared-files        8MiB |
|    0   N/A  N/A      2306      G   ...gAAAAAAAAA --shared-files        9MiB |
|    0   N/A  N/A      5615      G   /usr/lib/firefox/firefox            1MiB |
|    0   N/A  N/A      6433      G   /usr/lib/firefox/firefox            1MiB |
|    0   N/A  N/A      6690      G   /usr/lib/firefox/firefox            1MiB |


(base) (venv) wojtek@wojtek-GF63-8RC:~/_mgr/Lenet$ nvcc -V

nvcc:NVIDIA (R) Cuda 编译器驱动程序 版权所有 (c) 2005-2020 NVIDIA Corporation 构建于 Mon_Nov_30_19:08:53_PST_2020 Cuda 编译工具,版本 11.2,V11.2.67 构建 cuda_11.2.r11.2/compiler.29373293_0

标签: tensorflownvidia

解决方案


推荐阅读