我正在尝试使用pip安装TensorFlow:
$ pip install tensorflow --user
Collecting tensorflow
Could not find a version that satisfies the requirement tensorflow (from versions: )
No matching distribution found for tensorflow
我做错了什么?到目前为止,我使用Python和pip没有任何问题。
我正在尝试使用pip安装TensorFlow:
$ pip install tensorflow --user
Collecting tensorflow
Could not find a version that satisfies the requirement tensorflow (from versions: )
No matching distribution found for tensorflow
我做错了什么?到目前为止,我使用Python和pip没有任何问题。
当前回答
我也有这个问题。当查看不同的.whl文件时。我注意到在python 3.7中没有32位版本的tensorflow。最后只能从这里安装64位Python 3.7。
其他回答
试试这个:
export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/mac/cpu/tensorflow-0.12.1-py3-none-any.whl
pip3 install --upgrade $TF_BINARY_URL
来源:https://www.tensorflow.org/get_started/os_setup(页面已不存在)
更新2/23/17 文档移至:https://www.tensorflow.org/install
在Windows 10上,这里的任何东西都不适合我。也许下面的一个更新的解决方案确实对我有用。
Python -m PIP install——升级tensorflow。
这是在Windows 10上使用Python 3.6和tensorflow 1.5
正确的安装方法如下所述
$ pip install --upgrade TF_BINARY_URL # Python 2.7
$ pip3 install --upgrade TF_BINARY_URL # Python 3.N
从张量流官方主页找到正确的TF_BINARY_URL
至少在我写这篇文章的时候(2020年12月),Tensorflow不支持3.8之后的python版本。使用这个:https://www.tensorflow.org/install来检查它支持哪些python版本,我只是花了几个小时来查看这些答案,花了我很长时间才意识到这一点。
安装Python 3.5。x64位amd版本。确保将Python添加到PATH变量中。然后打开命令提示符并键入
python -m pip install --upgrade pip
应该会给你以下结果:
Collecting pip
Using cached pip-9.0.1-py2.py3-none-any.whl
Installing collected packages: pip
Found existing installation: pip 7.1.2
Uninstalling pip-7.1.2:
Successfully uninstalled pip-7.1.2
Successfully installed pip-9.0.1
现在式
pip3 install --upgrade tensorflow