Github user EntilZha commented on the pull request:
https://github.com/apache/spark/pull/4047#issuecomment-70542992
What might be the best way to have the EM and Gibbs LDA implementations
play well with each other?
If the aim is to not have separate LDA classes, on first thought I think
maybe then LearningState would be where to put the work in. So, that would mean
creating the LearningState trait, then within LDA, there would be multiple
definitions of classes that satisfy LearningState. So you might have
GibbsLearningState and EMLearningState (solves that naming problem easily). It
seems like most of the implementation would be within LearningState anyway, not
per se within LDA.
This has the advantage you named, in the LDA constructor we could set the
default LearningState type to either EM or Gibbs (probably whichever performs
better), allowing users to specify which algorithm they would like if wanted.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]