Skip to main content

ORCA high-throughput pipeline orchestrator

Project description

orcastrator

chain orca calculations together to build complex quantum chemistry pipelines.

Usage

from pathlib import Path
import logging

from logger import configure_logging

from orcastrator import Calculation

configure_logging(level=logging.DEBUG)

opt = Calculation(
    name="opt",
    root_dir=Path("test/scratch"),
    level_of_theory="! OPT D4 TPSS def2-SVP",
    charge=0,
    mult=1,
    xyz_string=Path("test/h2.xyz").read_text(),
    overwrite=True,
)
opt_result = opt.run()
print(opt_result.directory)

sp = Calculation(
    name="sp",
    root_dir=opt.root_dir,
    level_of_theory="! D4 TPSSh def2-TZVP",
    charge=opt.charge,
    mult=opt.mult,
    xyz_string=opt_result.geometry,
    overwrite=True,
)
sp.run()

Design

A single executable that runs all calculations itself. This means that the orcastrator run has to be submitted to SLURM by itself.

Calculation objects compose with an instance of a QCEngine class, which implements a run() method takes consumes a Calculation object and return its results (or smth).

What does a Calculation need? I'll focus on pure ORCA calculations, because I don't really use anything else anyway. The QCEngine is still a good idea because e.g. there are different ORCA versions etc. Alternatively, the Calculation is just a directory, containing at least an input file.

How can i represent the directory tree of the calculations? I think the orcastrator should probably consume its own toml input file.

How might that look?

xyz_file = "guess.xyz"
charge = 0
mult = 1

[opt_freq]
input = """
! OPT FREQ
! D4 TPSS def2/TZVP

* XYZFILE $charge $mult $xyz_file
"""

[tddft]
input = """
! D4 TPSSh def2/TZVP

%TDDFT
    NROOTS 16
END

* XYZFILE $charge $mult $opt_freq.xyz_file
"""

hmm.. maybe it's better to create everything programmatically.

opt_freq_template = """
! OPT FREQ ...

* XYZFILE $charge $mult $xyz_file
"""
tddft_template = """
! D4 TPSSh ...

* XYZFILE $charge $mult $xyz_file
"""

settings = dict(
    charge=0,
    mult=1,
    xyz_file="guess.xyz"
    engine=OrcaEngine(version="6.0.1", scratch="/scratch")
)

opt_freq = Calculation(input_template=opt_freq_template, settings)
tddft = Calculation(input_template=tddft_template, settings)

opt_freq.run()

tddft.xyz_file = opt_freq.files.optimized_xyz_file
tddft.run()

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

orcastrator-0.2.1.dev2.tar.gz (60.3 kB view details)

Uploaded Source

Built Distribution

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

orcastrator-0.2.1.dev2-py3-none-any.whl (13.0 kB view details)

Uploaded Python 3

File details

Details for the file orcastrator-0.2.1.dev2.tar.gz.

File metadata

  • Download URL: orcastrator-0.2.1.dev2.tar.gz
  • Upload date:
  • Size: 60.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.20

File hashes

Hashes for orcastrator-0.2.1.dev2.tar.gz
Algorithm Hash digest
SHA256 3bcd3e7a87601658410671f37b42b9a70c87454a7ca9ff38481cbf5d069c602f
MD5 48d5e22314b64540680298a4d39f3d66
BLAKE2b-256 51924d6aa9990b6a0a8c7f61b221a2ec326bffa52b16b1c8b9ea00fbe9ddd99c

See more details on using hashes here.

File details

Details for the file orcastrator-0.2.1.dev2-py3-none-any.whl.

File metadata

File hashes

Hashes for orcastrator-0.2.1.dev2-py3-none-any.whl
Algorithm Hash digest
SHA256 8b54f14cd2c6b24e197f929894c461256a1b0848cd7d5bb459c6153cf27ec0ab
MD5 124c905e05c9a929dff14d5bddb56073
BLAKE2b-256 9b5af914c1f3f29048eedf71dae2179b68c9c43dddb695fde1d817416571c03d

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