tensorflow-gpu 安装错误 T.T python:3.10 tensorflow: 2.11.0 CUDA 10.1 cuDNN 8.0.3

问题描述 投票:0回答:2
C:\Users\CITADEL>pip install tensorflow-gpu
Collecting tensorflow-gpu
  Using cached tensorflow-gpu-2.12.0.tar.gz (2.6 kB)
  Preparing metadata (setup.py) ... done
Requirement already satisfied: python_version>"3.7" in c:\users\citadel\appdata\local\programs\python\python310\lib\site-packages (from tensorflow-gpu) (0.0.2)
Building wheels for collected packages: tensorflow-gpu
  Building wheel for tensorflow-gpu (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "C:\Users\CITADEL\AppData\Local\Temp\pip-install-3o7_0drd\tensorflow-gpu_b2c72ac2351448d18a87a109721775f4\setup.py", line 37, in <module>
          raise Exception(TF_REMOVAL_WARNING)
      Exception:

      =========================================================
      The "tensorflow-gpu" package has been removed!

      Please install "tensorflow" instead.

      Other than the name, the two packages have been identical
      since TensorFlow 2.1, or roughly since Sep 2019. For more
      information, see: pypi.org/project/tensorflow-gpu
      =========================================================


      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for tensorflow-gpu
  Running setup.py clean for tensorflow-gpu
Failed to build tensorflow-gpu
Installing collected packages: tensorflow-gpu
  Running setup.py install for tensorflow-gpu ... error
  error: subprocess-exited-with-error

  × Running setup.py install for tensorflow-gpu did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "C:\Users\CITADEL\AppData\Local\Temp\pip-install-3o7_0drd\tensorflow-gpu_b2c72ac2351448d18a87a109721775f4\setup.py", line 37, in <module>
          raise Exception(TF_REMOVAL_WARNING)
      Exception:

      =========================================================
      The "tensorflow-gpu" package has been removed!

      Please install "tensorflow" instead.

      Other than the name, the two packages have been identical
      since TensorFlow 2.1, or roughly since Sep 2019. For more
      information, see: pypi.org/project/tensorflow-gpu
      =========================================================


      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> tensorflow-gpu

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
tensorflow
2个回答
14
投票
自 2.1 版本发布以来,

tensorflow-gpu
tensorflow
是相同的软件包。单独安装
tensorflow
将启用 GPU 加速。 您可以参考这个链接它有更多详细信息。


-2
投票

!pip 安装tensorflow-gpu 收集tensorflow-gpu 下载tensorflow-gpu-2.12.0.tar.gz (2.6 kB) 错误:subprocess-exited-with-error

× python setup.py Egg_info 未成功运行。 │ 退出代码: 1 ╰─> 请参阅上面的输出。

注意:此错误源自子进程,并且可能不是 pip 的问题。正在准备元数据(setup.py)...错误错误:元数据生成失败

× 生成包元数据时遇到错误。 ╰─> 输出见上文。

注意:这是上面提到的包的问题,而不是 pip 的问题。提示:详细信息请参见上文。如何解决这个问题?

© www.soinside.com 2019 - 2024. All rights reserved.