我在Windows上尝试使用pip
安装tensorflow 2,但它输出了以下错误:ERROR: Could not find a version that satisfies the requirement tensorflow (from versions: none)
啊!我执行了pip list
,tensorflow没有显示出来
回答:
对于当前最新版本的tensorflow发布(2.1.0)在Windows上,你需要Python 3.5、3.6或3.7。它不支持其他版本,例如Python 3.8,2.7虽然支持但在Windows上不支持。
在Unix系统上使用apt安装python3.7:
sudo apt-get install python3.7
在有AUR访问权限的Unix系统上安装python3.7:
yay -S python37
然后你可以使用以下命令安装tensorflow:
python3.7 -m pip install tensorflow