make_tiles#

cellpose_omni.transforms.make_tiles(imgi, bsize=224, augment=False, tile_overlap=0.1)[source]#

make tiles of image to run at test-time

if augmented, tiles are flipped and tile_overlap=2.
  • original

  • flipped vertically

  • flipped horizontally

  • flipped vertically and horizontally

Parameters
  • imgi (float32) -- array that's nchan x Ly x Lx

  • bsize (float (optional, default 224)) -- size of tiles

  • augment (bool (optional, default False)) -- flip tiles and set tile_overlap=2.

  • tile_overlap (float (optional, default 0.1)) -- fraction of overlap of tiles

Returns

  • IMG (float32) -- array that's ntiles x nchan x bsize x bsize

  • ysub (list) -- list of arrays with start and end of tiles in Y of length ntiles

  • xsub (list) -- list of arrays with start and end of tiles in X of length ntiles