Partners in a research project have sent us 44 DICOM datasets exported from a Philips Achieva 3T MRI scanner. Version of the Philips software is 3.2. Each dataset is made of 29 files:
IM_0001 IM_0004 IM_0006 IM_0008 IM_0010
IM_0012 IM_0014 IM_0016 IM_0018 IM_0021
IM_0023 IM_0025 PS_0002 PS_0019 XX_0003
XX_0005 XX_0007 XX_0009 XX_0011 XX_0013
XX_0015 XX_0017 XX_0020 XX_0022 XX_0024
XX_0026 XX_0027 XX_0028 XX_0029
* The IM files are EnhancedMRImageStorage images.
* The PS files are GrayscaleSoftcopyPresentationStateStorage images.
* The XX files are RawDataStorage images.
For all datasets, pydicom works fine on some of the files (IM_0001, PS_0002, XX_0003, IM_0004, XX_0005, IM_0006, XX_0007, ...) but bails out on others (IM_0008, XX_0009, XX_0011, ...):
Python 2.7.3 (default, Sep 26 2013, 20:03:06)
Type "help", "copyright", "credits" or "license" for more information.
>>> IM_0008 = dicom.read_file('IM_0008')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 562, in read_file
dataset = read_partial(fp, stop_when, defer_size=defer_size, force=force)
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 511, in read_partial
stop_when=stop_when, defer_size=defer_size)
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 303, in read_dataset
raw_data_element = de_gen.next()
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 272, in data_element_generator
seq = read_sequence(fp, is_implicit_VR, is_little_endian, length)
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 332, in read_sequence
dataset = read_sequence_item(fp, is_implicit_VR, is_little_endian)
File "/usr/lib/python2.7/dist-packages/dicom/filereader.py", line 351, in read_sequence_item
raise IOError, "No tag to read at file position %05x" % fp.tell()
IOError: No tag to read at file position 4d4c180
$
Is this a known issue? I'm not certain to which extent Enhanced DICOM files are supported but I would expect to at least be able to call dicom.read_file. Should I fill in a bug report? Has anyone else experience with Enhanced DICOM data, especially from Philips Achieva 3.2 machines?