Simple tool to wrap and execute sbatch commands from `python` scripts or `Jupyter Notebook` cells with `conda` envs and config files. Secure and reproducible
Project description
SlurmBot 🤖
Simple tool to wrap and execute sbatch commands from python scripts or Jupyter Notebook cells with conda envs and config files. Less mess, more reproducibility and security (if published to GitHub, for instance).
Based on jbatch.
- ⚙️ Config Files: Create config files in
YAMLformat and reuse them. Make adefault.yamlin~/.config/slurmbot/default.yaml - 🐍 Python Variables: Easily integrate Python variables into your Slurm job commands.
- 🛠️ Conda: Activate Conda environments with the
condaproperty.
Installation
pip install slurmbot
Example
from slurmbot import SlurmBot
sb = SlurmBot() # using default yaml from ~/.config/slurmbot/default.yaml, if exists OR specify path to config
samples = ["SRR000001", "SRR000002"]
for sample in samples:
sb.run(f"fasterq-dump {sample}", conda="ngs", mem=4, cpus=4, dry=True, v=2)
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file slurmbot-0.2.3.tar.gz.
File metadata
- Download URL: slurmbot-0.2.3.tar.gz
- Upload date:
- Size: 3.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.12.1 Linux/6.1.0-26-amd64
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
27bc9d93b9cb115754b6ea3191f94aef0054173b627faf0f8a2a207c814effa0
|
|
| MD5 |
2e261fc20cc1558a2718321caf773168
|
|
| BLAKE2b-256 |
837b0e1d4c4783e0f75c9e35b39c89f101c0ab5b7c5a428002348131d5ced4fa
|
File details
Details for the file slurmbot-0.2.3-py3-none-any.whl.
File metadata
- Download URL: slurmbot-0.2.3-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.12.1 Linux/6.1.0-26-amd64
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2352f4bf388dd695b45cd19a9b7be8d52990d0c34ac17231052605eac3e2c447
|
|
| MD5 |
3182bc6a508eb50939d50bf682cd8025
|
|
| BLAKE2b-256 |
399402ec4ef98de4226febc4d113dece204f6ca6c8302d1c4033fde868257fb8
|