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
Merge requests
!92
Dockerize GATK. Scattering now works with containers. Tabix another docker image.
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Dockerize GATK. Scattering now works with containers. Tabix another docker image.
BIOWDL-199
into
develop
Overview
9
Commits
24
Pipelines
0
Changes
1
Merged
Ruben Vorderman
requested to merge
BIOWDL-199
into
develop
6 years ago
Overview
9
Commits
24
Pipelines
0
Changes
1
Expand
0
0
Merge request reports
Viewing commit
5607a41d
Prev
Next
Show latest version
1 file
+
7
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
5607a41d
make output dirs
· 5607a41d
Ruben Vorderman
authored
6 years ago
biopet/biopet.wdl
+
20
−
13
Options
@@ -205,54 +205,60 @@ task FastqSync {
task ReorderGlobbedScatters {
input {
Array[File]+ scatters
String scatterDir
# Should not be changed from the main pipeline. As it should not influence results.
String dockerTag = "3.6"
}
command <<<
set -e
# Copy all the scatter files to the CWD so the output matches paths in
# the cwd.
for file in ~{sep=" " scatters}
do cp $file .
done
python << CODE
from os.path import basename
scatters = ['~{sep="','" scatters}']
splitext = [basename(x).split(".") for x in scatters]
splitnum = [x.split("-") + [y] for x,y in splitext]
ordered = sorted(splitnum, key=lambda x: int(x[1]))
merged = ["
~{scatterDir}/
{}-{}.{}".format(x[0],x[1],x[2]) for x in ordered]
merged = ["{}-{}.{}".format(x[0],x[1],x[2]) for x in ordered]
for x in merged:
print(x)
CODE
>>>
output {
Array[
String
] reorderedScatters = read_lines(stdout())
Array[
File
] reorderedScatters = read_lines(stdout())
}
runtime {
memory: 1
docker: "python:" + dockerTag
# 4 gigs of memory to be able to build the docker image in singularity
memory: 4
}
}
task ScatterRegions {
input {
String? preCommand
Reference reference
String outputDirPath
File? toolJar
Int? scatterSize
File? regions
Boolean notSplitContigs = false
Int memory = 4
Float memoryMultiplier = 3.0
String dockerTag = "0.2--0"
}
String toolCommand = if defined(toolJar)
then "java -Xmx" + memory + "G -jar " +toolJar
else "biopet-scatterregions -Xmx" + memory + "G"
# OutDirPath must be defined here because the glob process relies on
# linking. This path must be in the containers filesystem, otherwise the
# linking does not work.
String outputDirPath = "scatters"
command {
set -e -o pipefail
~{preCommand}
mkdir -p ~{outputDirPath}
~{toolCommand}
\
biopet-scatterregions -Xmx~{memory}G
\
-R ~{reference.fasta} \
-o ~{outputDirPath} \
~{"-s " + scatterSize} \
@@ -265,6 +271,7 @@ task ScatterRegions {
}
runtime {
docker: "quay.io/biocontainers/biopet-scatterregions:" + dockerTag
memory: ceil(memory * memoryMultiplier)
}
}
Loading