class_docstr: ```
  Image preprocessing
  ```
code: def __init__(
      self, datagen, classes, target_size=(224, 224), color_mode="rgb"
  ):
      if not isinstance(
          datagen, keras.preprocessing.image.ImageDataGenerator
      ):
          raise ValueError(
              "datagen must be instance of ImageDataGenerator"
          )
      self.datagen = datagen
      self.c = classes
      self.target_size = target_size
      self.color_mode = color_mode
  
file_path: ktrain/ktrain/vision/preprocessor.py
imports: from ..None import utils
  from ..imports import *
  from ..preprocessor import Preprocessor
label_desc: Use image node_id 1 to create a new ImagePreprocessor object from inherited base classes: Preprocessor with example: obj = ImagePreprocessor(datagen, classes, target_size, color_mode)