Yes, but do both shapes look the same i.e., are both in the format such as [n_images, height, width, channels] where the value of n_images varies between data_loader and train_loader?
Can you please tell us the shapes of images_data in data_loader and train_loader? This is because we can reproduce your error by generating random data of those shapes. Thank you.