The samplesheet tells the pipeline where your images are. It has one of two shapes, depending on
whether the pipeline should stitch the images (use_preprocessing,
on by default) or they are stitched already.
Cycle sheet¶
For raw images: one row per acquisition cycle. Rows with the same sample are one slide;
the pipeline stitches its cycles together into one image.
| sample | cycle_number | image_tiles | marker_sheet |
|---|---|---|---|
| slide01 | 1 | /data/myproject/raw/slide01/cycle01.ome.tiff | /data/myproject/sheets/markers_slide01.csv |
| slide01 | 2 | /data/myproject/raw/slide01/cycle02.ome.tiff | /data/myproject/sheets/markers_slide01.csv |
| slide02 | 1 | /data/myproject/raw/slide02/cycle01.ome.tiff | /data/myproject/sheets/markers_slide02.csv |
As CSV, to copy
sample,cycle_number,image_tiles,marker_sheet
slide01,1,/data/myproject/raw/slide01/cycle01.ome.tiff,/data/myproject/sheets/markers_slide01.csv
slide01,2,/data/myproject/raw/slide01/cycle02.ome.tiff,/data/myproject/sheets/markers_slide01.csv
slide02,1,/data/myproject/raw/slide02/cycle01.ome.tiff,/data/myproject/sheets/markers_slide02.csvsamplenames the slide and every output file made from it. Letters, digits,.,_and-only.cycle_numberruns 1, 2, 3, … for each sample, with no gaps or repeats. It sets the order in which cycles are stitched, and must match the cycle numbers in the marker sheet.image_tilesis the raw image of that cycle: one file holding all its tiles, or a folder of tiles.marker_sheetis the marker sheet for the sample. Repeat the same file on every row of a sample: it describes the whole stitched image, not one cycle. Two samples may use different sheets, so one run can mix panels.dfpandffp, optional: illumination profiles from an earlier run; see below.
Stitched-image sheet¶
For images stitched elsewhere, with use_preprocessing: false:
one row per image, and no marker sheet.
| sample | data_path |
|---|---|
| slideA | /data/myproject/stitched/slideA.ome.tif |
| slideB | /data/myproject/stitched/slideB.ome.tif |
As CSV, to copy
sample,data_path
slideA,/data/myproject/stitched/slideA.ome.tif
slideB,/data/myproject/stitched/slideB.ome.tifdata_pathis the stitched OME-TIFF, the only format read here.sampleis optional; without it, the file name is used.Channel names come from the image itself. An image without names gets
Channel:0:0, … ; see the Pre-stitched image tutorial.
Path rules¶
Use absolute paths, starting with
/. A relative path is read from wherever the run is launched, which is easy to get wrong.No spaces in any path or sample name. The run stops at startup if there are.
Every file must exist when the run starts; it checks.
Reuse illumination profiles¶
The first step, BaSiCPy, computes an illumination profile per cycle. To reuse profiles from an earlier run instead of computing them again, give them in two extra columns. Within one run folder, resuming already reuses them; this is for a new run.
Find the earlier run’s profiles:
preprocessing/illumination/{sample}_cycle{n}-dfp.ome.tifand-ffp.ome.tif, one pair per cycle.Add
dfpandffpcolumns to the samplesheet, on every cycle row of the sample:sample cycle_number image_tiles dfp ffp marker_sheet slide01 1 /data/raw/slide01/cycle01.ome.tiff /data/run1/preprocessing/illumination/slide01_cycle1-dfp.ome.tif /data/run1/preprocessing/illumination/slide01_cycle1-ffp.ome.tif /data/sheets/markers_slide01.csv slide01 2 /data/raw/slide01/cycle02.ome.tiff /data/run1/preprocessing/illumination/slide01_cycle2-dfp.ome.tif /data/run1/preprocessing/illumination/slide01_cycle2-ffp.ome.tif /data/sheets/markers_slide01.csv Run. BaSiCPy is skipped for those cycles.
Two rules:
Every cycle of a sample, or none. A sample with profiles on only some cycles stops at startup, because the profiles would end up matched to the wrong images.
Same channels, same order. A profile holds one plane per channel of its cycle; reuse it only for a cycle acquired with the same channels in the same order.
Columns¶
Generated from the schemas the run validates against.
Cycle sheet columns¶
One row per acquisition cycle. Rows sharing a sample name are grouped and ordered by cycle_number before stitching. Derived from nf-core/mcmicro’s schema_input_cycle.json.
| Column | Required | Type | Description |
|---|---|---|---|
sample | yes | string | Sample name. Becomes meta.id and is used to group cycles and to name outputs. |
cycle_number | yes | integer | 1-based acquisition cycle. Determines the order in which cycles are passed to Ashlar, and must match the cycle_number column of the marker sheet. Must run 1..N per sample without repeats or gaps: a repeat makes two rows indistinguishable, since a cycle is identified by sample and cycle_number together. JSON Schema validates rows independently and cannot express that, so it is checked by validateCycleNumbers at startup. |
image_tiles | yes | string | Path to the raw image tiles for this cycle: either a single multi-tile file or a directory of tiles. |
dfp | no | string | Optional pre-computed dark-field profile for this cycle. Supply only when skipping BaSiCPy; if given for one cycle it must be given for all. |
ffp | no | string | Optional pre-computed flat-field profile for this cycle. Supply only when skipping BaSiCPy; if given for one cycle it must be given for all. |
marker_sheet | yes | string | Path to the marker sheet for this sample, one row per channel. Every cycle row of a sample must name the same file: the sheet describes the whole stitched image, not one cycle of it. Two samples may name different sheets, which is the point of the column. |
Stitched-image sheet columns¶
Schema for the file provided with params.input
| Column | Required | Type | Description |
|---|---|---|---|
sample | no | string | |
id | no | string | |
data_path | yes | string |