Support Vector Machines

Support Vector Machines
 
Linear Separators
Binary classification can be viewed as the task of
separating classes in feature space:
 
w
T
x 
+ 
b
 = 0
 
w
T
x 
+ 
b
 < 0
 
w
T
x 
+ 
b
 > 0
 
f
(
x
)
 = 
sign(
w
T
x 
+ 
b
)
Linear Separators
Which of the linear separators is optimal?
What is a good Decision Boundary?
Many decision
boundaries!
The Perceptron algorithm
can be used to find such a
boundary
Are all decision
boundaries equally
good?
4
Examples of Bad Decision Boundaries
5
Class 1
Class 2
Class 1
Class 2
Finding the Decision Boundary
Let {
x
1
, ..., 
x
n
} be our data set and let 
y
i
 
   {1,-1} be the class
label of 
x
i
6
Class 1
Class 2
m
y=1
y=1
y=1
y=1
y=1
y=-1
y=-1
y=-1
y=-1
y=-1
y=-1
For 
y
i
=1
For 
y
i
=-1
So:
Large-margin Decision Boundary
The decision boundary should be as far away
from the data of both classes as possible
We should maximize the margin, 
m
7
Class 1
Class 2
m
Finding the Decision Boundary
The decision boundary should classify all points correctly 
The decision boundary can be found by solving the
following constrained optimization problem
This is a constrained optimization problem. Solving it
requires to use Lagrange multipliers
8
The Lagrangian is
i
≥0
Note that ||
w
||
2
 = 
w
T
w
9
Finding the Decision Boundary
Setting the gradient of     w.r.t. 
w
 and b to
zero, we have
10
Gradient with respect to 
w
 and 
b
n: no of examples, m: dimension of the space
The Dual Problem
If we substitute                             to     , we have
Since
This is a function of 
i
 only
11
The Dual Problem
The new objective function is in terms of 
i
 only
It is known as the dual problem: if we know 
w
, we know all 
i
; if we know
all 
i
, we know 
w
The original problem is known as the primal problem
The objective function of the dual problem needs to be maximized (comes
out from the KKT theory)
The dual problem is therefore:
12
Properties of 
i
 when we introduce
the Lagrange multipliers
The result when we differentiate the
original Lagrangian w.r.t. b
The Dual Problem
This is a quadratic programming (QP) problem
A global maximum of 
i 
can always be found
w
 can be recovered by
13
Characteristics of the Solution
Many of the 
i
 are zero
w
 is a linear combination of a small number of data
points
This “sparse” representation can be viewed as data
compression as in the construction of knn classifier
x
i
 with non-zero 
i
 are called support vectors (SV)
The decision boundary is determined only by the SV
Let 
t
j
 (
j
=1, ..., 
s
) be the indices of the 
s
 support
vectors. We can write
Note: 
w
 need not be formed explicitly
14
A Geometrical Interpretation
15
6
=1.4
Class 1
Class 2
1
=0.8
2
=0
3
=0
4
=0
5
=0
7
=0
8
=0.6
9
=0
10
=0
Characteristics of the Solution
For testing with a new data 
z
Compute                                                      
 
and classify 
z
 as class 1 if the sum is positive, and
class 2 otherwise
Note: 
w
 need not be formed explicitly
16
The Quadratic Programming Problem
Many approaches have been proposed
Loqo, cplex, etc. (see 
http://www.numerical.rl.ac.uk/qp/qp.html
)
Most are “interior-point” methods
Start with an initial solution that can violate the constraints
Improve this solution by optimizing the objective function
and/or reducing the amount of constraint violation
For SVM, sequential minimal optimization (SMO) seems to
be the most popular
A QP with two variables is trivial to solve
Each iteration of SMO picks a pair of (
i
,
j
) and solve the QP
with these two variables; repeat until convergence
In practice, we can just regard the QP solver as a “black-
box” without bothering how it works
17
Non-linearly Separable Problems
We allow “error” 
i
 in classification; it is based on the output
of the discriminant function 
w
T
x
+b
 
i
 approximates the number of misclassified samples
18
Soft Margin Hyperplane
The new conditions become
i
 are “slack variables” in optimization
Note that 
i
=0 if there is no error for 
x
i
i
 is an upper bound of the number of errors
We want to minimize
C
 : tradeoff parameter between error and margin
19
The Optimization Problem
 
20
With 
α
 and 
μ
 Lagrange multipliers, POSITIVE
The Dual Problem
 
With
The Optimization Problem
The dual of this new constrained optimization problem is
New constrainsderive from                            since 
μ
 and 
α
 are
positive.
w
 is recovered as
This is very similar to the optimization problem in the linear
separable case, except that there is an upper bound 
C
 on 
i
now
Once again, a QP solver can be used to find 
i
22
The algorithm try to keep ξ null, maximising the
margin
The algorithm does not minimise the number of
error. Instead, it minimises the sum of distances fron
the hyperplane
When C increases the number of errors tend to
lower. At the limit of C tending to infinite, the
solution tend to that given by the hard margin
formulation, with 0 errors
2/27/2025
23
Soft margin is more robust
24
Extension to Non-linear Decision
Boundary
So far, we have only considered large-margin classifier with
a linear decision boundary
How to generalize it to become nonlinear?
Key idea: transform 
x
i
 to a higher dimensional space to
“make life easier”
Input space: the space the point 
x
i
 are located
Feature space: the space of 
(
x
i
) after transformation
Why transform?
Linear operation in the feature space is equivalent to non-linear
operation in input space
Classification can become easier with a proper transformation.
In the XOR problem, for example, adding a new feature of x
1
x
2
make the problem linearly separable
25
XOR
26
Is not linearly separable
Is linearly separable
Find a feature space
27
Transforming the Data
Computation in the feature space can be costly
because it is high dimensional
The feature space is typically infinite-dimensional!
The kernel trick comes to rescue
28
(.)
Feature space
Input space
Note: feature space is of higher dimension
than the input space in practice
Transforming the Data
Computation in the feature space can be costly
because it is high dimensional
The feature space is typically infinite-dimensional!
The kernel trick comes to rescue
29
(.)
Feature space
Input space
Note: feature space is of higher dimension
than the input space in practice
The Kernel Trick
Recall the SVM optimization problem
The data points only appear as
 inner product
As long as we can calculate the inner product in the
feature space, we do not need the mapping explicitly
Many common geometric operations (angles,
distances) can be expressed by inner products
Define the kernel function 
K
  by
30
An Example for 
(.) and K(.,.)
Suppose 
(.) is given as follows
An inner product in the feature space is
So, if we define the kernel function as follows, there is no
need to carry out 
(.) explicitly
This use of kernel function to avoid carrying out 
(.)
explicitly is known as the 
kernel trick
31
Kernels
Given a mapping:
a kernel is represented as the inner product
A kernel must satisfy the Mercer’s condition:
32
Modification Due to Kernel Function
Change all inner products to kernel functions
For training,
33
Original
With kernel
function
Modification Due to Kernel Function
For testing, the new data 
z
 is classified as class
1 if 
f 
0, and as class 2 if 
f
 <0
34
Original
With kernel
function
More on Kernel Functions
Since the training of SVM only requires the value of
K
(
x
i
, 
x
j
), there is no restriction of the form of 
x
i
 and 
x
j
x
i
 can be a sequence or a tree, instead of a feature vector
K
(
x
i
, 
x
j
) is just a similarity measure comparing 
x
i
 and 
x
j
For a test object 
z
, the discriminant function essentially
is a weighted sum of the similarity between z and a
pre-selected set of objects (the support vectors)
35
Example
Suppose we have 5 1D data points
x
1
=1, x
2
=2, x
3
=4, x
4
=5, x
5
=6, with 1, 2, 6 as class 1
and 4, 5 as class 2 
 y
1
=1, y
2
=1, y
3
=-1, y
4
=-1, y
5
=1
36
Example
37
1
2
4
5
6
class 2
class 1
class 1
Example
We use the polynomial kernel of degree 2
K(x,y) = (xy+1)
2
C is set to 100
We first find 
i
 (
i
=1, …, 5) by
38
Example
By using a QP solver, we get
1
=0, 
2
=2.5, 
3
=0, 
4
=7.333, 
5
=4.833
Note that the constraints are indeed satisfied
The support vectors are {x
2
=2, x
4
=5, x
5
=6}
The discriminant function is
b
 is recovered by solving 
f(2)=1
 or by 
f(5)=-1
 or by 
