-
Notifications
You must be signed in to change notification settings - Fork 363
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Active space: Implement ERI calculation using half-transformed integr…
…als (#3082) This PR implements several options which have already been available in the input but were not implemented: half-transformed integral calculation algorithm: borrowed from the GPW-MP2 method. It is a much fast algorithm to calculate the integrals, especially if all orbitals are correlated. This implementation is 2-3 faster than the legacy FULL_GPW algorithm. store_wfn: this option enables the on-the-fly calculation the orbital functions on a grid. It increases the costs by 40 % in case of half-transformed integrals (no idea in case of the FULL_GPW method but probably much more expensive than the with storing the orbitals). It allows to reduce the memory footprint significantly, especially in case of molecular systems with their larger number of grid points subgroups: As in the WFC module, the calculation of integrals is possible in subgroups trading memory for reduced communication. I measured a threefold improvement. The new implementation is GPU accelerated as it relies on DBCSR and the grid code for the integration of the potential (untested). A bunch of new regression tests (QS/regtest-as-2, QS/regtest-as-3) This implementation works well with the GPW method but is inadequate if highly localised AOs are present (known issue of GPW). In these cases, a GAPW-like implementation would be advantageous but a matter of implementation.
- Loading branch information
Showing
19 changed files
with
1,216 additions
and
305 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# runs are executed in the same order as in this file | ||
# the second field tells which test should be run in order to compare with the last available output | ||
# e.g. 0 means do not compare anything, running is enough | ||
# 1 compares the last total energy in the file | ||
# for details see cp2k/tools/do_regtest | ||
# | ||
h2_gpw_nostore.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_nostore.inp 92 1e-8 4.08481739 | ||
h2_gpw_ht.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_ht.inp 92 1e-8 4.08599253 | ||
h2_gpw_ht_nostore.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_ht_nostore.inp 92 1e-8 4.08599253 | ||
h2_gpw_nostore_group.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_nostore_group.inp 92 1e-8 4.08481739 | ||
h2_gpw_ht_group.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_ht_group.inp 92 1e-8 4.08599253 | ||
h2_gpw_ht_nostore_group.inp 1 1e-12 -1.12622646044780 | ||
h2_gpw_ht_nostore_group.inp 92 1e-8 4.08599253 | ||
#EOF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
&FORCE_EVAL | ||
METHOD Quickstep | ||
&DFT | ||
&QS | ||
METHOD GPW | ||
&END QS | ||
&XC | ||
&XC_FUNCTIONAL NONE | ||
&END XC_FUNCTIONAL | ||
&HF 1.0 | ||
&END HF | ||
&END XC | ||
&POISSON | ||
POISSON_SOLVER ANALYTIC | ||
PERIODIC NONE | ||
&END POISSON | ||
&MGRID | ||
CUTOFF 500 | ||
&END MGRID | ||
&SCF | ||
ADDED_MOS 3 | ||
MAX_SCF 10 | ||
&RESTART OFF | ||
&END RESTART | ||
&END PRINT | ||
&END SCF | ||
&AO_MATRICES | ||
CORE_HAMILTONIAN TRUE | ||
KINETIC_ENERGY TRUE | ||
POTENTIAL_ENERGY TRUE | ||
&END AO_MATRICES | ||
&END PRINT | ||
&ACTIVE_SPACE | ||
ACTIVE_ELECTRONS 2 | ||
ACTIVE_ORBITALS 2 | ||
ISOLATED_SYSTEM TRUE | ||
&ERI | ||
METHOD GPW_HALF_TRANSFORM | ||
PERIODICITY 0 0 0 | ||
&END ERI | ||
&ERI_GPW | ||
CUTOFF 500 | ||
&END ERI_GPW | ||
&FCIDUMP | ||
FILENAME __STD_OUT__ | ||
&END FCIDUMP | ||
&END ACTIVE_SPACE | ||
&END DFT | ||
&SUBSYS | ||
&CELL | ||
ABC 6.0 6.0 6.0 | ||
PERIODIC NONE | ||
&END CELL | ||
&COORD | ||
H 0.000 0.000 0.356 | ||
H 0.000 0.000 -0.356 | ||
&END COORD | ||
&KIND H | ||
BASIS_SET 6-31G* | ||
POTENTIAL GTH-HF | ||
&END KIND | ||
&END SUBSYS | ||
&END FORCE_EVAL | ||
&GLOBAL | ||
RUN_TYPE ENERGY | ||
PRINT_LEVEL LOW | ||
PROJECT h2_gpw_ht | ||
&END GLOBAL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
&FORCE_EVAL | ||
METHOD Quickstep | ||
&DFT | ||
&QS | ||
METHOD GPW | ||
&END QS | ||
&XC | ||
&XC_FUNCTIONAL NONE | ||
&END XC_FUNCTIONAL | ||
&HF 1.0 | ||
&END HF | ||
&END XC | ||
&POISSON | ||
POISSON_SOLVER ANALYTIC | ||
PERIODIC NONE | ||
&END POISSON | ||
&MGRID | ||
CUTOFF 500 | ||
&END MGRID | ||
&SCF | ||
ADDED_MOS 3 | ||
MAX_SCF 10 | ||
&RESTART OFF | ||
&END RESTART | ||
&END PRINT | ||
&END SCF | ||
&AO_MATRICES | ||
CORE_HAMILTONIAN TRUE | ||
KINETIC_ENERGY TRUE | ||
POTENTIAL_ENERGY TRUE | ||
&END AO_MATRICES | ||
&END PRINT | ||
&ACTIVE_SPACE | ||
ACTIVE_ELECTRONS 2 | ||
ACTIVE_ORBITALS 2 | ||
ISOLATED_SYSTEM TRUE | ||
&ERI | ||
METHOD GPW_HALF_TRANSFORM | ||
PERIODICITY 0 0 0 | ||
&END ERI | ||
&ERI_GPW | ||
CUTOFF 500 | ||
GROUP_SIZE 1 | ||
&END ERI_GPW | ||
&FCIDUMP | ||
FILENAME __STD_OUT__ | ||
&END FCIDUMP | ||
&END ACTIVE_SPACE | ||
&END DFT | ||
&SUBSYS | ||
&CELL | ||
ABC 6.0 6.0 6.0 | ||
PERIODIC NONE | ||
&END CELL | ||
&COORD | ||
H 0.000 0.000 0.356 | ||
H 0.000 0.000 -0.356 | ||
&END COORD | ||
&KIND H | ||
BASIS_SET 6-31G* | ||
POTENTIAL GTH-HF | ||
&END KIND | ||
&END SUBSYS | ||
&END FORCE_EVAL | ||
&GLOBAL | ||
RUN_TYPE ENERGY | ||
PRINT_LEVEL LOW | ||
PROJECT h2_gpw_ht_group | ||
&END GLOBAL |
Oops, something went wrong.