troosh / openjpeg

Automatically exported from code.google.com/p/openjpeg
Other
0 stars 0 forks source link

Add a compare tiff function based on image struct for JP2 conformance test #100

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

Figure G.1 of JPEG 2000 Part 4 about JP2 conformance testing indicates that a 
metric comparison between output decode file and ref file is needed to achieve 
the compliance.
However ref file is a tiff file so we need to create a compare tiff files 
function which do:
 a metric comparison of two tiff images with a input tolerance,
 and generate outputs for the dashboard.

It is possible to take example to compare PGX image function: 
http://code.google.com/p/openjpeg/source/browse/trunk/tests/comparePGXimages.c

Or create a generic compare image function which can take all the formats 
founded in the convert.c file as input and generated necessary output for the 
dashboard.

Mickaël

Original issue reported on code.google.com by savmick...@gmail.com on 7 Oct 2011 at 3:02

GoogleCodeExporter commented 9 years ago

Original comment by mathieu.malaterre on 11 Jan 2012 at 9:09

GoogleCodeExporter commented 9 years ago

Original comment by mathieu.malaterre on 25 Feb 2014 at 3:41

GoogleCodeExporter commented 9 years ago
while importing tiff, there is a minor difference:

$ md5sum *.tif
e615e7b347e91e7c8acf018e4d5a8f32  jp2_1.tif
ebce77534f3fe6e6f28eeab802709192  jp2_2.tif
ca2b763ada468c9f8508dc2b6310780e  jp2_3.tif
01ff5dbd2ef33f618325bae7ca271362  jp2_4.tif
f0ae8aab534cb894ebdb4d944f9afe47  jp2_5.tif
c8e98c22e98ef86b4854b062b84c21c2  jp2_6.tif
adcfc07d5cf33eac14a12a8b9cb86515  jp2_7.tif
e889b21073bcce013042c8a219bd72fc  jp2_8.tif
da2a86bfe9b232d666074bd52020ffea  jp2_9.tif

while dataset given by antonin leads:

$ md5sum /tmp/test_streams/conformance/reference_jp2/file?-ref-out.tif
e615e7b347e91e7c8acf018e4d5a8f32  
/tmp/test_streams/conformance/reference_jp2/file1-ref-out.tif
ebce77534f3fe6e6f28eeab802709192  
/tmp/test_streams/conformance/reference_jp2/file2-ref-out.tif
ca2b763ada468c9f8508dc2b6310780e  
/tmp/test_streams/conformance/reference_jp2/file3-ref-out.tif
01ff5dbd2ef33f618325bae7ca271362  
/tmp/test_streams/conformance/reference_jp2/file4-ref-out.tif
a0611a6386bb5ec0ddbb29089ff28f48  
/tmp/test_streams/conformance/reference_jp2/file5-ref-out.tif
c8e98c22e98ef86b4854b062b84c21c2  
/tmp/test_streams/conformance/reference_jp2/file6-ref-out.tif
adcfc07d5cf33eac14a12a8b9cb86515  
/tmp/test_streams/conformance/reference_jp2/file7-ref-out.tif
e889b21073bcce013042c8a219bd72fc  
/tmp/test_streams/conformance/reference_jp2/file8-ref-out.tif
da2a86bfe9b232d666074bd52020ffea  
/tmp/test_streams/conformance/reference_jp2/file9-ref-out.tif

Original comment by mathieu.malaterre on 3 Mar 2014 at 4:31

GoogleCodeExporter commented 9 years ago
Is not easy to pick in between file5-ref-out.tif and jp2_5.tif. Doing a quick 
compulation leads to:

$ pnmpsnr /tmp/file5.kdu.ppm /tmp/jp2_5.conv.ppm
pnmpsnr: PSNR between /tmp/file5.kdu.ppm and /tmp/jp2_5.conv.ppm:
pnmpsnr: Y  color component: 24.93 dB
pnmpsnr: Cb color component: 17.65 dB
pnmpsnr: Cr color component: 27.48 dB

while

$ pnmpsnr /tmp/file5.kdu.ppm /tmp/f5.conv.ppm
pnmpsnr: PSNR between /tmp/file5.kdu.ppm and /tmp/f5.conv.ppm:
pnmpsnr: Y  color component: 24.72 dB
pnmpsnr: Cb color component: 18.17 dB
pnmpsnr: Cr color component: 27.21 dB

So it looks like jp2_5.tif has a slightly better PSNR than file5-ref-out.tif if 
we take kakadu output as gold ref.

Original comment by mathieu.malaterre on 3 Mar 2014 at 4:37

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r2566.

Original comment by mathieu.malaterre on 4 Mar 2014 at 9:14

GoogleCodeExporter commented 9 years ago

Original comment by anto...@gmail.com on 24 Mar 2014 at 3:57