box_mask#
- box_mask(shape, center, height)[source]#
Creates a box mask centered around the provided center point.
- Parameters:
- shapetuple of ints
Shape of the output array.
- centertuple of ints
Center point coordinates of the box.
- heighttuple of ints
Height (side length) of the box along each axis.
- Returns:
- NDArray
The created box mask.
- Raises:
- ValueError
If
shape
andcenter
do not have the same length. Ifcenter
andheight
do not have the same length.