centercrop
-
Description: Performs a center crop on the input image.
-
Parameters
- img (
np.ndarray): The input image to be center-cropped.
- img (
-
Returns
- np.ndarray: The cropped image.
-
Example
from capybara import imread, imresize
from capybara.vision.functionals import centercrop
img = imread('lena.png')
img = imresize(img, [128, 256])
crop_img = centercrop(img)The green box represents the center-crop region.
