You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
notebook In [21]:
def get_word_vec_similarity(node1, node2, node_ls):
node1_vec = [tup[4] for tup in node_ls if tup[0] == node1]
node2_vec = [tup[4] for tup in node_ls if tup[0] == node2]
if node1_vec and node2_vec:
return cosine_similarity(node1_vec, node2_vec)
return 'one or both terms not found'
The text was updated successfully, but these errors were encountered:
notebook In [21]:
def get_word_vec_similarity(node1, node2, node_ls):
node1_vec = [tup[4] for tup in node_ls if tup[0] == node1]
node2_vec = [tup[4] for tup in node_ls if tup[0] == node2]
if node1_vec and node2_vec:
return cosine_similarity(node1_vec, node2_vec)
return 'one or both terms not found'
The text was updated successfully, but these errors were encountered: