binny.nz package#
Submodules#
- binny.nz.calibration module
- binny.nz.models module
gamma_distribution()gaussian_distribution()gaussian_mixture_distribution()lognormal_distribution()luminosity_function_distribution()schechter_like_distribution()shifted_smail_distribution()skew_normal_distribution()smail_like_distribution()student_t_distribution()tabulated_distribution()tophat_distribution()
- binny.nz.registry module
Module contents#
- binny.nz.available_models() list[str]#
Lists the supported redshift-distribution model names.
- Returns:
A sorted list of registry keys that can be passed to
get_modelornz_model.
- binny.nz.get_model(name: str) Callable[[...], ndarray[tuple[Any, ...], dtype[float64]]]#
Gets a registered redshift-distribution model by name.
- Parameters:
name – Model name. The lookup is case-insensitive.
- Returns:
The callable model associated with
name.- Raises:
ValueError – If
nameis not a known model key.
- binny.nz.nz_model(name: str, z: Any, /, **params: Any) ndarray[tuple[Any, ...], dtype[float64]]#
Evaluates a named redshift-distribution model on a redshift grid.
This is a convenience wrapper around
get_modelthat also ensureszand the returned array arenp.float64.- Parameters:
name – Model name. Must be one of
available_models().z – Redshift grid. Any array-like input accepted by
np.asarray.**params – Model-specific keyword parameters forwarded to the model.
- Returns:
The model evaluated on
zas a float64 NumPy array.- Raises:
ValueError – If
nameis not a known model key.