Exemplo n.º 1
0
    def test_direct_pos_heur(self):
        gloss_pos = tier_tokens(create_words_tier_from_string('NOUN PRON VERB DET'))
        trans_pos = tier_tokens(create_words_tier_from_string('NOUN VERB DET NOUN'))

        h = heur_alignments(self.gloss_tokens, self.trans_tokens, gloss_pos=gloss_pos, trans_pos=trans_pos).flip()
        self.assertEqual(self.a2, h)
Exemplo n.º 2
0
    def test_add_pos_tags(self):
        add_pos_tags(self.igt, 'gw', self.tags)

        self.assertEquals(tier_tokens(pos_tag_tier(self.igt, 'gw')), self.tags)