Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Field SourceToSurfaceDistance Missing #575

Open
uyousafzai54 opened this issue Aug 12, 2022 · 5 comments
Open

[BUG] Field SourceToSurfaceDistance Missing #575

uyousafzai54 opened this issue Aug 12, 2022 · 5 comments
Labels

Comments

@uyousafzai54
Copy link

Describe the bug
It seems that while trying to adapt/calibrate a phantom DICOM dataset to import in MatRad, the SourceToSurfaceDistance tag is missing.

I hard coded a value of 50 cm assuming its the distance from the jaw but I just wanted to see if there's any reason why specific meta tags would be missing a value. From the comments in the code it seems that all of this info is defined in the first control point sequence and the only value missing for my dataset is the SourceToSurfaceDistance tag.

Therefore, while trying to import an RT plan as part from the phantom dataset, is there specific info I might need to hard code in to calibrate/add missing data for MatRad to generate its .m file?

I can give specific reproduction steps and/or dataset (anonymized and cleared for sharing) if needed.

@wahln
Copy link
Contributor

wahln commented Aug 12, 2022

It seem the tag is only checked here:

'PatientSupportAngle' 'CouchAngle';'SourceToSurfaceDistance' 'SSD'};

SourceToSurfaceDistance (SSD) means the distance from the (virtual) photon source to the patient's surface. It is used to get the correct photon pencil-beam kernel in the SVD algorithm. I am actually not sure why it is necessary here to have the field, as it is commented in this function

%stf(i).ray.SSD = Fields(ia(i)).SSD;

and it is computed in the dose calculation anyways.

So you should be OK with overriding this value in your DICOM RTPlan / changing the code to not obtain this field at all.

@uyousafzai54
Copy link
Author

Sounds good! As an aside, is there any test DICOM dataset for MatRad for simply creating a .mat file that I can use for debugging/understanding the DICOM import process against my dataset?

@wahln
Copy link
Contributor

wahln commented Aug 12, 2022

Unfortunately not really. Particuarly not for RTPlan & RTDose (would be good to have this in a testing pipeline though).

The only thing coming to my mind is the CORT dataset. These are the phantoms/patients within the mat files coming with matRad, and the corresponding DICOMs can be found here: https://academic.oup.com/gigascience/article/3/1/2047-217X-3-37/2682969

@uyousafzai54
Copy link
Author

It seem the tag is only checked here:

'PatientSupportAngle' 'CouchAngle';'SourceToSurfaceDistance' 'SSD'};

SourceToSurfaceDistance (SSD) means the distance from the (virtual) photon source to the patient's surface. It is used to get the correct photon pencil-beam kernel in the SVD algorithm. I am actually not sure why it is necessary here to have the field, as it is commented in this function

%stf(i).ray.SSD = Fields(ia(i)).SSD;

and it is computed in the dose calculation anyways.
So you should be OK with overriding this value in your DICOM RTPlan / changing the code to not obtain this field at all.

Also since you aren't sure why the field is necessary as the line is commented out anyways in [matRad/dicom/matRad_importDicomSteeringPhotons.m](https://github.com/e0404/matRad/blob/3d29b765a9a0a02a593890726102a7d9db907af7/dicom/matRad_importDicomSteeringPhotons.m#L83), should I make a PR to address this?

@wahln
Copy link
Contributor

wahln commented Aug 23, 2022

A PR would be nice (of course add your name to the AUTHORS file as well then in the PR, if it is not already there ;-) ).
If you want to walk the extra mile, you could also introduce it as an optional check (i.e., if the field is there it will be read, otherwise not).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants