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

updated traceback subworkflow and associated modules with changes for… #149

Open
wants to merge 5 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all 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
1 change: 0 additions & 1 deletion modules/msk/genotypevariants/all/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ process GENOTYPEVARIANTS_ALL {
$bams_standard \\
$bam_liquid \\
$sample \\
-t $task.cpus \\
$args

cat <<-END_VERSIONS > versions.yml
Expand Down
122 changes: 66 additions & 56 deletions modules/msk/genotypevariants/all/meta.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
## yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
name: "genotypevariants_all"
description: write your description here
keywords:
Expand All @@ -11,67 +10,78 @@ tools:
description: "module supports genotyping and merging small variants (SNV and INDELS)."
documentation: "https://genotype-variants.readthedocs.io/en/latest/"
licence: ["MIT"]
identifier: ""

input:
# Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient_1' ]`
- bam_standard:
type: file
description: Full path to standard bam file.
pattern: "*.{bam}"
- bai_standard:
type: file
description: Requires the standard .bai file is present at same location as the bam file.
pattern: "*.{bai}"
- bam_duplex:
type: file
description: Full path to duplex bam file.
pattern: "*.{bam}"
- bai_duplex:
type: file
description: Requires the duplex .bai file is present at same location as the bam file.
pattern: "*.{bai}"
- bam_simplex:
type: file
description: Full path to simplex bam file.
pattern: "*.{bam}"
- bai_simplex:
type: file
description: Requires the simplex .bai file is present at same location as the bam file.
pattern: "*.{bai}"
- maf:
type: file
description: Full path to small variants input file in MAF format
pattern: "*.{maf}"
- fasta:
type: file
description: The reference fasta file
pattern: "*.fasta"
- fai:
type: file
description: Index of reference fasta file
pattern: "*.fasta.fai"

- - meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient_1' ]`
- bam_standard:
type: file
description: Full path to standard bam file.
pattern: "*.{bam}"
- bai_standard:
type: file
description:
Requires the standard .bai file is present at same location as
the bam file.
pattern: "*.{bai}"
- bam_duplex:
type: file
description: Full path to duplex bam file.
pattern: "*.{bam}"
- bai_duplex:
type: file
description:
Requires the duplex .bai file is present at same location as the
bam file.
pattern: "*.{bai}"
- bam_simplex:
type: file
description: Full path to simplex bam file.
pattern: "*.{bam}"
- bai_simplex:
type: file
description:
Requires the simplex .bai file is present at same location as the
bam file.
pattern: "*.{bai}"
- maf:
type: file
description: Full path to small variants input file in MAF format
pattern: "*.{maf}"
- - fasta:
type: file
description: The reference fasta file
pattern: "*.fasta"
- - fai:
type: file
description: Index of reference fasta file
pattern: "*.fasta.fai"
output:
#Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient_1' ]`
- maf:
type: file
description: Genotyped maf for each bam provided and a merged genotyped maf. The mafs will be labelled with patient identifier or sample identifier as the prefix, and end with the type of bam (duplex, simplex, or standard). The sample identifier is prioritized.
pattern: "*.{mafs}"
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient_1' ]`
- "*.maf":
type: file
description:
Genotyped maf for each bam provided and a merged genotyped maf.
The mafs will be labelled with patient identifier or sample identifier as
the prefix, and end with the type of bam (duplex, simplex, or standard). The
sample identifier is prioritized.
pattern: "*.{mafs}"
- versions:
type: file
description: File containing software versions
pattern: "versions.yml"

- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
authors:
- "@buehlere"
maintainers:
Expand Down
4 changes: 2 additions & 2 deletions modules/msk/pvmaf/concat/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process PVMAF_CONCAT {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'ghcr.io/msk-access/postprocessing_variant_calls:0.3.0':
'ghcr.io/msk-access/postprocessing_variant_calls:0.3.0' }"
'ghcr.io/msk-access/postprocessing_variant_calls:0.2.6':
'ghcr.io/msk-access/postprocessing_variant_calls:0.2.6' }"

input:
tuple val(meta), path(maf_files, stageAs: "*?-ORG-SIMPLEX-DUPLEX_genotyped.maf")// [ id:'sample1', patient:'patient1' ], [maf_1, ... maf_n]
Expand Down
49 changes: 24 additions & 25 deletions modules/msk/pvmaf/concat/meta.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
name: "pvmaf_concat"
description: a flexible command for concatenating maf files
Expand All @@ -12,36 +11,36 @@ tools:
homepage: "https://github.com/msk-access/postprocessing_variant_calls"
documentation: "https://cmo-ci.gitbook.io/postprocessing_variant_calls/"
licence: ["MIT"]
identifier: ""

input:
# Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- maf_files:
type: file
description: list of maf files to concatenate
pattern: "*.{maf}"

- - meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- maf_files:
type: file
description: list of maf files to concatenate
pattern: "*.{maf}"
output:
#Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`

