machinevisiontoolbox.Image.endpoint
- Image.endpoint(**kwargs)
Find end points on a binary skeleton image
- Parameters:
kwargs – options passed to
hitormiss
- Returns:
Image
- Return type:
Image
instance
Return a binary image where pixels are True if the corresponding pixel in the binary image is the end point of a single-pixel wide line such as found in an image skeleton.
Example:
>>> from machinevisiontoolbox import Image >>> img = Image.String('000000|011110|000000') >>> img.print() 0 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 0 >>> img.endpoint().print() 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0
- Note:
Computed using the hit-or-miss morphological operator.
- References:
Robotics, Vision & Control for Python, Section 11.6.3, P. Corke, Springer 2023.
- Seealso: