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

pmg update #1622

Closed
wants to merge 14 commits into from
Closed

pmg update #1622

wants to merge 14 commits into from

Conversation

Andrew-S-Rosen
Copy link
Member

@Andrew-S-Rosen Andrew-S-Rosen commented Jan 26, 2024

TODO: also bump monty

@Andrew-S-Rosen Andrew-S-Rosen added the dependencies Dependency update or issue label Jan 29, 2024
auto-merge was automatically disabled February 7, 2024 03:40

Pull request was closed

@Andrew-S-Rosen Andrew-S-Rosen deleted the Andrew-S-Rosen-patch-4 branch February 8, 2024 17:13
Andrew-S-Rosen added a commit that referenced this pull request Feb 17, 2024
Closes #1311.

This PR allows support for Pymatgen-formatted input sets in the `Vasp`
calculator and, by extension, all VASP recipes. The `Vasp` calculator
takes a new keyword argument `pmg_input_set: DictSet | None = None`
that, if specified, would act in the same was a preset by providing a
list of default parameters to use. Any class inheriting from
[`pymatgen.io.vasp.sets.DictSet`](https://github.com/materialsproject/pymatgen/blob/main/pymatgen/io/vasp/sets.py)
is usable. This also means we can use the MP-compatible, pymatgen input
sets directly without having to try and duplicate them 1:1 in `quacc`,
such as by doing `pmg_input_set = MPRelaxSet`.

I also renamed `mp_relax_job` to `mp_metagga_relax_job` (and similar for
the rest) to allow for a future addition of the GGA MP workflows.

Requires: A new release of pymatgen to be minted (bumped in #1622).

Example:

```python
from ase.build import bulk
from quacc.calculators.vasp import Vasp
from pymatgen.io.vasp.sets import MPRelaxSet

atoms = bulk("Fe") * (2, 1, 1)
atoms[0].symbol = "O"
calc = Vasp(atoms, pmg_input_set=MPRelaxSet)
print(calc.parameters)
```

---------

Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Dependency update or issue
Development

Successfully merging this pull request may close these issues.

1 participant