using multiple losses for accurate facial age estimation

Yi Zhou, Heikki Huttunen, Tapio Elomaa · DOI

Abstract

Age estimation is an essential challenge in computer vision. With the advances of convolutional neural networks, the performance of age estimation has been dramatically improved. Existing approaches usually treat age estimation as a classification problem. However, the age labels are ambiguous, thus make the classification task difficult. In this paper, we propose a simple yet effective approach for age estimation, which improves the performance compared to classification-based methods. The method combines four classification losses and one regression loss representing different class granularities together, and we name it as Age-Granularity-Net. We validate the Age-Granularity-Net framework on the CVPR Chalearn 2016 dataset, and extensive experiments show that the proposed approach can reduce the prediction error compared to any individual loss. The source code link is https://github.com/yipersevere/age-estimation.

Introduction

Estimating a person's age from a single photograph is a classic computer vision challenge complicated by label ambiguity. Most datasets rely on "apparent age"—how old a person looks to human annotators—rather than "biological age." Because human judgment is subjective, a 24-year-old might be labeled as 25 or 26. Standard machine learning approaches usually treat age as either a classification problem (treating every year as a distinct category) or a regression problem (predicting a continuous number).

Classification often ignores the ordinal relationship between ages, while regression can struggle with the high variance and noise inherent in facial aging. To address these issues, we introduce a method that makes models more tolerant of "fuzzy" labels by supervising them at multiple scales of granularity.

Methodology: Age-Granularity-Net

The core innovation of our approach is the Age-Granularity-Net framework. This architecture can be applied to any standard backbone (e.g., ResNet, MobileNet, or AlexNet). It utilizes an aggregate loss function that supervises the model through five distinct branches:

  1. Fine-grained Classification: 100 classes (1-year intervals).
  2. Coarse Classification (Level 1): 20 classes (5-year intervals).
  3. Coarse Classification (Level 2): 10 classes (10-year intervals).
  4. Coarse Classification (Level 3): 5 classes (20-year intervals).
  5. Regression: A single neuron outputting a continuous value using Mean Squared Error (MSE).
The Age-Granularity-Net architecture featuring a shared backbone and five specialized output branches for multi-scale supervision.

By requiring the model to satisfy all these constraints simultaneously, the shared backbone learns features useful for both broad age-grouping and specific year-to-year differences. Crucially, at inference time, the extra branches are discarded; the 100-class branch alone provides the final prediction, meaning the added training complexity comes at zero computational cost during deployment.

Experimental Setup

We evaluated our framework using the CVPR 2016 ChaLearn Looking at People dataset. This dataset contains 7,591 facial images (4,113 training, 1,500 validation, and 1,978 test). These images represent "apparent ages" collected in non-controlled environments with diverse backgrounds, providing a realistic benchmark for age estimation.

Results and Discussion

Our experiments across five different backbones—AlexNet, MobileNet-V1, ResNet-50, DenseNet-121, and VGG-16—demonstrate consistent improvements.

Monotonic Improvement

A key finding was that adding additional loss branches almost always improved the Mean Absolute Error (MAE). There was no observed "sweet spot" where more information became detrimental; rather, more supervision consistently led to better performance.

The Impact of Regression

While classification is the standard for this task, the inclusion of a single regression (MSE) branch provided a significant boost. For instance, in the AlexNet backbone, adding the MSE loss reduced the error by 49% compared to the baseline classification-only model.

Quantitative results showing the Mean Absolute Error (MAE) for various backbone architectures as different loss components are added.

As shown in the table above, the multi-loss approach outperformed the single-loss baseline in every architecture tested. For example, ResNet-50's MAE dropped from 4.84 to 4.03, and DenseNet-121's MAE improved from 6.16 to 3.86. These results approach state-of-the-art performance while maintaining a much simpler, general-purpose architecture.

Conclusion

Age-Granularity-Net demonstrates that multi-scale supervision is a powerful tool for handling ambiguous labels in facial age estimation. By combining classification and regression losses at various granularities, we force the model to learn more robust features. This approach is easy to implement, compatible with any backbone, and adds no overhead to inference speed.

Summary updated

Abstract

Age estimation is an essential challenge in computer vision. With the advances of convolutional neural networks, the performance of age estimation has been dramatically improved. Existing approaches usually treat age estimation as a classification problem. However, the age labels are ambiguous, thus make the classification task difficult. In this paper, we propose a simple yet effective approach for age estimation, which improves the performance compared to classification-based methods. The method combines four classification losses and one regression loss representing different class granularities together, and we name it as Age-Granularity-Net. We validate the Age-Granularity-Net framework on the CVPR Chalearn 2016 dataset, and extensive experiments show that the proposed approach can reduce the prediction error compared to any individual loss. The source code link is https://github.com/yipersevere/age-estimation.
BibTeX
@misc{zhou2021using,
  author = {Yi Zhou and Heikki Huttunen and Tapio Elomaa},
  title = {{using multiple losses for accurate facial age estimation}},
  year = {2021},
  eprint = {2106.09393},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2106.09393},
}
Figure