A simple, flexible, and well-designed pytorch template for your deep learning projects. The main idea behind this template is to model all machine learning tasks as interactions between an agent with its environment or external data. All components of the project are built around this core idea.
There are multiple templates available for different kinds of machine learning tasks. Switch to the appropriate branch and see the installation section to download the template:
- Supervised Learning (SL)
- Reinforcement Learning (RL)
- Clone the repository and go to the project folder.
git clone https://github.com/ramanakshay/canvas --depth 1 --branch sl
cd canvas
- Reset git history.
rm -rf .git
git init
git add --all
git commit -m “initial canvas commit”
- Install dependencies from requirements file. Make sure to create a virtual environment before running this command.
pip install -r requirements.txt
- Test the code.
python main.py
- pytorch (An open source deep learning platform)
- hydra (A framework for configuring complex applications)
This architecture is inspired from the agent-environment interface in reinforcement learning. The template extends this concept to support all kinds of machine learning tasks.
├── model - this folder contains all code (models, networks) of the agent
│ ├── classifier.py
│ ├── network.py
│ └── layers.py
│
│
├── data - this folder contains code relevant to the data
│ └── data_loader.py
│
│
├── algorithm - this folder contains different algorithms of your project
│ ├── train.py
│ └── test.py
│
│
├── config
│ └── config.yaml - YAML config file for project
│
│
├── utils - this (optional) folder contains utilities of your project
│ └── utils.py
│
│
└── main.py - entry point of the project
- Support for loggers
Any kind of enhancement or contribution is welcomed.
This project is licensed under the MIT License. See LICENSE for more details.