Getting Python Pillow to work with in-built python.

Post Reply
Fabian
Posts: 14
Joined: 19 Nov 2014, 15:49

Getting Python Pillow to work with in-built python.

Post by Fabian » 18 Apr 2017, 21:08

Hi,
I've gotten Pillow installed via pip and all is fine except the _imaging module refuses to load. I assume it is some sort of binary incompatibility. Any advice to narrow down the problem. Other parts of Pillow that are not dependent on a binary module import just fine. I have a lot of VS redist packages installed too.

>>> from PIL import Image
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Program Files\Autodesk\Softimage 2015 SP2\Application\python\Lib\site-packages\PIL\Image.py", line 67, in <module>
from PIL import _imaging as core
ImportError: DLL load failed: The specified module could not be found.

Best regards,
Fabian

User avatar
Daniel Brassard
Posts: 878
Joined: 18 Mar 2010, 23:38
Location: St. Thomas, Ontario
Contact:

Re: Getting Python Pillow to work with in-built python.

Post by Daniel Brassard » 19 Apr 2017, 19:43

I will assume you have loaded the most recent update.

from the installation site

https://pillow.readthedocs.io/en/latest ... ation.html
Warning

Pillow >= 2.1.0 no longer supports “import _imaging”. Please use “from PIL.Image import core as _imaging” instead.
$ifndef "Softimage"
set "Softimage" "true"
$endif

Fabian
Posts: 14
Joined: 19 Nov 2014, 15:49

Re: Getting Python Pillow to work with in-built python.

Post by Fabian » 24 Apr 2017, 23:38

Yes, I even tried all the older still available versions. Managed to get 1.7.8 compiled but without the dependencies so it's not very useful. This would take no time on Linux but getting this working on Windows is just painful. Digging through MS websites to find old compilers and SDK that then don't want to install on new windows versions etc. X(

User avatar
Daniel Brassard
Posts: 878
Joined: 18 Mar 2010, 23:38
Location: St. Thomas, Ontario
Contact:

Re: Getting Python Pillow to work with in-built python.

Post by Daniel Brassard » 26 Apr 2017, 20:11

I feel your pain and totally agree. Python compiling on Windows suck big time.

Have you tried the solution here:

http://stackoverflow.com/questions/2059 ... on-windows

Did you try one of the wheel package provided by Christoph Gohlke's here:

http://www.lfd.uci.edu/~gohlke/pythonlibs/#pillow
$ifndef "Softimage"
set "Softimage" "true"
$endif

Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests