Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Tutorial 6: Pre-stitched image

When to use

Your images were stitched elsewhere and you only want segmentation, quantification and QC. The run starts at the SpatialData store: no illumination correction, stitching, dearray or background subtraction. The example below is made up; adapt it to your images.

The samplesheet

One row per image:

sampledata_path
slideA/data/myproject/stitched/slideA.ome.tif
slideB/data/myproject/stitched/slideB.ome.tif
Copy as CSV: samplesheet.csv
sample,data_path
slideA,/data/myproject/stitched/slideA.ome.tif
slideB,/data/myproject/stitched/slideB.ome.tif

Columns: The samplesheet.

The parameters

Save as params.yml:

input: /data/myproject/sheets/samplesheet.csv
outdir: /data/myproject/results

use_preprocessing: false

use_cellpose: true
cellpose_channels: "CD45 DAPI"

patch_width_pixel: 5000

Run

nextflow run CosciaLab/histo -r v3.2.0 \
    -profile singularity,size_small,slurm \
    -params-file params.yml

See Running on the cluster.

What runs: the SpatialData store, tiled segmentation with Cellpose, quantification and the QC report.

What you get

results/
├── slideA.zarr/
│   ├── images/      the image, channels named as in the file
│   ├── shapes/      image_patches, cellpose_cells
│   └── tables/      cellpose_table
├── slideB.zarr/
├── qc/              slideA_cellpose_qc_report.html, slideB_cellpose_qc_report.html, …
└── pipeline_info/

No preprocessing/. Every file: Outputs.

What to check

  1. “Channels” in the QC report: the names you expect, not Channel:0:0.

  2. “Segmentation overlay” and “Cells per patch”.

  3. The outlines over the image; see Viewers.

Something off? See Common failures.