Exercises

These exercises check the chapter's evaluation and debugging tools.

Exercise: Split role

Enter 1 for train, 2 for validation, or 3 for test: this split should be used for final reporting after model choices are fixed.

Compute it first, then check your number.

Exercise: Accuracy

A classifier gets 42 examples correct out of 50. What is accuracy as a decimal?

Compute it first, then check your number.

Exercise: Mean absolute error

Errors are -2, 4, and 1. What is the mean absolute error?

Compute it first, then check your number.

Exercise: Gradient norm

What is the L2 norm of gradient vector [5, 12]?

Compute it first, then check your number.

Exercise: Activation zero fraction

A layer has 200 activations and 150 are zero. What fraction is zero?

Compute it first, then check your number.

Exercise: Extreme weights

A parameter histogram has 4 extreme weights out of 80 total. What fraction is extreme?

Compute it first, then check your number.

Exercise: Seed average

Three seed results are 0.60, 0.66, and 0.69. What is their average?

Compute it first, then check your number.