pyxtal.optimize.WFS module
Global optimization using the Stochastic Width First Sampling (WFS) algorithm
- class pyxtal.optimize.WFS.WFS(smiles: str, workdir: str, sg: int | list, tag: str = 'test', info: dict[any, any] | None = None, ff_opt: bool = False, ff_style: str = 'openff', ff_parameters: str = 'parameters.xml', reference_file: str = 'references.xml', ref_criteria: dict[any, any] | None = None, N_gen: int = 10, N_pop: int = 10, N_cpu: int = 1, fracs: list | None = None, cif: str | None = None, block: list[any] | None = None, num_block: list[any] | None = None, composition: list[any] | None = None, lattice: Lattice | None = None, torsions: list[any] | None = None, molecules: list[pyxtal_molecule] | None = None, sites: list[any] | None = None, use_hall: bool = False, skip_ani: bool = True, factor: float = 1.1, eng_cutoff: float = 5.0, E_max: float = 10000000000.0, verbose: bool = False, random_state: int | None = None, max_time: float | None = None, matcher: StructureMatcher | None = None, early_quit: bool = False, check_stable: bool = False, use_mpi: bool = False, pre_opt: bool = False, check: bool = True)[source]
Bases:
GlobalOptimize
Standard Population algorithm
- Parameters:
smiles (str) – smiles string
workdir (str) – path of working directory
sg (int or list) – space group number or list of spg numbers
tag (string) – job prefix
ff_opt (bool) – activate on the fly FF mode
ff_style (str) – automated force style (gaff or openff)
ff_parameters (str or list) – ff parameter xml file or list
reference_file (str) – path of reference xml data for FF training
N_gen (int) – number of generation (default: 10)
N_pop (int) – number of populations (default: 10)
fracs (list) – fractions for each variation (default: [0.5, 0.5, 0.0])
N_cpu (int) – number of cpus for parallel calculation (default: 1)
cif (str) – cif file name to store all structure information
block – block mode
num_block – list of blocks
compositions – list of composition, (default is [1]*Num_mol)
lattice (bool) – whether or not supply the lattice
torsions – list of torsion angle
molecules (list) – list of pyxtal_molecule objects
sites (list) – list of wp sites, e.g., [[‘4a’]]
use_hall (bool) – whether or not use hall number (default: False)
skip_ani (bool) – whether or not use ani or not (default: True)
eng_cutoff (float) – the cutoff energy for FF training
E_max (float) – maximum energy defined as an invalid structure
verbose (bool) – show more details
matcher – structurematcher from pymatgen
early_quit (bool) – if quit the program early when the target is found
use_mpi (bool) – if use mpi