/point-bench

Playground for benchmarking point cloud algorithms

Primary LanguagePythonApache License 2.0Apache-2.0

DL-Template

My deep learning template repository.

Overview of Features

The core components of this template are as follows:

  • Premade utilities provided by combustion
  • Dockerfiles that enable easy containerization of a newly developed application
  • CI/CD/devops features (provided via a Makefile) like code formatting, test running, etc.

This template is designed with following 3rd party libraries in mind:

  • PyTorch-Lightning, a high level API for model training
  • Hydra, a library that enables YAML based configuration of hyperparameters

Installation

First create a virtual environment to store dependencies.

make venv

This make recipe can also be used to activate the virtual environment after install.

TODO docker build instructions here

Usage

A project template is provided in src/project. The existing __main__.py file demonstrates a basic training / testing example using PyTorch-Lightning and Hydra. Modify the project directory as needed.

Configuration

Hydra allows for hyperparameters and runtime properties to be easily configured using YAML files. The modularity of using multiple YAML files has many advantages over command line configuration. See the Hydra documentation for more details.

Some noteable features of Hydra to be aware of are:

  • Composition of multiple YAML files when specifying a runtime configuration
  • Ability to specify YAML values at the command line
  • Ability to specify YAML values at the command line

Development

Multiple make recipes are provided to aid in development:

  • pre-commit - Installs a pre-commit hook to run code quality tests
  • quality - Runs code quality tests
  • style - Automatically formats code (using black and autopep8)
  • test - Runs all tests
  • test-% - Runs specific tests by pattern match (via pytest -k flag)
  • test-pdb-% - Runs specific tests with debugging on failure (via pytest --pdb flag)

To Do

  • CircleCI CI/CD pipeline
  • Improve documentation for Combustion modules
  • Add / fix tests as needed

References