pymatgen icon indicating copy to clipboard operation
pymatgen copied to clipboard

Parsing AIRSS results into structures

Open janosh opened this issue 2 years ago • 0 comments

Ab initio random structure searching (AIRSS) run creates a directory of .res result files describing final structures and some high-level properties like Pressure, Volume, Enthalpy, Symmetry for each randomly sampled crystal relaxation.

I saw https://github.com/materialsproject/pymatgen/pull/2048 by @mkhorton to add Castep IO. The ability to parse .res files into Pymatgen structures would go well with that. How about we add support for

Structure.from_file('airss-run-1234.res')

which could be used to leverage pymatgen functionality like structure matching/grouping to analyze AIRSS results with pymatgen.

from glob import glob
from pymatgen.core import Structure

structures = []
for res_file in glob("good_castep/airss-run-*.res"):
    struct = Structure.from_file(res_file)
    structures.append(struct)

# start analysis

janosh avatar Jun 25 '22 17:06 janosh