Skip to content

Commit 5d9a63f

Browse files
authored
Refactor(abacus): return None but not raise error when energy can not be found in scf (#402)
1 parent dcc48d5 commit 5d9a63f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dpdata/abacus/scf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def get_energy(outlines):
9898
Etot = float(line.split()[1]) # in eV
9999
break
100100
if not Etot:
101-
raise RuntimeError("Final total energy cannot be found in output. Unknown problem.")
101+
return Etot,False
102102
for line in outlines:
103103
if "convergence has NOT been achieved!" in line:
104104
return Etot,False

0 commit comments

Comments
 (0)