Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add flye module #982

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions modules/flye/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ process FLYE {

input:
tuple val(meta), path(reads)
val mode

output:
tuple val(meta), path("*.fasta"), emit: fasta
Expand All @@ -32,10 +33,9 @@ process FLYE {

script:
def prefix = options.suffix ? "${meta.id}${options.suffix}" : "${meta.id}"
def mode = meta.mode
"""
flye \\
--$mode \\
$mode \\
$reads \\
$options.args \\
--threads $task.cpus \\
Expand Down
3 changes: 3 additions & 0 deletions modules/flye/meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ input:
type: file
description: Input file in FASTA/FASTQ format.
pattern: "*.{fasta,fastq,fasta.gz,fastq.gz,fa,fq,fa.gz,fq.gz}"
- mode:
type: val
description: flye mode ( --pacbio-raw | --pacbio-corr | --pacbio-hifi | --nano-raw | --nano-corr | --nano-hq )

output:
- meta:
Expand Down
36 changes: 24 additions & 12 deletions tests/modules/flye/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -5,49 +5,61 @@ nextflow.enable.dsl = 2
include { FLYE } from '../../../modules/flye/main.nf' addParams( options: [:] )

workflow test_flye_pacbio_raw {
input = [ [ id:'test', mode:'pacbio-raw' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['bacteroides_fragilis']['nanopore']['test_fastq_gz'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--pacbio-raw"

FLYE ( input, mode )
d4straub marked this conversation as resolved.
Show resolved Hide resolved
}

workflow test_flye_pacbio_corr {
input = [ [ id:'test', mode:'pacbio-corr' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['homo_sapiens']['pacbio']['hifi'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--pacbio-corr"

FLYE ( input, mode )
}

workflow test_flye_pacbio_hifi {
input = [ [ id:'test', mode:'pacbio-hifi' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['homo_sapiens']['pacbio']['hifi'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--pacbio-hifi"

FLYE ( input, mode )
}

workflow test_flye_nano_raw {
input = [ [ id:'test', mode:'nano-raw' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['bacteroides_fragilis']['nanopore']['test_fastq_gz'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--nano-raw"

FLYE ( input, mode )
}

workflow test_flye_nano_corr {
input = [ [ id:'test', mode:'nano-corr' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['homo_sapiens']['pacbio']['hifi'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--nano-corr"

FLYE ( input, mode )
}

workflow test_flye_nano_hq {
input = [ [ id:'test', mode:'nano-hq' ], // meta map
input = [ [ id:'test' ], // meta map
[ file(params.test_data['homo_sapiens']['pacbio']['hifi'], checkIfExists: true) ]
]

FLYE ( input )
mode = "--nano-hq"

FLYE ( input, mode )
}