holocron.utils.data¶
Batch collate¶
- holocron.utils.data.mixup_collate(data, alpha=0.1)[source]¶
Implements a batch collate function with MixUp strategy from “mixup: Beyond Empirical Risk Minimization”
- Example::
>>> import torch >>> from holocron import utils >>> loader = torch.utils.data.DataLoader(dataset, batch_size, collate_fn=utils.data.mixup_collate)