Refactor spin-flip TDDFT/TDA including analytic gradient#731
Open
wtpeter wants to merge 3 commits intopyscf:masterfrom
Open
Refactor spin-flip TDDFT/TDA including analytic gradient#731wtpeter wants to merge 3 commits intopyscf:masterfrom
wtpeter wants to merge 3 commits intopyscf:masterfrom
Conversation
- Keep all initial guess vectors in the first iteration - Implement double Gram-Schmidt orthogonalization for better stability
- Add davidson_nosym1 diagonalizer in tdscf._lr_eig for Spin-flip TDDFT. - Refactor SpinFlipTDA/TDDFT classes in tdscf.uhf and add post-processing. - Update test suite: add test_sftda.py, update test_sftddft.py, and remove obsolete tests. - Apply necessary code formatting.
- Refactor analytic gradient implementations in grad/tduks_sf.py. - Add df/grad/tduks_sf.py to support density-fitting gradients. - Add for SF-TDA and SF-TDDFT analytic gradient. - Consolidate and optimize SF-TDA/TDDFT tests to reduce CI runtime. - Improve exception messages in grad/tduks.py.
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.
This PR refactors the spin-flip TDDFT/TDA module with the following changes:
Davidson Solver: Improve stability with double Gram-Schmidt and keep all initial guess vectors in the first iteration to help convergence in
tdscf._lr_eig.eigh. Adddavidson_nosym1for SF-TDDFT.Core Refactor: Refactor
SpinFlipTDAandSpinFlipTDDFTclasses intdscf.uhf, and add necessary post-processing functions.Gradients: Refactor SF-TDDFT analytic gradients (supporting both with and without density-fitting).
Tests: Add and update tests for SF-TDDFT/TDA and their analytic gradients.
Others: Improve some error messages and remove obsolete test files.
Note: Example input files are not included in this PR.