Draft: Enable complex multi-k PEXSI path for LCAO#7381
Open
JohnHe233 wants to merge 3 commits into
Open
Conversation
Collaborator
|
Nice try! I will test the correctness of total energy on my machine later. A few small questions:
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reminder
ElecState, Hamilt, Operator or Psi? (ignore if not applicable)
Linked Issue
Fix #...
Unit Tests and/or Case Tests for my changes
DiagoPexsiRefactorTest.UsesInjectedSolverAndOwnedDensityBuffersIPexsiSolverto test solver injection and owned DM/EDM bufferswithout invoking the real PEXSI/MPI sparse solve path.
tools/pexsi/check_lcao_10case_regression.pyfor LCAO PEXSI regressionchecks.
ks_solver pexsi.5.0e-7 eVtotal-energy tolerance.4 MPI ranks / 1800 stestlimit.
What's changed?
format.
nspin=1to avoid double-counting spindegeneracy.
ElecStateLCAO::dm2rho.pexsi::IPexsiSolver.DiagoPexsito depend on the interface instead of directly depending onPEXSI_Solver.DiagoPexsi.std::vector<std::vector<T>>for storage.std::vector<T*> DM/EDMinterface for current callers.entered by a multi-k case.
MPI_Alltoallv.countMatrixDistributionzero-value check fromfabs(A[i] < 1e-31)tofabs(A[i]) < 1e-31.TransMAT2CCStimer coverage to separate ABACUS-side matrix conversion costfrom PEXSI solve cost.
Possible behavior changes
ks_solver pexsino longer fail immediately at theprevious unsupported complex-path boundary.
enters the real path.
in this branch, which improves energy consistency for some cases but can
significantly increase runtime.
implementation and repeated PEXSI setup/factorization.
Any changes of core modules? (ignore if not applicable)
DiagoPexsito support solver-interface injection, owned densitybuffers, complex multi-k PEXSI calls and global chemical-potential accumulation.
HSolverLCAOintegration to pass k-point weights and handle PEXSI DM/EDMoutput.
ElecStateLCAO.IPexsiSolver.