mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-11-10 20:23:10 +00:00
Change intervals to be part of sample specific input (#1189)
* Change intervals to be part of sample specific input * Fix some tests * Update checksum * Update intervals * Update intervals * Try out gavins idea for adding the file * update test line * update test line * update test line * revert contains line
This commit is contained in:
parent
5320ab7e6c
commit
a6e0629e24
13 changed files with 89 additions and 77 deletions
|
@ -8,20 +8,22 @@ process GATK4_APPLYBQSR {
|
|||
'quay.io/biocontainers/gatk4:4.2.4.0--hdfd78af_0' }"
|
||||
|
||||
input:
|
||||
tuple val(meta), path(input), path(input_index), path(bqsr_table)
|
||||
tuple val(meta), path(input), path(input_index), path(bqsr_table), path(intervals)
|
||||
path fasta
|
||||
path fai
|
||||
path dict
|
||||
path intervals
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*.bam"), emit: bam
|
||||
path "versions.yml" , emit: versions
|
||||
tuple val(meta), path("*.bam"), emit: bam, optional: true
|
||||
tuple val(meta), path("*.cram"), emit: cram, optional: true
|
||||
path "versions.yml" , emit: versions
|
||||
|
||||
script:
|
||||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def interval = intervals ? "-L ${intervals}" : ""
|
||||
def file_type = input.getExtension()
|
||||
|
||||
def avail_mem = 3
|
||||
if (!task.memory) {
|
||||
log.info '[GATK ApplyBQSR] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.'
|
||||
|
@ -35,7 +37,7 @@ process GATK4_APPLYBQSR {
|
|||
--bqsr-recal-file $bqsr_table \\
|
||||
$interval \\
|
||||
--tmp-dir . \\
|
||||
-O ${prefix}.bam \\
|
||||
-O ${prefix}.${file_type} \\
|
||||
$args
|
||||
|
||||
cat <<-END_VERSIONS > versions.yml
|
||||
|
|
|
@ -31,6 +31,9 @@ input:
|
|||
- bqsr_table:
|
||||
type: file
|
||||
description: Recalibration table from gatk4_baserecalibrator
|
||||
- intervals:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- fasta:
|
||||
type: file
|
||||
description: The reference fasta file
|
||||
|
@ -43,9 +46,7 @@ input:
|
|||
type: file
|
||||
description: GATK sequence dictionary
|
||||
pattern: "*.dict"
|
||||
- intervalsBed:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
|
||||
|
||||
output:
|
||||
- meta:
|
||||
|
|
|
@ -8,11 +8,10 @@ process GATK4_BASERECALIBRATOR {
|
|||
'quay.io/biocontainers/gatk4:4.2.4.0--hdfd78af_0' }"
|
||||
|
||||
input:
|
||||
tuple val(meta), path(input), path(input_index)
|
||||
tuple val(meta), path(input), path(input_index), path(intervals)
|
||||
path fasta
|
||||
path fai
|
||||
path dict
|
||||
path intervalsBed
|
||||
path knownSites
|
||||
path knownSites_tbi
|
||||
|
||||
|
@ -23,14 +22,16 @@ process GATK4_BASERECALIBRATOR {
|
|||
script:
|
||||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def intervalsCommand = intervalsBed ? "-L ${intervalsBed}" : ""
|
||||
def intervalsCommand = intervals ? "-L ${intervals}" : ""
|
||||
def sitesCommand = knownSites.collect{"--known-sites ${it}"}.join(' ')
|
||||
|
||||
def avail_mem = 3
|
||||
if (!task.memory) {
|
||||
log.info '[GATK BaseRecalibrator] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.'
|
||||
} else {
|
||||
avail_mem = task.memory.giga
|
||||
}
|
||||
|
||||
"""
|
||||
gatk --java-options "-Xmx${avail_mem}g" BaseRecalibrator \
|
||||
-R $fasta \
|
||||
|
|
|
@ -28,6 +28,9 @@ input:
|
|||
type: file
|
||||
description: BAI/CRAI file from alignment
|
||||
pattern: "*.{bai,crai}"
|
||||
- intervals:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- fasta:
|
||||
type: file
|
||||
description: The reference fasta file
|
||||
|
@ -40,9 +43,6 @@ input:
|
|||
type: file
|
||||
description: GATK sequence dictionary
|
||||
pattern: "*.dict"
|
||||
- intervalsBed:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- knownSites:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
|
|
|
@ -8,13 +8,12 @@ process GATK4_GENOTYPEGVCFS {
|
|||
'quay.io/biocontainers/gatk4:4.2.4.0--hdfd78af_0' }"
|
||||
|
||||
input:
|
||||
tuple val(meta), path(gvcf), path(gvcf_index)
|
||||
tuple val(meta), path(gvcf), path(gvcf_index), path(intervals)
|
||||
path fasta
|
||||
path fasta_index
|
||||
path fasta_dict
|
||||
path dbsnp
|
||||
path dbsnp_index
|
||||
path intervals_bed
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*.vcf.gz"), emit: vcf
|
||||
|
@ -25,7 +24,7 @@ process GATK4_GENOTYPEGVCFS {
|
|||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def dbsnp_options = dbsnp ? "-D ${dbsnp}" : ""
|
||||
def interval_options = intervals_bed ? "-L ${intervals_bed}" : ""
|
||||
def interval_options = intervals ? "-L ${intervals}" : ""
|
||||
def gvcf_options = gvcf.name.endsWith(".vcf") || gvcf.name.endsWith(".vcf.gz") ? "$gvcf" : "gendb://$gvcf"
|
||||
def avail_mem = 3
|
||||
if (!task.memory) {
|
||||
|
|
|
@ -25,6 +25,9 @@ input:
|
|||
description: |
|
||||
Tuple of gVCF(.gz) file (first) and its index (second) or the path to a GenomicsDB (and empty)
|
||||
pattern: ["*.{vcf,vcf.gz}", "*.{idx,tbi}"]
|
||||
- intervals:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- fasta:
|
||||
type: file
|
||||
description: Reference fasta file
|
||||
|
@ -45,10 +48,6 @@ input:
|
|||
type: tuple of files
|
||||
description: dbSNP VCF index file
|
||||
pattern: "*.tbi"
|
||||
- intervals_bed:
|
||||
type: file
|
||||
description: An intevals BED file
|
||||
pattern: "*.bed"
|
||||
|
||||
output:
|
||||
- meta:
|
||||
|
|
|
@ -8,13 +8,12 @@ process GATK4_HAPLOTYPECALLER {
|
|||
'quay.io/biocontainers/gatk4:4.2.4.0--hdfd78af_0' }"
|
||||
|
||||
input:
|
||||
tuple val(meta), path(input), path(input_index)
|
||||
tuple val(meta), path(input), path(input_index), path(intervals)
|
||||
path fasta
|
||||
path fai
|
||||
path dict
|
||||
path dbsnp
|
||||
path dbsnp_tbi
|
||||
path interval
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*.vcf.gz"), emit: vcf
|
||||
|
@ -24,7 +23,7 @@ process GATK4_HAPLOTYPECALLER {
|
|||
script:
|
||||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def interval_option = interval ? "-L ${interval}" : ""
|
||||
def interval_option = intervals ? "-L ${intervals}" : ""
|
||||
def dbsnp_option = dbsnp ? "-D ${dbsnp}" : ""
|
||||
def avail_mem = 3
|
||||
if (!task.memory) {
|
||||
|
|
|
@ -29,6 +29,9 @@ input:
|
|||
type: file
|
||||
description: BAI/CRAI file from alignment
|
||||
pattern: "*.{bai,crai}"
|
||||
- intervals:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
- fasta:
|
||||
type: file
|
||||
description: The reference fasta file
|
||||
|
@ -47,9 +50,6 @@ input:
|
|||
- dbsnp_tbi:
|
||||
type: file
|
||||
description: VCF index of dbsnp (optional)
|
||||
- interval:
|
||||
type: file
|
||||
description: Bed file with the genomic regions included in the library (optional)
|
||||
|
||||
output:
|
||||
- meta:
|
||||
|
|
|
@ -8,39 +8,40 @@ workflow test_gatk4_applybqsr {
|
|||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_baserecalibrator_table'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_baserecalibrator_table'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict, [] )
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict )
|
||||
}
|
||||
|
||||
workflow test_gatk4_applybqsr_intervals {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_baserecalibrator_table'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_baserecalibrator_table'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['genome']['test_bed'], checkIfExists: true)
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
intervals = file(params.test_data['sarscov2']['genome']['test_bed'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict, intervals )
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict )
|
||||
}
|
||||
|
||||
workflow test_gatk4_applybqsr_cram {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_baserecalibrator_table'], checkIfExists: true)
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_baserecalibrator_table'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
]
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
intervals = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict, intervals )
|
||||
GATK4_APPLYBQSR ( input, fasta, fai, dict )
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
- gatk4
|
||||
- gatk4/applybqsr
|
||||
files:
|
||||
- path: output/gatk4/test.bam
|
||||
md5sum: a333f80284a89a8daab28d3686a0b365
|
||||
- path: output/gatk4/test.cram
|
||||
md5sum: b7659b3b2adaabbe73658dc059dbfdf6
|
||||
- path: output/gatk4/versions.yml
|
||||
md5sum: 57933f27b3a31b05af3f7c248d365396
|
||||
|
|
|
@ -7,7 +7,8 @@ include { GATK4_BASERECALIBRATOR } from '../../../../modules/gatk4/baserecalibra
|
|||
workflow test_gatk4_baserecalibrator {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
@ -15,14 +16,14 @@ workflow test_gatk4_baserecalibrator {
|
|||
sites = file(params.test_data['sarscov2']['illumina']['test_vcf_gz'], checkIfExists: true)
|
||||
sites_tbi = file(params.test_data['sarscov2']['illumina']['test_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, [], sites, sites_tbi )
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, sites, sites_tbi )
|
||||
}
|
||||
|
||||
workflow test_gatk4_baserecalibrator_cram {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_baserecalibrator_table'], checkIfExists: true)
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
@ -30,28 +31,29 @@ workflow test_gatk4_baserecalibrator_cram {
|
|||
sites = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz'], checkIfExists: true)
|
||||
sites_tbi = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, [], sites, sites_tbi )
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, sites, sites_tbi )
|
||||
}
|
||||
|
||||
workflow test_gatk4_baserecalibrator_intervals {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['genome']['test_bed'], checkIfExists: true)
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
intervals = file(params.test_data['sarscov2']['genome']['test_bed'], checkIfExists: true)
|
||||
sites = file(params.test_data['sarscov2']['illumina']['test_vcf_gz'], checkIfExists: true)
|
||||
sites_tbi = file(params.test_data['sarscov2']['illumina']['test_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, intervals, sites, sites_tbi )
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, sites, sites_tbi )
|
||||
}
|
||||
|
||||
workflow test_gatk4_baserecalibrator_multiple_sites {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
@ -63,5 +65,5 @@ workflow test_gatk4_baserecalibrator_multiple_sites {
|
|||
file(params.test_data['sarscov2']['illumina']['test2_vcf_gz_tbi'], checkIfExists: true)
|
||||
]
|
||||
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, [], sites, sites_tbi )
|
||||
GATK4_BASERECALIBRATOR ( input, fasta, fai, dict, sites, sites_tbi )
|
||||
}
|
||||
|
|
|
@ -10,13 +10,15 @@ workflow test_gatk4_genotypegvcfs_vcf_input {
|
|||
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_idx'], checkIfExists: true) ]
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_idx'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
fastaDict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [], [] )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [])
|
||||
}
|
||||
|
||||
// Basic parameters with compressed VCF input
|
||||
|
@ -24,13 +26,15 @@ workflow test_gatk4_genotypegvcfs_gz_input {
|
|||
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true) ]
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
fastaDict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [], [] )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [])
|
||||
}
|
||||
|
||||
// Basic parameters + optional dbSNP
|
||||
|
@ -38,7 +42,9 @@ workflow test_gatk4_genotypegvcfs_gz_input_dbsnp {
|
|||
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true) ]
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
@ -47,7 +53,7 @@ workflow test_gatk4_genotypegvcfs_gz_input_dbsnp {
|
|||
dbsnp = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz'], checkIfExists: true)
|
||||
dbsnpIndex = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex, [] )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex)
|
||||
}
|
||||
|
||||
// Basic parameters + optional intervals
|
||||
|
@ -55,15 +61,14 @@ workflow test_gatk4_genotypegvcfs_gz_input_intervals {
|
|||
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true) ]
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true) ]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
fastaDict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
intervalsBed = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [], intervalsBed )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [])
|
||||
}
|
||||
|
||||
// Basic parameters + optional dbSNP + optional intervals
|
||||
|
@ -71,7 +76,9 @@ workflow test_gatk4_genotypegvcfs_gz_input_dbsnp_intervals {
|
|||
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true) ]
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_genome_vcf_gz_tbi'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
|
@ -80,9 +87,7 @@ workflow test_gatk4_genotypegvcfs_gz_input_dbsnp_intervals {
|
|||
dbsnp = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz'], checkIfExists: true)
|
||||
dbsnpIndex = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
intervalsBed = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex, intervalsBed )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex )
|
||||
}
|
||||
|
||||
// Basic parameters with GenomicsDB input
|
||||
|
@ -97,9 +102,11 @@ workflow test_gatk4_genotypegvcfs_gendb_input {
|
|||
UNTAR ( test_genomicsdb )
|
||||
gendb = UNTAR.out.untar.collect()
|
||||
gendb.add([])
|
||||
gendb.add([])
|
||||
|
||||
input = Channel.of([ id:'test' ]).combine(gendb)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [], [] )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [])
|
||||
}
|
||||
|
||||
// Basic parameters with GenomicsDB + optional dbSNP
|
||||
|
@ -117,9 +124,10 @@ workflow test_gatk4_genotypegvcfs_gendb_input_dbsnp {
|
|||
UNTAR ( test_genomicsdb )
|
||||
gendb = UNTAR.out.untar.collect()
|
||||
gendb.add([])
|
||||
gendb.add([])
|
||||
input = Channel.of([ id:'test' ]).combine(gendb)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex, [] )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex)
|
||||
}
|
||||
|
||||
// Basic parameters with GenomicsDB + optional intervals
|
||||
|
@ -129,16 +137,15 @@ workflow test_gatk4_genotypegvcfs_gendb_input_intervals {
|
|||
fastaIndex = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
fastaDict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
intervalsBed = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
test_genomicsdb = file(params.test_data['homo_sapiens']['illumina']['test_genomicsdb_tar_gz'], checkIfExists: true)
|
||||
|
||||
UNTAR ( test_genomicsdb )
|
||||
gendb = UNTAR.out.untar.collect()
|
||||
gendb.add([])
|
||||
gendb.add([file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)])
|
||||
input = Channel.of([ id:'test' ]).combine(gendb)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [], intervalsBed )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, [], [] )
|
||||
}
|
||||
|
||||
// Basic parameters with GenomicsDB + optional dbSNP + optional intervals
|
||||
|
@ -151,14 +158,13 @@ workflow test_gatk4_genotypegvcfs_gendb_input_dbsnp_intervals {
|
|||
dbsnp = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz'], checkIfExists: true)
|
||||
dbsnpIndex = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz_tbi'], checkIfExists: true)
|
||||
|
||||
intervalsBed = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
test_genomicsdb = file(params.test_data['homo_sapiens']['illumina']['test_genomicsdb_tar_gz'], checkIfExists: true)
|
||||
|
||||
UNTAR ( test_genomicsdb )
|
||||
gendb = UNTAR.out.untar.collect()
|
||||
gendb.add([])
|
||||
gendb.add([file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)])
|
||||
input = Channel.of([ id:'test' ]).combine(gendb)
|
||||
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex, intervalsBed )
|
||||
GATK4_GENOTYPEGVCFS ( input, fasta, fastaIndex, fastaDict, dbsnp, dbsnpIndex )
|
||||
}
|
||||
|
|
|
@ -7,31 +7,34 @@ include { GATK4_HAPLOTYPECALLER } from '../../../../modules/gatk4/haplotypecalle
|
|||
workflow test_gatk4_haplotypecaller {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true)
|
||||
file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam_bai'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, [], [], [] )
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, [], [])
|
||||
}
|
||||
|
||||
workflow test_gatk4_haplotypecaller_cram {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true)
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true),
|
||||
[]
|
||||
]
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true)
|
||||
dict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, [], [], [] )
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, [], [])
|
||||
}
|
||||
|
||||
workflow test_gatk4_haplotypecaller_intervals_dbsnp {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true)
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
]
|
||||
|
||||
fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true)
|
||||
|
@ -39,7 +42,6 @@ workflow test_gatk4_haplotypecaller_intervals_dbsnp {
|
|||
dict = file(params.test_data['homo_sapiens']['genome']['genome_dict'], checkIfExists: true)
|
||||
sites = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz'], checkIfExists: true)
|
||||
sites_tbi = file(params.test_data['homo_sapiens']['genome']['dbsnp_146_hg38_vcf_gz_tbi'], checkIfExists: true)
|
||||
intervals = file(params.test_data['homo_sapiens']['genome']['genome_bed'], checkIfExists: true)
|
||||
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, sites, sites_tbi, intervals )
|
||||
GATK4_HAPLOTYPECALLER ( input, fasta, fai, dict, sites, sites_tbi )
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue