code: def remember_exception(iterable, exception_box=None):
      """Wraps a TensorFlow dataset generator for catching its actual exceptions
      that would otherwise just interrupt iteration w/o bubbling up."""
  
      def do_iterate():
          try:
              yield from iterable()
          except StopIteration:
              return
          except Exception as ex:  # pylint: disable = broad-except
              exception_box.exception = ex
  
      return iterable if exception_box is None else do_iterate
  
imports: import os
  import sys
  import time
  import heapq
  import semver
  import random
  from multiprocessing import Pool
  from collections import namedtuple
label_desc: Use image node_id 5 for calling a global function with example usage: remember_exception(iterable, exception_box) and returns: unknown