Image.__floordiv__#

Image.__floordiv__(other) Image[source][source]#

Overloaded // operator

Returns:

element-wise floored division of images

Return type:

Image

Compute the integer quotient of an Image with another image or a scalar. Supports:

  • image // image

  • scalar // image

  • image // scalar

Example:

>>> from machinevisiontoolbox import Image
>>> img = Image([[1, 2], [3, 4]])
>>> z = img / 2
>>> z.array
array([[0.5, 1. ],
       [1.5, 2. ]], dtype=float32)
>>> z = img // 2
>>> z.array
array([[0, 1],
       [1, 2]], dtype=uint8)