Library · CC BY-SA 4.0

Dive intoDeep Learning

Dive into Deep Learning

Cover illustration of the book

Choose your version

The same text, told at every level, in every language and look shown here. Pick, then listen or download.

Listen and watch

The same player the product gives for your own book: the voice, the drawings as they are drawn, the text.

The open textbook used in hundreds of university courses on neural networks. Its first chapter explains what it means for a program to learn from data: models, losses, optimisation, the kinds of learning problems, and how deep learning came to win.

This is a sample: 1 of 23 chapters.

From the lectures

A stack of labelled recordings, each marked yes or no, feeds a learning algorithm that turns the knobs on a machine; the machine with its knobs set is the model.
Programming with examples

Labels, knobs and a learner

The trick is this: we cannot explain how to recognise "Alexa", but we can recognise it ourselves. So people listen to a great many short recordings and mark each one yes or no. That collection is called a dataset, and the marks are labels.

The two bills lie on a straight line that starts at 50 dollars at zero hours and rises 100 dollars per hour, giving 450 dollars for 4 hours; scattered real bills sit near the line with short gaps marked as misses.
Guessing how much

A call-out charge plus a rate

Now back to the plumber. You probably assumed that more hours cost more, and that there is a fixed call-out charge plus a rate for each hour.

Four result cards with scores 0.3, 0.9, 0.5 and 0.7 rearrange themselves so the highest score is on top.
Tags, rankings and your feed

Search ranks by score

Search is a related problem, but the question changes. For a web search, there are usually many pages that are relevant; what matters is which of them to show at the top. One way is to give every page a score and show the highest scores first.

The sentence the cat sat on the, with its last word hidden behind a question mark; a model guesses mat; what it learned is then fine-tuned for another task.
Learning without answers

Hide a word, guess it back

Another development is self-supervised learning, where the data itself provides the questions and the answers. For text, hide a word at random and ask the model to guess it from the words around it; huge amounts of text can be used this way with no labelling at all.

A small network of three layers of circles joined by lines, labelled layers; below, a timeline from 1990 to 2015 with the span 1995 to 2005 shaded as the quiet years.
Old roots

Layers, and the quiet years

At their heart are two ideas: layers of simple processing stacked one after another, and a way of adjusting all the knobs of the whole network at once, called backpropagation. After a burst of early progress, research on neural networks stalled from about 1995 to 2005.

Left, the headline fear of a robot uprising, crossed out; right, the real concerns: automatic credit decisions, routine jobs automated, biased models.
Everywhere, mostly unseen

Headline fears, real concerns

Self-driving cars have made great progress too, with some cars already driving themselves part of the time, though full self-driving is still out of reach: driving needs seeing, reasoning and following rules, and deep learning mainly handles the seeing.

How it was made

Examples for: a curious adult with school maths who uses ChatGPT and phone apps; add one modern instance per idea, such as a chatbot, a spam filter, a recommendation feed or a voice assistant

The source

The lectures retell the English text of d2l.ai (Cambridge University Press, 2023), GitHub d2l-ai/d2l-en by Aston Zhang, Zachary C. Lipton, Mu Li, Alexander J. Smola, published under an open licence that allows retelling and translation. The retelling, the drawings and the voice are made by AI and checked against the book by a second model. How AI is used.

The lectures adapt the original and are released under the same licence, free to share and adapt with credit to the author and a link to this page: CC BY-SA 4.0

Your own hard book, the same way

Upload a textbook or any difficult book. The first five minutes are free.

Upload a book