Skip to content

A comprehensive resource to master PyTorch, from basics to advanced techniques, for deep learning enthusiasts and practitioners.

License

Notifications You must be signed in to change notification settings

mr-pylin/pytorch-workshop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ”₯ PyTorch Workshop

License Python Version Codacy Badge Code Style Repo Size Last Updated PRs Welcome

A comprehensive PyTorch workshop covering the fundamentals and advanced techniques of deep learning.

πŸ“– Table of Contents

πŸ“– Main Notebooks

  1. Introduction to Tensors
    Learn about PyTorch tensors, the foundational data structure, and how to manipulate them.
  2. Gradient and Autograd
    Understand gradients, automatic differentiation, and how PyTorch handles backpropagation with autograd.
  3. Perceptron and AdaLiNe
    Explore the basics of the simplest neural network model (perceptron) and Adaptive Linear Neuron (Adaline).
  4. Regression Models
    Implement linear and logistic regression using PyTorch, including model training and prediction.
  5. Multi-Layer Perceptrons
    Implement and explore multi-layer perceptron (MLP) for more complex tasks.
  6. Radial Basis Function Networks
    Implement and explore Radial Basis Function (RBF) networks and how they differ from traditional neural networks.
  7. Convolutional Neural Networks
    Explore concepts around convolutional neural networks (CNNs).
  8. Feature Extraction
    Learn how to extract features from pre-trained models for downstream tasks.
  9. Transfer Learning
    Apply transfer learning by using pre-trained models for a new tasks.
  10. Fine-Tuning Models
    Understand how to fine-tune models by updating specific layers while freezing others.
  11. Recurrent Neural Networks
    Explore concepts around recurrent neural networks (RNNs).

πŸ“– Utilities

A collection of concepts and tools utilized in the main notebooks for training models, ...

  • Activation Functions
    Study different activation functions (ReLU, Sigmoid, Tanh, ...) and their roles in neural networks.
  • Checkpoints
    Learn how to save and load model checkpoints to resume training or for inference.
  • Custom Implementations
    Learn how to define custom models, dataset, loss function, ... using PyTorch's class-based approach.
  • Working with Datasets
    Understand how to work with datasets in PyTorch using torch.utils.data.Dataset and torch.utils.data.DataLoader.
  • Parameters vs. Hyperparameters
    Understand the difference between parameters and hyperparameters in neural networks.
  • Loss Functions
    Dive into common loss functions used in neural networks, including MSE, Cross-Entropy, and others.
  • Normalization Techniques
    Understand normalization techniques such as Batch Normalization and Layer Normalization.
  • Vision Transforms
    Learn to apply transforms like data augmentation on datasets using torchvision.transforms.v2.
  • Word Embeddings
    Explore different word embedding techniques and their applications in natural language processing.

πŸ“– Models

πŸ“– Projects

  1. Multi-Layer Perceptrons
    A comprehensive example to building, training, and deploying a MLP, from data preprocessing to prediction.
  2. Convolutional Neural Networks
    A comprehensive example to building, training, and deploying a CNN, from data preprocessing to prediction.
  3. Word2Vec Word Embedding
    An in-depth guide to implementing the Word2Vec algorithm for word embeddings in natural language processing.

πŸ“‹ Prerequisites

βš™οΈ Setup

This project was developed using Python v3.12.3. If you encounter issues running the specified version of dependencies, consider using this specific Python version.

πŸ“ List of Dependencies

datasets matplotlib numpy pandas PySoundFile scikit-learn seaborn torch torchaudio torchvision torchinfo torchmetrics

πŸ“¦ Install Dependencies

You can install all dependencies listed in requirements.txt using pip:

pip install -r requirements.txt

πŸ› οΈ Usage Instructions

  1. Open the root folder with VS Code:
    • Windows/Linux: Ctrl + K followed by Ctrl + O
    • macOS: Cmd + K followed by Cmd + O
  2. Open .ipynb files using Jupyter extension integrated with VS Code.
  3. Allow VS Code to install any recommended dependencies for working with Jupyter Notebooks.

✍️ Notes:

  • The table of contents embedded in the notebooks is not fully functional on GitHub!
  • To navigate the table of contents effectively, open the notebooks locally or view them via nbviewer for a better experience.

πŸ”— Useful Links

PyTorch

  • Source Code:
  • Website:
    • The official website for PyTorch, offering comprehensive documentation, tutorials, and resources for deep learning and machine learning with PyTorch.
    • Link: pytorch.org
  • Pytorch Documentations:
    • Detailed and comprehensive documentation for all PyTorch features and functionalities, including tutorials and guides to help you get started and master PyTorch.
    • Link: pytorch.org/docs/stable/index.html
  • TorchVision Documentations:
    • The torchvision package [part of the PyTorch] consists of popular datasets, model architectures, and common image transformations for computer vision.
    • Link: pytorch.org/vision/stable/index.html
  • TorchAudio Documentation:
    • The torchaudio package [part of the PyTorch] consists of audio I/O and signal processing functionalities, enabling efficient loading, transforming, and manipulating audio.
    • Link: pytorch.org/audio/stable/index.html

NumPy

  • A fundamental package for scientific computing in Python, providing support for arrays, matrices, and a large collection of mathematical functions.
  • Official site: numpy.org

Pandas

  • A powerful, open-source data analysis and manipulation library for Python.
  • Pandas is built on top of NumPy.
  • Official site: pandas.pydata.org

Data Visualization

πŸ” Find Me

Any mistakes, suggestions, or contributions? Feel free to reach out to me at:

I look forward to connecting with you! πŸƒβ€β™‚οΈ

πŸ“„ License

This project is licensed under the Apache License 2.0.
You are free to use, modify, and distribute this code, but you must include copies of both the LICENSE and NOTICE files in any distribution of your work.

✍️ Additional Licensing Information

  • Original Images:
    • The images located in the ./assets/images/original/ folder are licensed under the CC BY-ND 4.0.
    • Note: This license restricts derivative works, meaning you may share these images but cannot modify them.
  • Third-Party Assets:
    • Additional images located in ./assets/images/third_party/ are used with permission or according to their original licenses.
    • Attributions and references to original sources are included in the code where these images are used.

About

A comprehensive resource to master PyTorch, from basics to advanced techniques, for deep learning enthusiasts and practitioners.

Topics

Resources

License

Stars

Watchers

Forks