In this lecture I'm going to introduce you to the next section of the chorus which is on facial recognition
using Siamese networks.
Facial recognition has been a very controversial topic in the recent years as governments and basically
everyone who is not the government have competing interests.
So it's important for everyone to understand facial recognition its strengths and weaknesses and what
it can and cannot do so that you can be knowledgeable about how this technology will impact the way
we live.
Let's outline everything we will do in this section before moving on to the meat of the content.
I think what you'll find is the theory behind facial recognition for the algorithm we are about to discuss
is quite intuitive and simple.
You can probably arrive at a decent understanding of it in just five minutes.
The real challenge is going to be the little details that go into the implementation specifically a
lot of these little details have to do with data processing.
It's not so straightforward as here's a data set of inputs and targets.
Now throw them into a CNN usually that would require a very large set of images which technically we
have thanks to surveillance and people giving up their data to companies like Facebook and Instagram
but rather as we will learn we can train official recognition network without thousands or millions
of images.
So how can this be.
Think of how a facial recognition system might work.
Suppose I have a picture of you like say your student I.D. card and when you walk into a building a
camera will take a picture of you and compare that picture to your I.D. card.
So this is like a binary classification problem.
We want to know is it a match or not.
If we're given two pictures of the same person it should return a match.
If we're given two pictures of different people it should say it's not a match
all right.
So why does this approach require less data.
I don't want to get into too much detail right now but it all has to do with how we always want to consider
pairs.
Imagine we have three pictures a B and C..
How many possible pairs are there.
We have a b aC and B.C. if we have four pictures ABC NBC.
How many possible pairs are there.
Now we have a b aC a d B.C. BD and CB that's 6.
So what's the pattern.
In fact this is what we call a counting problem.
If we have any pictures then there are and choose two possible ways to combine different pictures.
This is equal to end times and minus one divided by two
so a lot of this section is just going to be figuring out how to load in the data split it up appropriately
and feed it into our facial recognition network.
Of course we'll still need to discuss the theory behind the algorithm and the special lost function
that we use in this scenario.
You'll also learn why this approach leads to imbalanced classes and how to evaluate the model which
is not as straightforward as usual.
Thanks for listening and I'll see you in the next lecture.