Skip to content

Commit

Permalink
More config updates
Browse files Browse the repository at this point in the history
  • Loading branch information
grst committed Jan 26, 2024
1 parent 306cd4e commit ede1ee9
Showing 1 changed file with 88 additions and 74 deletions.
162 changes: 88 additions & 74 deletions conf/modules.config
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,12 @@ process {
].join(' ').trim()
publishDir = [
[
path: { "${params.outdir}/umitools" },
path: { "${params.outdir}/umi_dedup/fastq_extracted_umi" },
mode: params.publish_dir_mode,
pattern: "*.log"
],
[
path: { "${params.outdir}/umitools" },
path: { "${params.outdir}/umi_dedup/fastq_extracted_umi" },
mode: params.publish_dir_mode,
pattern: "*.fastq.gz",
enabled: params.save_umi_intermeds
Expand All @@ -114,7 +114,7 @@ process {
//
withName: 'INDEX_GENOME' {
publishDir = [
path: { "${params.outdir}/bowtie_index" },
path: { "${params.outdir}/bowtie_index/genome" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
Expand All @@ -123,18 +123,66 @@ process {
//
// UMI deduplication
//
withName: '.*:DEDUPLICATE_UMIS:UMI_MAP_GENOME' {
publishDir = [
path: { "${params.outdir}/umi_dedup/bam_mapped" },
mode: params.publish_dir_mode,
pattern: '*.bam',
enabled: (
params.save_umi_intermeds
)
]
}
withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:SAMTOOLS_SORT' {
ext.prefix = { "${meta.id}.sorted" }
publishDir = [
path: { "${params.outdir}/umi_dedup/bam_mapped_sorted" },
mode: params.publish_dir_mode,
pattern: '*.{bam}',
enabled: (
params.save_umi_intermeds
)
]
}
withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:SAMTOOLS_INDEX' {
ext.prefix = { "${meta.id}.sorted" }
publishDir = [
path: { "${params.outdir}/umi_dedup/bam_mapped_sorted" },
mode: params.publish_dir_mode,
pattern: '*.{bai,csi}',
enabled: (
params.save_umi_intermeds
)
]
}
withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:.*' {
publishDir = [
path: { "${params.outdir}/umi_dedup/bam_mapped_sorted" },
mode: params.publish_dir_mode,
pattern: '*.{stats,flagstat,idxstats}'
]
}
withName: '.*:DEDUPLICATE_UMIS:UMICOLLAPSE' {
ext.args = { meta.single_end ? "--algo ${params.umitools_method} --two-pass" : "--method ${params.umitools_method} --two-pass --paired --remove-unpaired --remove-chimeric" }
ext.prefix = { "${meta.id}.umi_dedup.sorted" }
publishDir = [
path: { "${params.outdir}/umi_dedup" },
path: { "${params.outdir}/bam_deduplicated" },
mode: params.publish_dir_mode,
pattern: '*.bam',
enabled: (
params.save_umi_intermeds
)
]
}
withName: '.*:DEDUPLICATE_UMIS:SAMTOOLS_BAM2FQ' {
publishDir = [
path: { "${params.outdir}/umi_dedup/fastq_deduplicated" },
mode: params.publish_dir_mode,
enabled: (
params.save_umi_intermeds
)
]
}

//
// MIRTRACE QC
Expand All @@ -158,146 +206,112 @@ process {
]
}



//----

//
// MIRNA_QUANT
//
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:FORMAT_.*' {
publishDir = [
path: { "${params.outdir}/genome" },
path: { "${params.outdir}/mirna_quant/reference" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'EDGER_QC' {
publishDir = [
path: { "${params.outdir}/edger" },
mode: params.publish_dir_mode,
enabled: true
]
}


//
// UMI tools deduplication
//



withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:SAMTOOLS_SORT' {
ext.prefix = { "${meta.id}.sorted" }
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:PARSE_.*' {
publishDir = [
path: { "${params.outdir}/umi_dedup" },
path: { "${params.outdir}/mirna_quant/reference" },
mode: params.publish_dir_mode,
pattern: '*.{bam}',
enabled: (
params.save_umi_intermeds
)
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}

withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:SAMTOOLS_INDEX' {
ext.prefix = { "${meta.id}.sorted" }
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:INDEX_MATURE' {
publishDir = [
path: { "${params.outdir}/umi_dedup" },
path: { "${params.outdir}/bowtie_index/mirna_mature" },
mode: params.publish_dir_mode,
pattern: '*.{bai,csi}',
enabled: (
params.save_umi_intermeds
)
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}

withName: '.*:DEDUPLICATE_UMIS:BAM_SORT_STATS_SAMTOOLS:.*' {
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:INDEX_HAIRPIN' {
publishDir = [
path: { "${params.outdir}/umi_dedup/samtools_stats" },
mode: params.publish_dir_mode,
pattern: '*.{stats,flagstat,idxstats}'
]
}

//
// Quantification
//

withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:PARSE_.*' {
publishDir = [
path: { "${params.outdir}/genome" },
path: { "${params.outdir}/bowtie_index/mirna_hairpin" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:BAM_STATS_.*:SAMTOOLS_SORT' {
ext.prefix = { "${meta.id}.sorted" }
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:(BOWTIE_MAP_MATURE|BAM_STATS_MATURE).*' {
publishDir = [
path: { "${params.outdir}/samtools" },
path: { "${params.outdir}/mirna_quant/bam/mature" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:BAM_STATS_.*:BAM_STATS_SAMTOOLS:.*' {
ext.prefix = { "${meta.id}.sorted" }
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:(BOWTIE_MAP_HAIRPIN|BAM_STATS_HAIRPIN).*' {
publishDir = [
path: { "${params.outdir}/samtools/samtools_stats" },
path: { "${params.outdir}/mirna_quant/bam/hairpin" },
mode: params.publish_dir_mode,
pattern: "*.{stats,flagstat,idxstats}"
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:BOWTIE_MAP_.*' {
withName: 'EDGER_QC' {
publishDir = [
path: { "${params.outdir}/unmapped/fastq" },
path: { "${params.outdir}/mirna_quant/edger_qc" },
mode: params.publish_dir_mode,
pattern: "unmapped/*.gz"
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'SEQCLUSTER_SEQUENCES' {
publishDir = [
path: { "${params.outdir}/seqcluster" },
enabled: false
path: { "${params.outdir}/mirna_quant/seqcluster" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'MIRTOP_QUANT' {
publishDir = [
path: { "${params.outdir}" },
path: { "${params.outdir}/mirna_quant/mirtop" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:MIRNA_QUANT:TABLE_MERGE' {
publishDir = [
path: { "${params.outdir}/mirtop" },
path: { "${params.outdir}/mirna_quant/mirtop" },
mode: params.publish_dir_mode,
pattern: "*.tsv"
]
}



//
// GENOME_QUANT
//
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:GENOME_QUANT:BAM_SORT_STATS_SAMTOOLS:SAMTOOLS_.*' {
ext.prefix = { "${meta.id}.sorted" }
publishDir = [
path: { "${params.outdir}/samtools" },
path: { "${params.outdir}/genome_quant/bam" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}

withName: 'NFCORE_SMRNASEQ:SMRNASEQ:GENOME_QUANT:BAM_SORT_STATS_SAMTOOLS:BAM_STATS_SAMTOOLS:.*' {
ext.prefix = { "${meta.id}.sorted" }
publishDir = [
path: { "${params.outdir}/samtools/samtools_stats" },
path: { "${params.outdir}/genome_quant/bam" },
mode: params.publish_dir_mode,
pattern: "*.{stats,flagstat,idxstats}"
]
}
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:GENOME_QUANT:BOWTIE_MAP_.*' {
withName: 'NFCORE_SMRNASEQ:SMRNASEQ:GENOME_QUANT:BOWTIE_MAP_GENOME' {
publishDir = [
path: { "${params.outdir}/unmapped/fastq" },
path: { "${params.outdir}/unmapped/bam" },
mode: params.publish_dir_mode,
pattern: "unmapped/*.gz"
]
}


//
// MIRDEEP
//
withName: 'MIRDEEP2_MAPPER' {
publishDir = [
path: { "${params.outdir}/mirdeep2/mapper" },
Expand Down

0 comments on commit ede1ee9

Please sign in to comment.