mirror of https://github.com/explosion/spaCy.git
Fix similarity test for Python 3
This commit is contained in:
parent
3e688e6d4b
commit
c05cd2356e
|
@ -9,7 +9,7 @@ import pytest
|
||||||
|
|
||||||
|
|
||||||
def get_vector(letters):
|
def get_vector(letters):
|
||||||
return numpy.asarray(map(ord, letters), dtype='float32')
|
return numpy.asarray([ord(letter) for letter in letters], dtype='float32')
|
||||||
|
|
||||||
|
|
||||||
def get_cosine(vec1, vec2):
|
def get_cosine(vec1, vec2):
|
||||||
|
|
Loading…
Reference in New Issue