MA2823: Foundations of Machine Learning Homework...
Transcript of MA2823: Foundations of Machine Learning Homework...
MA2823: Foundations of Machine Learning Homework 8
Due November 25, 2016.
Question 1Let us consider the training data {(x1, y1), . . . , (xn, yn)}wherexi ∈ Rp and yi ∈ {−1,+1}.A soft-margin SVM solves
arg minw∈Rp,b∈R,ξ∈Rn
1
2||w||2 + C
n∑i=1
ξi (1)
s. t. yi(〈w,xi〉+ b) ≥ 1− ξiξi ≥ 0 ∀i ∈ {1, . . . , n}
(a) Is a soft-margin SVMmore likely to overfit if C is large or small?
Solution: If C is large, more importance is given to the error on the training set,and the SVM is more likely to overfit.
(b) Give one way of choosing C in practice.
Solution: By cross-validation.
(c) What does this mean for a feature j if the solution wj is close to 0?
Solution: That this feature is uninformative. The class won’t depend on this fea-ture. (Note: we’re talking about a feature weight wj , not a (support) vector coeffi-cient αi.)
(d) Give an interpretation of the two terms of Equation (1): ||w||2 and∑n
i=1 ξi.
Solution: ||w|| is the inverse of the margin.∑ni=1 ξi is the sum of slacks ξi, which quantify the error for eachmisclassified train-
ing point.