Commit ecaf2d09 authored by Nijsse, Bart's avatar Nijsse, Bart
Browse files

reference filter and kraken2 conditional fix

parent dd0656ec
......@@ -82,22 +82,12 @@ inputs:
type: string[]?
doc: References fasta file(s) for filtering
label: Filter reference file(s)
default: ["/unlock/references/databases/bbduk/GCA_000001405.28_GRCh38.p13_genomic.fna.gz"] # HUMAN
# ["/unlock/references/databases/bbduk/GCA_000001405.28_GRCh38.p13_genomic.fna.gz"] # HUMAN
deduplicate:
type: boolean?
doc: Remove exact duplicate reads with fastp
label: Deduplicate reads
default: false
run_kraken2:
type: boolean?
doc: Optionally run Kraken2
label: Kraken2
default: true
run_filter_references:
type: boolean?
doc: Optionally filter references
label: Filter References
default: false
kraken_database:
type: string?
doc: Kraken2 database location
......@@ -234,12 +224,14 @@ steps:
illumina_quality_kraken2:
label: Kraken2
doc: Taxonomic classification of FASTQ reads
when: $(inputs.kraken_database !== null)
run: ../kraken2/kraken2.cwl
in:
tmp_id: identifier
identifier:
valueFrom: $(inputs.tmp_id)_unfiltered_illumina
threads: threads
kraken_database: kraken_database
database: kraken_database
forward_reads: phix_filter/out_forward_reads
reverse_reads: phix_filter/out_reverse_reads
......@@ -250,24 +242,26 @@ steps:
illumina_quality_kraken2_krona:
label: Krona
doc: Visualization of Kraken2 classification with Krona
when: $(inputs.kraken_database !== null)
run: ../krona/krona.cwl
in:
kraken_database: kraken_database
kraken: illumina_quality_kraken2/sample_report
out: [krona_html]
#############################################
#### Merging of reference files
combine_references:
combine_references:
label: Combine references
doc: Combine references to a single fasta file
when: $(inputs.run_filter_references)
when: $(inputs.filter_references !== null)
run: ../bash/concatenate.cwl
in:
# infiles:
# source: references
# linkMerge: merge_flattened
# pickValue: all_non_null
run_filter_references: run_filter_references
filter_references: filter_references
file_paths:
source: filter_references
linkMerge: merge_flattened
......@@ -280,10 +274,10 @@ steps:
reference_filter_illumina:
label: Reference read mapping
doc: Map reads against references using BBMap
when: $(inputs.run_filter_references)
when: $(inputs.filter_references !== null)
run: ../bbmap/bbmap_filter-reads.cwl
in:
run_filter_references: run_filter_references
filter_references: filter_references
identifier: identifier
forward_reads: fastp/out_forward_reads
reverse_reads: fastp/out_reverse_reads
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment