I'm trying to build a neural network for an age detection task. Here some details :
- Dataset: I am using the "facial age" Kaggle dataset and the "UTKFace" dataset for a total of about 35k images I've divided the total dataset in train, dev and test set (70%-15%-15%) and I've applied data augmentation on the train set
- Task: Age detection, 8 class classification problem
- Model: I've applied transfer learning on ResNet-50, keras implementation
On the test set the model return an accuracy of 85.5% but on real world images (google images or personal photos) the model perform a lot worse (about 45%). The images of the real world I've choosen are quite similar to those of the datasets, it's not possible for an human eye to distinguish them.
Where is the problem ? What can I do to fix it ?