[Tutor] DICOM Header

Bill Sconce sconce at in-spec-inc.com
Thu Feb 22 21:07:34 CET 2007


On Thu, 22 Feb 2007 11:56:19 -0700
"Andrew Liimatta" <Andrew.Liimatta at hsc.utah.edu> wrote:

> 
> Hello,
> 
> 
> I am having a hard time figuring something out.
> 
> I have Files that are written in DICOM format.  I want to be able
> to pull out select elements from the header of these files
> 
> I have a dictionary file that contains enteries like this.
> 
> dicomdict = {
> # meta tags
> (0x0002,0x0001):('OB', "FileMetaInformationVersion",             '1', ''),
> (0x0002,0x0002):('UI', "MediaStorageSOPClassUID",                '1', ''),
> (0x0002,0x0003):('UI', "MediaStorageSOPInstanceUID",             '1', ''),
> (0x0002,0x0010):('UI', "TransferSyntaxUID",                      '1', ''),
> (0x0002,0x0012):('UI', "ImplementationClassUID",                 '1', ''),
> (0x0002,0x0013):('SH', "ImplementationVersionName",              '1', ''),
> (0x0002,0x0016):('AE', "SourceApplicationEntityTitle",           '1', ''),
> (0x0002,0x0100):('UI', "PrivateInformationCreatorUID",           '1', ''),
> (0x0002,0x0102):('OB', "PrivateInformation",                     '1', ''),
> }
> 
> I do understand how to use the dictionary file to help parse out the
> element that I want from the DICOM file.  For example how do I only grab
> the SourceApplicationEntityTitle from the DICOM header.
> 
> Any help would be appreciated.


I'd like to help.  (I have an interest in DICOM files myself, for a
client's needs.)

Unfortunately, I do NOT yet have knowledge of how a DICOM file is
made.  (This is an "opportunity".)  So first we should ask a couple
of questions -- for everyone's benefit, since the method of attack
on your problem has merit beyond DICOM files.

1. Is the dictionary file which you have part of the DICOM file?

2. Or is the dictionary file which you have part of the description
   of what you wish to EXTRACT from the DICOM file?

I could start with a suggested solution, since I think your status
is "2." (and that you mean "do NOT understand how to use the dictionary")
but I might be wrong, so it's better to nail down your requirement first.
Feel free to write me directly if it's going to get into a lot of DICOM
details.

-Bill




More information about the Tutor mailing list