Pergunta

I'm trying to obtain the best parameters for a one-class classifer using the wrapper of LibSVM under Weka.

For this reason, I'm going to weka.classifiers.meta.GridSearch and then I select LibSVM one class.

All data I'm using is labeled as the same class. The parameters I want to find are nu and gamma

The gridSearch options are:

weka.classifiers.meta.GridSearch -E CC -y-property classifier.kernel.gamma -y-min -5.0 -y-max 2.0 -y-step 1.0 -y-base 10.0 -y-expression pow(BASE,I) -filter weka.filters.AllFilter -x-property classifier.nu -x-min 0.01 -x-max 1.0 -x-step 10.0 -x-base 10.0 -x-expression I -sample-size 100.0 -traversal COLUMN-WISE -log-file "C:\Program Files\Weka-3-6" -S 1 -W weka.classifiers.functions.LibSVM -- -S 2 -K 2 -D 3 -G 0.0 -R 0.0 -N 0.5 -M 40.0 -C 1.0 -E 0.0010 -P 0.1

Then, weka tells me this:

weka.classifiers.meta.GridSearch Cannot handle unary class!!!

Is it true that gridsearch cannot handle unary class? or I'm just doing something wrong?

Thank you for your help.

-Jessica

Foi útil?

Solução

Grid search does cross validation and as mentioned in Labeling one class for cross validation in libsvm matlab :

According to http://www.joint-research.org/wp-content/uploads/2011/07/lukashevich2009Using-One-class-SVM-Outliers-Detection.pdf "Due to the lack of class labels in the one-class SVM, it is not possible to optimize the kernel parameters using cross-validation".

Therefore it is true that gridsearch cannot handle unary class.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top