Mercurial > repos > galaxytrakr > hfp_bettercallsal_konda
comparison 1.0.0/modules/mash/sketch/main.nf @ 0:0a8dda29956e draft default tip
planemo upload
| author | galaxytrakr |
|---|---|
| date | Thu, 28 May 2026 20:41:10 +0000 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:0a8dda29956e |
|---|---|
| 1 process MASH_SKETCH { | |
| 2 tag "mash sketch" | |
| 3 label 'process_micro' | |
| 4 | |
| 5 module (params.enable_module ? "${params.swmodulepath}${params.fs}mash${params.fs}2.3" : null) | |
| 6 conda (params.enable_conda ? "conda-forge::capnproto conda-forge::gsl bioconda::mash=2.3" : null) | |
| 7 container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? | |
| 8 'https://depot.galaxyproject.org/singularity/mash:2.3--he348c14_1': | |
| 9 'quay.io/biocontainers/mash:2.3--he348c14_1' }" | |
| 10 | |
| 11 input: | |
| 12 tuple val(meta), path(query), path(genomes_dir) | |
| 13 | |
| 14 output: | |
| 15 tuple val(meta), path("*.msh") , emit: sketch | |
| 16 tuple val(meta), path("*_mash_sketch.status"), emit: stats | |
| 17 path "versions.yml" , emit: versions | |
| 18 | |
| 19 when: | |
| 20 task.ext.when == null || task.ext.when | |
| 21 | |
| 22 script: | |
| 23 def args = task.ext.args ?: '' | |
| 24 def prefix = task.ext.prefix ?: "${meta.id}" | |
| 25 def queries = (query ?: query.collect().join(' ')) | |
| 26 sleep(Math.round(params.genomes_chunk.toInteger()) as int * 600) | |
| 27 """ | |
| 28 mash \\ | |
| 29 sketch \\ | |
| 30 -p $task.cpus \\ | |
| 31 -o "msh.k${params.mashsketch_k}.${params.mashsketch_s}h.${prefix}" \\ | |
| 32 $args \\ | |
| 33 $queries \\ | |
| 34 2> ${prefix}_mash_sketch.status | |
| 35 | |
| 36 cat <<-END_VERSIONS > versions.yml | |
| 37 "${task.process}": | |
| 38 mash: \$( mash --version ) | |
| 39 END_VERSIONS | |
| 40 """ | |
| 41 } |
