MUQ  0.4.3
muq::SamplingAlgorithms::MIMCMC Class Reference

Multiindex MCMC method. More...

#include <MIMCMC.h>

Detailed Description

Multiindex MCMC method.

A basic MIMCMC method based on a fixed number of samples for all model indices.

Definition at line 21 of file MIMCMC.h.

Public Member Functions

 MIMCMC (boost::property_tree::ptree options, std::shared_ptr< MIComponentFactory > const &componentFactory)
 
 MIMCMC (boost::property_tree::ptree pt, Eigen::VectorXd const &startPt, std::vector< std::shared_ptr< muq::Modeling::ModPiece >> const &models, std::shared_ptr< MultiIndexSet > const &multis=nullptr)
 
 MIMCMC (boost::property_tree::ptree pt, Eigen::VectorXd const &startPt, std::vector< std::shared_ptr< AbstractSamplingProblem >> const &problems, std::shared_ptr< MultiIndexSet > const &multis=nullptr)
 
virtual std::shared_ptr< MultiIndexEstimatorGetSamples () const
 
virtual std::shared_ptr< MultiIndexEstimatorGetQOIs () const
 
std::shared_ptr< MIMCMCBoxGetBox (std::shared_ptr< MultiIndex > index)
 Access an MIMCMCBox. More...
 
void Draw (bool drawSamples=true)
 Draw MI structure (mostly debugging purposes) More...
 
std::shared_ptr< MIMCMCBoxGetMIMCMCBox (std::shared_ptr< MultiIndex > index)
 
std::shared_ptr< MultiIndexSet > GetIndices ()
 Get set of indices of boxes set up by the method. More...
 
virtual std::shared_ptr< MultiIndexEstimatorRun ()
 
void WriteToFile (std::string filename)
 Write HDF5 output for the entire MIMCMC method. More...
 

Constructor & Destructor Documentation

◆ MIMCMC() [1/3]

muq::SamplingAlgorithms::MIMCMC::MIMCMC ( boost::property_tree::ptree  options,
std::shared_ptr< MIComponentFactory > const &  componentFactory 
)

◆ MIMCMC() [2/3]

MIMCMC::MIMCMC ( boost::property_tree::ptree  pt,
Eigen::VectorXd const &  startPt,
std::vector< std::shared_ptr< muq::Modeling::ModPiece >> const &  models,
std::shared_ptr< MultiIndexSet > const &  multis = nullptr 
)

Definition at line 7 of file MIMCMC.cpp.

◆ MIMCMC() [3/3]

MIMCMC::MIMCMC ( boost::property_tree::ptree  pt,
Eigen::VectorXd const &  startPt,
std::vector< std::shared_ptr< AbstractSamplingProblem >> const &  problems,
std::shared_ptr< MultiIndexSet > const &  multis = nullptr 
)

Definition at line 15 of file MIMCMC.cpp.

Member Function Documentation

◆ CreateProblems()

std::vector< std::shared_ptr< AbstractSamplingProblem > > MIMCMC::CreateProblems ( std::vector< std::shared_ptr< muq::Modeling::ModPiece >> const &  models)
staticprivate

Definition at line 115 of file MIMCMC.cpp.

◆ Draw()

void MIMCMC::Draw ( bool  drawSamples = true)

Draw MI structure (mostly debugging purposes)

Definition at line 92 of file MIMCMC.cpp.

References boxes.

◆ GetBox()

std::shared_ptr< MIMCMCBox > MIMCMC::GetBox ( std::shared_ptr< MultiIndex >  index)

Access an MIMCMCBox.

Parameters
indexModel index for which to retrieve the box.
Returns
std::shared_ptr<MIMCMCBox> The MIMCMCBox representing the Multiindex telescoping sum component associated with that model.

Definition at line 37 of file MIMCMC.cpp.

References boxes.

Referenced by main().

◆ GetIndices()

std::shared_ptr< MultiIndexSet > MIMCMC::GetIndices ( )

Get set of indices of boxes set up by the method.

Definition at line 79 of file MIMCMC.cpp.

References gridIndices.

◆ GetMIMCMCBox()

std::shared_ptr< MIMCMCBox > MIMCMC::GetMIMCMCBox ( std::shared_ptr< MultiIndex >  index)

Definition at line 64 of file MIMCMC.cpp.

References boxes.

◆ GetQOIs()

std::shared_ptr< MultiIndexEstimator > MIMCMC::GetQOIs ( ) const
virtual

Definition at line 48 of file MIMCMC.cpp.

References boxes.

Referenced by main().

◆ GetSamples()

std::shared_ptr< MultiIndexEstimator > MIMCMC::GetSamples ( ) const
virtual

Definition at line 45 of file MIMCMC.cpp.

References boxes.

Referenced by Run().

◆ multiindexToConfigString()

std::string MIMCMC::multiindexToConfigString ( std::shared_ptr< MultiIndex >  index)
private

Definition at line 84 of file MIMCMC.cpp.

Referenced by Run().

◆ ProcessMultis()

std::shared_ptr< MultiIndexSet > MIMCMC::ProcessMultis ( std::shared_ptr< MultiIndexSet > const &  multis,
unsigned int  numLevels 
)
staticprivate

Definition at line 105 of file MIMCMC.cpp.

◆ Run()

std::shared_ptr< MultiIndexEstimator > MIMCMC::Run ( )
virtual

Definition at line 52 of file MIMCMC.cpp.

References boxes, GetSamples(), multiindexToConfigString(), and pt.

Referenced by main().

◆ WriteToFile()

void MIMCMC::WriteToFile ( std::string  filename)

Write HDF5 output for the entire MIMCMC method.

Definition at line 72 of file MIMCMC.cpp.

References boxes.

Referenced by main().

Member Data Documentation

◆ boxes

std::vector<std::shared_ptr<MIMCMCBox> > muq::SamplingAlgorithms::MIMCMC::boxes
private

Definition at line 71 of file MIMCMC.h.

Referenced by Draw(), GetBox(), GetMIMCMCBox(), GetQOIs(), GetSamples(), Run(), and WriteToFile().

◆ componentFactory

std::shared_ptr<MIComponentFactory> muq::SamplingAlgorithms::MIMCMC::componentFactory
private

Definition at line 70 of file MIMCMC.h.

◆ gridIndices

std::shared_ptr<MultiIndexSet> muq::SamplingAlgorithms::MIMCMC::gridIndices
private

Definition at line 69 of file MIMCMC.h.

Referenced by GetIndices().

◆ pt

pt::ptree muq::SamplingAlgorithms::MIMCMC::pt
private

Definition at line 68 of file MIMCMC.h.

Referenced by Run().


The documentation for this class was generated from the following files: