Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#1663 closed defect (fixed)

DICOM value error 50 times but 2 found

Reported by: Elaine Meng Owned by: Tom Goddard
Priority: moderate Milestone:
Component: Volume Data Version:
Keywords: Cc:
Blocked By: Blocking:
Notify when closed: Platform: all
Project: ChimeraX

Description

Narrowed down the mouse data to at least one example, attached as zip file. (It may still be a good idea for you to try downloading some of these full studies because you can see possible issues with nonunique or nonhelpful model names. One reason I liked using filename is that the user can see which is which, and they are unique if you also retain the directory hierarchy.)

open dicom/tcia/Mouse-Astrocytoma/TVD_GBM_IC1_070610_19 format dicomTraceback (most recent call last):

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/cmd_line/tool.py", line 252, in execute

cmd.run(cmd_text)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/commands/cli.py", line 2615, in run

result = ci.function(session, kw_args)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/commands/open.py", line 41, in open

from_database=from_database, ignore_cache=ignore_cache, kw))

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/commands/open.py", line 117, in open

models = handle_unknown_kw(session.models.open, paths, format=format, name=name, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/commands/open.py", line 62, in handle_unknown_kw

return f(*args, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/models.py", line 598, in open

session, filenames, format=format, name=name, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/core/io.py", line 456, in open_multiple_data

models, status = open_func(session, paths, mname, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/volume.py", line 3450, in open_map_format

return open_map(session, stream, name=name, format=format, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/volume.py", line 3066, in open_map

verbose = kw.get('verbose'))

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/fileformats.py", line 141, in open_file

data = module.open(apath, kw)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/init.py", line 20, in open

return dicom_grids(paths, log = log, verbose = verbose)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_grid.py", line 21, in dicom_grids

series = find_dicom_series(paths, verbose = verbose)

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_format.py", line 24, in find_dicom_series

series.extend(dicom_file_series(dpaths, verbose = verbose))

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_format.py", line 53, in dicom_file_series

s.order_slices()

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_format.py", line 150, in order_slices

self._validate_time_series()

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_format.py", line 168, in _validate_time_series

% (self.num_times, len(tset), files[0].path, len(files)))

ValueError: DICOM series says it has 50 times but 2 found, /Users/meng/Desktop/dicom/tcia/Mouse-Astrocytoma/TVD_GBM_IC1_070610_19/09-27-2010-338722691-GBMintracranial-369.3/701-3D12SlDyn22sAPTR9TE3-427.3/000009.dcm... 24 files.

ValueError: DICOM series says it has 50 times but 2 found, /Users/meng/Desktop/dicom/tcia/Mouse-Astrocytoma/TVD_GBM_IC1_070610_19/09-27-2010-338722691-GBMintracranial-369.3/701-3D12SlDyn22sAPTR9TE3-427.3/000009.dcm... 24 files.

File "/Users/meng/Desktop/ChimeraX.app/Contents/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/chimerax/map/data/dicom/dicom_format.py", line 168, in _validate_time_series
% (self.num_times, len(tset), files[0].path, len(files)))

See log for complete Python traceback.

Attachments (1)

TVD_GBM_IC1_070610_19.zip (10.3 MB ) - added by Elaine Meng 7 years ago.

Change History (3)

by Elaine Meng, 7 years ago

Attachment: TVD_GBM_IC1_070610_19.zip added

comment:1 by Tom Goddard, 7 years ago

Resolution: fixed
Status: assignedclosed

When opening a partial time series (files present for only 2 of 50 times) I made ChimeraX issue a warning and open the available time images instead of an error.

Is your comment in the description of this ticket suggesting using the "file name" for the model name? What do you mean by the file name, I guess the directory where series is. The series with the error in this ticket is at this path

TVD_GBM_IC1_070610_19/09-27-2010-338722691-GBMintracranial-369.3/701-3D12SlDyn22sAPTR9TE3-427.3/000001.dcm

The current model name ChimeraX uses is

3D_12Sl_Dyn22s_AP_TR9/TE3 20100927

which is the Series Description and date. Are you saying you would prefer the model name be the directory, in this case,

701-3D12SlDyn22sAPTR9TE3-427.3

or path starting from the dicom directory that was opened?

TVD_GBM_IC1_070610_19/09-27-2010-338722691-GBMintracranial-369.3/701-3D12SlDyn22sAPTR9TE3-427.3

Many of the DICOM directory names are even worse (35 digit hexadecimal strings), and many of the series descriptions are better than this example.

comment:2 by Tom Goddard, 7 years ago

If you have specific DICOM model naming suggestions please make a ticket specifically for that.

Note: See TracTickets for help on using tickets.