predictionio-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From take...@apache.org
Subject [1/2] incubator-predictionio git commit: Fix use of case class in textclassifier example
Date Tue, 29 Aug 2017 05:04:50 GMT
Repository: incubator-predictionio
Updated Branches:
  refs/heads/develop 08ebd6b55 -> bcc0afe61


Fix use of case class in textclassifier example

Closes #426


Project: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/commit/9c68d86c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/tree/9c68d86c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/diff/9c68d86c

Branch: refs/heads/develop
Commit: 9c68d86c61a06b08d618b8cd8177c9d76cd86618
Parents: 350b183
Author: Naoki Takezoe <takezoe@apache.org>
Authored: Tue Aug 29 14:03:36 2017 +0900
Committer: Naoki Takezoe <takezoe@apache.org>
Committed: Tue Aug 29 14:03:36 2017 +0900

----------------------------------------------------------------------
 docs/manual/source/demo/textclassification.html.md.erb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-predictionio/blob/9c68d86c/docs/manual/source/demo/textclassification.html.md.erb
----------------------------------------------------------------------
diff --git a/docs/manual/source/demo/textclassification.html.md.erb b/docs/manual/source/demo/textclassification.html.md.erb
index 788178d..9830d3d 100644
--- a/docs/manual/source/demo/textclassification.html.md.erb
+++ b/docs/manual/source/demo/textclassification.html.md.erb
@@ -570,7 +570,7 @@ Once you have a vector of class probabilities, you can classify the text
documen
   def predict(doc : String) : PredictedResult = {
     val x: Array[Double] = getScores(doc)
     val y: (Double, Double) = (nb.labels zip x).maxBy(_._2)
-    new PredictedResult(pd.categoryMap.getOrElse(y._1, ""), y._2)
+    PredictedResult(pd.categoryMap.getOrElse(y._1, ""), y._2)
   }
 ```
 


Mime
View raw message