title: Keras flowFromDirectory get file names as they are being generated
body: <p>Is it possible to get the file names that were loaded using <code>flow_from_directory</code> ? 
  I have :</p>
  
  <pre><code>datagen = ImageDataGenerator(
      rotation_range=3,
  #     featurewise_std_normalization=True,
      fill_mode='nearest',
      width_shift_range=0.2,
      height_shift_range=0.2,
      horizontal_flip=True
  )
  
  train_generator = datagen.flow_from_directory(
          path+'/train',
          target_size=(224, 224),
          batch_size=batch_size,)
  </code></pre>
  
  <p>I have a custom generator for my multi output model like:</p>
  
  <pre><code>a = np.arange(8).reshape(2, 4)
  # print(a)
  
  print(train_generator.filenames)
  
  def generate():
      while 1:
          x,y = train_generator.next()
          yield [x] ,[a,y]
  </code></pre>
  
  <p>Node that at the moment I am generating random numbers for <code>a</code> but for real training , I wish to load up a <code>json</code> file that contains the bounding box coordinates for my images. For that I will need to get the file names that were generated using <code>train_generator.next()</code> method. After I have that , I can load the file, parse the <code>json</code> and pass it instead of <code>a</code>. It is also necessary that the ordering of the <code>x</code> variable and the list of the file names that I get is the same. </p>