Great. So now that we have cleared all the baseline techniques, let's jump right into and think about what's transfer learning. So this is a great quote by Andrew Engie, of course, he's a huge figure in the AI ML space. And in 2016, he mentioned that transfer learning will be the great next driver of ML success. And we are right now in 2020. And I think that, and you would see that so many problems or so many models have come out to solve different kinds of models via transfer learning.
So what is it? So a quick understanding for it is just nothing but just a machine learning technique, where a model is kind of trained on one task and it's kind of repurposed for a second task. Now, we'll see what that means. So let's say you have a dataset, right? You have a dataset one, which is like, say, a general image dataset and why the target variable is a classified object. That object could be, you know, a cat or a dog, a tree, a bus, or a truck, anything, anything. Any worldly objects that's already there in the image dataset. An example of it is ImageNet. I'm sure all of you have worked a little bit or have tried your hands on with this dataset in your work. Now, this, in a general view, is like a structure of neural network with few hidden layers and input layers and an output layer. So the output layer for the dataset one problem would be the, you know, if the classification between if it's cat or dog or any other particular object from the training dataset.
Now, think about the second case. Now, the second case that you have a dataset two and that's a very small dataset. You do not have a lot of training cases, but you have few. And the target data set is if it's an image of an urban image or if it's a rural image. Like, so what do you think is the common, you know, connection between these two datasets? The datasets is like both of them deal with image, both of them have, you know, a lot of worldly objects captured into it. But the final goal is exactly not the same. So here, transfer learning comes into action where you can, you know, kind of utilize the knowledge from the data set one that you have created in your first phase of modeling and just, you know, retrain the last layer. Here, it's the layer four if you can see, I mentioned is the last layer dense layer, retrained the last layer weights using softmax and class and like, you know, create or change those a final output layer from classifying it into CAD dog ship tree, et cetera, to classifying it as urban or rural based on the new data set that we have intertwined with level four. Now this can seem that, okay, why are we doing this? We are before that. Let's see, where are we doing this? So like, say, even in speech recognition, if you're saying a scraping or voice data from different sources like YouTube, and that's an English or Hindi, which is like, you know, one of the languages that we speak back in India. And then you pre train your network. Now, say you have a very small data set in Bengali and you want to kind of, you know, translate or understand what the speech is. So you can utilize the model that you have trained with a bigger data set in English and then use like, you know, translation. And then you utilize that for speech recognition, which isn't Bengali. The second image, the second example is what we spoke about right now.
Comments