py21cmmc.cosmoHammer.HDFStorage#
- class py21cmmc.cosmoHammer.HDFStorage(filename, name)[source]#
A HDF Storage utility, based on the HDFBackend from emcee v3.0.0.
Methods
__init__
(filename, name)get_blobs
(**kwargs)Get the chain of blobs for each sample in the chain.
get_chain
(**kwargs)Get the stored chain of MCMC samples.
Access the most recent sample in the chain.
get_log_prob
(**kwargs)Get the chain of log probabilities evaluated at the MCMC samples.
get_trialled_log_prob
(**kwargs)Get the chain of log probabilities evaluated as trials of the MCMC.
get_trials
(**kwargs)Get the stored chain of trials.
get_value
(name[, flat, thin, discard])Get a particular kind of entry from the backend file.
grow
(ngrow, blobs)Expand the storage space by some number of samples.
open
([mode])Open the backend file.
reset
(nwalkers, params)Clear the state of the chain and empty the backend.
save_step
(coords, log_prob, blobs, truepos, ...)Save a step to the file.
Attributes
Number of acceptances for each walker.
An array of bools representing whether parameter proposals were accepted.
Names for each of the arbitrary blobs.
Whether this file has blobs in it.
Whether the file object has been initialized.
The iteration the chain is currently at.
An initial guess for the parameters.
The parameter names.
The defining random state of the process.
Tuple of (nwalkers, ndim).
The length of the chain.