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 IntensityBuilder(particles, kinematics, phsp_data=None)[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 (Optional[dict]) – A phase space event collection, required if a normalization of the Intensity is performed.

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 HelicityAmplitudeGeneratorXML)

Return type

IntensityTF

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.

Return type

None