Shortcuts

PyTorch Recipes

  1. defining_a_neural_network.py

    Defining a Neural Network in PyTorch https://pytorch.org/tutorials/recipes/recipes/defining_a_neural_network.html

  2. what_is_state_dict.py

    What is a state_dict in PyTorch https://pytorch.org/tutorials/recipes/recipes/what_is_state_dict.html

  3. saving_and_loading_models_for_inference.py

    Saving and loading models for inference in PyTorch https://pytorch.org/tutorials/recipes/recipes/saving_and_loading_models_for_inference.html

  4. custom_dataset_transforms_loader.py

    Developing Custom PyTorch Dataloaders https://pytorch.org/tutorials/recipes/recipes/custom_dataset_transforms_loader.html

  5. Captum_Recipe.py

    Model Interpretability using Captum https://pytorch.org/tutorials/recipes/recipes/Captum_Recipe.html

  6. dynamic_quantization.py

    Dynamic Quantization https://pytorch.org/tutorials/recipes/recipes/dynamic_quantization.html

  7. warmstarting_model_using_parameters_from_a_different_model.py

    Warmstarting models using parameters from different model https://pytorch.org/tutorials/recipes/recipes/warmstarting_model_using_parameters_from_a_different_model.html

  8. zeroing_out_gradients.py

    Zeroing out gradients https://pytorch.org/tutorials/recipes/recipes/zeroing_out_gradients.html

  9. mobile_perf.py

    PyTorch Mobile Performance Recipes https://pytorch.org/tutorials/recipes/mobile_perf.html

  10. amp_recipe.py

    Automatic Mixed Precision https://pytorch.org/tutorials/recipes/amp_recipe.html

  11. regional_compilation.py
    Reducing torch.compile cold start compilation time with regional compilation

    https://pytorch.org/tutorials/recipes/regional_compilation.html

Performance Tuning Guide

Performance Tuning Guide

Changing default device

Changing default device

How to use TensorBoard with PyTorch

How to use TensorBoard with PyTorch

What is a state_dict in PyTorch

What is a state_dict in PyTorch

Warmstarting model using parameters from a different model in PyTorch

Warmstarting model using parameters from a different model in PyTorch

Reasoning about Shapes in PyTorch

Reasoning about Shapes in PyTorch

Tips for Loading an nn.Module from a Checkpoint

Tips for Loading an nn.Module from a Checkpoint

Defining a Neural Network in PyTorch

Defining a Neural Network in PyTorch

Zeroing out gradients in PyTorch

Zeroing out gradients in PyTorch

Timer quick start

Timer quick start

Model Interpretability using Captum

Model Interpretability using Captum

Extension points in nn.Module for load_state_dict and tensor subclasses

Extension points in nn.Module for load_state_dict and tensor subclasses

PyTorch Profiler

PyTorch Profiler

Automatic Mixed Precision

Automatic Mixed Precision

PyTorch Benchmark

PyTorch Benchmark

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources