diff --git a/skimage/morphology/binary.py b/skimage/morphology/binary.py index 636717af..d5e0d92b 100644 --- a/skimage/morphology/binary.py +++ b/skimage/morphology/binary.py @@ -18,8 +18,9 @@ def binary_erosion(image, selem=None, out=None): ---------- image : ndarray Binary input image. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. + If None, use cross-shaped structuring element (connectivity=1). out : ndarray of bool The array to store the result of the morphology. If None is passed, a new array will be allocated. @@ -66,9 +67,10 @@ def binary_dilation(image, selem=None, out=None): image : ndarray Binary input image. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray of bool + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray of bool, optional The array to store the result of the morphology. If None, is passed, a new array will be allocated. @@ -113,9 +115,10 @@ def binary_opening(image, selem=None, out=None): ---------- image : ndarray Binary input image. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray of bool + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray of bool, optional The array to store the result of the morphology. If None is passed, a new array will be allocated. @@ -145,9 +148,10 @@ def binary_closing(image, selem=None, out=None): ---------- image : ndarray Binary input image. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray of bool + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray of bool, optional The array to store the result of the morphology. If None, is passed, a new array will be allocated. diff --git a/skimage/morphology/grey.py b/skimage/morphology/grey.py index 7fb1c8c9..e50e1460 100644 --- a/skimage/morphology/grey.py +++ b/skimage/morphology/grey.py @@ -22,12 +22,13 @@ def erosion(image, selem=None, out=None, shift_x=False, shift_y=False): ---------- image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarrays + If None, use cross-shaped structuring element (connectivity=1). + out : ndarrays, optional The array to store the result of the morphology. If None is passed, a new array will be allocated. - shift_x, shift_y : bool + shift_x, shift_y : bool, optional shift structuring element about center point. This only affects eccentric structuring elements (i.e. selem with even numbered sides). @@ -79,12 +80,13 @@ def dilation(image, selem=None, out=None, shift_x=False, shift_y=False): image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray, optional The array to store the result of the morphology. If None, is passed, a new array will be allocated. - shift_x, shift_y : bool + shift_x, shift_y : bool, optional shift structuring element about center point. This only affects eccentric structuring elements (i.e. selem with even numbered sides). @@ -136,9 +138,10 @@ def opening(image, selem=None, out=None): ---------- image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray, optional The array to store the result of the morphology. If None is passed, a new array will be allocated. @@ -191,9 +194,10 @@ def closing(image, selem=None, out=None): ---------- image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray, optional The array to store the result of the morphology. If None, is passed, a new array will be allocated. @@ -245,9 +249,10 @@ def white_tophat(image, selem=None, out=None): ---------- image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. - out : ndarray + If None, use cross-shaped structuring element (connectivity=1). + out : ndarray, optional The array to store the result of the morphology. If None is passed, a new array will be allocated. @@ -299,8 +304,9 @@ def black_tophat(image, selem=None, out=None): ---------- image : ndarray Image array. - selem : ndarray + selem : ndarray, optional The neighborhood expressed as a 2-D array of 1's and 0's. + If None, use cross-shaped structuring element (connectivity=1). out : ndarray The array to store the result of the morphology. If None is passed, a new array will be allocated.