Questions tagged [libsvm]

LIBSVM is an integrated software library for support vector machines, performing support vector classification, (C-SVC, nu-SVC), regression (epsilon-SVR, nu-SVR) and distribution estimation (one-class SVM)

Reference: LIBSVM -- A Library for Support Vector Machines

It supports multi-class classification.

LIBSVM provides a simple interface where users can easily link it with their own programs. Main features of LIBSVM include.

  • Different SVM formulations
  • Efficient multi-class classification
  • Cross validation for model selection
  • Probability estimates
  • Various kernels (including precomputed kernel matrix)
  • Weighted SVM for unbalanced data
  • Both C++ and Java sources
  • GUI demonstrating SVM classification and regression
  • Python, R, MATLAB, Perl, Ruby, Weka, Common LISP, CLISP, Haskell, OCaml, LabVIEW, and PHP interfaces. C# .NET code and CUDA extension is available. It's also included in some data mining environments: RapidMiner, PCP, and LIONsolver.
  • Automatic model selection which can generate contour of cross validation accuracy.

The package includes the source code of the library in C++ and Java, and a simple program for scaling training data. A README file with detailed explanation is provided. For MS Windows users, there is a subdirectory in the zip file containing binary executable files. Precompiled Java class archive is also included.

http://www.csie.ntu.edu.tw/~cjlin/libsvm/

219 questions
176
votes
8 answers

What is the influence of C in SVMs with linear kernel?

I am currently using an SVM with a linear kernel to classify my data. There is no error on the training set. I tried several values for the parameter $C$ ($10^{-5}, \dots, 10^2$). This did not change the error on the test set. Now I wonder: is…
alfa
  • 2,505
  • 3
  • 15
  • 15
32
votes
2 answers

libsvm data format

I'm using the libsvm (http://www.csie.ntu.edu.tw/~cjlin/libsvm/) tool for support vector classification. However, I'm confused about the format of the input data. From the README: The format of training and testing data file is:
Siddhant Saraf
  • 421
  • 1
  • 4
  • 6
22
votes
1 answer

libsvm "reaching max number of iterations" warning and cross-validation

I'm using libsvm in C-SVC mode with a polynomial kernel of degree 2 and I'm required to train multiple SVMs. Each training set has 10 features and 5000 vectors. During training, I am getting this warning for most of the SVMs that I train: WARNING:…
19
votes
3 answers

SVM for unbalanced data

I want to attempt to use Support Vector Machines (SVMs) on my dataset. Before I attempt the problem though, I was warned that SVMs dont perform well on extremely unbalanced data. In my case, I can have as much as 95-98% 0's and 2-5% 1's. I tried to…
DankMasterDan
  • 1,188
  • 1
  • 10
  • 23
17
votes
4 answers

Is it possible to append training data to existing SVM models?

I'm using libsvm and I noticed that everytime I call svmtrain(), I create a new model and that there seems to be no option to put data in an existing model. Is this possible to do however? Am I just not seeing this aspect in libsvm?
mugetsu
  • 421
  • 1
  • 5
  • 11
14
votes
2 answers

Output of Scikit SVM in multiclass classification always gives same label

I am currently using Scikit learn with the following code: clf = svm.SVC(C=1.0, tol=1e-10, cache_size=600, kernel='rbf', gamma=0.0, class_weight='auto') and then do fit and predict for a set of data with 7 different labels. I got a…
Tamaki Sakura
  • 435
  • 1
  • 3
  • 11
13
votes
2 answers

Problem with e1071 libsvm?

I have a dataset with two overlapping classes, seven points in each class, points are in two-dimensional space. In R, and I'm running svm from the e1071 package to build a separating hyperplane for these classes. I'm using the following…
Leo
  • 2,484
  • 3
  • 22
  • 29
10
votes
2 answers

Which SVM kernel to use for a binary classification problem?

I'm a beginner when it comes to support vector machines. Are there some guidelines that say which kernel (e.g. linear, polynomial) is best suited for a specific problem? In my case, I have to classify webpages according to whether they contain some…
pemistahl
  • 445
  • 1
  • 4
  • 12
10
votes
1 answer

What does the cost (C) parameter mean in SVM?

I am trying to fit a SVM to my data. My dataset contains 3 classes and I am performing 10 fold cross validation (in LibSVM): ./svm-train -g 0.5 -c 10 -e 0.1 -v 10 training_data The help thereby states: -c cost : set the parameter C of C-SVC,…
9
votes
2 answers

Use of the Gamma parameter with support vector machines

When using libsvm, the parameter $\gamma$ is a parameter for the kernel function. Its default value is setup as $$\gamma = \frac{1}{\text{number of features.}}$$ Is there any theoretical guidance for setting up this parameter besides existing…
user3269
  • 4,622
  • 8
  • 43
  • 53
8
votes
1 answer

How probabilities are calculated for SVM model?

I would like to know, how probabilities are calculated in support vector machine. I have used Iris data set and here is my decision values for three "SupportVectorMachine" (please find the PMML below to know the support vector and coefficient…
Ramkumar
  • 181
  • 1
  • 3
7
votes
3 answers

Is a lower training accuracy possible in overfitting (one class SVM)

I am using the heart_scale data from LibSVM. The original data includes 13 features, but I only used 2 of them in order to plot the distributions in a figure. Instead of training the binary classifier, I treated the problem as a one-class SVM by…
lennon310
  • 2,582
  • 2
  • 21
  • 30
7
votes
4 answers

Libsvm one-class svm: how to consider all data to be in-class

I am using Libsvm for Matlab. I would like to construct the model for a full circumscription of all training data (in the higher SVM-space). For this I assume all my training data is correct and has no outliers. I generate random distributed data…
Roemer
  • 215
  • 2
  • 4
  • 10
7
votes
4 answers

Support vector machine for text classification

I am currently having a data set, class 1 with about 8000 short text files and class 2 with about 3000 short text files. I applied LibSVM and tried a couple of parameter combinations in the cross-validation experiment. Generally the class 1…
user3125
  • 2,617
  • 4
  • 25
  • 33
7
votes
0 answers

Optimising dual SVM: why do some authors drop constraints?

In Hastie's Elements of Statistical Learning the dual problem is put as $$ \begin{align} \text{arg min}_\alpha \quad &\ \frac{1}{2}\alpha^\top Q\, \alpha_i- \sum_i \alpha_i\\ \text{subject to}\quad &\ \forall i:0\le\alpha_i\le C\\ &\ \sum_i y_i…
appletree
  • 167
  • 4
1
2 3
14 15