To force the net to learn better, choose Andrew Yang as the negative sample for Andrew Ng. :-p
@songpandy9590 Жыл бұрын
Clearly explained. Thank you.
@logicboard77462 жыл бұрын
The fun fact at the end is mind blowing :-)
@ahhhwhysocute3 жыл бұрын
Thank you, this was very well explained and easy to understand !
@allancentis3003 жыл бұрын
very nicely done :)
@alessandrocornacchia81254 жыл бұрын
Thanks for your clear explanation
@pranavgandhiprojects5 ай бұрын
Loved the explaination...thanks
@IgneousGorilla3 жыл бұрын
Why is the squared norm used instead of just the norm, the actual euclidean distance?
@Darkev772 жыл бұрын
If you get an answer please lmk
@fabiansvensson95882 жыл бұрын
Hello! Why is it mandatory to have multiple images of the same person for the training? I'm creating an algorithm where I want to use SNNs to map photos of a product to a system-genereted image of the same product. The problem is that the products are personalized, so each product is unique. I therefore only have one image of each product. Why can I not simply create triplets with tons of different images. Why is it mandatory to have several photos of the same person/product?
@phoenix-hg8oq3 жыл бұрын
Thanks a lot sir....sir what is the significance of anchor here?why we choose anchor and positive from same class?
@kwon01285 жыл бұрын
exellent and absolutely best explanation thank you
@gorgolyt3 жыл бұрын
Why don't we just seek to always minimise |f(A) - f(P)|^2 - |f(A) - f(N)|^2 ? Instead of the max method which only minimises this when it's >= -alpha.
@Darkev772 жыл бұрын
If you found the answer please lmk
@samuelleecong45852 жыл бұрын
From my understanding it's to ensure that there is a larger difference between the positive and negative examples, so as to train your model to be more sensitive in identifying differences, forcing the difference function for the positive and negative functions to have more than a small difference i.e. 0.1, to the alpha value of maybe 5 or 6.
@raphaelnoronha14195 ай бұрын
Ok, but what I am looking at the end of it? (1) The weights (W) that transform the image matrix (Ii) in a vector (such as f(a)) --> Ii * W = F(Ii) = vector with n dimensions? (2) Such parameters (W) should be constant for any image?
@Acha4133 жыл бұрын
Hello Professor, I have a qeary. Why do we use squared norms to compute the distance between two examples (A,P or A,N). Isn't cosine a better way to compute the similarity between two examples (A,P or A,N). Because squared norms might have larger magnitude, even if they were closer to each other (that is angle between them is smaller), Hence , is cos(A,N)
@Darkev772 жыл бұрын
Please lmk if you found an answer
@Acha4132 жыл бұрын
we use square in the distance (f(A) - f(P))^2 because we do not want -ve values. In other word distance between (3-5)^2 = (5-3)^2 are same because we took square. In Machine Learning, we want to compute the gradient (1st order derivative) of this function for minimising the loss. For that purpose, we square the loss function and then minimize it. Also we can consider absolute value but first order derivative of absolute value at 0 does not exist. Hence even though abs(loss) is continuous, it is still not differentiable at 0. Hence Square is easier to differentiate and also it will square the error and. choose a model which minimizes the larger errors more than smaller errors. Due to these 2 reasons, i think square is a better choice for loss function.
@sharadchandakacherla8268 Жыл бұрын
Thank you sir.
@felixgao74178 ай бұрын
Question on choose triplets that are hard to train on. How to do that in practice you have a million pictures, is a human go to judge the two images with close enough distance between d(A, N) and d(A, P) and say, they are different use that for training?
@linzhu5178 Жыл бұрын
How do we differentiate this loss?
@vikramsandu60543 жыл бұрын
Well explained. Thanks for the video.
@LeenaGurgPhysics4 жыл бұрын
Can I use one of these face recognition pre-trained models to recognise plants?
@TimeKnowledgePower4 жыл бұрын
@leena perhaps the first few layers since they are looking for patterns of complex shapes such as faces, but the deeper the layers go the less likely you are to have a super relatable model.
@LeenaGurgPhysics4 жыл бұрын
@@TimeKnowledgePower Thank you for your suggestion. Will try this!
@sandipansarkar92113 жыл бұрын
nice explantion .
@meghnavasudeva48984 жыл бұрын
Now I can understand how DeepFakes would have been named :D
@furkatsultonov99763 жыл бұрын
or it could have been named as FakeNet lol
@debarunkumer20194 жыл бұрын
What if the pictures are of the same person from two different timelines? Will the model still work?
@clemsch904 жыл бұрын
If you train a neural network that's detecting throats, is it called "deepthroat"?
@WooblyBoobly4 жыл бұрын
someone's asking the real questions
@kaustubhparmar42744 жыл бұрын
ballsDeep
@nailcankara81644 жыл бұрын
Can I choose big margin for hard train?
@petarulev69772 жыл бұрын
I dont understand why the loss should be minimzed instead of maximized. After all, we want the difference between f(true) - f(neg) to be as large as possible.
@Frosp Жыл бұрын
because you want to minimize f(true) and maximize f(neg) therefore minimize -f(neg)
@AvinashSingh-bk8kg3 жыл бұрын
@08:15 - 9:21 , We need multiple samples of a person in our database to train the model using triple loss while only one sample image of a person while testing. Is it what Mr Andrew meant to say? If that is the case how can we call it one shot learning as we are training our model on multiple images of a person. Kindly clarify.
@osiris11023 жыл бұрын
I think we only need to train the network once and you can use random pictures from the internet to train it so that it can tell us that the two given pictures are of the same person or not. Then we can give it two images of the same person and it should be able to tell us if that's the same person or not.
@nidanoorain63393 жыл бұрын
Triplet loss:it helps in updating hyper parameters such as weights and bias of the network.When a new face is added we dont retrain the network since it requires huge calculations.We train when large data is added.Normally the output of the model is not a classification but a function(which can generate encoding (128d) for faces). One-shot: The new face is given to the network with same architecture with same weights and biases(trained with triplet loss) and similarity is calculated between the new and old faces using a similarity function which gives true if same face or false if different, then we can add the new face by giving the image to network to generate embedding. Here instead of retraining the model we can just create the embedding of image with pretrained model and dump to pickle file or any for classification.Correct me if am wrong hope it helps..
@ajaykannan60313 жыл бұрын
@@nidanoorain6339 "then we can add the new face by giving the image to network to generate embedding. " - So, in one shot, is the network adding the new Images and then training them too during the testing phase?
@nidanoorain63393 жыл бұрын
@@ajaykannan6031 it doesn't train in one-shot.. its like a classification task.for example if a new face needs to be added then give image to the network or model it creates embedding..now compare the embedding with previous embedding(ie..the embedding of the previous faces should also be saved in a file) by using similarity function keep some threshold, if the embedding similarity say is < 0.5 add the new face label and its embedding in the previous saved feature file...all together one-shot says if its same person or not we need to write condition to save the person to database with its embedding...hope it helps
@harrrymok4 жыл бұрын
thanks for the nice presentation, when i load the facenet model by tf.keras.models.load_model('facenet_keras.h5') with tensorflow 2.2, it keeps raising error (ValueError: bad marshal data (unknown type code), may i know is there any idea to mitigate it?
@nidanoorain63393 жыл бұрын
For anyone who is trying to load the model try it with keras 2.3.1 if it didnt then downgrade tf to 2.0.0 and keras 2.3.1 hope it helps
@kbstudios84026 жыл бұрын
How can we validate a dataset learnt using a Siamese network and triplet loss?
@donm79066 жыл бұрын
by testing whether it can recognize you, or 100 persons.
@GilangD216 жыл бұрын
the similiarity function?, the point is the model will produce 2 outputs, that is mean only two label which is "same" or "not same". then after that we keep validate is it produce the same label or not as what we do in usual supervised neural network.
@samuelbarham84836 жыл бұрын
You take the triplet loss over a heldout validation set.
@md.rijoanrabbi995 жыл бұрын
may i encode my own image using 2 layer neural network? instead of inception block ?is it use of supervise learning or on encoding occured in the inception or facenet unit?
@abdengineer62254 жыл бұрын
hello can i detect the person wich wear mask
@nayeonhan14064 жыл бұрын
@abd engineer Yeah you can detect people wearing masks!! You can detect whether the person is wearing a mask or not here: www.pyimagesearch.com/2020/05/04/covid-19-face-mask-detector-with-opencv-keras-tensorflow-and-deep-learning/ and you can detect the person wearing masks here: openaccess.thecvf.com/content_cvpr_2017/papers/Ge_Detecting_Masked_Faces_CVPR_2017_paper.pdf you can also get datasets of people wearing masks in here: datatang.ai/dataset/info/image/1084 These are only a few models and papers I searched, you may find many other models than these! Hope this will help you
@julessci27162 жыл бұрын
Nobody explains like A. Ng
@sylus1212 жыл бұрын
Good for facial expression recognition
@black-snow4 жыл бұрын
damn, upvote 665, off by one
@sadkntt5 жыл бұрын
Thanks so much, briliant, please add some python code
@gabrielwong19913 жыл бұрын
Choose triplets that are hard to train on.... So use entire training set as asian because we all look the same :D? haha
@arisioz Жыл бұрын
Is this your wife?
@jsonbourne8122 Жыл бұрын
You thought it was his wife, but it was me, Alpharius!