class_docstr: Implements a dataset wrapper for fast data loading
  
  >>> from doctr.datasets import CORD, DataLoader
  >>> train_set = CORD(train=True, download=True)
  >>> train_loader = DataLoader(train_set, batch_size=32)
  >>> train_iter = iter(train_loader)
  >>> images, targets = next(train_iter)
  
  Args:
  ----
      dataset: the dataset
      shuffle: whether the samples should be shuffled before passing it to the iterator
      batch_size: number of elements in each batch
      drop_last: if `True`, drops the last batch if it isn't full
      num_workers: number of workers to use for data loading
      collate_fn: function to merge samples into a batch
code: def __next__(self):
      if self._num_yielded < self.num_batches:
          # Get next indices
          idx = self._num_yielded * self.batch_size
          indices = self.indices[
              idx : min(len(self.dataset), idx + self.batch_size)
          ]
  
          samples = list(
              multithread_exec(
                  self.dataset.__getitem__,
                  indices,
                  threads=self.num_workers,
              )
          )
  
          batch_data = self.collate_fn(samples)
  
          self._num_yielded += 1
          return batch_data
      else:
          raise StopIteration
  
file_path: doctr/doctr/datasets/loader.py
imports: import math
  from typing import Callable, Optional
  import numpy
  import tensorflow
  from doctr.utils.multithreading import multithread_exec
label_desc: Use image node_id 5 for calling the DataLoader obj's underlying member method code with example usage: obj.__next__() and returns: batch_data