Commit c605a710 authored by lintangsutawika's avatar lintangsutawika
Browse files

add logging information

parent 618c5936
......@@ -6,3 +6,5 @@ logging.basicConfig(
level=logging.INFO,
)
eval_logger = logging.getLogger("lm-eval")
SPACING = " "*47
\ No newline at end of file
......@@ -9,7 +9,7 @@ from pathlib import Path
from lm_eval import evaluator, utils
from lm_eval.api.registry import ALL_TASKS
from lm_eval.logger import eval_logger
from lm_eval.logger import eval_logger, SPACING
from lm_eval.tasks import include_task_folder
os.environ["TOKENIZERS_PARALLELISM"] = "false"
......@@ -131,6 +131,12 @@ def main():
if os.path.isfile(task):
config = utils.load_yaml_config(task)
task_names.append(config)
if task_names == []:
eval_logger.error(
"No tasks were detected,\n"
f"{SPACING}Try `lm-eval -h` for list of available tasks",
)
if args.output_path:
path = Path(args.output_path)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment