mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-11-15 22:23:09 +00:00
801240a971
* create files with nf-core command * update meta.yml files * starting to work on index main.nf * prelim test for index * index test working; not finding all output files * index passing tests * index and align passing tests * prototyping biscuitblaster and pileup * update containers * updates to pileup * pileup passing tests * template creation for more biscuit tools * tests passing on blaster,bsconv,pupsom * epiread passing tests, but need to update SNP bed file path * vcf2bed working; change test file * all biscuit commands passing tests * biscuitblaster rename * try to fix permissions * more permission fixes * trying a couple more permission changes * hopefully last permission fixes * really last permission changes * few more permissions * add when blocks * Remove read group meta Co-authored-by: James A. Fellows Yates <jfy133@gmail.com> * remove read group meta Co-authored-by: James A. Fellows Yates <jfy133@gmail.com> * changes for first round of review * update meta.yml with more specific links * Update modules/biscuit/biscuitblaster/main.nf Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * Apply new version reporting Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * Update modules/biscuit/pileup/main.nf Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * Update main.nf * Update modules/biscuit/pileupsomatic/main.nf Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * update test file path * Update modules/biscuit/align/main.nf Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * Update modules/biscuit/align/main.nf Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> * tests passing again * Update modules/biscuit/align/main.nf * Update modules/biscuit/bsconv/main.nf * Update modules/biscuit/epiread/main.nf * Update modules/biscuit/index/main.nf * Update test.yml * Update modules/biscuit/pileupsomatic/main.nf * remove module-specific extension/prefix * remove module-specific extension/prefix * add missing args * switch pileup strategy * update test.yml * remove debug * whitespace cleanup * add in newline escapes * requested changes * Update modules/biscuit/pileup/meta.yml Co-authored-by: Spix <nathan.spix@submit.cm.cluster> Co-authored-by: James A. Fellows Yates <jfy133@gmail.com> Co-authored-by: Sateesh Peri <33637490+sateeshperi@users.noreply.github.com> Co-authored-by: Spix <nathan.spix@node107.cm.cluster> Co-authored-by: njspix <nathan.spix@vai.org>
45 lines
1.8 KiB
Text
45 lines
1.8 KiB
Text
process BISCUIT_PILEUP {
|
|
tag "$meta.id"
|
|
label 'process_high'
|
|
|
|
conda (params.enable_conda ? "bioconda::biscuit=1.0.2.20220113 bioconda::samtools=1.15" : null)
|
|
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
|
|
'https://depot.galaxyproject.org/singularity/mulled-v2-db16f1c237a26ea9245cf9924f858974ff321d6e:17fa66297f088a1bc7560b7b90dc273bf23f2d8c-0':
|
|
'quay.io/biocontainers/mulled-v2-db16f1c237a26ea9245cf9924f858974ff321d6e:17fa66297f088a1bc7560b7b90dc273bf23f2d8c-0' }"
|
|
|
|
input:
|
|
tuple val(meta), path(normal_bams), path(normal_bais), path(tumor_bam), path(tumor_bai)
|
|
path index
|
|
|
|
output:
|
|
tuple val(meta), path("*.vcf.gz"), emit: vcf
|
|
path "versions.yml" , emit: versions
|
|
|
|
when:
|
|
task.ext.when == null || task.ext.when
|
|
|
|
script:
|
|
def args = task.ext.args ?: ''
|
|
def args2 = task.ext.args2 ?: ''
|
|
def prefix = task.ext.prefix ?: "${meta.id}"
|
|
def biscuit_cpus = (int) Math.max(Math.floor(task.cpus*0.9),1)
|
|
def bgzip_cpus = task.cpus-biscuit_cpus
|
|
if ( tumor_bam != [] && normal_bams.toList().size() > 1 ) error "[BISCUIT_PILEUP] error: Tumor BAM provided with more than one normal BAM"
|
|
if ( tumor_bam.toList().size() > 1 ) error "[BISCUIT_PILEUP] error: more than one tumor BAM provided"
|
|
input = ( tumor_bam==[] ) ? "${normal_bams}" : "-S -T ${tumor_bam} -I ${normal_bams}"
|
|
"""
|
|
INDEX=`find -L ./ -name "*.bis.amb" | sed 's/.bis.amb//'`
|
|
|
|
biscuit pileup \\
|
|
-@ $biscuit_cpus \\
|
|
$args \\
|
|
\$INDEX \\
|
|
$input \\
|
|
| bgzip -@ $bgzip_cpus $args2 > ${prefix}.vcf.gz
|
|
|
|
cat <<-END_VERSIONS > versions.yml
|
|
"${task.process}":
|
|
biscuit: \$( biscuit version |& sed '1!d; s/^.*BISCUIT Version: //' )
|
|
END_VERSIONS
|
|
"""
|
|
}
|