Skip to content

Commit 3364295

Browse files
committed
Missed one ..
1 parent 5e068e3 commit 3364295

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mllib/src/main/scala/org/apache/spark/ml/classification/LogisticRegression.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,10 +132,10 @@ class LogisticRegressionModel private[ml] (
132132
override def transform(dataset: DataFrame, paramMap: ParamMap): DataFrame = {
133133
transformSchema(dataset.schema, paramMap, logging = true)
134134
val map = this.paramMap ++ paramMap
135-
val scoreFunction = udf((v: Vector) => {
135+
val scoreFunction = udf { v: Vector => {
136136
val margin = BLAS.dot(v, weights)
137137
1.0 / (1.0 + math.exp(-margin))
138-
} : Double)
138+
}
139139
val t = map(threshold)
140140
val predictFunction = udf { score: Double =>
141141
if (score > t) 1.0 else 0.0

0 commit comments

Comments
 (0)