Skip to content

Commit

Permalink
fix: small bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
ledong0110 committed Aug 3, 2024
1 parent aa11067 commit e8384a6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 2 additions & 1 deletion src/vieval/tools/pipelines/metric_pipelines.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def __init__(self):
"sentiment-analysis": [TextClassificationMetric, CalibrationMetric],
"language-modeling": [LanguageMetric],
"reasoning": [ReasoningMetric],
"math": [ReasoningMetric],
"information-retrieval": [InformationRetrievalMetric],
}

Expand Down Expand Up @@ -58,7 +59,7 @@ def run_mean(
def run_std(
self, data, task_name: str, answer_key: str, class_names: List, args
) -> Dict:
result_lst = self._run_bootrap(data, task_name, answer_key, args)
result_lst = self._run_bootrap(data, task_name, answer_key, class_names, args)
final_result = self._get_std(result_lst)

return final_result
Expand Down
4 changes: 1 addition & 3 deletions src/vieval/tools/pipelines/pipelines.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,7 @@ def __call__(self, ds_wrapper, ds_loader, saving_fn, start_idx=0):
elif "translation" in task:
return self.__translation(ds_wrapper, ds_loader, saving_fn, start_idx)
elif "language-modeling" in task:
return self.__language_modeling(
ds_wrapper, ds_loader, saving_fn, start_idx
)
return self.__language_modeling(ds_wrapper, ds_loader, saving_fn, start_idx)
elif "text-classification" in task:
return self.__multiple_choice_text_classification(
ds_wrapper, ds_loader, saving_fn, start_idx
Expand Down

0 comments on commit e8384a6

Please sign in to comment.