geom.gui.structure_generator ============================ .. py:module:: geom.gui.structure_generator .. autoapi-nested-parse:: Programmatic structure generation helpers used by the native GUI. Attributes ---------- .. autoapisummary:: geom.gui.structure_generator._GENERATION_LOCK geom.gui.structure_generator._CONVERSION_LOCK geom.gui.structure_generator.GUI_TMP_ROOT Classes ------- .. autoapisummary:: geom.gui.structure_generator.AtomRecord geom.gui.structure_generator.StructureResult Functions --------- .. autoapisummary:: geom.gui.structure_generator.supported_metals geom.gui.structure_generator.supported_atomistic_metals geom.gui.structure_generator.supported_fcc_metals geom.gui.structure_generator.generate_structure geom.gui.structure_generator.convert_molecule_to_xyz geom.gui.structure_generator.smiles_to_xyz geom.gui.structure_generator.manipulate_xyz geom.gui.structure_generator.translate_pair_controlled_distance geom.gui.structure_generator.cleanup_gui_tmp geom.gui.structure_generator._xyz_snapshot geom.gui.structure_generator._newest_generated_xyz geom.gui.structure_generator.read_xyz Module Contents --------------- .. py:data:: _GENERATION_LOCK .. py:data:: _CONVERSION_LOCK .. py:data:: GUI_TMP_ROOT .. py:class:: AtomRecord .. py:attribute:: element :type: str .. py:attribute:: x :type: float .. py:attribute:: y :type: float .. py:attribute:: z :type: float .. py:class:: StructureResult .. py:attribute:: xyz_path :type: pathlib.Path .. py:attribute:: atoms :type: tuple[AtomRecord, Ellipsis] .. py:attribute:: command :type: tuple[str, Ellipsis] .. py:property:: atom_count :type: int .. py:function:: supported_metals(arrangements: set[str] | None = None) -> list[str] Return metals supported by GEOM, optionally filtered by crystal arrangement. .. py:function:: supported_atomistic_metals() -> list[str] Return FCC/BCC metals supported by the bulk-lattice atomistic generators. .. py:function:: supported_fcc_metals() -> list[str] Return FCC metals used by the ASE cluster generators. .. py:function:: generate_structure(command_args: list[str], output_root: pathlib.Path) -> StructureResult Run GEOM's existing CLI generator and return the newest generated XYZ file. .. py:function:: convert_molecule_to_xyz(input_path: pathlib.Path) -> pathlib.Path Convert a PDB/SMI-like molecule file to XYZ through GEOM's RDKit command path. .. py:function:: smiles_to_xyz(smiles: str) -> pathlib.Path Write a SMILES string into GEOM's GUI temp folder and convert it to XYZ. .. py:function:: manipulate_xyz(input_path: pathlib.Path, command_args: Callable[[str], list[str]]) -> pathlib.Path Run an existing GEOM manipulation command in the GUI temp folder. .. py:function:: translate_pair_controlled_distance(fixed_path: pathlib.Path, moving_path: pathlib.Path, distance: float, axis: str) -> tuple[pathlib.Path, pathlib.Path] Run GEOM -t for two XYZ files, translating the second to a controlled distance. .. py:function:: cleanup_gui_tmp() -> None Remove GUI-generated temporary conversion files. .. py:function:: _xyz_snapshot(results_dir: pathlib.Path) -> dict[pathlib.Path, int] .. py:function:: _newest_generated_xyz(results_dir: pathlib.Path, before: dict[pathlib.Path, int]) -> pathlib.Path .. py:function:: read_xyz(path: pathlib.Path) -> tuple[AtomRecord, Ellipsis] Read the atom records from an XYZ file.