So i have used the same autoencoder model with a batch size of 10 without a generator (by loading the elements in memory ) and the model runs without any issues at all.