- versions:
type: file
description: File containing software versions
pattern: "versions.yml"
- maf:
type: file
description: concatenated maf file
pattern: "*.{maf}"

- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- "*.maf":
type: file
description: concatenated maf file
pattern: "*.{maf}"
- versions:
- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
authors:
- "@buehlere"
maintainers:
Expand Down
16 changes: 12 additions & 4 deletions modules/msk/pvmaf/concat/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,11 @@
]
}
],
"timestamp": "2024-02-23T11:31:39.015292"
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.2"
},
"timestamp": "2024-10-01T12:18:30.061693329"
},
"chr22maf - msk": {
"content": [
Expand All @@ -39,7 +43,7 @@
"id": "chr22",
"patient": "test"
},
"test_combined.maf:md5,7b36c0fda7ebb28b27ddf51b7d2a09e8"
"test_combined.maf:md5,e1d7d2ecaf53ce75908ad49b25289f32"
]
],
"1": [
Expand All @@ -51,14 +55,18 @@
"id": "chr22",
"patient": "test"
},
"test_combined.maf:md5,7b36c0fda7ebb28b27ddf51b7d2a09e8"
"test_combined.maf:md5,e1d7d2ecaf53ce75908ad49b25289f32"
]
],
"versions": [
"versions.yml:md5,c61c16c135e1cc470c79e7a579c4c76c"
]
}
],
"timestamp": "2024-02-23T11:31:28.145005"
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.2"
},
"timestamp": "2024-10-01T12:18:20.94747798"
}
}
4 changes: 1 addition & 3 deletions modules/msk/pvmaf/tagtraceback/environment.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json
name: "pvmaf_tagtraceback"
channels:
- conda-forge
- bioconda
- defaults
dependencies:
- "YOUR-TOOL-HERE"
- "YOUR-TOOL=HERE"
9 changes: 5 additions & 4 deletions modules/msk/pvmaf/tagtraceback/main.nf
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
process PVMAF_TAGTRACEBACK {
tag "$meta.id"
label 'process_single'

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'ghcr.io/msk-access/postprocessing_variant_calls:type_traceback_0.0.7':
'ghcr.io/msk-access/postprocessing_variant_calls:type_traceback_0.0.7' }"
'ghcr.io/msk-access/postprocessing_variant_calls:0.2.6':
'ghcr.io/msk-access/postprocessing_variant_calls:0.2.6' }"

input:
tuple val(meta), path(maf) // [ id:'sample1', patient:'patient1' ], *.maf
path(sample_sheets) // [samplesheet_1, ..., samplesheet_n]
tuple val(meta), path(maf)
path(sample_sheets)

output:
tuple val(meta), path("*.maf"), emit: maf
Expand Down
59 changes: 27 additions & 32 deletions modules/msk/pvmaf/tagtraceback/meta.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/meta-schema.json
name: "pvmaf_tagtraceback"
description: a flexible command for tagging maf files
Expand All @@ -12,43 +11,39 @@ tools:
homepage: "https://github.com/msk-access/postprocessing_variant_calls"
documentation: "https://cmo-ci.gitbook.io/postprocessing_variant_calls/"
licence: ["MIT"]
identifier: ""

input:
# Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`

- maf:
type: file
description: Maf file with columns required for selected tagging type.
pattern: "*.{maf}"

- path(sample_sheets):
type: file
description: |
Samplesheet with `sample_id` and `type` columns.
Used to add fillout type information to provided maf.
See Nucleovar for more info: https://github.com/mskcc-omics-workflows/nucleovar/blob/main/README.md.

- - meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- maf:
type: file
description: Maf file with columns required for selected tagging type.
pattern: "*.{maf}"
- - sample_sheets:
type: list
description: array holding the two samplesheets mandatory for running nucleovar, (pipeline_input and aux_bams)
output:
#Only when we have meta
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- versions:
type: file
description: File containing software versions
pattern: "versions.yml"
- maf:
type: file
description: tagged traceback maf.
pattern: "*.{maf}"

- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', patient:'patient1' ]`
- "*.maf":
type: file
description: tagged maf file.
pattern: "*.{maf}"
- versions:
- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
authors:
- "@buehlere"
maintainers:
Expand Down
2 changes: 1 addition & 1 deletion subworkflows/msk/traceback/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ workflow TRACEBACK {
.map {it -> [it[0].subMap('patient')[0], *it[1..-1]] }
.set{concat_maf}


bams
.map { it -> [it[0].subMap('patient')[0], it[0], *it[1..-1]] }
.combine(concat_maf, by:0)
.map { it[1..-1] }
.set{bam_list_maf}

// genotype each bam combined maf, per patient if provided
GENOTYPEVARIANTS_ALL(bam_list_maf, reference, reference_fai)
ch_versions = ch_versions.mix(GENOTYPEVARIANTS_ALL.out.versions.first())
Expand Down
Loading