Skip to content
This repository was archived by the owner on Aug 5, 2026. It is now read-only.
gri-shaPublic archive

About

Simple DL framework

Resources

Stars

2 stars

Watchers

0 watching

Forks

Repository files navigation

header logo

Python NumPy CuPy MkDocs pytest black

simplegrad is the simplest deep learning framework.

Install

The package is not yet on PyPI — install from source:

# CPU only (NumPy backend)
pip install git+https://github.com/gri-sha/simplegrad.git

# GPU support (CuPy — requires CUDA 12.x)
pip install "simplegrad[gpu] @ git+https://github.com/gri-sha/simplegrad.git"

The SimpleBoard frontend is compiled from npm sources during installation. Skip it if Node.js is not available:

SIMPLEGRAD_NO_BUILD_WEB=1 pip install git+https://github.com/gri-sha/simplegrad.git

Optional extras

Extra Installs Use when
gpu cupy-cuda12x Running on an NVIDIA GPU (CUDA 12.x)
bench torch Running the benchmarks in benchmarks/
dev pytest, black, mypy, ipykernel Contributing / running tests
docs mkdocs, mkdocs-material, mkdocstrings Building the documentation locally
# Install multiple extras at once
pip install "simplegrad[gpu,dev] @ git+https://github.com/gri-sha/simplegrad.git"

Quick start

import simplegrad as sg

x = sg.Tensor([[1.0, 2.0], [3.0, 4.0]], label="x")
w = sg.Tensor([[0.5], [-0.5]], label="w")

y = sg.mean(x @ w)
y.backward()

print(x.grad)  # d(mean(x @ w)) / dx
print(w.grad)  # d(mean(x @ w)) / dw

What's inside

Module What it gives you
core/ Tensor, autograd engine, lazy execution
functions/ Math, activations, losses, conv, pooling
nn/ Linear, Conv2d, Embedding, Dropout, ...
optimizers/ SGD, Adam
schedulers/ Linear, Exponential, Cosine, ReduceOnPlateau
track/ SQLite-backed experiment tracking
simpleboard/ Web dashboard for tracked runs

Docs

Full API reference, architecture walkthrough, and training examples at the documentation site.

About

Simple DL framework

Resources

Stars

2 stars

Watchers

0 watching

Forks

Contributors

Languages