0

我正在尝试保存 gensim Doc2vec 模型。该模型在 900 万个文档向量和大约 100 万个单词的词汇上进行了训练。但是我收到了pickel错误。“top”表示该程序使用了大约 13GB 的 RAM。另外我认为,由于我需要在需要时为新文档重新训练模型,因此必须保存所有参数。

Traceback (most recent call last):
 File "doc_2_vec.py", line 61, in <module>

model.save("/data/model_wl_videos/model",pickle_protocol=2)
 File "/home/meghana/.local/lib/python2.7/site-packages/gensim/models/word2vec.py", line 1406, in save
super(Word2Vec, self).save(*args, **kwargs)
 File "/home/meghana.negi/.local/lib/python2.7/site-packages/gensim/utils.py", line 504, in save
pickle_protocol=pickle_protocol)
 File "/home/meghana/.local/lib/python2.7/site-packages/gensim/utils.py", line 376, in _smart_save
pickle(self, fname, protocol=pickle_protocol)
 File "/home/meghana/.local/lib/python2.7/site-packages/gensim/utils.py", line 930, in pickle
_pickle.dump(obj, fout, protocol=protocol)

内存错误

4

0 回答 0