13 #ifndef QMCPLUSPLUS_SOA_LINEARCOMIBINATIONORBITALSET_TEMP_H 14 #define QMCPLUSPLUS_SOA_LINEARCOMIBINATIONORBITALSET_TEMP_H 42 std::shared_ptr<OffloadValueMatrix>
C;
51 std::unique_ptr<basis_type>&& bs,
66 std::unique_ptr<SPOSet>
makeClone() const final;
base class for Single-particle orbital sets
OrbitalSetTraits< ValueType >::HessVector HessVector
OffloadMatrix< ValueType > OffloadValueMatrix
void mw_evaluateVGL(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< ParticleSet > &P_list, int iat, const RefVector< ValueVector > &psi_v_list, const RefVector< GradVector > &dpsi_v_list, const RefVector< ValueVector > &d2psi_v_list) const final
evaluate the values, gradients and laplacians of this single-particle orbital sets of multiple walker...
bool hasIonDerivs() const final
Query if this SPOSet has an explicit ion dependence.
helper functions for EinsplineSetBuilder
int getBasisSetSize() const
return the size of the basis set
std::string getClassName() const final
return class name
void evaluateGradSourceRow(const ParticleSet &P, int iel, const ParticleSet &source, int iat_src, GradVector &grad_phi) final
Returns a row of d/dR_iat phi_j(r) evaluated at position r.
std::unique_ptr< SPOSet > makeClone() const final
make a clone of itself every derived class must implement this to have threading working correctly...
ResourceHandle manages the temporary resource referenced from a collection.
void evaluate_ionderiv_v_row_impl(const vgl_type &temp, GradVector &dlogdet) const
Unpacks data in vgl object and calculates/places ionic gradient of a single row (phi_j(r)) into dlogd...
const bool Identity
true if C is an identity matrix
A ParticleSet that handles virtual moves of a selected particle of a given physical ParticleSet Virtu...
NewTimer & mo_timer_
timer for MO
std::unique_ptr< basis_type > myBasisSet
pointer to the basis set
OrbitalSetTraits< ValueType >::ValueMatrix ValueMatrix
LatticeGaussianProduct::GradType GradType
std::shared_ptr< OffloadValueMatrix > C_copy
a copy of the original C before orbital rotation is applied;
SoA adaptor class for Vector<TinyVector<T,D> >
bool isRotationSupported() const final
return true if this SPOSet can be wrappered by RotatedSPO
void applyRotation(const ValueMatrix &rot_mat, bool use_stored_copy) final
apply rotation to all the orbitals
Timer accumulates time and call counts.
void evaluateGradSource(const ParticleSet &P, int first, int last, const ParticleSet &source, int iat_src, GradMatrix &grad_phi) final
Calculate ion derivatives of SPO's.
void evaluateVGL(const ParticleSet &P, int iat, ValueVector &psi, GradVector &dpsi, ValueVector &d2psi) final
evaluate the values, gradients and laplacians of this single-particle orbital set ...
void evaluate_vghgh_impl(const vghgh_type &temp, ValueVector &psi, GradVector &dpsi, HessVector &d2psi, GGGVector &dghpsi) const
Unpacks data in vghgh_type temp object into wavefunction friendly data structures for value...
LCAOrbitalSet(const std::string &my_name, std::unique_ptr< basis_type > &&bs, size_t norbs, bool identity, bool use_offload)
constructor
OrbitalSetTraits< ValueType >::ValueVector ValueVector
void mw_evaluateVGLImplGEMM(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< ParticleSet > &P_list, int iat, OffloadMWVGLArray &phi_vgl_v) const
QMCTraits::IndexType IndexType
vgh_type Temph
These are temporary VectorSoAContainers to hold value, gradient, and hessian for all basis or SPO fun...
void evaluateVGH(const ParticleSet &P, int iat, ValueVector &psi, GradVector &dpsi, HessVector &grad_grad_psi) final
evaluate the values, gradients and hessians of this single-particle orbital set
OrbitalSetTraits< ValueType >::GradMatrix GradMatrix
Specialized paritlce class for atomistic simulations.
Array< ValueType, 3, OffloadPinnedAllocator< ValueType > > OffloadMWVGLArray
void finalizeConstruction() override
update C on device
void evaluateValue(const ParticleSet &P, int iat, ValueVector &psi) final
evaluate the values of this single-particle orbital set
const IndexType BasisSetSize
number of Single-particle orbitals
VectorSoaContainer< T, 10 > vgh_type
OrbitalSetTraits< ValueType >::ValueVector ValueVector
std::shared_ptr< OffloadValueMatrix > C
pointer to matrix containing the coefficients
vgl_type Tempv
Tempv(OrbitalSetSize) Tempv=C*Temp.
RefVectorWithLeader< basis_type > extractBasisRefList(const RefVectorWithLeader< SPOSet > &spo_list) const
helper function for extracting a list of basis sets from a list of LCAOrbitalSet
void mw_evaluateValue(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< ParticleSet > &P_list, int iat, const RefVector< ValueVector > &psi_v_list) const final
evaluate the values this single-particle orbital sets of multiple walkers
void evaluate_vgh_impl(const vgh_type &temp, ValueVector &psi, GradVector &dpsi, HessVector &d2psi) const
These two functions unpack the data in vgh_type temp object into wavefunction friendly data structure...
void acquireResource(ResourceCollection &collection, const RefVectorWithLeader< SPOSet > &spo_list) const final
acquire a shared resource from collection
void mw_evaluateValueVPsImplGEMM(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< const VirtualParticleSet > &vp_list, OffloadMWVArray &phi_v) const
packed walker GEMM implementation with multi virtual particle sets
void checkObject() const final
check consistency between Identity and C
vghgh_type Tempghv
Nbasis x [1(value)+3(gradient)+6(hessian)+10(grad_hessian)].
void evaluateDetRatios(const VirtualParticleSet &VP, ValueVector &psi, const ValueVector &psiinv, std::vector< ValueType > &ratios) final
evaluate determinant ratios for virtual moves, e.g., sphere move for nonlocalPP
Define determinant operators.
std::vector< std::reference_wrapper< T > > RefVector
vgh_type Temphv
Norbitals x [1(value)+3(gradient)+6(hessian)].
void releaseResource(ResourceCollection &collection, const RefVectorWithLeader< SPOSet > &spo_list) const final
return a shared resource to collection
ResourceHandle< LCAOMultiWalkerMem > mw_mem_handle_
OrbitalSetTraits< ValueType >::GradHessVector GGGVector
void evaluate_ionderiv_v_impl(const vgl_type &temp, int i, GradMatrix &dlogdet) const
Unpacks data in vgl object and calculates/places ionic gradient result into dlogdet.
OrbitalSetTraits< ValueType >::GradVector GradVector
void createResource(ResourceCollection &collection) const final
initialize a shared resource and hand it to collection
const bool useOMPoffload_
whether offload is on or off at runtime.
void mw_evaluateVGLandDetRatioGrads(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< ParticleSet > &P_list, int iat, const std::vector< const ValueType *> &invRow_ptr_list, OffloadMWVGLArray &phi_vgl_v, std::vector< ValueType > &ratios, std::vector< GradType > &grads) const final
evaluate the values, gradients and laplacians of this single-particle orbital sets and determinant ra...
VectorSoaContainer< T, 20 > vghgh_type
void evaluate_ionderiv_vgl_impl(const vghgh_type &temp, int i, GradMatrix &dlogdet, HessMatrix &dglogdet, GradMatrix &dllogdet) const
Unpacks data in vgl object and calculates/places ionic gradient of value, electron gradient...
void storeParamsBeforeRotation() final
store parameters before getting destroyed by rotation.
void evaluate_vgl_impl(const vgl_type &temp, ValueVector &psi, GradVector &dpsi, ValueVector &d2psi) const
helper functions to handle Identity
LatticeGaussianProduct::ValueType ValueType
vghgh_type Tempgh
These are temporary VectorSoAContainers to hold value, gradient, hessian, and gradient hessian for al...
vgl_type Temp
Temp(BasisSetSize) : Row index=V,Gx,Gy,Gz,L.
class to handle linear combinations of basis orbitals used to evaluate the Dirac determinants.
void setOrbitalSetSize(int norbs) final
set the OrbitalSetSize and Identity=false and initialize internal storages
VectorSoaContainer< T, OHMMS_DIM+2 > vgl_type
void evaluate_notranspose(const ParticleSet &P, int first, int last, ValueMatrix &logdet, GradMatrix &dlogdet, ValueMatrix &d2logdet) final
evaluate the values, gradients and laplacians of this single-particle orbital for [first...
OrbitalSetTraits< ValueType >::GradHessMatrix GGGMatrix
NewTimer & basis_timer_
timer for basis set
A D-dimensional Array class based on PETE.
bool isOMPoffload() const override
Query if this SPOSet uses OpenMP offload.
void mw_evaluateValueImplGEMM(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< ParticleSet > &P_list, int iat, OffloadMWVArray &phi_v) const
packed walker GEMM implementation
void mw_evaluateDetRatios(const RefVectorWithLeader< SPOSet > &spo_list, const RefVectorWithLeader< const VirtualParticleSet > &vp_list, const RefVector< ValueVector > &psi_list, const std::vector< const ValueType *> &invRow_ptr_list, std::vector< std::vector< ValueType >> &ratios_list) const final
evaluate determinant ratios for virtual moves, e.g., sphere move for nonlocalPP, of multiple walkers ...
void evaluateVGHGH(const ParticleSet &P, int iat, ValueVector &psi, GradVector &dpsi, HessVector &grad_grad_psi, GGGVector &grad_grad_grad_psi) final
evaluate the values, gradients, hessians, and grad hessians of this single-particle orbital set ...
OrbitalSetTraits< ValueType >::HessMatrix HessMatrix
Declaration of a base class of BasisSet.