av-savchenko/face-emotion-recognition

Quick question (face-emotion recognition)

AmaiaBiomedicalEngineer opened this issue · 2 comments

Hello!
I'm trying to use your code and I don't understand the range in which the emotions go once you add a picture and run the code.
For example:
Happy: -4.876
Angry: 0.987654
And so on, which is the range in which this emotions can take values of?
Thank you very much,
Amaia

Hello!
I answered similar question in one if the previous issues. Let me quote a part of this answer:
By default, the PyTorch models return logits - output of the last layer before applying softmax. If you want to compute "probabilities", you need to apply softmax to the outputs of this model. It is an easy call of get_probabs() function (see example in abaw4_mtl_train.ipynb). But my HSEmotion library supports special flag logits, so you can call fer.predict_emotions(face_img,logits=False) to get probability values between 0 and 1 with sum equal to 1. Please, see example

Closing due to inactivity