Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…into develop
  • Loading branch information
tmylk committed Aug 14, 2016
2 parents bc8f3b3 + e3ee122 commit 727caf2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/notebooks/doc2vec-lee.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@
"sims = model.docvecs.most_similar([inferred_vector], topn=len(model.docvecs))\n",
"\n",
"# Compare and print the most/median/least similar documents from the train corpus\n",
"print('Test Document ({}): «{}»\\n'.format(doc_id, ' '.join(train_corpus[doc_id].words)))\n",
"print('Test Document ({}): «{}»\\n'.format(doc_id, ' '.join(test_corpus[doc_id])))\n",
"print(u'SIMILAR/DISSIMILAR DOCS PER MODEL %s:\\n' % model)\n",
"for label, index in [('MOST', 0), ('MEDIAN', len(sims)//2), ('LEAST', len(sims) - 1)]:\n",
" print(u'%s %s: «%s»\\n' % (label, sims[index], ' '.join(train_corpus[sims[index][0]].words)))"
Expand Down

0 comments on commit 727caf2

Please sign in to comment.