使用 PyCharm 软件 添加 python 的第三方库 ---- 模块

1. 添加第三方库

pycharm -> File -> Settings -> Project: <‘Project-name’> -> Project Interpreter

上面是用软件添加第三方库的路径
下面是通过搜索 Project Interpreter 添加第三方库:

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

2. 太慢 或者 失败

2.1 更新 pip

pip install --upgrade pip;
python -m pip install --upgrade pip;
pip3 install --upgrade pip;

2.2 添加镜像源

清华: https://pypi.tuna.tsinghua.edu.cn/simple
豆瓣: http://pypi.douban.com/simple/
阿里: http://mirrors.aliyun.com/pypi/simple/

http://mirrors.aliyun.com/pypi/simple/

在这里插入图片描述
在这里插入图片描述

2.3 添加模块

--trusted-host mirrors.aliyun.com

在这里插入图片描述在这里插入图片描述

Logo

腾讯云面向开发者汇聚海量精品云计算使用和开发经验,营造开放的云计算技术生态圈。

更多推荐