aimz.ImpactModel.sample_prior_predictive_on_batch#

ImpactModel.sample_prior_predictive_on_batch(X, *, num_samples=1000, rng_key=None, return_sites=None, return_datatree=True, **kwargs)[source]#

Draw samples from the prior predictive distribution.

Parameters:
  • X (ArrayLike) – Input data. The leading axis is the sample axis.

  • num_samples (int) – The number of samples to draw.

  • rng_key (Array | None) – A pseudo-random number generator key. By default, an internal key is used and split as needed.

  • return_sites (str | Iterable[str] | None) – Names of variables (sites) to return. If None, samples param_output and deterministic sites.

  • return_datatree (bool) – If True, return a DataTree; otherwise return a dict.

  • **kwargs (object) – Additional arguments passed to the model.

Returns:

Prior predictive samples. Posterior samples are included if available.

Raises:

TypeError – If param_output is passed as an argument.

Return type:

xr.DataTree | dict[str, npt.NDArray]