?? code_onevsone.m
字號:
function [codebook,scheme] = code_OneVsOne(m)% Generate the codebook for multiclass classification with One-Versus-One encoding.%% codebook = code_OneVsOne(m)%% see also:% codelssvm% Copyright (c) 2002, KULeuven-ESAT-SCD, License & help @ http://www.esat.kuleuven.ac.be/sista/lssvmlabnb = m*(m-1)/2;codebook = eps+zeros(nb,m);t=1;for i=1:m-1, for j=i+1:m, codebook(t,i) = 1; codebook(t,j) = -1; t=t+1; endend% output forat, where 'b' stands for binary discriminatorscheme = []; for i=1:nb, scheme = [scheme 'b']; end
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -