Skip to content

Commit

Permalink
update saved details of GPassKEvaluator
Browse files Browse the repository at this point in the history
  • Loading branch information
jnanliu committed Dec 20, 2024
1 parent 66cad93 commit 0a8807f
Showing 1 changed file with 18 additions and 9 deletions.
27 changes: 18 additions & 9 deletions opencompass/openicl/icl_evaluator/icl_gpassk_evaluator.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,15 +125,24 @@ def score(self, predictions, references, origin_prompt,
total_pass_num, count = 0, 0
for example_abbr, examples in example2replications.items():
detail = {
'question': examples[0]['question'],
'answer': examples[0]['answer'],
'question_type': examples[0]['question_type'],
'options': examples[0]['options'],
'subdivision': examples[0]['subdivision'],
'idx': examples[0]['idx'],
'prompt': examples[0]['prompt'],
'predictions': [example['prediction'] for example in examples],
'labels': [example['label'] for example in examples],
'question':
examples[0]['question'],
'answer':
examples[0]['answer'],
'question_type':
examples[0]['question_type'],
'options':
examples[0]['options'],
'subdivision':
examples[0]['subdivision'],
'idx':
examples[0]['idx'],
'prompt':
examples[0]['prompt'],
'predictions': [{
'prediction': example['prediction'],
'label': example['label']
} for example in examples],
}

all_dataset.add(examples[0]['subdivision'])
Expand Down

0 comments on commit 0a8807f

Please sign in to comment.