torchtext.data.iterator — torchtext 0.8.0 documentation
pytorch.org › torchtext › dataclass Iterator (object): """Defines an iterator that loads batches of data from a Dataset. Attributes: dataset: The Dataset object to load Examples from. batch_size: Batch size. batch_size_fn: Function of three arguments (new example to add, current count of examples in the batch, and current effective batch size) that returns the new effective batch size resulting from adding that example to ...