YCpBr Endoced big tiff images via VIPS

Help
Anonymous
2012-08-06
2012-10-06
  • Anonymous - 2012-08-06

    Ruven et al..

    As you know, VIPS now usesd YCpBr encoding... I hadn't played around with this
    for a bit, but I had switched to version 1.0 and thought it was working... but
    when I tried another file I had (a new one that actually with YCpCr encoded
    that way)... I was getting iipimage server error message..

    FIF :: Image cache initialisation
    TIFFReadEncodedTile failed for
    /bigdata2/PYRAMIDS/ADRC/40X/ADRC60-129/ADRC60-129_1C_pTDP.dzi.tif

    TIFFReadEncodedTile failed for
    /bigdata2/PYRAMIDS/ADRC/40X/ADRC60-129/ADRC60-129_1C_pTDP.dzi.tif

    Here's the iipsrv.fcgi log...

    CVT maximum viewport size set to 3000
    Full Request is Zoomify=/bigdata2/PYRAMIDS/ADRC/40X/ADRC60-129/ADRC60-129_1C_p
    TDP.dzi.tif/TileGroup0/0-0-0.jpg
    : Command / Argument is Zoomify : /bigdata2/PYRAMIDS/ADRC/40X/ADRC60-129/ADRC6
    0-129_1C_pTDP.dzi.tif/TileGroup0/0-0-0.jpg
    FIF :: Image cache initialisation
    FIF :: TIFF image requested
    FIF :: Image dimensions are 110592 x 90112
    FIF :: Image timestamp: Sun, 05 Aug 2012 13:37:50 GMT
    FIF :: Total command time 14979 microsecondsT
    Zoomify :: Tile request for resolution:0 at x:0, y:0
    TileManager :: Cache Miss for resolution: 0, tile: 0
    TileManager :: Cache Size: 0 tiles, 0 MB
    TIFFReadEncodedTile failed for
    /bigdata2/PYRAMIDS/ADRC/40X/ADRC60-129/ADRC60-129_1C_pTDP.dzi.tif

    Total Request Time: 26783 microseconds
    image closed and deleted
    Server count is 1

    tiffinfo seems to suggest this is a valid file, and some other operations
    worked on it as well-- I used tiffsplit and could view (via imagemagick) at
    least the bottom couples of layers--- my screen doesn't support 100000x65000
    unfortunately

    I posted the image at
    http://node15.cci.emory.edu/TEST_IMAGES/ADRC60-129_1C_pTDP.dzi.tif

    If you have any thoughts that would be great....

    TIFF Directory at offset 0x24f2c708 (619890440)
    Image Width: 110592 Image Length: 90112
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x300bf05a (806088794)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 55296 Image Length: 45056
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x3326f94c (858192204)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 27648 Image Length: 22528
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x33fbac5a (872131674)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 13824 Image Length: 11264
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x34375b90 (876043152)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 6912 Image Length: 5632
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x34466b74 (877030260)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 3456 Image Length: 2816
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x3449c00e (877248526)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 1728 Image Length: 1408
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x344aaa22 (877308450)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 864 Image Length: 704
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x344af884 (877328516)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 432 Image Length: 352
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)
    TIFF Directory at offset 0x344b0b78 (877333368)
    Subfile Type: reduced-resolution image (1 = 0x1)
    Image Width: 216 Image Length: 176
    Tile Width: 256 Tile Length: 256
    Resolution: 10, 10 pixels/cm
    Bits/Sample: 8
    Compression Scheme: JPEG
    Photometric Interpretation: YCbCr
    Orientation: row 0 top, col 0 lhs
    Samples/Pixel: 3
    Planar Configuration: single image plane
    Reference Black/White:
    0: 0 255
    1: 128 255
    2: 128 255
    JPEG Tables: (574 bytes)

    Here's what I am linking against:
    n@node15:/var/www/TEST_IMAGES$ ldd /usr/lib/cgi-bin/iipsrv.fcgi
    linux-vdso.so.1 => (0x00007fff557ff000)
    libfcgi.so.0 => /usr/lib/libfcgi.so.0 (0x00007f694ee76000)
    libnsl.so.1 => /lib/libnsl.so.1 (0x00007f694ec5c000)
    libtiff.so.5 => /usr/local/lib/libtiff.so.5 (0x00007f694e9ea000)
    liblzma.so.1 => /usr/lib/liblzma.so.1 (0x00007f694e7c9000)
    libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x00007f694e5a5000)
    libz.so.1 => /lib/libz.so.1 (0x00007f694e38d000)
    libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f694e079000)
    libm.so.6 => /lib/libm.so.6 (0x00007f694ddf6000)
    libc.so.6 => /lib/libc.so.6 (0x00007f694da72000)
    libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00007f694d85b000)
    libpthread.so.0 => /lib/libpthread.so.0 (0x00007f694d63e000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f694f0a8000)

     
  • David A gutman

    David A gutman - 2012-08-08

    So my server was down for a bit so I couldn't play..

    but I tried the same type of file on a freshly compiled iipimage I checked out
    from SVN..

    It seems the file itself (in theory) is OK though.. http://localhost/cgi-bin/
    iipsrv.fcgi?Zoomify=/var/www/TEST_IMAGE/ADRC60-129_1F_AT8.dzi.tif/ImagePropert
    ies.xml

    Returns a valid XML:
    appear to have any style information associated with it. The document tree is
    shown below.
    <IMAGE_PROPERTIES WIDTH="143360" HEIGHT="98304" NUMTILES="215040" NUMIMAGES="1" VERSION="1.8" TILESIZE="256"/>

    and when I "split" the image the lower layers are displayable (I obviously
    don't try and load the full res image)...

    <----------------------------------->

    QUERY_STRING not set

    QUERY_STRING not set

    FIF :: Image cache initialisation
    TIFFReadEncodedTile failed for /var/www/TEST_IMAGE/ADRC60-129_1F_AT8.dzi.tif

    TIFFReadEncodedTile failed for /var/www/TEST_IMAGE/ADRC60-129_1F_AT8.dzi.tif

    /var/www/TEST_IMAGE/ADRC60-129_1F_AT8.dzi.tif.dzi is neither a file or part of
    an image sequence

    TIFFReadEncodedTile failed for /var/www/TEST_IMAGE/ADRC60-129_1F_AT8.dzi.tif

    I emailed John Cupitt (VIPS developer).. and he mentioned.

    Conversely, when you load a tiff image that uses YCbCr jpeg compression, you
    need to signal to the jpeg compressor that you want RGB data out. By default
    it gives you the internal, subsampled YCbCR data back. You do this by adding
    the single line:

    TIFFSetField( tiff, TIFFTAG_JPEGCOLORMODE, JPEGCOLORMODE_RGB );

    I am not familiar enough with the IIPIMAGE codebase to see if / where that
    might be applicable.

     
  • Ruven

    Ruven - 2012-08-13

    I've just uploaded a fix to SVN that fixes this. I had to rearrange some code
    in addition to including this TIFFSetField command. Please try it out.

     
  • Anonymous - 2012-08-16

    Ruven--- Thanks a lot! I downloaded it, rebuilt from source and it seems to be
    working without an issue.

     


Anonymous

Cancel  Add attachments





Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks