【问题标题】:Unsatisfiable error while installing tensorflow-gpu in Anaconda在 Anaconda 中安装 tensorflow-gpu 时出现无法满足的错误
【发布时间】:2019-11-09 10:30:58
【问题描述】:

我已经在 Ubuntu 18.04 中安装了 Anaconda Python 3.7,然后执行了命令:

conda update --all
conda install cudnn

现在,当我尝试使用命令 conda install tensorflow-gpu 安装 tensorflow-gpu 时,我收到类似这样的 Unsatisfiable 错误:

UnsatisfiableError: 以下规格被发现是 互不相容:

  • pkgs/main/linux-64::_ipyw_jlab_nb_ext_conf==0.1.0=py37_0 -> ipywidgets -> widgetsnbextension[version='>=3.4.0, 笔记本[version='>=4.4.1'] -> nbconvert -> 漂白
  • pkgs/main/linux-64::bleach==3.1.0=py37_0
  • pkgs/main/linux-64::ipywidgets==7.4.2=py37_0 -> widgetsnbextension[version='>=3.4.0, 笔记本[version='>=4.4.1'] -> nbconvert -> 漂白
  • pkgs/main/linux-64::jupyterlab==0.35.5=py37hf63ae98_0 -> jupyterlab_server[version='>=0.2.0, 笔记本 -> nbconvert -> 漂白剂
  • pkgs/main/linux-64::jupyterlab_server==0.2.0=py37_0 -> 笔记本 -> nbconvert -> 漂白
  • pkgs/main/linux-64::notebook==5.7.8=py37_0 -> nbconvert -> 漂白
  • pkgs/main/linux-64::widgetsnbextension==3.4.2=py37_0 -> notebook[version='>=4.4.1'] -> nbconvert -> 漂白
  • pkgs/main/noarch::nbconvert==5.5.0=py_0 -> 漂白

由于这里涉及多个重要的包,我很困惑该怎么做。我的 PC 中有 NVIDIA GTX 1070 Max-Q,所以 tensorflow-gpu 应该可以完美运行。

【问题讨论】:

  • 嗨 Preetom,问题现在解决了吗?否则,您能否确认它是否适用于 Python 3.6 版?

标签: python tensorflow anaconda


【解决方案1】:

您可以使用以下代码安装 Tensorflow GPU:

  1. 创建一个新的虚拟环境

    conda create -n tensorflow_gpu pip python=3.6

  2. 激活虚拟环境

    activate tensorflow_gpu

  3. 使用

    安装 CUDA 工具包

    conda install -c anaconda cudatoolkit

  4. 安装 TensorFlow GPU

    pip install --ignore-installed --upgrade tensorflow-gpu==1.15

更多信息请参考Tensorflow Blog

【讨论】:

    猜你喜欢
    • 2017-09-29
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-06-05
    • 2020-04-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多