Workflow steps

  • The steps use filesystem artifacts to determine completion.

  • Steps are fail-fast: they terminate execution on critical failures.

  • The same step implementation may be reused by multiple workflows.

Base interface

class workflows.steps.Step(config)

Bases: ABC

Minimal step interface: not_finished + run, bound to a config.

abstract not_finished() bool
abstract run() None

Steps

class workflows.steps.GenerateStructuresStep(config)

Generate hypothetical structures in parallel (chunked).

Submits parsl_tasks.gen_structures.gen_structures() for each chunk i [1, n_chunks] where n_chunks = config[CK.GEN_STRUCTURES_NNODES], and waits for completion.

not_finished() bool
run() None
class workflows.steps.CgcnnStep(config)

Predicts formation energy with CGCNN for the candidates.

Submits parsl_tasks.cgcnn.cgcnn_prediction() for each chunk i [1, n_chunks] where n_chunks = config[CK.GEN_STRUCTURES_NNODES]. Merges work_dir/test_results_*.csv into work_dir/test_results.csv, then deletes the shard files.

not_finished() bool
run() None
class workflows.steps.SelectStructuresStep(config, out_dir, min_total=1000, max_total=4000)

Filter, deduplicate, and select candidate structures.

Runs parsl_tasks.select_structures.select_structures() to produce {work_dir}/new/POSCAR_{i} and {work_dir}/new/id_prop.csv.

not_finished() bool
run() None
class workflows.steps.MLIPRelaxationStep(config)

Relax selected structures with an MLIP and write per-structure energies.

not_finished() bool
run() None
class workflows.steps.EhullMLParallel(config)

Compute ML-based hull quantities in parallel and write the hull output.

not_finished() bool
run() None
class workflows.steps.VaspCalculationsStep(config, run_mlip_post_processing: bool = False)

Run two-stage VASP calculations for all selected structures and log outcomes.

Launches parsl_tasks.dft_optimization.run_vasp_calc() for each ID in {config[CK.VASP_ID_STRUCT_LIST]}. Writes a CSV of per-ID results to {config[CK.VASP_WORK_DIR]}/{config[CK.OUTPUT_FILE]}.

not_finished() bool
run() None
class workflows.steps.PostProcessingStep(config, get_hull: bool = True)

Compute Ehull, color the convex hull, and collect promising candidates.

Requires a 3- or 4-element system. Runs tools.post_processing.get_vasp_hull(), parsl_tasks.ehull.calculate_ehul() and parsl_tasks.convex_hull.convex_hull_color().

not_finished() bool
run() None

Workflows

MLIP based

  1. workflows.steps.GenerateStructuresStep

  2. workflows.steps.CgcnnStep

  3. workflows.steps.SelectStructuresStep

  4. workflows.steps.MLIPRelaxationStep

  5. workflows.steps.EhullMLParallel

  6. workflows.steps.VaspCalculationsStep

  7. workflows.steps.PostProcessingStep

VASP based

  1. workflows.steps.GenerateStructuresStep

  2. workflows.steps.CgcnnStep

  3. workflows.steps.SelectStructuresStep

  4. workflows.steps.VaspCalculationsStep

  5. workflows.steps.PostProcessingStep