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