Skip to content

Commit

Permalink
add verbose flag to AirssProvider.as_dict()
Browse files Browse the repository at this point in the history
  • Loading branch information
janosh committed Sep 7, 2022
1 parent bc239c3 commit 8fd8352
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pymatgen/io/res.py
Original file line number Diff line number Diff line change
Expand Up @@ -587,8 +587,10 @@ def entry(self) -> ComputedStructureEntry:
"""
return ComputedStructureEntry(self.structure, self.energy, data={"rems": self.rems})

def as_dict(self) -> dict[str, Any]:
def as_dict(self, verbose: bool = True) -> dict[str, Any]:
"""Get dict with title fields, structure and rems of this AirssProvider."""
if verbose:
return super().as_dict()
return dict(**vars(self._res.TITL), structure=self.structure.as_dict(), rems=self.rems)


Expand Down

0 comments on commit 8fd8352

Please sign in to comment.