PyTorch Tutorial
This repository contains material to get started with PyTorch v1.7. It was the base for this [pytorch tutorial] from PyData Berlin 2018.
Table of Contents
PART 0 - Foreword
- Foreword - Why PyTorch and why not? Why this talk?
PART 1 - Basics
- PyTorch basics - tensors, GPU, autograd - open in colab
- Debugging - open in colab
- Example: linear regression - open in colab
- Storing and loading models - open in colab
- Working with data -
Dataset
,DataLoader
,Sampler
,transforms
- open in colab
PART 2 - Computer Vision
PART 3 - Misc, Cool Applications, Tips, Advanced
- Torch JIT - open in colab
- Hooks - register functions to be called during the forward and backward pass - open in colab
- Machine Learning 101 with numpy and PyTorch - open in colab
- PyTorch + GPU in Google's Colab
- Teacher Forcing
- RNNs from Scratch - open in colab
- Mean Shift Clustering - open in colab
PART -2 - WIP and TODO
- TODO
nn
andnn.Module
- TODO Deployment
- TODO Deployment with TF Serving
- TODO
nn.init
- TODO PyTorch C++ frontend
PART -1 - The End
Setup
Requirements
- Python 3.8
Install Dependencies
python3.8 -m venv .venv
source .venv/bin/activate.fish
pip install -r requirements.txt
Optional
Run the following to enable the jupyter table of contents plugin:
jupyter labextension install @jupyterlab/toc
jupyter nbextension enable --py widgetsnbextension
Download data and models
Download data and models for the tutorial:
python download_data.py
Then you should be ready to go. Start jupyter lab:
jupyter lab
Prior Versions
- Version of this tutorial for the PyData 2018 conference: [material] [video]