欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

Linux安装TensorFlow2

程序员文章站 2024-03-11 10:32:19
...

快速安装:

python -m pip install tensorflow -i https://pypi.douban.com/simple

不建议直接pip install tensorflow,太慢,容易超时

个人遇到的bug:

tensorboard 1.14.0 has requirement setuptools>=41.0.0, but you'll have setuptools 40.6.3 which is incompatible.

Cannot uninstall 'wrapt'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall

更新 wrapt

>> pip install --ignore-installed wrapt
Collecting wrapt
Installing collected packages: wrapt
Successfully installed wrapt-1.12.1

更新 setuptools

>> pip install --ignore-installed  setuptools
Installing collected packages: setuptools
Successfully installed setuptools-46.0.0

重新更新:(是更新!)

python -m pip install --upgrade tensorflow -i https://pypi.douban.com/simple

ps:
若是重新安装(也就是运行了python -m pip install tensorflow -i https://pypi.douban.com/simple)会报错:THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS FILE

相关标签: 机器学习