dictionary = corpora.Dictionary(newlist)
corpus = [dictionary.doc2bow(text) for text in newlist]
改成:
dictionary = corpora.Dictionary([newlist])
corpus = [dictionary.doc2bow(text) for text in [newlist]]
两个地方都要加上方括号
dictionary = corpora.Dictionary(newlist)
corpus = [dictionary.doc2bow(text) for text in newlist]
改成:
dictionary = corpora.Dictionary([newlist])
corpus = [dictionary.doc2bow(text) for text in [newlist]]
两个地方都要加上方括号