[英]Tensorflow does not recognize GPU after installing CUDA toolkit and cuDNN
我有一個1070 gtx。 我跑的時候:
> sess = tf.Session(config=tf.ConfigProto(log_device_placement=True))
我有
> 2017-05-24 21:01:07.959988: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
> 2017-05-24 21:01:07.960018: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
> 2017-05-24 21:01:07.960030: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
> Device mapping: no known devices.
> 2017-05-24 21:01:07.962291: I tensorflow/core/common_runtime/direct_session.cc:257] Device mapping:
來自nvidia-smi的結果:
Wed May 24 21:47:25 2017
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 375.39 Driver Version: 375.39 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 GeForce GTX 1070 Off | 0000:02:00.0 On | N/A |
| 0% 44C P8 8W / 180W | 354MiB / 8112MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| 0 1179 G /usr/lib/xorg/Xorg 184MiB |
| 0 2343 G compiz 120MiB |
| 0 26145 G ...el-token=A9030FB8E905376BBEE74D68F09DFE81 47MiB |
+-----------------------------------------------------------------------------+
這告訴我tensorflow沒有使用GPU。 我安裝了CUDA 8.0,cuDNN 5.1和tensorflow 1.1.0。 我不確定是什么問題。 請幫忙。
正如@Alexander Yau指出的那樣,卸載常規的tensoflow軟件包就可以了。 謝謝。
你安裝了nvidia圖形驅動程序嗎? 這也需要。
您可以通過以下方式測試是否已安裝驅動程序
$ nvidia-smi
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.