local_threshold_isodata#

isodata_grid_sliding_xy(src, out_grid, wx, wy, wz, sx, sy, sz, max_bin)#

src: float volume, but representing quantized values in [0..max_bin-1] (or close). out_grid: coarse grid of thresholds, shape must match (nx//sx, ny//sy, nz//sz) or whatever you decide in Python. wx,wy,wz: window sizes (selem) sx,sy,sz: spacing between centers max_bin: e.g. 4096