Skip to main content

An adaptive and highly asynchronous ensemble simulation workflow manager MatEnsemble (https://github.com/Q-CAD/MatEnsemble) built jointly on top of the hierarchical graph based scheduler FLUX and concurrent-futures infrastructure of python

Project description

PyPI version Documentation Python License

MatEnsemble

MatEnsemble

MatEnsemble is a Python library for high-throughput workflows on HPC systems. You define a directed acyclic graph (DAG) of tasks—Python callables or executable commands—and MatEnsemble submits work through Flux, tracks completions, adapts scheduling to free CPUs and GPUs, and writes structured logs and per-chore output directories.

An optional in-tree dynopro stack supports streaming dynamics and on-the-fly analysis for advanced materials simulation workflows.

Features

  • DAG-based workflows with dependencies via deferred return values (OutputReference)
  • Adaptive scheduling that back-fills the allocation as tasks finish (with a non-adaptive mode when you need it)
  • Two chore types: Python chores (remotely unpickled and executed by matensemble.runtime_worker) and argv-style executable chores
  • Resource requests: tasks, cores per task, GPUs per task, optional MPI (pmi2) via Flux
  • Observability: status.json, matensemble_workflow.log, per-chore stdout / stderr, pickle and JSON result artifacts; optional web dashboard (FastAPI on port 8000)

Adaptive task management

On-the-fly dynamics and analysis

Documentation

Documentation (overview, architecture, tutorials, API reference):

matensemble.readthedocs.io

Installation

Containers (recommended on many clusters)

OCI images are published to GitHub Container Registry, for example:

ghcr.io/freddude2004/matensemble:baseline-vX.Y.Z

See the container packages and the Quick start in the docs for Apptainer/Singularity and site-specific notes.

Development install

From a clone of this repository:

uv sync
uv sync --group dev   # optional: docs and pytest tooling
uv run pytest

Or with pip:

pip install -e ".[flux]"

Site-specific Conda-style environment files live under scripts/ (for example scripts/baseline/environment.yaml, scripts/frontier/, scripts/perlmuter/). Align Python with 3.12+ and Flux with your center’s modules.

Quick example

from matensemble.pipeline import Pipeline

pipe = Pipeline()
pipe.exec(command=["/bin/echo", "hello from MatEnsemble"])
pipe.submit()

For Python chores, dependency graphs, and the required split between an importable chore module and a runner script, see the Tutorials.

Examples in the repository

Illustrative workflows live under example_workflows/.

Requirements and runtime

  • A Flux allocation (or equivalent) on the machine where you call Pipeline.submit()
  • For MPI Python or executable chores: a coherent MPI/Flux setup (e.g. PMI2) as expected by your site
  • Optional: SSH port forwarding if you enable the dashboard on a compute node (see the architecture guide in the docs)

Related links

Authors

Soumendu Bagchi, Kaleb Duchesneau (see pyproject.toml for contact details).

License

BSD 3-Clause. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

matensemble-0.2.1.tar.gz (211.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

matensemble-0.2.1-py3-none-any.whl (224.8 kB view details)

Uploaded Python 3

File details

Details for the file matensemble-0.2.1.tar.gz.

File metadata

  • Download URL: matensemble-0.2.1.tar.gz
  • Upload date:
  • Size: 211.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for matensemble-0.2.1.tar.gz
Algorithm Hash digest
SHA256 992891a9d5c30b59b895df4b6a6a53d95e5e7fe40be601065a3777427d494401
MD5 ba7fac3d8d536ea55cdcbb37146f4f21
BLAKE2b-256 6101342a60fe260188c8743d0f34c8992f5cd975675d25735b34a4c4756abca4

See more details on using hashes here.

File details

Details for the file matensemble-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: matensemble-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 224.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for matensemble-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 750cb61e0f020d0ff295405375493bd9e4c16edfc5b8e92d4261ee9b2aa5f4b3
MD5 cd3056fed2dcfee05257d2ed909139bb
BLAKE2b-256 ea9534654a0955dced3a2dceb861880fc284c8125ba705a9013abeb3402d04fb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page