Skip to content

Commit

Permalink
Fix picard java opts
Browse files Browse the repository at this point in the history
  • Loading branch information
lczech committed Feb 12, 2025
1 parent 9d7c550 commit 636565b
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
5 changes: 4 additions & 1 deletion workflow/rules/calling-freebayes.smk
Original file line number Diff line number Diff line change
Expand Up @@ -141,14 +141,17 @@ rule merge_variants:
done=touch("calling/genotyped-all.vcf.gz.done"),
params:
# See duplicates-picard.smk for the reason whe need this on MacOS.
java_opts=config["params"]["picard"]["MergeVcfs-java-opts"],
extra=(
" --USE_JDK_DEFLATER true --USE_JDK_INFLATER true" if platform.system() == "Darwin" else ""
),
resources:
mem_mb=config["params"]["picard"].get("MergeVcfs-mem-mb", 1024),
log:
"logs/calling/picard/merge-genotyped.log",
benchmark:
"benchmarks/calling/genotyped/picard/merge-genotyped.log"
conda:
"../envs/picard.yaml"
wrapper:
"0.51.3/bio/picard/mergevcfs"
"v5.7.0/bio/picard/mergevcfs"
7 changes: 5 additions & 2 deletions workflow/rules/filtering.smk
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ rule merge_calls:
# We use different naming for the VQSR intermediate files,
# to make it a bit more understandable to the user which file is which...
# not sure if that helps, or is more confusing in the end :-O
vcf=expand(
vcfs=expand(
"calling/filtered/all.{vartype}.{filtertype}.vcf.gz",
vartype=["SNP", "INDEL"],
filtertype=(
Expand All @@ -108,14 +108,17 @@ rule merge_calls:
done=touch("calling/filtered-all.vcf.gz.done"),
params:
# See duplicates-picard.smk for the reason whe need this on MacOS.
java_opts=config["params"]["picard"]["MergeVcfs-java-opts"],
extra=(
" --USE_JDK_DEFLATER true --USE_JDK_INFLATER true" if platform.system() == "Darwin" else ""
),
resources:
mem_mb=config["params"]["picard"].get("MergeVcfs-mem-mb", 1024),
log:
"logs/calling/picard-mergevcfs.log",
benchmark:
"benchmarks/calling/filtered/picard-mergevcfs.log"
conda:
"../envs/picard.yaml"
wrapper:
"0.27.1/bio/picard/mergevcfs"
"v5.7.0/bio/picard/mergevcfs"
10 changes: 2 additions & 8 deletions workflow/rules/qc-bam.smk
Original file line number Diff line number Diff line change
Expand Up @@ -226,19 +226,13 @@ rule picard_collectmultiplemetrics:
log:
"logs/qc/picard-collectmultiplemetrics/{sample}.log",
params:
config["params"]["picard"]["CollectMultipleMetrics-java-opts"]
+ " "
+ config["params"]["picard"]["CollectMultipleMetrics-extra"]
java_opts = config["params"]["picard"]["CollectMultipleMetrics-java-opts"],
extra = config["params"]["picard"]["CollectMultipleMetrics-extra"]
+ (" --USE_JDK_DEFLATER true --USE_JDK_INFLATER true" if platform.system() == "Darwin" else ""),
resources:
mem_mb=config["params"]["picard"].get("CollectMultipleMetrics-mem-mb", 1024),
conda:
"../envs/picard.yaml"
# script:
# We use our own version of the wrapper here, which fixes issues with missing files in cases
# where Picard does not have enough data for a specific metric to run.
# "../scripts/picard-collectmultiplemetrics.py"
# Update: fixed in the new wrapper now, so should be good.
wrapper:
"v5.7.0/bio/picard/collectmultiplemetrics"

Expand Down

0 comments on commit 636565b

Please sign in to comment.