From 829c15c98b1447f9445690e29f2b684dbe053f65 Mon Sep 17 00:00:00 2001 From: Ramprasad Neethiraj <20065894+ramprasadn@users.noreply.github.com> Date: Tue, 3 May 2022 14:26:34 +0200 Subject: [PATCH] partition --- modules/cnvpytor/partition/main.nf | 7 ++++--- modules/cnvpytor/partition/meta.yml | 3 +++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/modules/cnvpytor/partition/main.nf b/modules/cnvpytor/partition/main.nf index 8365cb29..42a5ec78 100644 --- a/modules/cnvpytor/partition/main.nf +++ b/modules/cnvpytor/partition/main.nf @@ -9,6 +9,7 @@ process CNVPYTOR_PARTITION { input: tuple val(meta), path(pytor) + val bin_sizes output: tuple val(meta), path("${pytor.baseName}.pytor"), emit: pytor @@ -18,15 +19,15 @@ process CNVPYTOR_PARTITION { task.ext.when == null || task.ext.when script: - def args = task.ext.args ?: '' + def bins = bin_sizes ?: '1000' """ cnvpytor \\ -root $pytor \\ - -partition $args + -partition $bins cat <<-END_VERSIONS > versions.yml "${task.process}": - cnvpytor: \$(echo \$(cnvpytor --version 2>&1) | sed 's/^.*pyCNVnator //; s/Using.*\$//' )) + cnvpytor: \$(echo \$(cnvpytor --version 2>&1) | sed 's/CNVpytor //' )) END_VERSIONS """ diff --git a/modules/cnvpytor/partition/meta.yml b/modules/cnvpytor/partition/meta.yml index a72cea4c..bb7a047e 100644 --- a/modules/cnvpytor/partition/meta.yml +++ b/modules/cnvpytor/partition/meta.yml @@ -22,6 +22,9 @@ input: type: file description: pytor file containing read depth data pattern: "*.{pytor}" + - bin_sizes: + type: string + description: list of binsizes separated by space e.g. "1000 10000" and "1000" output: - meta: