Skip to content

Commit

Permalink
Merge pull request #516 from genomic-medicine-sweden/rename_outputs
Browse files Browse the repository at this point in the history
Rename outputs
  • Loading branch information
ramprasadn authored Feb 16, 2024
2 parents 27f0aae + 3099751 commit 6e04808
Show file tree
Hide file tree
Showing 28 changed files with 315 additions and 141 deletions.
25 changes: 12 additions & 13 deletions conf/modules/align_MT.config
Original file line number Diff line number Diff line change
Expand Up @@ -21,29 +21,29 @@ process {
withName: '.*ALIGN_MT:BWAMEM2_MEM_MT' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes")) }
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted" }
}
}

if (params.aligner.equals("bwa")) {
withName: '.*ALIGN_MT:BWA_MEM_MT' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes")) }
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted" }
}
}

if (params.aligner.equals("sentieon")) {
withName: '.*ALIGN_MT:SENTIEON_BWAMEM_MT' {
ext.args = { "-M -K 10000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes"))}
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted" }
}
}

withName: '.*ALIGN_MT:GATK4_MERGEBAMALIGNMENT_MT' {
ext.args = '--TMP_DIR . --CREATE_INDEX true --MAX_GAPS -1 --SORT_ORDER queryname --INCLUDE_SECONDARY_ALIGNMENTS false --PAIRED_RUN false --VALIDATION_STRINGENCY LENIENT'
ext.prefix = { "${meta.id}_merged" }
ext.prefix = { "${meta.id}_sorted_merged" }
}

withName: '.*ALIGN_MT:PICARD_ADDORREPLACEREADGROUPS_MT' {
Expand All @@ -59,11 +59,11 @@ process {

withName: '.*ALIGN_MT:PICARD_MARKDUPLICATES_MT' {
ext.args = '--TMP_DIR . --VALIDATION_STRINGENCY LENIENT --CREATE_INDEX true'
ext.prefix = { "${meta.id}_markduplicates" }
ext.prefix = { "${meta.id}_sorted_merged_md" }
}

withName: '.*ALIGN_MT:SAMTOOLS_SORT_MT' {
ext.prefix = { "${meta.id}_sorted" }
ext.prefix = { "${meta.id}_sorted_merged_md_sorted" }
}

}
Expand All @@ -78,30 +78,29 @@ process {
withName: '.*ALIGN_MT_SHIFT:BWAMEM2_MEM_MT' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes")) }
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted_shifted" }
}
}

if (params.aligner.equals("sentieon")) {
withName: '.*ALIGN_MT_SHIFT:SENTIEON_BWAMEM_MT' {
ext.args = { "-M -K 10000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes"))}
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted_shifted" }
}
}


if (params.aligner.equals("bwa")) {
withName: '.*ALIGN_MT_SHIFT:BWA_MEM_MT' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.when = { !(params.analysis_type.equals("wes")) }
ext.prefix = { "${meta.id}.sorted" }
ext.prefix = { "${meta.id}_sorted_shifted" }
}
}

withName: '.*ALIGN_MT_SHIFT:GATK4_MERGEBAMALIGNMENT_MT' {
ext.args = '--TMP_DIR . --CREATE_INDEX true --MAX_GAPS -1 --SORT_ORDER queryname --INCLUDE_SECONDARY_ALIGNMENTS false --PAIRED_RUN false --VALIDATION_STRINGENCY LENIENT'
ext.prefix = { "${meta.id}_merged_shifted" }
ext.prefix = { "${meta.id}_sorted_merged_shifted" }
}

