AttributeError:'Projection'对象没有属性'u'gensim python lsi

时间:2016-01-13 11:34:03

标签: python-2.7 tf-idf gensim

当我尝试加载模型并对其执行任何操作时,我总是得到:“AttributeError: 'Projection' object has no attribute 'u'

我无法弄清楚我在这里做错了什么。不确定我是否正确保存模型或加载错误。

index = similarities.MatrixSimilarity(lsiModel[tfIdfModel[myCorpus]])
File "/home/analytics/.local/lib/python2.7/site-packages/gensim/models /lsimodel.py", line 405, 
in __getitem__ 
assert self.projection.u is not None, "decomposition not initialized yet"   
AttributeError: 'Projection' object has no attribute 'u'

0 个答案:

没有答案