diff --git a/.github/workflows/awsfulltest.yml b/.github/workflows/awsfulltest.yml index d45b8ecf..2f6822e4 100644 --- a/.github/workflows/awsfulltest.yml +++ b/.github/workflows/awsfulltest.yml @@ -24,7 +24,6 @@ jobs: - name: Launch workflow via Seqera Platform uses: seqeralabs/action-tower-launch@v2 - # TODO nf-core: You can customise AWS full pipeline tests as required # Add full size test data (but still relatively small datasets for few samples) # on the `test_full.config` test runs with only one set of parameters with: diff --git a/.nf-core.yml b/.nf-core.yml index c6f8f43c..08a86cf0 100644 --- a/.nf-core.yml +++ b/.nf-core.yml @@ -12,11 +12,13 @@ lint: nf_core_version: 3.5.2 repository_type: pipeline template: - author: Sameesh Kher, Florian Heyl + author: Sameesh Kher, Dongze He, Florian Heyl description: A pipeline for spatialomics Xenium In Situ data. force: false is_nfcore: true name: spatialxe org: nf-core outdir: . + skip_features: + - igenomes version: 1.0.0 diff --git a/README.md b/README.md index 20285254..6eafaeef 100644 --- a/README.md +++ b/README.md @@ -181,11 +181,8 @@ For further information or help, don't hesitate to get in touch on the [Slack `# ## Citations - - - An extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file. You can cite the `nf-core` publication as follows: diff --git a/assets/methods_description_template.yml b/assets/methods_description_template.yml index 12d9954f..c1fbf537 100644 --- a/assets/methods_description_template.yml +++ b/assets/methods_description_template.yml @@ -3,7 +3,6 @@ description: "Suggested text and references to use when describing pipeline usag section_name: "nf-core/spatialxe Methods Description" section_href: "https://github.com/nf-core/spatialxe" plot_type: "html" -## nf-core: Update the HTML below to your preferred methods description, e.g. add publication citation for this pipeline ## You inject any metadata in the Nextflow '${workflow}' object data: |

Methods

