Tensorflow安装出现dependency conflict错误

Python版本: 3.11.4

pip版本已升到最新

电脑上有mac的原装Python2.x,我装的3.11.4,还有个什么依赖的3.9

运行

pip3 install tensorflow

出现类似以下错误

(我报错的是另一个不是tensorflow---estimator,但基本就是这种错误,手太快直接关了窗口,这段是借用的别人的)

tensorflow 2.4.2 depends on tensorflow---estimator<2.5.0 and >=2.4.0

tensorflow 2.4.1 depends on tensorflow---estimator<2.5.0 and >=2.4.0

tensorflow 2.4.0 depends on tensorflow---estimator<2.5.0 and >=2.4.0rc0

tensorflow 2.3.3 depends on tensorflow---estimator<2.4.0 and >=2.3.0

tensorflow 2.3.2 depends on tensorflow---estimator<2.4.0 and >=2.3.0

tensorflow 2.3.1 depends on tensorflow---estimator<2.4.0 and >=2.3.0

tensorflow 2.3.0 depends on tensorflow---estimator<2.4.0 and >=2.3.0

tensorflow 2.2.3 depends on tensorflow---estimator<2.3.0 and >=2.2.0

tensorflow 2.2.2 depends on tensorflow---estimator<2.3.0 and >=2.2.0

tensorflow 2.2.1 depends on tensorflow---estimator<2.3.0 and >=2.2.0

tensorflow 2.2.0 depends on tensorflow---estimator<2.3.0 and >=2.2.0

To fix this you could try to:

  1. loosen the range of package versions you've specified

  2. remove package versions to allow pip attempt to solve the dependency conflict

最后通过运行以下命令解决

pip install tensorflow -i https://pypi.tuna.tsinghua.edu.cn/simple

成功安装tensorflow

相关推荐
2401_8735449211 小时前
使用Black自动格式化你的Python代码
jvm·数据库·python
Fortune7911 小时前
用Python破解简单的替换密码
jvm·数据库·python
码码哈哈0.011 小时前
某音评论采集代码分析(基于 Playwright)文末附成品下载
python
Chase_______11 小时前
【2026最新保姆级】Python 安装与PyCharm安装配置指南 (Window版)
开发语言·python·pycharm
创世宇图11 小时前
Python跨平台文字转语音:调用系统原生引擎实现实时朗读
python
第一程序员11 小时前
GitHub Copilot:Python开发者的AI助手
开发语言·python·github
2401_8735449211 小时前
Python深度学习入门:TensorFlow 2.0/Keras实战
jvm·数据库·python
文艺倾年11 小时前
【2026持续更新】OpenClaw + OpenCode/Claude + CoWork + 源码讲解百万字教程
人工智能·python
axinawang11 小时前
正则表达式
爬虫·python
qq_1481153711 小时前
将Python Web应用部署到服务器(Docker + Nginx)
jvm·数据库·python