We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
运行mmlu评估时,results.json中的结果少了一项。 results.json中没课结果只有四个答案,如下:
"abstract_algebra": { "0": "B", "1": "C", "2": "A", "3": "A" }, "anatomy": { "0": "D", "1": "C", "2": "C", "3": "B" },
mmlu的数据中每个应该有五项: abstract_algebra如下:
anatomy如下所示:
运行的脚本:
python run/eval.py llama3_lora_eval.yaml
run/eval.py简单的套了个run_eval()函数,如下所示:
from llamafactory.eval.evaluator import run_eval run_eval()
llama3_lora_eval.yaml如下所示:
### model model_name_or_path: /opt/gfbai/models/Meta-Llama-3-8B-Instruct adapter_name_or_path: saves/llama3-8b/lora/sft/checkpoint-54 ### method finetuning_type: lora ### dataset task: mmlu split: train template: fewshot lang: en n_shot: 5 ### output save_dir: saves/llama3-8b/lora/eval ### eval batch_size: 2 download_mode: force_redownload
输入出完整的答案
transformers
应该是mmlu数据集的脚本有问题 这个文件evaluation/mmlu/mmlu.py中:
def _generate_examples(self, filepath): df = pd.read_csv(filepath) df.columns = ["question", "A", "B", "C", "D", "answer"] for i, instance in enumerate(df.to_dict(orient="records")): yield i, instance
改为以下形式就好了
def _generate_examples(self, filepath): df = pd.read_csv(filepath, header=None) df.columns = ["question", "A", "B", "C", "D", "answer"] for i, instance in enumerate(df.to_dict(orient="records")): yield i, instance
The text was updated successfully, but these errors were encountered:
fixed
Sorry, something went wrong.
3404e8f
No branches or pull requests
Reminder
Reproduction
运行mmlu评估时,results.json中的结果少了一项。
results.json中没课结果只有四个答案,如下:
mmlu的数据中每个应该有五项:
abstract_algebra如下:
anatomy如下所示:
运行的脚本:
run/eval.py简单的套了个run_eval()函数,如下所示:
llama3_lora_eval.yaml如下所示:
Expected behavior
输入出完整的答案
System Info
transformers
version: 4.40.2Others
应该是mmlu数据集的脚本有问题
这个文件evaluation/mmlu/mmlu.py中:
改为以下形式就好了
The text was updated successfully, but these errors were encountered: