【问题标题】:I created a venv and tried to install tensorflow 1.15 but still the same error我创建了一个 venv 并尝试安装 tensorflow 1.15 但仍然出现相同的错误
【发布时间】:2021-03-21 21:42:54
【问题描述】:

请帮帮我。 我已经在全球范围内安装了 tensorflow 2.3,并正在尝试安装 tensorflow 1.15,但总是遇到此错误。我尝试全局卸载张量,但失败了。

(Cardiac) C:\venvCardiac>pip install tensorflow==1.15
Collecting tensorflow==1.15
  ERROR: Could not find a version that satisfies the requirement tensorflow==1.15 (from versions: 2.2.0rc1, 2.2.0rc2, 2.2.0rc3, 2.2.0rc4, 2.2.0, 2.2.1, 2.3.0rc0, 2.3.0rc1, 2.3.0rc2, 2.3.0, 2.3.1, 2.4.0rc0, 2.4.0rc1, 2.4.0rc2, 2.4.0rc3, 2.4.0rc4)
ERROR: No matching distribution found for tensorflow==1.15

【问题讨论】:

    标签: python tensorflow tensorflow2.0 python-venv virtual-environment


    【解决方案1】:

    如此处所述:https://www.tensorflow.org/install/pip Python3.8 与 Tensorflow 1.x 不兼容,但仅与 Tensorflow 2.x 兼容。

    您应该使用较旧的 Python 版本(如 3.6.9)创建一个新的 Python 环境,然后安装 Tensorflow 1.15(如果需要)。

    【讨论】:

    • 3.7.12 支持 1.x 吗?我阅读了 3.7 的支持,但在 3.7 版本中遇到了同样的错误
    【解决方案2】:

    用于卸载 tensorflow:

    pip uninstall tensorflow
    

    使用此命令升级 pip:

    pip install --upgrade pip
    

    使用此命令安装 tensorflow 1.15:

    pip install tensorflow==1.15.0
    

    【讨论】:

    • 这不是问题的答案。
    猜你喜欢
    • 2021-05-04
    • 1970-01-01
    • 2019-08-06
    • 2020-09-15
    • 2019-07-09
    • 2019-06-01
    • 1970-01-01
    • 2016-10-20
    • 2021-04-13
    相关资源
    最近更新 更多