DM825 Introduction to Machine Learning Lecture 8
Support Vector Machines
Marco Chiarandini
Department of Mathematics & Computer Science University of Southern Denmark
Support Vector Machines Marco Chiarandini Department of Mathematics - - PowerPoint PPT Presentation
DM825 Introduction to Machine Learning Lecture 8 Support Vector Machines Marco Chiarandini Department of Mathematics & Computer Science University of Southern Denmark Functional and Geometric Ma Optimal Margin Classifier Lagrange
Department of Mathematics & Computer Science University of Southern Denmark
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
2
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
3
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
◮ Binary classification. ◮ y ∈ {−1, 1} (instead of {0, 1} like in GLM) ◮ Let’s have h(
◮ h(
◮ Assume for now training set is linearly separable
4
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
5
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
6
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
◮ functional margin:
i
◮ geometric margin:
T
i
◮ γ = ˆ γ
◮ if
7
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
8
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
γ, θ,θ0
ˆ γ
ˆ γ, θ,θ0
9
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
10
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
11
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
12
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
m
p
◮ weighted sum of objective and constraint functions ◮ αi is Lagrange multiplier associated with fi(x) ≤ 0 ◮ βi is Lagrange multiplier associated with hi(x) = 0 ◮
13
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
x∈D L(x, α, β) = min x∈D
m
p
m
p
x∈D L(x, α, β) ≤ L(˜
14
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
α≥0,β (LD(α, β)) = p∗
15
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
16
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
i=1 λi∇gi(x0)
i=1 λi(gi(x0) − bi) = 0
17
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
18
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
m
θL(
m
m
m
m
19
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
m
m
m
m
m
m
20
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
m
m
m
m
◮ This problem is in m variables. Problem (OPT3) has D variables and
◮ the form above allows us to use kernel trick and have even infinite
◮ the use of the kernel and its constraint of being positive semidefinite
21
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
◮ if αi > 0, then yi(
◮ if yi(
22
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
23
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
24
Functional and Geometric Ma Optimal Margin Classifier Lagrange Duality Karush Kuhn Tucker Conditions Solving the Optimal Margin
25