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

yuhao yang commented on SPARK-5567:
-----------------------------------

I guess the major consideration is proper code reuse. 
I can provide a quick implementation based on the inference from 
OnlineLDAOptimizer (simply the gamma computation part).  yet I'm not sure if 
it's appropriate to have LocalLDAModel refer to the methods of 
OnlineLDAOptimizer. Possible solution includes 1) have a separate 
OnlineLDAModel, which can invoke the inference of OnlineLDA; 2) Move the 
inference method to object LDAOptimizer.


> Add prediction methods to LDA
> -----------------------------
>
>                 Key: SPARK-5567
>                 URL: https://issues.apache.org/jira/browse/SPARK-5567
>             Project: Spark
>          Issue Type: Improvement
>          Components: MLlib
>    Affects Versions: 1.3.0
>            Reporter: Joseph K. Bradley
>
> LDA currently supports prediction on the training set.  E.g., you can call 
> logLikelihood and topicDistributions to get that info for the training data.  
> However, it should support the same functionality for new (test) documents.
> This will require inference but should be able to use the same code, with a 
> few modification to keep the inferred topics fixed.
> Note: The API for these methods is already in the code but is commented out.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to