Results 1 to 7 of 7

Thread: JPEG 2000 lossy vs lossless decode speed

  1. #1
    Member
    Join Date
    May 2014
    Location
    Canada
    Posts
    136
    Thanks
    61
    Thanked 21 Times in 12 Posts

    JPEG 2000 lossy vs lossless decode speed

    Dear Encoders,

    I realize most people here are interested in lossless codecs, but I have a question about lossless vs lossy decode for J2K.
    I am finding that while a lossy encoded image may be half the size of a lossless encoded image, the time to decode lossy
    is only about 10% lower (using freely available Kakadu kdu_expand).

    One difference between lossless and lossy is that lossy uses a more computationally complex wavelet transform than lossless, and also needs
    to do dequantization. However, the majority of the decode time should be spent in reverse entropy coding, so my intuition tells me that lossy
    decode should be much faster than lossless.

    Any insights here would be greatly appreciated.

  2. #2
    Member
    Join Date
    Jun 2015
    Location
    Switzerland
    Posts
    667
    Thanks
    204
    Thanked 241 Times in 146 Posts
    What happens if you just vary the quality of the lossy coding? Do you see a similar correlation between size and decode speed?

  3. #3
    Member
    Join Date
    May 2014
    Location
    Canada
    Posts
    136
    Thanks
    61
    Thanked 21 Times in 12 Posts
    Quote Originally Posted by Jyrki Alakuijala View Post
    What happens if you just vary the quality of the lossy coding? Do you see a similar correlation between size and decode speed?
    Good idea - logically, speed should increase as compression ratio increases..

  4. #4
    Member
    Join Date
    Apr 2012
    Location
    Stuttgart
    Posts
    437
    Thanks
    1
    Thanked 96 Times in 57 Posts
    Quote Originally Posted by boxerab View Post
    Any insights here would be greatly appreciated.
    Compression and decompression speed of JPEG 2000 is very much dependent on thenumber of bitplanes included in the codestream. The wavelet transformation is computationally simple, and so is the quantization and the color transform, but the EBCOT takes a lot of time - its decoding time is approximately proportional to the number of included bitplanes. Hence, compression/decompression performance of JPEG 2000 is much more quality dependent than that of any other coding method.

  5. #5
    Member
    Join Date
    May 2014
    Location
    Canada
    Posts
    136
    Thanks
    61
    Thanked 21 Times in 12 Posts
    Quote Originally Posted by thorfdbg View Post
    Compression and decompression speed of JPEG 2000 is very much dependent on thenumber of bitplanes included in the codestream. The wavelet transformation is computationally simple, and so is the quantization and the color transform, but the EBCOT takes a lot of time - its decoding time is approximately proportional to the number of included bitplanes. Hence, compression/decompression performance of JPEG 2000 is much more quality dependent than that of any other coding method.
    Thanks, Thomas. What puzzles me is that: lossy encoding with rate control involves discarding least-significant bit planes in each code
    block, so it seems to me that lossy decode should be considerable faster, since there are fewer bit planes encoded.

    I suppose I need to test this with different implementations.

  6. #6
    Member
    Join Date
    Apr 2012
    Location
    Stuttgart
    Posts
    437
    Thanks
    1
    Thanked 96 Times in 57 Posts
    Quote Originally Posted by boxerab View Post
    Thanks, Thomas. What puzzles me is that: lossy encoding with rate control involves discarding least-significant bit planes in each code block, so it seems to me that lossy decode should be considerable faster, since there are fewer bit planes encoded. I suppose I need to test this with different implementations.
    Not quite sure what confuses you so much. Your argument is fully correct. Lossy decode *is* faster than lossless decode. I believe I created some figures for a SPIE paper a while ago which I might still have somewhere. The fun fact is that if you compare "which quality do I get for which speed" then JPEG 2000 performs better than JPEG for that matter, i.e. the "quality per speed ratio" is better. But this means that you would have to deal with pretty low qualities - at which JPEG 2000 is better than JPEG. For the average user, such qualities are less acceptable, and JPEG 2000 becomes overproportionally slower at high qualities.

  7. #7
    Member
    Join Date
    May 2014
    Location
    Canada
    Posts
    136
    Thanks
    61
    Thanked 21 Times in 12 Posts
    Thanks. I've discussed this issue on the Kakadu site, and it looks like this is just a problem with the Kakadu codec for my particular image and hardware configuration.

Similar Threads

  1. Grok JPEG 2000 Codec
    By boxerab in forum Data Compression
    Replies: 3
    Last Post: 30th March 2016, 06:10
  2. Replies: 0
    Last Post: 6th February 2015, 06:57
  3. Faustian Bargain for JPEG 2000 Supremacy
    By boxerab in forum Data Compression
    Replies: 4
    Last Post: 22nd January 2015, 03:41
  4. Open source OpenCL jpeg 2000 library
    By boxerab in forum Data Compression
    Replies: 12
    Last Post: 26th May 2014, 06:18
  5. Lossless vs. Lossy
    By WillatSMU in forum Data Compression
    Replies: 7
    Last Post: 11th May 2012, 17:29

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •