openghg_inversions.rhime.sampling#
RHIME sampling helpers.
- class openghg_inversions.rhime.sampling.RhimeSampler(*, draws: int = 1000, burn: int = 0, tune: int = 1000, chains: int = 4, nuts_sampler: Literal['pymc', 'nutpie', 'numpyro', 'blackjax'] | str = 'pymc', progressbar: bool = False, sample_kwargs: dict[str, Any] | None = None, sample_prior_predictive: bool | int = True, sample_posterior_predictive: bool | Sequence[str] = ('y',), posterior_predictive_kwargs: dict[str, Any] | None = None)#
Bases:
objectPyMC sampler configuration and execution for RHIME models.
- Parameters:
draws – Number of post-tuning draws requested from PyMC.
burn – Number of draws to discard from each chain after sampling.
tune – Number of PyMC tuning draws.
chains – Number of MCMC chains.
nuts_sampler – PyMC NUTS backend name.
progressbar – Whether PyMC progress output should be shown.
sample_kwargs – Extra keyword arguments forwarded to
pm.sample.sample_prior_predictive – Whether to append prior predictive draws.
sample_posterior_predictive – Whether to append posterior predictive draws, or variable names to sample.
posterior_predictive_kwargs – Extra keyword arguments forwarded to
pm.sample_posterior_predictive.