QMCPACK
SelfHealingOverlap.h
Go to the documentation of this file.
1 //////////////////////////////////////////////////////////////////////////////////////
2 // This file is distributed under the University of Illinois/NCSA Open Source License.
3 // See LICENSE file in top directory for details.
4 //
5 // Copyright (c) 2024 QMCPACK developers.
6 //
7 // File developed by: Jaron T. Krogel, krogeljt@ornl.gov, Oak Ridge National Laboratory
8 //
9 //////////////////////////////////////////////////////////////////////////////////////
10 
11 #ifndef QMCPLUSPLUS_SHOVERLAP_H
12 #define QMCPLUSPLUS_SHOVERLAP_H
13 #include <vector>
14 
15 #include "Configuration.h"
16 #include "OperatorEstBase.h"
18 
20 
21 
22 namespace qmcplusplus
23 {
24 /** Class that collects MSD coefficient values via the Self-Healing overlap
25  *
26  */
28 {
29 public:
35 
36  //data members set only during construction
38 
39  /** @ingroup SelfHealingOverlap mutable data members
40  */
42 
43 public:
44  /** Constructor for SelfHealingOverlapInput
45  */
47  const TrialWaveFunction& wfn,
49 
50  /** Constructor used when spawing crowd clones
51  * needs to be public so std::make_unique can call it.
52  * Do not use directly unless you've really thought it through.
53  */
55 
56  /** This allows us to allocate the necessary data for the DataLocality::queue
57  */
58  void startBlock(int steps) override;
59 
60  /** standard interface
61  */
62  std::unique_ptr<OperatorEstBase> spawnCrowdClone() const override;
63 
64  /** accumulate 1 or more walkers of SelfHealingOverlap samples
65  */
67  const RefVector<ParticleSet>& psets,
68  const RefVector<TrialWaveFunction>& wfns,
69  const RefVector<QMCHamiltonian>& hams,
70  RandomBase<FullPrecRealType>& rng) override;
71 
72  /** this allows the EstimatorManagerNew to reduce without needing to know the details
73  * of SelfHealingOverlap's data.
74  *
75  * can use base class default until crowd level SelfHealingOverlap
76  * estimators don't have a copy of the density grid.
77  */
78  void collect(const RefVector<OperatorEstBase>& operator_estimators) override;
79 
80  /** this allows the EstimatorManagerNew to reduce without needing to know the details
81  * of SelfHealingOverlap's data.
82  *
83  * can use base class default until crowd level SelfHealingOverlap estimators don't have a copy of the density grid.
84  */
85  //void collect(const OperatorEstBase& oeb);
86 
87  /** this gets us into the hdf5 file
88  *
89  * Just parroting for now don't fully understand.
90  *, needs to be unraveled and simplified the hdf5 output is another
91  * big state big coupling design.
92  */
93  void registerOperatorEstimator(hdf_archive& file) override;
94 
95 private:
96  SelfHealingOverlap(const SelfHealingOverlap& md) = default;
97 };
98 
99 } // namespace qmcplusplus
100 
101 #endif /* QMCPLUSPLUS_SHOVERLAP_H */
a class that defines a supercell in D-dimensional Euclean space.
Class that collects MSD coefficient values via the Self-Healing overlap.
helper functions for EinsplineSetBuilder
Definition: Configuration.h:43
void accumulate(const RefVector< MCPWalker > &walkers, const RefVector< ParticleSet > &psets, const RefVector< TrialWaveFunction > &wfns, const RefVector< QMCHamiltonian > &hams, RandomBase< FullPrecRealType > &rng) override
accumulate 1 or more walkers of SelfHealingOverlap samples
QTBase::RealType RealType
Definition: Configuration.h:58
CrystalLattice< OHMMS_PRECISION, OHMMS_DIM > ParticleLayout
Definition: Configuration.h:79
QMCTraits::ComplexType ComplexType
class to handle hdf file
Definition: hdf_archive.h:51
QTBase::ComplexType ComplexType
Definition: Configuration.h:59
const char walkers[]
Definition: HDFVersion.h:36
void collect(const RefVector< OperatorEstBase > &operator_estimators) override
this allows the EstimatorManagerNew to reduce without needing to know the details of SelfHealingOverl...
std::unique_ptr< OperatorEstBase > spawnCrowdClone() const override
standard interface
SelfHealingOverlap(SelfHealingOverlapInput &&inp, const TrialWaveFunction &wfn, DataLocality dl=DataLocality::crowd)
Constructor for SelfHealingOverlapInput.
Native representation for Self-Healing Overlap Estimator inputs.
QTBase::ValueType ValueType
Definition: Configuration.h:60
const SelfHealingOverlapInput input_
An abstract class for gridded estimators.
QTBase::PosType PosType
Definition: Configuration.h:61
std::vector< std::reference_wrapper< T > > RefVector
Class to represent a many-body trial wave function.
DataLocality
data locality with respect to walker buffer
Definition: DataLocality.h:19
void startBlock(int steps) override
This allows us to allocate the necessary data for the DataLocality::queue.
void registerOperatorEstimator(hdf_archive &file) override
this allows the EstimatorManagerNew to reduce without needing to know the details of SelfHealingOverl...