From fab56a9301e4ad14ce1e97c490f2b0527b5d157d Mon Sep 17 00:00:00 2001 From: Nico Date: Tue, 5 Dec 2023 11:55:39 +0100 Subject: [PATCH] introduce default jastrow as elec-elec pade jastrow --- qmctorch/scf/molecule.py | 2 +- qmctorch/solver/solver.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/qmctorch/scf/molecule.py b/qmctorch/scf/molecule.py index 85a027fb..f3b51900 100644 --- a/qmctorch/scf/molecule.py +++ b/qmctorch/scf/molecule.py @@ -41,7 +41,7 @@ def __init__( # pylint: disable=too-many-arguments calculator (str, optional): selet scf calculator. Defaults to 'adf'. - pyscf : PySCF calculator - adf : ADF2020+ calculator - - adf2019 : ADF2019 calculatori + - adf2019 : ADF2019 calculator scf (str, optional): select scf level of theory. Defaults to 'hf'. - hf : perform a Hatree-Fock calculation to obtain the molecular orbital coefficients - dft : perform a density functional theory using the local density approximation diff --git a/qmctorch/solver/solver.py b/qmctorch/solver/solver.py index 3cda3f07..bda0cf8d 100644 --- a/qmctorch/solver/solver.py +++ b/qmctorch/solver/solver.py @@ -106,8 +106,9 @@ def set_params_requires_grad(self, wf_params=True, geo_params=False): self.wf.fc.weight.requires_grad = wf_params if hasattr(self.wf, "jastrow"): - for param in self.wf.jastrow.parameters(): - param.requires_grad = wf_params + if self.wf.jastrow is not None: + for param in self.wf.jastrow.parameters(): + param.requires_grad = wf_params # no opt the atom positions self.wf.ao.atom_coords.requires_grad = geo_params