Skip to content

Commit

Permalink
callUDF => udf in ProbabilisticClassifier
Browse files Browse the repository at this point in the history
  • Loading branch information
BenFradet committed Jun 24, 2015
1 parent 0ea30b3 commit fe2a10b
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,9 @@ private[spark] abstract class ProbabilisticClassificationModel[
}
if ($(predictionCol).nonEmpty) {
val predUDF = if ($(rawPredictionCol).nonEmpty) {
callUDF(raw2prediction _, DoubleType, col($(rawPredictionCol)))
udf[Double, Vector](raw2prediction).apply(col($(rawPredictionCol)))
} else if ($(probabilityCol).nonEmpty) {
callUDF(probability2prediction _, DoubleType, col($(probabilityCol)))
udf[Double, Vector](probability2prediction).apply(col($(probabilityCol)))
} else {
callUDF(predict _, DoubleType, col($(featuresCol)))
}
Expand Down

0 comments on commit fe2a10b

Please sign in to comment.