1.安装matplotlib
2.按照提示更新pip失败
3.使用
python -m ensurepip
python -m pip install --upgrade pip
成功
4.但是我运行python仍然不行,因为不是一个python内核
找到相对应的python内核路径,用命令行打开,把刚才的步骤进行一遍
成功啦
5.想要在pycharm中直接安装库失败
想要在命令行中直接安装也失败
6.换源安装
- 阿里云:http://mirrors.aliyun.com/pypi/simple/
- 中国科技大学:https://pypi.mirrors.ustc.edu.cn/simple/
- 豆瓣 (douban):http://pypi.douban.com/simple/
- 清华大学:https://pypi.tuna.tsinghua.edu.cn/simple/
- 中国科学技术大学:http://pypi.mirrors.ustc.edu.cn/simple/
pip install 安装包 -i http://pypi.douban.com/simple
7.换源出现错误
再换一个源成功了,并且直接下载了相关库
8.用报错源加上--trusted-host pypi.douban.com
pip install 安装包 -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
成功啦