SlideShare a Scribd company logo
1 of 16
AGE AND GENDER
DETECTION
A PROJECT ON DEEP LEARNING
TABLE OF CONTENTS
Agenda
Objectives
Dataset description
Methodology
Data pre-processing
Building a CNN model
Model compilation
Testing and deployment
Real world use-cases
AGENDA
The age and gender classification system is used to categorize human images into various groups
determined by facial features. Estimating human age group and gender automatically via facial image
analysis has lots of potential real-world applications, such as human computer interaction and
multimedia communication.
The successful applications of CNN on many computer-vision tasks have revealed that CNN is a
powerful tool in image learning. If enough training data are given, CNN is able to learn a compact and
discriminative image feature representation.
This project aims to detect age and gender which works on the mechanism of deep learning using
convolutional neural network.
OBJECTIVES
 To pretrain the age and gender detection model using the
public Datasets such as UTKFace.
 To use facial images to detect the age and gender provided to
the model
 To use model and expose it in as API using Flask or other.
DATASET DESCRIPTION
o UTKFace dataset is a large-scale face dataset with long age span (range from 0 to 116 years old).
o It has a total of 23708 images. The images cover large variations in facial expression, illumination,
pose, resolution and occlusion.
o We chose this dataset because of its relatively more uniform distributions, the diversity it has in
image characteristics such as brightness, occlusion and position and also it involves images of the
public data.
o Each image is labeled with a 3-element tuple, with age (in years), gender (Male-0, Female-1) and
races (White-0, Black-1, Asian-2, Indian-3 and Others-4) respectively.
o We used the same set of images for training, testing and validation, to have standardized results.
This was done by dividing the data sets into train, test in 80 : 20 ratios.
METHODOLOGY
Load the dataset
Train-test split
Data pre-processing
Building CNN
Test and deployment
DATA PRE-PROCESSING
Grayscale conversion
Resizing
Storing in numpy array
Normalizing
Grayscale
conversion
Resizing
Storing in
numpy array
Normalizing
The conversion of a color image into a grayscale image is converting the
RGB values (24 bit) into grayscale value (8 bit). Grayscale simplifies the
algorithm and reduces computational requirements.
Deep learning models train faster on small images. Neural networks
receive inputs of the same size, all images need to be resized to a fixed size
before inputting them to the CNN. Here we are resizing it into 128 x 128.
Neural networks can handle only numpy array. NumPy arrays takes
significantly less amount of memory. So we are appending all the images
into a numpy array.
Data normalization is used to standardize data which ensures that each
input parameter (pixel, in this case) has a similar data distribution. This
makes convergence faster while training the network.
CNN MODEL
The tasks tackled using the deep CNN approach include gender classification and age estimation. The
basic structure includes a series of convolutional blocks, followed by a set of FC (fully connected)
layers for classification and regression.
Every architecture comprises convolutional blocks that are a stack of convolutional layers (filter size is
3x3) followed by non-linear activation ‘ReLU’, max pooling (2x2) and batch normalization to mitigate
the problem of covariate shift.
Following the convolutional blocks, the output is flattened before feeding that into FC layers. These
FC layers have activation function of ReLU, dropout (value between 0.2 & 0.4) and batch
normalization.
During training, the CNN learns the optimal values for filter matrices that enable it to extract
meaningful features from input feature.
Basic CNN Architecture
MODEL COMPILATION
• Loss function
Binary cross entropy for gender classification
Mean Absolute Error for age detection
• Optimizer : Adam
• Metric : Accuracy
TESTING AND DEPLOYMENT
The model is finally tested with a test data and the results are obtained and deployed using vs code
and streamlit.
REAL WORLD USE CASES
 Quividi is an AI software application
which is used to detect age and gender of
users who passes by based on online face
analyses and automatically starts playing
advertisements based on the targeted
audience.
 Another example could be AgeBot which
is an Android App that determines your
age from your photos using facial
recognition. It can guess your age and
gender along with that can also find
multiple faces in a picture and estimate
the age for each face.
THANK YOU!

More Related Content

Similar to ageandgenderdetection-220802061020-9ee5a2cd.pptx

Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
INFOGAIN PUBLICATION
 
Image Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural NetworkImage Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural Network
AIRCC Publishing Corporation
 
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdfresearchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
AvijitChaudhuri3
 

Similar to ageandgenderdetection-220802061020-9ee5a2cd.pptx (20)

Bangla Handwritten Digit Recognition Report.pdf
Bangla Handwritten Digit Recognition  Report.pdfBangla Handwritten Digit Recognition  Report.pdf
Bangla Handwritten Digit Recognition Report.pdf
 
