Reputation: 439
I am using eclipse to run Weka API along with LibSVM, weka API works fine but I cannot call LibSVM. I have checked to add LibSVM to the classpath and keep the right order of jar files. I have 1) JVM 1.7 2) Weka.jar 3.7.10. 3) LibSVM.jar located in wlsvm.zip located in the following link: http://www.cs.iastate.edu/~yasser/wlsvm.html
The problem I have: I am not able to instantiate LibSVM and not able to import it. Here is snapshot of the problem I have along with classpath confiugreation:
https://www.dropbox.com/sh/rj8ian8asceyf7b/YTHzOfHFIs#/
Any help is highly appreciated!
Upvotes: 2
Views: 1138
Reputation: 439
All provided links in my original post are for weka 3.6.8 and prior, and they were not compatible with weka 3.7 and most recent. Therefore, If you really want to use weka 3.7 jar and libsvm in your java code, then one way is to run weka GUI 3.7 as usual, select package manager from tool at the main bar and install libSVM. After that head to the folder in which libSVM has been installed. For Windows it usually has the following path: C:\Users\YourUserName\wekafiles\packages\LibSVM\LibSVM.jar; For MAC: (HOME)\wekafiles\packages\LibSVM\LibSVM.jar Then, simply add LibSVM.jar to your classpath of the javacode along with weka.jar "3.7" ..., where the order doesn't matter.
This package manager will always guarantee installing a compatible library with your weka. PS: you no logner need WLSVM in the classpath...
Upvotes: 1