Fix: Remove nonzero tails beyond spherical Bessel projector cutoffs (Useful Information for updating DeePKS benchmark data)#7673
Merged
Conversation
mohanchen
approved these changes
Jul 24, 2026
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.
Summary
This PR fixes generated DeePKS spherical-Bessel projector files that contained nonzero oscillatory samples beyond their declared cutoff radius. It preserves the requested radial spacing, keeps generated output meshes compatible with Simpson integration, repairs the affected versioned projector files, warns about inconsistent orbital metadata during reading, and refreshes all numerical references affected by the corrected projectors.
Background
Bessel_Basis::init_TableOne()extends its internal radial mesh with auxiliary points for Simpson integration. The same mesh was previously written directly tojle.orb, so a file declaring a 2.0 Bohr cutoff and a 0.01 Bohr spacing could contain 205 points and extend to 2.04 Bohr. Because the spherical Bessel function grows again after its zero at the cutoff, those extra points formed a nonzero tail and caused inconsistent results between grid and two-center projector integrations.Changes
drwhen writing generated projectors.Meshso thatAtomicRadialsreader and the legacyLCAO_Orbitalsreader when the declared cutoff differs fromjle.orbfiles in examples, fixtures, and DeePKS integration cases.result.reffiles, and 8 CSR references. Existingtotaltimerefvalues are preserved.Thread-sensitive integration references
The Gamma-point
nspin=2cases 29 and 31 follow different SCF trajectories with one and two OpenMP threads per MPI process. GitHub CI runs these cases with 4 MPI processes andOMP_NUM_THREADS=2, so their references were generated with the same configuration. No test threshold was relaxed.Verification
MODULE_IO_bessel_basis_test: 3/3 passed, including the even-mesh safeguard case.MODULE_NAO_atomic_radials: 5/5 passed.MODULE_AO_ORB_read_test --gtest_filter='LcaoOrbitalsTest.ReadOrbitals': passed.09_DeePKSintegration suite with 4 MPI processes andOMP_NUM_THREADS=2: all 31 cases passed..orbfiles among the 81 files with complete cutoff and mesh metadata.git diff --check: passed.Compatibility
Existing user projector files are not modified automatically. Readers only report inconsistent metadata and continue with the original samples. Newly generated files either end at the declared cutoff or retain only zero-valued samples beyond it, and their output meshes remain compatible with Simpson integration. No INPUT parameter or DeePKS model format is changed.
Documentation
No user-facing INPUT parameter or documented interface changes, so generated parameter documentation does not need an update. The compatibility behavior and the new reader warning are described in this PR body; intermediate diagnostic reports and figures are intentionally excluded from the PR.
Governance notes
The generator and reader changes do not introduce new cross-layer global dependencies or new header dependencies.