Closed JaGeo closed 1 year ago
This is tricky, the current default of atomate2 is to assume a material is metallic, in terms of the density of k-points and the smearing parameters. The idea is that if you use a double relax maker on an insulator, the first relaxation will have metallic parameters and the second relax with have insulating parameters.
In practice, I've found that this is unnecessarily expensive when screening lots of insulators/semiconductors. One way to get around this problem then would be to switch the behaviour and assume insulating for the first relaxation. This would get around the issue identified here.
Another issue I have is the automatic setting of KSPACING based on the band gap. It results in weird behaviour when going from a GGA calculation to a HSE calculation, as the band gap increases so the kspacing decreases, but you'd really expect the kspacing to stay the same.
Therefore, I'm thinking to:
Thanks for explaining the reasoning.
An alternative could be: setting ISMEAR=0 in the first optimization. This would have the advantage that it would work for optimizations of metals and insulators. The other options (kpoints) could be kept.
But I think switching to a less strict setting might have some advantages. Thus, I do like your suggestion of making the insulating material default. I found the run times for my NaCl tests too long.
What would be your approach to optimize structures that haven't been preoptimized before with the current Makers? If I run VASP without automation for a structure optimization, I would typically use a larger kspacing first to pre-optimize and then refine with a very small kspacing for the last 10-15 ionic steps. Is there currently a predefined maker for this or would I need to customize? I think this could save a lot of computing time for optimizations. For metals, one might however think about if two optimization runs are then still enough to reach a well-converged structure or if one needs to do three.
Coming back to this again: I very much like the idea of introducing 3 band gap settings. I think people would like to have consistent kspacings for all of their runs for a similar compound.
@JaGeo, do you think you'd be able to submit a PR with this feature? If not, I can try and look into it but might take a some time due to other commitments.
@utf I am currently also not sure how fast I/we can proceed here. We are not actively working on it at the moment.
Joining this thread, wondering if it is worth having more discussion on any of the following:
Not sure if this is the best place for discussion, or if a new issue would be better.
Describe the bug
ISMEAR=2
is set for non-metals.I try to optimize the structure of NaCl with the following script (atomate development version):
POSCAR.NaCl.vasp
I end up with this INCAR:
I think it is due the combination of this line here https://github.com/materialsproject/atomate2/blob/73b9b3e71be8addc237c9d6cfce3dd1c09aa2ca8/src/atomate2/vasp/sets/core.py#L43
And this one here: https://github.com/materialsproject/atomate2/blob/73b9b3e71be8addc237c9d6cfce3dd1c09aa2ca8/src/atomate2/vasp/sets/base.py#L976
I would maybe suggest to switch to a default value of "None" to avoid such errors. Happy to hear what other people are thinking.
(I can of course try to fix it but I suspect it might concern many parts of the code ...)