Skip to content
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

Are magnetic host simulations properly parsed? #46

Open
JPchico opened this issue Dec 4, 2020 · 7 comments
Open

Are magnetic host simulations properly parsed? #46

JPchico opened this issue Dec 4, 2020 · 7 comments

Comments

@JPchico
Copy link

JPchico commented Dec 4, 2020

@PhilippRue, @broeder-j I was testing bcc Fe to see the SCF when magnetism is considered (NSPIN=2, mag_init: True in the wf_parameters ). And the calculation is failing with the current error Finished [302] KKR parser retuned an error, when I do some checking I find that what is happening is that the parser is giving the error Error parsing output of KKR: orbital moment'.

When I see the output.2.txt I see that no orbital moment is printed, i.e. I'm running without NEWSOSOL, for what I can see in masci_tools it should not even reach this point to get the failure state.

I think that what is happening is that the use_newsosol function in matsci_tools is incorrectly identifying NEWSOSOL to be active (or use_chebychev) even when it is not. (I tried to parse them manually and I get this error) even when the line in question is

 <use_Chebychev_solver>=  F   use the Chebychev solver (former: 'NEWSOSOL')

I think that in the previous inputcard as the presence of the line was all that was necessary the use_newsosol just looks if a line containing NEWSOSOL is larger than 0, case which would not work here. One could perhaps replace it by something like this:

newsosol = True
if line.startswith("<use_Chebychev_solver>="):
     _temp = line.split()
    if _temp[1].lower() == "f":
        newsosol = False

P.S. How does one activate NEWSOSOL in the kkr_params?

@PhilippRue
Copy link
Member

yes, I realized this as well and I have just pushed a fix in masci-tools which I had already in my working directory. Since I change the capitalization in some keywords in masci-tools I also had to update aiida-kkr (although this is not properly tested yet) in commit 37329e0.

@PhilippRue
Copy link
Member

P.S. How does one activate NEWSOSOL in the kkr_params?

The 'traditional way' to activate this was to set RUNOPT=['NEWSOSOL'] in the kkrparams. Since the change to using the new style runoptions is not tested yet I advise using it like this.
At some point this will be done but there will be backwards compatibility to still support the RUNOPT-way of setting it.

@JPchico
Copy link
Author

JPchico commented Dec 4, 2020

Thanks @PhilippRue, I guess that then I should for the time being use a local installation of masci_tools instead of the pypi version until a release is done.

@PhilippRue
Copy link
Member

Thanks @PhilippRue, I guess that then I should for the time being use a local installation of masci_tools instead of the pypi version until a release is done.

yes that should work for now

@JPchico
Copy link
Author

JPchico commented Dec 5, 2020

@PhilippRue I think the modification to masci_tools will still fail as

    if itmp>=0 and 'NEWSOSOL' in tmptxt[itmp].upper():
        newsosol = True

will result in True as the line that contains use_Checbychev contains NEWSOSOL

<use_Chebychev_solver>=  F   use the Chebychev solver (former: 'NEWSOSOL')

and the check later

    if itmp>=0 :
        if tmptxt[itmp].split()[1][:1].upper()=='T':
            newsosol = True    

Only checks for a True condition, I think that one would need to add the search for the false condition to be able to capture it, otherwise it will always return True. A simple fix would be amending the function with this

    if itmp>=0 :
        if tmptxt[itmp].split()[1][:1].upper()=='T':
            newsosol = True    
        if tmptxt[itmp].split()[1][:1].upper()=='F':
            newsosol = False    

@PhilippRue
Copy link
Member

Oh yes, you are right, feel free to push a quick fix to the develop.

@JPchico
Copy link
Author

JPchico commented Dec 7, 2020

Sure thing I'll make it as soon as I have a free moment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

2 participants