Path: blob/master/chapter02_mathematical-building-blocks.ipynb
709 views
Kernel: Python 3
This is a companion notebook for the book Deep Learning with Python, Third Edition. For readability, it only contains runnable code blocks and section titles, and omits everything else in the book: text paragraphs, figures, and pseudocode.
If you want to be able to follow what's going on, I recommend reading the notebook side by side with your copy of the book.
The book's contents are available online at deeplearningwithpython.io.
In [0]:
In [0]:
In [0]:
The mathematical building blocks of neural networks
A first look at a neural network
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
Data representations for neural networks
Scalars (rank-0 tensors)
In [0]:
In [0]:
Vectors (rank-1 tensors)
In [0]:
In [0]:
Matrices (rank-2 tensors)
In [0]:
Rank-3 tensors and higher-rank tensors
In [0]:
Key attributes
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
Manipulating tensors in NumPy
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
The notion of data batches
In [0]:
In [0]:
In [0]:
Real-world examples of data tensors
Vector data
Timeseries data or sequence data
Image data
Video data
The gears of neural networks: tensor operations
Element-wise operations
In [0]:
In [0]:
In [0]:
In [0]:
Broadcasting
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
Tensor product
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
Tensor reshaping
In [0]:
In [0]:
In [0]:
In [0]:
In [0]:
Geometric interpretation of tensor operations
A geometric interpretation of deep learning
The engine of neural networks: Gradient-based optimization
What's a derivative?
Derivative of a tensor operation: the gradient
Stochastic gradient descent
Chaining derivatives: The Backpropagation algorithm
The chain rule
Automatic differentiation with computation graphs
Looking back at our first example
In [0]:
In [0]:
In [0]:
In [0]:
Reimplementing our first example from scratch
A simple Dense class
In [0]:
A simple Sequential class
In [0]:
In [0]:
A batch generator
In [0]:
Running one training step
The weight update step
In [0]:
In [0]:
Gradient computation
In [0]:
In [0]:
The full training loop
In [0]:
In [0]:
Evaluating the model
In [0]: