MUQ  0.4.3
muq::SamplingAlgorithms::GreedyMLMCMC Class Reference

Greedy Multilevel MCMC method. More...

#include <GreedyMLMCMC.h>

Detailed Description

Greedy Multilevel MCMC method.

A Multilevel MCMC method choosing the number of samples adaptively at runtime, estimating the most profitable level from statistical information on samples.

Definition at line 24 of file GreedyMLMCMC.h.

Public Member Functions

 GreedyMLMCMC (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)
 
 GreedyMLMCMC (boost::property_tree::ptree pt, Eigen::VectorXd const &startPt, std::vector< std::shared_ptr< AbstractSamplingProblem >> const &problems, std::shared_ptr< MultiIndexSet > const &multis=nullptr)
 
 GreedyMLMCMC (boost::property_tree::ptree pt, std::shared_ptr< MIComponentFactory > componentFactory)
 
virtual std::shared_ptr< MultiIndexEstimatorGetSamples () const
 
virtual std::shared_ptr< MultiIndexEstimatorGetQOIs () const
 
void Draw (bool drawSamples=true)
 
std::shared_ptr< MIMCMCBoxGetBox (int index)
 
std::vector< std::shared_ptr< MIMCMCBox > > GetBoxes ()
 
void WriteToFile (std::string filename)
 
virtual std::shared_ptr< MultiIndexEstimatorRun ()
 

Constructor & Destructor Documentation

◆ GreedyMLMCMC() [1/3]

muq::SamplingAlgorithms::GreedyMLMCMC::GreedyMLMCMC ( 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 
)

◆ GreedyMLMCMC() [2/3]

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

◆ GreedyMLMCMC() [3/3]

GreedyMLMCMC::GreedyMLMCMC ( boost::property_tree::ptree  pt,
std::shared_ptr< MIComponentFactory componentFactory 
)

Definition at line 24 of file GreedyMLMCMC.cpp.

References boxes, componentFactory, levels, and verbosity.

Member Function Documentation

◆ CreateProblems()

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

Definition at line 44 of file GreedyMLMCMC.cpp.

◆ Draw()

void GreedyMLMCMC::Draw ( bool  drawSamples = true)

Definition at line 154 of file GreedyMLMCMC.cpp.

References boxes.

Referenced by main().

◆ GetBox()

std::shared_ptr< MIMCMCBox > GreedyMLMCMC::GetBox ( int  index)

Definition at line 140 of file GreedyMLMCMC.cpp.

References boxes.

◆ GetBoxes()

std::vector< std::shared_ptr< MIMCMCBox > > GreedyMLMCMC::GetBoxes ( )

Definition at line 144 of file GreedyMLMCMC.cpp.

References boxes.

◆ GetQOIs()

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

Definition at line 58 of file GreedyMLMCMC.cpp.

References boxes.

Referenced by main().

◆ GetSamples()

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

Definition at line 54 of file GreedyMLMCMC.cpp.

References boxes.

Referenced by Run().

◆ ProcessMultis()

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

Definition at line 167 of file GreedyMLMCMC.cpp.

◆ Run()

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

Definition at line 62 of file GreedyMLMCMC.cpp.

References beta, boxes, componentFactory, e, GetSamples(), levels, numInitialSamples, nlohmann::to_string(), useQOIs, and verbosity.

Referenced by main().

◆ WriteToFile()

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

Definition at line 148 of file GreedyMLMCMC.cpp.

References boxes.

Referenced by main().

Member Data Documentation

◆ beta

const double muq::SamplingAlgorithms::GreedyMLMCMC::beta
private

Definition at line 61 of file GreedyMLMCMC.h.

Referenced by Run().

◆ boxes

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

Definition at line 64 of file GreedyMLMCMC.h.

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

◆ componentFactory

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

Definition at line 58 of file GreedyMLMCMC.h.

Referenced by GreedyMLMCMC(), and Run().

◆ e

const double muq::SamplingAlgorithms::GreedyMLMCMC::e
private

Definition at line 60 of file GreedyMLMCMC.h.

Referenced by Run().

◆ levels

const int muq::SamplingAlgorithms::GreedyMLMCMC::levels
private

Definition at line 62 of file GreedyMLMCMC.h.

Referenced by GreedyMLMCMC(), and Run().

◆ numInitialSamples

const int muq::SamplingAlgorithms::GreedyMLMCMC::numInitialSamples
private

Definition at line 59 of file GreedyMLMCMC.h.

Referenced by Run().

◆ useQOIs

bool muq::SamplingAlgorithms::GreedyMLMCMC::useQOIs
private

Definition at line 65 of file GreedyMLMCMC.h.

Referenced by Run().

◆ verbosity

int muq::SamplingAlgorithms::GreedyMLMCMC::verbosity
private

Definition at line 63 of file GreedyMLMCMC.h.

Referenced by GreedyMLMCMC(), and Run().


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