Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/Joon-Klaps/viralgenie into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
Klaps-bot committed Sep 28, 2023
2 parents 39dbcef + 9a594c0 commit 12d2274
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
6 changes: 5 additions & 1 deletion conf/modules.config
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

variant_caller = params.variant_caller
intermediate_variant_caller = params.intermediate_variant_caller
assemblers = params.assemblers ? params.assemblers.split(',').collect{ it.trim().toLowerCase() } : []

process {

Expand Down Expand Up @@ -229,7 +230,10 @@ process {

withName: TRINITY {
cpus = { check_max( 12 * task.attempt, 'cpus' ) } // defeault was 1
errorStrategy = { task.exitStatus in [1,2] ? 'ignore' : 'retry' } // can fail with very few reads
errorStrategy =
'megahit' in assemblers || 'spades' in assemblers ?
{ task.exitStatus == 2 ? 'ignore' : 'retry' } : // can fail with very few reads see issue #21
{'retry'}
ext.args = "--min_contig_length ${params.min_contig_size} --NO_SEQTK"
publishDir = [
path: { "${params.outdir}/assembly/assemblers/trinity/" },
Expand Down
8 changes: 7 additions & 1 deletion subworkflows/local/fastq_spades_trinity_megahit.nf
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,14 @@ workflow FASTQ_SPADES_TRINITY_MEGAHIT {
if ('trinity' in assemblers) {
TRINITY(reads)

TRINITY
.out
.transcript_fasta
.filter{ meta, contigs -> contigs != null } // filter out empty contigs check issue #21
.set{ch_scaffolds_trinity}

ch_versions = ch_versions.mix(TRINITY.out.versions.first())
ch_scaffolds = ch_scaffolds.mix(TRINITY.out.transcript_fasta)
ch_scaffolds = ch_scaffolds.mix(ch_scaffolds_trinity)
}

// MEGAHIT
Expand Down

0 comments on commit 12d2274

Please sign in to comment.