Closed chaelin0722 closed 3 years ago
x_score_norm should be classified by appropriate classifier, e.g., LinearSVC trained on the AFEW dataset. I did not save such a classifier, but you could train it by your own. However, I recommend you to start with more simple option. You could use original base_model without feature extraction, and run it for each facial region in a frame. In such case you could display immediate emotion of each frame (your face_img variable). Just take a look at my examples for a single photo. The emotion may rapidly change because it is better to combine the results for several sequential frames, but even such a simple technique should works rather well. I do not believe that classifier trained on AFEW will be much better because this dataset is rather small
thank you for specific advice!
Hello.
Thanks for your code. I am trying to run your code on webcam and face a problem.
This is my code fixed from your code "AFEW_train.ipynb" for real-time face emotion recognition.
now i'm having problem predicting face emotion from "x_score_norm" which has shape=(None, 4096). Can you help me how to classify facial emotion in 7 emotions by using this variable?