0
votes

I am running libsvm through weka. Its output accuracy looks good to me, so I am planning to write a svm model by myself. However, weka didn't generate any training parameter, such as number of support vector. Therefore i cannot do anything. Searching the web, i found somebody said it would generate some parameters like the following:

optimization finished, #iter = 27 
nu = 0.058475864943863545  
obj = -1.871013102744184, rho = -0.19357337828800944 
nSV = 9, nBSV = 0 `enter code here`
Total nSV = 9 

but how come i didn't see any of them? any step that i missed? please help me. Thanks a lot.

1

1 Answers

0
votes

Weka writes the output you mentioned to stderr.

So if you have started weka.sh or weka.bat from a terminal (or "command window" if you are on Windows), you should see that output appear in your terminal window after clicking "classify"

If you want to have access to this information via scripts, you can redirect the output to a file and read in that file.

Here is how to edit the startup file weka.sh / weka.bat.

Edit this line (it is probably the last line) in order to write log info to a file instead of the terminal window:

java -cp $CP -Xmx8092m weka.gui.GUIChooser 2>>/opt/weka-stable/weka.log &

You can also add a properties file to your home directory to add more fine-grained behaviour.

https://weka.wikispaces.com/Properties+file

(You probably can also access information via the Weka Java API somehow, but you did not ask for that)