The Modern Mathematics of Deep Learningexplained for non-mathematicians

Squared training objective

Penguin learning project

The project uses 342 complete Palmer penguin records: 240 training-pool and 102 held-out rows. The selected training rows determine feature scaling and model parameters. Source CSV

This project trains weights with softmax, unlike the homepage lab, which uses nearest species averages. Same penguin measurements; different classification methods. Predictions can differ.

Objectives · Combine losses and penalties into a criterion for parameters or rules.

Project predictions and known answers produce losses. Classification uses cross-entropy and α/2 times squared non-bias weights; Ridge uses normalized-mass MSE and α times all squared coefficients, including the intercept.

Consider this concept alongside the project; its source assumptions may differ. These observations do not prove a theorem.

Input: 12 × 2; Held-out evaluation: 102 · #58 · 40.6 mm, 193 mm. Known answer: Adélie; Prediction: Adélie · [≈0.7383, ≈0.2444, ≈0.01737].

Used in these source sections: 1.2.1 Finding better settings · 2.4 A second descent · 5.1 The shape of training loss · More source sections

Evaluate the network on each training input, subtract each target, square, and average.

This is the objective studied in the source discussion of lazy training.

Source formula example

r(θ)=R^s(θ)=1m∑i=1m(Φ(x(i),θ)−y(i))2.{r}(\theta)=\widehat{\mathcal{R}}_{{s}}(\theta)=\frac{1}{m}\sum_{i=1}^{m}(\Phi(x^{(i)},\theta)-y^{(i)})^{2}.

exact · The result is exact for these finite toy inputs, apart from ordinary computer rounding.

Symbols

Φ(x,θ)Φ(x,θ)
Network output for input x and parameters θ.
mm
Positive number of examples.

Source formula example

This source example uses its own inputs and assumptions. Editing it does not change the project.

Edit a value or the code, then run the example. This is a finite demonstration, not a proof of the paper’s theorem.

This example’s data flow

You choose

  • input.weight = 1

Initial values in code

  • xs = [1, 2]
  • ys = [2, 4]

Calculated here

Result expression: { errors, risk: errors.reduce((sum, e) => sum + e * e, 0) / errors.length }

  • errors = xs.map((x, i) => input.weight * x - ys[i]) Uses: xs, input.weight, ys

Returns

Example result
errors
array (2 items): [-1, -2]
risk
2.5

Read numbers from input and return the result. JavaScript basics.

Result

Enable JavaScript to run this example.

Technical statement

The example uses a linear one-weight predictor. Evaluating its objective does not demonstrate the source convergence theorem.

Source: Source expression