thoughtworksarts / EmoPy

A deep neural net toolkit for emotion analysis via Facial Expression Recognition (FER)
https://thoughtworksarts.io/blog/emopy-emotional-expression-toolkit/
GNU Affero General Public License v3.0
919 stars 264 forks source link

inaccurate emotion classification #34

Open octopousprime opened 4 years ago

octopousprime commented 4 years ago

Hi I used the pre-trained 7 emotions model but it gives me the same result (anger = 100%) irrespective of the input image provided. Can someone please provide me with an explanation of why this is happening? Thanks in advance.

xuv commented 4 years ago

@octopousprime Thanks for reaching out and submitting this. It sounds related to #33.

Will see what we can do about this, but it sounds like a bug.

octopousprime commented 4 years ago

Thanks! I appreciate if you can inform me when would you expect to investigate and resolve this bug; as I have an ongoing research that depends on the accuracy of the results.

microcosm commented 4 years ago

This doesn't look so similar to issue #33, because that issue describes inaccurate results. @octopousprime's issue describes a completely wrong result - 100%

However, this issue has been stale a while. I'm going to close it for now as we are trying to get a handle on the most crucial issues. @octopousprime please can you re-open this if you are still having a problem and we'll find someone to take a look at it - thanks

gri1 commented 4 years ago

I'm having the same issue, @microcosm. If I just change fermodel_example.py to use all 7 emotions:

target_emotions = ['calm', 'anger', 'happiness', 'surprise', 'disgust', 'fear', 'sadness']

Then I get the following output:

Predicting on happy image...
anger: 100.0%
disgust: 0.0%
fear: 0.0%
happiness: 0.0%
sadness: 0.0%
surprise: 0.0%
calm: 0.0%
Predicting on disgust image...
anger: 100.0%
disgust: 0.0%
fear: 0.0%
happiness: 0.0%
sadness: 0.0%
surprise: 0.0%
calm: 0.0%
Predicting on anger image...
anger: 98.3%
disgust: 0.0%
fear: 1.0%
happiness: 0.7%
sadness: 0.0%
surprise: 0.0%
calm: 0.0%

Therefore it seems this model can only predict anger.

Richardng12 commented 3 years ago

Leaving a comment to say I have the same problem.

Trained a model on FERPlus dataset using Conv_dropout_model. Relevant model plus emotion_map was exported using the methods in neuralnets

When predicting using fer_model_example, all images return 100% on one of the emotions. E.g anger -100% Either the model trained is incorrect, or the method used to predict is incorrect - not quite sure which one