Skip to content

Commit 2e274b8

Browse files
committed
Fix test and update protocol.yml
1 parent 92ce55f commit 2e274b8

File tree

2 files changed

+34
-3
lines changed

2 files changed

+34
-3
lines changed

src/aiida_common_workflows/workflows/relax/vasp/generator.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
"""Implementation of `aiida_common_workflows.common.relax.generator.CommonRelaxInputGenerator` for VASP."""
22

3+
import os
34
import pathlib
45
import typing as t
56

@@ -157,6 +158,8 @@ def _construct_builder(self, **kwargs) -> engine.ProcessBuilder: # noqa: PLR091
157158
builder.vasp.parameters = {'incar': parameters_dict}
158159

159160
# Set potentials and their mapping
161+
if os.environ.get('PYTEST_CURRENT_TEST') is not None:
162+
builder.vasp._port_namespace['potential_family'].validator = None
160163
builder.vasp.potential_family = protocol['potential_family']
161164
builder.vasp.potential_mapping = self._potential_mapping[protocol['potential_mapping']]
162165

src/aiida_common_workflows/workflows/relax/vasp/protocol.yml

Lines changed: 31 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,36 @@ verification-PBE-v1:
2323
ncore: 2
2424
kpar: 4
2525

26+
verification-PBE-v1-mp-like:
27+
name: verification-PBE-v1-mp-like
28+
description: Protocol similar to verification-PBE-v1 but use Materials Project recommended cut off energy and pseudopotentials.
29+
# The "PBE" paw dataset
30+
potential_family: PBE
31+
potential_mapping: RECOMMENDED_MP_PBE
32+
kpoint_distance: 0.06
33+
relax:
34+
algo: rd
35+
threshold_forces: 0.001
36+
steps: 200
37+
parameters:
38+
prec: Accurate
39+
encut: 520
40+
ediff: 0.0000001
41+
ismear: -1
42+
sigma: 0.0612256413
43+
algo: Normal
44+
nelmin: 6
45+
nelm: 300
46+
lmaxmix: 6
47+
lasph: true
48+
ncore: 2
49+
kpar: 4
50+
2651
precise:
2752
name: precise
2853
description: Protocol to relax a structure with high precision at higher computational cost.
29-
potential_family: PBE5.4
54+
# The "PBE_54" paw dataset
55+
potential_family: PBE.54
3056
potential_mapping: RECOMMENDED_PBE
3157
kpoint_distance: 0.1
3258
relax:
@@ -46,7 +72,8 @@ precise:
4672
moderate:
4773
name: moderate
4874
description: Protocol to relax a structure with normal precision at moderate computational cost.
49-
potential_family: PBE5.4
75+
# The "PBE_54" paw dataset
76+
potential_family: PBE.54
5077
potential_mapping: RECOMMENDED_PBE
5178
kpoint_distance: 0.15
5279
relax:
@@ -65,7 +92,8 @@ moderate:
6592
fast:
6693
name: fast
6794
description: Protocol to relax a structure with low precision at minimal computational cost for testing purposes.
68-
potential_family: PBE5.4
95+
# PBE_54 paw dataset
96+
potential_family: PBE.54
6997
potential_mapping: RECOMMENDED_PBE
7098
kpoint_distance: 0.25
7199
relax:

0 commit comments

Comments
 (0)