bundles / skimage latest / skimage / morphology / _misc_cy / _remove_objects_by_distance
fused_cython_function
skimage.morphology._misc_cy:_remove_objects_by_distance
Signature
def _remove_objects_by_distance ( out , border_indices , inner_indices , kdtree , p_norm , min_distance , shape ) Summary
Remove objects, in specified order, until remaining are a minimum distance apart.
Extended Summary
Remove labeled objects from an image until the remaining ones are spaced more than a given distance from one another. By default, smaller objects are removed first.
Parameters
outAn array with labels for each object in
imagematching it in shape.border_indices, inner_indicesIndices into
outfor the border of objects (border_indices) and the inner part of objects (inner_indices).border_indicesdetermines the iteration order; objects that are indexed first are preserved. Indices must be sorted such, that indices pointing to the same object are next to each other.kdtree: scipy.spatial.cKDTreeA KDTree containing the coordinates of all objects in
image.min_distanceThe minimal allowed distance between objects.
p_normThe Minkowski p-norm used to calculate the distance between objects. Defaults to 2 which corresponds to the Euclidean distance.
shapeThe shape of the unraveled
image.
Aliases
-
skimage.morphology._misc_cy._remove_objects_by_distance