Questions tagged [libsvm]

LIBSVM is a library for Support Vector Machines

LIBSVM is an integrated software for support vector classification, (C-SVC, nu-SVC), regression (epsilon-SVR, nu-SVR) and distribution estimation (one-class SVM). It supports multi-class classification. It comprises of both C++ and Java sources, and interfaces to several commonly used languages, such as Python, MATLAB, R, Ruby, Perl, PHP and Haskell.

1241 questions
11
votes
1 answer

Multi-class classification in libsvm

I'm working with libsvm and I must implement the classification for multiclasses with one versus all. How can I do it? Does libsvm version 2011 use this? I think that my question is not very clear. if libsvm don't use automatically one versus…
images
  • 171
  • 1
  • 1
  • 6
11
votes
3 answers

Multi-Class SVM( one versus all)

I know that LIBSVM only allows one-vs-one classification when it comes to multi-class SVM. However, I would like to tweak it a bit to perform one-against-all classification. I have tried to perform one-against-all below. Is this the correct…
lakshmen
  • 28,346
  • 66
  • 178
  • 276
11
votes
3 answers

Binarization in Natural Language Processing

Binarization is the act of transforming colorful features of of an entity into vectors of numbers, most often binary vectors, to make good examples for classifier algorithms. If we where to binarize the sentence "The cat ate the dog", we could start…
Sebastian Ganslandt
  • 965
  • 2
  • 13
  • 26
11
votes
3 answers

Predict probabilities using SVM

I wrote this code and wanted to obtain probabilities of classification. from sklearn import svm X = [[0, 0], [10, 10],[20,30],[30,30],[40, 30], [80,60], [80,50]] y = [0, 1, 2, 3, 4, 5, 6] clf = svm.SVC() clf.probability=True clf.fit(X, y) prob =…
Vidya Marathe
  • 403
  • 2
  • 6
  • 17
11
votes
4 answers

Precomputed Kernels with LibSVM in Python

I've been searching the net for ~3 hours but I couldn't find a solution yet. I want to give a precomputed kernel to libsvm and classify a dataset, but: How can I generate a precomputed kernel? (for example, what is the basic precomputed kernel for…
Lyyli
  • 111
  • 1
  • 1
  • 3
11
votes
2 answers

How to perform multi-class classification using 'svm' of e1071 package in R

I want to perform multi-class classification using the svm function of e1071 package. But from what I came to know from the documentation of svm, it can only perform binary classification. The vignettes document tells this for multi-class…
StrikeR
  • 1,598
  • 5
  • 18
  • 35
11
votes
2 answers

10 fold cross-validation in one-against-all SVM (using LibSVM)

I want to do a 10-fold cross-validation in my one-against-all support vector machine classification in MATLAB. I tried to somehow mix these two related answers: Multi-class classification in libsvm Example of 10-fold SVM classification in…
Zahra E
  • 427
  • 1
  • 6
  • 25
11
votes
5 answers

How do I install libsvm for python under windows 7?

Would like to know how to install libsvm for python under windows 7? I downloaded the livsvm zip, but I don't understand the instructions included. I have placed the libsvm.dll in my c:\windows\system32 directory, but when I try import…
Superdooperhero
  • 7,584
  • 19
  • 83
  • 138
11
votes
1 answer

Libsvm precomputed kernels

I am using libsvm with precomputed kernels. I generated a precomputed kernel file for the example data set heart_scale and executed the function svmtrain(). It worked properly and the support vectors were identifed correctly, i.e. similar to…
user1303919
  • 111
  • 1
  • 4
10
votes
2 answers

scaling the testing data for LIBSVM: MATLAB implementation

I currently use the MATLAB version of the LIBSVM support vector machine to classify my data. The LIBSVM documentation mentions that scaling before applying SVM is very important and we have to use the same method to scale both training and testing…
Lily
  • 315
  • 2
  • 6
  • 16
9
votes
1 answer

How to use libsvm in Matlab?

I am new to matlab and don't know how to use libsvm. Is there any sample code for classifying some data (with 2 features) with a SVM and then visualize the result? How about with kernel (RBF, Polynomial, and Sigmoid )? I saw that readme file in…
Sina
  • 1,632
  • 3
  • 15
  • 21
9
votes
2 answers

How to run easy.py of libsvm in window?

I am new to the libsvm and sorry for some silly questions. I am trying to run easy.py but have problems to do so. I have downloaded the libsvm-3.1 package and extract it into C:\User\Cassie\libsvm Install Python and it created a folder at…
Cassie
  • 1,179
  • 6
  • 18
  • 30
9
votes
2 answers

predict.svm does not predict new data

unfortunately I have problems using predict() in the following simple example: library(e1071) x <- c(1:10) y <- c(0,0,0,0,1,0,1,1,1,1) test <- c(11:15) mod <- svm(y ~ x, kernel = "linear", gamma = 1, cost = 2,…
Richard
  • 201
  • 1
  • 3
  • 5
9
votes
1 answer

LIBSVM Data Preparation: Excel data to LIBSVM format

I want to study how to perform LIBSVM for regression and I'm currently stuck in preparing my data. Currently I have this form of data in .csv and .xlsx format and I want to convert it into libsvm data format. So far, I understand that the data…
Gabriel Luna
  • 127
  • 1
  • 9
9
votes
1 answer

How to use the 'svm_toy' Applet example in LibSVM?

I'm using LIBSVM. In the download package is a svm_toy.java file. I could not find out how it works. Here is the source code: import libsvm.*; import java.applet.*; import java.awt.*; import java.util.*; import java.awt.event.*; import…
Jürgen K.
  • 3,427
  • 9
  • 30
  • 66
1 2
3
82 83