首页 > 解决方案 > 我可以让 tensorflow-gpu 与 NVIDIA GeForce MX130 一起工作吗?

问题描述

我知道这在任何意义上都不是机器学习的推荐设置,但我想使用我所拥有的。

我不是专家,有人告诉我 tf-gpu 应该与 cuda 支持的任何设备一起使用。

当我运行时:

from numba import cuda
cuda.detect()

我得到:

Found 1 CUDA devices
id 0        b'GeForce MX130'                              [SUPPORTED]
                      compute capability: 5.0
                           pci device id: 0
                              pci bus id: 1
Summary:
    1/1 devices are supported

而且我可以让 GPU 处理一些基本的“矢量化”任务。

另外,运行:

import tensorflow as tf
tf.test.is_built_with_cuda()

将返回 True

然而,运行

tf.config.experimental.list_physical_devices('gpu')

将返回一个空列表。

跑步:

print("Num GPUs Available: ", len(tf.config.experimental.list_physical_devices('GPU')))

将返回:

Num GPUs Available:  0

跑步:

strategy = tf.distribute.MirroredStrategy()
print("Number of devices: {}".format(strategy.num_replicas_in_sync))

将返回:

WARNING:tensorflow:There are non-GPU devices in `tf.distribute.Strategy`, not using nccl allreduce.
INFO:tensorflow:Using MirroredStrategy with devices ('/job:localhost/replica:0/task:0/device:CPU:0',)
Number of devices: 1

我已经用非 GPU 版本的 tensorflow 训练了一些基本模型,但我不知道如何处理 tf-gpu。根据任务管理器的说法,我能够用 CuDNNLSTM 层拟合模型,但脚本没有使用 GPU。

对于如何让它使用我的“gpu”或确认它是不可能的,我将不胜感激。谢谢!

编辑:

我卸载了 keras 和两个 tensorflow 版本,只安装了 tensorflow-gpu。没有改变。

标签: pythontensorflowjupyter-notebookgpu

解决方案


很不幸的是,不行。

尽管官方规格表明“是”,但 CUDA GPU 列表并未将 MX130 列为其列表的一部分。

(我也在笔记本上运行 MX130)

参考:


推荐阅读