Use force=True to force reading in rt_utils/image_helper.py (load_dcm_images_from_path )
xfuren opened this issue · 3 comments
Sometime we have not-so-standard DICOM files....
Suggestion...
ds = dcmread(os.path.join(root, file),force=True)
if hasattr(ds, 'ImageOrientationPatient'):
series_data.append(ds)
Hi xfuren, we haven't dealt with this since we dont like potentially going against the DICOM standard but we can add an optional parameter to set this
Maybe Ihave not-so-standard DICOM files,But
ds = dcmread(os.path.join(root, file),force=True)
still:
dicom_path exists: True
RT Structure file found: /root/autodl-tmp/datasets/CBCT/001925CBCT/RS.001925.dcm
Error reading RT Structure /root/autodl-tmp/datasets/CBCT/001925CBCT/RS.001925.dcm: No DICOM Images found in input path.
I also encountered the error:
AttributeError: 'FileDataset' object has no attribute 'ImageOrientationPatient'
from an RTSTRUCT file generated by varian eclipse 16.1. I thought those were pretty standard. No?