Skip to content
← Tools / Skills
Tooltiny corp/10 trustVerified

tinygrad

A tiny, hackable deep-learning stack: tensor library, autograd, and its own compiler that fuses kernels through lazy evaluation.

Visit official site →

About

tinygrad sits somewhere between PyTorch and Karpathy's micrograd: a full deep-learning stack small enough to read end to end. You get an eager Tensor API with autograd, nn/optim/datasets for real training, and then the unusual part, a visible, hackable compiler: operations are lazy, fused into single kernels, lowered through multiple passes with scheduling and BEAM search over kernel choices, and replayed with TinyJit. DEBUG=3 shows you the fused kernel; DEBUG=4 shows the generated code.

It borrows ergonomics from PyTorch, IR-based autodiff ideas from JAX, and scheduling from TVM, but keeps everything in one small codebase maintained by tiny corp (George Hotz's company). At 33,700+ stars it is both a serious research vehicle and the best way to actually understand how a modern ML compiler works. The honest trade-off: it is intentionally minimal, so you will miss PyTorch's library breadth, and some backends and ops are community-grade rather than production-hardened.

What it can do

  • End-to-end stack: tensors with autograd, IR, compiler, JIT, nn/optim/datasets
  • Lazy evaluation fuses operations into single kernels automatically
  • Visible, hackable compiler: multiple lowering passes, scheduling, BEAM search
  • TinyJit captures and replays kernel graphs
  • Broad accelerator support from one small codebase
  • Readable enough to learn how ML compilers actually work

Setup

  1. Install: pip install tinygrad (Python 3.9+).
  2. Write a familiar training loop with Tensor, nn, and tinygrad.nn.optim.
  3. Set DEBUG=3 to see kernel fusion in action, DEBUG=4 to inspect generated code.
  4. Wrap hot loops in TinyJit for capture-and-replay execution.
  5. Target different accelerators via the documented backend env vars (see docs.tinygrad.org).

Prerequisites

Python 3.9+; a GPU helps but CPU works for learning; curiosity about compilers helps more than anything.

Use cases

ml-frameworkscompilersresearchopen-sourcedeveloper-tools

Works with

Trust score — 9/10

/10 trustVerified

Scored 9/10 (verified tier, metrics-v1). Evidence: 33,758 GitHub stars (GitHub API), MIT, pushed Oct 15 2026; the README documents the tensor/IR/compiler/JIT stack, the PyTorch/JAX/TVM comparison, and the DEBUG introspection workflow; docs.tinygrad.org corroborates the backend story. Strengths: uniquely readable full-stack framework, huge community, real training capability. Docked for: (1) intentionally minimal vs PyTorch's breadth; (2) some backends are community-grade. License: MIT.

★ 33,758 GitHub stars

How the trust score is built

Full methodology →
Adoption · stars/downloads, log-scaled vs peers
8.0/10
Maintenance · recency, releases, issue load
10.0/10
Openness · license + docs
10.0/10
Manual review · sanity read + red-flag check
9.0/10
  • · Adoption 8: starScore from 33,758 stars on tinygrad/tinygrad (log scale vs 298k peer max)
  • · Maintenance 10: pushed 2026-10-15 (recency 10); tiny corp maintained
  • · Openness 10: MIT (0.7*10) + docs verified at docs.tinygrad.org (0.3*10)
  • · Manual 9: uniquely readable full-stack framework corroborated by README compiler story; docked for intentional minimalism vs PyTorch breadth

Sources

Every fact above was checked against these sources. Where a claim comes from the provider and couldn't be independently verified, the text says so.