Support homeAtera Instrument SoftwareAnalysis
Cell Segmentation Zarr Output File

Cell Segmentation Zarr Output File

The Atera Onboard Analysis pipeline generates one output file with cell and nucleus segmentation data.

Back to cell and transcript output file landing page

The cells.zarr.zip output file contains the cell and nucleus segmentation masks used for transcript assignment and the polygon boundaries used for visualization. It is the only file in the output bundle where you can find the cell and nucleus segmentation data.

The masks in the cell Zarr file can be used for downstream cell segmentation or morphology analysis. The polygons are a simplification of the true segmentation masks and are only intended for data visualization (i.e., in 10x Explorer).

It has the following hierarchy of array data:

(root) ├── bboxes ├── cell_id ├── cell_summary ├── gridded_polygon_sets ├── 0 │ ├── 0 │ │ ├── 0,4 │ │ │ ├── cell_index │ │ │ ├── num_vertices │ │ │ └── relative_vertices │ │ ├── 1 │ │ ├── 2 │ │ ├── 3 │ │ └── 4 │ └── 1 ├── masks │ ├── 0 │ ├── 1 │ └── homogeneous_transform └── polygon_sets ├── 0 │ ├── cell_index │ ├── method │ ├── num_vertices │ └── vertices └── 1 ├── cell_index ├── method ├── num_vertices └── vertices

Description of root group attributes:

FieldTypeDescription
has_gridded_polygon_setsboolTrue
major_versionintMajor version for this file. This number is increased when breaking changes are made.
minor_versionintThe minor file format version.
namestrCellSegmentationDataset
number_cellsintThe number of cells in the dataset.
polygon_set_descriptionslist[str]Each element is the description of a polygon set in 10x Explorer (e.g., "DAPI-based nuclei segmentation", "Cell Segmentation").
polygon_set_display_nameslist[str]Each element is the display name of a polygon set in 10x Explorer (e.g., "Nucleus boundaries", "Cell boundaries").
polygon_set_nameslist[str]Each element is the unique, machine-readable name of a polygon set (e.g., a single polygon associated with nuclei is called "nucleus").
segmentation_methodslist[str]Describes how a polygon's boundary was generated (e.g., cell segmentation methods: "Segmented by boundary stain (ATP1A1+CD45+E-Cadherin)", "Segmented by interior stain (18S)", "Segmented by nucleus expansion of 5.0µm", "Segmented by nuclear stain (DAPI) multi-focus", "Segmented by nuclear stain (DAPI) z stack", "Segmented by boundary stain at 0.25x (ATP1A1+CD45+E-Cadherin)", "Imported Cell Segmentation", "Imported Nucleus Segmentation").
spatial_unitsstrThe units of the stitched image space ("microns").

Description of the /cell_summary array attribute columns (float64):

column_namescolumn_descriptions
cell_centroid_xX coordinate of the cell centroid in µm.
cell_centroid_yY coordinate of the cell centroid in µm.
cell_areaThe two-dimensional area covered by the cell in µm2.
nucleus_centroid_xX coordinate of the nucleus centroid in µm.
nucleus_centroid_yY coordinate of the nucleus centroid in µm.
nucleus_areaThe two-dimensional area covered by the nucleus in µm2.
z_levelZ-level in which the cell was found in µm.
nucleus_countNumber of nuclei associated with this cell.

Description of root-level arrays:

PathTypeDescription
/bboxesfloat32Describes the bounding box containing the corresponding cell and nucleus polygons for each cell index. It is used by the gridded_polygon_sets.
/cell_iduint32The first column consists of the cell_id prefix, and the second column is the dataset suffix.
/cell_summaryfloat64Contains information about each cell (see attributes).
/gridded_polygon_setsn/aThe tiled, pyramided version of the polygon_sets object.
/masksn/aContains masks for the nucleus and cell segmentations in image space.
/polygon_setsn/aContains polygons for the nucleus and cell segmentations in physical space.

Description of segmentation /gridded_polygon_sets arrays:

PathTypeDescription
[gridded polygon set index]uint32The gridded_polygon_sets=0 contains the gridded nucleus segmentation polygons and the gridded_polygon_sets=1 contains the gridded cell segmentation polygons
cell_indexuint32An integer for the original cell index of the polygon in the tile.
num_verticesint32The number of vertices for each polygon in the tile.
relative_verticesuint8A flat array of vertex coordinates for all polygons in the tile, scaled to the polygon's bounding box. Use num_vertices to split the array into individual polygons. Unlike polygon_sets, each polygon here does not repeat its first vertex at the end.

Description of segmentation /masks arrays:

PathTypeDescription
[mask_index]uint32The mask_index=0 is the nucleus segmentation mask and the mask_index=1 is the cell segmentation mask. The arrays at these indices contain the masks and have a 2D shape (rows, columns) of the morphology image that segmentation was performed on. Non-zero pixel values are the instance label ID, which can also be found in the cell and nucleus boundaries files. Pixels with value=0 are background. For cell masks, the label ID is equal to the cell index + 1.
homogeneous_transformfloat32The 4x4 transform matrix used to convert data from physical space (microns) to stitched-image space (pixels). This is needed to generate polygons from the masks.

Description of segmentation /polygon_sets arrays:

PathTypeDescription
[polygon_sets_index]uint32The polygon_sets_index=0 contains the nucleus segmentation polygons and the polygon_sets_index=1 contains the cell segmentation polygons. Polygons are stored in order of increasing instance label ID.
cell_indexuint32An index for the cell that is associated with each nucleus or cell polygon. It corresponds to the root/cell_id. Each element in cell_index corresponds to an instance label ID in masks/i.
methoduint32An integer value describing the segmentation method used to derive this polygon. The integer corresponds to the order of methods listed in the root segmentation_methods attribute (starts at 0).
num_verticesint32Each element is the number of vertices for a given polygon, including a repeat of the initial vertex. A polygon with no vertices indicates the absence of a polygon for that cell.
verticesfloat32The XY coordinates in physical space (µm) for each vertex in the polygon. The coordinates for the first vertex are repeated at the end.