code: def run(self):
      events = [None for _ in self.cuda_streams]
  
      try:
          b_ix = 0
          Compiler.set_num_threads(self.loader.num_workers)
          while True:
              ixes = next(self.iter_ixes)
              slot = self.current_batch_slot
              self.current_batch_slot = (slot + 1) % (
                  self.loader.batches_ahead + 2
              )
              result = self.run_pipeline(b_ix, ixes, slot, events[slot])
              # print("RES", b_ix, "ready")
              to_output = (slot, result)
              while True:
                  try:
                      self.output_queue.put(
                          to_output, block=True, timeout=0.5
                      )
                      break
                  except Full:
                      pass
  
                  if self.terminate_event.is_set():
                      return
              if IS_CUDA:
                  # print("SUB", b_ix)
                  # We were able to submit this batch
                  # Therefore it means that the user must have entered the for loop for
                  # (batch_slot - batch_ahead + 1) % (batches ahead + 2)
                  # Therefore batch_slot - batch_ahead must have all it's work submitted
                  # We will record an event of all the work submitted on the main stream
                  # and make sure no one overwrite the data until they are done
                  just_finished_slot = (
                      slot - self.loader.batches_ahead - 1
                  ) % (self.loader.batches_ahead + 2)
                  # print("JFS", just_finished_slot)
                  event = ch.cuda.Event()
                  event.record(self.current_stream)
                  events[just_finished_slot] = event
              b_ix += 1
  
      except StopIteration:
          self.output_queue.put(None)
  
file_path: ffcv/ffcv/loader/epoch_iterator.py
imports: from collections import defaultdict
  from threading import Thread, Event
  from queue import Queue, Full
  from contextlib import nullcontext
  from typing import Sequence, TYPE_CHECKING
  import torch
  from ..traversal_order.quasi_random import QuasiRandom
  from ..utils import chunks
  from ..pipeline.compiler import Compiler
label_desc: Use image node_id 2 for calling the EpochIterator obj's underlying member method code with example usage: obj.run() without return types