Skip to content

Commit

Permalink
Merge pull request #2896 from xh2/bugfix/lda-doc-alpha
Browse files Browse the repository at this point in the history
Make docs clearer on `alpha` parameter in LDA model
  • Loading branch information
piskvorky authored Jul 26, 2020
2 parents c0e0169 + 7d0ef9e commit a662e8d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions gensim/models/ldamodel.py
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,8 @@ def __init__(self, corpus=None, num_topics=100, id2word=None,
our a-priori belief for the each topics' probability.
Alternatively default prior selecting strategies can be employed by supplying a string:
* 'asymmetric': Uses a fixed normalized asymmetric prior of `1.0 / topicno`.
* 'symmetric': Default; uses a fixed symmetric prior per topic,
* 'asymmetric': Uses a fixed normalized asymmetric prior of `1.0 / (topic_index + sqrt(num_topics))`,
* 'auto': Learns an asymmetric prior from the corpus (not available if `distributed==True`).
eta : {float, np.array, str}, optional
A-priori belief on word probability, this can be:
Expand Down Expand Up @@ -536,7 +537,8 @@ def init_dir_prior(self, prior, name):
If `name` == 'alpha', then the prior can be:
* an 1D array of length equal to the number of expected topics,
* 'asymmetric': Uses a fixed normalized asymmetric prior of `1.0 / topicno`.
* 'symmetric': Uses a fixed symmetric prior per topic,
* 'asymmetric': Uses a fixed normalized asymmetric prior of `1.0 / (topic_index + sqrt(num_topics))`,
* 'auto': Learns an asymmetric prior from the corpus.
name : {'alpha', 'eta'}
Whether the `prior` is parameterized by the alpha vector (1 parameter per topic)
Expand Down

0 comments on commit a662e8d

Please sign in to comment.