![]() |
#1
|
|||
|
|||
![]()
It took me a while to figure out how to get libsvm to work with Octave on Windows. C source files had to be compiled to .mex, and those had to be placed where Octave can find them. I documented the process at http://flyingpies.wordpress.com/2012...ve-on-windows/. I hope this helps!
|
#2
|
|||
|
|||
![]()
This was helpful, but...I got the following warnings when starting Octave with the .mex files in the search path:
warning: function .\libsvmread.mex shadows a core library function warning: function .\libsvmwrite.mex shadows a core library function warning: function .\svmpredict.mex shadows a core library function warning: function .\svmtrain.mex shadows a core library function I tried hiding them, but then svmtrain was undefined. (There is a file: "svmtrain_mex.mex" in ...\Octave-3.6.2\lib\octave\packages\nan-2.5.5\i686-pc-mingw32-api-v48+) Have you seen this? |
#3
|
|||
|
|||
![]()
I didn't realize it until you pointed it out: Octave ships with the nan package, which includes a version of libsvm. The documentation for the nan package does not list the libsvm entry points directly. Rather, train_sc and test_sc commands provide a richer interface to a wide variety of ML algorithms, including support vector machines. Nevertheless, the libsvm commands are still available via their mex, which may account for the shadowing warnings. They are named svmtrain_mex and svmpredict_mex.
I expect that both the train_sc and svmtrain_mex interfaces should work fine. I didn't try them out though. Had I known about this before, I would probably not have attempted compilation of the libsvm sources into mex. You should be able to test it out by typing: >> load pkg nan %note that this lists ~25 shadoing warnings >> svmtrain_mex >> svmpredict_mex See: nan: http://octave.sourceforge.net/nan/overview.html train_sc: http://octave.sourceforge.net/nan/fu.../train_sc.html |
![]() |
Tags |
libsvm, octave |
Thread Tools | |
Display Modes | |
|
|