I have been trying to create Siamese model for finding image similarity between 2 images (it has 2 input images). At the beginning I tested it with a small dataset, it fitted in my RAM and it worked kinda well. Now, I want to increase the training sample size and in order to do that I created images.csv file. In this file, I have 3 columns:
image_1, image_2, similarity
image_1 and image_2 are absolute paths to images. similarity is either 0 or 1.
I tried
generator.flow_from_dataframe(dataframe, target_size=(64, 64, 1), x_col=['image_1', 'image_2'],
y_col='similarity',
class_mode='sparse', subset='training')
but got this error:
ValueError: All values in column x_col=['image_1', 'image_2'] must be strings.
after removing image_2 and having x_col=image_1 error disappeared but it has only 1 input image.
What should I do?