MCMC kernel for Multiindex methods. More...
#include <MIKernel.h>
MCMC kernel for Multiindex methods.
This kernel combines a coarse proposal from a coarse chain with a fine one, as needed for MIMCMC.
Definition at line 19 of file MIKernel.h.
Public Member Functions | |
MIKernel (boost::property_tree::ptree const &pt, std::shared_ptr< AbstractSamplingProblem > problem, std::shared_ptr< AbstractSamplingProblem > coarse_problem, std::shared_ptr< MCMCProposal > proposal, std::shared_ptr< MCMCProposal > coarse_proposal, std::shared_ptr< MIInterpolation > proposalInterpolation, std::shared_ptr< SingleChainMCMC > coarse_chain) | |
~MIKernel () | |
virtual std::shared_ptr< MCMCProposal > | Proposal () |
virtual void | PostStep (unsigned int const t, std::vector< std::shared_ptr< SamplingState >> const &state) override |
Allow the kernel to adapt given a new state. More... | |
virtual void | PrintStatus (std::string prefix) const override |
virtual std::vector< std::shared_ptr< SamplingState > > | Step (unsigned int const t, std::shared_ptr< SamplingState > prevState) override |
virtual double | AcceptanceRate () const |
Public Member Functions inherited from muq::SamplingAlgorithms::TransitionKernel | |
TransitionKernel (boost::property_tree::ptree const &pt, std::shared_ptr< AbstractSamplingProblem > problem) | |
virtual | ~TransitionKernel ()=default |
virtual void | SetCommunicator (std::shared_ptr< parcer::Communicator > newcomm) |
virtual void | PreStep (unsigned int const t, std::shared_ptr< SamplingState > state) |
Allow the kernel to preprocess the current step. More... | |
virtual void | PrintStatus () const |
virtual void | SetBlockInd (int newBlockInd) |
virtual int | GetBlockInd () const |
virtual std::shared_ptr< AbstractSamplingProblem > const & | Problem () const |
Additional Inherited Members | |
Public Types inherited from muq::SamplingAlgorithms::TransitionKernel | |
typedef boost::function< std::shared_ptr< TransitionKernel >boost::property_tree::ptree, std::shared_ptr< AbstractSamplingProblem >)> | TransitionKernelConstructor |
typedef std::map< std::string, TransitionKernelConstructor > | TransitionKernelMap |
Static Public Member Functions inherited from muq::SamplingAlgorithms::TransitionKernel | |
static std::shared_ptr< TransitionKernel > | Construct (boost::property_tree::ptree const &pt, std::shared_ptr< AbstractSamplingProblem > problem) |
Static constructor for the transition kernel. More... | |
static std::shared_ptr< TransitionKernelMap > | GetTransitionKernelMap () |
MIKernel::MIKernel | ( | boost::property_tree::ptree const & | pt, |
std::shared_ptr< AbstractSamplingProblem > | problem, | ||
std::shared_ptr< AbstractSamplingProblem > | coarse_problem, | ||
std::shared_ptr< MCMCProposal > | proposal, | ||
std::shared_ptr< MCMCProposal > | coarse_proposal, | ||
std::shared_ptr< MIInterpolation > | proposalInterpolation, | ||
std::shared_ptr< SingleChainMCMC > | coarse_chain | ||
) |
Definition at line 14 of file MIKernel.cpp.
MIKernel::~MIKernel | ( | ) |
Definition at line 29 of file MIKernel.cpp.
|
inlinevirtual |
Definition at line 40 of file MIKernel.h.
References numAccepts, and numCalls.
|
overridevirtual |
Allow the kernel to adapt given a new state.
By default this function does nothing but children can override it to adapt the kernel
[in] | t | The current step |
[in] | state | The current state |
Reimplemented from muq::SamplingAlgorithms::TransitionKernel.
Definition at line 31 of file MIKernel.cpp.
References proposal.
|
overridevirtual |
Reimplemented from muq::SamplingAlgorithms::TransitionKernel.
Definition at line 121 of file MIKernel.cpp.
References numAccepts, and numCalls.
|
inlinevirtual |
Definition at line 32 of file MIKernel.h.
References proposal.
|
overridevirtual |
[in] | t | The current step |
[in] | state | The current state |
Implements muq::SamplingAlgorithms::TransitionKernel.
Definition at line 35 of file MIKernel.cpp.
References coarse_chain, coarse_problem, coarse_proposal, numAccepts, numCalls, muq::SamplingAlgorithms::TransitionKernel::problem, proposal, and proposalInterpolation.
|
protected |
Definition at line 47 of file MIKernel.h.
Referenced by Step().
|
protected |
Definition at line 43 of file MIKernel.h.
Referenced by Step().
|
protected |
Definition at line 45 of file MIKernel.h.
Referenced by Step().
|
protected |
Definition at line 50 of file MIKernel.h.
Referenced by AcceptanceRate(), PrintStatus(), and Step().
|
protected |
Definition at line 49 of file MIKernel.h.
Referenced by AcceptanceRate(), PrintStatus(), and Step().
|
protected |
Definition at line 44 of file MIKernel.h.
Referenced by PostStep(), Proposal(), and Step().
|
protected |
Definition at line 46 of file MIKernel.h.
Referenced by Step().