Constructor
new DistributedLDAModel()
Extends
Methods
(static) load(path) → {module:eclairjs/mllib/clustering.DistributedLDAModel}
Parameters:
Name | Type | Description |
---|---|---|
path |
string |
Returns:
(static) read() → {module:eclairjs/ml/util.MLReader}
Returns:
copy(extra) → {module:eclairjs/mllib/clustering.DistributedLDAModel}
Parameters:
Name | Type | Description |
---|---|---|
extra |
module:eclairjs/ml/param.ParamMap |
Returns:
describeTopics(maxTermsPerTopicopt) → {Array.<module:eclairjs.Tuple2>}
Return the topics described by weighted terms.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
maxTermsPerTopic |
number |
<optional> |
Maximum number of terms to collect for each topic. (term indices, term weights in topic). Each topic's terms are sorted in order of decreasing weight. |
- Inherited From:
- Source:
Returns:
Array over topics. Each topic is represented as a pair of matching arrays:
- Type
- Array.<module:eclairjs.Tuple2>
docConcentration() → {module:eclairjs/mllib/linalg.Vector}
Concentration parameter (commonly named "alpha") for the prior placed on documents'
distributions over topics ("theta").
This is the parameter to a Dirichlet distribution.
- Inherited From:
- Source:
Returns:
isDistributed() → {boolean}
Returns:
- Type
- boolean
k() → {number}
- Inherited From:
- Source:
Returns:
- Type
- number
toLocal() → {module:eclairjs/mllib/clustering.LocalLDAModel}
Convert this distributed model to a local representation. This discards info about the
training dataset.
WARNING: This involves collecting a large topicsMatrix to the driver.
Returns:
topicConcentration() → {number}
Concentration parameter (commonly named "beta" or "eta") for the prior placed on topics'
distributions over terms.
This is the parameter to a symmetric Dirichlet distribution.
Note: The topics' distributions over terms are called "beta" in the original LDA paper
by Blei et al., but are called "phi" in many later papers such as Asuncion et al., 2009.
- Inherited From:
- Source:
Returns:
- Type
- number
topicsMatrix() → {module:eclairjs/mllib/linalg.Matrix}
Inferred topics, where each topic is represented by a distribution over terms.
This is a matrix of size vocabSize x k, where each column is a topic.
No guarantees are given about the ordering of the topics.
- Inherited From:
- Source:
Returns:
vocabSize() → {number}
- Inherited From:
- Source:
Returns:
- Type
- number