Библиотека · CC BY-SA 4.0

Приключения Алисы в Странедифференцируемых чудес

Alice's Adventures in a Differentiable Wonderland, Volume I: A Tour of the Land

Иллюстрация к книге

Выберите версию

Один и тот же текст на каждом уровне, на всех языках и во всех оформлениях, что здесь есть. Выберите, потом слушайте или скачивайте.

Слушать и смотреть

Тот же плеер, который продукт даёт для вашей книги: голос, рисунки по мере того, как они рисуются, текст.

Современный учебник о том, как на самом деле устроены нейросети: от тензоров и градиентов до трансформеров. Первые три главы закладывают основу: о чём книга, линейная алгебра и анализ, на которых работает сеть, градиентный спуск, что такое набор данных и функция потерь.

Это пробная часть: 3 из 13 (главы).

Из лекций

A box with many knobs takes a photo and outputs cat; after a wrong answer an arrow turns one knob; below, a photo turns into a grid of numbers labelled tensor.
One Simple Recipe, Scaled Up

Learning Is a Search

Looking under the hood starts with one idea: learning is a search. You write a program with a vast number of adjustable knobs, called parameters, and you turn them until the program behaves well.

A 2 by 3 matrix of rows times a 3 by 2 matrix of columns gives a 2 by 2 table, each cell the dot product of one row with one column.
Arrows That Recognise Each Other

Many Dot Products at Once

A table of numbers, a matrix, can be read as a stack of such vectors, one per row, and the book calls this a batch of data. Multiplying matrices is then nothing more than computing many dot products at once, every row of one against every column of the other, in a single operation.

From one point, a gradient arrow pointing uphill and three unit step arrows: along it with full slope, at a right angle with slope 0, and diagonal with a partial slope.
How Costs Grow, and Which Way Is Uphill

Every Slope from One Arrow

Stand on a sloping lawn or a ramp and take one small step in several directions: straight up, sideways, diagonally. You should feel the steepest climb in one direction, no climb at all at right angles to it, and partial climbs in between.

Left, a bowl-shaped curve where marbles from both sides end at the same bottom; right, a bumpy curve where each marble settles in the nearest hollow.
Walking Downhill in the Fog

Bowl versus Egg Carton

Where does the walk end? It stops where the ground is flat, a stationary point, but flat ground can be a valley floor, a hilltop, or a saddle like a mountain pass that falls one way and rises the other.

A look-up table scores perfectly on its own examples; two bars show a near-zero training loss and a high test loss, with the gap between them marked.
A Score to Lower, and a Test You Have Not Seen

Memorised versus Learned

Then comes a trap. The average loss on the training examples can always be made perfect by a cheat: a look-up table that stores every example and answers with it, and gives some default for anything else. That table has memorised and learned nothing, exactly like your friend with last year's test.

A client's features in a column, each multiplied by a weight and summed into one prediction, which is either a number or a class.
Many Possible Models, and the Simplest One

The Simplest Block

Chapter 4 now builds the simplest block of all, the linear model, of which the book says every differentiable model is a clever variation.

Как это сделано

Примеры для: a curious adult with school maths who uses AI apps every day; add one modern instance per idea, such as how a chat assistant or a phone's photo app is trained

Источник

Лекции пересказывают с английского оригинала книгу arXiv 2404.17625 (version 3, 2025), автор — Симоне Скардапане; книга вышла под открытой лицензией, которая разрешает пересказ и перевод. Пересказ, рисунки и голос сделаны ИИ и сверены с книгой второй моделью. Как используется ИИ.

Лекции — переработка оригинала и распространяются под той же лицензией: их можно свободно распространять и перерабатывать с указанием автора и ссылкой на эту страницу: CC BY-SA 4.0

Ваша трудная книга — так же

Загрузите учебник или любую сложную книгу. Первые пять минут бесплатно.

Загрузить книгу