Course 4, Week 4, Assignment 1, Question about the pre-trained model

Hey -

I have a question about the pre-trained model loaded into this assignment to complete the face verification/recognition tasks. How was the pre-trained model created? Were pictures of the people in this organization (e.g., Kian, Younes, etc.) used as part of some big dataset to train the “keras-facenet” model with the triplet loss function? What if the people in this organization were not part of the training dataset for the “keras-facenet” model? Would the accuracy in terms of the distances then be adversely affected? Thanks for any clarification.

Have you tried googling “facenet keras”? Here’s the top hit I get from that search. Looks like an interesting place to start. Jason Brownlee’s website is a great source for anything related to AI and Machine Learning.

The overall answer is that it’s a generic model trained on a large database of images that does not include the staff of this course. But then you can do “transfer learning” by doing additional training on a dataset that is particularly of interest to you or just use the model “as is” and see how it does.

Thank you, Paul, I will check them out.

Hello I was wondering the same thing. Thanks for the answer.
Also : why this model gives poor results on webcam photos ?

Should I try to use transfer learning on various identities webcam photos to improve its accuracy ?

The first step in figuring that out would be to understand more about the training set that was used to train that model. Did you look at the link I gave in my previous reply? If it turns out that there is some fundamental difference in the training images from the webcam images that you care about, then it might well require some additional training to improve the model’s performance on your images.

The other potential issue was discussed on your other thread: the model expects normalized images. If you feed it raw RGB images even of the correct size, but with 0 - 255 values for the pixels, you’ll get terrible results. They describe in the notebook how to normalize the images and even give us the code to do it.