Last active
March 4, 2018 23:37
-
-
Save eisenjulian/6f0add8a141931637210b9a1ebba29f6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
embeddings = {} | |
with open('glove.6B.50d.txt', 'r', encoding='utf-8') as f: | |
for line in f: | |
values = line.strip().split() | |
w = values[0] | |
vectors = np.asarray(values[1:], dtype='float32') | |
embeddings[w] = vectors |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment