What Is PyTorch

This section provides a quick introduction on PyTorch, which is a Python-based scientific computing package targeted at two sets of audiences: A replacement for NumPy to use the power of GPUs and a deep learning research platform that provides maximum flexibility and speed.

What Is PyTorch? PyTorch is a Python-based scientific computing package targeted at two sets of audiences: A replacement for NumPy to use the power of GPUs and a deep learning research platform that provides maximum flexibility and speed. PyTorch was originally developed as a research framework by a Facebook intern in 2017.

PyTorch is divided into the following components:

1. torch - Numpy like library for tensors with GPU support.

2. torch.autograd - Give differentiation support for all operations on tensors.

3. torch.nn - Provides classes necessary for building neural networks.

4. torch.optim - Provides optimization methods for different neural network models.

5. torch.utils - Provides classes for data processing.

6. torch.nn.Module - A container that all models (layers with trainable parameters) should inherited from because it tracks the trainable parameters.

7. torch.nn.functional - A functional interface (no trainable parameters) that has ops for building neural networks (loss and activation functions).

Table of Contents

 About This Book

 Deep Playground for Classical Neural Networks

 Building Neural Networks with Python

 Simple Example of Neural Networks

 TensorFlow - Machine Learning Platform

PyTorch - Machine Learning Platform

What Is PyTorch

 Install PyTorch Library

 Commonly Used 'torch' functions

 Gradio - ML Demo Platform

 CNN (Convolutional Neural Network)

 RNN (Recurrent Neural Network)

 GNN (Graph Neural Network)

 GAN (Generative Adversarial Network)

 Performance Evaluation Metrics

 References

 Full Version in PDF/EPUB