Using trident¶
trident is a deep learning framework designed to train and evaluate models efficiently. It serves as a convenience layer atop several robust libraries:
trident’s goal is to minimize boilerplate through a modular design:
Data and preprocessing pipelines are powered by datasets and LightningDataModule, requiring minimal user setup.
Training and evaluation are simplified with high-level wrappers around Lightning.
Familiarity with hydra is essential, as it forms the core framework for configuring and composing experiments in trident.
Quick Start¶
Installation¶
All necessary packages for a base installation of trident can be installed with conda (or mamba)
conda env create -f environment.yaml
conda activate trident
Usage¶
Typical usage of trident follows the below schema:
Clone the repo
Write a configuration for your model (see also trident in 20 minutes)
Train on an existing experiment with python -m trident.run experiment=mnli module=my_model
You can find existing pipelines at experiments configs. A full experiment (incl. module) is defined in the MNLI-TinyBert config.
Contributing¶
Please see Contributing!
Credits¶
This project is was largely inspired by and is based on https://github.com/ashleve/lightning-hydra-template
A related project is: https://github.com/PyTorchLightning/lightning-transformers