如何在Pycharm中正确安装模块?

2024-05-16 18:45:00 发布

您现在位置:Python中文网/ 问答频道 /正文

我想在python中安装PIL,但似乎无法正确安装模块,有什么可以解决问题的吗? (我的python版本是2.7)

enter image description here


Tags: 模块版本pil解决问题
2条回答

试着安装枕头,我也面临着同样的问题,然后我发现PIL可以用以下方法安装。

pip install Pillow

查找您的Python路径:

which python
/Users/gogasca/anaconda/bin/python

您可以从IDE本身或项目设置安装它:

Settings | Project | Project Interpreter | Select the right path, Click + and add pil Library

你可以从那里安装。对我来说,1.1.7在OSX Python2.7.10的Pycharm 5.0.4中工作。其他选择是通过CLI或枕头

enter image description here

或者从pycharm终端“pip安装枕头”

相关问题 更多 >