-
Notifications
You must be signed in to change notification settings - Fork 80
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
Problematic translation in HubbardStructureData
#991
Comments
Hi @t-reents , this is NOT a bug, but it is the intended way. This is because You can in fact inspect that in you hubbard paramters one of the translations is |
Probably we should raise a WARNING when this happens, but the |
Hi @bastonero thanks a lot for the explanation! This clarifies a lot. |
I tried to run a
PwCalculation
calculation using aHubbardStructureData
that was generated based on the followingStructureData
.Generating the
HubbardStructureData
:The calculation fails during the presubmit call, when calling
HubbardUtils(structure).get_hubbard_card()
. Inspecting the output ofhubbard_structure.hubbard.parameters
explains this failure:The translation in the second entry is not part of the
QE_TRANSLATIONS
(https://github.com/aiidateam/aiida-quantumespresso/blob/main/src/aiida_quantumespresso/utils/hubbard.py#L21-L24), wherefore the following function call excepts (https://github.com/aiidateam/aiida-quantumespresso/blob/main/src/aiida_quantumespresso/utils/hubbard.py#L326).If one would use the second O site, everything would work out. However, this method (https://github.com/aiidateam/aiida-quantumespresso/blob/main/src/aiida_quantumespresso/data/hubbard_structure.py#L214) selects the first occurring site that matches the
kind_name
. Apparently, this logic seems to work out in general, but in this case, it somehow breaks.The text was updated successfully, but these errors were encountered: