ray.data.DatasetPipeline.iter_torch_batches#

DatasetPipeline.iter_torch_batches(*, prefetch_blocks: int = 0, batch_size: Optional[int] = 256, batch_format: str = 'default', drop_last: bool = False, local_shuffle_buffer_size: Optional[int] = None, local_shuffle_seed: Optional[int] = None) Iterator[Union[torch.Tensor, Dict[str, torch.Tensor]]][source]#

Call Dataset.iter_torch_batches over the stream of output batches from the pipeline.