f(6)=1
,
All three give 
b=9
39
Example
40
Value of discriminant function
1
2
4
5
6
class 2
class 1
class 1
Kernel Functions
In practical use of SVM, the user specifies the kernel
function; the transformation 
(.) is not explicitly stated
Given a kernel function 
K
(
x
i
, 
x
j
), the transformation 
(.)
is given by its eigenfunctions (a concept in functional
analysis)
Eigenfunctions can be difficult to construct explicitly
This is why people only specify the kernel function without
worrying about the exact transformation
Another view: kernel function, being an inner product,
is really a similarity measure between the objects
41
A kernel is associated to a
transformation
Given a kernel, in principle it should be recovered the
transformation in the feature space that originates it.
K(x,y) = (xy+1)
2
= 
x
2
y
2
+2xy+1
It corresponds the transformation
2/27/2025
42
Examples of Kernel Functions
Polynomial kernel up to degree 
d
Polynomial kernel up to degree 
d
Radial basis function kernel with width 
The feature space is infinite-dimensional
Sigmoid with parameter 
 and 
It does not satisfy the Mercer condition on all 
 and 
43
44
Example
Building new kernels
If k
1
(x,y) and k
2
(x,y) are two valid kernels then the
following kernels are valid
Linear Combination
Exponential
Product
Polymomial tranfsormation (Q: polymonial with non
negative coeffients)
Function product (f: any function)
45
Ploynomial kernel
Ben-Hur et al, PLOS computational Biology 4 (2008)
46
Gaussian RBF kernel
Ben-Hur et al, PLOS computational Biology 4 (2008)
47
Spectral kernel for sequences
Given a DNA sequence x we can count the
number of bases (4-D feature space)
Or the number of dimers (16-D space)
Or l-mers (4
l
 –D space)
The spectral kernel is
2/27/2025
48
Choosing the Kernel Function
Probably the most tricky part of using SVM.
The kernel function is important because it creates the
kernel matrix, which summarizes all the data
Many principles have been proposed (diffusion kernel,
Fisher kernel, string kernel, …)
There is even research to estimate the kernel matrix from
available information
In practice, a low degree polynomial kernel or RBF kernel
with a reasonable width is a good initial try
Note that SVM with RBF kernel is closely related to RBF
neural networks, with the centers of the radial basis
functions automatically chosen for SVM
49
Other Aspects of SVM
How to use SVM for multi-class classification?
One can change the QP formulation to become multi-class
More often, multiple binary classifiers are combined
See DHS 5.2.2 for some discussion
One can train multiple one-versus-all classifiers, or
combine multiple pairwise classifiers “intelligently”
How to interpret the SVM discriminant function value
as probability?
By performing logistic regression on the SVM output of a
set of data (validation set) that is not used for training
Some SVM software (like libsvm) have these features
built-in
50
Active Support Vector Learning
P. Mitra, B. Uma Shankar and S. K. Pal, Segmentation of multispectral remote sensing
Images using active support vector machines, Pattern Recognition Letters, 2004. 
Supervised Classification
Software
A list of SVM implementation can be found at
http://www.kernel-
machines.org/software.html
Some implementation (such as LIBSVM) can
handle multi-class classification
SVMLight is among one of the earliest
implementation of SVM
Several Matlab toolboxes for SVM are also
available
53
Summary: Steps for Classification
Prepare the pattern matrix
Select the kernel function to use
Select the parameter of the kernel function and
the value of 
C
You can use the values suggested by the SVM
software, or you can set apart a validation set to
determine the values of the parameter
Execute the training algorithm and obtain the 
i
Unseen data can be classified using the 
i 
and the
support vectors
54
Strengths and Weaknesses of SVM
Strengths
Training is relatively easy
 No local optimal, unlike in neural networks
It scales relatively well to high dimensional data
Tradeoff between classifier complexity and error can
be controlled explicitly
Non-traditional data like strings and trees can be used
as input to SVM, instead of feature vectors
Weaknesses
Need to choose a “good” kernel function.
55
Conclusion
SVM is a useful alternative to neural networks
Two key concepts of SVM: maximize the
margin and the kernel trick
Many SVM implementations are available on
the web for you to try on your data set!
56
Resources
http://www.kernel-machines.org/
http://www.support-vector.net/
http://www.support-vector.net/icml-
tutorial.pdf
http://www.kernel-
machines.org/papers/tutorial-nips.ps.gz
http://www.clopinet.com/isabelle/Projects/SV
M/applist.html
57
Slide Note
Embed
Share

