Lossless Photo Compression Benchmark

updated on 21-Jun-2011
(c) Alex Ratushnyak

The results presented in this benchmark are free for scientific, commercial or private use, under the sole restriction of mentioning the source (this page).
All images are 24-bit RGB, pages for 8-bit, 16, 32 and 48-bit images may be added later.
Notes: Bold value means that no compressor with higher quality is faster. Click on compressed sizes for details.
Compressed         Compression    Decompression  Program, options
size, bytes, %     time, seconds  time, seconds
 953701529 100.00      1754.85       1899.74     GraLIC
 958288436 100.48     11342.88       2901.74     BMF -s -q9
 960779536 100.74      3507.06       2890.06     BMF -s
 968656284 101.56     15700.72      14825.83     ZPAQ ocbmp_j4.cfg
 980424622 102.80     32912.98      32663.35     PAQ8im -7
1025785927 107.55       278.83        271.74     FLIC
1029421809 107.93   ~144000       ~144000        WinRK profile PWCM
1036193935 108.64      1355.54       1399.43     StuffIt /c -o --quiet
1051223777 110.22      3627.66       1928.07     RKIM cx
1090648326 114.35      1693.15       1785.98     UHIC m
                                                 Top 10 entries - more details, percentage  
1099168520 115.25       429.26        277.00     BMF
1101457183 115.49      1318.50       1534.62     RKIM c
1112285765 116.62       856.83        926.71     UHIC e
1113625899 116.76      2395.85        547.90     Pyramid Workshop -lv 8 -p 5 -c 65
1124096989 117.86    ~28800        ~29000?       WinRK profile HIGH
1124525483 117.91      2119.37        554.76     NK2 /s
1139523816 119.48       819.84        160.52     BCIF
1168786351 122.55     ~6600          ~806        WinRK profile Best asymmetric
1179594021 123.68      1719.74        481.26     (lossy) dli c -q 100 -qc 80 -ac
1197373664 125.55       169.43         63.31     (lossy) optimized JPEG (NConvert -out jpeg -q 100 -subsampling 2 -opthuff)
1198922703 125.71       167.08        227.57     lsp
1205774721 126.43       324.93        266.39     Kakadu (JPEG2000) Creversible=yes -quiet -num_threads 1
1205805694 126.43       586.06        533.71     JasPer (JPEG2000)
1205815405 126.43      1778.30       1609.19     OpenJPEG (JPEG2000)
1241570883 130.18       180.89        183.35     LOCOe (JPEG-LS)
1241571864 130.18       102.14         88.58     CharLS (JPEG-LS) -encodepnm
1246629218 130.71       497.33        356.65     PGF
1258234867 131.93       133.56        162.45     Libra8 0
1259292302 132.04       671.93        399.13     Pyramid Workshop
1259424035 132.05       126.24        176.17     lsp -f
1260513837 132.17    1000000+      124332.26     (lossy) dli c -q 100 -qc 80 -ac -or
1268001769 132.95       165.80        230.24     lsp -g
1275300753 133.72      3680.75       3263.61     UHARC a -mx -md32768
1276385609 133.83      3525.41       3140.42     UHARC a -mx -md-
1281581846 134.37      1539.57        316.88     APT
1289694107 135.23      4158.51        482.33     UHARC a -m3 -md32768
1292585946 135.53      1112.75       1179.83     packPNM
1303171453 136.64       133.28         63.95     (lossy)  regular  JPEG (NConvert -out jpeg -q 100 -subsampling 2)
1306655142 137.00       950.74        498.29     UHARC a -m3 -md-
1343413925 140.86       203.15        258.97     Libra8 1
1377369189 144.42       356.50        320.60     HD Photo DPK (JPEG-XR)
1380827989 144.78     26889.24         64.50     maximum PNG (PNGOUT /c2 /f5)
1392640222 146.02       342.51        431.86     FreeArc -mt1 -mmm:3*8+grzip:m4:l
1404531562 147.27       410.39        465.62     UHARC a -mz -md32768
1414027643 148.26       814.82         68.65     regular PNG (NConvert -out png)
1434233822 150.38       271.83         83.35     Lossless JPEG (Cornell University)
1478511186 155.02       212.90        266.18     Libra8 2
1490797440 156.31       528.69         62.35     RAR -m5
1493781139 156.62       489.23         62.32     RAR -m3
1505780553 157.88       513.49        103.31     RAR -m5 -mcc+
1660307451 174.09      1930.41        182.07     FreeArc -mx
1665209757 174.60        72.14         47.28     FreeArc -mt1 -mmm:3*8+1xb
1670950770 175.20       506.86        221.82     Bzip2 -k -9
1714263867 179.74       487.47        219.19     Bzip2 -k -5
1715595115 179.88       580.88         93.94     FreeArc
1719326279 180.27      1433.55        130.55     7-zip -mx
1724150516 180.78      1287.17        129.91     7-zip
1853286671 194.32       262.38         70.97     FreeArc -m3
1854100926 194.41       469.30        207.89     Bzip2 -k -1
1892085363 198.39       533.31         91.01     RAR -m5 -mcc-
1916095298 200.91       438.66         46.03     RAR -m3 -mcc-
2144844030 224.89       103.46         40.64     FreeArc -m2
2243458812 235.23       171.11         57.05     RAR -m1
3328613693 349.02         7.92          7.92     copy

