Skip to content Skip to sidebar Skip to footer

Package (python Pil/pillow) Installed But I Can't Import It

I want to do some image processing and I encountered a problem. Importing the pillow module doesn't seem to work. I found a simple script here to check what packages are installed

Solution 1:

You are importing incorrectly. Try using:

import PIL

or

fromPILimportImage

PIL, i.e., Python Imaging Library is no longer maintained, Pillow is used instead. To maintain backwards compatibility, the PIL module name is used in imports.

Solution 2:

In fact, Pillow is installed under name "PIL", so:

importPILas pillow
fromPILimportImage
...

Look this:

enter image description here

Solution 3:

Checkout the doc:

http://pillow.readthedocs.org/handbook/tutorial.html

You must import it like that:

import PIL

Post a Comment for "Package (python Pil/pillow) Installed But I Can't Import It"