We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 474bd5e commit 61720bbCopy full SHA for 61720bb
src/atomate2/jdftx/schemas/calculation.py
@@ -158,7 +158,8 @@ def from_jdftxoutput(
158
The output document.
159
"""
160
optimized_structure: Structure = jdftxoutput.structure
161
- forces = jdftxoutput.forces.tolist() if hasattr(jdftxoutput, "forces") else None
+ if hasattr(jdftxoutput, "forces"):
162
+ forces = None if jdftxoutput.forces is None else jdftxoutput.forces.tolist()
163
if hasattr(jdftxoutput, "stress"):
164
stress = None if jdftxoutput.stress is None else jdftxoutput.stress.tolist()
165
else:
0 commit comments