3.10.1.5.1.7.1.1. opengate.contrib.tps.ionbeamtherapy

3.10.1.5.1.7.1.1.1. Attributes

logger

3.10.1.5.1.7.1.1.2. Classes

SpotInfo

LayerInfo

BeamInfo

BeamsetInfo

This class reads a DICOM 'RT Ion Plan Storage' file and collects related information such as TPS dose files.

TreatmentPlanSource

3.10.1.5.1.7.1.1.3. Functions

is_close(x, y[, eps])

sequence_check(obj, attr[, nmin, nmax, name])

spots_info_from_txt(txtFile, ionType, beam_nr)

check_plan_tag(txt_line, tag)

get_spots_from_beamset(beamset)

get_spots_from_beamset_beam(beamset, beam_nr)

3.10.1.5.1.7.1.1.4. Module Contents

opengate.contrib.tps.ionbeamtherapy.logger[source]
opengate.contrib.tps.ionbeamtherapy.is_close(x, y, eps=1e-06)[source]
opengate.contrib.tps.ionbeamtherapy.sequence_check(obj, attr, nmin=1, nmax=0, name='object')[source]
opengate.contrib.tps.ionbeamtherapy.spots_info_from_txt(txtFile, ionType, beam_nr)[source]
opengate.contrib.tps.ionbeamtherapy.check_plan_tag(txt_line, tag)[source]
opengate.contrib.tps.ionbeamtherapy.get_spots_from_beamset(beamset)[source]
opengate.contrib.tps.ionbeamtherapy.get_spots_from_beamset_beam(beamset, beam_nr)[source]
class opengate.contrib.tps.ionbeamtherapy.SpotInfo(xiec, yiec, w, e)[source]

Bases: object

xiec[source]
yiec[source]
w[source]
energy[source]
particle_name = None[source]
beamFraction = None[source]
t0 = None[source]
t1 = None[source]
get_msw(t0, t1)[source]
class opengate.contrib.tps.ionbeamtherapy.LayerInfo(ctrlpnt, j, cumsumchk=[], verbose=False, keep0=False)[source]

Bases: object

_cp[source]
x[source]
y[source]
property energy[source]
property tuneID[source]
property npainting[source]
property mswtot[source]
property nspots[source]
property weights[source]
property spots[source]
get_spots(t0=None, t1=None)[source]
class opengate.contrib.tps.ionbeamtherapy.BeamInfo(beam, i, override_number, keep0=False)[source]

Bases: object

_dcmbeam[source]
_warnings[source]
_icp0[source]
_beam_number_is_fishy[source]
_index[source]
_layers[source]
GetAndClearWarnings()[source]
property FinalCumulativeMetersetWeight[source]
property PatientSupportAngle[source]
property patient_angle[source]
property IsoCenter[source]
property Name[source]
property Number[source]
property name[source]
property number[source]
property RadiationType[source]
property gantry_angle[source]
property TreatmentMachineName[source]
property SnoutID[source]
property SnoutPosition[source]
property NumberOfRangeModulators[source]
property RangeModulatorIDs[source]
property NumberOfRangeShifters[source]
property RangeShifterIDs[source]
property NumberOfEnergies[source]
property nlayers[source]
property layers[source]
property nspots[source]
property mswtot[source]
property PrimaryDosimeterUnit[source]
class opengate.contrib.tps.ionbeamtherapy.BeamsetInfo(rpfp)[source]

Bases: object

This class reads a DICOM ‘RT Ion Plan Storage’ file and collects related information such as TPS dose files. It does NOT (yet) try to read a reffered structure set and/or CT images. This acts as a wrapper (all DICOM access on the plan file happens here). This has a few advantages over direct DICOM access in the other modules: * we can deal with different “DICOM dialects” here; some TPSs may store their plans in different ways. * if ‘private tags’ need to be taken into account then we can also do that here. * We can make a similar class, with the same attributes, for a treatment plan stored in a different format, e.g. for research, commissioning or QA purposes.

Then the rest of the code can work with that in the same way.

patient_attrs = ['Patient ID', 'Patient Name', 'Patient Birth Date', 'Patient Sex'][source]
plan_req_attrs = ['RT Plan Label', 'SOP Instance UID', 'Referring Physician Name', 'Plan Intent'][source]
plan_opt_attrs = ['Operators Name', 'Reviewer Name', 'Review Date', 'Review Time'][source]
plan_attrs[source]
bs_attrs = ['Number Of Beams', 'RT Plan Label', 'Prescription Dose', 'Target ROI Name', 'Radiation Type',...[source]
_warnings[source]
_beam_numbers_corrupt = False[source]
_rp[source]
_rpfp[source]
_rpdir[source]
_rpuid[source]
_dose_roiname = None[source]
_dose_roinumber = None[source]
_beams[source]
GetAndClearWarnings()[source]
__getitem__(k)[source]
_chkrp()[source]
property mswtot[source]
property name[source]
property fields[source]
property beams[source]
property uid[source]
property beam_angles[source]
property beam_names[source]
property beam_numbers[source]
property Nfractions[source]
property target_ROI_name[source]
property target_ROI_number[source]
property prescription_dose[source]
property plan_label[source]
property sanitized_plan_label[source]
property patient_info[source]
property plan_info[source]
property bs_info[source]
__repr__()[source]
class opengate.contrib.tps.ionbeamtherapy.TreatmentPlanSource(name, sim)[source]
name[source]
rotation[source]
translation = [0, 0, 0][source]
spots = None[source]
beamline_model = None[source]
n_sim = 0[source]
sim[source]
set_particles_to_simulate(n_sim)[source]
set_spots(spots)[source]
set_spots_from_rtplan(rt_plan_path, beam_nr=1)[source]
set_beamline_model(beamline)[source]
initialize_tpsource(flat_generation=False, activity=False)[source]
_sample_n_particles_spots(flat_generation=False)[source]
_get_pbs_position(spot)[source]
_get_pbs_rotation(spot)[source]