Fix OUTCAR parsing for VASP 5.4.4 with selective dynamics: variable m…#11
Open
eliakim-k wants to merge 1 commit into
Open
Fix OUTCAR parsing for VASP 5.4.4 with selective dynamics: variable m…#11eliakim-k wants to merge 1 commit into
eliakim-k wants to merge 1 commit into
Conversation
…ode count + robust dielectric-tensor parsing
Contributor
|
Can you generate diff that only changes the actual code. Also how is this different compared to e309fa3 |
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.
Fix OUTCAR parsing for VASP 5.4.4 (selective dynamics) and harden dielectric-tensor reading
Problem.
get_modes_from_OUTCAR assumes exactly 3xnat modes. With selective dynamics, VASP prints modes only for unconstrained atoms (3xN_free), so the fixed-length loop overruns the eigenvector block and crashes with AttributeError: 'NoneType' object has no attribute 'group'. Reproduced on VASP 5.4.4 (build Nov 2024) for a Cu(111) slab: nat=55, 48 frozen Cu atoms → only 21 modes exist, not 165.
Changes.
Note. Imaginary (f/i=) modes are skipped by the frequency detector (intended for off-resonant Raman of stable structures); mode indices then refer to real modes only.
Verified against a real OUTCAR: 11 real modes parsed with correct frequencies and the dielectric tensor read correctly.