Skip to content

Commit

Permalink
Merge pull request #318 from biowdl/shallow_mode
Browse files Browse the repository at this point in the history
Add inputs for hfmtool's purple "shallow mode"
  • Loading branch information
DavyCats authored Mar 17, 2023
2 parents d2f3c9e + 36a4575 commit c2b179a
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ that users understand how the changes affect the new version.
-->
version 5.1.0-dev
---------------------------
+ Add the `highlyDiploidPercentage` and `somaticMinPuritySpread` inputs to the
hmtools PURPLE task.
+ Add a task for fastp.
+ Add a task for picard CollectInsertSizeMetrics.
+ Increased the timeMinutes runtime attribute for manta (somatic and germline) to `2880`.
Expand Down
10 changes: 9 additions & 1 deletion fastp.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ task Fastp {
Boolean performAdapterTrimming = true
Boolean performQualityFiltering = true
Boolean performLengthFiltering = true
Boolean? performPolyGTrimming

Int threads = 4
String memory = "50GiB"
Expand All @@ -50,6 +51,11 @@ task Fastp {
String outputDirR1 = sub(outputPathR1, basename(outputPathR1), "")
String outputDirR2 = sub(outputPathR2, basename(outputPathR2), "")

String polyGTrimmingFlag = if defined(performPolyGTrimming)
then
if select_first([performPolyGTrimming]) then "--trim_poly_g" else "--disable_trim_poly_g"
else ""

Int? effectiveSplit = if select_first([split, 1]) > 1 then split else noneInt

command <<<
Expand Down Expand Up @@ -77,7 +83,8 @@ task Fastp {
~{if defined(effectiveSplit) then "-d 0" else ""} \
~{if performAdapterTrimming then "" else "--disable_adapter_trimming"} \
~{if performQualityFiltering then "" else "--disable_quality_filtering"} \
~{if performLengthFiltering then "" else "--disable_length_filtering"}
~{if performLengthFiltering then "" else "--disable_length_filtering"} \
~{polyGTrimmingFlag}
>>>

output {
Expand Down Expand Up @@ -108,6 +115,7 @@ task Fastp {
performAdapterTrimming: {description: "Whether adapter trimming should be performed or not.", category: "advanced"}
performQualityFiltering: {description: "Whether reads should be filtered based on quality scores.", category: "advanced"}
performLengthFiltering: {description: "Whether reads shoulde be filtered based on lengths.", catgegory: "advanced"}
performPolyGTrimming: {description: "Whether or not poly-G-tail trimming should be performed. If undefined fastp's default behaviour will be used, ie. enabled for NextSeq/NovaSeq data as detected from read headers.", category: "advanced"}
threads: {description: "The number of threads to use. Only used if the split input is not set.", category: "advanced"}
memory: {description: "The amount of memory this job will use.", category: "advanced"}
timeMinutes: {description: "The maximum amount of time the job will run in minutes.", category: "advanced"}
Expand Down
6 changes: 6 additions & 0 deletions hmftools.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -1070,6 +1070,8 @@ task Purple {
File driverGenePanel
File somaticHotspots
File germlineHotspots
Float? highlyDiploidPercentage
Float? somaticMinPuritySpread
#The following should be in the same directory.
File geneDataCsv
File proteinFeaturesCsv
Expand Down Expand Up @@ -1103,6 +1105,8 @@ task Purple {
-run_drivers \
-somatic_hotspots ~{somaticHotspots} \
-driver_gene_panel ~{driverGenePanel} \
~{"-highly_diploid_percentage " + highlyDiploidPercentage} \
~{"-somatic_min_purity_spread " + somaticMinPuritySpread} \
-threads ~{threads}
}

Expand Down Expand Up @@ -1182,6 +1186,8 @@ task Purple {
driverGenePanel: {description: "A TSV file describing the driver gene panel.", category: "required"}
somaticHotspots: {description: "A vcf file with hotspot somatic variant sites.", category: "required"}
germlineHotspots: {description: "A vcf file with hotspot germline variant sites.", category: "required"}
highlyDiploidPercentage: {description: "Equivalent to PURPLE's `-highly_diploid_percentage` option.", category: "advanced"}
somaticMinPuritySpread: {description: "Equivalent to PURPLE's `-somatic_min_purity_spread` option.", category: "advanced"}
geneDataCsv: {description: "A CSV file containing gene information, must be in the same directory as `proteinFeaturesCsv`, `transExonDataCsv` and `transSpliceDataCsv`.", category: "required"}
proteinFeaturesCsv: {description: "A CSV file containing protein feature information, must be in the same directory as `geneDataCsv`, `transExonDataCsv` and `transSpliceDataCsv`.", category: "required"}
transExonDataCsv: {description: "A CSV file containing transcript exon information, must be in the same directory as `geneDataCsv`, `proteinFeaturesCsv` and `transSpliceDataCsv`.", category: "required"}
Expand Down

0 comments on commit c2b179a

Please sign in to comment.