Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tasks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
biowdl
tasks
Commits
27f54c49
Commit
27f54c49
authored
6 years ago
by
pjvan_thof
Browse files
Options
Downloads
Patches
Plain Diff
Added picard as a non jar command
parent
c0bbdd8c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
picard.wdl
+34
-15
34 additions, 15 deletions
picard.wdl
with
34 additions
and
15 deletions
picard.wdl
+
34
−
15
View file @
27f54c49
...
@@ -2,17 +2,22 @@ task ScatterIntervalList {
...
@@ -2,17 +2,22 @@ task ScatterIntervalList {
String? preCommand
String? preCommand
File interval_list
File interval_list
Int scatter_count
Int scatter_count
String picard
_j
ar
String
?
picard
J
ar
Float? memory
Float? memory
Float? memoryMultiplier
Float? memoryMultiplier
Int mem = ceil(select_first([memory, 4.0]))
Int mem = ceil(select_first([memory, 4.0]))
String toolCommand = if defined(picardJar)
then "java -Xmx" + mem + "G -jar " + picardJar
else "gatk -Xmx" + mem + "G"
command {
command {
set -e -o pipefail
set -e -o pipefail
${preCommand}
${preCommand}
mkdir scatter_list
mkdir scatter_list
java -Xmx${mem}G -jar ${picard_jar
} \
${toolCommand
} \
IntervalListTools \
IntervalListTools \
SCATTER_COUNT=${scatter_count} \
SCATTER_COUNT=${scatter_count} \
SUBDIVISION_MODE=BALANCING_WITHOUT_INTERVAL_SUBDIVISION_WITH_OVERFLOW \
SUBDIVISION_MODE=BALANCING_WITHOUT_INTERVAL_SUBDIVISION_WITH_OVERFLOW \
...
@@ -38,17 +43,21 @@ task GatherBamFiles {
...
@@ -38,17 +43,21 @@ task GatherBamFiles {
Array[File]+ input_bams
Array[File]+ input_bams
String output_bam_path
String output_bam_path
Int? compression_level
Int? compression_level
String picard
_j
ar
String
?
picard
J
ar
Float? memory
Float? memory
Float? memoryMultiplier
Float? memoryMultiplier
Int mem = ceil(select_first([memory, 4.0]))
Int mem = ceil(select_first([memory, 4.0]))
String toolCommand = if defined(picardJar)
then "java -Xmx" + mem + "G -jar " + picardJar
else "gatk -Xmx" + mem + "G"
command {
command {
set -e -o pipefail
set -e -o pipefail
${preCommand}
${preCommand}
java ${"-Dsamjdk.compression_level=" + compression_level} \
${toolCommand} \
-Xmx${mem}G -jar ${picard_jar} \
GatherBamFiles \
GatherBamFiles \
INPUT=${sep=' INPUT=' input_bams} \
INPUT=${sep=' INPUT=' input_bams} \
OUTPUT=${output_bam_path} \
OUTPUT=${output_bam_path} \
...
@@ -74,7 +83,7 @@ task MarkDuplicates {
...
@@ -74,7 +83,7 @@ task MarkDuplicates {
String output_bam_path
String output_bam_path
String metrics_path
String metrics_path
Int? compression_level
Int? compression_level
String picard
_j
ar
String
?
picard
J
ar
Float? memory
Float? memory
Float? memoryMultiplier
Float? memoryMultiplier
...
@@ -88,12 +97,16 @@ task MarkDuplicates {
...
@@ -88,12 +97,16 @@ task MarkDuplicates {
# This works because the output of BWA is query-grouped and therefore, so is the output of MergeBamAlignment.
# This works because the output of BWA is query-grouped and therefore, so is the output of MergeBamAlignment.
# While query-grouped isn't actually query-sorted, it's good enough for MarkDuplicates with ASSUME_SORT_ORDER="queryname"
# While query-grouped isn't actually query-sorted, it's good enough for MarkDuplicates with ASSUME_SORT_ORDER="queryname"
Int mem = ceil(select_first([memory, 4.0]))
Int mem = ceil(select_first([memory, 4.0]))
String toolCommand = if defined(picardJar)
then "java -Xmx" + mem + "G -jar " + picardJar
else "gatk -Xmx" + mem + "G"
command {
command {
set -e -o pipefail
set -e -o pipefail
${preCommand}
${preCommand}
mkdir -p $(dirname ${output_bam_path})
mkdir -p $(dirname ${output_bam_path})
java ${"-Dsamjdk.compression_level=" + compression_level} \
${toolCommand} \
-Xmx${mem}G -jar ${picard_jar} \
MarkDuplicates \
MarkDuplicates \
INPUT=${sep=' INPUT=' input_bams} \
INPUT=${sep=' INPUT=' input_bams} \
OUTPUT=${output_bam_path} \
OUTPUT=${output_bam_path} \
...
@@ -124,7 +137,7 @@ task MergeVCFs {
...
@@ -124,7 +137,7 @@ task MergeVCFs {
Array[File] inputVCFsIndexes
Array[File] inputVCFsIndexes
String outputVCFpath
String outputVCFpath
Int? compressionLevel
Int? compressionLevel
String picardJar
String
?
picardJar
Float? memory
Float? memory
Float? memoryMultiplier
Float? memoryMultiplier
...
@@ -132,11 +145,15 @@ task MergeVCFs {
...
@@ -132,11 +145,15 @@ task MergeVCFs {
# Using MergeVcfs instead of GatherVcfs so we can create indices
# Using MergeVcfs instead of GatherVcfs so we can create indices
# See https://github.com/broadinstitute/picard/issues/789 for relevant GatherVcfs ticket
# See https://github.com/broadinstitute/picard/issues/789 for relevant GatherVcfs ticket
Int mem = ceil(select_first([memory, 4.0]))
Int mem = ceil(select_first([memory, 4.0]))
String toolCommand = if defined(picardJar)
then "java -Xmx" + mem + "G -jar " + picardJar
else "gatk -Xmx" + mem + "G"
command {
command {
set -e -o pipefail
set -e -o pipefail
${preCommand}
${preCommand}
java ${"-Dsamjdk.compression_level=" + compressionLevel} \
${toolCommand} \
-Xmx${mem}G -jar ${picardJar} \
MergeVcfs \
MergeVcfs \
INPUT=${sep=' INPUT=' inputVCFs} \
INPUT=${sep=' INPUT=' inputVCFs} \
OUTPUT=${outputVCFpath}
OUTPUT=${outputVCFpath}
...
@@ -158,17 +175,19 @@ task SamToFastq {
...
@@ -158,17 +175,19 @@ task SamToFastq {
String outputRead1
String outputRead1
String? outputRead2
String? outputRead2
String? outputUnpaired
String? outputUnpaired
String picard
_j
ar
String
?
picard
J
ar
Float? memory
Float? memory
Float? memoryMultiplier
Float? memoryMultiplier
Int mem = ceil(select_first([memory, 16.0])) # High memory default to avoid crashes.
Int mem = ceil(select_first([memory, 16.0])) # High memory default to avoid crashes.
String toolCommand = if defined(picardJar)
then "java -Xmx" + mem + "G -jar " + picardJar
else "gatk -Xmx" + mem + "G"
command {
command {
set -e -o pipefail
set -e -o pipefail
${preCommand}
${preCommand}
java \
${toolCommand} \
-Xmx${mem}G \
-jar ${picard_jar} \
SamToFastq \
SamToFastq \
I=${inputBam} \
I=${inputBam} \
${"FASTQ=" + outputRead1} \
${"FASTQ=" + outputRead1} \
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment