Open
Description
评估越来越慢,gpu利用率低
在我使用evalscope评估后,评估耗时异常,发现推理每条的耗时从不到3秒下降到80+秒
使用的工具 / Tools Used
- Native / 原生框架
执行的代码或指令 / Code or Commands Executed
import os
import pprint
from evalscope.run import run_task
from evalscope.config import TaskConfig, registry_tasks
eval_model_path=""
outputs=""
TaskConfig.registry(
name=task_name, # 任务名称
data_pattern="general_qa", # 数据格式
dataset_dir=dataset_dir, # 数据集路径
)
# 2. 配置任务,通过任务名称获取配置
task_cfg = registry_tasks[task_name]
# Prepare the config
task_cfg.update(
{
"generation_config": {
"do_sample": False,
"repetition_penalty": 1.0,
"max_new_tokens": 2048,
},
"eval_type": "checkpoint",
"model": eval_model_path,
"template_type": "qwen",
"outputs": outputs,
"mem_cache": False,
"use_cache": False,
"eval_backend": "Native",
"debug": False,
}
)
print("task_cfg:")
pprint.pprint(task_cfg)
# Run task
run_task(task_cfg=task_cfg)
请提供您执行的主要代码或指令。 / Please provide the main code or commands you executed. 例如 / For example:
错误日志 / Error Log
请粘贴完整的错误日志或控制台输出。 / Please paste the full error log or console output. 例如 / For example:
日志正常,变慢
运行环境 / Runtime Environment
-
操作系统 / Operating System:
- Ubuntu
-
Python版本 / Python Version:
- 3.11.9
其他信息 / Additional Information
如果有其他相关信息,请在此处提供。 / If there is any other relevant information, please provide it here.