[Insight-users] Problem with writing DICOM using KeepOriginalUID
Mathieu Malaterre
mathieu.malaterre at gmail.com
Tue Apr 21 06:03:08 EDT 2009
Hi Martin,
On Tue, Apr 21, 2009 at 6:16 AM, Martin Kavec <martin.kavec at gmail.com> wrote:
> Hi all,
>
> I have a problem with the code below with ITK-3.12 (gdcm1). What I am trying
> to do is to add another series into the existing study after the images have
> been processed. The code below is largely based on DicomResample written by
> Bill Lorensen. Shortly, in order to add a new series to an existing study,
> the series and frame of reference UIDs are extrected from the
> existing "template" series and for each new slice these are added to the
> metadata dictionary. Additionally, series number, description and several
> other tags are updated KeepOriginalUIDOn is also passed to the gdcm IO.
>
> Now the problem is that with the KeepOriginalUIDOn the resulting dicoms are
> recognized by Osirix as a new series of the original study, but the series
> has few 2-3/182 slices missing, despite of the correct number of the files
> produced. The things work well when KeepOriginalUIDOn is commented out with
> the penalty that the output dicom images are generated as new study, when
> imported to Osirix.
>
> I was hoping that someone (Mathieu our dicom guru) may have some insight what
> could be wrong.
Code is looking alright.
Could you generate the two series :
1. the working one but with the new Series UID
2. the non-working one
Then run 'gdcminfo' on each of those generated files and send me the
log file. If you are using gdcm 2.0.10 you cannot specify directory
instead you should do someting like that:
find my_working_dicom/ -type f -exec gdcminfo {} \; > working.log
If you are compiling gdcm 2.x from svn trunk you can specify a top
level directory:
gdcminfo my_working_dicom/ > working.log
This will not contains any kind of patient related information (only
meta information about images stored).
--
Mathieu
Ref:
http://apps.sourceforge.net/mediawiki/gdcm/index.php?title=GDCM_Release_2.0#GDCM_2.0.10_.282008.2F11.2F18.29
More information about the Insight-users
mailing list