16 #include <boost/property_tree/ptree.hpp>
18 namespace pt = boost::property_tree;
23 #include "ParallelProblem.h"
30 pt.put(
"NumSamples", 1e3);
31 pt.put(
"NumInitialSamples", 1e4);
32 pt.put(
"GreedyTargetVariance", 0.05);
33 pt.put(
"verbosity", 1);
36 for (
int subsampling : {0, 5, 10, 25, 100, 1000}) {
37 std::cout <<
"Running with subsampling " << subsampling << std::endl;
38 pt.put(
"MLMCMC.Subsampling", subsampling);
41 auto componentFactory = std::make_shared<MyMIComponentFactory>(pt);
43 std::cout << std::endl <<
"*************** greedy multillevel chain" << std::endl << std::endl;
47 std::cout <<
"mean QOI: " << greedymlmcmc.
GetQOIs()->Mean().transpose() << std::endl;
48 greedymlmcmc.
Draw(
false);
Greedy Multilevel MCMC method.
virtual std::shared_ptr< MultiIndexEstimator > GetQOIs() const
virtual std::shared_ptr< MultiIndexEstimator > Run()
void Draw(bool drawSamples=true)