Action Certainer using Transfer Learning in Pytorch

Original article was published on Deep Learning on Medium


Action Certainer using Transfer Learning in Pytorch

Hi everyone! Happy to see you all again!

Hope you all doing great!!

Today let me explain something interesting out everywhere called “Transfer Learning” along with my trained model for better understanding step by step.

Transfer Learning

Transfer Learning is nothing but utilizing already existing high performance open-source models and their trained weights and doing some tweaks to model by freezing and/or adding some layers to the model according to our data for best performance in minimal amount of time.

There are some more details about it. Let me explain them on the go.

Dataset

I took this awesome dataset from Kaggle .It is a good combination of Fight and Non-Fight images which accounts for 8 classes. This will help us to determine how we can handle complex combinations of data using Transfer Learning. Fr further details, visit the dataset .

Note

Please go through the code blocks and read the comments in the code block for sure to get better understanding.

Now let’s get into action.

I have hosted the code at kaggle and at Github — Feel feel to fork it.

Firstly we will import all the necessary modules and state the labels i.e names of the classes.