Image-Py / cellpose-planer

cellpose on planer framework, light and fast!

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

implement the cell diameter parameter

marius10p opened this issue · comments

The default Cellpose models are optimized for an average cell diameter of 30 pixels. Results can be really bad if the cell diameter is significantly larger or smaller than this.

did you mean the image should be zoomed to make sure the object 30 diameter? then input the models?

def get_flow(nets, img, cn=[0,0], sample=1, size=512, tile=True, work=1, callback=progress)

  • nets: the nets loaded upon.

  • img: the image to process

  • cn: the cytoplasm and nucleus channels

  • sample: if not 1, we scale it. (only avalible when tile==True)

  • size: when tile==True, this is the tile size, when tile==False, we scale the image to size.

  • tile: if True, method try to process image in tiles. else resize the image.

  • work: open multi-thread to process the image. (GPU not recommend)

now some parameter added.

in tile mode: the input image would scale by sample factor, then use the size as tile.

in no tile mode: sample disabled, the input image would be scale to size x size.