Dive into Deep Learning
2026-05-24
Dive into Deep Learning
Interactive deep learning, with code, math, and discussions — implemented in PyTorch, JAX, TensorFlow, and MXNet.
One book, four frameworks
Every example runs end-to-end in your framework of choice. Switch tabs to see the same idea in idiomatic code for each.
- PyTorch
- JAX
- TensorFlow
- MXNet
What you get
Code you can run
Every concept ships with executable Jupyter notebooks. Tweak hyperparameters and see the effect immediately.
Math grounded in intuition
Derivations stay close to the code. Equations, figures, and prose are interwoven, not relegated to appendices.
Truly multi-framework
The same chapter, the same explanations, in PyTorch, JAX, TensorFlow, and MXNet. Pick your framework, keep the book.
Runs anywhere
Local Jupyter, Google Colab, Amazon SageMaker Studio Lab, or your own GPU box. No paywalls, no setup hurdles.
Classroom-tested
Used as a primary or supplementary text at 500+ universities. Slide decks, exercises, and a discussion forum included.
Always free, always evolving
The book is fully open-source. New chapters and corrections land continuously, in step with the field.
Authors
Chapter contributors
Specialist authors who led the writing of individual chapters in the second volume.
Reinforcement Learning
Gaussian Processes
Hyperparameter Optimization
Recommender Systems
Mathematics for Deep Learning
Framework adaptation leads
Driving the per-framework code: porting every example to PyTorch, JAX, and TensorFlow.
Adopted at universities worldwide
What people are saying
In a way that strikes the perfect balance between hands-on learning and mathematical rigor, this book is the most accessible and resourceful guide to deep learning we currently have.
Course adopter, R1 university
The notebooks make it easy to get students from zero to a working model in a single lecture. The math is there when you want it and stays out of the way when you don't.
Instructor, graduate ML course
I switched from PyTorch to JAX mid-semester and didn't have to switch textbooks. That alone is unheard of.
Researcher, industry lab
Cite the book
@book{zhang2023dive,
title = {Dive into Deep Learning},
author = {Zhang, Aston and Lipton, Zachary C. and Li, Mu and Smola, Alexander J.},
publisher = {Cambridge University Press},
note = {\url{https://D2L.ai}},
year = {2023}
}
Resources
Global university adoption










































































































































































