GitHub user dbtsai opened a pull request:
https://github.com/apache/spark/pull/1897
[SPARK-2979][MLlib ]Improve the convergence rate by minimize the condition
number
Scaling to minimize the condition number:
During the optimization process, the convergence (rate) depends on the
condition number of the training dataset. Scaling the variables often reduces
this condition number, thus mproving the convergence rate dramatically. Without
reducing the condition number, some training datasets mixing the columns with
different scales may not be able to converge.
GLMNET and LIBSVM packages perform the scaling to reduce the condition
number, and return the weights in the original scale.
See page 9 in http://cran.r-project.org/web/packages/glmnet/glmnet.pdf
Here, if useFeatureScaling is enabled, we will standardize the training
features by dividing the variance of each column (without subtracting the
mean), and train the model in the scaled space. Then we transform the
coefficients from the scaled space to the original scale as GLMNET and LIBSVM
do.
Currently, it's only enabled in LogisticRegressionWithLBFGS
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/AlpineNow/spark dbtsai-feature-scaling
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/1897.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1897
----
commit 5257751cda9cd0cb284af06c81e1282e1bfb53f7
Author: DB Tsai <[email protected]>
Date: 2014-08-08T23:23:21Z
Improve the convergence rate by minimize the condition number in LOR with
LBFGS
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]