-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathrun
More file actions
executable file
·27 lines (24 loc) · 777 Bytes
/
run
File metadata and controls
executable file
·27 lines (24 loc) · 777 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/env python
import os
import json
import subprocess
with open("config.json") as conf:
config = json.load(conf)
snake_out = os.path.join(config['logs'], "snake.out")
snake_err = os.path.join(config['logs'], "snake.err")
stats_path = os.path.join(config['logs'], 'stats.json')
with open(snake_out, 'w') as out, open(snake_err, 'w') as err:
snake = subprocess.check_call(
[
"snakemake",
"--snakefile", os.path.join(config['src'], 'Snakefile'),
"--jobscript", os.path.join(config['src'], 'jobscript.sh'),
"--cluster", 'qsub',
"--rerun-incomplete",
"-j", "100",
"--stats", stats_path,
"-T",
"-k",
],
stdout=out, stderr=err
)