srowen commented on a change in pull request #24458: [SPARK-27540][MLlib] Add
'meanAveragePrecision_at_k' metric to RankingMetrics
URL: https://github.com/apache/spark/pull/24458#discussion_r278597275
##########
File path:
mllib/src/main/scala/org/apache/spark/mllib/evaluation/RankingMetrics.scala
##########
@@ -209,8 +259,9 @@ object RankingMetrics {
@Since("1.4.0")
def of[E, T <: jl.Iterable[E]](predictionAndLabels: JavaRDD[(T, T)]):
RankingMetrics[E] = {
implicit val tag = JavaSparkContext.fakeClassTag[E]
- val rdd = predictionAndLabels.rdd.map { case (predictions, labels) =>
- (predictions.asScala.toArray, labels.asScala.toArray)
+ val rdd = predictionAndLabels.rdd.map {
Review comment:
I think this much can be reverted?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]