Skip to content

Commit

Permalink
specify a default for the tmp-dir when not in the config
Browse files Browse the repository at this point in the history
  • Loading branch information
padraicc authored Feb 20, 2024
1 parent 80c1013 commit 0525bfc
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions workflow/rules/pbrun.smk
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ rule pbrun_deepvariant:
cuda=get_cuda_devices,
extra=config.get("pbrun_deepvariant", {}).get("extra", ""),
num_gpus=lambda wildcards: get_num_gpus("pbrun_deepvariant", wildcards),
tmp=config.get("pbrun_deepvariant", {}).get("tmp_dir", "parabricks/pbrun_deepvariant/{wildcards.sample}_{wildcards.type}"),
tmp=config.get("pbrun_deepvariant", {}).get(
"tmp_dir", lambda wildcards: f"parabricks/pbrun_deepvariant/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_deepvariant/{sample}_{type}.vcf.log",
benchmark:
Expand Down Expand Up @@ -57,7 +59,9 @@ rule pbrun_fq2bam:
extra=config.get("pbrun_fq2bam", {}).get("extra", ""),
in_fq=get_in_fq,
num_gpus=lambda wildcards: get_num_gpus("pbrun_fq2bam", wildcards),
tmp=config.get("pbrun_fq2bam", {}).get("tmp_dir", "parabricks/pbrun_fq2bam/{wildcards.sample}_{wildcards.type}"),
tmp=config.get("pbrun_fq2bam", {}).get(
"tmp_dir", lambda wildcards: f"parabricks/pbrun_fq2bam/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_fq2bam/{sample}_{type}.bam.log",
benchmark:
Expand Down Expand Up @@ -102,7 +106,7 @@ rule pbrun_fq2bam_recal:
in_fq=get_in_fq,
num_gpus=lambda wildcards: get_num_gpus("pbrun_fq2bam_recal", wildcards),
tmp=config.get("pbrun_fq2bam_recal", {}).get(
"tmp_dir", "parabricks/pbrun_fq2bam_recal/{wildcards.sample}_{wildcards.type}"
"tmp_dir", lambda wildcards: f"parabricks/pbrun_fq2bam_recal/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_fq2bam_recal/{sample}_{type}.bam.log",
Expand Down Expand Up @@ -148,7 +152,7 @@ rule pbrun_mutectcaller_t:
extra=config.get("pbrun_mutectcaller_t", {}).get("extra", ""),
num_gpus=lambda wildcards: get_num_gpus("pbrun_mutectcaller_t", wildcards),
tmp=config.get("pbrun_mutectcaller_t", {}).get(
"tmp_dir", "parabricks/pbrun_mutectcaller_t/{wildcards.sample}_{wildcards.type}"
"tmp_dir", lambda wildcards: f"parabricks/pbrun_mutectcaller_t/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_mutectcaller_t/{sample}_T.vcf.log",
Expand Down Expand Up @@ -197,7 +201,7 @@ rule pbrun_mutectcaller_tn:
extra=config.get("pbrun_mutectcaller_tn", {}).get("extra", ""),
num_gpus=lambda wildcards: get_num_gpus("pbrun_mutectcaller_tn", wildcards),
tmp=config.get("pbrun_mutectcaller_tn", {}).get(
"tmp_dir", "parabricks/pbrun_mutectcaller_tn/{wildcards.sample}_{wildcards.type}"
"tmp_dir", lambda wildcards: f"parabricks/pbrun_mutectcaller_tn/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_mutectcaller_tn/{sample}.vcf.log",
Expand Down Expand Up @@ -244,7 +248,9 @@ rule pbrun_rna_fq2bam:
extra=config.get("pbrun_rna_fq2bam", {}).get("extra", ""),
in_fq=get_in_fq,
num_gpus=lambda wildcards: get_num_gpus("pbrun_rna_fq2bam", wildcards),
tmp=config.get("pbrun_rna_fq2bam", {}).get("tmp_dir", "parabricks/pbrun_rna_fq2bam/{wildcards.sample}_{wildcards.type}"),
tmp=config.get("pbrun_rna_fq2bam", {}).get(
"tmp_dir", lambda wildcards: f"parabricks/pbrun_rna_fq2bam/{wildcards.sample}_{wildcards.type}"
),
log:
"parabricks/pbrun_rna_fq2bam/{sample}_{type}.bam.log",
benchmark:
Expand Down

0 comments on commit 0525bfc

Please sign in to comment.