Image for post
Image for post
Photo by Tyler Easton on Unsplash

PyTorch is a Python package developed by Facebook AI designed to perform numerical calculations using tensor programming. It also allows its execution on GPU to speed up calculations.

Typically PyTorch is used both to replace numpy and process calculations on GPUs, and for research and development of machine learning algorithms including neural networks.

As part of the course at “Deep Learning with PyTorch: Zero to GANs”, I’ll briefly explore five simple but useful functions of PyTorch package, providing some examples of a correct execution as well as cases in which it fails. The functions chosen are:

  • torch.rand()
  • torch.arange()
  • torch.transpose()

Diego Gachet Páez

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store