[Image-SIG] PIL error with encoder

Dhruv Majumdar dhruv at nettrackers.net
Mon Aug 2 20:53:11 CEST 2010


Hi Fredrik,

>>> import _imaging; print _imaging.__file__
/usr/local/lib/python2.7/site-packages/PIL/_imaging.so


Here's a dump of the complete error in case it helps;

[root at acroplia-1 audioprocessing]# /usr/local/bin/python wav2png.py
M1F1-Alaw-AFsp.wav
processing file M1F1-Alaw-AFsp.wav:
        0% 10% 20% 30% 40% 50% 60% 70% 80% 90% 100% Traceback (most recent
call last):
  File "wav2png.py", line 45, in <module>
    create_wave_images(*args)
  File "/root/a/freesound/freesound/utils/audioprocessing/processing.py",
line 479, in create_wave_images
    waveform.save(output_filename_w)
  File "/root/a/freesound/freesound/utils/audioprocessing/processing.py",
line 391, in save
    self.image.save(filename)
  File "/usr/local/lib/python2.7/site-packages/PIL/Image.py", line 1439, in
save
    save_handler(self, fp, filename)
  File "/usr/local/lib/python2.7/site-packages/PIL/PngImagePlugin.py", line
572, in _save
    ImageFile._save(im, _idat(fp, chunk), [("zip", (0,0)+im.size, 0,
rawmode)])
  File "/usr/local/lib/python2.7/site-packages/PIL/ImageFile.py", line 481,
in _save
    e = Image._getencoder(im.mode, e, a, im.encoderconfig)
  File "/usr/local/lib/python2.7/site-packages/PIL/Image.py", line 401, in
_getencoder
    raise IOError("encoder %s not available" % encoder_name)
IOError: encoder zip not available

Thank you,
         Dhruv
+1-510-931-6347



On 2 August 2010 19:35, Fredrik Lundh <fredrik at pythonware.com> wrote:

> 2010/8/2 Dhruv Majumdar <dhruv at nettrackers.net>:
>
> > Im new to Python and have been struggling with this error during tests:
> >
> > IOError: encoder zip not available
> >
> > I have python 2.7 with zlib, jpeg and freetype installed on the server.
> When
> > building PIL it shows support for all three above. However i notice at
> > ImageFile._save(im, _idat(fp, chunk), [("zip", (0,0)+im.size, 0,
> rawmode)])
> >
> > I get the abovementioned error.
>
> Make sure your Python script is actually picking up the version you
> built.  To see which version it's using, add this to your script:
>
>     import _imaging; print _imaging.__file__
>
> </F>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/image-sig/attachments/20100803/84a4b17f/attachment.html>


More information about the Image-SIG mailing list