Function ndarray_ndimage::binary_opening
source · pub fn binary_opening<SM, SK>(
mask: &ArrayBase<SM, Ix3>,
kernel: &ArrayBase<SK, Ix3>,
iterations: usize
) -> Maskwhere
SM: Data<Elem = bool>,
SK: Data<Elem = bool>,Expand description
Binary opening of a 3D binary image.
The opening of an input image by a structuring element is the dilation of the erosion of the image by the structuring element.
Unlike other libraries, the border values of the:
- dilation is always
false, to avoid dilating the borders - erosion is always
true, to avoid border effects
mask- Binary image to be opened.kernel- Structuring element used for the opening.iterations- The erosion step of the opening, then the dilation step are each repeated iterations times.