withName: '.*ALIGN_MT_SHIFT:PICARD_ADDORREPLACEREADGROUPS_MT' {
Expand All @@ -117,11 +116,11 @@ process {

withName: '.*ALIGN_MT_SHIFT:PICARD_MARKDUPLICATES_MT' {
ext.args = '--TMP_DIR . --VALIDATION_STRINGENCY LENIENT --CREATE_INDEX true'
ext.prefix = { "${meta.id}_markduplicates_shifted" }
ext.prefix = { "${meta.id}_sorted_merged_md_shifted" }
}

withName: '.*ALIGN_MT_SHIFT:SAMTOOLS_SORT_MT' {
ext.prefix = { "${meta.id}_sorted_shifted" }
ext.prefix = { "${meta.id}_sorted_merged_md_sorted_shifted" }
}

}
8 changes: 4 additions & 4 deletions conf/modules/align_bwa_bwamem2.config
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ process {

withName: '.*ALIGN:ALIGN_BWA_BWAMEM2:BWAMEM2_MEM' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.prefix = { "${meta.id}.sorted" }
ext.when = { params.aligner.equals("bwamem2")}
ext.prefix = { "${meta.id}_sorted" }
ext.when = { params.aligner.equals("bwamem2") }
}

withName: '.*ALIGN:ALIGN_BWA_BWAMEM2:BWA_MEM' {
ext.args = { "-M -K 100000000 -R ${meta.read_group}" }
ext.prefix = { "${meta.id}.sorted" }
ext.when = { params.aligner.equals("bwa")}
ext.prefix = { "${meta.id}_sorted" }
ext.when = { params.aligner.equals("bwa") }
}

withName: '.*ALIGN:ALIGN_BWA_BWAMEM2:SAMTOOLS_STATS' {
Expand Down
27 changes: 17 additions & 10 deletions conf/modules/annotate_genome_snvs.config
Original file line number Diff line number Diff line change
Expand Up @@ -25,26 +25,29 @@ process {

withName: '.*ANNOTATE_GENOME_SNVS:RHOCALL_ANNOTATE' {
ext.args = { "--v14 " }
ext.prefix = { "${meta.id}_rohann" }
}

withName: '.*ANNOTATE_GENOME_SNVS:ZIP_TABIX_ROHCALL' {
ext.prefix = { "${input.simpleName}" }
}

withName: '.*ANNOTATE_GENOME_SNVS:VCFANNO' {
ext.prefix = { "${meta.id}_rohann_vcfanno" }
ext.prefix = { "${vcf.simpleName}_vcfanno" }
}

withName: '.*ANNOTATE_GENOME_SNVS:UPD_SITES' {
ext.prefix = { "${meta.id}_rohann_vcfanno_upd_sites" }
ext.prefix = { "${vcf.simpleName}_upd_sites" }
ext.args = {"--af-tag GNOMADAF --proband ${meta.upd_child} --mother ${meta.mother} --father ${meta.father} sites"}
}

withName: '.*ANNOTATE_GENOME_SNVS:UPD_REGIONS' {
ext.prefix = { "${meta.id}_rohann_vcfanno_upd_regions" }
ext.prefix = { "${vcf.simpleName}_upd_regions" }
ext.args = {"--af-tag GNOMADAF --proband ${meta.upd_child} --mother ${meta.mother} --father ${meta.father} regions --min-size 5 --min-sites 1"}
ext.when = { !(workflow.profile.tokenize(',').intersect(['test', 'test_one_sample']).size() >= 1) || workflow.stubRun }
}

withName: '.*ANNOTATE_GENOME_SNVS:CHROMOGRAPH_SITES' {
ext.prefix = { "${meta7.id}_rohann_vcfanno_upd_sites_chromograph" }
ext.prefix = { "${sites.simpleName}_chromograph" }
ext.args = { "--euploid" }
tag = {"${meta7.id}"}
publishDir = [
Expand All @@ -55,7 +58,7 @@ process {
}

withName: '.*ANNOTATE_GENOME_SNVS:CHROMOGRAPH_REGIONS' {
ext.prefix = { "${meta6.id}_rohann_vcfanno_upd_regions_chromograph" }
ext.prefix = { "${regions.simpleName}_chromograph" }
ext.args = { '--euploid' }
ext.when = { !(workflow.profile.tokenize(',').intersect(['test', 'test_one_sample', 'test_sentieon']).size() >= 1) || workflow.stubRun }
tag = {"${meta6.id}"}
Expand All @@ -66,17 +69,21 @@ process {
]
}

withName: '.*ANNOTATE_GENOME_SNVS:ZIP_TABIX_VCFANNO' {
ext.prefix = { "${input.simpleName}" }
}

withName: '.*ANNOTATE_GENOME_SNVS:BCFTOOLS_VIEW' {
ext.prefix = { "${meta.id}_rohann_vcfanno_filter" }
ext.prefix = { "${vcf.simpleName}_filter" }
ext.args = { '--output-type z --exclude "INFO/GNOMADAF > 0.70 | INFO/GNOMADAF_popmax > 0.70" ' }
}

withName: '.*ANNOTATE_GENOME_SNVS:GATK4_SELECTVARIANTS' {
ext.prefix = { "${meta.id}_${intervals.simpleName}" }
ext.prefix = { "${vcf.simpleName}_${intervals.simpleName}" }
}

withName: '.*ANNOTATE_GENOME_SNVS:ENSEMBLVEP_SNV' {
ext.prefix = { "${vcf.simpleName}_rohann_vcfanno_filter_vep" }
ext.prefix = { "${meta.prefix}_vep_${meta.scatterid}" }
ext.args = { [
'--dir_plugins vep_cache/Plugins',
'--plugin LoFtool,LoFtool_scores.txt',
Expand All @@ -94,7 +101,7 @@ process {
}

withName: '.*ANNOTATE_GENOME_SNVS:BCFTOOLS_CONCAT' {
ext.prefix = { "${meta.id}_rohann_vcfanno_filter_vep" }
ext.prefix = { "${meta.prefix}_vep" }
publishDir = [
path: { "${params.outdir}/annotate_snv/genome" },
mode: params.publish_dir_mode,
Expand Down
85 changes: 44 additions & 41 deletions conf/modules/annotate_mt_snvs.config
Original file line number Diff line number Diff line change
Expand Up @@ -16,49 +16,52 @@
//

process {
if (!params.skip_mt_annotation) {
withName: '.*ANNOTATE_MT_SNVS:ENSEMBLVEP_MT' {
ext.args = { [
'--dir_plugins vep_cache/Plugins',
'--plugin LoFtool,LoFtool_scores.txt',
'--plugin pLI,pLI_values.txt',
'--plugin SpliceAI,snv=spliceai_21_scores_raw_snv_-v1.3-.vcf.gz,indel=spliceai_21_scores_raw_snv_-v1.3-.vcf.gz',
'--distance 0',
'--buffer_size 20000',
'--format vcf --fork 4 --max_sv_size 248956422',
'--appris --biotype --cache --canonical --ccds --compress_output bgzip',
'--domains --exclude_predicted --force_overwrite',
'--hgvs --humdiv --no_progress --numbers',
'--merged --polyphen p --protein --offline --regulatory --sift p --symbol --tsl --vcf',
'--uniprot'
].join(' ') }
}
withName: '.*ANNOTATE_MT_SNVS:ENSEMBLVEP_MT' {
ext.args = { [
'--dir_plugins vep_cache/Plugins',
'--plugin LoFtool,LoFtool_scores.txt',
'--plugin pLI,pLI_values.txt',
'--plugin SpliceAI,snv=spliceai_21_scores_raw_snv_-v1.3-.vcf.gz,indel=spliceai_21_scores_raw_snv_-v1.3-.vcf.gz',
'--distance 0',
'--buffer_size 20000',
'--format vcf --fork 4 --max_sv_size 248956422',
'--appris --biotype --cache --canonical --ccds --compress_output bgzip',
'--domains --exclude_predicted --force_overwrite',
'--hgvs --humdiv --no_progress --numbers',
'--merged --polyphen p --protein --offline --regulatory --sift p --symbol --tsl --vcf',
'--uniprot'
].join(' ') }
ext.prefix = { "${meta.prefix}" }
}

withName: '.*ANNOTATE_MT_SNVS:ZIP_TABIX_HMTNOTE' {
ext.prefix = { "${meta.id}_vep_vcfanno_hmtnote_mt" }
publishDir = [
path: { "${params.outdir}/annotate_snv/mitochondria" },
mode: params.publish_dir_mode,
pattern: "*{vcf.gz,vcf.gz.tbi}",
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: '.*ANNOTATE_MT_SNVS:VCFANNO_MT' {
ext.prefix = { "${meta.prefix}" }
}

withName: '.*ANNOTATE_MT_SNVS:HMTNOTE_ANNOTATE' {
ext.prefix = { "${meta.id}_vep_vcfanno_hmtnote_mt" }
ext.args = '--offline'
publishDir = [
enabled: false
]
}
withName: '.*ANNOTATE_MT_SNVS:ZIP_TABIX_HMTNOTE' {
ext.prefix = { "${meta.prefix}" }
publishDir = [
path: { "${params.outdir}/annotate_snv/mitochondria" },
mode: params.publish_dir_mode,
pattern: "*{vcf.gz,vcf.gz.tbi}",
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}

withName: '.*ANNOTATE_MT_SNVS:HMTNOTE_ANNOTATE' {
ext.prefix = { "${meta.prefix}_uncompressed" }
ext.args = '--offline'
publishDir = [
enabled: false
]
}

withName: '.*ANNOTATE_MT_SNVS:HAPLOGREP2_CLASSIFY_MT' {
ext.prefix = { "${meta.id}_haplogrep" }
publishDir = [
path: { "${params.outdir}/annotate_snv/mitochondria" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
withName: '.*ANNOTATE_MT_SNVS:HAPLOGREP2_CLASSIFY_MT' {
ext.prefix = { "${meta.prefix}_haplogrep" }
publishDir = [
path: { "${params.outdir}/annotate_snv/mitochondria" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
}
2 changes: 1 addition & 1 deletion conf/modules/annotate_structural_variants.config
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ process {
}

withName: '.*ANNOTATE_STRUCTURAL_VARIANTS:PICARD_SORTVCF' {
ext.prefix = { "${meta.id}_sortvcf" }
ext.prefix = { "${meta.id}_svdbquery" }
}

withName: '.*ANNOTATE_STRUCTURAL_VARIANTS:BCFTOOLS_VIEW' {
Expand Down
2 changes: 1 addition & 1 deletion conf/modules/call_snv.config
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ process {

withName: '.*CALL_SNV:GATK4_SELECTVARIANTS' {
ext.args = { "--exclude-intervals ${params.mito_name}" }
ext.prefix = { "${meta.id}_nomito" }
ext.prefix = { "${meta.id}_snv" }
publishDir = [
path: { "${params.outdir}/call_snv/genome" },
mode: params.publish_dir_mode,
Expand Down
1 change: 1 addition & 0 deletions conf/modules/call_structural_variants.config
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ process {
}

withName: '.*CALL_STRUCTURAL_VARIANTS:SVDB_MERGE' {
ext.prefix = {"${meta.id}_sv"}
ext.args = '--pass_only --same_order'
publishDir = [
path: { "${params.outdir}/call_sv/genome" },
Expand Down
1 change: 1 addition & 0 deletions conf/modules/call_sv_MT.config
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ process {

withName: '.*CALL_SV_MT:MT_DELETION' {
ext.args = '-s --insert-size 16000'
ext.prefix = { "${meta.id}_mitochondria_deletions" }
publishDir = [
path: { "${params.outdir}/call_sv/mitochondria" },
mode: params.publish_dir_mode,
Expand Down
2 changes: 1 addition & 1 deletion conf/modules/call_sv_germlinecnvcaller.config
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ process {
}

withName: '.*CALL_STRUCTURAL_VARIANTS:CALL_SV_GERMLINECNVCALLER:BCFTOOLS_VIEW' {
ext.prefix = { "${meta.id}_gatkcnv_segments_reffiltered" }
ext.prefix = { "${meta.id}_gatkcnv_segments_refiltered" }
ext.args = { '--output-type z --exclude "N_ALT = 0" ' }
}
}
Expand Down
17 changes: 1 addition & 16 deletions conf/modules/generate_clinical_set.config
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ process {
withName: '.*:GENERATE_CLINICAL_SET_SNV:TABIX_BGZIP' {
ext.when = !params.skip_vep_filter
ext.prefix = { "${meta.id}_snv_${meta.set}" }
publishDir = [
path: { "${params.outdir}/rank_and_filter" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
}

Expand All @@ -40,18 +35,13 @@ process {
process {
withName: '.*:GENERATE_CLINICAL_SET_SV:ENSEMBLVEP_FILTERVEP' {
ext.when = !params.skip_vep_filter
ext.prefix = { "${meta.id}_sv_${meta.set}" }
ext.prefix = { "${input.simpleName}_sv_${meta.set}" }
ext.args = { "--filter \"HGNC_ID in ${meta.hgnc_ids.join(',')}\"" }
}

withName: '.*:GENERATE_CLINICAL_SET_SV:TABIX_BGZIP' {
ext.when = !params.skip_vep_filter
ext.prefix = { "${meta.id}_sv_${meta.set}" }
publishDir = [
path: { "${params.outdir}/rank_and_filter" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
}

Expand All @@ -67,10 +57,5 @@ process {
withName: '.*:GENERATE_CLINICAL_SET_MT:TABIX_BGZIP' {
ext.when = !params.skip_vep_filter
ext.prefix = { "${meta.id}_mt_${meta.set}" }
publishDir = [
path: { "${params.outdir}/rank_and_filter" },
mode: params.publish_dir_mode,
saveAs: { filename -> filename.equals('versions.yml') ? null : filename }
]
}
}
1 change: 1 addition & 0 deletions conf/modules/qc_bam.config
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ process {

withName: '.*QC_BAM:UCSC_WIGTOBIGWIG' {
ext.args = '-clip'
ext.prefix = { "${meta.id}_tidditcov" }
}

withName: '.*QC_BAM:CHROMOGRAPH_COV' {
Expand Down
4 changes: 2 additions & 2 deletions conf/modules/rank_variants.config
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ process {
].join(' ') }
}

withName: '.*RANK_VARIANTS_SNV:GENMOD_MODELS' {
ext.prefix = { "${meta.id}_snv_genmod_models_${meta.set}" }
withName: '.*RANK_VARIANTS_SV:GENMOD_MODELS' {
ext.prefix = { "${meta.id}_sv_genmod_models_${meta.set}" }
ext.args = " --whole_gene "
}

Expand Down
Loading

0 comments on commit 6e04808

Please sign in to comment.