-
Notifications
You must be signed in to change notification settings - Fork 0
/
Snakefile
57 lines (44 loc) · 1.24 KB
/
Snakefile
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import yaml
sample_sheet = config["sample_sheet"]
with open(sample_sheet) as f:
SAMPLES = yaml.safe_load(f)
for param in ["threads", "mem_gb"]:
for k in config[param]:
config[param][k] = int(config[param][k])
wildcard_constraints:
sample="[^/]{1,100}",
OUT = config["output_dir"]
INPUT = config["input_dir"]
localrules:
all,
no_typing,
aggregate_species,
copy_sample_bam,
copy_sample_vcf,
copy_deletion_vcf,
copy_ref,
combine_lineage_typing,
mtb_filter_res_table_positions,
mtb_make_json,
audit_version_gatk,
audit_version_biopython,
audit_version_bcftools,
audit_version_bedtools,
audit_version_bwa,
audit_version_bgzip,
audit_version_samtools,
audit_version_seqkit,
audit_version_snpeff,
combine_version,
include: "workflow/rules/choose_species.smk"
include: "workflow/rules/mtb_prepare_files.smk"
include: "workflow/rules/mtb_typing.smk"
include: "workflow/rules/audit_version.smk"
rule all:
input:
expand(OUT + "/typing_check/{sample}_done.txt", sample=SAMPLES),
expand(
OUT + "/mtb_typing/annotated_resistance_filtered/{sample}.tsv",
sample=SAMPLES,
),
OUT + "/version_audit/versions.txt",