在支持 GPU 的 ubuntu 上安装 tensorflow

Installing tensorflow on ubuntu with GPU support

好的。我有一个大问题,我好几天都无法解决。我已经搜索了所有关于此的帖子,但仍然无法做到。

首先。我正在使用 Ubuntu 18.04 与 python 3.6 和 Nvidia Gforce 920M 显卡。我有 Cuda 9.0(也尝试过 9.1 和 9.2)。

我正在尝试安装 tensorflow-gpu,但每次导入它时都会出现同样的错误。

2018-12-09 01:43:41.324778: F tensorflow/core/platform/cpu_feature_guard.cc:37] The TensorFlow library was compiled to use AVX instructions, but these aren't available on your machine. Aborted (core dumped)

我也试过使用 Anaconda,但还是不行。

你们能帮帮我吗? 提前谢谢你。

好的。切换到 python 2.7 并安装 tensorflow-gpu 解决了这个问题。我仍然不知道为什么,但这是解决此问题的方法。如果你们知道如何为 Python 3.6 post 修复它,但直到那时才使用 Python 2.7.

编码愉快!