ct_philips.py extractor fails for Philips Brilliance 16P CT scanner
For the only example I have from this type of scanner the extractor fails because the Acquisition DateTime
is blank for each acquisition in the dose summary object.
Comments (10)
-
reporter -
reporter Is it a good idea to configure
get_date_time
to return nothing if it encounters aValueError
? Would it be better to try and catch the error in the calling routine? Any thoughts @edmcdonagh? -
I think returning nothing probably is the best way to do it. It is consistent with the other
get
functions.We'd need to make the same change for the other
date_time
functions. -
reporter Modifed datetime routines to make them return
None
if there is aValueError
encountered. References issue#500→ <<cset 963b0a36c5cf>>
-
reporter Added a catch for
TypeError
to prevent a missing datetime value from preventing import. References issue#500→ <<cset 43f4fbdd2378>>
-
reporter - changed status to resolved
The two commits solve this problem - the Philips Brilliance 16P study with empty Acquisition DateTime imports without a problem. I can also confirm that studies from the Philips Brilliance 64 continue to import correctly.
-
reporter Added anonymised Philips Brilliance 16P CT scanner enhanced structured report file. References issue
#500→ <<cset c88e8ea48bd7>>
-
Adding a very basic test to ensure sample Philips SC imports - fails with current develop. Refs
#500→ <<cset b31b72c3ce9e>>
-
Adding ref
#500to changes→ <<cset 7d1e5e9f136f>>
-
Issue
#478was marked as a duplicate of this issue. - Log in to comment
I have fixed this on my local system by altering
get_date_time
in thedcmdatetime.py
file. This routine currently fails if the contents of the tag are blank. A tweak is also required in_ctradiationdose
within thect_philips.py
file.Altering
get_date_time
to the following fixes the first problem:_ctradiationdose
needs to have atry
put around the microsecond calculation code: