sample_scaled(shape) -> bounding_box

    Yields an iterator that iterates over all sampled bounding boxes in the given (scaled) image shape.

    **Parameters:**

    ``shape`` : (int, int) or (int, int, int)
      The (current) shape of the (scaled) image

    **Yields:**

    ``bounding_box`` : :py:class:`BoundingBox`
      An iterator iterating over all bounding boxes that are valid for the given shape

def sample_scaled(self, shape):
    """sample_scaled(shape) -> bounding_box

    Yields an iterator that iterates over all sampled bounding boxes in the given (scaled) image shape.

    **Parameters:**

    ``shape`` : (int, int) or (int, int, int)
      The (current) shape of the (scaled) image

    **Yields:**

    ``bounding_box`` : :py:class:`BoundingBox`
      An iterator iterating over all bounding boxes that are valid for the given shape
    """
    for y in range(0, shape[-2]-self.m_patch_box.bottomright[0], self.m_distance):
      for x in range(0, shape[-1]-self.m_patch_box.bottomright[1], self.m_distance):
        # create bounding box for the current shift
        yield self.m_patch_box.shift((y,x))