Ejemplo n.º 1
0
 def __call__(self, obj, *args, **kwargs):      
     log.info("reading counts from " + self.counts_pkl_fname)
     self.counts_dict = cPickle.load(open(self.counts_pkl_fname))  
     Scorer.__call__(self, obj, *args, **kwargs)   
Ejemplo n.º 2
0
 def __call__(self, obj, *args, **kwargs):
     # It is assumed that the order of documents (by docid) in the source
     # and reference is the same
     self.counts = iter(read_ref_trans_counts(self.ref_fname, flatten=True))        
     Scorer.__call__(self, obj, *args, **kwargs)