I've used Watson Studio for some basic course work; is it possible to load Google Word Vectors in binary form (.bin) into Watson Studio?
Asked
Active
Viewed 79 times
1 Answers
0
You can certainly read binary format files and technically any type of files in watson studio Notebook.
First thing, you need is to upload the binary zip file of
GoogleNews-vectors-negative300.bin.gz to watson studio data asset, you can drag and drop to files section.
Once that is done, you can use project-lib
to read that file into binary object.
insert project token, please refer below documentation on how to.
fetch file
my_file = project.get_file("GoogleNews-vectors-negative300.bin.gz")
since it is gzip, you need to use gzip
import gzip
gzip_f = gzip.GzipFile(fileobj=my_file)
install gensim
!pip install gensim
- import genism and Load the model
import gensim
# Load Google's pre-trained Word2Vec model.
model = gensim.models.KeyedVectors.load_word2vec_format(gzip_f,binary=True)

charles gomes
- 2,145
- 10
- 15