A comprehensive overview of Support Vector Machines (SVM), a popular machine learning algorithm used for classification and regression tasks. Learn about the principles behind SVM, how it works, its strengths and weaknesses, and practical applications in various fields such as finance, healthcare, and image recognition. Delve into the optimization techniques, kernel functions, and tuning parameters that enhance SVM performance, making it a valuable tool in predictive modeling and data analysis.

  • Machine Learning
  • Classification
  • Regression
  • Optimization
  • Kernel Functions

Uploaded on Feb 27, 2025 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.

E N D

Presentation Transcript


  1. Support Vector Machines

  2. Linear Separators Binary classification can be viewed as the task of separating classes in feature space: wTx + b = 0 wTx + b > 0 wTx + b < 0 f(x) = sign(wTx + b)

  3. Linear Separators Which of the linear separators is optimal?

  4. What is a good Decision Boundary? Many decision boundaries! The Perceptron algorithm can be used to find such a boundary Are all decision boundaries equally good? Class 2 Class 1 4

  5. Examples of Bad Decision Boundaries Class 2 Class 2 Class 1 Class 1 5

  6. Finding the Decision Boundary Let {x1, ..., xn} be our data set and let yi {1,-1} be the class label of xi +b +b T w 1 w x For yi=1 For yi=-1 i T 1 x i y=1 y=1 So: ( ) ( ) y=1 + T , 1 , y w x b x y y=-1 y=1 i i i i y=1 y=-1 Class 2 y=-1 y=-1 y=-1 m y=-1 Class 1 6

  7. Large-margin Decision Boundary The decision boundary should be as far away from the data of both classes as possible We should maximize the margin, m Class 2 m Class 1 7

  8. Finding the Decision Boundary The decision boundary should classify all points correctly The decision boundary can be found by solving the following constrained optimization problem This is a constrained optimization problem. Solving it requires to use Lagrange multipliers 8

  9. Finding the Decision Boundary The Lagrangian is i 0 Note that ||w||2 = wTw 9

  10. Gradient with respect to w and b Setting the gradient of w.r.t. w and b to zero, we have ( = + = i k 1 1 2 n: no of examples, m: dimension of the space ( ) ) 1 n = + + = T T 1 L w w y w x b i i i 2 1 i 1 m n m = = = k k + k k k 1 w w y w x b i i i 1 w L = , 0 k k L = 0 b 10

  11. The Dual Problem If we substitute to , we have Since This is a function of i only 11

  12. The Dual Problem The new objective function is in terms of i only It is known as the dual problem: if we know w, we know all i; if we know all i, we know w The original problem is known as the primal problem The objective function of the dual problem needs to be maximized (comes out from the KKT theory) The dual problem is therefore: Properties of i when we introduce the Lagrange multipliers The result when we differentiate the original Lagrangian w.r.t. b 12

  13. The Dual Problem This is a quadratic programming (QP) problem A global maximum of i can always be found w can be recovered by 13

  14. Characteristics of the Solution Many of the i are zero w is a linear combination of a small number of data points This sparse representation can be viewed as data compression as in the construction of knn classifier xi with non-zero i are called support vectors (SV) The decision boundary is determined only by the SV Let tj (j=1, ..., s) be the indices of the s support vectors. We can write Note: w need not be formed explicitly 14

  15. A Geometrical Interpretation Class 2 10=0 8=0.6 7=0 2=0 5=0 1=0.8 4=0 6=1.4 9=0 3=0 Class 1 15

  16. Characteristics of the Solution For testing with a new data z Compute and classify z as class 1 if the sum is positive, and class 2 otherwise Note: w need not be formed explicitly 16

  17. The Quadratic Programming Problem Many approaches have been proposed Loqo, cplex, etc. (see http://www.numerical.rl.ac.uk/qp/qp.html) Most are interior-point methods Start with an initial solution that can violate the constraints Improve this solution by optimizing the objective function and/or reducing the amount of constraint violation For SVM, sequential minimal optimization (SMO) seems to be the most popular A QP with two variables is trivial to solve Each iteration of SMO picks a pair of ( i, j) and solve the QP with these two variables; repeat until convergence In practice, we can just regard the QP solver as a black- box without bothering how it works 17

  18. Non-linearly Separable Problems We allow error i in classification; it is based on the output of the discriminant function wTx+b i approximates the number of misclassified samples Class 2 Class 1 18

  19. Soft Margin Hyperplane The new conditions become iare slack variables in optimization Note that i=0 if there is no error for xi i is an upper bound of the number of errors We want to minimize 1 n = i 2 + w C i 2 1 C : tradeoff parameter between error and margin 19

  20. The Optimization Problem ( 1 ( ) ) 1 n n n = i = i = + + + T T L w w C y w x b i i i i i i i 2 = 1 1 1 i With and Lagrange multipliers, POSITIVE n n L = = i = = = 0 w y x 0 w y x i i i j i i ij w = 1 i 1 j L = = 0 C j j j n L = i = = 0 iy i b 1 20

  21. The Dual Problem 1 n n n = 1 = i T = i + + L y y x x C j i j i j i 2 = 1 1 1 i j n n n = i = j = i T + + y y x x b i i i j j j i i i 1 1 1 n = i = + C With iy = 0 j j i 1 1 n n n = i 1 = i T = i + L y y x x j i j i j i 2 = 1 1 j

  22. The Optimization Problem The dual of this new constrained optimization problem is = + C New constrainsderive from since and are positive. w is recovered as j j This is very similar to the optimization problem in the linear separable case, except that there is an upper bound C on i now Once again, a QP solver can be used to find i 22

  23. 1 n = i 2 + w C i 2 1 The algorithm try to keep null, maximising the margin The algorithm does not minimise the number of error. Instead, it minimises the sum of distances fron the hyperplane When C increases the number of errors tend to lower. At the limit of C tending to infinite, the solution tend to that given by the hard margin formulation, with 0 errors 2/27/2025 23

  24. Soft margin is more robust 24

  25. Extension to Non-linear Decision Boundary So far, we have only considered large-margin classifier with a linear decision boundary How to generalize it to become nonlinear? Key idea: transform xi to a higher dimensional space to make life easier Input space: the space the point xi are located Feature space: the space of (xi) after transformation Why transform? Linear operation in the feature space is equivalent to non-linear operation in input space Classification can become easier with a proper transformation. In the XOR problem, for example, adding a new feature of x1x2 make the problem linearly separable 25

  26. XOR Is not linearly separable X Y 0 0 0 0 1 1 1 0 1 1 1 0 Is linearly separable X Y XY 0 0 0 1 0 0 0 1 1 0 0 1 1 1 1 0 26

  27. Find a feature space 27

  28. Transforming the Data ( ) ( ) ( ) ( ) ( ) ( ) (.) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) Feature space Note: feature space is of higher dimension than the input space in practice Input space Computation in the feature space can be costly because it is high dimensional The feature space is typically infinite-dimensional! The kernel trick comes to rescue 28

  29. Transforming the Data ( ) ( ) ( ) ( ) ( ) ( ) (.) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) Feature space Note: feature space is of higher dimension than the input space in practice Input space Computation in the feature space can be costly because it is high dimensional The feature space is typically infinite-dimensional! The kernel trick comes to rescue 29

  30. The Kernel Trick Recall the SVM optimization problem The data points only appear as inner product As long as we can calculate the inner product in the feature space, we do not need the mapping explicitly Many common geometric operations (angles, distances) can be expressed by inner products Define the kernel function K by 30

  31. An Example for (.) and K(.,.) Suppose (.) is given as follows An inner product in the feature space is So, if we define the kernel function as follows, there is no need to carry out (.) explicitly This use of kernel function to avoid carrying out (.) explicitly is known as the kernel trick 31

  32. Kernels Given a mapping: a kernel is represented as the inner product i x (x) x y (x) (y) ( , ) K i i A kernel must satisfy the Mercer s condition: 2 x x x x, y x y x y ( such that ) ( ) 0 ( ) ( ) ( ) 0 g g d K g g d d 32

  33. Modification Due to Kernel Function Change all inner products to kernel functions For training, Original With kernel function 33

  34. Modification Due to Kernel Function For testing, the new data z is classified as class 1 if f 0, and as class 2 if f <0 Original With kernel function 34

  35. More on Kernel Functions Since the training of SVM only requires the value of K(xi, xj), there is no restriction of the form of xi and xj xi can be a sequence or a tree, instead of a feature vector K(xi, xj) is just a similarity measure comparing xi and xj For a test object z, the discriminant function essentially is a weighted sum of the similarity between z and a pre-selected set of objects (the support vectors) 35

  36. Example Suppose we have 5 1D data points x1=1, x2=2, x3=4, x4=5, x5=6, with 1, 2, 6 as class 1 and 4, 5 as class 2 y1=1, y2=1, y3=-1, y4=-1, y5=1 36

  37. Example class 1 class 1 class 2 1 2 4 5 6 37

  38. Example We use the polynomial kernel of degree 2 K(x,y) = (xy+1)2 C is set to 100 We first find i (i=1, , 5) by 38

  39. Example By using a QP solver, we get 1=0, 2=2.5, 3=0, 4=7.333, 5=4.833 Note that the constraints are indeed satisfied The support vectors are {x2=2, x4=5, x5=6} The discriminant function is b is recovered by solving f(2)=1 or by f(5)=-1 or by f(6)=1, All three give b=9 39

  40. Example Value of discriminant function class 1 class 1 class 2 1 2 4 5 6 40

  41. Kernel Functions In practical use of SVM, the user specifies the kernel function; the transformation (.) is not explicitly stated Given a kernel function K(xi, xj), the transformation (.) is given by its eigenfunctions (a concept in functional analysis) Eigenfunctions can be difficult to construct explicitly This is why people only specify the kernel function without worrying about the exact transformation Another view: kernel function, being an inner product, is really a similarity measure between the objects 41

  42. A kernel is associated to a transformation Given a kernel, in principle it should be recovered the transformation in the feature space that originates it. K(x,y) = (xy+1)2= x2y2+2xy+1 2 x 2 x x It corresponds the transformation 1 2/27/2025 42

  43. Examples of Kernel Functions Polynomial kernel up to degree d Polynomial kernel up to degree d Radial basis function kernel with width The feature space is infinite-dimensional Sigmoid with parameter and It does not satisfy the Mercer condition on all and 43

  44. Example 44

  45. Building new kernels If k1(x,y) and k2(x,y) are two valid kernels then the following kernels are valid Linear Combination ) , ( ) , ( 1 1 c y x k c y x k + = ) , ( exp ) , ( 1 y x k y x k = ( , ) k x y 2 2 Exponential Product ( x k = , ) ( , ) ( , ) y k x y k x y 1 2 Polymomial tranfsormation (Q: polymonial with non negative coeffients) ) , ( ) , ( 1 y x k Q y x k = Function product (f: any function) ) ( ) , ( x f y x k = ( , ) ( ) k x y f y 1 45

  46. Ploynomial kernel Ben-Hur et al, PLOS computational Biology 4 (2008) 46

  47. Gaussian RBF kernel Ben-Hur et al, PLOS computational Biology 4 (2008) 47

  48. Spectral kernel for sequences Given a DNA sequence x we can count the number of bases (4-D feature space) x = ( ) ( , , , ) n n n n 1 A C G T Or the number of dimers (16-D space) , , ( ) ( 2 AC AA n n n x = , , , , , ,..) n n n n n AG AT CA CC CG CT Or l-mers (4l D space) ( ) x ( ) y = The spectral kernel is ( , ) k x y l l l 2/27/2025 48

  49. Choosing the Kernel Function Probably the most tricky part of using SVM. The kernel function is important because it creates the kernel matrix, which summarizes all the data Many principles have been proposed (diffusion kernel, Fisher kernel, string kernel, ) There is even research to estimate the kernel matrix from available information In practice, a low degree polynomial kernel or RBF kernel with a reasonable width is a good initial try Note that SVM with RBF kernel is closely related to RBF neural networks, with the centers of the radial basis functions automatically chosen for SVM 49

  50. Other Aspects of SVM How to use SVM for multi-class classification? One can change the QP formulation to become multi-class More often, multiple binary classifiers are combined See DHS 5.2.2 for some discussion One can train multiple one-versus-all classifiers, or combine multiple pairwise classifiers intelligently How to interpret the SVM discriminant function value as probability? By performing logistic regression on the SVM output of a set of data (validation set) that is not used for training Some SVM software (like libsvm) have these features built-in 50

More Related Content

giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#giItT1WQy@!-/#