class_docstr: Wrapper class on top of the Keras-native data generators. These can either be generator functions,
  `keras.utils.Sequence` or Keras-specific data generators (`keras.preprocessing.image.ImageDataGenerator`).
docstr: Create a Keras data generator wrapper instance.
  
  :param iterator: A generator as specified by Keras documentation. Its output must be a tuple of either
                   `(inputs, targets)` or `(inputs, targets, sample_weights)`. All arrays in this tuple must have
                   the same length. The generator is expected to loop over its data indefinitely.
  :param size: Total size of the dataset.
  :param batch_size: Size of the minibatches.
code: def __init__(
      self,
      iterator: Union[
          "keras.utils.Sequence",
          "tf.keras.utils.Sequence",
          "keras.preprocessing.image.ImageDataGenerator",
          "tf.keras.preprocessing.image.ImageDataGenerator",
          Generator,
      ],
      size: Optional[int],
      batch_size: int,
  ) -> None:
      """
      Create a Keras data generator wrapper instance.
  
      :param iterator: A generator as specified by Keras documentation. Its output must be a tuple of either
                       `(inputs, targets)` or `(inputs, targets, sample_weights)`. All arrays in this tuple must have
                       the same length. The generator is expected to loop over its data indefinitely.
      :param size: Total size of the dataset.
      :param batch_size: Size of the minibatches.
      """
      super().__init__(size=size, batch_size=batch_size)
      self._iterator = iterator
  
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import abc
  import inspect
  import logging
  from typing import Any, Dict, Generator, Iterator, Optional, Tuple, Union, TYPE_CHECKING
  import numpy
label_desc: Use image node_id 1 to create a new KerasDataGenerator object from inherited base classes: DataGenerator with example: obj = KerasDataGenerator(iterator, size, batch_size)