MCPcopy Index your code
hub / github.com/clips/pattern / test_find_lemma

Method test_find_lemma

test/test_fr.py:32–40  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

30 print "pattern.fr.predicative()"
31
32 def test_find_lemma(self):
33 # Assert the accuracy of the verb lemmatization algorithm.
34 i, n = 0, 0
35 for v1, v2 in fr.inflect.verbs.inflections.items():
36 if fr.inflect.verbs.find_lemma(v1) == v2:
37 i += 1
38 n += 1
39 self.assertTrue(float(i) / n > 0.80)
40 print "pattern.fr.inflect.verbs.find_lemma()"
41
42 def test_find_lexeme(self):
43 # Assert the accuracy of the verb conjugation algorithm.

Callers

nothing calls this directly

Calls 2

itemsMethod · 0.45
find_lemmaMethod · 0.45

Tested by

no test coverage detected