From f99b04588d3725f28d13dcdfcbc0846cc1c52321 Mon Sep 17 00:00:00 2001 From: Adam Lopez Date: Wed, 5 Sep 2012 13:15:17 -0400 Subject: Pass F, E texts to features --- python/src/sa/rulefactory.pxi | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'python/src/sa/rulefactory.pxi') diff --git a/python/src/sa/rulefactory.pxi b/python/src/sa/rulefactory.pxi index a123e85f..ea0805bf 100644 --- a/python/src/sa/rulefactory.pxi +++ b/python/src/sa/rulefactory.pxi @@ -19,7 +19,9 @@ FeatureContext = namedtuple('FeatureContext', 'fsample_count', 'input_span', 'matches', - 'test_sentence' + 'test_sentence', + 'f_text', + 'e_text' ]) cdef int PRECOMPUTE = 0 @@ -1103,7 +1105,7 @@ cdef class HieroCachingRuleFactory: count = len(locs) scores = self.scorer.score(FeatureContext( f, e, count, fcount[f], num_samples, - (k,i+spanlen), locs, fwords + (k,i+spanlen), locs, fwords, self.fda, self.eda )) yield Rule(self.category, f, e, scores, alignment) -- cgit v1.2.3