Codecs JPEG/RLE test images/issues

472 views
Skip to first unread message

Henri Papath

unread,
Jan 14, 2013, 7:10:34 AM1/14/13
to fo-d...@googlegroups.com
I run some tests for JPEG/RLE compressed images using the library and i wanted to share some results.
I am using sample images from various sources for almost every transfer syntax.

Until now,I am seeing decoding issues with the following JPEG TSs:

1.2.840.10008.1.2.4.51JPEG Extended
1.2.840.10008.1.2.4.57 JPEG Lossless
1.2.840.10008.1.2.4.81 JPEG-LS Lossy (Near-Lossless) Image Compression

1.2.840.10008.1.2.4.91 (this one is caused by unsupported photometric interpetation -YBR-ICT)

I am attaching the images for reference.

Other TSs which i tested without issues are:

1.2.840.10008.1.2.4.50
1.2.840.10008.1.2.4.70
1.2.840.10008.1.2.4.80
1.2.840.10008.1.2.5
1.2.840.10008.1.2.4.90

(for test i used Vb.net 2010:   bmp = DcmImage.RenderImage(0) showing bmp in picturebox)
(where DcmImage is DicomImage)

images are from David Clunie.
1.2.840.10008.1.2.4.91 VL5_J2KI.dcm.zip
1.2.840.10008.1.2.4.51 MR2_JPLY.dcm.zip
1.2.840.10008.1.2.4.57 MR-MONO2-12-shoulder.dcm.zip
1.2.840.10008.1.2.4.81 MR2_JLSN.dcm.zip

Mahesh Dubey

unread,
Jan 14, 2013, 8:51:49 AM1/14/13
to fo-d...@googlegroups.com
Hello;
          What issue you are facing ?? I had tested the above images except the image which is having photometric interpetation ==YBR-ICT. I haven't saw any problem for other images, all are displaying fine. 

Mahesh

Henri Papath

unread,
Jan 15, 2013, 5:05:42 AM1/15/13
to fo-d...@googlegroups.com
Hi Mahesh,

I am attaching the image i get from the DicomDump project
I tried playing with the window width/center values but didn't get any significant change.

Am i missing something?
1.2.840.10008.1.2.4.57 MR-MONO2-12-shoulder.png

Mahesh Dubey

unread,
Jan 15, 2013, 6:38:25 AM1/15/13
to fo-d...@googlegroups.com
Attach image is what I get using the dicom dump image view.
Also the WL processing works fine.
1) Do u have updated code ?

Mahesh
1.2.840.10008.1.2.4.57 MR-MONO2-12-shoulder.JPG

Henri Papath

unread,
Jan 15, 2013, 6:45:21 AM1/15/13
to fo-d...@googlegroups.com
Wow.

Ok. Really strange. Seems i don't obviously.

Is this in master? I checked out the repo 3 or 4 days ago.


Mahesh Dubey

unread,
Jan 15, 2013, 6:49:37 AM1/15/13
to fo-d...@googlegroups.com
Yes this is forked from master

Henri Papath

unread,
Jan 15, 2013, 7:19:15 AM1/15/13
to fo-d...@googlegroups.com
I just re-cloned the repo and i still get the same image. I am using the Git windows client.
Anyway, propably i am doing something wrong.

Thanks for your support and congrats for the lib. I love its compact design 


Mahesh Dubey

unread,
Jan 15, 2013, 8:40:32 AM1/15/13
to fo-d...@googlegroups.com
Can you post some code here ? 

Regards
Mahesh

Henri Papath

unread,
Jan 15, 2013, 11:27:52 AM1/15/13
to fo-d...@googlegroups.com
The strange thing is that the last screenshot i attached was from the DicomDump project of the Dicom solution.
Not my code. So i don't know which part of the code would usefull to post here.

I will now try to build and run on another PC...

Henri Papath

unread,
Jan 15, 2013, 11:41:07 AM1/15/13
to fo-d...@googlegroups.com
I just tried on Vista SP2 X86 VS2010 and i get the attached image.
I clode, build and run with Dicom Dump in Examples as startup project. 
Very strange...
foMR.png

Henri Papath

unread,
Jan 17, 2013, 1:58:02 AM1/17/13
to fo-d...@googlegroups.com
Hi Mahesh,

May i ask if it is possible for you to upload/attach a zip here with the binaries of your DicomDump project (debug folder) so i could test it?

Thanks in advance
Best regards

Henri

Mahesh Dubey

unread,
Jan 17, 2013, 2:17:20 AM1/17/13
to fo-d...@googlegroups.com
Attached the binary of dicom dump.

Mahesh
Dicom Dump.zip

Henri Papath

unread,
Jan 17, 2013, 9:18:08 AM1/17/13
to fo-d...@googlegroups.com
Even with these binaries, I still get the same image as the one i posted before.
I tried on another PC also (Windows7 X86).
I double checked the image.It renders correctly with a dicom viewer (microDicom)

Really strange...


Mahesh Dubey

unread,
Jan 17, 2013, 9:31:22 AM1/17/13
to fo-d...@googlegroups.com
What is the localization (Encoding)  of u r machine ?? I suspect the double pixel spacing value is not parsing correctly. Just to confirm try to open other images and see whether it is displaying properly or not.

Mahesh

Henri Papath

unread,
Jan 17, 2013, 10:10:18 AM1/17/13
to fo-d...@googlegroups.com
YES !
You are correct!
I dont' believe it could never come across my mind...

My localization was Greek. I switched to US and the image renders corectly!


Henri Papath

unread,
Jan 18, 2013, 8:18:26 AM1/18/13
to fo-d...@googlegroups.com
Hi Mahesh,

Could you guide me to the point in code where you located the issue?

Mahesh Dubey

unread,
Jan 19, 2013, 1:11:49 AM1/19/13
to fo-d...@googlegroups.com
Hello;
           I spot the issue by just carefully seeing the screenshot of the image you attached in your last post.
There are various attributes which has to be considered while rendering the dicom image. By seeing the screenshot I  suspect that there is a problem in applying modality LUT (why modality lut only ?  Here your experience and knowledge of dicom imaging plays a role :) ) 

These modality LUT (rescale slope and intercept ) parsed in double by the toolkit, Now in my machine it is parsing correctly but in your machine it is having the problem, so which affect this parsing ? The answer is regional setting of the OS (culture)

 Well this is the bug in the toolkit, parsing of the values must be independent of the regional setting i.e. invariant culture, Will you please report this bug on the git hub ? Also mark the post as  answered if the problem is resolved.

Mahesh

Henri Papath

unread,
Jan 19, 2013, 1:40:08 AM1/19/13
to fo-d...@googlegroups.com
Thank you Mahesh.

Reply all
Reply to author
Forward
0 new messages