Skip to content
Snippets Groups Projects
Verified Commit 8818f78d authored by Laurent Modolo's avatar Laurent Modolo
Browse files

gatk4: change Xmx option parsing

parent bea9b094
No related branches found
No related tags found
No related merge requests found
......@@ -211,8 +211,9 @@ process select_variants_snp {
output:
tuple val(file_id), path("*_joint_snp.vcf"), emit: vcf
script:
xmx_memory = task.memory - ~/\s*GB/
"""
gatk --java-options "-Xmx${task.memory}" -T SelectVariants \
gatk --java-options "-Xmx${xmx_memory}G" -T SelectVariants \
-nct ${task.cpus} \
-R ${fasta} \
-V ${vcf} \
......@@ -232,8 +233,9 @@ process select_variants_indels {
output:
tuple val(file_id), path("*_joint_indel.vcf"), emit: vcf
script:
xmx_memory = task.memory - ~/\s*GB/
"""
gatk --java-options "-Xmx${task.memory}" -T SelectVariants \
gatk --java-options "-Xmx${xmx_memory}" -T SelectVariants \
-nct ${task.cpus} \
-R ${fasta} \
-V ${vcf} \
......@@ -254,12 +256,12 @@ process personalized_genome {
tuple val(file_id), path("*_genome.fasta"), emit: fasta
script:
library = pick_library(file_id, library_list)
xmx_memory = task.memory - ~/\s*GB/
"""
gatk --java-options "-Xmx${task.memory}" -T FastaAlternateReferenceMaker\
gatk --java-options "-Xmx${xmx_memory}" -T FastaAlternateReferenceMaker\
-R ${reference} \
-V ${vcf} \
-o ${library}_genome.fasta
-o ${file_id.library}_genome.fasta
"""
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment