Setup WEKA and LIBSVM for WEKA in Debian Etch

When we try to use LIBSVM through WEKA, we might encounter the problem of libsvm.jar not in the classpath. Here, I’d like to describe how to set up Weka and LIBSVM for weka.

1) Download weka-3.5.7.zip from http://www.cs.waikato.ac.nz/ml/weka/, and unzip it to /path/to/weka-3.5.7

2) Download libsvm-2.85.zip from http://www.csie.ntu.edu.tw/~cjlin/libsvm/, and unzip it into /path/to/libsvm-2.85

3) Copy weka.gif in the /path/to/weka-3.5.7 to /usr/share/pixmaps. (need to be root)

4) Right click on the Gnome top tool bar -> Add to panel –> Custom Application Launcher

5) In the command, enter:

<code>

java -Xmx1600m -classpath $CLASSPATH:/path/to/weka-3-5-7/weka.jar:/path/to/libsvm-2.84/java/libsvm.jar weka.gui.GUIChooser

</code>

6) In the icon, there should be weka.gif in the list due to step 3 above.

7) Change WEKA Java maximum heap size as appropriate in the command line above by modifying -Xmx1600m, where 1600m = 1.6GB.

[Update: March 21, 2008] If you don’t do any feature selection or preprocessing, don’t bother using WEKA for your LIBSVM experiment. Writing your own Java interface to LIBSVM will take less momory consumption and faster execution time, or you just run LIBSVM from the command line. 

[Update: April 8, 2008] Feature selection is an important step for data mining/text mining tasks. A list here http://elvis.slis.indiana.edu/fetched/kiduk/0409.html explains how to use feature selection in Weka.

Advertisements
This entry was posted in Java, Linux, text mining. Bookmark the permalink.

One Response to Setup WEKA and LIBSVM for WEKA in Debian Etch

  1. zizoo says:

    hi
    thank you for this useful information,
    but i need to setup lebsvm for weka in windows xp
    can u help me to do this.
    thanks and best regards.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s