## 3 Proposed Method
### Age Estimation  
#### 3.1.1 Data Cleansing & Balancing  
Real age and gender estimation from a face image is a very complex problem acknowledged by computer vision researchers. Especially, age estimation from the face image is still an open complex problem within the research community. It is a well-known fact that a very deep neural network is needed to solve a complex problem. Accordingly, training a very deep network requires a huge amount of training images. Otherwise, a network will overfit if we fail to provide an optimum amount of training images to that network. To overcome the overfitting problem of the network, the first and foremost step is the data adequacy for training the deployed network. In reality, there are only a few datasets that have a very rich number of face images under an unconstrained environment. In  
Figure 1: Schematic diagram of the proposed age and gender estimation method.  
Figure 2: The process diagram of a smart store customer relationship management system.  
our experiment, we have used the richest in-the-wild image dataset IMDB-WIKI [24] for training the deep network. Despite the IMDB-WIKI dataset is rich concerning the number of images, data sparsity is huge in this dataset. In the case of the age estimation task, we observed that this dataset consists of a huge number of images for people aged between 15-65 compared to children and elderly people. In this situation, if we train the model with this class sparsity, it is impossible to get optimized results for the class which is imbalanced in real-time as the model never gets a sufficient look at the underlying class. We mitigate the data sparsity problem by taking the following scheme:  
* Randomly choose the number of samples from the class which has sufficient observations so that the comparative ratio among the class will be retained;
* Manually filter out the wrongly annotated samples from each class that is shown in Figure 3
* For the classes of fewer samples, we first enhance the data from another benchmark dataset, the Adience dataset [9], and perform necessary offline data augmentation operations to make the class balance. The performed data augment operations, such as right flipping, rotation in the angle between \(-30^{\circ}\) to \(30^{\circ}\) with the steps of \(5^{\circ}\), scaling, and adding noise to a certain probability.  
During training, we perform online data augmentation by rescaling the input image into 256 \(\times\) 256 pixels and taking a center crop of 224 \(\times\) 224 pixels from the 256 \(\times\) 256 size image and pass it on for the training. This can alleviate the over-fitting problem of the network and enhances the robustness of the model. Through empirical observation, it is evident that after these operations, the training effect of the network is better, and the age and gender estimation accuracy of the final model is higher. In Figure 4, we show the resulting data distribution among the underlying classes before and after we introduce parity in the number of image samples of the combined IMDB-WIKI dataset.  
Figure 4: Class-wise sample distribution of the IMDB-WIKI dataset prior to and following parity among classes.  
Figure 3: Some of the wrongly annotated image samples in the existing IMDB-WIKI benchmark dataset.