6 Core PyTorch: Autograd, optimizers, and utilities

This chapter covers

  • Understanding automatic differentiation
  • Using automatic differentiation with PyTorch tensors
  • Getting started with PyTorch SGD and Adam optimizers
  • Applying PyTorch to linear regression with gradient descent
  • Using data set batches for gradient descent
  • PyTorch Dataset and DataLoader utility classes for batches

In chapter 5, you learned about the tensor, a core PyTorch data structure for n-dimensional arrays. The chapter illustrated the significant performance advantages of PyTorch tensors over native Python data structures for arrays and introduced PyTorch APIs for creating tensors as well as performing common operations on one or more tensors.

This chapter teaches another ...

Get MLOps Engineering at Scale now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.