how to use multiple generator in keras fit_generator() I want to train the multi-input model on a set of images. I use ImageDataGenerator.flow_from_directory() and fit_generator in keras.

The problem is I don't know how to use multiple generators.

This is my inputs &amp; output generator and seeds are same:

input1 = imageDataGenerator.flow_from_directory(directory=base_data_directory + 'img/' + mode+'/', **img_generator_config)
input2 = imageDataGenerator.flow_from_directory(directory=base_data_directory + 'edge/' + mode,**edge_generator_config)
output = imageDataGenerator.flow_from_directory(directory=base_data_directory + 'label/' + mode, **label_generator_config)


How should I use fit_generator with this data?
In my opinion, you should build the custom data generator or just use the fit function of Keras and make your input data as follows:

x = [[image1, feature1], [image2, feature1], [image3, feature1]]

y = [class1, class2, class1]