Skip to main content

SlurmGen - Simple Slurm Manager

Project description

SlurmGen - Simple Slurm Manager

Summary

SlurmGen is a very simple Slurm manager:

  • The job description is stored in a JSON file.
  • The JSON file is transformed into a Slurm script.
  • The Slurm file is submitted to the cluster.

SlurmGen is only supporting a small subset of Slurm:

  • Create and delete folders.
  • Set environment variables.
  • Set the job name and log.
  • Set the ressources (memory, time, CPU, etc.).
  • Define the set of commands to be executed.

SlurmGen is not a binding and/or a wrapper for Slurm. SlurmGen is only generating Slurm scripts from JSON files. SlurmGen is written in Python without any external dependencies.

Example

An example is located in the example folder of the repository:

  • test.json contains the Slurm job description
  • run_slurm.py contains is dummy script executed by the jon
  • slurm_output contains the generated Slurm script and log file
  • 'data_output' contains data generated by the Slurm job
# Running this command will:
#   - Create a Slurm script "slurm_output/test.slm"
#   - Put the log file in "slurm_output/test.log"
#   - Run the Slurm script on the cluster
sgen test.json

Project Links

Author

Copyright

(c) 2023 - Thomas Guillod - Dartmouth College

BSD 2-Clause "Simplified" 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

slurmgen-0.3.0.tar.gz (8.6 kB view hashes)

Uploaded Source

Built Distribution

slurmgen-0.3.0-py3-none-any.whl (6.5 kB view hashes)

Uploaded Python 3

Supported by

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