Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #80904

Re: Error when trying to open an image

Date 2014-11-16 13:02 -0800
From Gary Herron <gary.herron@islandtraining.com>
Subject Re: Error when trying to open an image
References <CAA+hu4V7V8hW7L79L97Ty6aGbQtb7NEF_iOmLY4CxDzw5suEjA@mail.gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.15901.1416172331.18130.python-list@python.org> (permalink)

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On 11/16/2014 11:37 AM, Abdul Abdul wrote:
> Hello,
>
> I'm trying to open an image using the `Python Imaging Library` as follows:
>
> from PIL import Image
> img = Image.open('xyz.jpg')
>
> But, got the following error:
>
> File "C:/Users/abc/PycharmProjects/untitled/open_image.py", line 2, in 
> <module>
>     from PIL import Image
>   File "C:\Python34\lib\site-packages\PIL\Image.py", line 62, in <module>
>     from PIL import _imaging as core
> ImportError: DLL load failed: %1 is not a valid Win32 application.
>
> Why is that? How can I solve this issue?

... To be clearer, your problem is not with *opening* an image, but (if 
you look at the error message) its with importing PIL.

Gary Herron

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Error when trying to open an image Gary Herron <gary.herron@islandtraining.com> - 2014-11-16 13:02 -0800

csiph-web