Skip to main content

snakemake-executor-plugin-sge

A Snakemake executor plugin for Sun Grid Engine (SGE), Univa Grid Engine (UGE), and Open Grid Scheduler (OGS) clusters.

Features

  • Every job is an array job – singletons become -t 1-1, batches become -t 1-N. One submission path, one tracking path, no special cases.
  • Group jobs as a single array job – Snakemake group jobs (several rules bundled together) are submitted as one qsub call.
  • Rich qsub flag coverage – queue, project, parallel environment, wall time, memory (per-slot and total), priority, requeue, reservation, notify, mail, hold_jid, task concurrency, env-var export, join logs, and arbitrary extra flags.
  • Per-rule resource overrides – any global setting can be overridden via rule resources: (e.g. sge_queue, sge_pe, sge_extra, …).
  • Two-stage status pollingqstat for in-flight jobs, qacct for completed jobs; configurable retries and optional qacct disabling.
  • Clean log management – per-task stdout/stderr, optional auto-delete on success, age-based rotation.

Installation

pip install snakemake-executor-plugin-sge

Quick start

snakemake --executor sge --jobs 100

Common options

CLI flag Default Description
--sge-queue Default queue (-q)
--sge-pe Parallel environment for multi-thread jobs
--sge-project Project (-P)
--sge-export-env True Export environment (-V)
--sge-join-logs False Merge stdout+stderr (-j y)
--sge-requeue Requeue on failure (-r y/n)
--sge-reservation Resource reservation (-R y/n)
--sge-notify False Send notify signal
--sge-mail-on Mail events (b, e, a, s, n)
--sge-mail-address Mail address (-M)
--sge-hold-jid Hold until job(s) finish
--sge-array-limit 75000 Max tasks per qsub -t call
--sge-task-concurrency Max concurrent array tasks (-tc)
--sge-logdir .snakemake/sge_logs Log directory
--sge-keep-successful-logs False Keep logs for successful jobs
--sge-use-qacct True Use qacct for finished-job detection
--sge-extra Raw extra qsub flags (global)
--sge-jobname-prefix Prefix for SGE job names

Per-rule resource overrides

rule my_rule:
    resources:
        runtime        = 120,          # minutes → h_rt=02:00:00
        mem_mb         = 8192,         # total memory (divided by threads per slot)
        mem_mb_per_cpu = 2048,         # per-slot memory (takes precedence)
        threads        = 4,
        sge_queue      = "highmem.q",
        sge_pe         = "smp",
        sge_project    = "myproject",
        sge_extra      = "-l gpu=1",   # arbitrary extra qsub flags
        sge_resources  = {"h_cpu": "24:00:00", "arch": "lx-amd64"},
        sge_join_logs  = True,
        sge_requeue    = True,
        sge_priority   = -100,
        sge_notify     = True,
        sge_mail_on    = "e",
        sge_mail_address = "me@example.com",
        sge_hold_jid   = "12345",
        sge_task_concurrency = 8,
        sge_export_env = False,
    threads: 4
    shell: "..."

Array-job design

Every qsub submission uses qsub -t start-end. Execution commands are stored in a JSON file on the shared filesystem before qsub is called. The submission script reads $SGE_TASK_ID, looks up the compressed command, and evaluates it. This avoids command-line length limits and all heredoc/quoting problems.

License

MIT

Download files

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

Source Distribution

snakemake_executor_plugin_sge-0.6.24.tar.gz (26.2 kB view details)

Uploaded Source

Built Distribution

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

snakemake_executor_plugin_sge-0.6.24-py3-none-any.whl (27.4 kB view details)

Uploaded Python 3

File details

Details for the file snakemake_executor_plugin_sge-0.6.24.tar.gz.

File metadata

File hashes

Hashes for snakemake_executor_plugin_sge-0.6.24.tar.gz
Algorithm Hash digest
SHA256 2e131b9f3d0051749a24addedcf092d24d875f3b8d368bc396af78cf7e5ce8e4
MD5 b0d253f5d1aeabb5649cd30bccf08394
BLAKE2b-256 c493c916fdfcd0fb74fcbabea0c4bfcdeb6a8e92f257841b200da3d57644c98f

See more details on using hashes here.

File details

Details for the file snakemake_executor_plugin_sge-0.6.24-py3-none-any.whl.

File metadata

File hashes

Hashes for snakemake_executor_plugin_sge-0.6.24-py3-none-any.whl
Algorithm Hash digest
SHA256 a8051948c227908f03711609ec78f66b6d3a2626ce60a40a89db5c37f10c8be2
MD5 fcd5f1751d40e93f7215aca66d90d4b9
BLAKE2b-256 e6ec438a4b1b71f6cdd50e0dbd06b87d33534ecde50a451f0fb9b6e2e057c212

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.6.24 This release

2 files

0.6.23

2 files

0.6.22

2 files

0.6.20

2 files

0.6.19

2 files

0.6.18

2 files

0.6.17

2 files

0.6.16

2 files

0.6.13

2 files

0.6.12

2 files

0.6.11

2 files

0.6.10

2 files

0.6.9

2 files

0.6.8

2 files

0.6.7

2 files

0.6.6

2 files

0.6.5

2 files

0.6.4

2 files

0.6.3

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.9

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page