grain.transforms.Batch#
- class grain.transforms.Batch(batch_size: 'int', drop_remainder: 'bool' = False, batch_fn: 'Callable[[Sequence[Any]], Any] | None' = None)#
- Parameters:
batch_size (int)
drop_remainder (bool)
batch_fn (Callable[[Sequence[Any]], Any] | None)
- __init__(batch_size, drop_remainder=False, batch_fn=None)#
- Parameters:
batch_size (int)
drop_remainder (bool)
batch_fn (Callable[[Sequence[Any]], Any] | None)
- Return type:
None
Methods
__init__
(batch_size[, drop_remainder, batch_fn])Attributes
batch_fn
drop_remainder
batch_size