Skip to content

Latest commit

 

History

History
85 lines (54 loc) · 2.14 KB

README.md

File metadata and controls

85 lines (54 loc) · 2.14 KB

Age-Sex Detector

Deep Learning (Convolutional Neural Network) model to predict the age and sex from face images (UTKFace dataset), achieving 0.92 test sex accuracy and 8.68 test age RMSE

Data

UTKFace dataset

UTKFace dataset Kaggle

This dataset contains over 20,000 face images with annotations of age, sex, and ethnicity. The images cover large variation in pose, facial expression, illumination, occlusion, resolution, etc.

Data Explanation

If a photo is called 34_0_0_201701171712010149082.jpg.chip.jpg, it means that the age of the individual is 34 and his sex is male. That is, the photo names follow the following scheme age_sex_race_relevant_data.jpg.chip.jpg.

Sex being 0 for male and 1 for female.

Model Full

We have used Convolutional Neural Networks (CNN) to predict the age and sex of the full input image.

We have obtained the following metrics:

  • Validation:
    • Sex accuracy: 0.869
    • Age MSE: 135.65
    • Age MAE: 8.54
  • Test:
    • Sex accuracy: 0.878
    • Age MSE: 140.35
    • Age MAE: 8.68

Model Cropped

We have used Convolutional Neural Networks (CNN) to predict the age and sex of the cropped input image.

We have obtained the following metrics:

  • Validation:
    • Sex accuracy: 0.905
    • Age MSE: 78.956
  • Test:
    • Sex accuracy: 0.915
    • Age MSE: 75.28

Dash images

Prediction tool (the age has an error margin): prediction

Saliency maps: saliency_maps

Model metrics (best model selected): metrics

Steps to run web app

From the main project folder (AgeSexDetector/) run the following command:

pip install -r requirements.txt

Then, from one of the main folders (AgeSexDetector/full/ or AgeSexDetector/cropped/) run the following command:

python -m dashboard.dashboard