title: How to use predict_generator with ImageDataGenerator?
body: <p>I'm very new to Keras. I trained a model and would like to predict some images stored in subfolders (like for training). For testing, I want to predict 2 images from 7 classes (subfolders). The test_generator below sees 14 images, but I get 196 predictions. Where is the mistake? Thanks a lot!</p>
  
  <pre><code>test_datagen = ImageDataGenerator(rescale=1./255)
  
  test_generator = test_datagen.flow_from_directory(
          test_dir,
          target_size=(200, 200),
          color_mode="rgb",
          shuffle = "false",
          class_mode='categorical')
  
  filenames = test_generator.filenames
  nb_samples = len(filenames)
  
  predict = model.predict_generator(test_generator,nb_samples)
  </code></pre>