superstats.transition.deterministic.linear#
Linear deterministic transition.
Classes
|
Deterministic linear transition with an intercept and slope. |
- class superstats.transition.deterministic.linear.Linear(bounds=None, intercept=None, beta=None, normalize_steps=True)[source]#
Bases:
DeterministicTransitionDeterministic linear transition with an intercept and slope.
- Parameters:
- boundssequence
oftwofloatsorNone,optional, default:None Lower and upper bounds for the deterministic trajectory. Tuples and lists are accepted.
- intercept
float,Prior,orNone,optional, default:None Starting value of the trajectory. A Prior samples one intercept per trajectory; None uses the deterministic default prior.
- beta
float,Prior,orNone,optional, default:None Change across the trajectory when normalize_steps=True. A Prior samples one slope per trajectory; None uses the deterministic default prior.
- normalize_stepsbool,
optional, default:True If True, use a time axis from 0 to 1. If False, use integer step indices, so the slope is applied at every step.
- boundssequence
- Parameters:
Notes
The sample method returns a dict with keys deterministic_params, hyper_params, and fixed_params. Trajectory values are clipped to bounds.
- sample_from_parameters(params, batch_size, num_steps)[source]#
Generate trajectories from already-resolved transition parameters.
Subclasses used with posterior predictive resimulation should override this method.
paramscontains the subclass’s own hyperparameter names, independent of any name used by aJointPrior.