Beam delivery timing

Hi,

I’m trying to calculate the total delivery time for a plan i.e. irradiation time + scanning time + energy layer switching time.

Starting with the example provided in “run_PBSDeliveryTimings.py”, the outputs using

print(plan_with_timings._beams[0]._layers[0]._dict_)

give spot positions (x,y), mu, start times, irradiation duration etc. this irradiation time however is only for each spot? I noted for successive layers the start time only indicates 10ms between layers (i.e. taking the start time + irradiation time, compared with the start time of the next layer) which doesn’t account for the energy layer switching time? (default 0.6s according to the SimpleBeamDeliveryTimings class)

Is there a way I can get the total beam delivery time?

Thanks,

Jacinta

I think I might’ve managed to get it, please let me know if this works correctly -

I created another function in the SimpleBeamDeliveryTimingsclass to return accumul_layer_time as previously defined i.e. accumul_layer_time += np.sum(scanningTime) + np.sum(irradiationTime)

Calling this function gives me a float