c++ - How to judge the predict result of which SVM in opencv? -


for example have 2 svm objects svma , svmb, train different data set, , have sample sampc.

int idx  = svma.predict(sampc); int idx2 = svmb.predict(sampc); 

how judge svm return similar result ? thanks.

this answered here, , in predict() doco (assuming have 2 class svm).

if call predict() again, , set parameter returndfval=true decision function value (the signed distance margin). can use judge result "better". bigger distance margin, more sample belongs class has been assigned.


Comments

Popular posts from this blog

elasticsearch python client - work with many nodes - how to work with sniffer -

unity3d - Rotate an object to face an opposite direction -

angular - Is it possible to get native element for formControl? -