snapshot_step

flipbook.snapshot_step(model_fn: Callable[[ndarray[tuple[Any, ...], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]]], ndarray[tuple[Any, ...], dtype[float64]]], t: _Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | bytes | str | _NestedSequence[complex | bytes | str], chain: _Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | bytes | str | _NestedSequence[complex | bytes | str] | Chain, *, step: int, walkers: str | int | Sequence[int] | ndarray[tuple[Any, ...], dtype[integer[Any]]] = 'all', log_prob: _Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | bytes | str | _NestedSequence[complex | bytes | str] | None = None, param_transform: Callable[[ndarray[tuple[Any, ...], dtype[float64]]], ndarray[tuple[Any, ...], dtype[float64]]] | None = None, vectorized: bool = False, n_jobs: int = 1, chunk_size: int = 32, percentile_bands: Sequence[float] | None = None, per_step_aggregate: str | None = None, color_by: str | None = None, alpha: float = 0.15, max_curves_per_frame: int | None = None, title: str | None = None, y_label: str = 'Model', ylim: tuple[float, float] | None = None) Figure[source]

Generate a static snapshot of a specific step from the chain.

Parameters:
model_fncallable

Callable implementing f(theta, t) -> y.

tarray_like

One-dimensional array of time samples.

chainarray_like or Chain

Chain data or Chain instance.

stepint

Step index to visualise.

walkers{‘all’, int, sequence of int}, optional

Walker selection specification.

log_probarray_like, optional

Log-probability values for the chain.

param_transformcallable, optional

Optional transformation applied prior to model evaluation.

vectorizedbool, optional

Indicates that model_fn supports vectorized evaluation.

n_jobsint, optional

Number of worker threads for non-vectorized evaluation.

chunk_sizeint, optional

Batch size for threaded evaluation.

percentile_bandssequence of float, optional

Percentile bands to shade in the snapshot.

per_step_aggregate{‘median’, ‘mean’, None}, optional

Aggregate curve to highlight.

color_by{‘walker’, ‘logp’, None}, optional

Strategy used to colour individual walker curves.

alphafloat, optional

Transparency applied to walker curves.

max_curves_per_frameint, optional

Upper bound on the number of curves rendered.

titlestr, optional

Title for the generated figure.

y_labelstr, optional

Y-axis label.

ylimtuple, optional

Y-axis limits.

Returns:
matplotlib.figure.Figure

Matplotlib figure containing the snapshot.