MCPcopy Create free account
hub / github.com/InternScience/SciReason / __init__

Method __init__

opencompass/summarizers/default.py:41–65  ·  view source on GitHub ↗
(self, config: ConfigDict, dataset_abbrs: Optional[List[str]] = None, summary_groups: List = [], prompt_db = None)

Source from the content-addressed store, hash-verified

39 """
40
41 def __init__(self, config: ConfigDict, dataset_abbrs: Optional[List[str]] = None, summary_groups: List = [], prompt_db = None) -> None:
42 self.tasks = []
43 self.cfg = config
44 self.logger = get_logger()
45 self.summary_groups = summary_groups
46 self.dataset_abbrs = dataset_abbrs
47 if prompt_db:
48 self.logger.warning('prompt_db is deprecated and no longer used. '
49 'Please remove it from your config.')
50
51 # Enable lark bot if lark_url is presented
52 self.lark_reporter = None
53 if self.cfg.get('lark_bot_url', None):
54 self.lark_reporter = LarkReporter(self.cfg['lark_bot_url'])
55
56 self.model_cfgs = self.cfg['models']
57 self.dataset_cfgs = self.cfg['datasets']
58 self.work_dir = self.cfg['work_dir']
59 model_abbrs = []
60 for model in self.model_cfgs:
61 model_abbr = model_abbr_from_cfg_used_in_summarizer(model)
62 if model_abbr in model_abbrs:
63 continue
64 model_abbrs.append(model_abbr)
65 self.model_abbrs = model_abbrs
66
67 def _pick_up_results(self):
68 """The function reads the numerical results of evaluations from the

Callers

nothing calls this directly

Calls 4

get_loggerFunction · 0.90
LarkReporterClass · 0.90
getMethod · 0.80

Tested by

no test coverage detected