Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update tiddit/sv #581

Merged
merged 19 commits into from
Jun 16, 2022
Merged
Show file tree
Hide file tree
Changes from 18 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,27 +33,28 @@ jobs:
test:
- "aligner"
- "annotation"
- "default"
- "cnvkit"
- "controlfreec"
- "deepvariant"
- "default"
- "freebayes"
- "gatk4_spark"
- "haplotypecaller"
- "manta"
- "markduplicates"
- "mutect2"
- "msisensorpro"
# - 'save_bam_mapped'
- "mutect2"
- "prepare_recalibration"
- "recalibrate"
- "variantcalling_channel"
# - 'save_bam_mapped'
- "skip_markduplicates"
- "split_fastq"
- "strelka"
- "strelkabp"
- "split_fastq"
- "targeted"
- "tiddit"
- "tumor_normal_pair"
- "variantcalling_channel"

steps:
- name: Check out pipeline code
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- [#572](https://github.com/nf-core/sarek/pull/572) - Adjusted subway map svg for firefox compatibility
- [#578](https://github.com/nf-core/sarek/pull/578) - Updated module deeptools/bamcoverage
- [#585](https://github.com/nf-core/sarek/pull/585) - Remove explicit BAM to CRAM conversion after MarkduplicatesSpark; tool does it internally
- [#581](https://github.com/nf-core/sarek/pull/581) - `TIDDIT` is updated to `3.1.0`

### Fixed

Expand Down Expand Up @@ -87,6 +88,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- [#567](https://github.com/nf-core/sarek/pull/567) - Fix interval name resolving during scatter/gather by moving logic to modules.config causing name to be correctly resolved on process execution; also fixed duplicate naming when variant callers produce multiple vcf files by adding field `type` to `meta` map
- [#585](https://github.com/nf-core/sarek/pull/585) - Fix Spark usage for GATK4 modules
- [#587](https://github.com/nf-core/sarek/pull/587) - Fix issue with VEP extra files
- [#581](https://github.com/nf-core/sarek/pull/581) - `TIDDIT` is back
- [#590](https://github.com/nf-core/sarek/pull/590) - Fix empty folders during scatter/gather

### Deprecated
Expand Down
24 changes: 18 additions & 6 deletions conf/modules.config
Original file line number Diff line number Diff line change
Expand Up @@ -652,12 +652,24 @@ process{
]
}

// withName: 'TIDDIT_SV' {
// publishDir = [
// mode: params.publish_dir_mode,
// path: { "${params.outdir}/variant_calling/${meta.id}/tiddit" }
// ]
// }
//TIDDIT
withName: 'TIDDIT_SV' {
ext.when = { params.tools && params.tools.contains('tiddit') }
ext.args = { bwa_index ? "" : "--skip_assembly" }
publishDir = [
mode: params.publish_dir_mode,
path: { "${params.outdir}/variant_calling/${meta.id}/tiddit" },
pattern: "*tab",
]
}
withName : 'TABIX_BGZIP_TIDDIT_SV' {
ext.prefix = { "${meta.id}.vcf" }
publishDir = [
mode: params.publish_dir_mode,
path: { "${params.outdir}/variant_calling/${meta.id}/tiddit" },
pattern: "*{vcf.gz,vcf.gz.tbi}"
]
}

// TUMOR_VARIANT_CALLING

Expand Down
2 changes: 1 addition & 1 deletion modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
"git_sha": "b3e9b88e80880f450ad79a95b2b7aa05e1de5484"
},
"tiddit/sv": {
"git_sha": "57cb730e78634673fb254a77606e014ce942734c"
"git_sha": "b689b8ed88a9f89eb2f7c75d3eb0bace77ade109"
},
"trimgalore": {
"git_sha": "85ec13ff1fc2196c5a507ea497de468101baabed"
Expand Down
33 changes: 17 additions & 16 deletions modules/nf-core/modules/tiddit/sv/main.nf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 12 additions & 8 deletions modules/nf-core/modules/tiddit/sv/meta.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

36 changes: 23 additions & 13 deletions subworkflows/local/germline_variant_calling.nf
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,21 @@
// GERMLINE VARIANT CALLING
//

include { RUN_CNVKIT_GERMLINE } from '../nf-core/variantcalling/cnvkit/germline/main.nf'
include { RUN_DEEPVARIANT } from '../nf-core/variantcalling/deepvariant/main.nf'
include { RUN_FREEBAYES } from '../nf-core/variantcalling/freebayes/main.nf'
include { RUN_HAPLOTYPECALLER } from '../nf-core/variantcalling/haplotypecaller/main.nf'
include { RUN_MANTA_GERMLINE } from '../nf-core/variantcalling/manta/germline/main.nf'
include { RUN_STRELKA_SINGLE } from '../nf-core/variantcalling/strelka/single/main.nf'
include { RUN_CNVKIT_GERMLINE } from '../nf-core/variantcalling/cnvkit/germline/main.nf'
//include { TIDDIT } from './variantcalling/tiddit.nf'
include { RUN_TIDDIT } from '../nf-core/variantcalling/tiddit/main.nf'

workflow GERMLINE_VARIANT_CALLING {
take:
tools // Mandatory, list of tools to apply
cram_recalibrated // channel: [mandatory] cram
dbsnp
dbsnp_tbi // channel: []
bwa // channel: [mandatory] bwa
dbsnp // channel: [mandatory] dbsnp
dbsnp_tbi // channel: [mandatory] dbsnp_tbi
known_sites
known_sites_tbi
dict // channel: [mandatory] dict
Expand All @@ -28,15 +29,16 @@ workflow GERMLINE_VARIANT_CALLING {

main:

ch_versions = Channel.empty()
ch_versions = Channel.empty()

//TODO: Temporary until the if's can be removed and printing to terminal is prevented with "when" in the modules.config
deepvariant_vcf = Channel.empty()
freebayes_vcf = Channel.empty()
haplotypecaller_vcf = Channel.empty()
genotype_gvcf = Channel.empty()
manta_vcf = Channel.empty()
strelka_vcf = Channel.empty()
deepvariant_vcf = Channel.empty()
freebayes_vcf = Channel.empty()
genotype_gvcf = Channel.empty()
haplotypecaller_vcf = Channel.empty()
manta_vcf = Channel.empty()
strelka_vcf = Channel.empty()
tiddit_vcf = Channel.empty()

// Remap channel with intervals
cram_recalibrated_intervals = cram_recalibrated.combine(intervals)
Expand Down Expand Up @@ -137,15 +139,23 @@ workflow GERMLINE_VARIANT_CALLING {
}

//TIDDIT
//TODO
if (tools.contains('tiddit')){
RUN_TIDDIT(cram_recalibrated,
fasta,
bwa)

tiddit_vcf = RUN_TIDDIT.out.tiddit_vcf
ch_versions = ch_versions.mix(RUN_TIDDIT.out.versions)
}

emit:
deepvariant_vcf
freebayes_vcf
haplotypecaller_vcf
genotype_gvcf
haplotypecaller_vcf
manta_vcf
strelka_vcf
tiddit_vcf

versions = ch_versions
}
44 changes: 21 additions & 23 deletions subworkflows/nf-core/variantcalling/tiddit/main.nf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions tests/test_tools.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,17 @@
- path: results/variant_calling/sample1/cnvkit/test.paired_end.recalibrated.sorted.cns
- path: results/variant_calling/sample1/cnvkit/test.paired_end.recalibrated.sorted.call.cns

- name: Run variant calling on germline sample with tiddit
command: nextflow run main.nf -profile test,tools_germline,docker --tools tiddit -c ./tests/nextflow.config
tags:
- tiddit
- germline
- variant_calling
files:
- path: results/variant_calling/sample1/tiddit/sample1.ploidies.tab
- path: results/variant_calling/sample1/tiddit/sample1.vcf.gz
- path: results/variant_calling/sample1/tiddit/sample1.vcf.gz.tbi

- name: Run variant calling on somatic samples with controlfreec
command: nextflow run main.nf -profile test,tools_somatic,docker --tools controlfreec -c ./tests/nextflow.config
tags:
Expand Down
2 changes: 2 additions & 0 deletions workflows/sarek.nf
Original file line number Diff line number Diff line change
Expand Up @@ -759,6 +759,7 @@ workflow SAREK {
GERMLINE_VARIANT_CALLING(
params.tools,
cram_variant_calling_status_normal,
[],
dbsnp,
dbsnp_tbi,
known_sites,
Expand Down Expand Up @@ -817,6 +818,7 @@ workflow SAREK {
vcf_to_annotate = vcf_to_annotate.mix(GERMLINE_VARIANT_CALLING.out.freebayes_vcf)
vcf_to_annotate = vcf_to_annotate.mix(GERMLINE_VARIANT_CALLING.out.haplotypecaller_vcf)
vcf_to_annotate = vcf_to_annotate.mix(GERMLINE_VARIANT_CALLING.out.manta_vcf)
vcf_to_annotate = vcf_to_annotate.mix(GERMLINE_VARIANT_CALLING.out.tiddit_vcf)
vcf_to_annotate = vcf_to_annotate.mix(GERMLINE_VARIANT_CALLING.out.strelka_vcf)
vcf_to_annotate = vcf_to_annotate.mix(TUMOR_ONLY_VARIANT_CALLING.out.freebayes_vcf)
vcf_to_annotate = vcf_to_annotate.mix(TUMOR_ONLY_VARIANT_CALLING.out.mutect2_vcf)
Expand Down