![]() |
QMCPACK
|
Estimator for local energy only. More...
Public Types | |
using | WP = WalkerProperties::Indexes |
![]() | |
using | RealType = QMCTraits::FullPrecRealType |
using | accumulator_type = accumulator_set< RealType > |
using | Walker_t = MCWalkerConfiguration::Walker_t |
using | MCPWalker = Walker< QMCTraits, PtclOnLatticeTraits > |
using | WalkerIterator = MCWalkerConfiguration::const_iterator |
using | RecordListType = RecordNamedProperty< RealType > |
Public Member Functions | |
LocalEnergyOnlyEstimator () | |
std::string | getName () const override |
void | accumulate (const MCWalkerConfiguration &W, WalkerIterator first, WalkerIterator last, RealType wgt) override |
a virtual function to accumulate observables or collectables More... | |
void | accumulate (const RefVector< MCPWalker > &walkers) override |
a virtual function to accumulate observables or collectables More... | |
void | registerObservables (std::vector< ObservableHelper > &h5dec, hdf_archive &file) override |
add descriptors of observables to utilize hdf5 More... | |
void | add2Record (RecordListType &record) override |
add the local energy, variance and all the Hamiltonian components to the scalar record container More... | |
LocalEnergyOnlyEstimator * | clone () override |
clone the object More... | |
const std::string & | getSubTypeStr () const override |
String representation of the derived type of the ScalarEstimator. More... | |
![]() | |
ScalarEstimatorBase () | |
virtual | ~ScalarEstimatorBase () |
virtual bool | isMainEstimator () const |
Is this estimator a main estimator i.e. the estimator required for a particular driver. More... | |
RealType | average (int i=0) const |
return average of the More... | |
RealType | variance (int i=0) const |
return a variance More... | |
std::pair< RealType, RealType > | operator[] (int i) const |
retrun mean and variance More... | |
virtual int | size () const |
return the size of scalars it manages More... | |
void | clear () |
clear the scalars to collect More... | |
template<typename IT > | |
void | takeBlockAverage (IT first) |
take block average and write to a common container More... | |
template<typename IT > | |
void | takeBlockAverage (IT first, IT first_sq) |
take block average and write to common containers for values and squared values More... | |
template<typename IT > | |
void | addAccumulated (IT first) |
add the block accumulated scalars More... | |
virtual void | add2Record (RecordNamedProperty< RealType > &record)=0 |
add the content of the scalar estimator to the record More... | |
Public Attributes | |
const std::string | type_str = "LocalEnergyOnlyEstimatorNotSupportedInBatchedVersion" |
![]() | |
int | FirstIndex |
first index within an record of the first element handled by an object More... | |
int | LastIndex |
last index within an record of the first element handled by an object More... | |
std::vector< accumulator_type > | scalars |
scalars to be measured More... | |
std::vector< accumulator_type > | scalars_saved |
scalars saved More... | |
Estimator for local energy only.
Definition at line 22 of file LocalEnergyOnlyEstimator.h.
using WP = WalkerProperties::Indexes |
Definition at line 24 of file LocalEnergyOnlyEstimator.h.
|
inline |
Definition at line 26 of file LocalEnergyOnlyEstimator.h.
References ScalarEstimatorBase::scalars, and ScalarEstimatorBase::scalars_saved.
Referenced by LocalEnergyOnlyEstimator::clone().
|
inlineoverridevirtual |
a virtual function to accumulate observables or collectables
W | const MCWalkerConfiguration |
first | const_iterator for the first walker |
last | const_iterator for the last walker |
wgt | weight |
Pass W along with the iterators so that the properties of W can be utilized.
Implements ScalarEstimatorBase.
Definition at line 34 of file LocalEnergyOnlyEstimator.h.
References ScalarEstimatorBase::scalars.
Referenced by qmcplusplus::TEST_CASE().
a virtual function to accumulate observables or collectables
global_walkers_ | walkers per ranks or walkers total? |
RefVector | of MCPWalkers |
wgt | weight or maybe norm |
Implements ScalarEstimatorBase.
Definition at line 46 of file LocalEnergyOnlyEstimator.h.
References ScalarEstimatorBase::scalars, qmcplusplus::walker, and qmcplusplus::hdf::walkers.
|
inlineoverride |
add the local energy, variance and all the Hamiltonian components to the scalar record container
record | storage of scalar records (name,value) |
Definition at line 60 of file LocalEnergyOnlyEstimator.h.
References RecordNamedProperty< T >::add(), ScalarEstimatorBase::clear(), ScalarEstimatorBase::FirstIndex, and ScalarEstimatorBase::LastIndex.
|
inlineoverridevirtual |
clone the object
Implements ScalarEstimatorBase.
Definition at line 70 of file LocalEnergyOnlyEstimator.h.
References LocalEnergyOnlyEstimator::LocalEnergyOnlyEstimator().
|
inlineoverridevirtual |
Implements ScalarEstimatorBase.
Definition at line 32 of file LocalEnergyOnlyEstimator.h.
Referenced by qmcplusplus::TEST_CASE().
|
inlineoverridevirtual |
String representation of the derived type of the ScalarEstimator.
Implements ScalarEstimatorBase.
Definition at line 73 of file LocalEnergyOnlyEstimator.h.
References LocalEnergyOnlyEstimator::type_str.
|
inlineoverridevirtual |
add descriptors of observables to utilize hdf5
h5desc | descriptor of a data stored in a h5 group |
file | file to which each statistical data will be stored |
Implements ScalarEstimatorBase.
Definition at line 55 of file LocalEnergyOnlyEstimator.h.
const std::string type_str = "LocalEnergyOnlyEstimatorNotSupportedInBatchedVersion" |
Definition at line 72 of file LocalEnergyOnlyEstimator.h.
Referenced by LocalEnergyOnlyEstimator::getSubTypeStr().