2015-01-30 05:45:45 +00:00
|
|
|
from __future__ import unicode_literals
|
|
|
|
|
|
|
|
from spacy.en import English
|
|
|
|
|
|
|
|
import pytest
|
|
|
|
|
2015-07-22 23:19:11 +00:00
|
|
|
@pytest.mark.vectors
|
2015-01-30 05:45:45 +00:00
|
|
|
def test_vec(EN):
|
|
|
|
hype = EN.vocab['hype']
|
|
|
|
assert hype.orth_ == 'hype'
|
|
|
|
assert 0.08 >= hype.repvec[0] > 0.07
|
|
|
|
|
2015-04-19 19:39:18 +00:00
|
|
|
|
2015-07-22 23:19:11 +00:00
|
|
|
@pytest.mark.vectors
|
2015-01-30 05:45:45 +00:00
|
|
|
def test_capitalized(EN):
|
|
|
|
hype = EN.vocab['Hype']
|
|
|
|
assert hype.orth_ == 'Hype'
|
|
|
|
assert 0.08 >= hype.repvec[0] > 0.07
|