It seems that train_y is smaller in one iteration for some reason.
Could you check the shape of X and y and make sure they contain the same number of samples?



 SriAnu:

I’m using CNNs to predict the gender of people.


What’s your use case btw.?