I am trying to save gensim Doc2vec model. The model is trained on 9M document vectors and vocabulary of around 1M words. But I am getting pickel error. "top" shows that the program uses around 13GB of RAM. Also I think since I need to re-train the model for new documents as and when required, saving all parameters is necessary.
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)
MemoryError