Skip to content

Latest commit

 

History

History
42 lines (33 loc) · 2.03 KB

README.md

File metadata and controls

42 lines (33 loc) · 2.03 KB

deep-learning-project-template

GitHub stars issues License Maintenance Code style: black Codefactor

This is a deep learning project template designed for PyTorch and PyTorch Lightning users.

How to use this template

  1. Run the following commands...
pip install -r requirements-dev.txt
git init
pre-commit install  # automatically format and do style check when committing
  1. Start coding!

The files and directories are organized as follows:

- data
    |- ...  # put your data here, do not include large files in git
- models
    |- ...  # models should be `torch.nn.Module`
- tasks
    |- ...  # tasks should be a framework or a system inherited from `pl.LightningModule`
- utils
    |- callbacks    # put your custom PyTorch Lightning callbacks here
    |- data         # put `torch.utils.data.Dataset` and `pl.LightningDataModule` subclasses here
    |- metrics      # put your custom metrics here, it is recommended to inherit from `torchmetrics.Metric`

An MLP classifier and an MNIST data module are already implemented as examples. Replace them with your custom tasks/models/data modules.

Requirements

  • torch
  • torchvision (if you want to run the MNIST example, otherwise unnecessary)
  • pytorch-lightning>=1.3.0
  • torchmetrics>=0.3.0
  • pre-commit
  • black
  • flake8