microsoft / FERPlus

This is the FER+ new label annotations for the Emotion FER dataset.
https://arxiv.org/abs/1608.01041
Other
594 stars 166 forks source link

Distorting the image on new images to predict #12

Open handav opened 5 years ago

handav commented 5 years ago

@ebarsoumMS @cha-zhang Is distorting the images a necessary step for new images I'm predicting on? Any other guidance for preprocessing new images to feed into the trained model?

amirhfarzaneh commented 5 years ago

If you mean data augmentation by distortion then no! Data augmentation is a common practice only for the training set. Some people also do data augmentation on the test set to see if their network generalizing well or not. On the other hand, pre-processing is different than data augmentation. The authors apply pre-processing to enhance the contrast between the face and background. They are actually doing histogram equalization. You want your test set and train set to be of same distribution and since pre-processing is already applied on training set you have to apply it on the test set as well. You might notice performance decrease if you don't pre-process your test set. You can read more about other pre-processing techniques for FER applications in this survey: https://arxiv.org/abs/1804.08348

handav commented 5 years ago

No, apologies for being unclear - I mean what preprocessing should I be doing on new images that I’m using the trained model to predict? Cropping to the face and resizing to 64x64 is clear, and I’m also calling the normalize and preprocessing function on it from img_util. Does that sound right?

On Apr 11, 2019, at 5:15 PM, Amir H. Farzaneh notifications@github.com wrote:

If you mean data augmentation by distortion then yes! Data augmentation is a common practice even for larger datasets. This way the network gets to see more perturbed example for better generalizations. The authors also do pre-processing which is enhancing the contrast between the face and background. They are actually doing histogram equalization. This is also a common pre-processing for face recognition/facial expression recognition techniques. You can read more about other pre-processing techniques for FER applications in this survey: https://arxiv.org/abs/1804.08348

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

amirhfarzaneh commented 5 years ago

There is no cropping to the face that I'm aware of!

These three steps are necessary!