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
f27a750c
Unverified
Commit
f27a750c
authored
6 years ago
by
Ruben Vorderman
Committed by
GitHub
6 years ago
Browse files
Options
Downloads
Plain Diff
Merge branch 'develop' into BIOWDL-194
parents
edfcd38d
37442743
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!89
allow for additional annotations to be added into mergecounts output
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
hisat2.wdl
+47
-0
47 additions, 0 deletions
hisat2.wdl
picard.wdl
+38
-89
38 additions, 89 deletions
picard.wdl
with
85 additions
and
89 deletions
hisat2.wdl
0 → 100644
+
47
−
0
View file @
f27a750c
version 1.0
task Hisat2 {
input {
File indexDirectory
String indexBasename
File inputR1
File? inputR2
String outputBam
String sample
String library
String readgroup
String platform = "illumina"
Boolean downstreamTranscriptomeAssembly = true
Int threads = 1
Int memory = 48
String dockerTag = "2388ff67fc407dad75774291ca5038f40cac4be0-0"
}
command {
set -e -o pipefail
mkdir -p $(dirname ~{outputBam})
hisat2 \
-p ~{threads} \
-x ~{indexDirectory}/~{indexBasename} \
~{true="-1" false="-U" defined(inputR2)} ~{inputR1} \
~{"-2" + inputR2} \
--rg-id ~{readgroup} \
--rg 'SM:~{sample}' \
--rg 'LB:~{library}' \
--rg 'PL:~{platform}' \
~{true="--dta" false="" downstreamTranscriptomeAssembly} \
| samtools sort > ~{outputBam}
}
output {
File bamFile = outputBam
}
runtime {
memory: (memory / threads) + 1
cpu: threads + 1
docker: "quay.io/biocontainers/mulled-v2-a97e90b3b802d1da3d6958e0867610c718cb5eb1:" + dockerTag
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
picard.wdl
+
38
−
89
View file @
f27a750c
...
...
@@ -4,26 +4,20 @@ import "common.wdl"
task BedToIntervalList {
input {
String? preCommand
File? picardJar
File bedFile
File dict
String outputPath
Int memory = 4
Float memoryMultiplier = 3.0
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
String dockerTag = "2.18.26--0"
}
command {
set -e -o pipefail
mkdir -p $(dirname "~{outputPath}")
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
BedToIntervalList \
I=~{bedFile} \
O=~{outputPath} \
...
...
@@ -35,13 +29,13 @@ task BedToIntervalList {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task CollectMultipleMetrics {
input {
String? preCommand
IndexedBamFile bamFile
Reference reference
String basename
...
...
@@ -56,21 +50,16 @@ task CollectMultipleMetrics {
Boolean collectSequencingArtifactMetrics = true
Boolean collectQualityYieldMetrics = true
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "8dde04faba6c9ac93fae7e846af3bafd2c331b3b-0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
mkdir -p $(dirname "~{basename}")
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
CollectMultipleMetrics \
I=~{bamFile.file} \
R=~{reference.fasta} \
...
...
@@ -109,33 +98,30 @@ task CollectMultipleMetrics {
}
runtime {
# https://raw.githubusercontent.com/BioContainers/multi-package-containers/80886dfea00f3cd9e7ae2edf4fc42816a10e5403/combinations/mulled-v2-23d9f7c700e78129a769e78521eb86d6b8341923%3A8dde04faba6c9ac93fae7e846af3bafd2c331b3b-0.tsv
# Contains r-base=3.4.1,picard=2.18.2
docker: "quay.io/biocontainers/mulled-v2-23d9f7c700e78129a769e78521eb86d6b8341923:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task CollectRnaSeqMetrics {
input {
String? preCommand
IndexedBamFile bamFile
File refRefflat
String basename
String strandSpecificity = "NONE"
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "8dde04faba6c9ac93fae7e846af3bafd2c331b3b-0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
mkdir -p $(dirname "~{basename}")
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
CollectRnaSeqMetrics \
I=~{bamFile.file} \
O=~{basename}.RNA_Metrics \
...
...
@@ -150,34 +136,31 @@ task CollectRnaSeqMetrics {
}
runtime {
# https://raw.githubusercontent.com/BioContainers/multi-package-containers/80886dfea00f3cd9e7ae2edf4fc42816a10e5403/combinations/mulled-v2-23d9f7c700e78129a769e78521eb86d6b8341923%3A8dde04faba6c9ac93fae7e846af3bafd2c331b3b-0.tsv
# Contains r-base=3.4.1,picard=2.18.2
docker: "quay.io/biocontainers/mulled-v2-23d9f7c700e78129a769e78521eb86d6b8341923:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task CollectTargetedPcrMetrics {
input {
String? preCommand
IndexedBamFile bamFile
Reference reference
File ampliconIntervals
Array[File]+ targetIntervals
String basename
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
mkdir -p $(dirname "~{basename}")
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
CollectTargetedPcrMetrics \
I=~{bamFile.file} \
R=~{reference.fasta} \
...
...
@@ -195,6 +178,7 @@ task CollectTargetedPcrMetrics {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
...
...
@@ -202,24 +186,18 @@ task CollectTargetedPcrMetrics {
# Combine multiple recalibrated BAM files from scattered ApplyRecalibration runs
task GatherBamFiles {
input {
String? preCommand
Array[File]+ inputBams
Array[File]+ inputBamsIndex
String outputBamPath
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
GatherBamFiles \
INPUT=~{sep=' INPUT=' inputBams} \
OUTPUT=~{outputBamPath} \
...
...
@@ -236,30 +214,25 @@ task GatherBamFiles {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task GatherVcfs {
input {
String? preCommand
Array[File]+ inputVcfs
Array[File]+ inputVcfIndexes
String outputVcfPath
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
GatherVcfs \
INPUT=~{sep=' INPUT=' inputVcfs} \
OUTPUT=~{outputVcfPath}
...
...
@@ -270,6 +243,7 @@ task GatherVcfs {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
...
...
@@ -277,15 +251,14 @@ task GatherVcfs {
# Mark duplicate reads to avoid counting non-independent observations
task MarkDuplicates {
input {
String? preCommand
Array[File]+ inputBams
Array[File] inputBamIndexes
String outputBamPath
String metricsPath
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
# The program default for READ_NAME_REGEX is appropriate in nearly every case.
# Sometimes we wish to supply "null" in order to turn off optical duplicate detection
...
...
@@ -297,15 +270,10 @@ task MarkDuplicates {
# 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"
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
mkdir -p $(dirname ~{outputBamPath})
~{toolCommand}
\
picard -Xmx~{memory}G
\
MarkDuplicates \
INPUT=~{sep=' INPUT=' inputBams} \
OUTPUT=~{outputBamPath} \
...
...
@@ -329,6 +297,7 @@ task MarkDuplicates {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
...
...
@@ -336,28 +305,22 @@ task MarkDuplicates {
# Combine multiple VCFs or GVCFs from scattered HaplotypeCaller runs
task MergeVCFs {
input {
String? preCommand
Array[File]+ inputVCFs
Array[File]+ inputVCFsIndexes
String outputVcfPath
Int? compressionLevel
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
# Using MergeVcfs instead of GatherVcfs so we can create indices
# See https://github.com/broadinstitute/picard/issues/789 for relevant GatherVcfs ticket
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
MergeVcfs \
INPUT=~{sep=' INPUT=' inputVCFs} \
OUTPUT=~{outputVcfPath}
...
...
@@ -371,31 +334,26 @@ task MergeVCFs {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task SamToFastq {
input {
String? preCommand
IndexedBamFile inputBam
String outputRead1
String? outputRead2
String? outputUnpaired
String? picardJar
Int memory = 16 # High memory default to avoid crashes.
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
SamToFastq \
I=~{inputBam.file} \
~{"FASTQ=" + outputRead1} \
...
...
@@ -410,30 +368,25 @@ task SamToFastq {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task ScatterIntervalList {
input {
String? preCommand
File interval_list
Int scatter_count
String? picardJar
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
mkdir scatter_list
~{toolCommand}
\
picard -Xmx~{memory}G
\
IntervalListTools \
SCATTER_COUNT=~{scatter_count} \
SUBDIVISION_MODE=BALANCING_WITHOUT_INTERVAL_SUBDIVISION_WITH_OVERFLOW \
...
...
@@ -449,31 +402,26 @@ task ScatterIntervalList {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
task SortVcf {
input {
String? preCommand
String? picardJar
Array[File]+ vcfFiles
String outputVcfPath
File? dict
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "2.18.26--0"
}
String toolCommand = if defined(picardJar)
then "java -Xmx" + memory + "G -jar " + picardJar
else "picard -Xmx" + memory + "G"
command {
set -e -o pipefail
~{preCommand}
~{toolCommand} \
picard -Xmx~{memory}G \
SortVcf \
I=~{sep=" I=" vcfFiles} \
~{"SEQUENCE_DICTIONARY=" + dict} \
...
...
@@ -488,6 +436,7 @@ task SortVcf {
}
runtime {
docker: "quay.io/biocontainers/picard:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
\ No newline at end of file
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