BLOOD TISSUE IMAGE TO IDENTIFY MALARIA DISEASE CLASSIFICATION
BLOOD TISSUE IMAGE TO IDENTIFY MALARIA DISEASE CLASSIFICATIONBLOOD TISSUE IMAGE TO IDENTIFY MALARIA DISEASE CLASSIFICATION
BLOOD TISSUE IMAGE TO IDENTIFY MALARIA DISEASE CLASSIFICATION
 
IRJET - Gender and Age Prediction using Wideresnet Architecture
IRJET - Gender and Age Prediction using Wideresnet ArchitectureIRJET - Gender and Age Prediction using Wideresnet Architecture
IRJET - Gender and Age Prediction using Wideresnet Architecture
 
Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
Dataset Pre-Processing and Artificial Augmentation, Network Architecture and ...
 
Image Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural NetworkImage Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural Network
 
Image Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural NetworkImage Segmentation and Classification using Neural Network
Image Segmentation and Classification using Neural Network
 
Age and Gender Prediction and Human count
Age and Gender Prediction and Human countAge and Gender Prediction and Human count
Age and Gender Prediction and Human count
 
IRJET - Explicit Content Detection using Faster R-CNN and SSD Mobilenet V2
 IRJET - Explicit Content Detection using Faster R-CNN and SSD Mobilenet V2 IRJET - Explicit Content Detection using Faster R-CNN and SSD Mobilenet V2
IRJET - Explicit Content Detection using Faster R-CNN and SSD Mobilenet V2
 
FACE RECOGNITION USING PRINCIPAL COMPONENT ANALYSIS WITH MEDIAN FOR NORMALIZA...
FACE RECOGNITION USING PRINCIPAL COMPONENT ANALYSIS WITH MEDIAN FOR NORMALIZA...FACE RECOGNITION USING PRINCIPAL COMPONENT ANALYSIS WITH MEDIAN FOR NORMALIZA...
FACE RECOGNITION USING PRINCIPAL COMPONENT ANALYSIS WITH MEDIAN FOR NORMALIZA...
 
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdfresearchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
researchpaper_2023_Lungs_Cancer.pdfdfgdgfhdf
 
Real-Time Face-Age-Gender Detection System
Real-Time Face-Age-Gender Detection SystemReal-Time Face-Age-Gender Detection System
Real-Time Face-Age-Gender Detection System
 
IRJET- A Survey on Medical Image Interpretation for Predicting Pneumonia
IRJET- A Survey on Medical Image Interpretation for Predicting PneumoniaIRJET- A Survey on Medical Image Interpretation for Predicting Pneumonia
IRJET- A Survey on Medical Image Interpretation for Predicting Pneumonia
 
Real-Time Face Tracking with GPU Acceleration
Real-Time Face Tracking with GPU AccelerationReal-Time Face Tracking with GPU Acceleration
Real-Time Face Tracking with GPU Acceleration
 
CUDA Accelerated Face Recognition
CUDA Accelerated Face RecognitionCUDA Accelerated Face Recognition
CUDA Accelerated Face Recognition
 
IRJET-Multiclass Classification Method Based On Deep Learning For Leaf Identi...
IRJET-Multiclass Classification Method Based On Deep Learning For Leaf Identi...IRJET-Multiclass Classification Method Based On Deep Learning For Leaf Identi...
IRJET-Multiclass Classification Method Based On Deep Learning For Leaf Identi...
 
Blood Cell Image Classification for Detecting Malaria using CNN
Blood Cell Image Classification for Detecting Malaria using CNNBlood Cell Image Classification for Detecting Malaria using CNN
Blood Cell Image Classification for Detecting Malaria using CNN
 
IPT.pdf
IPT.pdfIPT.pdf
IPT.pdf
 
A multilevel automatic thresholding method based on a genetic algorithm for a...
A multilevel automatic thresholding method based on a genetic algorithm for a...A multilevel automatic thresholding method based on a genetic algorithm for a...
A multilevel automatic thresholding method based on a genetic algorithm for a...
 
Locate, Size and Count: Accurately Resolving People in Dense Crowds via Detec...
Locate, Size and Count: Accurately Resolving People in Dense Crowds via Detec...Locate, Size and Count: Accurately Resolving People in Dense Crowds via Detec...
Locate, Size and Count: Accurately Resolving People in Dense Crowds via Detec...
 
Caricature Recognition and Generation
Caricature Recognition and GenerationCaricature Recognition and Generation
Caricature Recognition and Generation
 

Recently uploaded

Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Riyadh +966572737505 get cytotec
 
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
amitlee9823
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
amitlee9823
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
amitlee9823
 
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
amitlee9823
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
amitlee9823
 
Probability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter LessonsProbability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter Lessons
JoseMangaJr1
 
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
amitlee9823
 

Recently uploaded (20)

Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
 
Mature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptxMature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptx
 
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
 
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
 
Capstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics ProgramCapstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics Program
 
VidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptxVidaXL dropshipping via API with DroFx.pptx
VidaXL dropshipping via API with DroFx.pptx
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
 
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Thane West Call On 9920725232 With Body to body massage...
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
 
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% SecureCall me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
 
Discover Why Less is More in B2B Research
Discover Why Less is More in B2B ResearchDiscover Why Less is More in B2B Research
Discover Why Less is More in B2B Research
 
Probability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter LessonsProbability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter Lessons
 
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Saket (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
Halmar dropshipping via API with DroFx
Halmar  dropshipping  via API with DroFxHalmar  dropshipping  via API with DroFx
Halmar dropshipping via API with DroFx
 
ELKO dropshipping via API with DroFx.pptx
ELKO dropshipping via API with DroFx.pptxELKO dropshipping via API with DroFx.pptx
ELKO dropshipping via API with DroFx.pptx
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interaction
 
Edukaciniai dropshipping via API with DroFx
Edukaciniai dropshipping via API with DroFxEdukaciniai dropshipping via API with DroFx
Edukaciniai dropshipping via API with DroFx
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
 

ageandgenderdetection-220802061020-9ee5a2cd.pptx

  • 1. AGE AND GENDER DETECTION A PROJECT ON DEEP LEARNING
  • 2. TABLE OF CONTENTS Agenda Objectives Dataset description Methodology Data pre-processing Building a CNN model Model compilation Testing and deployment Real world use-cases
  • 3. AGENDA The age and gender classification system is used to categorize human images into various groups determined by facial features. Estimating human age group and gender automatically via facial image analysis has lots of potential real-world applications, such as human computer interaction and multimedia communication. The successful applications of CNN on many computer-vision tasks have revealed that CNN is a powerful tool in image learning. If enough training data are given, CNN is able to learn a compact and discriminative image feature representation. This project aims to detect age and gender which works on the mechanism of deep learning using convolutional neural network.
  • 4. OBJECTIVES  To pretrain the age and gender detection model using the public Datasets such as UTKFace.  To use facial images to detect the age and gender provided to the model  To use model and expose it in as API using Flask or other.
  • 5.
  • 6. DATASET DESCRIPTION o UTKFace dataset is a large-scale face dataset with long age span (range from 0 to 116 years old). o It has a total of 23708 images. The images cover large variations in facial expression, illumination, pose, resolution and occlusion. o We chose this dataset because of its relatively more uniform distributions, the diversity it has in image characteristics such as brightness, occlusion and position and also it involves images of the public data. o Each image is labeled with a 3-element tuple, with age (in years), gender (Male-0, Female-1) and races (White-0, Black-1, Asian-2, Indian-3 and Others-4) respectively. o We used the same set of images for training, testing and validation, to have standardized results. This was done by dividing the data sets into train, test in 80 : 20 ratios.
  • 7.
  • 8. METHODOLOGY Load the dataset Train-test split Data pre-processing Building CNN Test and deployment
  • 10. Grayscale conversion Resizing Storing in numpy array Normalizing The conversion of a color image into a grayscale image is converting the RGB values (24 bit) into grayscale value (8 bit). Grayscale simplifies the algorithm and reduces computational requirements. Deep learning models train faster on small images. Neural networks receive inputs of the same size, all images need to be resized to a fixed size before inputting them to the CNN. Here we are resizing it into 128 x 128. Neural networks can handle only numpy array. NumPy arrays takes significantly less amount of memory. So we are appending all the images into a numpy array. Data normalization is used to standardize data which ensures that each input parameter (pixel, in this case) has a similar data distribution. This makes convergence faster while training the network.
  • 11. CNN MODEL The tasks tackled using the deep CNN approach include gender classification and age estimation. The basic structure includes a series of convolutional blocks, followed by a set of FC (fully connected) layers for classification and regression. Every architecture comprises convolutional blocks that are a stack of convolutional layers (filter size is 3x3) followed by non-linear activation ‘ReLU’, max pooling (2x2) and batch normalization to mitigate the problem of covariate shift. Following the convolutional blocks, the output is flattened before feeding that into FC layers. These FC layers have activation function of ReLU, dropout (value between 0.2 & 0.4) and batch normalization. During training, the CNN learns the optimal values for filter matrices that enable it to extract meaningful features from input feature.
  • 13. MODEL COMPILATION • Loss function Binary cross entropy for gender classification Mean Absolute Error for age detection • Optimizer : Adam • Metric : Accuracy
  • 14. TESTING AND DEPLOYMENT The model is finally tested with a test data and the results are obtained and deployed using vs code and streamlit.
  • 15. REAL WORLD USE CASES  Quividi is an AI software application which is used to detect age and gender of users who passes by based on online face analyses and automatically starts playing advertisements based on the targeted audience.  Another example could be AgeBot which is an Android App that determines your age from your photos using facial recognition. It can guess your age and gender along with that can also find multiple faces in a picture and estimate the age for each face.