The Deep Learning with PyTorch Workshop
eBook - ePub

The Deep Learning with PyTorch Workshop

Build deep neural networks and artificial intelligence applications with PyTorch

Hyatt Saleh

  1. 330 pages
  2. English
  3. ePUB (adapté aux mobiles)
  4. Disponible sur iOS et Android
eBook - ePub

The Deep Learning with PyTorch Workshop

Build deep neural networks and artificial intelligence applications with PyTorch

Hyatt Saleh

DĂ©tails du livre
Aperçu du livre
Table des matiĂšres
Citations

À propos de ce livre

Get a head start in the world of AI and deep learning by developing your skills with PyTorch

Key Features

  • Learn how to define your own network architecture in deep learning
  • Implement helpful methods to create and train a model using PyTorch syntax
  • Discover how intelligent applications using features like image recognition and speech recognition really process your data

Book Description

Want to get to grips with one of the most popular machine learning libraries for deep learning? The Deep Learning with PyTorch Workshop will help you do just that, jumpstarting your knowledge of using PyTorch for deep learning even if you're starting from scratch.

It's no surprise that deep learning's popularity has risen steeply in the past few years, thanks to intelligent applications such as self-driving vehicles, chatbots, and voice-activated assistants that are making our lives easier. This book will take you inside the world of deep learning, where you'll use PyTorch to understand the complexity of neural network architectures.

The Deep Learning with PyTorch Workshop starts with an introduction to deep learning and its applications. You'll explore the syntax of PyTorch and learn how to define a network architecture and train a model. Next, you'll learn about three main neural network architectures - convolutional, artificial, and recurrent - and even solve real-world data problems using these networks. Later chapters will show you how to create a style transfer model to develop a new image from two images, before finally taking you through how RNNs store memory to solve key data issues.

By the end of this book, you'll have mastered the essential concepts, tools, and libraries of PyTorch to develop your own deep neural networks and intelligent apps.

What you will learn

  • Explore the different applications of deep learning
  • Understand the PyTorch approach to building neural networks
  • Create and train your very own perceptron using PyTorch
  • Solve regression problems using artificial neural networks (ANNs)
  • Handle computer vision problems with convolutional neural networks (CNNs)
  • Perform language translation tasks using recurrent neural networks (RNNs)

Who this book is for

This deep learning book is ideal for anyone who wants to create and train deep learning models using PyTorch. A solid understanding of the Python programming language and its packages will help you grasp the topics covered in the book more quickly.

Foire aux questions

Comment puis-je résilier mon abonnement ?
Il vous suffit de vous rendre dans la section compte dans paramĂštres et de cliquer sur « RĂ©silier l’abonnement ». C’est aussi simple que cela ! Une fois que vous aurez rĂ©siliĂ© votre abonnement, il restera actif pour le reste de la pĂ©riode pour laquelle vous avez payĂ©. DĂ©couvrez-en plus ici.
Puis-je / comment puis-je télécharger des livres ?
Pour le moment, tous nos livres en format ePub adaptĂ©s aux mobiles peuvent ĂȘtre tĂ©lĂ©chargĂ©s via l’application. La plupart de nos PDF sont Ă©galement disponibles en tĂ©lĂ©chargement et les autres seront tĂ©lĂ©chargeables trĂšs prochainement. DĂ©couvrez-en plus ici.
Quelle est la différence entre les formules tarifaires ?
Les deux abonnements vous donnent un accĂšs complet Ă  la bibliothĂšque et Ă  toutes les fonctionnalitĂ©s de Perlego. Les seules diffĂ©rences sont les tarifs ainsi que la pĂ©riode d’abonnement : avec l’abonnement annuel, vous Ă©conomiserez environ 30 % par rapport Ă  12 mois d’abonnement mensuel.
Qu’est-ce que Perlego ?
Nous sommes un service d’abonnement Ă  des ouvrages universitaires en ligne, oĂč vous pouvez accĂ©der Ă  toute une bibliothĂšque pour un prix infĂ©rieur Ă  celui d’un seul livre par mois. Avec plus d’un million de livres sur plus de 1 000 sujets, nous avons ce qu’il vous faut ! DĂ©couvrez-en plus ici.
Prenez-vous en charge la synthÚse vocale ?
Recherchez le symbole Écouter sur votre prochain livre pour voir si vous pouvez l’écouter. L’outil Écouter lit le texte Ă  haute voix pour vous, en surlignant le passage qui est en cours de lecture. Vous pouvez le mettre sur pause, l’accĂ©lĂ©rer ou le ralentir. DĂ©couvrez-en plus ici.
Est-ce que The Deep Learning with PyTorch Workshop est un PDF/ePUB en ligne ?
Oui, vous pouvez accĂ©der Ă  The Deep Learning with PyTorch Workshop par Hyatt Saleh en format PDF et/ou ePUB ainsi qu’à d’autres livres populaires dans Ciencia de la computaciĂłn et ProgramaciĂłn en Python. Nous disposons de plus d’un million d’ouvrages Ă  dĂ©couvrir dans notre catalogue.

Informations

Année
2020
ISBN
9781838981846

1. Introduction to Deep Learning and PyTorch

Overview
This chapter introduces the two main topics of this book: deep learning and PyTorch. Here, you will be able to explore some of the most popular applications of deep learning, understand what PyTorch is, and use PyTorch to build a single-layer network, which will be the starting point for you to apply your learning to real-life data problems. By the end of this chapter, you will be able to use PyTorch's syntax to build neural networks, which will be essential in subsequent chapters.

Introduction

Deep learning is a subset of machine learning that focuses on using neural networks to solve complex data problems. It is becoming increasingly popular nowadays, thanks to advances in software and hardware that allow us to gather and process large amounts of data (we are talking about millions and billions of entries). This is important considering that deep neural networks require vast amounts of data to perform well.
Some of the most well-known applications of deep learning are self-driving vehicles, popular chatbots, and a wide variety of voice-activated assistants, which will be further explained in this chapter.
PyTorch was launched back in 2017, and its main characteristic is that it uses graphics processing units (GPUs) to process data using "tensors". This allows algorithms to run at high speeds and, at the same time, it provides its users with flexibility and a standard syntax to obtain the best results for many data problems. Furthermore, PyTorch uses dynamic computational graphs that allow you to make changes to the network on the go. This book demystifies neural networks using PyTorch and helps you understand the complexity of neural network architectures.

Why Deep Learning?

In this section, we will cover the importance of deep learning and the reasons for its popularity.
Deep learning is a subset of machine learning that uses multi-layer neural networks (large neural networks), inspired by the biological structure of the human brain, where neurons in a layer receive some input data, process it, and send the output to the following layer. These neural networks can consist of thousands of interconnected nodes (neurons), mostly organized in different layers, where one node is connected to several nodes in the previous layer from where it receives its input data, as well as being connected to several nodes in the following layer, to which it sends the output data after it has been processed.
Deep learning's popularity is due to its accuracy. It has achieved higher accuracy levels than other algorithms have ever before for complex data problems such as natural language processing (NLP). Deep learning's ability to perform outstandingly well has reached levels where machines can outperform humans, such as in the case of fraud detection. Deep learning models can not only optimize processes but also improve their quality. This has meant advances in revolutionary fields where accuracy is vital for safety reasons, such as self-driven cars.
Even though neural networks were theorized decades ago, there are two main reasons why they have recently become popular:
  • Neural networks require, and actually capitalize on, vast amounts of labeled data to achieve an optimal solution. This means that for the algorithm to create an outstanding model, it requires hundreds of thousands or even millions of entries, containing both the features and the target values. For instance, as regards the image recognition of cats, the more images you have, the more features the model is able to detect, which makes it better.
    Note
    Labeled data refers to data that contains a set of features (characteristics that describe an instance) and a target value (the value to be achieved); for example, a dataset containing demographical and financial information, with a target feature that determines the wage of a person.
    The following plot shows the performance of deep learning against other algorithms in terms of the quantity of data:
Figure 1.1: Performance of deep learning against other algorithms
Figure 1.1: Performance of deep learning against other algorithms
This is possible nowadays thanks to advances in software and hardware that allow us to gather and process such granularity.
  • Neural networks require considerable computing power to be able to process such large amounts of data without taking weeks (or even longer) to be trained. Because the process of achieving the best possible model is based on trial and error, it is necessary to be able to run the training process as efficiently as possible.
    This can be achieved today through the use of GPUs, which can cut down the training time of a neural network from weeks to hours.
    Note
    With the objective of accelerating deep learning in order to be able to make use of large amounts of training data and construct state-of-the-art models, field-programmable gate arrays (FPGAs) and tensor processing units (TPUs) are being developed by major cloud computing providers, such as AWS, Microsoft Azure, and Google.

Applications of Deep Learning

Deep learning is revolutionizing technology and is already impacting our lives. Deep learning can be applied to a wide variety of situations, ranging from medical and safety (such as fraud detection) purposes to more trivial tasks, such as colorizing black and white images or translating text in real time.
Some of the applications of deep learning that are either under development or in use today include the following:
  • Self-driving vehicles: Several companies, such as Google, have been working on the development of partially or totally self-driving vehicles that learn to drive by using digital sensors to identify the objects around them.
  • Medical diagnosis: Deep learning is impacting this industry by improving the diagnosis accuracy of terminal diseases such as brain and breast cancer. This is done by classifying X-rays (or any other diagnostic imagery mechanisms) of new patients, based on labeled X-rays from previous patients that did or did not have cancer.
  • Voice assistants: This may be one of the most popular applications nowadays, due to the proliferation of different voice-activated intelligent assistants, such as Apple's Siri, Google Home, and Amazon's Alexa.
  • Automatic text generation: This means generating new text based on an input sentence. This is popularly used in email writing, where the email provider suggests the next couple of words to the user, based on the text that's already been written.
  • Advertising: In the commercial world, deep learning is helping to increase the return on investment of advertising campaigns by targeting the right audiences and by creating more effective ads. One example of this is the generation of content in order to produce up-to-date and informative blogs that help to engage current customers and attract new ones.
  • Price forecasting: For beginners, this is a typical example of what can be achieved through the use of machine learning algorithms. Price forecasting consists of training a model based on real data. For instance, in the field of real estate, this would consist of feeding a model with property characteristics and their final price in order to be able to predict the prices of future entries based solely on property characteristics.

Introduction to PyTorch

PyTorch is an open source library developed mainly by Facebook's artificial intelligence research group as a Python version of Torch.
Note
Torch is an open source, scientific computing framework that supports a wide variety of machine learning algorithms.
PyTorch was first released to the public in January 2017. It uses the power of GPUs to speed up the computation of tensors, which accelerates the training times of complex models.
The library has a C++ backend, combined with the deep learning framework of Torch, which allows much faster computations than native Python libraries with many deep learning features. The frontend is in Python, which has helped it gain popularity, enabling data scientists new to the library to construct complex neural networks. It is possible to use PyTorch alongside other popular Python packages.
Although the PyTorch is fairly new, it has gained popularity quickly as it was developed using feedback from many experts in the field. This has led PyTorch to become a useful library for users.

GPUs in PyTorch

GPUs were originally developed to speed up computation...

Table des matiĂšres

  1. The Deep Learning with PyTorch Workshop
  2. Preface
  3. 1. Introduction to Deep Learning and PyTorch
  4. 2. Building Blocks of Neural Networks
  5. 3. A Classification Problem Using DNN
  6. 4. Convolutional Neural Networks
  7. 5. Style Transfer
  8. 6. Analyzing the Sequence of Data with RNNs
  9. Appendix
Normes de citation pour The Deep Learning with PyTorch Workshop

APA 6 Citation

Saleh, H. (2020). The Deep Learning with PyTorch Workshop (1st ed.). Packt Publishing. Retrieved from https://www.perlego.com/book/1694586/the-deep-learning-with-pytorch-workshop-build-deep-neural-networks-and-artificial-intelligence-applications-with-pytorch-pdf (Original work published 2020)

Chicago Citation

Saleh, Hyatt. (2020) 2020. The Deep Learning with PyTorch Workshop. 1st ed. Packt Publishing. https://www.perlego.com/book/1694586/the-deep-learning-with-pytorch-workshop-build-deep-neural-networks-and-artificial-intelligence-applications-with-pytorch-pdf.

Harvard Citation

Saleh, H. (2020) The Deep Learning with PyTorch Workshop. 1st edn. Packt Publishing. Available at: https://www.perlego.com/book/1694586/the-deep-learning-with-pytorch-workshop-build-deep-neural-networks-and-artificial-intelligence-applications-with-pytorch-pdf (Accessed: 14 October 2022).

MLA 7 Citation

Saleh, Hyatt. The Deep Learning with PyTorch Workshop. 1st ed. Packt Publishing, 2020. Web. 14 Oct. 2022.