ToolPythonBeginner
Counting cells with scipy.ndimage: how many are there, and how large?
- labels, n = ndi.label(mask)
- print(f"regions without the opening: {ndi.label(raw_mask)[1]}")
- markers, n_markers = ndi.label(ndi.binary_dilation(peaks, iterations=3))
- print(f"groups of top pixels: {ndi.label(peaks)[1]}, markers after growing: {n_markers}")
- lab, k = ndi.label(ndi.binary_opening(smooth > t, structure=disk))
- lab, k = ndi.label(ndi.binary_opening(smooth_steep > 0.6, structure=disk))
and 4 more lines in this tutorial