diff --git a/conf/base.config b/conf/base.config index 299708cf..e1668aaf 100644 --- a/conf/base.config +++ b/conf/base.config @@ -14,7 +14,7 @@ process { memory = { 6.GB * task.attempt } time = { 4.h * task.attempt } - resourceLimits = [ cpus: 192, memory: 750.GB, time: 72.h ] + // resourceLimits = [ cpus: 192, memory: 750.GB, time: 72.h ] errorStrategy = { task.exitStatus in ((130..145) + 104 + 2147483647) ? 'retry' : 'finish' } maxRetries = 3 @@ -79,7 +79,7 @@ process { withLabel:process_gpu { ext.use_gpu = { params.use_gpu } accelerator = { params.use_gpu ? 1 : null } - containerOptions = { "--shm-size ${task.memory.toGiga().intValue()}g" } + // containerOptions = { "--shm-size ${task.memory.toGiga().intValue()}g" } } // Single-GPU processes (e.g., Cellpose, StarDist) diff --git a/conf/modules.config b/conf/modules.config index 7de4eb2b..22726919 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -218,7 +218,7 @@ process { withName: PARQUET_TO_CSV { publishDir = [ - path: { "${params.outdir}/${params.mode}/utility/spatialconverter/parquet_to_csv" }, + path: { "${params.outdir}/${params.mode}/utility/parquet_to_csv" }, mode: params.publish_dir_mode, ] } diff --git a/conf/test_coordinate_mode.config b/conf/test_coordinate_mode.config index beb99283..e8338a5c 100644 --- a/conf/test_coordinate_mode.config +++ b/conf/test_coordinate_mode.config @@ -21,7 +21,7 @@ process { } params { - config_profile_name = 'Test profile' + config_profile_name = 'Test profile coordinate mode' config_profile_description = 'Minimal test dataset to check pipeline function in the coordinate mode' // Input data diff --git a/conf/test_image_mode.config b/conf/test_image_mode.config index b9b9665c..17e8124a 100644 --- a/conf/test_image_mode.config +++ b/conf/test_image_mode.config @@ -21,7 +21,7 @@ process { } params { - config_profile_name = 'Test profile' + config_profile_name = 'Test profile image mode' config_profile_description = 'Minimal test dataset to check pipeline function in the image mode' // Input data diff --git a/conf/test_preview_mode.config b/conf/test_preview_mode.config index 0fa2ce09..144a2349 100644 --- a/conf/test_preview_mode.config +++ b/conf/test_preview_mode.config @@ -21,7 +21,7 @@ process { } params { - config_profile_name = 'Test profile' + config_profile_name = 'Test profile preview mode' config_profile_description = 'Minimal test dataset to check pipeline function in the preview mode' // Input data diff --git a/conf/test_segfree_mode.config b/conf/test_segfree_mode.config index 72e2a159..5f4467b5 100644 --- a/conf/test_segfree_mode.config +++ b/conf/test_segfree_mode.config @@ -21,7 +21,7 @@ process { } params { - config_profile_name = 'Test profile' + config_profile_name = 'Test profile segfree mode' config_profile_description = 'Minimal test dataset to check pipeline function in the segfree mode' // Input data diff --git a/modules/local/baysor/create_dataset/tests/main.nf.test b/modules/local/baysor/create_dataset/tests/main.nf.test index 7bd9b6ca..41b2742a 100644 --- a/modules/local/baysor/create_dataset/tests/main.nf.test +++ b/modules/local/baysor/create_dataset/tests/main.nf.test @@ -15,7 +15,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file(params.modules_testdata_base_path + "spatial_omics/xenium/homo_sapiens/spatial_gene_expression.csv", checkIfExists: true) ]) @@ -41,7 +41,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file(params.modules_testdata_base_path + "spatial_omics/xenium/homo_sapiens/spatial_gene_expression.csv", checkIfExists: true) ]) diff --git a/modules/local/baysor/preprocess/tests/main.nf.test b/modules/local/baysor/preprocess/tests/main.nf.test index 122fbdde..f3112c25 100644 --- a/modules/local/baysor/preprocess/tests/main.nf.test +++ b/modules/local/baysor/preprocess/tests/main.nf.test @@ -15,7 +15,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true) ]) @@ -45,7 +45,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true) ]) diff --git a/modules/local/baysor/preview/tests/main.nf.test b/modules/local/baysor/preview/tests/main.nf.test index c4fbde32..d3f522d7 100644 --- a/modules/local/baysor/preview/tests/main.nf.test +++ b/modules/local/baysor/preview/tests/main.nf.test @@ -15,7 +15,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/config/xenium.toml", checkIfExists: true) @@ -41,7 +41,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/config/xenium.toml", checkIfExists: true) diff --git a/modules/local/baysor/run/tests/main.nf.test b/modules/local/baysor/run/tests/main.nf.test index 2ae31336..37cda127 100644 --- a/modules/local/baysor/run/tests/main.nf.test +++ b/modules/local/baysor/run/tests/main.nf.test @@ -16,7 +16,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), [], @@ -46,7 +46,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), [], diff --git a/modules/local/baysor/segfree/tests/main.nf.test b/modules/local/baysor/segfree/tests/main.nf.test index d7e8ce12..1fb7d2bc 100644 --- a/modules/local/baysor/segfree/tests/main.nf.test +++ b/modules/local/baysor/segfree/tests/main.nf.test @@ -15,7 +15,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/config/xenium.toml", checkIfExists: true) @@ -41,7 +41,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_baysor"], file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/transcripts.parquet", checkIfExists: true), file("https://raw.githubusercontent.com/khersameesh24/test-datasets/baysor/config/xenium.toml", checkIfExists: true) diff --git a/modules/local/ficture/model/main.nf b/modules/local/ficture/model/main.nf index 4eea675b..34c2dbc0 100644 --- a/modules/local/ficture/model/main.nf +++ b/modules/local/ficture/model/main.nf @@ -20,7 +20,6 @@ process FICTURE { script: def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" def features_list = features ? "--in-feature ${features}": "" """ @@ -33,12 +32,11 @@ process FICTURE { --n-factor 6,12 \\ --n-jobs ${task.cpus} \\ --plot-each-factor \\ - --all + --all \\ + ${args} """ stub: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" """ mkdir -p results/ """ diff --git a/modules/local/ficture/preprocess/main.nf b/modules/local/ficture/preprocess/main.nf index c412b1b9..7ec3c081 100644 --- a/modules/local/ficture/preprocess/main.nf +++ b/modules/local/ficture/preprocess/main.nf @@ -27,7 +27,8 @@ process FICTURE_PREPROCESS { ficture_preprocess.py \\ --transcripts ${transcripts} \\ ${features_arg} \\ - --negative-control-regex '${params.negative_control_regex}' + --negative-control-regex '${params.negative_control_regex}' \\ + ${args} """ stub: diff --git a/modules/local/proseg/proseg2baysor/tests/main.nf.test b/modules/local/proseg/proseg2baysor/tests/main.nf.test index fe8a8031..039217e0 100644 --- a/modules/local/proseg/proseg2baysor/tests/main.nf.test +++ b/modules/local/proseg/proseg2baysor/tests/main.nf.test @@ -30,7 +30,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_proseg2baysor"], ]).combine(PROSEG.out.seg_outs, by: 0) """ @@ -53,7 +53,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_run_proseg2baysor"], ]).combine(PROSEG.out.seg_outs, by: 0) """ diff --git a/modules/local/resolift/tests/tags.yml b/modules/local/resolift/tests/tags.yml deleted file mode 100644 index 93ee19d3..00000000 --- a/modules/local/resolift/tests/tags.yml +++ /dev/null @@ -1,2 +0,0 @@ -resolift: - - "modules/local/resolift/**" diff --git a/modules/local/utility/convert_mask_uint32/main.nf b/modules/local/utility/convert_mask_uint32/main.nf index 9102b183..fd2a3bff 100644 --- a/modules/local/utility/convert_mask_uint32/main.nf +++ b/modules/local/utility/convert_mask_uint32/main.nf @@ -16,7 +16,6 @@ process CONVERT_MASK_UINT32 { tag "${meta.id}" label 'process_low' - conda "conda-forge::python=3.12 conda-forge::tifffile conda-forge::numpy" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/d9/d964e0bef867bb2ff1a309c9c087d8d83ac734ce3aa315dd8311d4c1bfdafd8e/data' : 'community.wave.seqera.io/library/python_pip_imagecodecs_nvidia-cublas-cu12_pruned:b668bcb6d531d350' }" diff --git a/modules/local/utility/extract_dapi/main.nf b/modules/local/utility/extract_dapi/main.nf index 791a8a92..adbc6d87 100644 --- a/modules/local/utility/extract_dapi/main.nf +++ b/modules/local/utility/extract_dapi/main.nf @@ -16,7 +16,6 @@ process EXTRACT_DAPI { tag "${meta.id}" label 'process_low' - conda "conda-forge::python=3.12 conda-forge::tifffile conda-forge::numpy" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/d9/d964e0bef867bb2ff1a309c9c087d8d83ac734ce3aa315dd8311d4c1bfdafd8e/data' : 'community.wave.seqera.io/library/python_pip_imagecodecs_nvidia-cublas-cu12_pruned:b668bcb6d531d350' }" diff --git a/modules/local/utility/spatialconverter/parquet_to_csv/main.nf b/modules/local/utility/parquet_to_csv/main.nf similarity index 100% rename from modules/local/utility/spatialconverter/parquet_to_csv/main.nf rename to modules/local/utility/parquet_to_csv/main.nf diff --git a/modules/local/utility/spatialconverter/parquet_to_csv/meta.yml b/modules/local/utility/parquet_to_csv/meta.yml similarity index 94% rename from modules/local/utility/spatialconverter/parquet_to_csv/meta.yml rename to modules/local/utility/parquet_to_csv/meta.yml index 0d7a8611..60d58fcc 100644 --- a/modules/local/utility/spatialconverter/parquet_to_csv/meta.yml +++ b/modules/local/utility/parquet_to_csv/meta.yml @@ -1,9 +1,9 @@ -name: "spatialconverter_parquet_to_csv" +name: "parquet_to_csv" description: Tool suite for spatial omics data conversions. keywords: - xenium tools: - - "spatialconverter": + - "parquet_to_csv": description: "Collects functions to convert data formats for various types of data processing and analysis for spatial omics data." homepage: "https://github.com/heylf/spatialconverter" documentation: "https://github.com/heylf/spatialconverter" diff --git a/modules/local/utility/spatialconverter/parquet_to_csv/resources/usr/bin/parquet_to_csv.py b/modules/local/utility/parquet_to_csv/resources/usr/bin/parquet_to_csv.py similarity index 100% rename from modules/local/utility/spatialconverter/parquet_to_csv/resources/usr/bin/parquet_to_csv.py rename to modules/local/utility/parquet_to_csv/resources/usr/bin/parquet_to_csv.py diff --git a/modules/nf-core/xeniumranger/import-segmentation/tests/main.nf.test b/modules/nf-core/xeniumranger/import-segmentation/tests/main.nf.test index 54d3ba00..e61cdc11 100644 --- a/modules/nf-core/xeniumranger/import-segmentation/tests/main.nf.test +++ b/modules/nf-core/xeniumranger/import-segmentation/tests/main.nf.test @@ -26,7 +26,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_import-segmentation"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = 0 @@ -93,7 +93,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_import-segmentation"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = 0 @@ -159,7 +159,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_import-segmentation"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = 0 @@ -225,7 +225,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_import-segmentation"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = 0 @@ -292,7 +292,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_import-segmentation"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = 0 diff --git a/modules/nf-core/xeniumranger/relabel/tests/main.nf.test b/modules/nf-core/xeniumranger/relabel/tests/main.nf.test index d0962738..7c37a32a 100644 --- a/modules/nf-core/xeniumranger/relabel/tests/main.nf.test +++ b/modules/nf-core/xeniumranger/relabel/tests/main.nf.test @@ -26,7 +26,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_relabel"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = UNZIP.out.unzipped_archive.map { it[1] } + "/gene_panel.json" @@ -76,7 +76,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_relabel"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = UNZIP.out.unzipped_archive.map { it[1] } + "/gene_panel.json" diff --git a/modules/nf-core/xeniumranger/resegment/tests/main.nf.test b/modules/nf-core/xeniumranger/resegment/tests/main.nf.test index 861c2414..36f26f46 100644 --- a/modules/nf-core/xeniumranger/resegment/tests/main.nf.test +++ b/modules/nf-core/xeniumranger/resegment/tests/main.nf.test @@ -26,7 +26,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_resegment"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = [] @@ -57,7 +57,7 @@ nextflow_process { when { process { """ - input[0] = Channel.of([ + input[0] = channel.of([ [id: "test_xeniumranger_resegment"], ]).combine(UNZIP.out.unzipped_archive.map { it[1] }) input[1] = [] diff --git a/nextflow.config b/nextflow.config index bc551340..73be717e 100644 --- a/nextflow.config +++ b/nextflow.config @@ -130,7 +130,6 @@ params { restrict_concurrency = false // restrict running certain process in parallel // Boilerplate options - outdir = null publish_dir_mode = 'copy' email = null email_on_fail = null diff --git a/ro-crate-metadata.json b/ro-crate-metadata.json index ef0b01d9..89f81f6a 100644 --- a/ro-crate-metadata.json +++ b/ro-crate-metadata.json @@ -23,7 +23,7 @@ "@type": "Dataset", "creativeWorkStatus": "Stable", "datePublished": "2026-04-28T15:09:48+00:00", - "description": "

\n \n \n \"nf-core/spatialxe\"\n \n

\n\n[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/nf-core/spatialxe)\n[![GitHub Actions CI Status](https://github.com/nf-core/spatialxe/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/spatialxe/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/spatialxe/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/spatialxe/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/spatialxe/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)\n[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A525.04.0-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.4.1-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.4.1)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/spatialxe)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23spatialxe-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/spatialxe)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/spatialxe** is a bioinformatics best-practice processing and quality control pipeline for Xenium data. The current plan for the pipeline implementation is shown in the metromap below. **The pipeline is under active developement and changes might occure frequently**.\n\n![nf-core/spatialxe-metromap](docs/images/spatialxe-metromap.png)\n\n> [!NOTE]\n> We are currently testing the pipeline for the [10x Atera system](https://www.10xgenomics.com/platforms/atera).\n\n## Tools supported\n\nThe pipeline supports the following tools:\n\n- Segmenation methods:\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n - [Cellpose](https://doi.org/10.1038/s41592-020-01018-x)\n - [Xenium ranger (XR)](https://www.10xgenomics.com/support/software/xenium-ranger/latest)\n - [StarDist](https://doi.org/10.48550/arXiv.2203.02284)\n- Segmentation free methods:\n - [Ficture](https://doi.org/10.1038/s41592-024-02415-2)\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n- Transcript assignment methods:\n - [Segger](https://doi.org/10.1101/2025.03.14.643160)\n - [Proseg](https://doi.org/10.1038/s41592-025-02697-0)\n- Utility methods:\n - [SpatialData](https://doi.org/10.1038/s41592-024-02212-x)\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n- QC methods:\n - [MultiQC Xenium Extra Plugin](https://github.com/MultiQC/xenium-extra)\n - [OPT](https://github.com/JEFworks-Lab/off-target-probe-tracker)\n\n## Usage\n\nOn release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/spatialxe/results).\n\n> [!NOTE]\n> The pipeline does not support conda currently. We are working on it.\n\n## Quick Start\n\n`samplesheet.csv`:\n\n```csv\nsample,bundle,image\ntest_sample,/path/to/xenium-bundle,/path/to/morphology.ome.tif\n```\n\nNow, you can run the pipeline using:\n\n### Run image-based segmentation mode
\n\n`CELLPOSE -> BAYSOR -> XR-IMPORT_SEGMENTATION -> SPATIALDATA -> QC`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode \n```\n\n### Run coordinate-based segmentation mode
\n\n`PROSEG -> PROSEG2BAYSOR -> XR-IMPORT_SEGMENTATION -> SPATIALDATA -> QC`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode coordinate\n```\n\n### Run segfree mode
\n\n`BAYSOR_SEGFREE`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode segfree\n```\n\n### Run preview mode
\n\n`BAYSOR_PREVIEW`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode preview\n```\n\n### Run just the quality control
\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode qc\n```\n\n### Additional information\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/spatialxe/usage) and the [parameter documentation](https://nf-co.re/spatialxe/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/spatialxe/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/spatialxe/output).\n\n## Runtime and resource estimations\n\n| Tool | Compute | Runtime (min / med / max) | Peak RSS (min / med / max) |\n| ------------------------- | ------- | ------------------------- | -------------------------- |\n| Cellpose | GPU | 1m / 4m / 1.4h | 10 GB / 26 GB / 554 GB |\n| Cellpose | CPU | 1.3h / 2.3h / 6.5h | 161 GB / 426 GB / 1115 GB |\n| StarDist | GPU | 1m / 4m / 7m | 5 GB / 12 GB / 18 GB |\n| StarDist | CPU | 5m / 6m / 7m | 18 GB / 18 GB / 18 GB |\n| Segger (create_dataset) | GPU | 2m / 9m / 31m | 1.7 GB / 14 GB / 50 GB |\n| Segger (create_dataset) | CPU | 13m / 21m / 46m | 13 GB / 19 GB / 49 GB |\n| Segger (train) | GPU | 10m / 43m / 2.9h | 30 GB / 33 GB / 60 GB |\n| Segger (predict) | GPU | 2m / 16m / 59m | 10 GB / 25 GB / 87 GB |\n| Baysor (whole-image) | CPU | 2m / 30m / 17h | 6 GB / 10 GB / 650 GB |\n| Baysor (tiled) | CPU | 1m / 18m / 13h | 0.2 GB / 34 GB / 530 GB |\n| Proseg | CPU | 1m / 18m / 6.8h | 279 MB / 3.8 GB / 136 GB |\n| XeniumRanger (resegment) | CPU | 18m / 39m / 3.7h | 28 GB / 54 GB / 60 GB |\n| XeniumRanger (import_seg) | CPU | 2m / 7m / 2.7h | 2.6 GB / 11 GB / 51 GB |\n| Ficture (preprocess) | CPU | 3m / 4m / 13m | 331 MB / 357 MB / 21 GB |\n\n- Cellpose GPU vs CPU: 35x faster on GPU (4m median vs 2.3h), 16x less memory (26 GB vs 426 GB)\n- Segger: Only tool that truly requires GPU for all 3 steps (create_dataset, train, predict)\n- StarDist: Very fast on CPU, GPU is not necessary to run its default model\n\n## Credits\n\nnf-core/spatialxe is mainly developed by [Sameesh Kher](https://github.com/khersameesh24), [Dongze He](https://github.com/dongzehe), and [Florian Heyl](https://github.com/heylf).\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n- Tobias Krause\n- Kre\u0161imir Be\u0161tak (kbestak)\n- Matthias H\u00f6rtenhuber (mashehu)\n- Maxime Garcia (maxulysse)\n- K\u00fcbra Narc\u0131 (kubranarci)\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#spatialxe` channel](https://nfcore.slack.com/channels/spatialxe) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\n\n\n\n\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", + "description": "

\n \n \n \"nf-core/spatialxe\"\n \n

\n\n[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/nf-core/spatialxe)\n[![GitHub Actions CI Status](https://github.com/nf-core/spatialxe/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/spatialxe/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/spatialxe/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/spatialxe/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/spatialxe/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)\n[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A525.04.0-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.4.1-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.4.1)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/spatialxe)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23spatialxe-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/spatialxe)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/spatialxe** is a bioinformatics best-practice processing and quality control pipeline for Xenium data. The current plan for the pipeline implementation is shown in the metromap below. **The pipeline is under active developement and changes might occure frequently**.\n\n![nf-core/spatialxe-metromap](docs/images/spatialxe-metromap.png)\n\n> [!NOTE]\n> We are currently testing the pipeline for the [10x Atera system](https://www.10xgenomics.com/platforms/atera).\n\n## Tools supported\n\nThe pipeline supports the following tools:\n\n- Segmenation methods:\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n - [Cellpose](https://doi.org/10.1038/s41592-020-01018-x)\n - [Xenium ranger (XR)](https://www.10xgenomics.com/support/software/xenium-ranger/latest)\n - [StarDist](https://doi.org/10.48550/arXiv.2203.02284)\n- Segmentation free methods:\n - [Ficture](https://doi.org/10.1038/s41592-024-02415-2)\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n- Transcript assignment methods:\n - [Segger](https://doi.org/10.1101/2025.03.14.643160)\n - [Proseg](https://doi.org/10.1038/s41592-025-02697-0)\n- Utility methods:\n - [SpatialData](https://doi.org/10.1038/s41592-024-02212-x)\n - [Baysor](https://doi.org/10.1038/s41587-021-01044-w)\n- QC methods:\n - [MultiQC Xenium Extra Plugin](https://github.com/MultiQC/xenium-extra)\n - [OPT](https://github.com/JEFworks-Lab/off-target-probe-tracker)\n\n## Usage\n\nOn release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/spatialxe/results).\n\n> [!NOTE]\n> The pipeline does not support conda currently. We are working on it.\n\n## Quick Start\n\n`samplesheet.csv`:\n\n```csv\nsample,bundle,image\ntest_sample,/path/to/xenium-bundle,/path/to/morphology.ome.tif\n```\n\nNow, you can run the pipeline using:\n\n### Run image-based segmentation mode
\n\n`CELLPOSE -> BAYSOR -> XR-IMPORT_SEGMENTATION -> SPATIALDATA -> QC`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode \n```\n\n### Run coordinate-based segmentation mode
\n\n`PROSEG -> PROSEG2BAYSOR -> XR-IMPORT_SEGMENTATION -> SPATIALDATA -> QC`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode coordinate\n```\n\n### Run segfree mode
\n\n`BAYSOR_SEGFREE`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode segfree\n```\n\n### Run preview mode
\n\n`BAYSOR_PREVIEW`\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode preview\n```\n\n### Run just the quality control
\n\n```bash\nnextflow run nf-core/spatialxe \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \\\n --mode qc\n```\n\n### Additional information\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/spatialxe/usage) and the [parameter documentation](https://nf-co.re/spatialxe/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/spatialxe/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/spatialxe/output).\n\n## Runtime and resource estimations\n\n| Tool | Compute | Runtime (min / med / max) | Peak RSS (min / med / max) |\n| ------------------------- | ------- | ------------------------- | -------------------------- |\n| Cellpose | GPU | 1m / 4m / 1.4h | 10 GB / 26 GB / 554 GB |\n| Cellpose | CPU | 1.3h / 2.3h / 6.5h | 161 GB / 426 GB / 1115 GB |\n| StarDist | GPU | 1m / 4m / 7m | 5 GB / 12 GB / 18 GB |\n| StarDist | CPU | 5m / 6m / 7m | 18 GB / 18 GB / 18 GB |\n| Segger (create_dataset) | GPU | 2m / 9m / 31m | 1.7 GB / 14 GB / 50 GB |\n| Segger (create_dataset) | CPU | 13m / 21m / 46m | 13 GB / 19 GB / 49 GB |\n| Segger (train) | GPU | 10m / 43m / 2.9h | 30 GB / 33 GB / 60 GB |\n| Segger (predict) | GPU | 2m / 16m / 59m | 10 GB / 25 GB / 87 GB |\n| Baysor (whole-image) | CPU | 2m / 30m / 17h | 6 GB / 10 GB / 650 GB |\n| Baysor (tiled) | CPU | 1m / 18m / 13h | 0.2 GB / 34 GB / 530 GB |\n| Proseg | CPU | 1m / 18m / 6.8h | 279 MB / 3.8 GB / 136 GB |\n| XeniumRanger (resegment) | CPU | 18m / 39m / 3.7h | 28 GB / 54 GB / 60 GB |\n| XeniumRanger (import_seg) | CPU | 2m / 7m / 2.7h | 2.6 GB / 11 GB / 51 GB |\n| Ficture (preprocess) | CPU | 3m / 4m / 13m | 331 MB / 357 MB / 21 GB |\n\n- Cellpose GPU vs CPU: 35x faster on GPU (4m median vs 2.3h), 16x less memory (26 GB vs 426 GB)\n- Segger: Only tool that truly requires GPU for all 3 steps (create_dataset, train, predict)\n- StarDist: Very fast on CPU, GPU is not necessary to run its default model\n\n## Credits\n\nnf-core/spatialxe is mainly developed by [Sameesh Kher](https://github.com/khersameesh24), [Dongze He](https://github.com/dongzehe), and [Florian Heyl](https://github.com/heylf).\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n- Tobias Krause\n- Kre\u0161imir Be\u0161tak (kbestak)\n- Matthias H\u00f6rtenhuber (mashehu)\n- Maxime Garcia (maxulysse)\n- K\u00fcbra Narc\u0131 (kubranarci)\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#spatialxe` channel](https://nfcore.slack.com/channels/spatialxe) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\n\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", "hasPart": [ { "@id": "main.nf" diff --git a/subworkflows/local/baysor_generate_preview/main.nf b/subworkflows/local/baysor_generate_preview/main.nf index 3c4112c1..2494fcbd 100644 --- a/subworkflows/local/baysor_generate_preview/main.nf +++ b/subworkflows/local/baysor_generate_preview/main.nf @@ -5,7 +5,7 @@ include { BAYSOR_PREVIEW } from '../../../modules/local/baysor/preview/main' include { BAYSOR_CREATE_DATASET } from '../../../modules/local/baysor/create_dataset/main' include { EXTRACT_PREVIEW_DATA } from '../../../modules/local/utility/extract_preview_data/main' -include { PARQUET_TO_CSV } from '../../../modules/local/utility/spatialconverter/parquet_to_csv/main' +include { PARQUET_TO_CSV } from '../../../modules/local/utility/parquet_to_csv/main' workflow BAYSOR_GENERATE_PREVIEW { take: @@ -14,9 +14,8 @@ workflow BAYSOR_GENERATE_PREVIEW { main: - ch_versions = Channel.empty() - ch_preview_mqc_html = Channel.empty() - ch_preview_mqc_png = Channel.empty() + ch_preview_mqc_html = channel.empty() + ch_preview_mqc_png = channel.empty() // run parquet to csv @@ -47,5 +46,4 @@ workflow BAYSOR_GENERATE_PREVIEW { emit: preview_html = ch_preview_mqc_html // channel: [ val(meta), ["*_mqc.tsv"] ] preview_img = ch_preview_mqc_png // channel: [ val(meta), ["*_mqc.png"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/baysor_generate_segfree/main.nf b/subworkflows/local/baysor_generate_segfree/main.nf index 02ff44c8..52e2e699 100644 --- a/subworkflows/local/baysor_generate_segfree/main.nf +++ b/subworkflows/local/baysor_generate_segfree/main.nf @@ -13,9 +13,7 @@ workflow BAYSOR_GENERATE_SEGFREE { main: - ch_versions = Channel.empty() - - ch_transcripts = Channel.empty() + ch_transcripts = channel.empty() // Always preprocess transcripts.parquet to CSV for Baysor 0.7.1 compatibility. // Baysor's Julia Parquet.jl cannot read zstd-compressed parquet files from Xenium bundles. @@ -43,7 +41,7 @@ workflow BAYSOR_GENERATE_SEGFREE { BAYSOR_SEGFREE( ch_baysor_segfree_input ) + emit: ncvs = BAYSOR_SEGFREE.out.ncvs // channel: [ val(meta), ["ncvs.loom"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/baysor_run_prior_segmentation_mask/main.nf b/subworkflows/local/baysor_run_prior_segmentation_mask/main.nf index 02eaaec8..17025571 100644 --- a/subworkflows/local/baysor_run_prior_segmentation_mask/main.nf +++ b/subworkflows/local/baysor_run_prior_segmentation_mask/main.nf @@ -16,12 +16,10 @@ workflow BAYSOR_RUN_PRIOR_SEGMENTATION_MASK { main: - ch_versions = Channel.empty() + ch_transcripts = channel.empty() - ch_transcripts = Channel.empty() - - ch_redefined_bundle = Channel.empty() - ch_coordinate_space = Channel.value("pixels") + ch_redefined_bundle = channel.empty() + ch_coordinate_space = channel.value("pixels") // Always preprocess transcripts.parquet to CSV for Baysor 0.7.1 compatibility. // Baysor's Julia Parquet.jl cannot read zstd-compressed parquet files from Xenium bundles. @@ -77,5 +75,4 @@ workflow BAYSOR_RUN_PRIOR_SEGMENTATION_MASK { emit: coordinate_space = ch_coordinate_space // channel: [ "pixels" ] redefined_bundle = ch_redefined_bundle // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/baysor_run_transcripts_parquet/main.nf b/subworkflows/local/baysor_run_transcripts_parquet/main.nf index c085a34f..26f9283b 100644 --- a/subworkflows/local/baysor_run_transcripts_parquet/main.nf +++ b/subworkflows/local/baysor_run_transcripts_parquet/main.nf @@ -29,8 +29,7 @@ workflow BAYSOR_RUN_TRANSCRIPTS_PARQUET { main: - ch_versions = Channel.empty() - ch_coordinate_space = Channel.value("microns") + ch_coordinate_space = channel.value("microns") if ( params.baysor_tiling ) { @@ -155,5 +154,4 @@ workflow BAYSOR_RUN_TRANSCRIPTS_PARQUET { emit: redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs coordinate_space = ch_coordinate_space - versions = ch_versions } diff --git a/subworkflows/local/baysor_run_transcripts_parquet_tiled/main.nf b/subworkflows/local/baysor_run_transcripts_parquet_tiled/main.nf index 23435886..16cb06dd 100644 --- a/subworkflows/local/baysor_run_transcripts_parquet_tiled/main.nf +++ b/subworkflows/local/baysor_run_transcripts_parquet_tiled/main.nf @@ -17,7 +17,7 @@ workflow BAYSOR_RUN_TRANSCRIPTS_PARQUET_TILED { main: - ch_coordinate_space = Channel.value("microns") + ch_coordinate_space = channel.value("microns") // Step 1: Divide transcripts into overlapping patches XENIUM_PATCH_DIVIDE ( ch_transcripts_file ) diff --git a/subworkflows/local/cellpose_baysor_import_segmentation/main.nf b/subworkflows/local/cellpose_baysor_import_segmentation/main.nf index 9f89162f..011d9477 100644 --- a/subworkflows/local/cellpose_baysor_import_segmentation/main.nf +++ b/subworkflows/local/cellpose_baysor_import_segmentation/main.nf @@ -23,11 +23,9 @@ workflow CELLPOSE_BAYSOR_IMPORT_SEGMENTATION { main: - ch_versions = Channel.empty() - ch_transcripts = Channel.empty() - ch_imp_seg_inputs = Channel.empty() - ch_filtered_transcripts = Channel.empty() - ch_coordinate_space = Channel.value("microns") + ch_transcripts = channel.empty() + ch_imp_seg_inputs = channel.empty() + ch_coordinate_space = channel.value("microns") // Use empty list when no model is provided; path input for official cellpose module @@ -180,5 +178,4 @@ workflow CELLPOSE_BAYSOR_IMPORT_SEGMENTATION { emit: coordinate_space = ch_coordinate_space // channel: [ val("microns") ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/cellpose_resolift_morphology_ome_tif/main.nf b/subworkflows/local/cellpose_resolift_morphology_ome_tif/main.nf index 2fda9ec2..bc81a5d7 100644 --- a/subworkflows/local/cellpose_resolift_morphology_ome_tif/main.nf +++ b/subworkflows/local/cellpose_resolift_morphology_ome_tif/main.nf @@ -18,9 +18,8 @@ workflow CELLPOSE_RESOLIFT_MORPHOLOGY_OME_TIF { main: - ch_versions = Channel.empty() - ch_imp_seg_inputs = Channel.empty() - ch_coordinate_space = Channel.value("pixels") + ch_imp_seg_inputs = channel.empty() + ch_coordinate_space = channel.value("pixels") // Use empty list when no model is provided; path input for official cellpose module cellpose_model = params.cellpose_model ? file(params.cellpose_model) : [] @@ -50,7 +49,7 @@ workflow CELLPOSE_RESOLIFT_MORPHOLOGY_OME_TIF { else { ch_cellpose_input = ch_image - ch_scale_info = Channel.empty() + ch_scale_info = channel.empty() } // run cellpose on morphology tiff (or downscaled version) @@ -134,5 +133,4 @@ workflow CELLPOSE_RESOLIFT_MORPHOLOGY_OME_TIF { emit: coordinate_space = ch_coordinate_space // channel: [ ["pixels"] ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/ficture_preprocess_model/main.nf b/subworkflows/local/ficture_preprocess_model/main.nf index 203d057e..06d4edf2 100644 --- a/subworkflows/local/ficture_preprocess_model/main.nf +++ b/subworkflows/local/ficture_preprocess_model/main.nf @@ -4,7 +4,7 @@ include { FICTURE_PREPROCESS } from '../../../modules/local/ficture/preprocess/main' include { FICTURE } from '../../../modules/local/ficture/model/main' -include { PARQUET_TO_CSV } from '../../../modules/local/utility/spatialconverter/parquet_to_csv/main' +include { PARQUET_TO_CSV } from '../../../modules/local/utility/parquet_to_csv/main' @@ -15,8 +15,6 @@ workflow FICTURE_PREPROCESS_MODEL { main: - ch_versions = Channel.empty() - // convert parquet to csv PARQUET_TO_CSV(ch_transcripts_file, ".csv") @@ -26,7 +24,7 @@ workflow FICTURE_PREPROCESS_MODEL { FICTURE_PREPROCESS(ch_transcripts, ch_features) // run the ficture wrapper pipeline - ch_features_clean = params.features ? FICTURE_PREPROCESS.out.features : Channel.value([]) + ch_features_clean = params.features ? FICTURE_PREPROCESS.out.features : channel.value([]) FICTURE( FICTURE_PREPROCESS.out.transcripts, FICTURE_PREPROCESS.out.coordinate_minmax, @@ -37,5 +35,4 @@ workflow FICTURE_PREPROCESS_MODEL { coordinate_minmax = FICTURE_PREPROCESS.out.coordinate_minmax // channel: [ "*coordinate_minmax.tsv" ] features = FICTURE_PREPROCESS.out.features // channel: [ "*feature.clean.tsv.gz" ] results = FICTURE.out.results // channel: [ val(meta), [ "results/** ] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/opt_flip_track_stat/main.nf b/subworkflows/local/opt_flip_track_stat/main.nf index 916268ad..839768d2 100644 --- a/subworkflows/local/opt_flip_track_stat/main.nf +++ b/subworkflows/local/opt_flip_track_stat/main.nf @@ -11,8 +11,8 @@ workflow OPT_FLIP_TRACK_STAT { main: - ch_versions = Channel.empty() - ch_summary = Channel.empty() + ch_versions = channel.empty() + ch_summary = channel.empty() // correct probes that are aligning to opposite strand with `flip` OPT_FLIP(ch_probe_fasta, ch_references) diff --git a/subworkflows/local/proseg_preset_proseg2baysor/main.nf b/subworkflows/local/proseg_preset_proseg2baysor/main.nf index 757e319f..3f9d8c99 100644 --- a/subworkflows/local/proseg_preset_proseg2baysor/main.nf +++ b/subworkflows/local/proseg_preset_proseg2baysor/main.nf @@ -13,8 +13,7 @@ workflow PROSEG_PRESET_PROSEG2BAYSOR { main: - ch_versions = Channel.empty() - ch_coordinate_space = Channel.value("microns") + ch_coordinate_space = channel.value("microns") // run proseg with the xenium format PROSEG(ch_transcripts_file) @@ -48,5 +47,4 @@ workflow PROSEG_PRESET_PROSEG2BAYSOR { emit: coordinate_space = ch_coordinate_space // channel: [ "microns" ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/proseg_preset_proseg2baysor_tiled/main.nf b/subworkflows/local/proseg_preset_proseg2baysor_tiled/main.nf index ab141ae8..afeca1a0 100644 --- a/subworkflows/local/proseg_preset_proseg2baysor_tiled/main.nf +++ b/subworkflows/local/proseg_preset_proseg2baysor_tiled/main.nf @@ -16,8 +16,7 @@ workflow PROSEG_PRESET_PROSEG2BAYSOR_TILED { main: - ch_versions = Channel.empty() - ch_coordinate_space = Channel.value("microns") + ch_coordinate_space = channel.value("microns") // Step 1: Divide transcripts into overlapping patches XENIUM_PATCH_DIVIDE ( ch_transcripts_file ) @@ -84,5 +83,4 @@ workflow PROSEG_PRESET_PROSEG2BAYSOR_TILED { emit: coordinate_space = ch_coordinate_space // channel: [ "microns" ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/segger_create_train_predict/main.nf b/subworkflows/local/segger_create_train_predict/main.nf index 97c38aad..7e3b8b74 100644 --- a/subworkflows/local/segger_create_train_predict/main.nf +++ b/subworkflows/local/segger_create_train_predict/main.nf @@ -15,10 +15,9 @@ workflow SEGGER_CREATE_TRAIN_PREDICT { main: - ch_versions = Channel.empty() // Note: spatialxe uses "pixels" but per 10x docs, transcript-based segmentation // (like Baysor/Segger) must use "microns" since Xenium coordinates are in microns - ch_coordinate_space = Channel.value("microns") + ch_coordinate_space = channel.value("microns") // create dataset (always needed for predict step) SEGGER_CREATE_DATASET(ch_bundle) @@ -74,5 +73,4 @@ workflow SEGGER_CREATE_TRAIN_PREDICT { emit: coordinate_space = ch_coordinate_space // channel: [ "microns" ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/spatialdata_write_meta_merge/main.nf b/subworkflows/local/spatialdata_write_meta_merge/main.nf index 68ddf26c..32052d85 100644 --- a/subworkflows/local/spatialdata_write_meta_merge/main.nf +++ b/subworkflows/local/spatialdata_write_meta_merge/main.nf @@ -15,29 +15,28 @@ workflow SPATIALDATA_WRITE_META_MERGE { main: - ch_versions = Channel.empty() - ch_segmented_object = Channel.empty() + ch_segmented_object = channel.empty() // check segmentation - only nuclei, cells or both cells & nuclei if (params.mode == 'image') { if (params.nucleus_segmentation_only && params.cell_segmentation_only) { - ch_segmented_object = Channel.value('cells_and_nuclei') + ch_segmented_object = channel.value('cells_and_nuclei') } else if (params.nucleus_segmentation_only) { - ch_segmented_object = Channel.value('nuclei') + ch_segmented_object = channel.value('nuclei') } else if (params.cell_segmentation_only) { - ch_segmented_object = Channel.value('cells') + ch_segmented_object = channel.value('cells') } else { - ch_segmented_object = Channel.value([]) + ch_segmented_object = channel.value([]) } } // set all boundaries as false - default if (params.mode == 'coordinate') { - ch_segmented_object = Channel.value([]) + ch_segmented_object = channel.value([]) } // write spatialdata object from the raw xenium bundle @@ -76,5 +75,4 @@ workflow SPATIALDATA_WRITE_META_MERGE { sd_redefined_bundle = SPATIALDATA_WRITE_REDEFINED_BUNDLE.out.spatialdata // channel: [ val(meta), "spatialdata_redefined" ] sd_merged_bundle = SPATIALDATA_MERGE_RAW_REDEFINED.out.merged_bundle // channel: [ val(meta), "spatialdata_merged" ] sd_metadata = SPATIALDATA_META.out.metadata // channel: [ val(meta), "spatialdata_meta" ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/stardist_resolift_morphology_ome_tif/main.nf b/subworkflows/local/stardist_resolift_morphology_ome_tif/main.nf index ad338f57..ad2188c2 100644 --- a/subworkflows/local/stardist_resolift_morphology_ome_tif/main.nf +++ b/subworkflows/local/stardist_resolift_morphology_ome_tif/main.nf @@ -15,9 +15,8 @@ workflow STARDIST_RESOLIFT_MORPHOLOGY_OME_TIF { main: - ch_versions = Channel.empty() - ch_imp_seg_inputs = Channel.empty() - ch_coordinate_space = Channel.value("pixels") + ch_imp_seg_inputs = channel.empty() + ch_coordinate_space = channel.value("pixels") // Use default model when no model is provided stardist_nuclei_model = params.stardist_nuclei_model ?: '2D_versatile_fluo' @@ -66,5 +65,4 @@ workflow STARDIST_RESOLIFT_MORPHOLOGY_OME_TIF { emit: coordinate_space = ch_coordinate_space // channel: [ ["pixels"] ] redefined_bundle = XENIUMRANGER_IMPORT_SEGMENTATION.out.outs // channel: [ val(meta), ["redefined-xenium-bundle"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/local/utils_nfcore_spatialxe_pipeline/main.nf b/subworkflows/local/utils_nfcore_spatialxe_pipeline/main.nf index 51bf77b2..b812e1c7 100644 --- a/subworkflows/local/utils_nfcore_spatialxe_pipeline/main.nf +++ b/subworkflows/local/utils_nfcore_spatialxe_pipeline/main.nf @@ -37,8 +37,6 @@ workflow PIPELINE_INITIALISATION { main: - ch_versions = Channel.empty() - // // Print version and exit if required and dump pipeline parameters to JSON file // @@ -101,7 +99,7 @@ workflow PIPELINE_INITIALISATION { // try { - Channel.fromList(samplesheetToList(input, "${projectDir}/assets/schema_input.json")) + channel.fromList(samplesheetToList(input, "${projectDir}/assets/schema_input.json")) .map { meta, bundle, image -> return [[id: meta.id], bundle, image] } @@ -125,7 +123,6 @@ workflow PIPELINE_INITIALISATION { emit: samplesheet = ch_samplesheet - versions = ch_versions } /* @@ -331,7 +328,6 @@ def validateXeniumBundle(ch_samplesheet) { // Generate methods description for MultiQC // def toolCitationText() { - // TODO nf-core: Optionally add in-text citation tools to this list. // Can use ternary operators to dynamically construct based conditions, e.g. params["run_xyz"] ? "Tool (Foo et al. 2023)" : "", // Uncomment function in methodsDescriptionText to render in MultiQC report def citation_text = [ @@ -344,7 +340,6 @@ def toolCitationText() { } def toolBibliographyText() { - // TODO nf-core: Optionally add bibliographic entries to this list. // Can use ternary operators to dynamically construct based conditions, e.g. params["run_xyz"] ? "
  • Author (2023) Pub name, Journal, DOI
  • " : "", // Uncomment function in methodsDescriptionText to render in MultiQC report def reference_text = [ @@ -381,11 +376,10 @@ def methodsDescriptionText(mqc_methods_yaml) { meta["tool_citations"] = "" meta["tool_bibliography"] = "" - // TODO nf-core: Only uncomment below if logic in toolCitationText/toolBibliographyText has been filled! + // Only uncomment below if logic in toolCitationText/toolBibliographyText has been filled! // meta["tool_citations"] = toolCitationText().replaceAll(", \\.", ".").replaceAll("\\. \\.", ".").replaceAll(", \\.", ".") // meta["tool_bibliography"] = toolBibliographyText() - def methods_text = mqc_methods_yaml.text def engine = new groovy.text.SimpleTemplateEngine() diff --git a/subworkflows/local/xeniumranger_import_segmentation_redefine_bundle/main.nf b/subworkflows/local/xeniumranger_import_segmentation_redefine_bundle/main.nf index 4940e6d3..e18b36ec 100644 --- a/subworkflows/local/xeniumranger_import_segmentation_redefine_bundle/main.nf +++ b/subworkflows/local/xeniumranger_import_segmentation_redefine_bundle/main.nf @@ -13,9 +13,9 @@ workflow XENIUMRANGER_IMPORT_SEGMENTATION_REDEFINE_BUNDLE { main: - ch_versions = Channel.empty() - ch_redefined_bundle = Channel.empty() - ch_coordinate_space = Channel.empty() + ch_versions = channel.empty() + ch_redefined_bundle = channel.empty() + ch_coordinate_space = channel.empty() cells = ch_bundle_path.map { meta, bundle -> return [meta, bundle + "/cells.zarr.zip"] diff --git a/subworkflows/local/xeniumranger_relabel_resegment/main.nf b/subworkflows/local/xeniumranger_relabel_resegment/main.nf index 8dc95d6f..424224a7 100644 --- a/subworkflows/local/xeniumranger_relabel_resegment/main.nf +++ b/subworkflows/local/xeniumranger_relabel_resegment/main.nf @@ -12,7 +12,7 @@ workflow XENIUMRANGER_RELABEL_RESEGMENT { main: - ch_versions = Channel.empty() + ch_versions = channel.empty() // Combine bundle path with gene panel into a single tuple for relabel XENIUMRANGER_RELABEL( diff --git a/subworkflows/local/xeniumranger_resegment_morphology_ome_tif/main.nf b/subworkflows/local/xeniumranger_resegment_morphology_ome_tif/main.nf index 6de384e3..fce90bb6 100644 --- a/subworkflows/local/xeniumranger_resegment_morphology_ome_tif/main.nf +++ b/subworkflows/local/xeniumranger_resegment_morphology_ome_tif/main.nf @@ -11,9 +11,8 @@ workflow XENIUMRANGER_RESEGMENT_MORPHOLOGY_OME_TIF { main: - ch_versions = Channel.empty() - ch_redefined_bundle = Channel.empty() - ch_coordinate_space = Channel.value("pixels") + ch_redefined_bundle = channel.empty() + ch_coordinate_space = channel.value("pixels") // run resegment with changed config values XENIUMRANGER_RESEGMENT(ch_bundle_path) @@ -58,5 +57,4 @@ workflow XENIUMRANGER_RESEGMENT_MORPHOLOGY_OME_TIF { emit: redefined_bundle = ch_redefined_bundle // channel: [ val(meta), ["redefined-xenium-bundle"] ] coordinate_space = ch_coordinate_space // channel: [ ["pixels"] ] - versions = ch_versions // channel: [ versions.yml ] } diff --git a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test index 68718e4f..897d6681 100644 --- a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test +++ b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test @@ -40,9 +40,9 @@ nextflow_function { } } - test("Test Function checkCondaChannels") { + test("Test Function checkCondachannels") { - function "checkCondaChannels" + function "checkCondachannels" then { assertAll( diff --git a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test.snap b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test.snap index e3f0baf4..f03a352a 100644 --- a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test.snap +++ b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.function.nf.test.snap @@ -9,7 +9,7 @@ }, "timestamp": "2024-02-28T12:02:05.308243" }, - "Test Function checkCondaChannels": { + "Test Function checkCondachannels": { "content": null, "meta": { "nf-test": "0.8.4", diff --git a/tests/coordinate_mode.nf.test b/tests/coordinate_mode.nf.test index b6240f32..51623327 100644 --- a/tests/coordinate_mode.nf.test +++ b/tests/coordinate_mode.nf.test @@ -5,7 +5,7 @@ nextflow_pipeline { tag "pipeline" config "../conf/test_coordinate_mode.config" - test("-profile test") { + test("-profile test stub") { options "-stub" diff --git a/tests/coordinate_mode.nf.test.snap b/tests/coordinate_mode.nf.test.snap index 6e10be9d..828fe335 100644 --- a/tests/coordinate_mode.nf.test.snap +++ b/tests/coordinate_mode.nf.test.snap @@ -1,5 +1,5 @@ { - "-profile test": { + "-profile test stub": { "content": [ { "PROSEG2BAYSOR": { diff --git a/tests/default.nf.test b/tests/default.nf.test index f1ef2bcf..1e6301e7 100644 --- a/tests/default.nf.test +++ b/tests/default.nf.test @@ -5,7 +5,7 @@ nextflow_pipeline { tag "pipeline" config "../conf/test.config" - test("-profile test") { + test("-profile test stub") { options "-stub" diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index 134212cb..b913b700 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -1,5 +1,5 @@ { - "-profile test": { + "-profile test stub": { "content": [ { "PROSEG2BAYSOR": { diff --git a/tests/image_mode.nf.test b/tests/image_mode.nf.test index dec9adaf..000faeb9 100644 --- a/tests/image_mode.nf.test +++ b/tests/image_mode.nf.test @@ -5,7 +5,7 @@ nextflow_pipeline { tag "pipeline" config "../conf/test_image_mode.config" - test("-profile test") { + test("-profile test stub") { options "-stub" diff --git a/tests/image_mode.nf.test.snap b/tests/image_mode.nf.test.snap index 2512e272..50366f0a 100644 --- a/tests/image_mode.nf.test.snap +++ b/tests/image_mode.nf.test.snap @@ -1,5 +1,5 @@ { - "-profile test": { + "-profile test stub": { "content": [ { "BAYSOR_PREPROCESS_TRANSCRIPTS": { diff --git a/tests/nextflow.config b/tests/nextflow.config index 21d5c006..eff6fcbb 100644 --- a/tests/nextflow.config +++ b/tests/nextflow.config @@ -4,7 +4,6 @@ ======================================================================================== */ -// TODO nf-core: Specify any additional parameters here // Or any resources requirements params { modules_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/' diff --git a/tests/preview_mode.nf.test b/tests/preview_mode.nf.test index 39fbb8c5..fe206319 100644 --- a/tests/preview_mode.nf.test +++ b/tests/preview_mode.nf.test @@ -5,7 +5,7 @@ nextflow_pipeline { tag "pipeline" config "../conf/test_preview_mode.config" - test("-profile test") { + test("-profile test stub") { options "-stub" diff --git a/tests/preview_mode.nf.test.snap b/tests/preview_mode.nf.test.snap index 0f542673..e1c92907 100644 --- a/tests/preview_mode.nf.test.snap +++ b/tests/preview_mode.nf.test.snap @@ -1,5 +1,5 @@ { - "-profile test": { + "-profile test stub": { "content": [ { "BAYSOR_CREATE_DATASET": { @@ -45,17 +45,16 @@ "preview/untar/test_run/morphology.ome.tif", "preview/untar/test_run/transcripts.parquet", "preview/utility", + "preview/utility/parquet_to_csv", + "preview/utility/parquet_to_csv/test_run", + "preview/utility/parquet_to_csv/test_run/transcripts.parquet.csv", "preview/utility/preview_data", "preview/utility/preview_data/test_run", "preview/utility/preview_data/test_run/gene_structure_mqc.tsv", "preview/utility/preview_data/test_run/noise_distribution_mqc.tsv", "preview/utility/preview_data/test_run/noise_level_mqc.png", "preview/utility/preview_data/test_run/transcript_plots_mqc.png", - "preview/utility/preview_data/test_run/umap_mqc.tsv", - "preview/utility/spatialconverter", - "preview/utility/spatialconverter/parquet_to_csv", - "preview/utility/spatialconverter/parquet_to_csv/test_run", - "preview/utility/spatialconverter/parquet_to_csv/test_run/transcripts.parquet.csv" + "preview/utility/preview_data/test_run/umap_mqc.tsv" ], [ "sampled_transcripts.csv:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -67,18 +66,18 @@ "gene_panel.json:md5,d41d8cd98f00b204e9800998ecf8427e", "morphology.ome.tif:md5,d41d8cd98f00b204e9800998ecf8427e", "transcripts.parquet:md5,d41d8cd98f00b204e9800998ecf8427e", + "transcripts.parquet.csv:md5,d41d8cd98f00b204e9800998ecf8427e", "gene_structure_mqc.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "noise_distribution_mqc.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "noise_level_mqc.png:md5,d41d8cd98f00b204e9800998ecf8427e", "transcript_plots_mqc.png:md5,d41d8cd98f00b204e9800998ecf8427e", - "umap_mqc.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "transcripts.parquet.csv:md5,d41d8cd98f00b204e9800998ecf8427e" + "umap_mqc.tsv:md5,d41d8cd98f00b204e9800998ecf8427e" ] ], - "timestamp": "2026-04-29T19:23:42.749448196", + "timestamp": "2026-04-30T19:00:29.84624323", "meta": { "nf-test": "0.9.5", - "nextflow": "25.10.4" + "nextflow": "26.04.0" } } } \ No newline at end of file diff --git a/tests/segfree_mode.nf.test b/tests/segfree_mode.nf.test index ece296bd..2319b6e2 100644 --- a/tests/segfree_mode.nf.test +++ b/tests/segfree_mode.nf.test @@ -5,7 +5,7 @@ nextflow_pipeline { tag "pipeline" config "../conf/test_segfree_mode.config" - test("-profile test") { + test("-profile test stub") { options "-stub" diff --git a/tests/segfree_mode.nf.test.snap b/tests/segfree_mode.nf.test.snap index bb13b3ea..98326c02 100644 --- a/tests/segfree_mode.nf.test.snap +++ b/tests/segfree_mode.nf.test.snap @@ -1,5 +1,5 @@ { - "-profile test": { + "-profile test stub": { "content": [ { "BAYSOR_PREPROCESS_TRANSCRIPTS": { diff --git a/workflows/spatialxe.nf b/workflows/spatialxe.nf index 28dafede..71047930 100644 --- a/workflows/spatialxe.nf +++ b/workflows/spatialxe.nf @@ -43,7 +43,7 @@ include { XENIUMRANGER_IMPORT_SEGMENTATION_REDEFINE_BUNDLE } from '../subworkflo // spatialdata subworkflows include { SPATIALDATA_WRITE_META_MERGE } from '../subworkflows/local/spatialdata_write_meta_merge/main' -// TODO qc layer subworkflows +// qc layer subworkflows include { OPT_FLIP_TRACK_STAT } from '../subworkflows/local/opt_flip_track_stat/main' /* @@ -64,29 +64,29 @@ workflow SPATIALXE { ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ - ch_versions = Channel.empty() - - ch_input = Channel.empty() - ch_config = Channel.empty() - ch_features = Channel.value([]) - ch_raw_bundle = Channel.empty() - ch_gene_panel = Channel.empty() - ch_qc_reports = Channel.empty() - ch_bundle_path = Channel.empty() - ch_preview_html = Channel.empty() - ch_exp_metadata = Channel.empty() - ch_gene_synonyms = Channel.empty() - ch_multiqc_files = Channel.empty() - ch_multiqc_report = Channel.empty() - ch_qupath_polygons = Channel.empty() - ch_morphology_image = Channel.empty() - ch_redefined_bundle = Channel.empty() - ch_coordinate_space = Channel.empty() - ch_panel_probes_fasta = Channel.empty() - ch_transcripts_file = Channel.empty() - ch_reference_annotations = Channel.empty() - ch_multiqc_pre_xr_report = Channel.empty() - ch_multiqc_post_xr_report = Channel.empty() + ch_versions = channel.empty() + + ch_input = channel.empty() + ch_config = channel.empty() + ch_features = channel.value([]) + ch_raw_bundle = channel.empty() + ch_gene_panel = channel.empty() + ch_qc_reports = channel.empty() + ch_bundle_path = channel.empty() + ch_preview_html = channel.empty() + ch_exp_metadata = channel.empty() + ch_gene_synonyms = channel.empty() + ch_multiqc_files = channel.empty() + ch_multiqc_report = channel.empty() + ch_qupath_polygons = channel.empty() + ch_morphology_image = channel.empty() + ch_redefined_bundle = channel.empty() + ch_coordinate_space = channel.empty() + ch_panel_probes_fasta = channel.empty() + ch_transcripts_file = channel.empty() + ch_reference_annotations = channel.empty() + ch_multiqc_pre_xr_report = channel.empty() + ch_multiqc_post_xr_report = channel.empty() /* @@ -95,7 +95,6 @@ workflow SPATIALXE { ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ - // TODO: Replace with params.test_data_mode for robustness if (workflow.profile.contains('test')) { // get sample, xenium bundle and image path @@ -191,7 +190,7 @@ workflow SPATIALXE { } // get baysor xenium config - ch_config = Channel.fromPath( + ch_config = channel.fromPath( "${projectDir}/assets/config/xenium.toml", checkIfExists: true ) @@ -199,7 +198,7 @@ workflow SPATIALXE { // get segmentation mask if provided with --segmentation_mask for the baysor method if (params.segmentation_mask) { - ch_segmentation_mask = Channel.fromPath( + ch_segmentation_mask = channel.fromPath( params.segmentation_mask, checkIfExists: true ) @@ -208,12 +207,12 @@ workflow SPATIALXE { // get a list of features if provided with the --features for the ficture method ch_features = params.features - ? Channel.fromPath(params.features, checkIfExists: true).flatten() - : Channel.value([]) + ? channel.fromPath(params.features, checkIfExists: true).flatten() + : channel.value([]) // get custom cellpose model if provided with the --cellpose_model for the cellpose method if (params.cellpose_model) { - ch_cellpose_model = Channel.fromPath( + ch_cellpose_model = channel.fromPath( params.cellpose_model, checkIfExists: true ) @@ -222,7 +221,7 @@ workflow SPATIALXE { // get panel probes fasta for off-target-probe tracking if (params.probes_fasta) { - ch_panel_probes_fasta = Channel.fromPath( + ch_panel_probes_fasta = channel.fromPath( params.probes_fasta, checkIfExists: true ) @@ -231,7 +230,7 @@ workflow SPATIALXE { // get reference annotation files (gff,fa) for off-target-probe tracking if (params.reference_annotations) { - ch_reference_annotations = Channel.fromPath( + ch_reference_annotations = channel.fromPath( "${params.reference_annotations}/*.{fa,gff}".toString(), checkIfExists: true ) @@ -240,7 +239,7 @@ workflow SPATIALXE { // get gene synonyms for off-target-probe tracking if (params.gene_synonyms) { - ch_gene_synonyms = Channel.fromPath( + ch_gene_synonyms = channel.fromPath( params.gene_synonyms, checkIfExists: true ) @@ -249,7 +248,7 @@ workflow SPATIALXE { // get qupath ploygons if (params.qupath_polygons) { - ch_qupath_polygons = Channel.fromPath( + ch_qupath_polygons = channel.fromPath( "${params.qupath_polygons}/*.geojson", checkIfExists: true ) @@ -443,7 +442,7 @@ workflow SPATIALXE { "For tiled Baysor, use baysor_prior='cells' (column-based)." } - ch_prior_mask = Channel.empty() + ch_prior_mask = channel.empty() BAYSOR_RUN_TRANSCRIPTS_PARQUET( ch_bundle_path, @@ -549,18 +548,18 @@ workflow SPATIALXE { SPATIALXE - MultiQC ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ - ch_multiqc_config = Channel.fromPath( + ch_multiqc_config = channel.fromPath( "${projectDir}/assets/multiqc_config.yml", checkIfExists: true ) ch_multiqc_custom_config = params.multiqc_config - ? Channel.fromPath(params.multiqc_config, checkIfExists: true) - : Channel.empty() + ? channel.fromPath(params.multiqc_config, checkIfExists: true) + : channel.empty() ch_multiqc_logo = params.multiqc_logo - ? Channel.fromPath(params.multiqc_logo, checkIfExists: true) - : Channel.empty() + ? channel.fromPath(params.multiqc_logo, checkIfExists: true) + : channel.empty() // Combine default and custom configs into a single list for the tuple-based MULTIQC input ch_multiqc_configs = ch_multiqc_config.mix(ch_multiqc_custom_config).collect() @@ -570,7 +569,7 @@ workflow SPATIALXE { parameters_schema: "nextflow_schema.json" ) - ch_workflow_summary = Channel.value(paramsSummaryMultiqc(summary_params)) + ch_workflow_summary = channel.value(paramsSummaryMultiqc(summary_params)) ch_multiqc_files = ch_multiqc_files.mix( ch_workflow_summary.collectFile(name: 'workflow_summary_mqc.yaml') @@ -580,7 +579,7 @@ workflow SPATIALXE { ? file(params.multiqc_methods_description, checkIfExists: true) : file("${projectDir}/assets/methods_description_template.yml", checkIfExists: true) - ch_methods_description = Channel.value( + ch_methods_description = channel.value( methodsDescriptionText(ch_multiqc_custom_methods_description) ) @@ -636,7 +635,6 @@ workflow SPATIALXE { // get the qc htmls if qc mode is run if (params.mode == 'qc' || params.run_qc) { - // TODO collect all qc outs in a channel to be passed to multiqc ch_multiqc_files = ch_multiqc_files.mix( ch_qc_reports.map { _meta, qc_reports -> qc_reports }.collect().ifEmpty([]) )