pyanno4rt.optimization.components._equivalent_uniform_dose
Equivalent uniform dose (EUD) component.
Overview
Equivalent uniform dose (EUD) component class. |
|
Compute the component value. |
|
Compute the component gradient. |
Classes
- class pyanno4rt.optimization.components._equivalent_uniform_dose.EquivalentUniformDose(target_eud=None, volume_parameter=None, embedding='active', weight=1.0, rank=1, bounds=None, link=None, identifier=None, display=True)[source]
Bases:
pyanno4rt.optimization.components.ConventionalComponentClassEquivalent uniform dose (EUD) component class.
This class provides methods to compute the value and the gradient of the EUD component.
- Parameters:
target_eud (int or float) – Target value for the EUD.
volume_parameter (int or float) – Dose-volume effect parameter.
embedding ({'active', 'passive'}, default='active') – Mode of embedding for the component. In ‘passive’ mode, the component value is computed and tracked, but not considered in the optimization problem, unlike in ‘active’ mode.
weight (int or float, default=1.0) – Weight of the component function.
rank (int, default=1) – Rank of the component in the lexicographic order.
bounds (None or list, default=None) – Constraint bounds for the component.
link (None or list, default=None) – Other segments used for joint evaluation.
identifier (None or str, default=None) – Additional string for naming the component.
display (bool, default=True) – Indicator for the display of the component.
- parameter_value
Value of the component parameters.
- Type:
list
Overview
Methods compute_value(*args)Return the component value from the jitted ‘compute’ function.
compute_gradient(*args)Return the component gradient from the jitted ‘differentiate’ function.
Members
- compute_value(*args)[source]
Return the component value from the jitted ‘compute’ function.
- Parameters:
*args (tuple) – Keyworded parameters, where args[0] must be the dose vector(s) to evaluate.
- Returns:
Value of the component function.
- Return type:
float
- compute_gradient(*args)[source]
Return the component gradient from the jitted ‘differentiate’ function.
- Parameters:
*args (tuple) – Keyworded parameters, where args[0] must be the dose vector(s) to evaluate and args[1] the corresponding segment(s).
- Returns:
Value of the component gradient.
- Return type:
ndarray
Functions
- pyanno4rt.optimization.components._equivalent_uniform_dose.compute(dose, parameter_value)
Compute the component value.
- Parameters:
dose (tuple) – Values of the dose in the segment(s).
parameter_value (list) – Value of the component parameters.
- Returns:
Value of the component function.
- Return type:
float
- pyanno4rt.optimization.components._equivalent_uniform_dose.differentiate(dose, parameter_value, number_of_voxels, segment_indices)
Compute the component gradient.
- Parameters:
dose (tuple) – Values of the dose in the segment(s).
parameter_value (list) – Value of the component parameters.
number_of_voxels (int) – Total number of dose voxels.
segment_indices (tuple) – Indices of the segment(s).
- Returns:
Value of the component gradient.
- Return type:
ndarray