You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "DB Tsai (JIRA)" <ji...@apache.org> on 2015/09/27 02:01:12 UTC

[jira] [Comment Edited] (SPARK-3181) Add Robust Regression Algorithm with Huber Estimator

    [ https://issues.apache.org/jira/browse/SPARK-3181?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14909530#comment-14909530 ] 

DB Tsai edited comment on SPARK-3181 at 9/27/15 12:00 AM:
----------------------------------------------------------

Ref: Prof. Art Owen's paper, [A robust hybrid of lasso and ridge regression](http://statweb.stanford.edu/~owen/reports/hhu.pdf ). 

In MLlib/Breeze, since we don't support L-BFGS-B while the scaling factor in Eq.(6) \sigma has to be >= 0, we can replace it by \exp(\sigma). However, the second derivative of Huber loss is not continuous, this will cause some stability issue since L-BFGS requires it for guaranteed convergence. The workaround I'm going to implement will be [Pseudo-Huber loss function](https://en.wikipedia.org/wiki/Huber_loss#Pseudo-Huber_loss_function) which can be used as a smooth approximation of the Huber loss function, and ensures that derivatives are continuous for all degrees.

BTW, in robust regression, the scaling factor \sigma has to be estimated as well, and this value can not be a constant. Imagining that, when the optimization is just started with some initial condition, if the initial guess is not good, then most of the training instances will be treated as outliners. As a result, \epsilon will be large initially, but will be one of the parameters that will be estimated. See the details in Prof. Art Owen's paper in section 4. 


was (Author: dbtsai):
Ref: Prof. Art Owen's paper, [A robust hybrid of lasso and ridge regression](http://statweb.stanford.edu/~owen/reports/hhu.pdf ). 

In MLlib/Breeze, since we don't support L-BFGS-B while the scaling factor in Eq.(6) \sigma has to be >= 0, we can replace it by \exp(\sigma). However, the second derivative of Huber loss is not continuous, this will cause some stability issue since L-BFGS requires it for guaranteed convergence. The workaround I'm going to implement will be [Pseudo-Huber loss function](https://en.wikipedia.org/wiki/Huber_loss#Pseudo-Huber_loss_function) which can be used as a smooth approximation of the Huber loss function, and ensures that derivatives are continuous for all degrees.

BTW, in robust regression, the scaling factor \sigma has to be estimated as well, and this value can not be a constant. Imagining that, when the optimization is just started with some initial condition, if the initial guess is not good, then most of the training instances will be treated as outliners. As a result, \epsilon will be large initially, but will be one of the parameters to be minimized. See the details in Prof. Art Owen's paper in section 4. 

> Add Robust Regression Algorithm with Huber Estimator
> ----------------------------------------------------
>
>                 Key: SPARK-3181
>                 URL: https://issues.apache.org/jira/browse/SPARK-3181
>             Project: Spark
>          Issue Type: New Feature
>          Components: MLlib
>            Reporter: Fan Jiang
>            Assignee: Fan Jiang
>              Labels: features
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> Linear least square estimates assume the error has normal distribution and can behave badly when the errors are heavy-tailed. In practical we get various types of data. We need to include Robust Regression  to employ a fitting criterion that is not as vulnerable as least square.
> In 1973, Huber introduced M-estimation for regression which stands for "maximum likelihood type". The method is resistant to outliers in the response variable and has been widely used.
> The new feature for MLlib will contain 3 new files
> /main/scala/org/apache/spark/mllib/regression/RobustRegression.scala
> /test/scala/org/apache/spark/mllib/regression/RobustRegressionSuite.scala
> /main/scala/org/apache/spark/examples/mllib/HuberRobustRegression.scala
> and one new class HuberRobustGradient in 
> /main/scala/org/apache/spark/mllib/optimization/Gradient.scala



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org