Skip to content

This repository provides a detailed comparison between traditional Cross Entropy loss function vs Ordinal for Age vs Consistent Ranked Logits(CORAL) approach for Age.

License

Notifications You must be signed in to change notification settings

Chirag-Sai-Panuganti/Age-and-Gender-Detection-Cross-Entropy-vs-Ordinal-vs-CORAL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Age and Gender Detection Cross Entropy vs Ordinal vs CORAL

This project is performed using Pytorch and ResNet-34 is used as backbone. The Datasets used were UTKFace and MORPH-2. The face images were cropped and preprocessed. It is split into Train-Validation-Test sets(80-10-10). The Images are labeled in .csv files. The Batch size used is 256.

Cross Entropy

This is the Cross Entropy Architecture.The Soft max layer is applied in the final layer.The Optimizer used was ADAM and the learning Rate is 0.0005. The Accuracy of Gender is 83.78%(UTKFace) and 99.18%(MORPH-2) and Mean Absolute Error for Age is 7.13(UTKFace) and 3.27(MORPH-2).

CORAL

This is Consistent Ranked Logits(CORAL) Architecture.The n-1 indvidual classifiers are applied in the final layer.The Optimizer used was ADAM and the loss function is Weighted Cross Entropy Loss Function.The learning rate is 0.0005. The Accuracy of Gender is 89.20%(UTKFace) and 99.38%(MORPH-2) and Mean Absolute Error for Age is 5.58(UTKFace) and 2.57(MORPH-2).

The Results are:-

Results

MAE: Mean Absolute Error and RMSE: Root Mean Squared Error.

Conclusion: We have observed that "CORAL outperformed both Ordinal and Cross Entropy approaches for Age and Gender Detection".

About

This repository provides a detailed comparison between traditional Cross Entropy loss function vs Ordinal for Age vs Consistent Ranked Logits(CORAL) approach for Age.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published