code: def enumerate_epoch(self, return_type="auto"):
      buffer = []
      if self.steps_per_epoch:
          if not self._current_iterator:
              self._current_iterator = self._get_iterator(return_type)
              self._insufficient_data = False
  
          for step in range(self.steps_per_epoch):
              if self._insufficient_data:
                  break
  
              try:
                  data = next(self._current_iterator)
                  buffer.append(data)
                  if len(buffer) == self.steps_per_execution:
                      yield step - len(buffer) + 1, buffer
                      buffer = []
              except (StopIteration,):
                  warnings.warn(
                      "Your input ran out of data; interrupting epoch. "
                      "Make sure that your dataset or generator can generate "
                      "at least `steps_per_epoch * epochs` batches. "
                      "You may need to use the `.repeat()` "
                      "function when building your dataset.",
                      stacklevel=2,
                  )
                  self._current_iterator = None
                  self._insufficient_data = True
          if buffer:
              yield step - len(buffer) + 1, buffer
      else:
          for step, data in enumerate(self._get_iterator(return_type)):
              buffer.append(data)
              if len(buffer) == self.steps_per_execution:
                  yield step - len(buffer) + 1, buffer
                  buffer = []
          if buffer:
              yield step - len(buffer) + 1, buffer
          if not self._num_batches:
              # Infer the number of batches returned by the data_adapter.
              # Assumed static.
              self._num_batches = step + 1
      self.data_adapter.on_epoch_end()
  
imports: import warnings
  from keras.trainers import data_adapters
label_desc: Use image node_id 3 for calling the EpochIterator obj's underlying member method code with example usage: obj.enumerate_epoch(return_type) without return types