mythos.observables.pitch
Pitch observable.
Attributes
Classes
Computes the average pitch angle in radians for each state. |
Functions
|
Computes the pitch given an average pitch angle in radians. |
|
Computes the pitch angle between adjacent base pairs. |
Module Contents
- mythos.observables.pitch.TARGETS
- mythos.observables.pitch.compute_pitch(avg_pitch_angle: float) float[source]
Computes the pitch given an average pitch angle in radians.
- mythos.observables.pitch.single_pitch_angle(quartet: jax.numpy.ndarray, base_sites: jax.numpy.ndarray, back_sites: jax.numpy.ndarray, displacement_fn: collections.abc.Callable) mythos.utils.types.ARR_OR_SCALAR[source]
Computes the pitch angle between adjacent base pairs.
- mythos.observables.pitch.single_pitch_angle_mapped
- class mythos.observables.pitch.PitchAngle[source]
Bases:
mythos.observables.base.BaseObservableComputes the average pitch angle in radians for each state.
The pitch is defined by (2*pi) / <angle> where <angle> is the average angle between adjacent base pairs across states
- Parameters:
quartets – a (n_quartets, 2, 2) array containing the pairs of adjacent base pairs for which to compute pitch angles
displacement_fn – a function for computing displacements between two positions
- quartets: jax.numpy.ndarray
- displacement_fn: collections.abc.Callable
- __call__(trajectory: mythos.simulators.io.SimulatorTrajectory) mythos.utils.types.ARR_OR_SCALAR[source]
Calculate the average pitch angle in radians.
- Parameters:
trajectory (jd_traj.Trajectory) – the trajectory to calculate the pitch for
- Returns:
the average pitch angle in radians for each state, so expect a size of (n_states,)
- Return type:
jd_types.ARR_OR_SCALAR