Skip to content

Commit

Permalink
Tiny fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Anna V. Kozlova committed Dec 28, 2017
1 parent 23031e7 commit b70980d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions week3/week3-Embeddings.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -823,7 +823,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"**Task 4 (W2VTokenizedRanks).** For each question from *test.tsv* submit the ranks of the candidates to earn the points. It should take about 3-5 minutes. Pay attention that the function *rank_candidates* returns a ranking, while in this case you should find a position in this ranking. Ranks should start with 1."
"**Task 4 (W2VTokenizedRanks).** For each question from tokenized *test.tsv* submit the ranks of the candidates to earn the points. It should take about 3-5 minutes. Pay attention that the function *rank_candidates* returns a ranking, while in this case you should find a position in this ranking. Ranks should start with 1."
]
},
{
Expand All @@ -846,7 +846,8 @@
"outputs": [],
"source": [
"w2v_ranks_results = []\n",
"for line in open('test_tokenized.txt'):\n",
"tokenized_test_data = ######### YOUR CODE HERE #############\n",
"for line in open(tokenized_test_data):\n",
" q, *ex = line.strip().split('\\t')\n",
" ranks = rank_candidates(q, ex, wv_embeddings, 300)\n",
" ranked_candidates = [r[0] for r in ranks]\n",
Expand Down Expand Up @@ -1039,7 +1040,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.5.2"
"version": "3.4.3"
}
},
"nbformat": 4,
Expand Down

0 comments on commit b70980d

Please sign in to comment.