This release is a pre-release and may not be stable for production use.
psub
Submit and monitor array jobs on Hoffman2 with minimal configuration and confusion.
psub provides an intuitive way to submit array jobs on UCLA's Hoffman2 compute cluster and monitor their output logs. Instead of trying to write scripts that generate scripts that in turn gets submitted to the scheduler or dealing with environmental variables, you can do this with psub and forget about the rest:
psub --mem 4G --time 12:00:00 "./my_script.sh {} --argument {} ::: *.csv ::: arg1 arg2"
When run in a folder containing f1.csv, f2.csv and f3.csv, this will submit a job array of 6 jobs for each combination of arg and each file, and request 4 GB of memory and 12 hours from the scheduler:
./my_script.sh f1.csv --argument arg1
./my_script.sh f1.csv --argument arg2
./my_script.sh f2.csv --argument arg1
./my_script.sh f2.csv --argument arg2
./my_script.sh f3.csv --argument arg1
./my_script.sh f3.csv --argument arg2
psub keeps all stdouts and stderrs nice and tidy. You can view and search logs associated with a particular job with the psub logs subcommand.
See psub --help for all features.
There is also a Python programmatic interface:
from psub import Psub
pp = Psub(name="big_job",
l_arch="intel*",
l_mem="4G",
l_time="1:00:00",
l_highp=True)
for i in range(3):
pp.add(f"echo hi {i}") # add individually
# or add parameter combinations in one go
pp.add_parameter_combinations(
"./my_script.sh {} --argument {}",
["f1.csv", "f2.csv", "f3.csv"], ["arg1", "arg2"]
)
pp.submit() # submit jobs
pp.status # view job status
pp.exit_codes # view exit codes of individual jobs
pp.rerun_failed() # rerun any failed jobs (TBA)
psub is still in alpha, please let me know of any bugs.
psub is for quickly running and monitoring straightforward array jobs. If your workflow has complex interdependencies, you should look into the excellent snakemake tool.
Installation:
pip install psub
psub stands for petko-submit, the OG ernstlab member who had the core idea.
Metadata
Release files for psub 0.1.2a0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| psub-0.1.2a0.tar.gz | 13.9 kB | Without provenance | Details for psub-0.1.2a0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| psub-0.1.2a0-py3-none-any.whl | Python 3 | none | any | Details for psub-0.1.2a0-py3-none-any.whl |
Total release size: 29.5 kB
Release files / psub-0.1.2a0.tar.gz
| Download URL | psub-0.1.2a0.tar.gz |
|---|---|
| Size | 13.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a07c4fe41a84399d6fe11cc09400cd5e984628b34ea7d6d7398a02a5da1e29b6
|
|
BLAKE2b-256 checksum How to use checksums |
b29ba605b61b513a7af5d232f78c48cd59d00c0e44e975d3df38c8ecc2ee9bca
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.4
|
Release files / psub-0.1.2a0-py3-none-any.whl
| Download URL | psub-0.1.2a0-py3-none-any.whl |
|---|---|
| Size | 15.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d1a11d714550b40227d1d9a9d4bb30b92d7b8e72acf2da1fa0874d036d248809
|
|
BLAKE2b-256 checksum How to use checksums |
d6f443853a1850d7fd207d066a93e166c4881655f3047714c6d658bb79e736ac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.4
|
Security for psub 0.1.2a0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.