Skip to content

OSError: decoder tiff_adobe_deflate not available #3206

Closed

Description

@YubinXie

What did you do?

I tried to open and display a tiff file compressed in tiff_adobe_deflate and it failed.

OSError: decoder tiff_adobe_deflate not available

How can I get tiff_adobe_deflate decoder? I have installed libtiff.

System: Mac OS

Activity

  1. radarhere commented on Jun 26, 2018

    @radarhere
    Member

    What operating system are you using?

  2. YubinXie commented on Jun 26, 2018

    @YubinXie
    Author

    Mac OS

  3. kkopachev commented on Jun 26, 2018

    @kkopachev
    Contributor

    Is that tiled tiff?

  4. YubinXie commented on Jun 26, 2018

    @YubinXie
    Author

    Yes, tilted tiff image.

  5. kkopachev commented on Jun 26, 2018

    @kkopachev
    Contributor

    In that case Pillow is forced to not use libtiff. I'm currently working to add support for reading tiled images through libtiff and fighting with jpeg downsampling issues.
    Related issues #3044 #2754.
    In order to read your image, you could convert it to baseline image.

  6. YubinXie commented on Jun 26, 2018

    @YubinXie
    Author

    @kkopachev By re-defining im.size, loading the general tiled images are fine. I am able to work with tiled tiff_lzw compressed images.

    I think the main issues is absence of the tiff decoder. I did not find that decoder in my PILLOW plug-in library. It is not due to tiled tiff.

  7. YubinXie commented on Jun 26, 2018

    @YubinXie
    Author

    @kkopachev Did you mean that even if I do not have tiff_adobe_deflate decoder, as long as libtiff works, tiff_adobe_deflate images can be handled?

    I saw other people's PIL._imaging has tiff_adobe_deflate. I do not know why it is not in my PIL and do not know how to get it.

    import PIL from PIL import Image, TiffImagePlugin TiffImagePlugin.READ_LIBTIFF=True dir(PIL._imaging) [‘DEFAULT_STRATEGY’, ‘FILTERED’, ‘FIXED’, ‘HUFFMAN_ONLY’, ‘PILLOW_VERSION’, ‘RLE’, ‘__doc__‘, ‘__file__‘, ‘__loader__‘, ‘__name__‘, ‘__package__‘, ‘__spec__‘, ‘alpha_composite’, ‘bcn_decoder’, ‘bit_decoder’, ‘blend’, ‘convert’, ‘copy’, ‘crc32’, ‘draw’, ‘effect_mandelbrot’, ‘effect_noise’, ‘eps_encoder’, ‘fill’, ‘fli_decoder’, ‘font’, ‘getcodecstatus’, ‘getcount’, ‘gif_decoder’, ‘gif_encoder’, ‘hex_decoder’, ‘hex_encoder’, ‘jpeg_decoder’, ‘jpeg_encoder’, ‘jpeglib_version’, ‘libtiff_decoder’, ‘libtiff_encoder’, ‘linear_gradient’, ‘map_buffer’, ‘new’, ‘outline’, ‘packbits_decoder’, ‘path’, ‘pcd_decoder’, ‘pcx_decoder’, ‘pcx_encoder’, ‘radial_gradient’, ‘raw_decoder’, ‘raw_encoder’, ‘sun_rle_decoder’, ‘tga_rle_decoder’, ‘tiff_lzw_decoder’, ‘wedge’, ‘xbm_decoder’, ‘xbm_encoder’, ‘zip_decoder’, ‘zip_encoder’, ‘zlib_version’]

  8. kkopachev commented on Jun 26, 2018

    @kkopachev
    Contributor

    I'm not sure, but looks like all separate tiff decoders/encoders were removed long time ago #417 and looking at the code at that time, I still see it was only supported with striped images.
    tiff_lzw_decoder works with tiled images, since it goes through LZW decoder.

  9. hugovk commented on Sep 29, 2018

    @hugovk
    Member

    Probably fixed by #3227.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions