rickardcronholm / CTC_auto

A python module that converts DICOM CT data to voxalized phantom for the EGSnrc Monte Carlo code DOSXYZnrc
Other
8 stars 6 forks source link

AttributeError: Dataset does not have attribute 'ContourSequence’ #5

Closed rickardcronholm closed 6 years ago

rickardcronholm commented 7 years ago

An instance of CTC_auto produces the following error dialogue:

Traceback (most recent call last): File "/home/nftang/MCQA/CTC_auto.py", line 315, in main structures[cnt].contour = CTCtools.getContour(RS.ROIContourSequence[elem], ct_zmesh, abs(orientCT[1]), True) File "/home/nftang/MCQA/CTCtools.py", line 250, in getContour for i in range(0, len(RSData.ContourSequence)): File "/usr/lib/python2.7/dist-packages/dicom/dataset.py", line 256, in getattr "'{0:s}'.".format(name)) AttributeError: Dataset does not have attribute 'ContourSequence’.

rickardcronholm commented 6 years ago

Issue solved in 0.6. Structures lacking the 'ContourSequence’ Attribute are now skipped