dvpio.read.image.read_openslide

Contents

dvpio.read.image.read_openslide#

dvpio.read.image.read_openslide(path, chunk_size=(10000, 10000), pyramidal=True)#

Read WSI to Image2DModel

Uses openslide to read multiple pathology slide representations and parse them to a lazy dask array. Currently supported formats

Tested

  • .mirax (Mirax format)

In principle supported by openslide:

  • Aperio (.svs, .tif)

  • DICOM (.dcm)

  • Hamamatsu (.ndpi, .vms, .vmu)

  • Leica (.scn)

  • MIRAX (.mrxs)

  • Philips (.tiff)

  • Sakura (.svslide)

  • Trestle (.tif)

  • Ventana (.bif, .tif)

  • Generic tiled TIFF (.tif)

We recommend to use the read_czi function for this format

  • Zeiss (.czi)

Parameters:
  • path (str) – Path to file

  • chunk_size (tuple[int, int] (default: (10000, 10000))) – Size of the individual regions that are read into memory during the process in format (x, y)

  • pyramidal (bool (default: True)) – Whether to create a pyramidal image with same scales as original image

Return type:

Image2DModel

Returns:

spatialdata.models.Image2DModel