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

Fix positional params used for gensim.models.CoherenceModel in gensim.models.callbacks #1823

Merged
merged 2 commits into from Jan 12, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 5 additions & 2 deletions gensim/models/callbacks.py
Expand Up @@ -98,10 +98,13 @@ def get_value(self, **kwargs):
self.model = None
self.topics = None
super(CoherenceMetric, self).set_parameters(**kwargs)

cm = gensim.models.CoherenceModel(
self.model, self.topics, self.texts, self.corpus, self.dictionary,
self.window_size, self.coherence, self.topn
model=self.model, topics=self.topics, texts=self.texts, corpus=self.corpus,
dictionary=self.dictionary, window_size=self.window_size,
coherence=self.coherence, topn=self.topn
)

return cm.get_coherence()


Expand Down