Python: 多维图像的洪水填充

Python: flood filling of multidimensional image

我有一个二进制多维图像。我想获得一些 flood fill 的实现,这将给我下一个:

  1. 连接区域列表(相邻像素的值为 True)。

  2. 对于每个区域,我想获取其边界框和互连区域中所有像素的像素坐标列表。

有类似的实现吗?

见鬼! scipy.ndimage.measurements 模块有帮助!