From ea3feffbb0e882d562188c87b0f15140d2783d4b Mon Sep 17 00:00:00 2001 From: Janosh Riebesell Date: Tue, 6 Aug 2024 16:26:31 -0400 Subject: [PATCH 1/3] add back symprec kwarg to MP and MatPES set generators --- src/atomate2/vasp/sets/matpes.py | 6 ++++++ src/atomate2/vasp/sets/mp.py | 12 ++++++++++++ 2 files changed, 18 insertions(+) diff --git a/src/atomate2/vasp/sets/matpes.py b/src/atomate2/vasp/sets/matpes.py index f92c245b60..8886bfb479 100644 --- a/src/atomate2/vasp/sets/matpes.py +++ b/src/atomate2/vasp/sets/matpes.py @@ -24,9 +24,12 @@ class MatPesGGAStaticSetGenerator(MatPESStaticSet): xc_functional: Literal["R2SCAN", "PBE", "PBE+U"] = "PBE" auto_ismear: bool = False auto_kspacing: bool = False + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @@ -42,9 +45,12 @@ class MatPesMetaGGAStaticSetGenerator(MatPESStaticSet): xc_functional: Literal["R2SCAN", "PBE", "PBE+U"] = "R2SCAN" auto_ismear: bool = False auto_kspacing: bool = False + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @property diff --git a/src/atomate2/vasp/sets/mp.py b/src/atomate2/vasp/sets/mp.py index 954cb35fbb..0627834a1f 100644 --- a/src/atomate2/vasp/sets/mp.py +++ b/src/atomate2/vasp/sets/mp.py @@ -40,9 +40,12 @@ class MPGGARelaxSetGenerator(MPRelaxSet): bandgap_tol: float = None force_gamma: bool = True auto_metal_kpoints: bool = True + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @@ -57,9 +60,12 @@ class MPGGAStaticSetGenerator(MPStaticSet): inherit_incar: bool | None = False force_gamma: bool = True auto_metal_kpoints: bool = True + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @@ -72,9 +78,12 @@ class MPMetaGGAStaticSetGenerator(MPScanStaticSet): auto_kspacing: bool = True bandgap_tol: float = 1e-4 inherit_incar: bool | None = False + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @property @@ -118,9 +127,12 @@ class MPMetaGGARelaxSetGenerator(MPScanRelaxSet): auto_ismear: bool = False auto_kspacing: bool = True inherit_incar: bool | None = False + symprec: float | None = None def __post_init__(self) -> None: """Raise deprecation warning and validate.""" + if self.symprec is not None: + self.sym_prec = self.symprec super().__post_init__() @property From 93bf7c71fdfb258c9f4d402aabd5e3d499ede049 Mon Sep 17 00:00:00 2001 From: Janosh Riebesell Date: Tue, 6 Aug 2024 19:47:33 -0400 Subject: [PATCH 2/3] bump matgl==1.1.3 https://github.com/materialsvirtuallab/matgl/releases/tag/v1.1.3 --- pyproject.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 00516dd2e9..9001d892e8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ forcefields = [ "calorine<=2.2.1", "chgnet>=0.2.2", "mace-torch>=0.3.3", - "matgl>=1.1.1", + "matgl>=1.1.3", "quippy-ase>=0.9.14", "sevenn>=0.9.3", "torch<=2.2.1", # incompatibility with dgl if newer versions are used @@ -93,7 +93,7 @@ strict = [ "jobflow==0.1.18", "lobsterpy==0.4.5", "mace-torch>=0.3.3", - "matgl==1.1.2", + "matgl==1.1.3", "monty==2024.7.30", "mp-api==0.41.2", "numpy", From 92c7392932cb03471f34024c7c40211da1046089 Mon Sep 17 00:00:00 2001 From: Janosh Riebesell Date: Wed, 7 Aug 2024 10:03:13 -0400 Subject: [PATCH 3/3] trigger CI --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9001d892e8..3d39360ff5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -198,7 +198,7 @@ ignore = [ "S324", # use of insecure hash function "S507", # paramiko auto trust "S603", # use of insecure subprocess - "TD", # TODOs + "TD", # todos "TRY003", # long message outside exception class ] pydocstyle.convention = "numpy"