Skip to content

Commit

Permalink
Merge pull request #781 from MouseLand/SimonBon-min_size_fix
Browse files Browse the repository at this point in the history
Simon bon min size fix
  • Loading branch information
carsen-stringer committed Sep 13, 2023
2 parents 9f1c6e1 + da6201c commit a097ecc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cellpose/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,8 @@ def _run_cp(self, x, compute_masks=True, normalize=True, invert=False,
resize = [shape[1], shape[2]] if not resample else None
for i in iterator:
outputs = dynamics.compute_masks(dP[:,i], cellprob[i], niter=niter, cellprob_threshold=cellprob_threshold,
flow_threshold=flow_threshold, interp=interp, resize=resize,
flow_threshold=flow_threshold, interp=interp, resize=resize,
min_size=min_size if stitch_threshold==0 or nimg==1 else -1, # turn off for 3D stitching
use_gpu=self.gpu, device=self.device)
masks.append(outputs[0])
p.append(outputs[1])
Expand Down

0 comments on commit a097ecc

Please sign in to comment.