![]() |
Auxiliary results from a Sequential Monte Carlo step.
tfp.experimental.mcmc.SequentialMonteCarloResults(
steps,
parent_indices,
incremental_log_marginal_likelihood,
accumulated_log_marginal_likelihood,
seed
)
This structure serves as the kernel_results
for the SequentialMonteCarlo
transition kernel.
Elements:
steps
: scalar intTensor
number of inference steps completed so far.parent_indices
:int
Tensor
of shape[num_particles, b1, ..., bN]
, such thatparent_indices[k]
gives the indice(s) of the particle(s) at the previous step from which the thek
th current particle is immediately descended. See alsotfp.experimental.mcmc.reconstruct_trajectories
.incremental_log_marginal_likelihood
: floatTensor
of shape[b1, ..., bN]
, giving the natural logarithm of an unbiased estimate of the ratio in normalizing constants incurred in the most recent step (typically this is the likelihood of observed data). Note that (by Jensen's inequality) this is smaller in expectation than the true log ratio.cumulative_log_marginal_likelihood
: floatTensor
of shape[b1, ..., bN]
, giving the natural logarithm of an unbiased estimate of the ratio in normalizing constants incurred since the initial step (typically this is the likelihood of observed data). Note that (by Jensen's inequality) this is smaller in expectation than the true log ratio.seed
: The seed used in one_step.
In some contexts, results may be stacked across multiple inference steps,
in which case all Tensor
shapes will be prefixed by an additional dimension
of size num_steps
.
Attributes | |
---|---|
steps
|
A namedtuple alias for field number 0
|
parent_indices
|
A namedtuple alias for field number 1
|
incremental_log_marginal_likelihood
|
A namedtuple alias for field number 2
|
accumulated_log_marginal_likelihood
|
A namedtuple alias for field number 3
|
seed
|
A namedtuple alias for field number 4
|