Hi,
From liblinear documentation:

Usage: train [options] training_set_file [model_file]

Where options is as follows:
-s type (loss/penalty function)
-c cost
-p epsilon
-e epsilon
-B bias
-wi weight
-v n-fold cross validation
-q

I understand how to relate –s, -c, -wi, -v, -q.

If fit_intercept is true, as it is by default, _get_bias returns 
intercept_scaling (which is 1 by default), so I get the –B bias for liblinear 
will be 1 and not -1?

Regarding –p and –e, I’m not sure which values sklearn is passing to liblinear. 
Probably one of the two is tolerance but I’m not sure.

Does anyone know?

Thank you,






From: Manoj Kumar [mailto:[email protected]]
Sent: Friday, August 08, 2014 11:12 AM
To: [email protected]
Subject: Re: [Scikit-learn-general] mapping liblinear wrapper with LinearSVC

Hi,
I think you need to be looking at the recent master of scikit-learn

LinearSVC inherits from BaseLibLinear, the call to train_wrap is made in this 
line 
https://github.com/scikit-learn/scikit-learn/blob/master/sklearn/svm/base.py#L719
 . You can see the parameter (method) self._get_bias() , which corresponds to 
https://github.com/scikit-learn/scikit-learn/blob/master/sklearn/svm/base.py#L783
 . This is set to -1.0 if intercept is not fit and intercept_scaling if 
fit_intercept is True. I am not really sure about the epsilon parameter though 
(I will have to look in detail) , however the default tol is 1e-4.

HTH
---
Regards,
Manoj Kumar,
GSoC 2014, Scikit-learn
Mech Undergrad
http://manojbits.wordpress.com
------------------------------------------------------------------------------
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to