ResNet — 101 with PyTorch

PyTorch Logo (https://pytorch.org/)

So, How can you make a CNN perform better ? ??

Backpropagation in a neural net
Fig 1: Backpropagation in a neural net (https://deepai.org/machine-learning-glossary-and-terms/backpropagation)

Kaiming He and CoAuthors from the Microsoft Research team,in December 2015 came up with ResNets (https://arxiv.org/pdf/1512.03385.pdf)

Fig 2: Skip connection in a Resnet.

Let’s go ahead and implement a vanilla ResNet in PyTorch

Fig 3: nn module and the nn.functional module imported
Fig 4: Layer definition for our ResNet
Fig 5: forward function with skip connection

And there you go. That was a small and basic introduction to skip connection and ResNets in PyTorch.

--

--

Machine Learning Engineer II at Swiggy. On a quest for technology.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Abhishek Bose

Machine Learning Engineer II at Swiggy. On a quest for technology.