mythos.observables.base

Base class for observables.

Attributes

ERR_RIGID_BODY_TRANSFORM_FN_REQUIRED

Classes

BaseObservable

Base class for observables.

Functions

local_helical_axis_with_norm(→ jax.numpy.ndarray)

Computes the norm and normalized local helical axis defined by two base pairs.

local_helical_axis(→ jax.numpy.ndarray)

Computes the normalized local helical axis defined by two base pairs.

get_duplex_quartets(→ jax.numpy.ndarray)

Computes all quartets (i.e. pairs of adjacent base pairs) for a duplex of a given size.

Module Contents

mythos.observables.base.ERR_RIGID_BODY_TRANSFORM_FN_REQUIRED = 'rigid_body_transform_fn must be provided'
class mythos.observables.base.BaseObservable[source]

Base class for observables.

rigid_body_transform_fn: collections.abc.Callable
__call__(trajectory: mythos.simulators.io.SimulatorTrajectory) jax.numpy.ndarray[source]

Calculate the observable.

mythos.observables.base.local_helical_axis_with_norm(quartet: jax.numpy.ndarray, base_sites: jax.numpy.ndarray, displacement_fn: collections.abc.Callable) jax.numpy.ndarray[source]

Computes the norm and normalized local helical axis defined by two base pairs.

mythos.observables.base.local_helical_axis(quartet: jax.numpy.ndarray, base_sites: jax.numpy.ndarray, displacement_fn: collections.abc.Callable) jax.numpy.ndarray[source]

Computes the normalized local helical axis defined by two base pairs.

mythos.observables.base.get_duplex_quartets(n_nucs_per_strand: int) jax.numpy.ndarray[source]

Computes all quartets (i.e. pairs of adjacent base pairs) for a duplex of a given size.

Parameters:

n_nucs_per_strand (int) – number of nucleotides on each strand

Returns:

array of all quartets

Return type:

jnp.ndarray