Book Image

Deep Learning with PyTorch Quick Start Guide

By : David Julian
Book Image

Deep Learning with PyTorch Quick Start Guide

By: David Julian

Overview of this book

PyTorch is extremely powerful and yet easy to learn. It provides advanced features, such as supporting multiprocessor, distributed, and parallel computation. This book is an excellent entry point for those wanting to explore deep learning with PyTorch to harness its power. This book will introduce you to the PyTorch deep learning library and teach you how to train deep learning models without any hassle. We will set up the deep learning environment using PyTorch, and then train and deploy different types of deep learning models, such as CNN, RNN, and autoencoders. You will learn how to optimize models by tuning hyperparameters and how to use PyTorch in multiprocessor and distributed environments. We will discuss long short-term memory network (LSTMs) and build a language model to predict text. By the end of this book, you will be familiar with PyTorch's capabilities and be able to utilize the library to train your neural networks with relative ease.
Table of Contents (8 chapters)

Approaches to machine learning

Prior to general machine learning, if we wanted to, for example, build a spam filter, we could start by compiling a list of words that commonly appear in spam. The spam detector then scans each email and when the number of blacklisted words reaches a threshold, the email would be classified as spam. This is called a rules-based approach, and is illustrated in the following diagram:

The problem with this approach is that once the writers of spam know the rules, they are able to craft emails that avoid this filter. The people with the unenviable task of maintaining this spam filter would have to continually update the list of rules. With machine learning, we can effectively automate this rule-updating process. Instead of writing a list of rules, we build and train a model. As a spam detector, it will be more accurate since it can analyze large volumes...