Regarding validation accuracy

My model is performing giving good training accuracy and as well as validation accuracy,i was predicting open eyes and closed eyes,but when i give some outside image,it does not perform good what can be happen.

The model might be learning something that is not what you wanted in the first place. I guess a good idea would be to try to check whether they have similar distributions and whether your model actually has good accuracy on the initial dataset.

So may be i don’t have normalize my data,may not take all images on same scale that can be problem?

I am also sharing the code also.