Replies: 1 comment
-
|
I think that keeping the old dm-eri contraction could be better. This is mostly for efficiency concern when density matrix is not low-rank enough. Assuming that we have to dealing with DF-K integral,
I believe that this technique may not only be applied to non-hermitian density matrix, but could also applicable to sy/he (symmetric/hermitian). However, most sy/he cases has already been optimized by passing tagged ndarray Also, I think that this topic is related to building DF-JK with different left (bra) and right (ket) coefficients, something similar to Psi4's |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, the DF JK evaluation of non-hermitian dm has to go through the dm-eri contraction, like
pyscf/pyscf/df/df_jk.py
Lines 341 to 366 in ef75f41
If replacing this with contraction of eri and left/right mo after svd, it will be roughly 4x faster, depends on the rank of dm. A simple demo can be
https://github.com/jeanwsr/pyscf/blob/cd65e816a6f166c68163fe1a384bac1a0565b90c/pyscf/df/df_jk.py#L341-L375
I believe it's useful to add this feature, which can benefit the efficiency of scf stability and other functions (I'm not clear how many functions use this, but at least this replacement did not break any test).
But there's a few questions I'm not sure:
It seems not so convenient to set and pass the
use_svdparameter in a stability function.elif getattr(dm, 'mo_coeff', None) is not None:after decomposition. I'm not sure whether we really have df jk calls with such hermitian dm.Beta Was this translation helpful? Give feedback.
All reactions