📄 bsvm2.html
字号:
<html><head> <meta HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=ISO-8859-1"> <title>Contents.m</title><link rel="stylesheet" type="text/css" href="../stpr.css"></head><body><table border=0 width="100%" cellpadding=0 cellspacing=0><tr valign="baseline"><td valign="baseline" class="function"><b class="function">BSVM2</b><td valign="baseline" align="right" class="function"><a href="../svm/index.html" target="mdsdir"><img border = 0 src="../up.gif"></a></table> <p><b>Multi-class BSVM with L2-soft margin.</b></p> <hr><div class='code'><code><span class=help></span><br><span class=help> <span class=help_field>Synopsis:</span></span><br><span class=help> model = bsvm2( data, options ) </span><br><span class=help></span><br><span class=help> <span class=help_field>Description:</span></span><br><span class=help> This function trains the multi-class SVM classifier based</span><br><span class=help> on BSVM formulation (bias added to the objective function) and</span><br><span class=help> L2-soft margin penalization of misclassifications.</span><br><span class=help> The quadratic programming task is optimized by one of the</span><br><span class=help> following algorithms:</span><br><span class=help> mdm ... Mitchell-Demyanov-Malozemov</span><br><span class=help> imdm ... Mitchell-Demyanov-Malozemov Improved 1.</span><br><span class=help> iimdm ... Mitchell-Demyanov-Malozemov Improved 2.</span><br><span class=help> kozinec ... Kozinec algorithm.</span><br><span class=help> keerthi ... NPA algorithm by Keerthi et al.</span><br><span class=help> kowalczyk ... Based on Kowalczyk's maximal margin perceptron.</span><br><span class=help></span><br><span class=help> For more info refer to V.Franc: Optimization Algorithms for Kernel </span><br><span class=help> Methods. Research report. CTU-CMP-2005-22. CTU FEL Prague. 2005.</span><br><span class=help> ftp://cmp.felk.cvut.cz/pub/cmp/articles/franc/Franc-PhD.pdf .</span><br><span class=help></span><br><span class=help> <span class=help_field>Input:</span></span><br><span class=help> data [struct] Training data:</span><br><span class=help> .X [dim x num_data] Training vectors.</span><br><span class=help> .y [1 x num_data] Labels (1,2,...,nclass).</span><br><span class=help></span><br><span class=help> options [struct] Control parameters:</span><br><span class=help> .ker [string] Kernel identifier. See 'help kernel'.</span><br><span class=help> .arg [1 x nargs] Kernel argument(s).</span><br><span class=help> .C [1x1] Regularization constant.</span><br><span class=help> .solver [string] Solver to be used: 'mdm', 'imdm' (default), 'iimdm', </span><br><span class=help> 'kozinec', 'kowalczyk','keerthi'.</span><br><span class=help> .tmax [1x1] Maximal number of iterations (default inf).</span><br><span class=help> .tolabs [1x1] Absolute tolerance stopping condition (default 0.0).</span><br><span class=help> .tolrel [1x1] Relative tolerance stopping condition (default 0.001).</span><br><span class=help> .thlb [1x1] Thereshold on the lower bound (default inf).</span><br><span class=help> .cache [1x1] Number of columns of kernel matrix to be cached (default 1000).</span><br><span class=help> .verb [1x1] If > 0 then some info is printed (default 0).</span><br><span class=help></span><br><span class=help> <span class=help_field>Output:</span></span><br><span class=help> model [struct] Multi-class SVM classifier:</span><br><span class=help> .Alpha [nsv x nclass] Weights.</span><br><span class=help> .b [nclass x 1] Biases.</span><br><span class=help> .sv.X [dim x nsv] Support vectors.</span><br><span class=help> .nsv [1x1] Number of support vectors.</span><br><span class=help> .options [struct] Copy of input options.</span><br><span class=help> .t [1x1] Number of iterations.</span><br><span class=help> .UB [1x1] Upper bound on the optimal solution.</span><br><span class=help> .LB [1x1] Lower bound on the optimal solution.</span><br><span class=help> .History [2 x (t+1)] UB and LB with respect to t.</span><br><span class=help> .trnerr [1x1] Training classification error.</span><br><span class=help> .kercnt [1x1] Number of kernel evaluations.</span><br><span class=help> .cputime [1x1] CPU time (measured by tic-toc).</span><br><span class=help> .stat [struct] Statistics about optimization:</span><br><span class=help> .access [1x1] Number of requested columns of matrix H.</span><br><span class=help> .t [1x1] Number of iterations.</span><br><span class=help> .UB [1x1] Upper bound on the optimal value of criterion.</span><br><span class=help> .LB [1x1] Lower bound on the optimal value of criterion.</span><br><span class=help> .LB_History [1x(t+1)] LB with respect to t.</span><br><span class=help> .UB_History [1x(t+1)] UB with respect to t.</span><br><span class=help> .NA [1x1] Number of non-zero elements in solution.</span><br><span class=help></span><br><span class=help> <span class=help_field>Example:</span></span><br><span class=help> data = load('pentagon');</span><br><span class=help> options = struct('ker','rbf','arg',1,'C',10);</span><br><span class=help> model = bsvm2(data,options )</span><br><span class=help> figure; </span><br><span class=help> ppatterns(data); ppatterns(model.sv.X,'ok',12);</span><br><span class=help> pboundary(model);</span><br><span class=help></span><br><span class=help> <span class=also_field>See also </span><span class=also></span><br><span class=help><span class=also> <a href = "../svm/svmclass.html" target="mdsbody">SVMCLASS</a>, <a href = "../svm/oaasvm.html" target="mdsbody">OAASVM</a>, <a href = "../svm/oaosvm.html" target="mdsbody">OAOSVM</a>, GMNP.</span><br><span class=help></span><br></code></div> <hr> <b>Source:</b> <a href= "../svm/list/bsvm2.html">bsvm2.m</a> <p><b class="info_field">About: </b> Statistical Pattern Recognition Toolbox<br> (C) 1999-2005, Written by Vojtech Franc and Vaclav Hlavac<br> <a href="http://www.cvut.cz">Czech Technical University Prague</a><br> <a href="http://www.feld.cvut.cz">Faculty of Electrical Engineering</a><br> <a href="http://cmp.felk.cvut.cz">Center for Machine Perception</a><br> <p><b class="info_field">Modifications: </b> <br> 09-sep-2005, VF<br> 24-jan-2005, VF<br> 29-nov-2004, VF<br> 26-nov-2004, VF<br> 16-Nov-2004, VF<br> 31-may-2004, VF<br> 23-jan-2003, VF<br></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -