Skip to content

Commit

Permalink
Updated to filter out empties
Browse files Browse the repository at this point in the history
  • Loading branch information
DLBPointon committed Oct 19, 2023
1 parent 8055b7b commit 245465a
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion subworkflows/local/extract_nt_blast.nf
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,28 @@ workflow EXTRACT_NT_BLAST {
REFORMAT_FULL_OUTFMT6 ( BLAST_CHUNK_TO_FULL.out.full )
ch_versions = ch_versions.mix(REFORMAT_FULL_OUTFMT6.out.versions)

//
// LOGIC:
//
REFORMAT_FULL_OUTFMT6.out.full
.map { meta, file ->
tuple( [ id: meta.id,
sz: file.size() ],
file
)
}
.branch {
valid: it[0].sz >= 1
invalid: it[0].sz <= 0
}
.set { gatekeeper }

//
// MODULE:
//
BLAST_GET_TOP_HITS ( REFORMAT_FULL_OUTFMT6.out.full )
BLAST_GET_TOP_HITS (
gatekeeper.valid
)
ch_versions = ch_versions.mix(BLAST_GET_TOP_HITS.out.versions)

//
Expand Down

0 comments on commit 245465a

Please sign in to comment.