Skip to content

Commit

Permalink
update "R2SCAN" to "r2SCAN" to match enum convention
Browse files Browse the repository at this point in the history
  • Loading branch information
tsmathis committed Sep 24, 2024
1 parent 3a15f68 commit b9be862
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion emmet-core/emmet/core/thermo.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def from_entries(
for e in entries:
entries_by_mpid[e.data["material_id"]].append(e)

entry_quality_scores = {"GGA": 1, "GGA+U": 2, "SCAN": 3, "R2SCAN": 4}
entry_quality_scores = {"GGA": 1, "GGA+U": 2, "SCAN": 3, "r2SCAN": 4}

def _energy_eval(entry: Union[ComputedStructureEntry, ComputedEntry]):
"""
Expand Down
4 changes: 2 additions & 2 deletions emmet-core/emmet/core/vasp/material.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
class BlessedCalcs(BaseModel):
GGA: Optional[ComputedStructureEntry] = None
GGA_U: Optional[ComputedStructureEntry] = Field(None, alias="GGA+U")
PBESol: Optional[ComputedStructureEntry] = None
PBESol: Optional[ComputedStructureEntry] = Field(None, alias="PBEsol")
SCAN: Optional[ComputedStructureEntry] = None
R2SCAN: Optional[ComputedStructureEntry] = None
R2SCAN: Optional[ComputedStructureEntry] = Field(None, alias="r2SCAN")
HSE: Optional[ComputedStructureEntry] = None


Expand Down
6 changes: 3 additions & 3 deletions emmet-core/tests/vasp/test_vasp.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
import pytest
from monty.io import zopen

from emmet.core.vasp.calc_types import RunType, TaskType, run_type, task_type
from emmet.core.tasks import TaskDoc
from emmet.core.vasp.calc_types import RunType, TaskType, run_type, task_type
from emmet.core.vasp.task_valid import TaskDocument
from emmet.core.vasp.validation import ValidationDoc, _potcar_stats_check

Expand Down Expand Up @@ -32,8 +32,8 @@ def test_run_type():
("GGA+U", {"GGA": "--", "LDAU": True}),
("SCAN", {"METAGGA": "Scan"}),
("SCAN+U", {"METAGGA": "Scan", "LDAU": True}),
("R2SCAN", {"METAGGA": "R2SCAN"}),
("R2SCAN+U", {"METAGGA": "R2SCAN", "LDAU": True}),
("r2SCAN", {"METAGGA": "R2SCAN"}),
("r2SCAN+U", {"METAGGA": "R2SCAN", "LDAU": True}),
("HFCus", {"LHFCALC": True}),
]

Expand Down

0 comments on commit b9be862

Please sign in to comment.