Skip to main content
The tissue segmentation model identifies tissue regions in a slide, letting you discard background tiles before running H-Optimus or M-Optimus. It is bundled with both model packages.

Specifications

PropertyValue
TaskBinary tissue mask
Input512×512 RGB tile at 8.0 µm/px
OutputFlattened binary mask of length 262,144 (512×512), values 0.0 or 1.0
SageMaker dispatchmodel_name: "tissue-seg", mode: "prediction"
Recommended instanceml.g5.xlarge
Run segmentation at the coarse 8.0 µm/px resolution first; it is cheap relative to per-tile feature extraction at 0.5 µm/px and can dramatically reduce the number of tiles you embed.

Reshaping the output

The endpoint returns a flat array. Reshape it to a 512×512 mask:
import numpy as np

mask = np.array(result["output"]).reshape(512, 512)

Deploy

Tissue segmentation has no separate deployment — it is bundled with both the H-Optimus and M-Optimus packages and served from the same endpoint. Deploy either model and tissue-seg is available alongside it.

AWS & SageMaker

Production endpoints (bundled with H-Optimus / M-Optimus).

On-premise

Self-hosted container (bundled with each package).

Using it in a pipeline

In practice you rarely call this endpoint directly — the SDK’s tissue mask provider generates and caches masks for you, then filters tiles before feature extraction or prediction. See Spatial transcriptomics and the SDK guide.