刚刚开始学习python在安装package上碰了不上壁。
ModuleNotFoundError: No module named 'keras'
使用pycharm-->setting-->project Interpreter直接安装失败,如下图所示
在尝试了用terminal直接用命令pip install keras --user 以及pip install kerashttp://pypi.douban.com/simple/安装失败后,尝试通过下载第三方库,再通过路径导入的方法。
解决方法:
1、 在国内的镜像网站下载pip
国内源:
清华:https://pypi.tuna.tsinghua.edu.cn/simple
阿里云:http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/
华中理工大学:http://pypi.hustunique.com/
山东理工大学:http://pypi.sdutlinux.org/
豆瓣:http://pypi.douban.com/simple/
2、setting-->project Interpreter-->show all-->如下图
成功解决pycharm 的setting中的Error occurred when installing package 'Keras'
最新推荐文章于 2024-04-15 10:58:25 发布