diff --git a/CHANGELOG.md b/CHANGELOG.md index 76265949..5e962c64 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,7 +9,7 @@ Initial release of nf-core/spatialaxe, created with the [nf-core](https://nf-co. ### `Added` -- Added the entire **spoQC tool and subworkflow**: `subworkflows/local/spoqc/main.nf` plus 31 new local modules under `modules/local/spoQC/` (`ambient`, `analysis_category`, `analysis_cluster`, `analysis_overview`, `annotation`, `bubble`, `cell`, `cellcycle`, `combine_masks`, `doublet`, `finalreport`, `general`, `hqcr_celltype`, `hqcr_ident`, `hqpr_bounding_box`, `hqpr_celltype`, `hqpr_clustering`, `hqpr_metrices`, `hqpr_refinement`, `hqtr_ac`, `hqtr_bounding_box`, `hqtr_celltype`, `hqtr_clustering`, `hqtr_metrices`, `hqtr_qv`, `hqtr_refinement`, `marker`, `model`, `transcript`, `void`, `whole_slide`), each with its own `main.nf`, `meta.yml`, and nf-test suite (`tests/main.nf.test` + snapshot). +- Added the entire **spoQC tool and subworkflow**: `subworkflows/local/spoqc/main.nf` plus 30 new local modules under `modules/local/spoQC/` (`ambient`, `analysis_category`, `analysis_cluster`, `analysis_overview`, `annotation`, `cell`, `cellcycle`, `combine_masks`, `doublet`, `finalreport`, `general`, `hqcr_celltype`, `hqcr_ident`, `hqpr_bounding_box`, `hqpr_celltype`, `hqpr_clustering`, `hqpr_metrices`, `hqpr_refinement`, `hqtr_ac`, `hqtr_bounding_box`, `hqtr_celltype`, `hqtr_clustering`, `hqtr_metrices`, `hqtr_qv`, `hqtr_refinement`, `marker`, `model`, `transcript`, `void`, `whole_slide`), each with its own `main.nf`, `meta.yml`, and nf-test suite (`tests/main.nf.test` + snapshot). - Wired spoQC into `workflows/spatialaxe.nf`. - Added `bin/spatialdata_write.py` support for spoQC's SpatialData output. - New test configs: `conf/tests/test_spoqc.config` and `conf/tests/test_full_spoqc.config` diff --git a/conf/test.config b/conf/test.config index 1784c30f..68af4f06 100644 --- a/conf/test.config +++ b/conf/test.config @@ -30,5 +30,7 @@ params { // Input data input = "${projectDir}/assets/samplesheet.csv" - mode = 'coordinate' + //mode = 'coordinate' + mode = 'qc' + spoqc = true } diff --git a/docs/output.md b/docs/output.md index 20442cb2..db0e00ad 100644 --- a/docs/output.md +++ b/docs/output.md @@ -137,7 +137,6 @@ The pipeline is built using [Nextflow](https://www.nextflow.io/) and processes d - `unsupervised_cell_annotation.tsv` unsupervised cell-type annotation, generated only when no annotation file was supplied as input - `whole_slide_qc/` whole-slide QC overview report - `generalqc/` general-purpose QC report - - `bubbleqc/` bubble-artifact QC report - `doubletqc/` doublet-detection QC report - `voidqc/` void/empty-region QC report - `cellqc/` cell-level QC report @@ -170,16 +169,17 @@ The pipeline is built using [Nextflow](https://www.nextflow.io/) and processes d - `staining_log.txt` log of the stainings processed by spoQC - `report.html` final self-contained HTML report aggregating every spoQC step above - `spoQC_tmp/` intermediate data consumed by later spoQC steps - - `generalqc_output_hqcr.parquet`, `bubbleqc_output_hqcr.parquet`, `doubletqc_output_hqcr.parquet`, `voidqc_output_hqcr.parquet`, `cellqc_output_hqcr.parquet` per-step HQCR contribution scores + - `generalqc_output_hqcr.parquet`, `doubletqc_output_hqcr.parquet`, `voidqc_output_hqcr.parquet`, `cellqc_output_hqcr.parquet` per-step HQCR contribution scores - `ambient_output_genes.parquet` ambient RNA gene-signal estimate - - `hqcr_output_mask_raw.parquet` / `hqcr_output_mask_smoothed_raw.parquet` combined raw/smoothed HQCR mask - - `hqcr_output_mask_smoothed_celltype_refined.parquet` cell-type-refined smoothed HQCR mask + - `mask_raw_output_hqcr.parquet` / `mask_smoothed_raw_output_hqcr.parquet` combined raw/smoothed HQCR mask + - `traffic_light_output_hqcr.parquet` HQCR traffic-light classification + - `mask_smoothed_celltype_refined_output_hqcr.parquet` cell-type-refined smoothed HQCR mask - `metrices/hqpr/${staining}/` per-staining HQPR metrics - - `hqpr_${staining}_output_mask_raw/` / `hqpr_${staining}_output_mask_smoothed_raw/` per-staining raw/smoothed HQPR mask + - `mask_raw_output_hqpr_${staining}/` / `mask_smoothed_raw_output_hqpr_${staining}/` per-staining raw/smoothed HQPR mask - `metrices/hqtr/` HQTR metrics - - `hqtr_output_ac_prob/` HQTR ambient-contamination probabilities - - `hqtr_output_qv_prob/` HQTR quality-value probabilities - - `hqtr_output_mask_raw/` / `hqtr_output_mask_smoothed_raw/` raw/smoothed HQTR mask + - `ac_density_output_hqtr/` HQTR ambient-contamination probabilities + - `qv_density_output_hqtr/` HQTR quality-value probabilities + - `mask_raw_output_hqtr/` / `mask_smoothed_raw_output_hqtr/` raw/smoothed HQTR mask - `multiqc/` - `multiqc_report.html`: a standalone HTML file that can be viewed in your web browser. - `multiqc_data/`: directory containing parsed statistics from the different tools used in the pipeline. diff --git a/modules/local/spoQC/ambient/main.nf b/modules/local/spoQC/ambient/main.nf index 7531cbd8..7d6039d4 100644 --- a/modules/local/spoQC/ambient/main.nf +++ b/modules/local/spoQC/ambient/main.nf @@ -6,7 +6,7 @@ process SPOQC_AMBIENT { label 'process_mid_time' label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/analysis_category/main.nf b/modules/local/spoQC/analysis_category/main.nf index c0893143..55fdd4dc 100644 --- a/modules/local/spoQC/analysis_category/main.nf +++ b/modules/local/spoQC/analysis_category/main.nf @@ -6,25 +6,23 @@ process SPOQC_ANALYSIS_CATEGORY { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") path(annotation, stageAs: "*") val(step) path(tmp_general, stageAs: "spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "spoQC_tmp/cellqc_output_hqcr.parquet") - path(mask_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_raw.parquet") - path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet") - path(traffic_light_hqcr, stageAs: "spoQC_tmp/traffic_light_output_hqcr.parquet") - path(qv, stageAs: "spoQC_tmp/hqtr_output_qv_prob") - path(ac, stageAs: "spoQC_tmp/hqtr_output_ac_prob") + path(mask_hqcr, stageAs: "spoQC_tmp/mask_raw_output_hqcr.parquet") + path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet") + path(qv, stageAs: "spoQC_tmp/qv_density_output_hqtr") + path(ac, stageAs: "spoQC_tmp/ac_density_output_hqtr") path(metrices_hqtr, stageAs: "spoQC_tmp/metrices/hqtr") - path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_smoothed_raw") - path(mask_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_raw") + path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqtr") + path(mask_hqtr, stageAs: "spoQC_tmp/mask_raw_output_hqtr") path(metrices_hqpr, stageAs: "spoQC_tmp/metrices/hqpr/*") path(mask_smoothed_hqpr, stageAs: "spoQC_tmp/*") path(mask_hqpr, stageAs: "spoQC_tmp/*") diff --git a/modules/local/spoQC/analysis_category/meta.yml b/modules/local/spoQC/analysis_category/meta.yml index 0e08773a..36523e0b 100644 --- a/modules/local/spoQC/analysis_category/meta.yml +++ b/modules/local/spoQC/analysis_category/meta.yml @@ -38,11 +38,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -61,12 +56,12 @@ input: - mask_hqcr: type: file description: HQCR raw mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_raw.parquet" + pattern: "mask_raw_output_hqcr.parquet" ontologies: [] - mask_smoothed_hqcr: type: file description: Smoothed HQCR mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_smoothed_raw.parquet" + pattern: "mask_smoothed_raw_output_hqcr.parquet" ontologies: [] - traffic_light_hqcr: type: file @@ -76,12 +71,12 @@ input: - qv: type: directory description: HQTR quality-value probability output from SPOQC_HQTR_QV - pattern: "hqtr_output_qv_prob" + pattern: "qv_density_output_hqtr" ontologies: [] - ac: type: directory description: HQTR ambient-contamination probability output from SPOQC_HQTR_AC - pattern: "hqtr_output_ac_prob" + pattern: "ac_density_output_hqtr" ontologies: [] - metrices_hqtr: type: directory @@ -91,12 +86,12 @@ input: - mask_smoothed_hqtr: type: directory description: Smoothed HQTR mask from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] - mask_hqtr: type: directory description: HQTR raw mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] - metrices_hqpr: type: directory diff --git a/modules/local/spoQC/analysis_category/tests/main.nf.test b/modules/local/spoQC/analysis_category/tests/main.nf.test index 254d74fe..d64a291d 100644 --- a/modules/local/spoQC/analysis_category/tests/main.nf.test +++ b/modules/local/spoQC/analysis_category/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -104,10 +94,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -219,21 +208,19 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_category" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[10] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[12] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[13] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[14] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[15] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } @@ -258,21 +245,19 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_category" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[10] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[12] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[13] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[14] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[15] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } diff --git a/modules/local/spoQC/analysis_cluster/main.nf b/modules/local/spoQC/analysis_cluster/main.nf index 4a89aacc..1afa0f33 100644 --- a/modules/local/spoQC/analysis_cluster/main.nf +++ b/modules/local/spoQC/analysis_cluster/main.nf @@ -6,25 +6,24 @@ process SPOQC_ANALYSIS_CLUSTER { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") path(annotation, stageAs: "*") val(step) path(tmp_general, stageAs: "spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "spoQC_tmp/cellqc_output_hqcr.parquet") - path(mask_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_raw.parquet") - path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet") + path(mask_hqcr, stageAs: "spoQC_tmp/mask_raw_output_hqcr.parquet") + path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet") path(traffic_light_hqcr, stageAs: "spoQC_tmp/traffic_light_output_hqcr.parquet") - path(qv, stageAs: "spoQC_tmp/hqtr_output_qv_prob") - path(ac, stageAs: "spoQC_tmp/hqtr_output_ac_prob") + path(qv, stageAs: "spoQC_tmp/qv_density_output_hqtr") + path(ac, stageAs: "spoQC_tmp/ac_density_output_hqtr") path(metrices_hqtr, stageAs: "spoQC_tmp/metrices/hqtr") - path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_smoothed_raw") - path(mask_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_raw") + path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqtr") + path(mask_hqtr, stageAs: "spoQC_tmp/mask_raw_output_hqtr") path(metrices_hqpr, stageAs: "spoQC_tmp/metrices/hqpr/*") path(mask_smoothed_hqpr, stageAs: "spoQC_tmp/*") path(mask_hqpr, stageAs: "spoQC_tmp/*") diff --git a/modules/local/spoQC/analysis_cluster/meta.yml b/modules/local/spoQC/analysis_cluster/meta.yml index d424311c..763ccd0a 100644 --- a/modules/local/spoQC/analysis_cluster/meta.yml +++ b/modules/local/spoQC/analysis_cluster/meta.yml @@ -40,11 +40,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -63,12 +58,17 @@ input: - mask_hqcr: type: file description: HQCR raw mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_raw.parquet" + pattern: "mask_raw_output_hqcr.parquet" ontologies: [] - mask_smoothed_hqcr: type: file description: Smoothed HQCR mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_smoothed_raw.parquet" + pattern: "mask_smoothed_raw_output_hqcr.parquet" + ontologies: [] + - traffic_light_hqcr: + type: file + description: HQCR traffic-light classification from SPOQC_HQCR_IDENT + pattern: "traffic_light_output_hqcr.parquet" ontologies: [] - traffic_light_hqcr: type: file @@ -78,12 +78,12 @@ input: - qv: type: directory description: HQTR quality-value probability output from SPOQC_HQTR_QV - pattern: "hqtr_output_qv_prob" + pattern: "qv_density_output_hqtr" ontologies: [] - ac: type: directory description: HQTR ambient-contamination probability output from SPOQC_HQTR_AC - pattern: "hqtr_output_ac_prob" + pattern: "ac_density_output_hqtr" ontologies: [] - metrices_hqtr: type: directory @@ -93,12 +93,12 @@ input: - mask_smoothed_hqtr: type: directory description: Smoothed HQTR mask from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] - mask_hqtr: type: directory description: HQTR raw mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] - metrices_hqpr: type: directory diff --git a/modules/local/spoQC/analysis_cluster/tests/main.nf.test b/modules/local/spoQC/analysis_cluster/tests/main.nf.test index 75a8547c..dc254d5b 100644 --- a/modules/local/spoQC/analysis_cluster/tests/main.nf.test +++ b/modules/local/spoQC/analysis_cluster/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -104,10 +94,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -219,21 +208,20 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_cluster" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } + input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } @@ -259,21 +247,20 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_cluster" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } + input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } diff --git a/modules/local/spoQC/analysis_overview/main.nf b/modules/local/spoQC/analysis_overview/main.nf index 84715135..bc97af37 100644 --- a/modules/local/spoQC/analysis_overview/main.nf +++ b/modules/local/spoQC/analysis_overview/main.nf @@ -6,25 +6,24 @@ process SPOQC_ANALYSIS_OVERVIEW { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") path(annotation, stageAs: "*") val(step) path(tmp_general, stageAs: "spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "spoQC_tmp/cellqc_output_hqcr.parquet") - path(mask_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_raw.parquet") - path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet") + path(mask_hqcr, stageAs: "spoQC_tmp/mask_raw_output_hqcr.parquet") + path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet") path(traffic_light_hqcr, stageAs: "spoQC_tmp/traffic_light_output_hqcr.parquet") - path(qv, stageAs: "spoQC_tmp/hqtr_output_qv_prob") - path(ac, stageAs: "spoQC_tmp/hqtr_output_ac_prob") + path(qv, stageAs: "spoQC_tmp/qv_density_output_hqtr") + path(ac, stageAs: "spoQC_tmp/ac_density_output_hqtr") path(metrices_hqtr, stageAs: "spoQC_tmp/metrices/hqtr") - path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_smoothed_raw") - path(mask_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_raw") + path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqtr") + path(mask_hqtr, stageAs: "spoQC_tmp/mask_raw_output_hqtr") path(metrices_hqpr, stageAs: "spoQC_tmp/metrices/hqpr/*") path(mask_smoothed_hqpr, stageAs: "spoQC_tmp/*") path(mask_hqpr, stageAs: "spoQC_tmp/*") diff --git a/modules/local/spoQC/analysis_overview/meta.yml b/modules/local/spoQC/analysis_overview/meta.yml index 27f5818a..f6bcb754 100644 --- a/modules/local/spoQC/analysis_overview/meta.yml +++ b/modules/local/spoQC/analysis_overview/meta.yml @@ -39,11 +39,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -62,12 +57,17 @@ input: - mask_hqcr: type: file description: HQCR raw mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_raw.parquet" + pattern: "mask_raw_output_hqcr.parquet" ontologies: [] - mask_smoothed_hqcr: type: file description: Smoothed HQCR mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_smoothed_raw.parquet" + pattern: "mask_smoothed_raw_output_hqcr.parquet" + ontologies: [] + - traffic_light_hqcr: + type: file + description: HQCR traffic-light classification from SPOQC_HQCR_IDENT + pattern: "traffic_light_output_hqcr.parquet" ontologies: [] - traffic_light_hqcr: type: file @@ -77,12 +77,12 @@ input: - qv: type: directory description: HQTR quality-value probability output from SPOQC_HQTR_QV - pattern: "hqtr_output_qv_prob" + pattern: "qv_density_output_hqtr" ontologies: [] - ac: type: directory description: HQTR ambient-contamination probability output from SPOQC_HQTR_AC - pattern: "hqtr_output_ac_prob" + pattern: "ac_density_output_hqtr" ontologies: [] - metrices_hqtr: type: directory @@ -92,12 +92,12 @@ input: - mask_smoothed_hqtr: type: directory description: Smoothed HQTR mask from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] - mask_hqtr: type: directory description: HQTR raw mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] - metrices_hqpr: type: directory diff --git a/modules/local/spoQC/analysis_overview/tests/main.nf.test b/modules/local/spoQC/analysis_overview/tests/main.nf.test index ac78a7cd..6e73c2ce 100644 --- a/modules/local/spoQC/analysis_overview/tests/main.nf.test +++ b/modules/local/spoQC/analysis_overview/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -104,10 +94,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -219,21 +208,20 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_overview" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } + input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } @@ -259,21 +247,20 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_overview" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } - input[11] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[13] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[14] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[15] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[16] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[18] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQCR_IDENT.out.traffic_light.map { it[1] } + input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } diff --git a/modules/local/spoQC/annotation/main.nf b/modules/local/spoQC/annotation/main.nf index 35ccc0f8..5a56aa33 100644 --- a/modules/local/spoQC/annotation/main.nf +++ b/modules/local/spoQC/annotation/main.nf @@ -7,7 +7,7 @@ process SPOQC_ANNOTATION { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/bubble/main.nf b/modules/local/spoQC/bubble/main.nf deleted file mode 100644 index b91258a4..00000000 --- a/modules/local/spoQC/bubble/main.nf +++ /dev/null @@ -1,54 +0,0 @@ - -process SPOQC_BUBBLE { - tag "$meta.id" - label 'process_tiny_cpus' - label 'process_tiny_mem' - label 'process_tiny_time' - label 'spoqc' - - - container "heylf/spoqc_dev:0.1.0" - - input: - tuple val(meta), path(spatialdata, stageAs: "*") - val(step) - - output: - tuple val(meta), path("./report/bubbleqc") , emit: report - tuple val(meta), path("./spoQC_tmp/bubbleqc_output_hqcr.parquet") , emit: tmp - tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc - - when: - task.ext.when == null || task.ext.when - - script: - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - error("SPOQC_BUBBLE module does not support Conda. Please use Docker / Singularity / Podman instead.") - } - - def args = task.ext.args ?: '' - - """ - python3 -m spoqc \\ - -i ${spatialdata} \\ - -o ./ \\ - -t ./spoQC_tmp/ \\ - -n ${task.cpus} \\ - -s ${step} \\ - --dataset ${meta.id} \\ - ${args} - """ - - stub: - // Exit if running this module with -profile conda / -profile mamba - if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { - error("SPOQC_BUBBLE module does not support Conda. Please use Docker / Singularity / Podman instead.") - } - - """ - mkdir -p ./report/bubbleqc - mkdir -p ./spoQC_tmp - touch ./spoQC_tmp/bubbleqc_output_hqcr.parquet - """ -} diff --git a/modules/local/spoQC/bubble/meta.yml b/modules/local/spoQC/bubble/meta.yml deleted file mode 100644 index 60017403..00000000 --- a/modules/local/spoQC/bubble/meta.yml +++ /dev/null @@ -1,77 +0,0 @@ -name: spoqc_bubble -description: | - Run bubble-artifact QC checks on a SpatialData object. -keywords: - - spatial transcriptomics - - quality control - - spoqc - - xenium - - bubble artifact -tools: - - "spoqc": - description: | - spoQC is a modular framework for multimodal quality control (QC) of imaging-based spatially resolved transcriptomics (SRT). - homepage: https://github.com/heylf/spoQC - documentation: https://github.com/heylf/spoQC - licence: ["MIT license"] -input: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'sample' ] - - spatialdata: - type: directory - description: Path to the SpatialData zarr store to run QC on - ontologies: [] - - step: - type: string - description: Name of the spoQC step to run, passed to `spoqc -s` -output: - report: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'sample' ] - - "report": - type: directory - description: HTML/plot QC report directory produced for this step - ontologies: [] - tmp: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'sample' ] - - "bubbleqc_output_hqcr.parquet": - type: file - description: | - Per-cell bubble-artifact QC parquet output, consumed by the HQCR identification/cell-type and downstream analysis steps. - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - versions_spoqc: - - - "${task.process}": - type: string - description: The process the versions were collected from - - spoqc: - type: string - description: The tool name - - "spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown": - type: eval - description: The expression to obtain the version of the tool -topics: - versions: - - - "${task.process}": - type: string - description: The process the versions were collected from - - spoqc: - type: string - description: The tool name - - "spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown": - type: eval - description: The expression to obtain the version of the tool -authors: - - "@heylf" -maintainers: - - "@heylf" diff --git a/modules/local/spoQC/bubble/tests/main.nf.test b/modules/local/spoQC/bubble/tests/main.nf.test deleted file mode 100644 index 02412adf..00000000 --- a/modules/local/spoQC/bubble/tests/main.nf.test +++ /dev/null @@ -1,82 +0,0 @@ -nextflow_process { - - name "Test Process SPOQC_BUBBLE" - script "../main.nf" - process "SPOQC_BUBBLE" - config "./nextflow.config" - - tag "modules" - tag "modules_local" - tag "spoqc" - tag "spoqc/bubble" - - setup { - run("UNTAR") { - script "modules/nf-core/untar/main.nf" - process { - """ - input[0] = [[], file('https://raw.githubusercontent.com/nf-core/test-datasets/spatialaxe/xenium_bundle.tar.gz', checkIfExists: true)] - """ - } - } - - run("SPATIALDATA_WRITE") { - script "modules/local/spatialdata/write/main.nf" - process { - """ - input[0] = channel.of([ - [id: "test_run_spoqc"], - ]).combine(UNTAR.out.untar.map { it[1] }) - input[1] = "spatialdata_raw" - input[2] = [] - input[3] = "all" - """ - } - } - } - - test("spoqc bubble") { - - when { - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - - then { - assertAll( - { assert process.success }, - { assert file(process.out.report[0][1]).isDirectory() }, - { assert file(process.out.tmp[0][1]).exists() }, - { assert snapshot(process.out.versions_spoqc).match() } - ) - } - } - - test("spoqc bubble stub") { - - options "-stub" - - when { - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - - then { - assertAll( - { assert process.success }, - { assert file(process.out.report[0][1]).isDirectory() }, - { assert file(process.out.tmp[0][1]).exists() }, - { assert snapshot(process.out.versions_spoqc).match() } - ) - } - } - -} diff --git a/modules/local/spoQC/bubble/tests/main.nf.test.snap b/modules/local/spoQC/bubble/tests/main.nf.test.snap deleted file mode 100644 index 51d07ce7..00000000 --- a/modules/local/spoQC/bubble/tests/main.nf.test.snap +++ /dev/null @@ -1,34 +0,0 @@ -{ - "spoqc bubble": { - "content": [ - [ - [ - "SPOQC_BUBBLE", - "spoqc", - "0.1.0" - ] - ] - ], - "timestamp": "2026-08-12T16:24:03.176288069", - "meta": { - "nf-test": "0.9.5", - "nextflow": "26.04.6" - } - }, - "spoqc bubble stub": { - "content": [ - [ - [ - "SPOQC_BUBBLE", - "spoqc", - "0.1.0" - ] - ] - ], - "timestamp": "2026-08-12T16:24:27.473999654", - "meta": { - "nf-test": "0.9.5", - "nextflow": "26.04.6" - } - } -} \ No newline at end of file diff --git a/modules/local/spoQC/bubble/tests/nextflow.config b/modules/local/spoQC/bubble/tests/nextflow.config deleted file mode 100644 index f8b3a30a..00000000 --- a/modules/local/spoQC/bubble/tests/nextflow.config +++ /dev/null @@ -1,9 +0,0 @@ -process { - - resourceLimits = [ - cpus: 4, - memory: '8.GB', - time: '2.h', - ] - -} diff --git a/modules/local/spoQC/cell/main.nf b/modules/local/spoQC/cell/main.nf index 827bdb19..f8d17088 100644 --- a/modules/local/spoQC/cell/main.nf +++ b/modules/local/spoQC/cell/main.nf @@ -7,7 +7,7 @@ process SPOQC_CELL { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/cellcycle/main.nf b/modules/local/spoQC/cellcycle/main.nf index 19544b98..2002adf4 100644 --- a/modules/local/spoQC/cellcycle/main.nf +++ b/modules/local/spoQC/cellcycle/main.nf @@ -7,7 +7,7 @@ process SPOQC_CELLCYCLE { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/combine_masks/main.nf b/modules/local/spoQC/combine_masks/main.nf index 76f247fb..d2b22e78 100644 --- a/modules/local/spoQC/combine_masks/main.nf +++ b/modules/local/spoQC/combine_masks/main.nf @@ -6,17 +6,17 @@ process SPOQC_COMBINE_MASKS { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(_stain_sd) val(step) - tuple path(mask_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_raw.parquet"), val(_stain_hqcr) + tuple path(mask_hqcr, stageAs: "spoQC_tmp/mask_raw_output_hqcr.parquet"), val(_stain_hqcr) tuple val(staining), path(mask_hqpr, stageAs: "spoQC_tmp/*") - tuple path(mask_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_raw"), val(_stain_hqtr) - tuple path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet"), val(_stain_smoothed_hqcr) + tuple path(mask_hqtr, stageAs: "spoQC_tmp/mask_raw_output_hqtr"), val(_stain_hqtr) + tuple path(mask_smoothed_hqcr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet"), val(_stain_smoothed_hqcr) tuple val(_s), path(mask_smoothed_hqpr, stageAs: "spoQC_tmp/*") - tuple path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/hqtr_output_mask_smoothed_raw"), val(_stain_smoothed_hqtr) + tuple path(mask_smoothed_hqtr, stageAs: "spoQC_tmp/mask_smoothed_raw_output_hqtr"), val(_stain_smoothed_hqtr) output: tuple val(meta), path("report/combine_masks/${staining}") , emit: report diff --git a/modules/local/spoQC/combine_masks/meta.yml b/modules/local/spoQC/combine_masks/meta.yml index 4c4eab4b..0079bd21 100644 --- a/modules/local/spoQC/combine_masks/meta.yml +++ b/modules/local/spoQC/combine_masks/meta.yml @@ -33,7 +33,7 @@ input: - - mask_hqcr: type: file description: HQCR raw mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_raw.parquet" + pattern: "mask_raw_output_hqcr.parquet" ontologies: [] - staining_idx_hqcr: type: integer @@ -49,7 +49,7 @@ input: - - mask_hqtr: type: directory description: HQTR raw mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] - staining_idx_hqtr: type: integer @@ -57,7 +57,7 @@ input: - - mask_smoothed_hqcr: type: file description: Smoothed HQCR mask from SPOQC_HQCR_IDENT - pattern: "hqcr_output_mask_smoothed_raw.parquet" + pattern: "mask_smoothed_raw_output_hqcr.parquet" ontologies: [] - staining_idx_smoothed_hqcr: type: integer @@ -73,7 +73,7 @@ input: - - mask_smoothed_hqtr: type: directory description: Smoothed HQTR mask from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] - staining_idx_smoothed_hqtr: type: integer diff --git a/modules/local/spoQC/combine_masks/tests/main.nf.test b/modules/local/spoQC/combine_masks/tests/main.nf.test index bdbfb335..b0ebca71 100644 --- a/modules/local/spoQC/combine_masks/tests/main.nf.test +++ b/modules/local/spoQC/combine_masks/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -104,10 +94,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } diff --git a/modules/local/spoQC/doublet/main.nf b/modules/local/spoQC/doublet/main.nf index 8452bb77..db532ec9 100644 --- a/modules/local/spoQC/doublet/main.nf +++ b/modules/local/spoQC/doublet/main.nf @@ -7,7 +7,7 @@ process SPOQC_DOUBLET { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/finalreport/main.nf b/modules/local/spoQC/finalreport/main.nf index 36f8309d..b4a46646 100644 --- a/modules/local/spoQC/finalreport/main.nf +++ b/modules/local/spoQC/finalreport/main.nf @@ -6,7 +6,7 @@ process SPOQC_FINALREPORT { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/finalreport/tests/main.nf.test b/modules/local/spoQC/finalreport/tests/main.nf.test index 75f20af4..4fb0b7be 100644 --- a/modules/local/spoQC/finalreport/tests/main.nf.test +++ b/modules/local/spoQC/finalreport/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -104,10 +94,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -120,10 +109,9 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqcr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -200,6 +188,7 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqtr_bounding_box" input[2] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[3] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } """ } } @@ -212,12 +201,11 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqtr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[9] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[8] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } """ } } @@ -273,11 +261,10 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { _meta, f -> [f, 0] } input[2] = "hqpr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { _meta, f -> [f, 0] } - input[4] = SPOQC_BUBBLE.out.tmp.map { _meta, f -> [f, 0] } - input[5] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } - input[6] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } - input[7] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } - input[8] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } + input[4] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } + input[5] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } + input[6] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } + input[7] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } .join(SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, staining, m -> [staining, m] }) """ } @@ -338,20 +325,19 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_overview" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[10] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[12] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[13] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[14] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[15] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } @@ -364,20 +350,19 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_category" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[10] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[12] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[13] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[14] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[15] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } @@ -390,20 +375,19 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "analysis_cluster" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } - input[9] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } - input[10] = SPOQC_HQTR_QV.out.tmp.map { it[1] } - input[11] = SPOQC_HQTR_AC.out.tmp.map { it[1] } - input[12] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } - input[13] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } - input[14] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[15] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() - input[16] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() - input[17] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQCR_IDENT.out.mask.map { it[1] } + input[8] = SPOQC_HQCR_IDENT.out.mask_smoothed.map { it[1] } + input[9] = SPOQC_HQTR_QV.out.tmp.map { it[1] } + input[10] = SPOQC_HQTR_AC.out.tmp.map { it[1] } + input[11] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } + input[12] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[13] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[14] = SPOQC_HQPR_METRICES.out.metrices.map { _meta, _staining, p -> p }.collect() + input[15] = SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, _staining, p -> p }.collect() + input[16] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, _staining, p -> p }.collect() """ } } diff --git a/modules/local/spoQC/general/main.nf b/modules/local/spoQC/general/main.nf index 3fc8cb31..bc179225 100644 --- a/modules/local/spoQC/general/main.nf +++ b/modules/local/spoQC/general/main.nf @@ -7,7 +7,7 @@ process SPOQC_GENERAL { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/hqcr_celltype/main.nf b/modules/local/spoQC/hqcr_celltype/main.nf index 849c52a5..09ee37ef 100644 --- a/modules/local/spoQC/hqcr_celltype/main.nf +++ b/modules/local/spoQC/hqcr_celltype/main.nf @@ -7,21 +7,20 @@ process SPOQC_HQCR_CELLTYPE { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") path(annotation, stageAs: "*") val(step) path(tmp_general, stageAs: "./spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "./spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "./spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "./spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "./spoQC_tmp/cellqc_output_hqcr.parquet") output: tuple val(meta), path("./report/hqcr/hqcr_celltype") , emit: report - tuple val(meta), path("./spoQC_tmp/hqcr_output_mask_smoothed_celltype_refined.parquet") , emit: mask + tuple val(meta), path("./spoQC_tmp/mask_smoothed_celltype_refined_output_hqcr.parquet") , emit: mask tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -57,7 +56,7 @@ process SPOQC_HQCR_CELLTYPE { """ mkdir -p ./report/hqcr/hqcr_celltype mkdir -p ./spoQC_tmp - touch ./spoQC_tmp/hqcr_output_mask_smoothed_celltype_refined.parquet + touch ./spoQC_tmp/mask_smoothed_celltype_refined_output_hqcr.parquet """ } diff --git a/modules/local/spoQC/hqcr_celltype/meta.yml b/modules/local/spoQC/hqcr_celltype/meta.yml index 56ea2c68..f4525903 100644 --- a/modules/local/spoQC/hqcr_celltype/meta.yml +++ b/modules/local/spoQC/hqcr_celltype/meta.yml @@ -1,6 +1,6 @@ name: spoqc_hqcr_celltype description: | - Refine the high-quality cell region (HQCR) mask using cell-type information, combining the general/bubble/doublet/void/cell QC outputs. + Refine the high-quality cell region (HQCR) mask using cell-type information, combining the general/doublet/void/cell QC outputs. keywords: - spatial transcriptomics - quality control @@ -39,11 +39,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -79,7 +74,7 @@ output: - "mask": type: file description: Cell-type-refined, smoothed HQCR mask - pattern: "hqcr_output_mask_smoothed_celltype_refined.parquet" + pattern: "mask_smoothed_celltype_refined_output_hqcr.parquet" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqcr_celltype/tests/main.nf.test b/modules/local/spoQC/hqcr_celltype/tests/main.nf.test index 9c3b81f3..9de87174 100644 --- a/modules/local/spoQC/hqcr_celltype/tests/main.nf.test +++ b/modules/local/spoQC/hqcr_celltype/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -107,10 +97,9 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqcr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -136,10 +125,9 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqcr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } """ } } diff --git a/modules/local/spoQC/hqcr_ident/main.nf b/modules/local/spoQC/hqcr_ident/main.nf index 82c12237..c3fc9db2 100644 --- a/modules/local/spoQC/hqcr_ident/main.nf +++ b/modules/local/spoQC/hqcr_ident/main.nf @@ -7,13 +7,12 @@ process SPOQC_HQCR_IDENT { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") val(step) path(tmp_general, stageAs: "./spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "./spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "./spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "./spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "./spoQC_tmp/cellqc_output_hqcr.parquet") @@ -22,8 +21,8 @@ process SPOQC_HQCR_IDENT { output: tuple val(meta), path("./report/hqcr/hqcr_ident") , emit: report - tuple val(meta), path("./spoQC_tmp/hqcr_output_mask_raw.parquet") , emit: mask - tuple val(meta), path("./spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet") , emit: mask_smoothed + tuple val(meta), path("./spoQC_tmp/mask_raw_output_hqcr.parquet") , emit: mask + tuple val(meta), path("./spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet") , emit: mask_smoothed tuple val(meta), path("./spoQC_tmp/traffic_light_output_hqcr.parquet") , emit: traffic_light tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc @@ -61,8 +60,8 @@ process SPOQC_HQCR_IDENT { """ mkdir -p ./report/hqcr/hqcr_ident mkdir -p ./spoQC_tmp - touch ./spoQC_tmp/hqcr_output_mask_raw.parquet - touch ./spoQC_tmp/hqcr_output_mask_smoothed_raw.parquet + touch ./spoQC_tmp/mask_raw_output_hqcr.parquet + touch ./spoQC_tmp/mask_smoothed_raw_output_hqcr.parquet touch ./spoQC_tmp/traffic_light_output_hqcr.parquet """ } diff --git a/modules/local/spoQC/hqcr_ident/meta.yml b/modules/local/spoQC/hqcr_ident/meta.yml index 9e9f3106..aaaefaa5 100644 --- a/modules/local/spoQC/hqcr_ident/meta.yml +++ b/modules/local/spoQC/hqcr_ident/meta.yml @@ -1,6 +1,6 @@ name: spoqc_hqcr_ident description: | - Identify high-quality cell regions (HQCR) by combining the general/bubble/doublet/void/cell QC outputs into a smoothed mask. + Identify high-quality cell regions (HQCR) by combining the general/doublet/void/cell QC outputs into a smoothed mask. keywords: - spatial transcriptomics - quality control @@ -33,11 +33,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -73,7 +68,7 @@ output: - "mask": type: file description: Raw HQCR mask - pattern: "hqcr_output_mask_raw.parquet" + pattern: "mask_raw_output_hqcr.parquet" ontologies: [] mask_smoothed: - - meta: @@ -84,7 +79,18 @@ output: - "mask_smoothed": type: file description: Smoothed HQCR mask - pattern: "hqcr_output_mask_smoothed_raw.parquet" + pattern: "mask_smoothed_raw_output_hqcr.parquet" + ontologies: [] + traffic_light: + - - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'sample' ] + - "traffic_light": + type: file + description: HQCR traffic-light classification + pattern: "traffic_light_output_hqcr.parquet" ontologies: [] traffic_light: - - meta: diff --git a/modules/local/spoQC/hqcr_ident/tests/main.nf.test b/modules/local/spoQC/hqcr_ident/tests/main.nf.test index dd748f9c..fce75843 100644 --- a/modules/local/spoQC/hqcr_ident/tests/main.nf.test +++ b/modules/local/spoQC/hqcr_ident/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -106,10 +96,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } @@ -136,10 +125,9 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqcr_ident" input[2] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[3] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[5] = SPOQC_VOID.out.tmp.map { it[1] } - input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[3] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[4] = SPOQC_VOID.out.tmp.map { it[1] } + input[5] = SPOQC_CELL.out.tmp.map { it[1] } """ } } diff --git a/modules/local/spoQC/hqpr_bounding_box/main.nf b/modules/local/spoQC/hqpr_bounding_box/main.nf index a6e1bd5e..292fcf25 100644 --- a/modules/local/spoQC/hqpr_bounding_box/main.nf +++ b/modules/local/spoQC/hqpr_bounding_box/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQPR_BOUNDING_BOX { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(_stain_sd) diff --git a/modules/local/spoQC/hqpr_celltype/main.nf b/modules/local/spoQC/hqpr_celltype/main.nf index 512237b9..95e4f597 100644 --- a/modules/local/spoQC/hqpr_celltype/main.nf +++ b/modules/local/spoQC/hqpr_celltype/main.nf @@ -7,14 +7,13 @@ process SPOQC_HQPR_CELLTYPE { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(_stain_sd) tuple path(annotation, stageAs: "*"), val(_stain_ann) val(step) tuple path(tmp_general, stageAs: "./spoQC_tmp/generalqc_output_hqcr.parquet"), val(_stain_g) - tuple path(tmp_bubble, stageAs: "./spoQC_tmp/bubbleqc_output_hqcr.parquet"), val(_stain_b) tuple path(tmp_doublet, stageAs: "./spoQC_tmp/doubletqc_output_hqcr.parquet"), val(_stain_d) tuple path(tmp_void, stageAs: "./spoQC_tmp/voidqc_output_hqcr.parquet"), val(_stain_v) tuple path(tmp_cell, stageAs: "./spoQC_tmp/cellqc_output_hqcr.parquet"), val(_stain_c) diff --git a/modules/local/spoQC/hqpr_celltype/meta.yml b/modules/local/spoQC/hqpr_celltype/meta.yml index 0019fcfa..ad2d2888 100644 --- a/modules/local/spoQC/hqpr_celltype/meta.yml +++ b/modules/local/spoQC/hqpr_celltype/meta.yml @@ -1,6 +1,6 @@ name: spoqc_hqpr_celltype description: | - Run per-staining high-quality pixel region (HQPR) cell-type QC, combining the general/bubble/doublet/void/cell QC outputs with the HQPR probability and mask. + Run per-staining high-quality pixel region (HQPR) cell-type QC, combining the general/doublet/void/cell QC outputs with the HQPR probability and mask. keywords: - spatial transcriptomics - quality control @@ -47,13 +47,6 @@ input: - staining_idx_g: type: integer description: Staining index carried alongside tmp_general to align the per-staining combined channel (Groovy var `_stain_g`) - - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE, tagged with the staining index - ontologies: [] - - staining_idx_b: - type: integer - description: Staining index carried alongside tmp_bubble to align the per-staining combined channel (Groovy var `_stain_b`) - - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET, tagged with the staining index diff --git a/modules/local/spoQC/hqpr_celltype/tests/main.nf.test b/modules/local/spoQC/hqpr_celltype/tests/main.nf.test index 9751d92e..44463ed0 100644 --- a/modules/local/spoQC/hqpr_celltype/tests/main.nf.test +++ b/modules/local/spoQC/hqpr_celltype/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -139,11 +129,10 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { _meta, f -> [f, 0] } input[2] = "hqpr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { _meta, f -> [f, 0] } - input[4] = SPOQC_BUBBLE.out.tmp.map { _meta, f -> [f, 0] } - input[5] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } - input[6] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } - input[7] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } - input[8] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } + input[4] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } + input[5] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } + input[6] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } + input[7] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } .join(SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, staining, m -> [staining, m] }) """ } @@ -169,11 +158,10 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { _meta, f -> [f, 0] } input[2] = "hqpr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { _meta, f -> [f, 0] } - input[4] = SPOQC_BUBBLE.out.tmp.map { _meta, f -> [f, 0] } - input[5] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } - input[6] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } - input[7] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } - input[8] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } + input[4] = SPOQC_DOUBLET.out.tmp.map { _meta, f -> [f, 0] } + input[5] = SPOQC_VOID.out.tmp.map { _meta, f -> [f, 0] } + input[6] = SPOQC_CELL.out.tmp.map { _meta, f -> [f, 0] } + input[7] = SPOQC_HQPR_CLUSTERING.out.mask.map { _meta, staining, m -> [staining, m] } .join(SPOQC_HQPR_REFINEMENT.out.mask_smoothed.map { _meta, staining, m -> [staining, m] }) """ } diff --git a/modules/local/spoQC/hqpr_clustering/main.nf b/modules/local/spoQC/hqpr_clustering/main.nf index 50776bcd..af38564a 100644 --- a/modules/local/spoQC/hqpr_clustering/main.nf +++ b/modules/local/spoQC/hqpr_clustering/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQPR_CLUSTERING { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(_stain_sd) @@ -16,7 +16,7 @@ process SPOQC_HQPR_CLUSTERING { output: tuple val(meta), val(staining), path("report/hqpr/hqpr_clustering/${staining}") , emit: report - tuple val(meta), val(staining), path("spoQC_tmp/hqpr_${staining}_output_mask_raw") , emit: mask + tuple val(meta), val(staining), path("spoQC_tmp/mask_raw_output_hqpr_${staining}") , emit: mask tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -50,7 +50,7 @@ process SPOQC_HQPR_CLUSTERING { """ mkdir -p report/hqpr/hqpr_clustering/${staining} - mkdir -p spoQC_tmp/hqpr_${staining}_output_mask_raw + mkdir -p spoQC_tmp/mask_raw_output_hqpr_${staining} """ } diff --git a/modules/local/spoQC/hqpr_clustering/meta.yml b/modules/local/spoQC/hqpr_clustering/meta.yml index 545f52c3..eb54793f 100644 --- a/modules/local/spoQC/hqpr_clustering/meta.yml +++ b/modules/local/spoQC/hqpr_clustering/meta.yml @@ -66,7 +66,7 @@ output: - "mask": type: directory description: Per-staining HQPR raw probability mask - pattern: "spoQC_tmp/hqpr_${staining}_output_mask_raw" + pattern: "spoQC_tmp/mask_raw_output_hqpr_${staining}" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqpr_metrices/main.nf b/modules/local/spoQC/hqpr_metrices/main.nf index e8d51d15..ae3f884e 100644 --- a/modules/local/spoQC/hqpr_metrices/main.nf +++ b/modules/local/spoQC/hqpr_metrices/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQPR_METRICES { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(staining) diff --git a/modules/local/spoQC/hqpr_refinement/main.nf b/modules/local/spoQC/hqpr_refinement/main.nf index 7906e25e..caf99dc8 100644 --- a/modules/local/spoQC/hqpr_refinement/main.nf +++ b/modules/local/spoQC/hqpr_refinement/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQPR_REFINEMENT { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*"), val(_stain_sd) @@ -16,7 +16,7 @@ process SPOQC_HQPR_REFINEMENT { output: tuple val(meta), val(staining), path("report/hqpr/hqpr_refinement/${staining}") , emit: report - tuple val(meta), val(staining), path("spoQC_tmp/hqpr_${staining}_output_mask_smoothed_raw") , emit: mask_smoothed + tuple val(meta), val(staining), path("spoQC_tmp/mask_smoothed_raw_output_hqpr_${staining}") , emit: mask_smoothed tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -50,7 +50,7 @@ process SPOQC_HQPR_REFINEMENT { """ mkdir -p report/hqpr/hqpr_refinement/${staining} - mkdir -p spoQC_tmp/hqpr_${staining}_output_mask_smoothed_raw + mkdir -p spoQC_tmp/mask_smoothed_raw_output_hqpr_${staining} """ } diff --git a/modules/local/spoQC/hqpr_refinement/meta.yml b/modules/local/spoQC/hqpr_refinement/meta.yml index 1938dae4..a7daf608 100644 --- a/modules/local/spoQC/hqpr_refinement/meta.yml +++ b/modules/local/spoQC/hqpr_refinement/meta.yml @@ -66,7 +66,7 @@ output: - "mask_smoothed": type: directory description: Per-staining smoothed HQPR mask - pattern: "spoQC_tmp/hqpr_${staining}_output_mask_smoothed_raw" + pattern: "spoQC_tmp/mask_smoothed_raw_output_hqpr_${staining}" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqtr_ac/main.nf b/modules/local/spoQC/hqtr_ac/main.nf index e1763f0e..923bae03 100644 --- a/modules/local/spoQC/hqtr_ac/main.nf +++ b/modules/local/spoQC/hqtr_ac/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQTR_AC { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") @@ -16,7 +16,7 @@ process SPOQC_HQTR_AC { output: tuple val(meta), path("./report/hqtr/hqtr_ac") , emit: report - tuple val(meta), path("./spoQC_tmp/hqtr_output_ac_prob") , emit: tmp + tuple val(meta), path("./spoQC_tmp/ac_density_output_hqtr") , emit: tmp tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -49,7 +49,7 @@ process SPOQC_HQTR_AC { """ mkdir -p ./report/hqtr/hqtr_ac - mkdir -p ./spoQC_tmp/hqtr_output_ac_prob + mkdir -p ./spoQC_tmp/ac_density_output_hqtr """ } diff --git a/modules/local/spoQC/hqtr_ac/meta.yml b/modules/local/spoQC/hqtr_ac/meta.yml index f6667dbe..13c56a1a 100644 --- a/modules/local/spoQC/hqtr_ac/meta.yml +++ b/modules/local/spoQC/hqtr_ac/meta.yml @@ -53,7 +53,7 @@ output: - "tmp": type: directory description: HQTR ambient-contamination probability output - pattern: "hqtr_output_ac_prob" + pattern: "ac_density_output_hqtr" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqtr_bounding_box/main.nf b/modules/local/spoQC/hqtr_bounding_box/main.nf index ac185b5f..0deceec2 100644 --- a/modules/local/spoQC/hqtr_bounding_box/main.nf +++ b/modules/local/spoQC/hqtr_bounding_box/main.nf @@ -6,12 +6,13 @@ process SPOQC_HQTR_BOUNDING_BOX { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") val(step) - path(edge_strength, stageAs: "./spoQC_tmp/hqtr_output_mask_smoothed_raw") + path(edge_strength, stageAs: "./spoQC_tmp/mask_smoothed_raw_output_hqtr") + path(metrices, stageAs: "spoQC_tmp/metrices/hqtr") output: tuple val(meta), path("./report/hqtr/hqtr_bounding_box") , emit: report diff --git a/modules/local/spoQC/hqtr_bounding_box/meta.yml b/modules/local/spoQC/hqtr_bounding_box/meta.yml index d37d72e0..7a4696b1 100644 --- a/modules/local/spoQC/hqtr_bounding_box/meta.yml +++ b/modules/local/spoQC/hqtr_bounding_box/meta.yml @@ -31,7 +31,12 @@ input: - edge_strength: type: directory description: HQTR spatially smoothed mask (edge-strength input) from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" + ontologies: [] + - metrices: + type: directory + description: HQTR metrics directory from SPOQC_HQTR_METRICES + pattern: "spoQC_tmp/metrices/hqtr" ontologies: [] output: report: diff --git a/modules/local/spoQC/hqtr_bounding_box/tests/main.nf.test b/modules/local/spoQC/hqtr_bounding_box/tests/main.nf.test index 3e18fc3c..d702a69d 100644 --- a/modules/local/spoQC/hqtr_bounding_box/tests/main.nf.test +++ b/modules/local/spoQC/hqtr_bounding_box/tests/main.nf.test @@ -108,6 +108,7 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqtr_bounding_box" input[2] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[3] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } """ } } @@ -131,6 +132,7 @@ nextflow_process { input[0] = SPATIALDATA_WRITE.out.spatialdata input[1] = "hqtr_bounding_box" input[2] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[3] = SPOQC_HQTR_METRICES.out.metrices.map { it[1] } """ } } diff --git a/modules/local/spoQC/hqtr_celltype/main.nf b/modules/local/spoQC/hqtr_celltype/main.nf index 0efb06b0..e2321e09 100644 --- a/modules/local/spoQC/hqtr_celltype/main.nf +++ b/modules/local/spoQC/hqtr_celltype/main.nf @@ -7,19 +7,18 @@ process SPOQC_HQTR_CELLTYPE { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") path(annotation, stageAs: "*") val(step) path(tmp_general, stageAs: "./spoQC_tmp/generalqc_output_hqcr.parquet") - path(tmp_bubble, stageAs: "./spoQC_tmp/bubbleqc_output_hqcr.parquet") path(tmp_doublet, stageAs: "./spoQC_tmp/doubletqc_output_hqcr.parquet") path(tmp_void, stageAs: "./spoQC_tmp/voidqc_output_hqcr.parquet") path(tmp_cell, stageAs: "./spoQC_tmp/cellqc_output_hqcr.parquet") - path(mask, stageAs: "./spoQC_tmp/hqtr_output_mask_raw") - path(mask_smoothed, stageAs: "./spoQC_tmp/hqtr_output_mask_smoothed_raw") + path(mask, stageAs: "./spoQC_tmp/mask_raw_output_hqtr") + path(mask_smoothed, stageAs: "./spoQC_tmp/mask_smoothed_raw_output_hqtr") output: tuple val(meta), path("./report/hqtr/hqtr_celltype") , emit: report diff --git a/modules/local/spoQC/hqtr_celltype/meta.yml b/modules/local/spoQC/hqtr_celltype/meta.yml index 7a27da30..42b8aaa4 100644 --- a/modules/local/spoQC/hqtr_celltype/meta.yml +++ b/modules/local/spoQC/hqtr_celltype/meta.yml @@ -1,6 +1,6 @@ name: spoqc_hqtr_celltype description: | - Run high-quality transcript region (HQTR) cell-type QC, combining the general/bubble/doublet/void/cell QC outputs with the HQTR probability and mask. + Run high-quality transcript region (HQTR) cell-type QC, combining the general/doublet/void/cell QC outputs with the HQTR probability and mask. keywords: - spatial transcriptomics - quality control @@ -39,11 +39,6 @@ input: description: General QC parquet output from SPOQC_GENERAL pattern: "generalqc_output_hqcr.parquet" ontologies: [] - - tmp_bubble: - type: file - description: Bubble QC parquet output from SPOQC_BUBBLE - pattern: "bubbleqc_output_hqcr.parquet" - ontologies: [] - tmp_doublet: type: file description: Doublet QC parquet output from SPOQC_DOUBLET @@ -62,12 +57,12 @@ input: - mask: type: directory description: HQTR raw probability mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] - mask_smoothed: type: directory description: Smoothed HQTR mask from SPOQC_HQTR_REFINEMENT - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] output: report: diff --git a/modules/local/spoQC/hqtr_celltype/tests/main.nf.test b/modules/local/spoQC/hqtr_celltype/tests/main.nf.test index 5d07c920..03f51516 100644 --- a/modules/local/spoQC/hqtr_celltype/tests/main.nf.test +++ b/modules/local/spoQC/hqtr_celltype/tests/main.nf.test @@ -56,16 +56,6 @@ nextflow_process { } } - run("SPOQC_BUBBLE") { - script "modules/local/spoQC/bubble/main.nf" - process { - """ - input[0] = SPATIALDATA_WRITE.out.spatialdata - input[1] = "bubbleqc" - """ - } - } - run("SPOQC_DOUBLET") { script "modules/local/spoQC/doublet/main.nf" process { @@ -172,12 +162,11 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqtr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[9] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[8] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } """ } } @@ -202,12 +191,11 @@ nextflow_process { input[1] = SPOQC_ANNOTATION.out.annotation.map { it[1] } input[2] = "hqtr_celltype" input[3] = SPOQC_GENERAL.out.tmp.map { it[1] } - input[4] = SPOQC_BUBBLE.out.tmp.map { it[1] } - input[5] = SPOQC_DOUBLET.out.tmp.map { it[1] } - input[6] = SPOQC_VOID.out.tmp.map { it[1] } - input[7] = SPOQC_CELL.out.tmp.map { it[1] } - input[8] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } - input[9] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } + input[4] = SPOQC_DOUBLET.out.tmp.map { it[1] } + input[5] = SPOQC_VOID.out.tmp.map { it[1] } + input[6] = SPOQC_CELL.out.tmp.map { it[1] } + input[7] = SPOQC_HQTR_CLUSTERING.out.mask.map { it[1] } + input[8] = SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { it[1] } """ } } diff --git a/modules/local/spoQC/hqtr_clustering/main.nf b/modules/local/spoQC/hqtr_clustering/main.nf index e793883a..38184f23 100644 --- a/modules/local/spoQC/hqtr_clustering/main.nf +++ b/modules/local/spoQC/hqtr_clustering/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQTR_CLUSTERING { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") @@ -18,7 +18,7 @@ process SPOQC_HQTR_CLUSTERING { output: tuple val(meta), path("report/hqtr/hqtr_clustering") , emit: report - tuple val(meta), path("spoQC_tmp/hqtr_output_mask_raw") , emit: mask + tuple val(meta), path("spoQC_tmp/mask_raw_output_hqtr") , emit: mask tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -51,7 +51,7 @@ process SPOQC_HQTR_CLUSTERING { """ mkdir -p report/hqtr/hqtr_clustering - mkdir -p spoQC_tmp/hqtr_output_mask_raw + mkdir -p spoQC_tmp/mask_raw_output_hqtr """ } diff --git a/modules/local/spoQC/hqtr_clustering/meta.yml b/modules/local/spoQC/hqtr_clustering/meta.yml index 74956272..3adebc2e 100644 --- a/modules/local/spoQC/hqtr_clustering/meta.yml +++ b/modules/local/spoQC/hqtr_clustering/meta.yml @@ -60,10 +60,10 @@ output: description: | Groovy Map containing sample information e.g. [ id:'sample' ] - - "hqtr_output_mask_raw": + - "mask_raw_output_hqtr": type: directory description: HQTR raw probability mask - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqtr_metrices/main.nf b/modules/local/spoQC/hqtr_metrices/main.nf index a4e4b790..a380c25e 100644 --- a/modules/local/spoQC/hqtr_metrices/main.nf +++ b/modules/local/spoQC/hqtr_metrices/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQTR_METRICES { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/hqtr_qv/main.nf b/modules/local/spoQC/hqtr_qv/main.nf index 87fe00db..020820d5 100644 --- a/modules/local/spoQC/hqtr_qv/main.nf +++ b/modules/local/spoQC/hqtr_qv/main.nf @@ -7,7 +7,7 @@ process SPOQC_HQTR_QV { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") @@ -15,7 +15,7 @@ process SPOQC_HQTR_QV { output: tuple val(meta), path("./report/hqtr/hqtr_qv") , emit: report - tuple val(meta), path("./spoQC_tmp/hqtr_output_qv_prob") , emit: tmp + tuple val(meta), path("./spoQC_tmp/qv_density_output_hqtr") , emit: tmp tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -48,7 +48,7 @@ process SPOQC_HQTR_QV { """ mkdir -p ./report/hqtr/hqtr_qv - mkdir -p ./spoQC_tmp/hqtr_output_qv_prob + mkdir -p ./spoQC_tmp/qv_density_output_hqtr """ } diff --git a/modules/local/spoQC/hqtr_qv/meta.yml b/modules/local/spoQC/hqtr_qv/meta.yml index 59a5a4a7..936f995a 100644 --- a/modules/local/spoQC/hqtr_qv/meta.yml +++ b/modules/local/spoQC/hqtr_qv/meta.yml @@ -45,10 +45,10 @@ output: description: | Groovy Map containing sample information e.g. [ id:'sample' ] - - "hqtr_output_qv_prob": + - "qv_density_output_hqtr": type: directory description: HQTR quality-value probability output - pattern: "hqtr_output_qv_prob" + pattern: "qv_density_output_hqtr" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/hqtr_refinement/main.nf b/modules/local/spoQC/hqtr_refinement/main.nf index 22a6f4c8..55e8aee9 100644 --- a/modules/local/spoQC/hqtr_refinement/main.nf +++ b/modules/local/spoQC/hqtr_refinement/main.nf @@ -6,16 +6,16 @@ process SPOQC_HQTR_REFINEMENT { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") val(step) - path(mask, stageAs: "./spoQC_tmp/hqtr_output_mask_raw") + path(mask, stageAs: "./spoQC_tmp/mask_raw_output_hqtr") output: tuple val(meta), path("./report/hqtr/hqtr_refinement") , emit: report - tuple val(meta), path("./spoQC_tmp/hqtr_output_mask_smoothed_raw") , emit: mask_smoothed + tuple val(meta), path("./spoQC_tmp/mask_smoothed_raw_output_hqtr") , emit: mask_smoothed tuple val("${task.process}"), val('spoqc'), eval("spoqc --version 2>&1 | grep -oP '\\d+\\.\\d+\\.\\d+' || echo unknown"), topic: versions, emit: versions_spoqc when: @@ -48,7 +48,7 @@ process SPOQC_HQTR_REFINEMENT { """ mkdir -p ./report/hqtr/hqtr_refinement - mkdir -p ./spoQC_tmp/hqtr_output_mask_smoothed_raw + mkdir -p ./spoQC_tmp/mask_smoothed_raw_output_hqtr """ } diff --git a/modules/local/spoQC/hqtr_refinement/meta.yml b/modules/local/spoQC/hqtr_refinement/meta.yml index 4a73ef61..ff8220f8 100644 --- a/modules/local/spoQC/hqtr_refinement/meta.yml +++ b/modules/local/spoQC/hqtr_refinement/meta.yml @@ -31,7 +31,7 @@ input: - mask: type: directory description: HQTR raw mask from SPOQC_HQTR_CLUSTERING - pattern: "hqtr_output_mask_raw" + pattern: "mask_raw_output_hqtr" ontologies: [] output: report: @@ -50,10 +50,10 @@ output: description: | Groovy Map containing sample information e.g. [ id:'sample' ] - - "hqtr_output_mask_smoothed_raw": + - "mask_smoothed_raw_output_hqtr": type: directory description: Smoothed HQTR mask - pattern: "hqtr_output_mask_smoothed_raw" + pattern: "mask_smoothed_raw_output_hqtr" ontologies: [] versions_spoqc: - - "${task.process}": diff --git a/modules/local/spoQC/marker/main.nf b/modules/local/spoQC/marker/main.nf index 8462be0e..12f34b5f 100644 --- a/modules/local/spoQC/marker/main.nf +++ b/modules/local/spoQC/marker/main.nf @@ -6,7 +6,7 @@ process SPOQC_MARKER { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/model/main.nf b/modules/local/spoQC/model/main.nf index af1ecf08..5c61baad 100644 --- a/modules/local/spoQC/model/main.nf +++ b/modules/local/spoQC/model/main.nf @@ -6,7 +6,7 @@ process SPOQC_MODEL { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/transcript/main.nf b/modules/local/spoQC/transcript/main.nf index 78f5615d..309991de 100644 --- a/modules/local/spoQC/transcript/main.nf +++ b/modules/local/spoQC/transcript/main.nf @@ -7,7 +7,7 @@ process SPOQC_TRANSCRIPT { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/void/main.nf b/modules/local/spoQC/void/main.nf index 8b6c219b..64cc6680 100644 --- a/modules/local/spoQC/void/main.nf +++ b/modules/local/spoQC/void/main.nf @@ -7,7 +7,7 @@ process SPOQC_VOID { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/modules/local/spoQC/whole_slide/main.nf b/modules/local/spoQC/whole_slide/main.nf index 1c4f4c74..04319ab0 100644 --- a/modules/local/spoQC/whole_slide/main.nf +++ b/modules/local/spoQC/whole_slide/main.nf @@ -7,7 +7,7 @@ process SPOQC_WHOLE_SLIDE { label 'spoqc' - container "heylf/spoqc_dev:0.1.0" + container "heylf/spoqc_dev:0.1.1" input: tuple val(meta), path(spatialdata, stageAs: "*") diff --git a/subworkflows/local/spoqc/main.nf b/subworkflows/local/spoqc/main.nf index f1a94fea..9d596f3d 100644 --- a/subworkflows/local/spoqc/main.nf +++ b/subworkflows/local/spoqc/main.nf @@ -7,7 +7,6 @@ include { SPATIALDATA_WRITE as SPATIALDATA_WRITE_RAW_BUNDLE } from '../../ include { SPOQC_ANNOTATION } from '../../../modules/local/spoQC/annotation/main' include { SPOQC_WHOLE_SLIDE } from '../../../modules/local/spoQC/whole_slide/main' include { SPOQC_GENERAL } from '../../../modules/local/spoQC/general/main' -include { SPOQC_BUBBLE } from '../../../modules/local/spoQC/bubble/main' include { SPOQC_DOUBLET } from '../../../modules/local/spoQC/doublet/main' include { SPOQC_VOID } from '../../../modules/local/spoQC/void/main' include { SPOQC_CELL } from '../../../modules/local/spoQC/cell/main' @@ -99,11 +98,6 @@ workflow SPOQC { "whole_slide_qc", ) - SPOQC_BUBBLE( - ch_sd, - "bubbleqc", - ) - SPOQC_DOUBLET( ch_sd_annotation.sd, ch_sd_annotation.annotation, @@ -133,7 +127,6 @@ workflow SPOQC { ch_sd, "hqcr_ident", SPOQC_GENERAL.out.tmp.map { _meta, f -> f }, - SPOQC_BUBBLE.out.tmp.map { _meta, f -> f }, SPOQC_DOUBLET.out.tmp.map { _meta, f -> f }, SPOQC_VOID.out.tmp.map { _meta, f -> f }, SPOQC_CELL.out.tmp.map { _meta, f -> f }, @@ -146,7 +139,6 @@ workflow SPOQC { ch_sd_annotation.annotation, "hqcr_celltype", SPOQC_GENERAL.out.tmp.map { _meta, f -> f }, - SPOQC_BUBBLE.out.tmp.map { _meta, f -> f }, SPOQC_DOUBLET.out.tmp.map { _meta, f -> f }, SPOQC_VOID.out.tmp.map { _meta, f -> f }, SPOQC_CELL.out.tmp.map { _meta, f -> f }, @@ -234,7 +226,6 @@ workflow SPOQC { ch_sd_annotation_stainings.annotation, "hqpr_celltype", SPOQC_GENERAL.out.tmp.combine(ch_stainings, by: 0).map { _meta, f, staining -> [f, staining] }, - SPOQC_BUBBLE.out.tmp.combine(ch_stainings, by: 0).map { _meta, f, staining -> [f, staining] }, SPOQC_DOUBLET.out.tmp.combine(ch_stainings, by: 0).map { _meta, f, staining -> [f, staining] }, SPOQC_VOID.out.tmp.combine(ch_stainings, by: 0).map { _meta, f, staining -> [f, staining] }, SPOQC_CELL.out.tmp.combine(ch_stainings, by: 0).map { _meta, f, staining -> [f, staining] }, @@ -278,6 +269,7 @@ workflow SPOQC { ch_sd, "hqtr_bounding_box", SPOQC_HQTR_REFINEMENT.out.mask_smoothed.map { _meta, f -> f }, + SPOQC_HQTR_METRICES.out.metrices.map { _meta, f -> f }, ) SPOQC_HQTR_CELLTYPE( @@ -285,7 +277,6 @@ workflow SPOQC { ch_sd_annotation.annotation, "hqtr_celltype", SPOQC_GENERAL.out.tmp.map { _meta, f -> f }, - SPOQC_BUBBLE.out.tmp.map { _meta, f -> f }, SPOQC_DOUBLET.out.tmp.map { _meta, f -> f }, SPOQC_VOID.out.tmp.map { _meta, f -> f }, SPOQC_CELL.out.tmp.map { _meta, f -> f }, @@ -372,7 +363,6 @@ workflow SPOQC { ch_sd .join(ch_annotation_path, by: 0, remainder: true) .join(SPOQC_GENERAL.out.tmp, by: 0) - .join(SPOQC_BUBBLE.out.tmp, by: 0) .join(SPOQC_DOUBLET.out.tmp, by: 0) .join(SPOQC_VOID.out.tmp, by: 0) .join(SPOQC_CELL.out.tmp, by: 0) @@ -388,14 +378,13 @@ workflow SPOQC { .join(ch_files_hqpr_masks_smoothed, by: 0, remainder: true) .join(ch_files_hqpr_masks, by: 0, remainder: true) .multiMap { meta, spatialdata, annotation, - general, bubble, doublet, void_qc, cell, + general, doublet, void_qc, cell, hqcr_mask, hqcr_mask_smoothed, hqcr_traffic_light, hqtr_qv, hqtr_ac, hqtr_metrices, hqtr_mask_smoothed, hqtr_mask, hqpr_metrics, hqpr_masks_smoothed, hqpr_masks -> sd: [meta, spatialdata] annotation: annotation ?: [] general_tmp: general - bubble_tmp: bubble doublet_tmp: doublet void_tmp: void_qc cell_tmp: cell @@ -418,7 +407,6 @@ workflow SPOQC { ch_analysis_inputs.annotation, "analysis_overview", ch_analysis_inputs.general_tmp, - ch_analysis_inputs.bubble_tmp, ch_analysis_inputs.doublet_tmp, ch_analysis_inputs.void_tmp, ch_analysis_inputs.cell_tmp, @@ -440,7 +428,6 @@ workflow SPOQC { ch_analysis_inputs.annotation, "analysis_category", ch_analysis_inputs.general_tmp, - ch_analysis_inputs.bubble_tmp, ch_analysis_inputs.doublet_tmp, ch_analysis_inputs.void_tmp, ch_analysis_inputs.cell_tmp, @@ -462,7 +449,6 @@ workflow SPOQC { ch_analysis_inputs.annotation, "analysis_cluster", ch_analysis_inputs.general_tmp, - ch_analysis_inputs.bubble_tmp, ch_analysis_inputs.doublet_tmp, ch_analysis_inputs.void_tmp, ch_analysis_inputs.cell_tmp, diff --git a/subworkflows/local/spoqc/meta.yml b/subworkflows/local/spoqc/meta.yml index 215f582d..0cd6d184 100644 --- a/subworkflows/local/spoqc/meta.yml +++ b/subworkflows/local/spoqc/meta.yml @@ -2,7 +2,7 @@ name: "spoqc" description: | Builds a raw SpatialData object from a 10x Xenium bundle and runs the full spoQC quality-control - toolkit against it: general/bubble/doublet/void/cell/ambient QC, high-quality cell region (HQCR), + toolkit against it: general/doublet/void/cell/ambient QC, high-quality cell region (HQCR), high-quality pixel region (HQPR) and high-quality transcript region (HQTR) mask identification/clustering/refinement, mask combination, transcript/cell-cycle/model QC, and the downstream overview/category/cluster analysis reports. @@ -19,7 +19,6 @@ components: - spoQC/annotation - spoQC/general - spoQC/whole_slide - - spoQC/bubble - spoQC/doublet - spoQC/void - spoQC/cell diff --git a/tests/spoqc.nf.test b/tests/spoqc.nf.test index 934e8a2f..92fb873a 100644 --- a/tests/spoqc.nf.test +++ b/tests/spoqc.nf.test @@ -29,7 +29,7 @@ nextflow_pipeline { def stable_path = getAllFilesFromDir(params.outdir, ignoreFile: 'tests/.nftignore') // spoQC report subfolders: checked for existence only (see spoqc/** exclusion above) def spoqc_report_dirs = [ - "ambientqc", "analysis", "annotation", "bubbleqc", "cellcycleqc", + "ambientqc", "analysis", "annotation", "cellcycleqc", "cellqc", "combine_masks", "doubletqc", "generalqc", "hqcr", "hqpr", "hqtr", "modelqc", "transcriptqc", "voidqc", "whole_slide_qc" ] @@ -73,7 +73,7 @@ nextflow_pipeline { def stable_path = getAllFilesFromDir(params.outdir, ignoreFile: 'tests/.nftignore') // spoQC report subfolders: checked for existence only (see spoqc/** exclusion above) def spoqc_report_dirs = [ - "ambientqc", "analysis", "annotation", "bubbleqc", "cellcycleqc", + "ambientqc", "analysis", "annotation", "cellcycleqc", "cellqc", "combine_masks", "doubletqc", "generalqc", "hqcr", "hqpr", "hqtr", "modelqc", "transcriptqc", "voidqc", "whole_slide_qc" ] diff --git a/tests/spoqc.nf.test.snap b/tests/spoqc.nf.test.snap index c6aea8b7..84e6ed38 100644 --- a/tests/spoqc.nf.test.snap +++ b/tests/spoqc.nf.test.snap @@ -20,9 +20,6 @@ "SPOQC_ANNOTATION": { "spoqc": "0.1.0" }, - "SPOQC_BUBBLE": { - "spoqc": "0.1.0" - }, "SPOQC_CELL": { "spoqc": "0.1.0" }, @@ -502,9 +499,6 @@ "SPOQC_ANNOTATION": { "spoqc": "0.1.0" }, - "SPOQC_BUBBLE": { - "spoqc": "0.1.0" - }, "SPOQC_CELL": { "spoqc": "0.1.0" },