From 6e0d00b3da13b0b503e1cda7f7eb47e2c958e881 Mon Sep 17 00:00:00 2001 From: Megan Date: Thu, 3 Sep 2020 12:41:01 +0100 Subject: [PATCH] Change num_words to topn in dtm_coherence (#2926) --- gensim/models/wrappers/dtmmodel.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gensim/models/wrappers/dtmmodel.py b/gensim/models/wrappers/dtmmodel.py index 4530bbb3b7..7271e45cf1 100644 --- a/gensim/models/wrappers/dtmmodel.py +++ b/gensim/models/wrappers/dtmmodel.py @@ -604,7 +604,7 @@ def dtm_coherence(self, time, num_words=20): """ coherence_topics = [] for topic_no in range(0, self.num_topics): - topic = self.show_topic(topicid=topic_no, time=time, num_words=num_words) + topic = self.show_topic(topicid=topic_no, time=time, topn=num_words) coherence_topic = [] for prob, word in topic: coherence_topic.append(word)