[Insight-users] GDCM crashes when reading some dicom images
Mathieu Malaterre
mathieu.malaterre at gmail.com
Fri Apr 25 06:26:14 EDT 2008
On a different subject what anonymizer did you use ? It could not cope
with a bunch of public elements, and inserted a VR=UN when doing the
conversion from Implicit encoding to Explicit encoding.
-Mathieu
On Thu, Apr 24, 2008 at 10:10 PM, Jesús Spínola <jspinola at gmail.com> wrote:
> Hello,
>
> I'm using itk 2.8.1 and I have a problem reading some DICOM images with
> itkGDCMImageIO. For most of images I opened since now, it works ok, but I
> have images from several studies that is not able to open because it crashes
> with a SIGFPE (floating point exception). When debugging, this is the
> message after crashing
>
> Program received signal SIGFPE, Arithmetic exception.
> [Switching to Thread -1223084336 (LWP 6551)]
> 0xb7de14e6 in gdcm::PixelReadConvert::ConvertReArrangeBits () from
> /usr/lib/InsightToolkit/libitkgdcm.so.2.8
>
>
> and the backtrace is the following:
>
>
> #0 0xb7de14e6 in gdcm::PixelReadConvert::ConvertReArrangeBits () from
> /usr/lib/InsightToolkit/libitkgdcm.so.2.8
> #1 0xb7de9c31 in gdcm::PixelReadConvert::ReadAndDecompressPixelData () from
> /usr/lib/InsightToolkit/libitkgdcm.so.2.8
> #2 0xb7dbd69c in gdcm::FileHelper::GetRaw () from
> /usr/lib/InsightToolkit/libitkgdcm.so.2.8
> #3 0xb7dbebf2 in gdcm::FileHelper::GetImageData () from
> /usr/lib/InsightToolkit/libitkgdcm.so.2.8
> #4 0xb7ee1892 in itk::GDCMImageIO::Read () from
> /usr/lib/InsightToolkit/libITKIO.so.2.8
> #5 0x08061964 in itk::ImageFileReader<itk::Image<int, 3u>,
> itk::DefaultConvertPixelTraits<int> >::GenerateData ()
> #6 0xb7a62380 in itk::ProcessObject::UpdateOutputData () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #7 0xb7a1f969 in itk::DataObject::UpdateOutputData () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #8 0xb7a1f770 in itk::DataObject::Update () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #9 0xb7a5ffca in itk::ProcessObject::UpdateLargestPossibleRegion () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #10 0x0805d6c0 in itk::ImageSeriesReader<itk::Image<int, 3u>
> >::GenerateData ()
> #11 0xb7a62380 in itk::ProcessObject::UpdateOutputData () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #12 0xb7a1f969 in itk::DataObject::UpdateOutputData () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #13 0xb7a1f770 in itk::DataObject::Update () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #14 0xb7a60062 in itk::ProcessObject::Update () from
> /usr/lib/InsightToolkit/libITKCommon.so.2.8
> #15 0x0804e0f4 in main ()
>
> To test this problem I've writen a little program I've attached
> (gdcmBug.cpp) reproducing the problem. You can use the following anonymized
> study ( http://hades.udg.edu/~chus/study1.tar.gz ) with some series to test
> this bug. It crashes with any of the images of the study.
>
> I also tried to read the same images with other libraries such as vtk or
> dcmtk and they're able to open the same images successfully.
>
> Assuming ITKINCLUDEDIR is /usr/include/InsightToolkit and ITKLIBDIR is
> /usr/lib/InsightToolkit, the compile command for g++ is the following
>
> g++ -o gdcmBug gdcmBug.o -I. -I/usr/include/InsightToolkit
> -I/usr/include/InsightToolkit/IO -I/usr/include/InsightToolkit/gdcm/src
> -L/usr/lib/InsightToolkit -lITKIO -litkgdcm
>
> To run this test you have to pass by argument the files you want to read.
>
> For example, if you want to read 3 images (im1, im2, im3) from the same
> series:
>
> $>gdcmBug im1 im2 im3
>
> If you want to test with only one single image
>
> $>gdcmbug im1
>
> and so on...
>
> I tested this under Linux Mandriva 2008.0 and Kubuntu Feisty 7.04.
>
> Maybe this bug is resolved in a more recent version of itk, but I don't know
> it. If so, let me know which version has solved this problem.
>
> I hope this test and the images I provided can help to find the problem. I
> have more images to reproduce the problem, if necessary.
>
>
> Thanks in advance!
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>
>
--
Mathieu
More information about the Insight-users
mailing list