Skip to content

Commit f22e553

Browse files
committed
remove virials key
1 parent 774fb7d commit f22e553

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

dpdata/plugins/ase.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,8 @@ def from_labeled_system(self, atoms: ase.Atoms, **kwargs) -> dict:
6262
"""Convert ase.Atoms to a LabeledSystem. Energies and forces
6363
are calculated by the calculator.
6464
65-
Note that this method will try to load virials from the following sources:
65+
Note that this method will try to load virial from the following sources:
6666
- atoms.info['virial']
67-
- atoms.info['virials']
6867
- converted from stress tensor
6968
7069
Parameters
@@ -101,8 +100,6 @@ def from_labeled_system(self, atoms: ase.Atoms, **kwargs) -> dict:
101100

102101
# try to get virials from different sources
103102
virials = atoms.info.get("virial")
104-
if virials is None:
105-
virials = atoms.info.get("virials")
106103
if virials is None:
107104
try:
108105
stress = atoms.get_stress(False)

0 commit comments

Comments
 (0)