ML TLDR Profile picture
Not active anymore. Used to be run by @gowthami_s and @kamalgupta09.

Apr 6, 2021, 5 tweets

Depending on the problem we are trying to solve, the loss function varies. Today we are going to learn about Triplet losses. You must have heard about it while reading about Siamese networks.

#MachineLearning #DeepLearning #RepresentationLearning

Triplet loss is an important loss function for learning a good “representation”. What’s a representation you ask? Finding similarity (or difference) between two images is hard if you just use pixels.

So what do we do about it - given three images cat1, cat2, dog, we use a neural network to map the images to vectors f(cat1), f(cat2), and f(dog).

Now as the name suggests, triplet loss takes 3 inputs, and tries to minimize the distance between cat images, and maximize the distance between cat and dog images. That’s it!

That’s it. See this image from Bromley, Guyon and @ylecun ’s 1994 paper - “Signature Verification using a Siamese Time Delay Neural Network”. Do you notice the parallels?

Share this Scrolly Tale with your friends.

A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.

Keep scrolling