S1423 of 55
0 XP
  1. Hook
  2. Problems

S14 · Midterm exam

Midterm exam: fitting and generalization, likelihood and Bayes, decisions, information, Bayesian inference, regression and classification

Twelve problems from lessons 1 to 20: least squares and the gap between training and test error, generalization bounds, maximum likelihood and Bayes' theorem, decision boundaries and the Bayes error, entropy and cross-entropy, conjugate priors and Gaussian inference, ridge and Bayesian regression, Fisher's discriminant, logistic regression, generative classifiers, nearest neighbors and model evaluation. Give yourself two hours and work without the lessons open. "Another set" deals a different exam.

Check

Points (0, 1), (1, 2), (3, 9); separately, a correct model with 4 parameters fitted to 30 examples with noise variance 0.1.

(a)

Least-squares slope?

(b)

Expected test error?

(c)

Expected gap between test and training error?

Check

4 Gaussian samples whose maximum-likelihood variance is 2; and a log-likelihood with squared deviations summing to 60 at σ² = 2.

(a)

Unbiased variance?

(b)

Log-likelihood?

Check

Noise variance 0.01 with a weight prior of standard deviation 0.3; a false alarm costing 10 against a miss costing 500.

(a)

Equivalent regularization constant?

(b)

Posterior threshold for deciding positive?

Check

Gaussian classes with means 0 and 1, σ = 1.5, class 1's prior 0.8.

(a)

Minimum-error boundary?

(b)

Bayes error if the priors were equal?

Check

A binary event with probability 0.1, modeled as 0.2; a binary symmetric channel with flip probability 0.15.

(a)

Entropy of the event?

(b)

KL divergence in nats?

(c)

Channel mutual information with uniform input?

Check

A beta(1, 2) prior updated with 9 successes in 30 trials.

(a)

Posterior mean?

(b)

MAP?

(c)

Laplace's rule, ignoring this prior?

Check

Prior N(0, 0.5²) on a mean; 20 observations averaging 2 with noise variance 3.

(a)

Posterior variance?

(b)

Posterior mean?

Check

Zero-mean jointly Gaussian x, y with σx = 1, σy = 2, ρ = 0.8.

(a)

E[y | x = 3]?

(b)

var(y | x)?

(c)

Mahalanobis distance of (3, 1) if ρ were 0?

Check

Ridge on one weight: Σx² = 4, true w = 0.5, noise variance 8, λ = 6.

(a)

Mean squared error of the estimate?

(b)

Error at the best λ?

Check

Bayesian regression of one weight: α = 0.5, β = 2, Σx² = 15, Σxt = 12.

(a)

Posterior mean?

(b)

Predictive standard deviation at x = 1?

(c)

Equivalent ridge λ?

Check

Two classes whose means differ by (1, 1), with diagonal within-class variances 2 and 6.

(a)

Fisher's direction from the first axis?

(b)

Separation J?

Check

A logistic model with w0 = −4, w1 = 0.5, and an example at x = 3 with target 1.

(a)

Predicted probability?

(b)

Gradient with respect to w1?

(c)

Decision boundary?

Have paper and a calculator ready. Work each problem out by hand, then enter the answer. Your first try on each one counts toward your score.

Practice

Keep practicing

16 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.