fishy.data.augmentation

Data augmentation module for the deep learning pipeline.

Classes

class fishy.data.augmentation.AugmentationConfig(enabled: bool = False, num_augmentations: int = 5, noise_enabled: bool = True, shift_enabled: bool = False, scale_enabled: bool = False, crop_enabled: bool = False, flip_enabled: bool = False, permutation_enabled: bool = False, noise_level: float = 0.1, shift_range: float = 0.1, scale_range: float = 0.1, crop_size: float = 0.8)[source]

Bases: object

Configuration for data augmentation.

Examples

>>> config = AugmentationConfig(enabled=True, num_augmentations=10)
>>> config.enabled
True
>>> config.num_augmentations
10
__init__(enabled: bool = False, num_augmentations: int = 5, noise_enabled: bool = True, shift_enabled: bool = False, scale_enabled: bool = False, crop_enabled: bool = False, flip_enabled: bool = False, permutation_enabled: bool = False, noise_level: float = 0.1, shift_range: float = 0.1, scale_range: float = 0.1, crop_size: float = 0.8) None[source]
crop_enabled: bool = False
crop_size: float = 0.8
enabled: bool = False
flip_enabled: bool = False
noise_enabled: bool = True
noise_level: float = 0.1
num_augmentations: int = 5
permutation_enabled: bool = False
scale_enabled: bool = False
scale_range: float = 0.1
shift_enabled: bool = False
shift_range: float = 0.1
class fishy.data.augmentation.DataAugmenter(config: AugmentationConfig)[source]

Bases: object

Applies various data augmentation techniques to a DataLoader.

__init__(config: AugmentationConfig) None[source]
augment(dataloader: DataLoader) DataLoader[source]

s