-
-
Notifications
You must be signed in to change notification settings - Fork 461
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'Word2VecKeyedVectors' object has no attribute 'get_vocab' #249
Comments
The class of "model" is custom defined class but not native gensim model class. You may simply use or you can load embeddings into a custom class first and passing it to augmenter
|
makcedward
added a commit
that referenced
this issue
Nov 21, 2021
makcedward
added a commit
that referenced
this issue
Nov 21, 2021
Thank you! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi!
I'm getting this error when I tried to augment a text. I used a pre-trained embedding called BioWordVec, their github repo is here:
I loaded their vector using gensim
bwv = KeyedVectors.load_word2vec_format('/Thesis/Word Embeddings/BioWordVec_PubMed_MIMICIII_d200.vec.bin', binary=True, limit=1000000)
and used it in WordsEmbAug like this
aug = naw.WordEmbsAug( model_type='word2vec', model= bwv, action="insert")
and when I run
aug_text = aug.augment(text)
I get the error 'Word2VecKeyedVectors' object has no attribute 'get_vocab'
The text was updated successfully, but these errors were encountered: