VarianAPIs / Varian-Code-Samples

Code samples for ESAPI and other Varian APIs and web services.
MIT License
112 stars 105 forks source link

Dose metrics from HyperArc #122

Open DerekLiuMedPhys opened 2 years ago

DerekLiuMedPhys commented 2 years ago

Greetings.

Is the ESAPI able to access HyperArc-related dose metrics, such as Paddick, RTOG CI, HI, and GI?

Our planners would like to track these number when iterating during optimization. For small number targets, we can manually record them easily. But this gets difficult with large number of targets.

Thanks

Kiragroh commented 2 years ago

Hi. This is not a problem. You can automatically contour ring structures for the necessary calculations of multiple targets. After the calculations in my script the help structure are deleted.

On my GitHub is a screenshot of the script: https://github.com/Kiragroh/ESAPI_Showcase_ComplexScripts

DerekLiuMedPhys commented 2 years ago

Thank you. The script(s) look very impressive. They would be really helpful if we need to code the calculations.

We were hoping it would be a simple look-up, as Eclipse does calculate them for hyperarc plans.

Thanks again

Kiragroh commented 2 years ago

I know from Brainlab elements that this kind of calculations are dynamically. Therefore my scripts works this way and I think that this would be the same for HyperArc.

But why dynamically? You need to check whether a Isodose surpasses your predefined rings. If yes: your rings has to be a little big bigger or you can't calculate the indices. If your help rings are too big you have the problem of interference with other ptv isodoses. To find the right balance a dynamic algorithm is needed.

If it where a simple look up it would be evil to hide a quality check feature behind a paywall because you can create HyperArc similar plans with scripting or manual planning if you know the publication that HyperArc is based on (Thomas Clark 2012 - step to step guide for the planning steps are published too)

Radiotherapy in Managing Brain Metastases A Case-Based Approach (chapter 17 - published 2020)