PrecomputedTissueMask
.npy (loaded via numpy.load).
The loaded mask is binarised (non-zero → 1) and returned as uint8 (H, W).
Directory containing mask files.
Expected file extension including the dot (e.g.
".png"). When None (default), the provider searches for the first file in mask_dir whose stem matches the slide name, trying all supported extensions.FileNotFoundError- Atgeneratetime if no matching mask file is found for a slide.
generate
reader.path, finds the corresponding file in mask_dir, loads and binarises it.
An open WSI reader.
Ignored for pre-computed masks (kept for interface compatibility).
np.ndarray- Auint8mask of shape(H, W)with values in{0, 1}where1= tissue / region of interest.
FileNotFoundError- If no mask file is found for the slide.

