machinevisiontoolbox.Image.blue

Image.blue()[source]

Extract the blue plane of a color image

Raises:

ValueError – if image is not color

Return out:

greyscale image representing the blue image plane

Return type:

Image

Example:

>>> from machinevisiontoolbox import Image
>>> img = Image.Read("flowers4.png")
>>> blue = img.blue() # blue plane
>>> blue.disp()
<matplotlib.image.AxesImage object at 0x7fcd39b37340>
>>> blue
Image: 640 x 426 (uint8)
>>> blue.iscolor
False

(Source code, png, hires.png, pdf)

../_images/machinevisiontoolbox-Image-blue-1.png
Seealso:

plane red green