[ 
https://issues.apache.org/jira/browse/SPARK-10413?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14904276#comment-14904276
 ] 

Yanbo Liang edited comment on SPARK-10413 at 9/23/15 10:23 AM:
---------------------------------------------------------------

[~mengxr] 
I think to support prediction on single instance for PredictionModel and its 
subclass is not complex, we just make predict() public and add test cases.
In the case of other Model subclass we should add predict function for single 
instance prediction. And then the transform function will use predict functions 
as UDF.
And one issues that we should discuss is that after we make predict as public,  
shall we need to make other functions such as predictRaw, predictProbability, 
etc. public for single instance?
I have send a PR to illustrate my thought(still work-in-progress), and looking 
forward your comments to verify whether I am in the correct direction.


was (Author: yanboliang):
[~mengxr] 
I think to support prediction on single instance for PredictionModel and its 
subclass is not complex, we just make predict() public and add test cases.
In the case of other Model subclass we should add predict function for single 
instance prediction. And then the transform function will use predict functions 
as UDF.
And one issues that we should discuss is that after we make predict as public,  
shall we need to make other functions such as predictRaw, predictProbability, 
etc. public for single instance?
 

> Model should support prediction on single instance
> --------------------------------------------------
>
>                 Key: SPARK-10413
>                 URL: https://issues.apache.org/jira/browse/SPARK-10413
>             Project: Spark
>          Issue Type: Umbrella
>          Components: ML
>            Reporter: Xiangrui Meng
>            Priority: Critical
>
> Currently models in the pipeline API only implement transform(DataFrame). It 
> would be quite useful to support prediction on single instance.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to