libsvm源代码注释+算法描述:svm_train

这篇博客主要聚焦于libsvm中解决C-SVM问题的solve_c_svc函数,该函数采用WSS3(一种使用WSS3的SMO分解方法)。首先选择最大化违反最优条件的特征对i和j作为工作集B。更新αi和αj,同时维护梯度。最终,svm_train训练后生成的模型文件包含了支持向量和其对应的权重。
摘要由CSDN通过智能技术生成

(I will try my best to make this note clearer. We mainly focus on solve_c_svc in this note)

We mainly focus on solve_c_svc in this note.

Our goal:
mindB 12dTB2f(αk)dB+f(αk)TBdB
s.t. yTBdB=0

Core function of training: solve_c_svc.
It will call the function:

s.Solve(l, SVC_Q(*prob,*param,y), minus_ones, y, alpha, Cp, Cn, param->eps, si, param->shrinking);

Algotirhm 2 of WSS3 (An SMO-type decomposition method using WSS3)
After the initialization (trivial, we will discuss later), the first step is to select the working set B={ i,j} . The chosen i and j most violate the optimally condition. Thus it is a natural choice . We called it “maximal violating pair”.
The pair satisfies in WSS1:
iargmaxt{ ytf(αk)t|tIup(αk)}
jargmint

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值