Submitted:
20 October 2023
Posted:
23 October 2023
You are already at the latest version
Abstract
Keywords:
1. Introduction

- Extension of existing literature by providing insights into areas for enhancement in facial expression detection through machine learning techniques.
- Despite achieving results that were not as impressive as those of previous studies, this research sheds light on the importance of increasing real-world representativeness in training models.
- By exploring the limitations of training models on datasets that are not person independent, this research highlights the drawbacks and potential biases that can arise when models struggle to generalize to unseen individuals. This contributes to a better understanding of the importance of person-independent datasets in facial expression detection models.
- Identifying imbalanced datasets performing well in classifying non-neutral expressions highlights the need for alternative methods for detecting neutral expressions. This research identifies this as crucial to improve accuracy and prevent biases in real-world applications.
- Also, this research identifies several promising areas for future studies in neutral facial expression detection. These include developing more precise and reliable machine learning models, collecting and annotating more extensive and diverse datasets focusing on neutral expressions and investigating the impact of various factors on neutral expression identification.
- The research emphasizes the need for dedicated datasets that explicitly classify neutral and non-neutral expressions, as existing datasets primarily focus on identifying various emotions without specific categorization.
2. Literature Review
2.1. Facial Expression Detection
2.2. Neutral Facial Expression Detection
3. Datasets
| Neutral | Not Neutral | Total | |
|---|---|---|---|
| FER2013 | 6198 (17%) | 29688 (83%) | 35886 |
| CK+ | 593 (64%) | 327 (36%) | 830 |
| JAFFE | 30 (14%) | 183 (86%) | 213 |

| Predicted Class | |||
|---|---|---|---|
| Neutral | Not Neutral | ||
| Actual Class | Neutral | 6 | 7 |
| Not Neutral | 0 | 30 | |
| Neutral | Not Neutral | Total | |
|---|---|---|---|
| Test | 1367 | 6110 | 7477 (20%) |
| Train | 4909 | 21690 | 26599 (72%) |
| Validation | 545 | 2409 | 2954 (8%) |
| Total | 6821 (18%) | 30209 (82%) | 37030 |

4. Models





| Model | Precision (Weighted Avg) | Recall (Weighted Avg) | F1-Score (Weighted Avg) | Epochs |
|---|---|---|---|---|
| InceptionV3 | 0.82 | 0.72 | 0.75 | 6 |
| VGG16 | 0.77 | 0.79 | 0.78 | 4 |
| ResNet50 | 0.67 | 0.82 | 0.73 | 7 |
| MobileNet | 0.74 | 0.76 | 0.75 | 4 |
| InceptionV3 Unfreezed | 0.78 | 0.81 | 0.78 | 4 |
| InceptionV3 No Early | 0.78 | 0.81 | 0.78 | 20 |
5. Preprocessing



6. Results
- 1
- Privacy consent: Before proceeding with the data collection process, it is obtained the participant’s informed consent regarding the capturing and usage of their facial expressions.
- 2
- Set up the camera: Determine that the camera is correctly connected and positioned to capture the subject’s facial expressions clearly. As needed, change camera settings such as resolution and frame rate.
- 3
- Position the subject: Instruct the participant in the research to stand in front of the camera, facing it. Make sure there is enough light to accurately capture face characteristics.
- 4
- Start the real-time system and collect data: Launch the real-time system for neutral facial expression detection. This system incorporates the model for the classification of neutral facial expressions, as well as the result if the expression is indeed neutral and its confidence value. Begin the data capturing process, and the camera starts recording.
- 5
- Instruct the participant to start by executing a neutral facial expression: Request that the subject relax their face and maintain a neutral expression.
- 6
- Capture frames of the neutral expression: Request the subject to keep the neutral expression for a set amount of time, such as 5 seconds.
- 7
- Instruct the participant to perform other facial expressions: Instruct the subject to execute various facial expressions, such as happy, sad, surprised or angry.
- 8
- End the data capture: Stop the data collection procedure on the camera after the participant has performed the neutral expression and other expressions. Ensure that each participant’s neutral frame with the highest confidence level is correctly saved to the chosen storage place.
- 9
- Validate the captured frames: Conduct a visual inspection of the captured frames to ensure the quality and clarity of the neutral facial expressions. Remove any frames that do not correspond to a neutral facial expression.

| Person | Expression Detected | Expression Saved | Confidence |
|---|---|---|---|
| 1 | Neutral | Neutral | 60% |
| 2 | Neutral | Neutral | 58% |
| 3 | Neutral | Neutral | 55% |
| 4 | Neutral | Neutral | 51% |
| 5 | Not Neutral | - | - |
| 6 | Neutral | Neutral | 71% |
| 7 | Neutral | Neutral | 70% |
| 8 | Neutral | Neutral | 53% |
| 9 | Neutral | Not Neutral | 59% |
| 10 | Neutral | Neutral | 63% |
| 11 | Neutral | Neutral | 57% |
| 12 | Neutral | Neutral | 63% |
| 13 | Neutral | Neutral | 69% |
| 14 | Not Neutral | - | - |
| 15 | Neutral | Neutral | 58% |
| 16 | Neutral | Neutral | 62% |
| 17 | Neutral | Neutral | 69% |
| 18 | Neutral | Not Neutral | 61% |
| 19 | Neutral | Neutral | 58% |
| 20 | Neutral | Neutral | 58% |
| 21 | Not Neutral | - | - |
| 22 | Not Neutral | - | - |
| 23 | Neutral | Neutral | 79% |
| 24 | Neutral | Neutral | 77% |
| 25 | Neutral | Neutral | 78% |
| 26 | Neutral | Neutral | 52% |
| 27 | Neutral | Neutral | 70% |
| 28 | Not Neutral | - | - |
| 29 | Neutral | Neutral | 63% |
| 30 | Neutral | Not Neutral | 58% |
| 31 | Neutral | Neutral | 73% |
| 32 | Neutral | Neutral | 70% |




7. Discussion
8. Conclusion
Author Contributions
Funding
Conflicts of Interest
Abbreviations
| AAM | Active Appearance Model |
| AU | Action Unit |
| AUDN | Action Unit-Inspired Deep Network |
| BU-3DFE | Binghamton University 3D Facial Expression |
| BU-4DFE | Binghamton University 4D (3D+time) Facial Expression |
| CCNU-FE | Central China Normal University Facial Expression |
| CK+ | Extended Cohn–Kanade |
| CLM | Constrained Local Model |
| CNN | Convolutional Neural Network |
| CRF | Conditional Random Forest |
| DPND | Deep Peak-Neutral Difference |
| DT | Decision Tree |
| DPR | Deep Representation Feature |
| ED | Euclidean Distance |
| ELM | Extreme Learning Machine |
| EmotiW | Emotion Recognition in the Wild |
| ER | Emotion Recognition |
| FAP | Facial Animation Parameter |
| FACS | Facial Action Coding System |
| FC | Fully Connected |
| FER | Facial Expression Recognition |
| FDR | False Discovery Rate |
| HOG | Histograms of Oriented Gradients |
| HMM | Hidden Markov Model |
| ISL | Intelligent Systems Lab |
| JAFFE | Japanese Female Facial Expression |
| KE | Key Emotion |
| KDEF | Karolinska Directed Emotional Faces |
| KNN | K-Nearest Neighbor |
| LPQ | Local Phase Quantization |
| LBP | Local Binary Patterns |
| MTCNN | Multi-task Cascade Convolutional Neural Network |
| OF | Optical Flow |
| OpenCV | Open Computer Vision |
| RaFD | Radboud Faces Database |
| RF | Random Forest |
| ROI | Region of Interest |
| SFEW | Static Facial Expression in the Wild |
| SVM | Support Vector Machine |
| TL | Transfer Learning |
| TPR | True Positive Rate |
| RGB | Red, Green and Blue |
| ReLU | Rectified Linear Unit |
References
- Ekman, P. Basic emotions. Handbook of cognition and emotion 1999, 98, 16. [Google Scholar] [CrossRef]
- Lucey, P.; Cohn, J.F.; Kanade, T.; Saragih, J.; Ambadar, Z.; Matthews, I. The Extended Cohn-Kanade Dataset (CK+): A complete dataset for action unit and emotion-specified expression 2010. pp. 94–101. [CrossRef]
- Karnati, M.; Seal, A.; Krejcar, O.; Yazidi, A. FER-net: facial expression recognition using deep neural net. Neural Computing and Applications 2021, 33. [Google Scholar] [CrossRef]
- Samadiani, N.; Huang, G.; Cai, B.; Luo, W.; Chi, C.H.; Xiang, Y.; He, J. A review on automatic facial expression recognition systems assisted by multimodal sensor data. Sensors 2019, 19, 1863. [Google Scholar] [CrossRef] [PubMed]
- Kuenecke, J.; Wilhelm, O.; Sommer, W. Emotion Recognition in Nonverbal Face-to-Face Communication. Journal of Nonverbal Behavior 2017, 41. [Google Scholar] [CrossRef]
- Joormann, J.; Gotlib, I.H. Is this happiness I see? Biases in the identification of emotional facial expressions in depression and social phobia. Journal of abnormal psychology 2006, 115, 705. [Google Scholar] [CrossRef] [PubMed]
- Barreto, A. Application of facial expression studies on the field of marketing. In Emotional expression: The brain and the face; FEELab Science Books: Porto, Portugal.
- Al-Modwahi, A.A.M.; Sebetela, O.; Batleng, L.N.; Parhizkar, B.; Lashkari, A.H. Facial expression recognition intelligent security system for real time surveillance. 2012. [Google Scholar]
- Li, P.; Phung, S.L.; Bouzerdoum, A.; Tivive, F.H.C. Automatic Recognition of Smiling and Neutral Facial Expressions. 2010 International Conference on Digital Image Computing: Techniques and Applications, 2010, pp. 581–586. [CrossRef]
- Saito, A.; Sato, W.; Yoshikawa, S. Rapid detection of neutral faces associated with emotional value. Cognition and Emotion 2022, 36, 546–559. [Google Scholar] [CrossRef]
- Uono, S.; Sato, W.; Sawada, R.; Kawakami, S.; Yoshimura, S.; Toichi, M. Schizotypy is associated with difficulties detecting emotional facial expressions. Royal Society Open Science 2021, 8, 211322. [Google Scholar] [CrossRef]
- Sawada, R.; Sato, W.; Nakashima, R.; Kumada, T. How are emotional facial expressions detected rapidly and accurately? A diffusion model analysis. Cognition 2022, 229, 105235. [Google Scholar] [CrossRef]
- Jia, S.; Wang, S.; Hu, C.; Webster, P.J.; Li, X. Detection of genuine and posed facial expressions of emotion: databases and methods. Frontiers in Psychology 2021, 11, 580287. [Google Scholar] [CrossRef]
- Shao, Z.; Liu, Z.; Cai, J.; Wu, Y.; Ma, L. Facial Action Unit Detection Using Attention and Relation Learning. IEEE Transactions on Affective Computing 2022, 13, 1274–1289. [Google Scholar] [CrossRef]
- Rizwan, S.A.; Jalal, A.; Kim, K. An Accurate Facial Expression Detector using Multi-Landmarks Selection and Local Transform Features 2020. pp. 1–6. [CrossRef]
- Canedo, D.; Neves, A.J. Facial expression recognition using computer vision: A systematic review. Applied Sciences 2019, 9, 4678. [Google Scholar] [CrossRef]
- Tong, Y.; Liao, W.; Ji, Q. Facial action unit recognition by exploiting their dynamic and semantic relationships. IEEE transactions on pattern analysis and machine intelligence 2007, 29, 1683–1699. [Google Scholar] [CrossRef] [PubMed]
- Chiranjeevi, P.; Gopalakrishnan, V.; Moogi, P. Neutral Face Classification Using Personalized Appearance Models for Fast and Robust Emotion Detection. IEEE Transactions on Image Processing 2015, 24, 2701–2711. [Google Scholar] [CrossRef] [PubMed]
- Yin, L.; Chen, X.; Sun, Y.; Worm, T.; Reale, M. A high-resolution 3D dynamic facial expression database 2008. pp. 1–6. [CrossRef]
- Chen, J.; Xu, R.; Liu, L. Deep peak-neutral difference feature for facial expression recognition. Multimedia Tools and Applications 2018, 77. [Google Scholar] [CrossRef]
- Li, Y.; Bolle, R.; Bolle, R. Automatic Neutral Face Detection Using Location and Shape. RC Computer Science 2001, 22259, 111–73. [Google Scholar]
- Khaireddin, Y.; Chen, Z. Facial emotion recognition: State of the art performance on FER2013. arXiv 2021, arXiv:2105.03588 2021. [Google Scholar]
- Kamachi, M.; Lyons, M.; Gyoba, J. The japanese female facial expression (jaffe) database. 1997. Available online: http://www. kasrl. org/jaffe. htm.
- Lyons, M.; Akamatsu, S.; Kamachi, M.; Gyoba, J. Coding facial expressions with Gabor wavelets 1998. pp. 200–205. [CrossRef]
- Lyons, M. “Excavating AI” Re-Excavated: Debunking a Fallacious Account of the Jaffe Dataset. SSRN Electronic Journal 2021. [Google Scholar] [CrossRef]
- Xue, M.; Liu, W.; Li, L. Person-independent facial expression recognition via hierarchical classification. 2013 IEEE Eighth International Conference on Intelligent Sensors, Sensor Networks and Information Processing 2013, pp. 449–454. [CrossRef]
- Toda, K.; Shinomiya, N. Machine learning-based fall detection system for the elderly using passive RFID sensor tags. 2019 13th International Conference on Sensing Technology (ICST) 2019, pp. 1–6. [CrossRef]
- Bradski, G. The OpenCV Library. Dr. Dobb’s Journal of Software Tools.
- Meena, G.; Mohbey, K.; Kumar, S.; Chawda, R.; Gaikwad, S. Image-Based Sentiment Analysis Using InceptionV3 Transfer Learning Approach. SN Computer Science 2023, 4. [Google Scholar] [CrossRef]
- Ali, L.; Alnajjar, F.; Jassmi, H.; Gochoo, M.; Khan, W.; Serhani, M. Performance Evaluation of Deep CNN-Based Crack Detection and Localization Techniques for Concrete Structures. Sensors 2021, 21, 1688. [Google Scholar] [CrossRef]
- Lin, M.; Chen, Q.; Yan, S. Network in network. arXiv 2013, arXiv:1312.4400 2013. [Google Scholar]
- Javid, A.M.; Das, S.; Skoglund, M.; Chatterjee, S. A relu dense layer to improve the performance of neural networks 2021. pp. 2810–2814. [CrossRef]
- Darapaneni, N.; Tanndalam, A.; Gupta, M.; Taneja, N.; Purushothaman, P.; Eswar, S.; Paduri, A.R.; Arichandrapandian, T. Banana Sub-Family Classification and Quality Prediction using Computer Vision. arXiv 2022, arXiv:2204.02581 2022. [Google Scholar]
- Htay, M.; Sinha, P.G.; Htun, H.; Thwe, P. COMPARISON OF PREPROCESSING METHOD USED IN FACIAL EXPRESSION RECOGNITION. 2019.
- Revina, I.; Emmanuel, W.S. A Survey on Human Face Expression Recognition Techniques. Journal of King Saud University - Computer and Information Sciences 2021, 33, 619–628. [Google Scholar] [CrossRef]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).