![]() |
QMCPACK
|
Manages the state of QMC sections and handles population control for DMCs. More...
Classes | |
struct | VParams |
controlling parameters of full precision real type More... | |
Public Member Functions | |
SimpleFixedNodeBranch (RealType tau, int nideal) | |
Constructor. More... | |
SimpleFixedNodeBranch (const SimpleFixedNodeBranch &abranch) | |
copy constructor More... | |
~SimpleFixedNodeBranch () | |
bool | phaseChanged (RealType psi0) const |
void | advanceQMCCounter () |
increment QMCCounter More... | |
void | regressQMCCounter () |
EstimatorManagerBase * | getEstimatorManager () |
get the EstimatorManager More... | |
void | setEstimatorManager (std::unique_ptr< EstimatorManagerBase > est) |
set the EstimatorManager More... | |
int | initWalkerController (MCWalkerConfiguration &mcwc, bool fixW, bool killwalker) |
initialize the WalkerController More... | |
void | initReptile (MCWalkerConfiguration &w) |
initialize reptile stats More... | |
void | checkParameters (MCWalkerConfiguration &w) |
determine trial and reference energies More... | |
RealType | branchWeightBare (RealType enew, RealType eold) const |
return the bare branch weight More... | |
RealType | branchWeight (FullPrecRealType enew, FullPrecRealType eold) const |
return the bare branch weight with a filtering using an energy window More... | |
RealType | symLinkAction (RealType logGf, RealType logGb, RealType enew, RealType eold) const |
RealType | symLinkActionBare (RealType logGf, RealType logGb, RealType enew, RealType eold) const |
RealType | DMCLinkAction (RealType enew, RealType eold) const |
RealType | branchWeight (RealType enew, RealType eold, RealType scnew, RealType scold) const |
return the branch weight according to JCP1993 Umrigar et al. More... | |
RealType | branchWeight (RealType enew, RealType eold, RealType scnew, RealType scold, RealType p) const |
return the branch weight according to JCP1993 Umrigar et al. More... | |
RealType | branchWeightTau (RealType enew, RealType eold, RealType scnew, RealType scold, RealType taueff) |
return the branch weight according to JCP1993 Umrigar et al. More... | |
RealType | getEref () const |
RealType | getEtrial () const |
RealType | getTau () const |
RealType | getTauEff () const |
void | branch (int iter, MCWalkerConfiguration &w) |
perform branching More... | |
void | collect (int iter, MCWalkerConfiguration &w) |
update RMC counters and running averages. More... | |
void | flush (int counter) |
restart averaging More... | |
void | reset () |
reset the internal parameters More... | |
int | resetRun (xmlNodePtr cur) |
reset the internal parameters More... | |
bool | put (xmlNodePtr cur) |
Parse the xml file for parameters. More... | |
void | write (const std::string &fname, bool overwrite=true) |
write the state More... | |
void | read (const std::string &fname) |
void | registerParameters () |
create map between the parameter name and variables More... | |
void | start (const std::string &froot, bool append=false) |
start a run More... | |
void | finalize (MCWalkerConfiguration &w) |
finalize the simulation More... | |
Public Attributes | |
BranchModeType | BranchMode |
IParamType | iParam |
VParamType | vParam |
int | ToDoSteps |
number of remaning steps for a specific tasks More... | |
FullPrecRealType | logN |
Feed*log(N) More... | |
xmlNodePtr | myNode |
save xml element More... | |
std::unique_ptr< WalkerControlBase > | WalkerController |
WalkerController. More... | |
std::unique_ptr< WalkerControlBase > | BackupWalkerController |
Backup WalkerController for mixed DMC. More... | |
std::unique_ptr< EstimatorManagerBase > | MyEstimator |
accumulator_set< FullPrecRealType > | EnergyHist |
a simple accumulator for energy More... | |
accumulator_set< FullPrecRealType > | VarianceHist |
a simple accumulator for variance More... | |
accumulator_set< RealType > | R2Accepted |
a simple accumulator for energy More... | |
accumulator_set< RealType > | R2Proposed |
a simple accumulator for energy More... | |
accumulator_set< RealType > | R2Center |
a simple accumulator for reptation's center slice More... | |
std::string | RootName |
root name More... | |
std::string | branching_cutoff_scheme |
scheme of branching cutoff More... | |
ParameterSet | m_param |
set of parameters More... | |
std::vector< std::string > | sParam |
string parameters More... | |
FullPrecRealType | ScaleSum |
Used for the average scaling. More... | |
unsigned long | ScaleNum |
RealType | LogJacobRef |
LogJacob. More... | |
std::vector< RealType > | LogNorm |
LogNorm. More... | |
Private Member Functions | |
void | setBranchCutoff (FullPrecRealType variance, FullPrecRealType targetSigma, FullPrecRealType maxSigma, int Nelec=0) |
set branch cutoff, max, filter More... | |
Private Attributes | |
std::string | debug_disable_branching_ |
disable branching for debugging More... | |
Manages the state of QMC sections and handles population control for DMCs.
: Remove Estimator dependency, only has come dependency. Express accumulate in the actual DMC algorithm (i.e. in DMCBatched.cpp)
: Remove duplicate reading of Driver XML section with own copies of input parameters.
: Rename, it is the only branching class so its name is too much
: Use normal types for data members, don't be clever, the parameter enums violate KISS and make debugging annoying
: Remove as much state as possible.
QMCDriver object owns a SimpleFixedNodeBranch to keep track of the progress of a qmc section. It implements several methods to control the population and trial energy during a DMC and evaluate the properties of a population, e.g., energy, variance, population etc. It owns WalkerController (pointer to a WalkerControlBase object) which manages the population (killing and duplicating walkers) and load balancing among multiple MPI tasks.
Steps in 'Legacy' SFNB states machine
Finally branch can be called! It will be called once each step.
Definition at line 99 of file SimpleFixedNodeBranch.h.
using BranchModeType = std::bitset<B_MODE_MAX> |
booleans to set the branch modes
Definition at line 133 of file SimpleFixedNodeBranch.h.
using IParamType = TinyVector<int, B_IPARAM_MAX> |
input parameters of integer types
Definition at line 164 of file SimpleFixedNodeBranch.h.
using MCPWalker = Walker<QMCTraits, PtclOnLatticeTraits> |
Definition at line 102 of file SimpleFixedNodeBranch.h.
using SBVP = SimpleBranchVectorParameter |
Definition at line 189 of file SimpleFixedNodeBranch.h.
using ThisType = SimpleFixedNodeBranch |
Definition at line 101 of file SimpleFixedNodeBranch.h.
using VParamType = VParams<SBVP> |
Definition at line 202 of file SimpleFixedNodeBranch.h.
anonymous enum |
enum for booleans
Definition at line 107 of file SimpleFixedNodeBranch.h.
anonymous enum |
enum for iParam std::bitset<B_IPARAM_MAX>
When introducing a new iParam, check if B_IPARAM_MAX is sufficiently large. Use multiples of 8 Why? Much easier to use bool flags. Are these ever serialized?
Definition at line 142 of file SimpleFixedNodeBranch.h.
|
strong |
enum for vParam
Easy serialization is a relatively minor concern compared to the annoyance this causes elsewhere.
Enumerator | |
---|---|
TAU | |
TAUEFF | |
ETRIAL | |
EREF | |
ENOW | |
BRANCHMAX | |
BRANCHCUTOFF | |
BRANCHFILTER | |
SIGMA2 | |
ACC_ENERGY | |
ACC_SAMPLES | |
FEEDBACK | |
FILTERSCALE | |
VPARAM_MAX |
Definition at line 172 of file SimpleFixedNodeBranch.h.
SimpleFixedNodeBranch | ( | RealType | tau, |
int | nideal | ||
) |
Constructor.
Definition at line 45 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::B_BRANCHINTERVAL, SimpleFixedNodeBranch::B_CLEARHISTORY, SimpleFixedNodeBranch::B_COUNTER, SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::B_ENERGYUPDATEINTERVAL, SimpleFixedNodeBranch::B_KILLNODES, SimpleFixedNodeBranch::B_MAXWALKERS, SimpleFixedNodeBranch::B_MINWALKERS, SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::B_USETAUEFF, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::BranchMode, qmcplusplus::DUMMYOPT, qmcplusplus::Units::charge::e, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::FILTERSCALE, SimpleFixedNodeBranch::iParam, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, SimpleFixedNodeBranch::registerParameters(), SimpleFixedNodeBranch::reset(), SimpleFixedNodeBranch::sParam, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
SimpleFixedNodeBranch | ( | const SimpleFixedNodeBranch & | abranch | ) |
copy constructor
Copy only selected data members and WalkerController is never copied.
Definition at line 79 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::registerParameters(), and SimpleFixedNodeBranch::reset().
|
default |
|
inline |
increment QMCCounter
QMCCounter is the number of times any QMC section is processed.
Definition at line 274 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::B_COUNTER, and SimpleFixedNodeBranch::iParam.
Referenced by qmcplusplus::TEST_CASE().
void branch | ( | int | iter, |
MCWalkerConfiguration & | w | ||
) |
perform branching
iter | current step |
w | Walker configuration |
Definition at line 281 of file SimpleFixedNodeBranch.cpp.
References qmcplusplus::app_log(), SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::B_ENERGYUPDATEINTERVAL, SimpleFixedNodeBranch::B_KILLNODES, SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_USETAUEFF, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BackupWalkerController, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::BranchMode, accumulator_set< T, typename >::clear(), SimpleFixedNodeBranch::debug_disable_branching_, SimpleFixedNodeBranch::EnergyHist, SimpleFixedNodeBranch::ENOW, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, qmcplusplus::log(), SimpleFixedNodeBranch::logN, accumulator_set< T, typename >::mean(), qmcplusplus::MIXDMCOPT, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::sParam, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, SimpleFixedNodeBranch::ToDoSteps, SimpleFixedNodeBranch::VarianceHist, SimpleFixedNodeBranch::vParam, SimpleFixedNodeBranch::WalkerController, and qmcplusplus::hdf::walkers.
|
inline |
return the bare branch weight with a filtering using an energy window
Cutoff values are set by the variance
Definition at line 317 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHFILTER, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, qmcplusplus::exp(), SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
Referenced by DMCUpdateAllWithRejection::advanceWalker(), SODMCUpdatePbyPWithRejectionFast::advanceWalker(), DMCUpdatePbyPWithRejectionFast::advanceWalker(), DMCUpdatePbyPL2::advanceWalker(), and DMCUpdateAllWithKill::advanceWalker().
return the branch weight according to JCP1993 Umrigar et al.
Appendix A p=1, q=0
enew | new energy |
eold | old energy |
scnew | ![]() |
scold | ![]() |
Definition at line 367 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, qmcplusplus::exp(), SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
|
inline |
return the branch weight according to JCP1993 Umrigar et al.
Appendix A
enew | new energy |
eold | old energy |
scnew | ![]() |
scold | ![]() |
p | acceptance ratio |
Definition at line 381 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, qmcplusplus::exp(), SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
return the bare branch weight
This is equivalent to calling branchWeight(enew,eold,1.0,1.0)
Definition at line 308 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::ETRIAL, qmcplusplus::exp(), SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
|
inline |
return the branch weight according to JCP1993 Umrigar et al.
Appendix A p=1, q=0
enew | new energy |
eold | old energy |
scnew | ![]() |
scold | ![]() |
taueff |
Definition at line 396 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, qmcplusplus::exp(), SimpleFixedNodeBranch::ScaleNum, SimpleFixedNodeBranch::ScaleSum, and SimpleFixedNodeBranch::vParam.
void checkParameters | ( | MCWalkerConfiguration & | w | ) |
determine trial and reference energies
Definition at line 642 of file SimpleFixedNodeBranch.cpp.
References qmcplusplus::app_log(), SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::BranchMode, accumulator_set< T, typename >::clear(), qmcplusplus::Units::charge::e, SimpleFixedNodeBranch::EnergyHist, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::VarianceHist, and SimpleFixedNodeBranch::vParam.
void collect | ( | int | iter, |
MCWalkerConfiguration & | w | ||
) |
update RMC counters and running averages.
iter | the iteration |
w | the walker ensemble |
Definition at line 387 of file SimpleFixedNodeBranch.cpp.
References qmcplusplus::app_log(), SimpleFixedNodeBranch::B_ENERGYUPDATEINTERVAL, SimpleFixedNodeBranch::B_RMCSTAGE, SimpleFixedNodeBranch::B_USETAUEFF, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::BranchMode, accumulator_set< T, typename >::clear(), SimpleFixedNodeBranch::EnergyHist, SimpleFixedNodeBranch::ENOW, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FILTERSCALE, Reptile::getHead(), Reptile::getTail(), SimpleFixedNodeBranch::iParam, accumulator_set< T, typename >::mean(), SimpleFixedNodeBranch::MyEstimator, qmcplusplus::pow(), Walker< t_traits, p_traits >::Properties, ParticleSet::R, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, MCWalkerConfiguration::reptile, accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, SimpleFixedNodeBranch::ToDoSteps, SimpleFixedNodeBranch::VarianceHist, and SimpleFixedNodeBranch::vParam.
Definition at line 351 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHFILTER, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
Referenced by RMCUpdatePbyPWithDrift::advanceWalkersRMC(), RMCUpdateAllWithDrift::advanceWalkersRMC(), and RMCUpdateAllWithDrift::advanceWalkersVMC().
void finalize | ( | MCWalkerConfiguration & | w | ) |
finalize the simulation
Definition at line 665 of file SimpleFixedNodeBranch.cpp.
References qmcplusplus::app_log(), SimpleFixedNodeBranch::B_COUNTER, SimpleFixedNodeBranch::B_MAXWALKERS, SimpleFixedNodeBranch::B_MINWALKERS, SimpleFixedNodeBranch::B_RMC, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::BranchMode, qmcplusplus::Units::charge::e, SimpleFixedNodeBranch::EnergyHist, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::RootName, SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, SimpleFixedNodeBranch::vParam, SimpleFixedNodeBranch::WalkerController, and SimpleFixedNodeBranch::write().
void flush | ( | int | counter | ) |
restart averaging
counter | Counter to determine the cummulative average will be reset. |
Definition at line 275 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::WalkerController.
|
inline |
Definition at line 406 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::EREF, and SimpleFixedNodeBranch::vParam.
|
inline |
get the EstimatorManager
Definition at line 278 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::MyEstimator.
Referenced by qmcplusplus::TEST_CASE().
|
inline |
Definition at line 407 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::ETRIAL, and SimpleFixedNodeBranch::vParam.
|
inline |
Definition at line 408 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::TAU, and SimpleFixedNodeBranch::vParam.
Referenced by QMCUpdateBase::resetRun(), and qmcplusplus::TEST_CASE().
|
inline |
Definition at line 409 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
void initReptile | ( | MCWalkerConfiguration & | w | ) |
initialize reptile stats
Definition at line 217 of file SimpleFixedNodeBranch.cpp.
References qmcplusplus::app_log(), SimpleFixedNodeBranch::B_COUNTER, SimpleFixedNodeBranch::B_RESTART, SimpleFixedNodeBranch::B_RMC, SimpleFixedNodeBranch::B_RMCSTAGE, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::BranchMode, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, SimpleFixedNodeBranch::MyEstimator, ParticleSet::R, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, SimpleFixedNodeBranch::reset(), accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, SimpleFixedNodeBranch::vParam, and SimpleFixedNodeBranch::WalkerController.
int initWalkerController | ( | MCWalkerConfiguration & | mcwc, |
bool | fixW, | ||
bool | killwalker | ||
) |
initialize the WalkerController
mcwc | Walkers |
fixW | true, if reconfiguration with the fixed number of walkers is used |
killwalker |
Definition at line 126 of file SimpleFixedNodeBranch.cpp.
References Communicate::allreduce(), qmcplusplus::app_log(), SimpleFixedNodeBranch::B_COUNTER, SimpleFixedNodeBranch::B_DMC, SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::B_KILLNODES, SimpleFixedNodeBranch::B_MAXWALKERS, SimpleFixedNodeBranch::B_MINWALKERS, SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_RESTART, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BackupWalkerController, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::BranchMode, qmcplusplus::createWalkerController(), SimpleFixedNodeBranch::debug_disable_branching_, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, qmcplusplus::MIXDMCOPT, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::myNode, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, Communicate::rank(), SimpleFixedNodeBranch::reset(), accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SIGMA2, Communicate::size(), SimpleFixedNodeBranch::sParam, SimpleFixedNodeBranch::TAU, SimpleFixedNodeBranch::TAUEFF, SimpleFixedNodeBranch::vParam, SimpleFixedNodeBranch::WalkerController, and qmcplusplus::hdf::walkers.
|
inline |
Definition at line 260 of file SimpleFixedNodeBranch.h.
References qmcplusplus::cos().
Referenced by DMCUpdateAllWithRejection::advanceWalker(), SODMCUpdatePbyPWithRejectionFast::advanceWalker(), DMCUpdatePbyPWithRejectionFast::advanceWalker(), DMCUpdatePbyPL2::advanceWalker(), DMCUpdateAllWithKill::advanceWalker(), RMCUpdatePbyPWithDrift::advanceWalkersRMC(), RMCUpdateAllWithDrift::advanceWalkersRMC(), RMCUpdatePbyPWithDrift::advanceWalkersVMC(), and RMCUpdateAllWithDrift::advanceWalkersVMC().
bool put | ( | xmlNodePtr | cur | ) |
Parse the xml file for parameters.
cur | current xmlNode |
Few important parameters are:
Definition at line 732 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::m_param, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::myNode, ParameterSet::put(), and SimpleFixedNodeBranch::reset().
void read | ( | const std::string & | fname | ) |
Definition at line 756 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::ACC_ENERGY, SimpleFixedNodeBranch::ACC_SAMPLES, qmcplusplus::app_log(), SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_RESTART, SimpleFixedNodeBranch::BranchMode, accumulator_set< T, typename >::count(), SimpleFixedNodeBranch::EnergyHist, accumulator_set< T, typename >::good(), accumulator_set< T, typename >::mean(), SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::VarianceHist, and SimpleFixedNodeBranch::vParam.
void registerParameters | ( | ) |
create map between the parameter name and variables
Definition at line 92 of file SimpleFixedNodeBranch.cpp.
References ParameterSet::add(), SimpleFixedNodeBranch::B_BRANCHINTERVAL, SimpleFixedNodeBranch::B_ENERGYUPDATEINTERVAL, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::debug_disable_branching_, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::FILTERSCALE, SimpleFixedNodeBranch::iParam, SimpleFixedNodeBranch::m_param, qmcplusplus::MIXDMCOPT, SimpleFixedNodeBranch::sParam, SimpleFixedNodeBranch::TAU, qmcplusplus::USETAUOPT, and SimpleFixedNodeBranch::vParam.
Referenced by SimpleFixedNodeBranch::SimpleFixedNodeBranch().
|
inline |
Definition at line 275 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::B_COUNTER, and SimpleFixedNodeBranch::iParam.
void reset | ( | ) |
reset the internal parameters
Calculates and saves various action components, also does necessary updates for running averages.
Definition at line 478 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::B_ENERGYUPDATEINTERVAL, SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_RMC, SimpleFixedNodeBranch::B_RMCSTAGE, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::B_USETAUEFF, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BranchMode, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, qmcplusplus::log(), SimpleFixedNodeBranch::logN, SimpleFixedNodeBranch::sParam, SimpleFixedNodeBranch::ToDoSteps, qmcplusplus::USETAUOPT, SimpleFixedNodeBranch::vParam, and SimpleFixedNodeBranch::WalkerController.
Referenced by SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::put(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
int resetRun | ( | xmlNodePtr | cur | ) |
reset the internal parameters
only used by legacy drivers
Definition at line 523 of file SimpleFixedNodeBranch.cpp.
References ParameterSet::add(), APP_ABORT, qmcplusplus::app_log(), SimpleFixedNodeBranch::B_DMC, SimpleFixedNodeBranch::B_DMCSTAGE, SimpleFixedNodeBranch::B_MAXWALKERS, SimpleFixedNodeBranch::B_MINWALKERS, SimpleFixedNodeBranch::B_POPCONTROL, SimpleFixedNodeBranch::B_TARGETWALKERS, SimpleFixedNodeBranch::B_WARMUPSTEPS, SimpleFixedNodeBranch::BackupWalkerController, TinyVector< T, D >::begin(), SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::BranchMode, accumulator_set< T, typename >::clear(), qmcplusplus::createWalkerController(), TinyVector< T, D >::end(), SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::ETRIAL, SimpleFixedNodeBranch::FEEDBACK, SimpleFixedNodeBranch::iParam, SimpleFixedNodeBranch::m_param, SimpleFixedNodeBranch::MyEstimator, SimpleFixedNodeBranch::myNode, ParameterSet::put(), SimpleFixedNodeBranch::R2Accepted, SimpleFixedNodeBranch::R2Proposed, SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SIGMA2, SimpleFixedNodeBranch::ToDoSteps, SimpleFixedNodeBranch::vParam, and SimpleFixedNodeBranch::WalkerController.
|
private |
set branch cutoff, max, filter
Definition at line 787 of file SimpleFixedNodeBranch.cpp.
References APP_ABORT, SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHFILTER, SimpleFixedNodeBranch::branching_cutoff_scheme, SimpleFixedNodeBranch::BRANCHMAX, omptarget::min(), qmcplusplus::sqrt(), SimpleFixedNodeBranch::TAU, and SimpleFixedNodeBranch::vParam.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), and SimpleFixedNodeBranch::resetRun().
|
inline |
set the EstimatorManager
est | estimator created by the first QMCDriver this assumes estimator managers are reused section to section |
Definition at line 284 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::MyEstimator.
Referenced by qmcplusplus::TEST_CASE().
void start | ( | const std::string & | froot, |
bool | append = false |
||
) |
start a run
Definition at line 120 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::MyEstimator, and SimpleFixedNodeBranch::RootName.
|
inline |
Definition at line 328 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::BRANCHCUTOFF, SimpleFixedNodeBranch::BRANCHFILTER, SimpleFixedNodeBranch::BRANCHMAX, SimpleFixedNodeBranch::EREF, SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
Referenced by RMCUpdateAllWithDrift::advanceWalkersRMC(), and RMCUpdateAllWithDrift::advanceWalkersVMC().
|
inline |
Definition at line 342 of file SimpleFixedNodeBranch.h.
References SimpleFixedNodeBranch::TAUEFF, and SimpleFixedNodeBranch::vParam.
void write | ( | const std::string & | fname, |
bool | overwrite = true |
||
) |
write the state
fname | name of the configuration file |
overwrite | NOT USED |
Definition at line 743 of file SimpleFixedNodeBranch.cpp.
References SimpleFixedNodeBranch::ACC_ENERGY, SimpleFixedNodeBranch::ACC_SAMPLES, accumulator_set< T, typename >::count(), SimpleFixedNodeBranch::EnergyHist, SimpleFixedNodeBranch::MyEstimator, accumulator_set< T, typename >::result(), SimpleFixedNodeBranch::RootName, SimpleFixedNodeBranch::vParam, and BranchIO< SFNB >::write().
Referenced by SimpleFixedNodeBranch::finalize().
std::unique_ptr<WalkerControlBase> BackupWalkerController |
Backup WalkerController for mixed DMC.
Definition at line 217 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::initWalkerController(), and SimpleFixedNodeBranch::resetRun().
std::string branching_cutoff_scheme |
scheme of branching cutoff
Definition at line 237 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::registerParameters(), SimpleFixedNodeBranch::resetRun(), SimpleFixedNodeBranch::setBranchCutoff(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
BranchModeType BranchMode |
Definition at line 134 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::checkParameters(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::read(), SimpleFixedNodeBranch::reset(), SimpleFixedNodeBranch::resetRun(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
|
private |
disable branching for debugging
Definition at line 464 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::initWalkerController(), and SimpleFixedNodeBranch::registerParameters().
accumulator_set<FullPrecRealType> EnergyHist |
a simple accumulator for energy
Definition at line 221 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::checkParameters(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::read(), and SimpleFixedNodeBranch::write().
IParamType iParam |
Definition at line 165 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::advanceQMCCounter(), SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::registerParameters(), SimpleFixedNodeBranch::regressQMCCounter(), SimpleFixedNodeBranch::reset(), SimpleFixedNodeBranch::resetRun(), SimpleFixedNodeBranch::SimpleFixedNodeBranch(), and qmcplusplus::TEST_CASE().
RealType LogJacobRef |
LogJacob.
Definition at line 248 of file SimpleFixedNodeBranch.h.
FullPrecRealType logN |
Feed*log(N)
Definition at line 211 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), and SimpleFixedNodeBranch::reset().
std::vector<RealType> LogNorm |
LogNorm.
Definition at line 250 of file SimpleFixedNodeBranch.h.
ParameterSet m_param |
set of parameters
Definition at line 239 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::put(), SimpleFixedNodeBranch::registerParameters(), and SimpleFixedNodeBranch::resetRun().
std::unique_ptr<EstimatorManagerBase> MyEstimator |
Definition at line 219 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::checkParameters(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::getEstimatorManager(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::put(), SimpleFixedNodeBranch::read(), SimpleFixedNodeBranch::resetRun(), SimpleFixedNodeBranch::setEstimatorManager(), SimpleFixedNodeBranch::start(), and SimpleFixedNodeBranch::write().
xmlNodePtr myNode |
save xml element
Definition at line 213 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::put(), and SimpleFixedNodeBranch::resetRun().
accumulator_set<RealType> R2Accepted |
a simple accumulator for energy
Definition at line 225 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::read(), SimpleFixedNodeBranch::resetRun(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
accumulator_set<RealType> R2Center |
a simple accumulator for reptation's center slice
Definition at line 229 of file SimpleFixedNodeBranch.h.
accumulator_set<RealType> R2Proposed |
a simple accumulator for energy
Definition at line 227 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::read(), SimpleFixedNodeBranch::resetRun(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
std::string RootName |
root name
Definition at line 235 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::start(), and SimpleFixedNodeBranch::write().
unsigned long ScaleNum |
Definition at line 245 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branchWeightTau().
FullPrecRealType ScaleSum |
Used for the average scaling.
Definition at line 244 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branchWeightTau().
std::vector<std::string> sParam |
string parameters
Definition at line 241 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::registerParameters(), SimpleFixedNodeBranch::reset(), and SimpleFixedNodeBranch::SimpleFixedNodeBranch().
int ToDoSteps |
number of remaning steps for a specific tasks
set differently for BranchMode[B_DMCSTAGE]
Definition at line 209 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::reset(), and SimpleFixedNodeBranch::resetRun().
accumulator_set<FullPrecRealType> VarianceHist |
a simple accumulator for variance
Definition at line 223 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::checkParameters(), SimpleFixedNodeBranch::collect(), and SimpleFixedNodeBranch::read().
VParamType vParam |
Definition at line 203 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::branchWeight(), SimpleFixedNodeBranch::branchWeightBare(), SimpleFixedNodeBranch::branchWeightTau(), SimpleFixedNodeBranch::checkParameters(), SimpleFixedNodeBranch::collect(), SimpleFixedNodeBranch::DMCLinkAction(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::getEref(), SimpleFixedNodeBranch::getEtrial(), SimpleFixedNodeBranch::getTau(), SimpleFixedNodeBranch::getTauEff(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::read(), SimpleFixedNodeBranch::registerParameters(), SimpleFixedNodeBranch::reset(), SimpleFixedNodeBranch::resetRun(), SimpleFixedNodeBranch::setBranchCutoff(), SimpleFixedNodeBranch::SimpleFixedNodeBranch(), SimpleFixedNodeBranch::symLinkAction(), SimpleFixedNodeBranch::symLinkActionBare(), and SimpleFixedNodeBranch::write().
std::unique_ptr<WalkerControlBase> WalkerController |
WalkerController.
Definition at line 215 of file SimpleFixedNodeBranch.h.
Referenced by SimpleFixedNodeBranch::branch(), SimpleFixedNodeBranch::finalize(), SimpleFixedNodeBranch::flush(), SimpleFixedNodeBranch::initReptile(), SimpleFixedNodeBranch::initWalkerController(), SimpleFixedNodeBranch::reset(), and SimpleFixedNodeBranch::resetRun().