Fix broken data path and add git clone cell
" cd glove && make "
]
},
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Cloning into 'glove'...\n",
+ "remote: Enumerating objects: 431, done.\u001b[K\n",
+ "remote: Total 431 (delta 0), reused 0 (delta 0), pack-reused 431\u001b[K\n",
+ "Receiving objects: 100% (431/431), 176.20 KiB | 0 bytes/s, done.\n",
+ "Resolving deltas: 100% (236/236), done.\n",
+ "Checking connectivity... done.\n"
+ ]
+ }
+ ],
+ "source": [
+ "!git clone http://github.com/stanfordnlp/glove "
+ ]
+ },
{
"cell_type": "markdown",
"metadata": {},
"outputs": [],
"source": [
"# Save our corpus as tokens delimited by spaces with new line characters in between sentences.\n",
- "with open(BASE_DATA_PATH+'/clean/stsbenchmark/training-corpus-cleaned.txt', 'w', encoding='utf8') as file:\n",
+ "with open(BASE_DATA_PATH+'/raw/stsbenchmark/training-corpus-cleaned.txt', 'w', encoding='utf8') as file:\n",
" for sent in sentences:\n",
" file.write(\" \".join(sent) + \"\\n\")"
]
}
],
"source": [
- "!\"glove/build/vocab_count\" -min-count 5 -verbose 2 <\"../../data/clean/stsbenchmark/training-corpus-cleaned.txt\"> \"../../data/trained_word_embeddings/vocab.txt\""
+ "!\"glove/build/vocab_count\" -min-count 5 -verbose 2 <\"../../data/raw/stsbenchmark/training-corpus-cleaned.txt\"> \"../../data/trained_word_embeddings/vocab.txt\""
]
},
{
}
],
"source": [
- "!\"glove/build/cooccur\" -memory 4 -vocab-file \"../../data/trained_word_embeddings/vocab.txt\" -verbose 2 -window-size 15 <\"../../data/clean/stsbenchmark/training-corpus-cleaned.txt\"> \"../../data/trained_word_embeddings/cooccurrence.bin\""
+ "!\"glove/build/cooccur\" -memory 4 -vocab-file \"../../data/trained_word_embeddings/vocab.txt\" -verbose 2 -window-size 15 <\"../../data/raw/stsbenchmark/training-corpus-cleaned.txt\"> \"../../data/trained_word_embeddings/cooccurrence.bin\""
]
},
{
