I’ve built my own model using a gensim word2vec and succesfully loaded it using
nlp = spacy.load('/Users/mos/Dropbox/spacy/build_swedish_spacy_model/w2v_model_1M')
Now, when I try to load it again in the same way it throws an error:
---------------------------------------------------------------------------
OverflowError Traceback (most recent call last)
<ipython-input-3-12adfa70fede> in <module>()
1 import spacy
----> 2 nlp = spacy.load('/Users/mos/Dropbox/spacy/build_swedish_spacy_model/w2v_model_1M')
3 #nlp.add_pipe(nlp.create_pipe('ner'))
4 #nlp.to_disk('/Users/mos/Dropbox/spacy/build_swedish_spacy_model/w2v_model_1M')
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/__init__.py in load(name, **overrides)
40 overrides['meta'] = meta
41 overrides['path'] = model_path
---> 42 return cls(**overrides)
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/language.py in __init__(self, **overrides)
263
264 self.vocab = self.Defaults.create_vocab(self) \
--> 265 if 'vocab' not in overrides \
266 else overrides['vocab']
267 add_vectors = self.Defaults.add_vectors(self) \
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/language.py in create_vocab(cls, nlp)
40 else:
41 vocab = Vocab.load(nlp.path, lex_attr_getters=cls.lex_attr_getters,
---> 42 tag_map=cls.tag_map, lemmatizer=lemmatizer)
43 for tag_str, exc in cls.morph_rules.items():
44 for orth_str, attrs in exc.items():
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/vocab.pyx in spacy.vocab.Vocab.load (spacy/vocab.cpp:4974)()
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/vocab.pyx in
spacy.vocab.Vocab.load_lexemes (spacy/vocab.cpp:9653)()
/Users/mos/anaconda3/lib/python3.5/site-packages/spacy/strings.pyx in
spacy.strings.StringStore.__getitem__ (spacy/strings.cpp:2470)()
OverflowError: can't convert negative value to uint64_t
I have the code in Dropbox, which might be a bad idea in general. Might it be something resulting from that?