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

New modules metabuli: Add- Build- Classify #5862

Draft
wants to merge 22 commits into
base: master
Choose a base branch
from
Draft
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
Prev Previous commit
Next Next commit
Module only accepts fasta
Use seqtk downstream to convert fastqs
  • Loading branch information
TheOafidian committed Jun 5, 2023
commit 96669023a1e3f34bce53d6a921fc23c01a33f8d0
26 changes: 1 addition & 25 deletions modules/nf-core/metabuli/classify/main.nf
Original file line number Diff line number Diff line change
@@ -1,20 +1,3 @@
// TODO nf-core: If in doubt look at other nf-core/modules to see how we are doing things! :)
// https://github.com/nf-core/modules/tree/master/modules/nf-core/
// You can also ask for help via your pull request or on the #modules channel on the nf-core Slack workspace:
// https://nf-co.re/join
// TODO nf-core: A module file SHOULD only define input and output files as command-line parameters.
// All other parameters MUST be provided using the "task.ext" directive, see here:
// https://www.nextflow.io/docs/latest/process.html#ext
// where "task.ext" is a string.
// Any parameters that need to be evaluated in the context of a particular sample
// e.g. single-end/paired-end data MUST also be defined and evaluated appropriately.
// TODO nf-core: Software that can be piped together SHOULD be added to separate module files
// unless there is a run-time, storage advantage in implementing in this way
// e.g. it's ok to have a single module for bwa to output BAM instead of SAM:
// bwa mem | samtools view -B -T ref.fasta
// TODO nf-core: Optional inputs are not currently supported by Nextflow. However, using an empty
// list (`[]`) instead of a file can be used to work around this issue.

process METABULI_CLASSIFY {
tag "$meta.id"
label 'process_medium'
Expand All @@ -25,8 +8,6 @@ process METABULI_CLASSIFY {
'biocontainers/1.0.0--pl5321hf1761c0_0' }"

input:
// TODO nf-core: Where applicable please provide/convert compressed files as input/output
// e.g. "*.fastq.gz" and NOT "*.fastq", "*.bam" and NOT "*.sam" etc.
tuple val(meta), path(fastas)
path(db)

Expand All @@ -42,18 +23,13 @@ process METABULI_CLASSIFY {
def args = task.ext.args ?: ''
def prefix = task.ext.prefix ?: "${meta.id}"
def input = meta.single_end ? "--seq_mode 1 ${fastas}" : "${fastas}"
// TODO nf-core: Where possible, a command MUST be provided to obtain the version number of the software e.g. 1.10
// If the software is unable to output a version number on the command-line then it can be manually specified
// e.g. https://github.com/nf-core/modules/blob/master/modules/nf-core/homer/annotatepeaks/main.nf
// Each software used MUST provide the software name and version number in the YAML version file (versions.yml)
// TODO nf-core: It MUST be possible to pass additional parameters to the tool as a command-line string via the "task.ext.args" directive
"""
metabuli \\
classify \\
$args \\
--threads $task.cpus \\
${input}
${database}
${db}
${prefix} \\
${prefix}

Expand Down
13 changes: 6 additions & 7 deletions modules/nf-core/metabuli/classify/meta.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
name: "metabuli_classify"
## TODO nf-core: Add a description of the module and list keywords
description: Classify FASTA files against a metabuli database
keywords:
- metabuli
Expand All @@ -15,7 +14,7 @@ tools:
homepage: "https://github.com/steineggerlab/Metabuli"
documentation: "https://github.com/steineggerlab/Metabuli#readme"
tool_dev_url: "https://github.com/steineggerlab/Metabuli"
doi: "https://doi.org/10.1101/2023.05.31.543018"
doi: "10.1101/2023.05.31.543018"
licence: "['GPL v3']"

input:
Expand All @@ -24,13 +23,13 @@ input:
description: |
Groovy Map containing sample information
e.g. [ id:'test', single_end:false ]
- fastas:
- fastas:
type: file
description: single or paired FASTA files, optionally gzipped
pattern: "*.{fa,fa.gz,fasta,fasta.gz,fna,fna.gz}"
- db:
description: single or paired FASTA files
pattern: "*.{fa,fasta,fna}"
- db:
type: file
description: Metabuli databse file from build or custom made.
description: Metabuli database file, prebuild or custom made.

output:
- meta:
Expand Down