ConstantsAugmentation
- class lib.training.data.augmentation.ConstantsAugmentation(color: ConstantsColor, transform: ConstantsTransform, warp: ConstantsWarp)
Bases:
objectDataclass for holding constants for Image Augmentation.
- Parameters:
color (ConstantsColor)
transform (ConstantsTransform)
warp (ConstantsWarp)
- color
The constants for adjusting color/contrast in an image
- transform
The constants for image transformation
- warp
The constants for image warping
- Dataclass should be initialized using its :func:`from_config` method
Example
>>> constants = ConstantsAugmentation.from_config(processing_size=256, ... batch_size=16)
Methods Summary
from_config(processing_size, batch_size)Create a new dataclass instance from user config
Methods Documentation
- classmethod from_config(processing_size: int, batch_size: int) ConstantsAugmentation
Create a new dataclass instance from user config
- Parameters:
processing_size (int) – The size of image to augment the data for
batch_size (int) – The batch size that augmented data is being prepared for
- Return type:
- color: ConstantsColor = <dataclasses._MISSING_TYPE object>
The constants for adjusting color/contrast in an image
- classmethod from_config(processing_size: int, batch_size: int) ConstantsAugmentation
Create a new dataclass instance from user config
- Parameters:
processing_size (int) – The size of image to augment the data for
batch_size (int) – The batch size that augmented data is being prepared for
- Return type:
- transform: ConstantsTransform = <dataclasses._MISSING_TYPE object>
The constants for image transformation
- warp: ConstantsWarp = <dataclasses._MISSING_TYPE object>
The constants for image warping