About the test images. Five sets with 109 images totalling 3.33 Gb: 50 images (1999 Mb) from http://photographyblog.com and 59 images (1329 Mb) from http://photojournal.jpl.nasa.gov. More details on test data. History, comments and links 11 Apr 2011 - launched the benchmark, with 12 programs tested: GraLIC 1.9.demo, BMF 2.01, PAQ8im, FLIC 1.4.demo, BCIF 1.0 beta, Kakadu 6.4.1, JasPer 1.900.1, LOCO-I/JPEG-LS from HP Labs, packPNM 1.0d, regular PNG (created by NConvert 5.80), Lossless JPEG (Cornell University), RAR 4.00. Conversion to PPM and BMP formats was done by NConvert. JasPer failed to compress this large 139 Mb image (in PPM format), the file created by Kakadu was taken instead. JasPer and Lossless JPEG were compiled with GCC (version and options as in readme.txt in the FLIC package). All programs were tested on an Intel Core i7-930 CPU, 2.8 GHz, 3 Gb RAM, Windows XP. 12 Apr 2011 - added PGF Console Version 6.09.44 and PNGOUT Apr-10-2011 (hopefully no more that slow programs), compiled page Top 10 entries - more details. 13 Apr 2011 - added two programs that were competing in 1999 and 2000: RKIM 1.06 and UHIC 2.0. UHIC dealt with images in BMP format (and short 8.3 names), while for RKIM they were converted to TGA. UHIC fails to fully unpack olympu09.bmp compressed with command e. For measuring decompression time, olympu11.uhi was decompressed instead of olympu09.uhi. 14 Apr 2011 - added LSP, OpenJPEG 1.4, RAR -m5 -mcc+, -m3, -m1. 15 Apr 2011 - added Pyramid Workshop (ver. 21.03.2011 compiled by Niels Fröhling), RAR -m5 -mcc-, RAR -m3 -mcc-. PW with -lv 8 -p 5 -c 65 fails to compress two images, they were compressed with -lv 8 -p 5. With no options it fails to losslessly decompress two other images, but only three bytes differ. 16 Apr 2011 - added FreeArc 0.67 (March 18 2011), PAQ8im decompression time, compiled page Top 10 entries - percentage. 17 Apr 2011 - added Libra8 and ZPAQ 2.05 with bmp_j4 model. ZPAQ was recompiled (to turn on the optimization "o" feature for faster compression and decompression with config files) with this command: g++ -O3 -DNDEBUG -DOPT="\"g++ -O3 -DNDEBUG -march=pentiumpro -s -fomit-frame-pointer zpaq.cpp libzpaq.cpp zpaqopt.cpp -o zpaqopt.exe\"" zpaq.cpp libzpaq.cpp libzpaqo.cpp -o zpaq After you run it with command okcbmp_j4.cfg, it creates zpaqopt.exe, and then you run zpaqopt.exe instead of zpaq.exe. Output is bit-exact, but speed is much higher. 18 Apr 2011 - added 7-zip 9.20, BZIP2 1.0.6, HD Photo DPK 1.0. 7-zip exits with "Internal Error #1" if archive name is nul.ext, with "Unknown Error" if it's nul.exte, it says "Error: I won't write compressed data to a terminal" if you try 7z a -so archive image, and finally "System error: Not implemented" if you try 7z a -so archive image >redirect. Bzip2 was compiled with GCC. HD Photo DPK was compiled in Visual Studio 2008 - Release, no project settings were modified. If the extension of compressed image file is not .wdp, decompressor refuses to unpack the image, although the format name has changed twice: Windows Media Photo - HD Photo - JPEG XR. 19 Apr 2011 - added APT 1.0 and StuffIt 2010 ver. 14.0.0.18 (Compression Technology version 14.0.0.15). Compression time will be added later. 20 Apr 2011 - added NK2 and compression time for APT and StuffIt. Started testing DLI -q 100 -qc 80 -ac. 21 Apr 2011 - DLI -or is extremely slow. Looks like it will take more than 333 hours to compress all 109 images. Started testing WinRK 3.1.2. 29 Apr 2011 - added WinRK 3.1.2. The only non command line program. Time is "Elapsed time" reported by WinRK itself. It crashes compressing the set of all 109 images with profile Best asymmetric. Does not crash if five sets are compressed separately. Decompression was bit-exact for all images, both tested profiles. DLI -or -q 100 -qc 80 -ac will finish compressing on Monday or Tuesday. 04 May 2011 - added WinRK with profile HIGH and CharLS v.64769 ( \trunk\charls\test\test.vcproj ). CharLS was compiled in Visual Studio 2008 - Release, no project settings were modified. WinRK with profile HIGH fails to decompress 41st image (canon_eos_600d_14) and all remaining images. 11 May 2011 - added FreeArc -mmm:3*8+1xb, FreeArc -mmm:3*8+grzip:m4:l, and two lossy algorithms: DLI 2.1 and JPEG, both at best possible quality. 13 May 2011 - UHARC 0.6b was tested, C- and D-time will be added later. 16 Jun 2011 - Added UHARC's compression time and decompression time. With -mz it was compressing images in BMP format, because on PPM files compressed size was 39% bigger. 21 Jun 2011 - NConvert 5.91 was released, it doesn't fail on raw images from Fujifilm FinePix X100 and Canon EOS 1100D, so everything* will soon be re-tested with the updated test set. When the most recent version 2.4 of Detector for ex-JPEGs is applied, 65 of 110 images from photojournal.jpl.nasa.gov are detected as ex-JPEGs (and discarded), but none of the 62 images from photographyblog.com. *Everything except WinRK, DLI in slow mode, Libra8 with options 1 and 2. Return to the main LPCB page.