pymatgen
pymatgen copied to clipboard
SymmetrizedStructure.to(json) raises TypeError
from pymatgen.analysis.structure_analyzer import SpacegroupAnalyzer
from pymatgen.core import Lattice, Structure
structure = Structure(
lattice=Lattice.cubic(3),
species=("Fe", "Fe"),
coords=((0, 0, 0), (0.5, 0.5, 0.5)),
)
symmetrized_structure = SpacegroupAnalyzer(structure).get_symmetrized_structure()
symmetrized_structure.to("dummy.json")
raises
TypeError: Object of type SymmOp is not JSON serializable