mirror of
				https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
				synced 2025-11-04 12:22:47 +00:00 
			
		
		
		
	Continue new list building for results
This commit is contained in:
		@@ -287,12 +287,14 @@ class CQiWrapper(CQiClient):
 | 
			
		||||
        first_cpos, last_cpos = match_cpos_list[0], match_cpos_list[-1]
 | 
			
		||||
        context_sentences = {}
 | 
			
		||||
        s_ids = self.cl_cpos2struc(key, [first_cpos, last_cpos])
 | 
			
		||||
        logger.warning('s id match: {}'.format(s_ids))
 | 
			
		||||
        for s_id in s_ids:
 | 
			
		||||
            s_start, s_end = self.cl_struc2cpos(key, s_id)
 | 
			
		||||
            s_cpos = list(range(s_start, s_end + 1))
 | 
			
		||||
            context_sentences[s_id] = s_cpos
 | 
			
		||||
        if get_surrounding_s:
 | 
			
		||||
            max_s_id = self.cl_attribute_size(key)
 | 
			
		||||
            max_s_id = self.cl_attribute_size(key) - 1
 | 
			
		||||
            logger.warning('max sid: {}'.format(max_s_id))
 | 
			
		||||
            additional_s_ids = []
 | 
			
		||||
            additional_s = list(range(max(s_ids[0]
 | 
			
		||||
                                          - l_r_s_context_additional_len,
 | 
			
		||||
@@ -302,6 +304,7 @@ class CQiWrapper(CQiClient):
 | 
			
		||||
                                          max_s_id) + 1))
 | 
			
		||||
            additional_s_ids.extend(additional_s)
 | 
			
		||||
            for s_id in additional_s_ids:
 | 
			
		||||
                logger.warning('s id additional: {}'.format(s_id))
 | 
			
		||||
                s_start, s_end = self.cl_struc2cpos(key, s_id)
 | 
			
		||||
                s_cpos = list(range(s_start, s_end + 1))
 | 
			
		||||
                context_sentences[s_id] = s_cpos
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user