我正在新的虚拟环境上安装tensorflow。当我尝试 pip install tensorflow 时,我收到以下消息
Collecting tensorflow-gpu
Could not find a version that satisfies the requirement tensorflow-gpu (from
versions: )
No matching distribution found for tensorflow-gpu
我使用的是 macOS yosemitie 和 python 3.6
我尝试过以下方法:
- 使用 python 3.5 安装
- 转到 pypi,下载轮子并在其上使用 pip
- 此外,还尝试在 pip 中使用
--usewheel
选项
- 此外,还尝试在 pip 中使用
- git 克隆tensorflow存储库并使用
tensorflow/tools/pip_package/setup.py
进行安装
到目前为止,还没有任何效果。关于为什么以及我能做什么有什么见解吗?
最佳答案
Note: As of version 1.2, TensorFlow no longer provides GPU support on macOS.
在没有-gpu
的情况下运行以下命令:
pip install --upgrade tensorflow # for Python 2.7
pip3 install --upgrade tensorflow # for Python 3.n
官方说明可以在这里找到:Installing TensorFlow on macOS
关于python - Pip 在 macOS 上找不到 python 3.6 的 tensorflow ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47118100/