Skip to content

Commit

Permalink
[SPARK-1406] Fixed extreme cases for logit
Browse files Browse the repository at this point in the history
  • Loading branch information
selvinsource committed Apr 28, 2015
1 parent 7a5e0ec commit 30165c4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ private[mllib] class BinaryClassificationPMMLModelExport(
var interceptNO = threshold
if (RegressionNormalizationMethodType.LOGIT == normalizationMethod) {
if (threshold <= 0)
interceptNO = 1000
else if (threshold >= 1)
interceptNO = -1000
else if (threshold >= 1)
interceptNO = 1000
else
interceptNO = -math.log(1/threshold -1)
}
Expand Down

0 comments on commit 30165c4

Please sign in to comment.