Skip to content
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
4 changes: 2 additions & 2 deletions modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -123,12 +123,12 @@
},
"utils_nfcore_pipeline": {
"branch": "master",
"git_sha": "271e7fc14eb1320364416d996fb077421f3faed2",
"git_sha": "f0b535b3ae20080f8db03dd5388876ad1ec29d70",
"installed_by": ["subworkflows"]
},
"utils_nfschema_plugin": {
"branch": "master",
"git_sha": "4b406a74dc0449c0401ed87d5bfff4252fd277fd",
"git_sha": "fdc08b8b1ae74f56686ce21f7ea11ad11990ce57",
"installed_by": ["subworkflows"]
}
}
Expand Down
2 changes: 1 addition & 1 deletion modules/local/create_anndata_mudata/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ process CREATE_ANNDATA_MUDATA {
template 'create_anndata_mudata.py'

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_genetic.h5ad
touch ${prefix}_hashing.h5ad
Expand Down
2 changes: 1 addition & 1 deletion modules/local/extract_hashes/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ process EXTRACT_HASHES {
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"

"""
touch ${prefix}_hashes.txt
Expand Down
2 changes: 1 addition & 1 deletion modules/local/gene_summary/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ process GENE_SUMMARY {
template 'gene_summary.py'

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_genetic_summary_assignment.csv
touch ${prefix}_genetic_summary_classification.csv
Expand Down
2 changes: 1 addition & 1 deletion modules/local/hash_summary/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ process HASH_SUMMARY {
template 'hash_summary.py'

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_hashing_summary_assignment.csv
touch ${prefix}_hashing_summary_classification.csv
Expand Down
2 changes: 1 addition & 1 deletion modules/local/htodemux_visualization/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ process HTODEMUX_VISUALIZATION {
template 'htodemux_visualization.R'

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_ridge_htodemux.jpeg
touch ${prefix}_featureScatter_htodemux.jpeg
Expand Down
2 changes: 1 addition & 1 deletion modules/local/preprocessing_for_htodemux_multiseq/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ process PREPROCESSING_FOR_HTODEMUX_MULTISEQ {
template 'pre_processing.R'

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
prefix = task.ext.prefix ?: "${meta.id}"
"""
touch ${prefix}_preprocessed.rds
touch ${prefix}_params_preprocessing.csv
Expand Down
2 changes: 1 addition & 1 deletion modules/nf-core/demuxem/main.nf

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

2 changes: 1 addition & 1 deletion subworkflows/local/genetic_demultiplexing/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ workflow GENETIC_DEMULTIPLEXING {
.join(ch_demuxlet, remainder: true)
.join(ch_freemuxlet, remainder: true)
.join(ch_souporcell, remainder: true)
.map { tuple -> tuple.collect { it == null ? [] : it } }
.map { tuple -> tuple.collect { val -> val == null ? [] : val } }

GENE_SUMMARY(ch_summary)

Expand Down
16 changes: 3 additions & 13 deletions subworkflows/local/hash_demultiplexing/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,6 @@ workflow HASH_DEMULTIPLEXING {
PREPROCESSING_FOR_HTODEMUX_MULTISEQ.out.seurat_object.map { meta, seurat_object -> [meta, seurat_object, "HTO"] }
)

ch_assignments = HTODEMUX.out.assignment
.map { meta, assignment ->
[meta, [result: assignment, method: 'htodemux_assignment']]
}

ch_classifications = HTODEMUX.out.classification
.map { meta, classification ->
[meta, [result: classification, method: 'htodemux_classification']]
}

ch_htodemux_assignments = ch_htodemux_assignments.mix(HTODEMUX.out.assignment)
ch_htodemux_classifications = ch_htodemux_classifications.mix(HTODEMUX.out.classification)

Expand Down Expand Up @@ -112,7 +102,7 @@ workflow HASH_DEMULTIPLEXING {
meta,
hto,
params.gmmdemux_hto_names ? params.gmmdemux_hto_names : meta.hto_names,
params.gmmdemux_estimated_n_cells ? gmmdemux_estimated_n_cells : [],
params.gmmdemux_estimated_n_cells ? params.gmmdemux_estimated_n_cells : [],
]
}

Expand Down Expand Up @@ -159,7 +149,7 @@ workflow HASH_DEMULTIPLEXING {
ch_versions = ch_versions.mix(HASHSOLO.out.versions)
}

ch_summary = ch_samplesheet.map { meta, rna, hto -> [meta,hto] }
ch_summary = ch_samplesheet.map { meta, _rna, hto -> [meta,hto] }
.join(ch_htodemux_assignments, remainder: true)
.join(ch_htodemux_classifications, remainder: true)
.join(ch_multiseq, remainder: true)
Expand All @@ -170,7 +160,7 @@ workflow HASH_DEMULTIPLEXING {
.join(ch_hasheddrops_results, remainder: true)
.join(ch_hasheddrops_id_to_hash, remainder: true)
.join(ch_hashsolo, remainder: true)
.map { tuple -> tuple.collect { it == null ? [] : it } }
.map { tuple -> tuple.collect { val -> val == null ? [] : val } }
// Empty inputs solved as recommended here:
// https://nf-co.re/docs/guidelines/components/modules#optional-inputs

Expand Down
12 changes: 4 additions & 8 deletions subworkflows/local/utils_nfcore_hadge_pipeline/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ include { samplesheetToList } from 'plugin/nf-schema'
include { paramsHelp } from 'plugin/nf-schema'
include { completionEmail } from '../../nf-core/utils_nfcore_pipeline'
include { completionSummary } from '../../nf-core/utils_nfcore_pipeline'
include { imNotification } from '../../nf-core/utils_nfcore_pipeline'
include { UTILS_NFCORE_PIPELINE } from '../../nf-core/utils_nfcore_pipeline'
include { UTILS_NEXTFLOW_PIPELINE } from '../../nf-core/utils_nextflow_pipeline'

Expand All @@ -28,10 +27,10 @@ workflow PIPELINE_INITIALISATION {
take:
version // boolean: Display version and exit
validate_params // boolean: Boolean whether to validate parameters against the schema at runtime
monochrome_logs // boolean: Do not use coloured log outputs
_monochrome_logs // boolean: Do not use coloured log outputs
nextflow_cli_args // array: List of positional nextflow CLI args
outdir // string: The output directory where the results will be saved
input // string: Path to input samplesheet
_input // string: Path to input samplesheet
help // boolean: Display help message and exit
help_full // boolean: Show the full help message
show_hidden // boolean: Show hidden parameters in the help message
Expand Down Expand Up @@ -148,9 +147,6 @@ workflow PIPELINE_COMPLETION {
}

completionSummary(monochrome_logs)
if (hook_url) {
imNotification(summary_params, hook_url)
}
}

workflow.onError {
Expand Down Expand Up @@ -214,8 +210,8 @@ def validateInputParameters() {
//

def validateHtoNames(Map meta){
if(meta.hto_names.split(",").any { it.contains('_') }){
def bad = meta.hto_names.split(",").findAll { it.contains('_') }.join(', ')
if(meta.hto_names.split(",").any { name -> name.contains('_') }){
def bad = meta.hto_names.split(",").findAll { name -> name.contains('_') }.join(', ')
throw new IllegalArgumentException(
"Running hadge with the methods htodemux or multiseq does not allow to use underscores ('_') in HTO names. Both tools require a SeuratObject as input, which will replace '_' with '-' leading to ambiguous or misleading assignment summaries. Please remove underscores ('_') from: ${bad}"
)
Expand Down
64 changes: 0 additions & 64 deletions subworkflows/nf-core/utils_nfcore_pipeline/main.nf

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

3 changes: 1 addition & 2 deletions subworkflows/nf-core/utils_nfschema_plugin/main.nf

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

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

4 changes: 2 additions & 2 deletions workflows/hadge.nf
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ workflow HADGE {
}

// create channels for deconvolution tools
ch_genetic = ch_preprocessed.map { meta, rna, _hto, bam, barcodes, vcf -> [meta, bam, barcodes, vcf] }
ch_genetic = ch_preprocessed.map { meta, _rna, _hto, bam, barcodes, vcf -> [meta, bam, barcodes, vcf] }
ch_hashing = ch_preprocessed.map { meta, rna, hto, _bam, _barcodes, _vcf -> [meta, rna, hto] }
ch_create_anndata_mudata = ch_preprocessed.map { meta, rna, hto, _bam, _barcodes, _vcf -> [meta, rna, hto] }

Expand Down Expand Up @@ -191,7 +191,7 @@ workflow HADGE {
CREATE_ANNDATA_MUDATA(
ch_create_anndata_mudata.map { tuple ->
// hto can be null in genetic mode
if (params.mode == 'genetic'){ tuple.collect { it == null ? [] : it } }
if (params.mode == 'genetic'){ tuple.collect { val -> val == null ? [] : val } }
else{ tuple }
}
)
Expand Down
Loading