Book Image

PyTorch Deep Learning Hands-On

By : Sherin Thomas, Sudhanshu Passi
Book Image

PyTorch Deep Learning Hands-On

By: Sherin Thomas, Sudhanshu Passi

Overview of this book

PyTorch Deep Learning Hands-On is a book for engineers who want a fast-paced guide to doing deep learning work with PyTorch. It is not an academic textbook and does not try to teach deep learning principles. The book will help you most if you want to get your hands dirty and put PyTorch to work quickly. PyTorch Deep Learning Hands-On shows how to implement the major deep learning architectures in PyTorch. It covers neural networks, computer vision, CNNs, natural language processing (RNN), GANs, and reinforcement learning. You will also build deep learning workflows with the PyTorch framework, migrate models built in Python to highly efficient TorchScript, and deploy to production using the most sophisticated available tools. Each chapter focuses on a different area of deep learning. Chapters start with a refresher on how the model works, before sharing the code you need to implement it in PyTorch. This book is ideal if you want to rapidly add PyTorch to your deep learning toolset.
Table of Contents (11 chapters)
10
Index

Introduction to CNNs

CNNs are a decades-old machine learning algorithms that never proved their power until Geoffrey Hinton and his lab came up with AlexNet. Since then, CNNs have been through several iterations. Now we have a few different architectures built on top of CNNs, which power all the computer vision implementations around the world.

A CNN is a network architecture that fundamentally consists of small networks, almost like the simple feedforward network introduced in Chapter 2, A Simple Neural Network, but for solving problems with images as input. CNNs consist of neurons that have non-linearity, weight parameters, biases, and spit out one loss value based on which the whole network is rearranged using backpropagation.

If this sounds similar to simple fully connected networks, what makes CNNs special for processing images? CNNs let the developer make certain assumptions that are applicable to images, such as the spatial relation of pixel values.

Simple fully connected...