bilby.core.sampler.dynesty_utils.apply_boundaries_

bilby.core.sampler.dynesty_utils.apply_boundaries_(u_prop, periodic, reflective)[source]

Apply the periodic and reflective boundaries and test if we are inside the unit cube.

Parameters:
u_prop: np.ndarray

The proposed point in the unit hypercube space.

periodic: np.ndarray

Indices of the parameters with periodic boundaries.

reflective: np.ndarray

Indices of the parameters with reflective boundaries.

Returns:
[np.ndarray, None]:

Either the remapped proposed point, or None if the proposed point lies outside the unit cube.