amplitude

Amplitude module for the helicity formalism.

Its responsibility is the construction of complicated helicity formalism amplitude models using a recipe (see IntensityBuilder). These models are encapsulated in an IntensityTF class, which can be evaluated as a regular callable.

class DynamicsProperties[source]

Bases: tuple

Data structure representing dynamic properties.

property inv_mass_name

Alias for field number 3

property inv_mass_name_prod1

Alias for field number 4

property inv_mass_name_prod2

Alias for field number 5

property meson_radius

Alias for field number 6

property orbit_angular_momentum

Alias for field number 0

property resonance_mass

Alias for field number 1

property resonance_width

Alias for field number 2

class IntensityBuilder(particles, kinematics, phsp_data=array([], dtype=float64))[source]

Bases: object

Builds Intensities from helicity formalism recipe files.

Parameters
  • particles (dict) – Contains info of various particles.

  • kinematics (HelicityKinematics) – A helicity kinematics instance. Note that this kinematics instance will be modified in the process.

  • phsp_data (ndarray) – A phase space event collection, required if a normalization of the Intensity is performed.

create_dynamics(decaying_state_name, dynamics_properties)[source]

Create a dynamics function callable.

Parameters
Return type

Callable

create_element(recipe)[source]

Create a computation element from the recipe.

The recipe can only contain names registered in the pool of known element builders.

Parameters

recipe (dict) –

Return type

Callable

create_intensity(recipe)[source]

Create an IntensityTF instance based on a recipe.

Parameters

recipe (dict) – Contains builder instructions. These recipe files can be generated via the expert system (see HelicityAmplitudeGenerator)

Return type

IntensityTF

get_normalization_data()[source]

Return phase space dataset and its volume.

Return type

Tuple[dict, float]

get_parameter(name)[source]
Parameters

name (str) –

Return type

Variable

get_particle_infos(particle_name)[source]

Obtain particle information identified by its name.

Parameters

particle_name (str) –

Return type

dict

register_dynamics_builder(dynamics_name, builder)[source]

Register custom dynamics function builders.

Parameters
Return type

None

register_parameter(name, value)[source]
Parameters
Return type

Variable

class IntensityTF(tf_model, parameters)[source]

Bases: tensorwaves.interfaces.Function

Implementation of the Function interface using tensorflow.

Initialize the intensity based on a tensorflow model.

Parameters
  • tf_model (Callable) – A callable with potential tensorflow code.

  • parameters (Dict[str, Variable]) – The collection of parameters of the model.

__call__(dataset)[source]

Evaluate the Intensity.

Parameters

dataset (Dict[str, ndarray]) – Contains all required kinematic variables.

Return type

ndarray

Returns

List of intensity values.

property parameters

Get dict of parameters.

Return type

dict

update_parameters(new_parameters)[source]

Update the collection of parameters.

Parameters

new_parameters (dict) –

Return type

None