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

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

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

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

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

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

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

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

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

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

Из лекций

A grid of numbers labelled tensor goes through a chain of blocks, linear and nonlinear, whose ends are shaped like plugs and sockets; letters with a cross sit to the side.
Learning as a Search Among Dials

Blocks That Fit Like Plugs

The first part of the book, called Compass and Needle, chapters two to six, sets up exactly this machinery. Seeing a network as a chain of differentiable building blocks raises two questions, and the book's second figure illustrates them. First, what kinds of data can go in and come out?

On a grid, the arrow (2, 1) plus twice the arrow (1, 3), which is (2, 6), completes a parallelogram ending at (4, 7); then the arrow (3, 4) with length 5.
Arrows, Lengths and the Dot Product

Vectors as Arrows

Most of the models in the book are built from very plain ingredients: sums, multiplications, and a few bent functions such as the exponential, sines and cosines, and square roots. Vectors, the tensors with one direction, have their own arithmetic, which mathematicians call a vector space.

Two 2 by 2 by 2 cubes, one filled with ones and one with twos, multiplied position by position and summed into 16, the same as the dot product of their flattened lists of eight.
Stacks of Tables and a Shorthand by Letters

A Dot Product of Whole Tensors

For the second kind, the book gives a generalised dot product. Take two tensors of the same shape, with three directions, multiply them position by position, and add up every single product. It is nothing but the ordinary dot product of the two tensors flattened into long lists.

A valley-shaped curve with a ball starting high on the left and taking steps downhill toward the bottom; each step is an arrow labelled with the step size, and a small flipped hill shows that maximising is minimising the negative.
Where the Ground Falls Fastest

Step by Step Downhill

Now to gradient descent. Suppose we want the input that makes a function of many numbers as small as possible, its minimum.

A latent space with two dog points almost touching, at (1, 2) and (1.1, 2.2), and a car point far away at (4, 6); a short line between the dogs reads 0.22 and a long line from dog to car reads 5.
What Makes a Good Pile of Examples

Close Meanings, Close Points

The chapter's opening figure looks ahead to something remarkable. A differentiable model transforms its input step by step with operations from linear algebra.

The likelihood written as a product of probabilities, then minus its logarithm written as a sum of minus logs; below, the forecaster example: 0.105 plus 0.511 equals 0.616, which is minus log 0.54.
The Most Likely Explanation, and Many Explanations at Once

From Product to Sum of Logs

How is such a model trained? Because the examples are assumed independent and drawn from the same distribution, the probability a model assigns to the whole dataset is the product of the probabilities it assigns to each example's true output. That product is called the likelihood of the dataset.

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

Примеры для: 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

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

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

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