[英]InternalError: cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version ANACONDA WINDOWS
[英]cudaGetDevice() failed. Status: CUDA driver version is insufficient for CUDA runtime version (on GCP - Ubuntu 18 LTS running in VNC GUI)
我已点击此链接按顺序获取我的所有版本:
我需要将 Tensorflow_GPU_1.14.0 用于遗留代码。
所以:
tensorflow_gpu-1.14.0
蟒蛇:2.7、3.3-3.7
立方网络:7.4
库达:10.0
import tensorflow as tf; print(tf.__version__)
返回 1.14.0
我的 nvcc 版本是:
nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2018 NVIDIA Corporation
Built on Sat_Aug_25_21:08:01_CDT_2018
Cuda compilation tools, release 10.0, V10.0.130
我的 nvidia-smi 是:
nvidia-smi
Wed Jan 22 16:47:10 2020
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 410.104 Driver Version: 410.104 CUDA Version: 10.0 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 Tesla K80 Off | 00000000:00:04.0 Off | 0 |
| N/A 47C P8 31W / 149W | 27MiB / 11441MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| 0 2524 G /usr/lib/xorg/Xorg 9MiB |
| 0 2574 G /usr/bin/gnome-shell 6MiB |
+-----------------------------------------------------------------------------+
我的 Cudnn 版本是:
cat /usr/include/cudnn.h | grep CUDNN_MAJOR -A 2
#define CUDNN_MAJOR 7
#define CUDNN_MINOR 4
#define CUDNN_PATCHLEVEL 2
--
#define CUDNN_VERSION (CUDNN_MAJOR * 1000 + CUDNN_MINOR * 100 + CUDNN_PATCHLEVEL)
#include "driver_types.h"
我的蟒蛇版本:
import sys
print(sys.version)
3.6.10 |Anaconda, Inc.| (default, Jan 7 2020, 21:14:29)
[GCC 7.3.0]
我正在使用 Ubuntu 18.04 LTS
为了在下面的评论部分扩展罗伯特的回答,我首先使用卸载了现有的 nvidia
sudo apt-get purge nvidia-*
然后使用安装最新版本
sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt update
sudo apt upgrade
ubuntu-drivers list
然后从我选择的列表中
sudo apt install nvidia-driver-VERSION_NUMBER_HERE
然后我sudo reboot
我的实例,并在 Jupyter notebook 中执行以下代码。
import tensorflow as tf
print(('Is your GPU available for use?\n{0}').format(
'Yes, your GPU is available: True' if tf.test.is_gpu_available() == True else 'No, your GPU is NOT available: False'
))
print(('\nYour devices that are available:\n{0}').format(
[device.name for device in tf.config.experimental.list_physical_devices()]
))
它奏效了
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.