cut_square_box#
- scarlet2.plot.cut_square_box(arr, center, size)[source]#
Cut out a square box from a 2D array based on the center and size.
Parameters: arr: numpy.ndarray
The input 2D array.
- center: tuple
The center of the box in the format (row_center, col_center).
- size: int
The size of the square box (side length).
- Returns:
numpy.ndarray: The square box extracted from the input array.