Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make docs clearer on alpha parameter in LDA model #2896

Merged
merged 5 commits into from
Jul 26, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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