Exercise 3.6

Answers

(a) The probability to get yn is P(yn|xn), by maximum likelihood method, we need maximize the likelihood, n=1NP(yn|xn), this is equivalent to maximize the logrithm of it: n=1N ln (P(yn|xn)), or minimize the negative of it: n=1N ln (P(yn|xn))

When yn = +1, P(yn|xn) = h(xn), and when yn = 1, P(yn|xn) = 1 h(xn), separate the cases for yn = 1 and yn = 1, we have:

Ein(w) = n=1N ln (P(y n|xn)) = n=1NI(y n = +1)ln h(xn) + I(yn = 1)ln (1 h(xn)) = n=1NI(y n = +1)ln 1 h(xn) + I(yn = 1)ln 1 (1 h(xn))

(b) For h(x) = 𝜃(wTx) = ewTx 1+ewTx, we have ln 1 h(xn) = ln (1 + ewTx n) and ln 1 (1h(xn)) = ln (1 + ewTx n). Combine them together we have

Ein(w) = n=1NI(y n = +1)ln (1 + ewTx n) + I(yn = 1)ln (1 + ewTx n) = n=1N ln (1 + eynwTx n)

Which is equivalent to minimizing the one in equation (3.9).

User profile picture
2021-12-07 22:14
Comments