Zoom
- class CVAugmentor.assets.augmentations._zoom.Zoom(zoom_size: tuple[int | float, int | float] | None = None)
Zoom an image by a specified or a random size.
Usage
The class instance must be called.
- __init__(zoom_size: tuple[int | float, int | float] | None = None) None
Constructor of the Zoom class.
- Parameters:
zoom_size (tuple, optional) – Size of the zoom as (width, height). The default value to None. If None, a random zoom size will be used.
- Return type:
None.
- _zoom(image: Image) Image
The zoom operation.
- Parameters:
image (Image.Image) – The image to be augmented.
- Returns:
zoomed_image – The zoomed image.
- Return type:
Image.Image