-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ProjwfcParser: fixed a bug when parsing pdos files #165
Conversation
@zhubonan thanks for the fix. As you noticed, there is an incompatibility with the current |
Current implementation relying on the order of pdos files to be consistent with that of projections in out_file. However, the the `<prefix>.pdos_atom#xxx` file were not sorted correctly. Natural sorting should be used to get the correct order of files.
@sphuber No problem I have rebased into the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this version does not support aiida-core version newer than 0.12.* anyway, there is no point in having the try catch
remote_folders = self.get_outputs(node_type=RemoteData) | ||
# Maintain compatibility with aiida_core 0.12.0 and older versions | ||
try: | ||
remote_folders = self.get_outputs(type=RemoteData) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove this try/catch. This version will only support 0.12.* and older anyway. In the v3*
series we will make sure to update the signature for aiida-core v1.0.0
and higher.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I get confused when this change of method signature was made - it was there since 0.11.2
. The try
was for maintain compatibility with versions older than that and not related to v1.0.0
and higher.
Here is the commit that made the change aiidateam/aiida-core@991596e.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have remove this commit.
@zhubonan thanks a lot for your contribution |
Fixes #166
Current implementation relying on the order of pdos files to be consistent with that of projections in
<prefix>.out
. However, names of<prefix>.pdos_atom#xxx
files with array of pdos were not sorted correctly, giving wrongly associated PDOS arrays. Natural sorting is now used to get the correct order of files.Also, I removed one line of unnecessary if compare.