明明显示已经安装了pillow,但是pillow模块依然显示没有。
Pillow的导入用: import PIL
不是用 import pillow
Pillow是PIL的一个派生分支,但如今已经发展成为比PIL本身更具活力的图像处理库。
安装它很简单 pip install pillow
使用方式:
#python2
import Image
#python3(因为是派生的PIL库,所以要导入PIL中的Image)
from PIL import Image
以python3为例,
from PIL import Image
im = Image.open("1.png")
im.show()