Commit b64e592d authored by lintangsutawika's avatar lintangsutawika
Browse files

fix missing lines

parent 47933b98
......@@ -111,7 +111,9 @@ def parse_eval_args() -> argparse.Namespace:
help=(
"String arguments for model generation on greedy_until tasks,"
" e.g. `temperature=0,top_k=0,top_p=0`"
)
),
)
parser.add_argument(
"--verbosity",
type=str,
default="INFO",
......@@ -216,7 +218,7 @@ def cli_evaluate(args: Union[argparse.Namespace, None] = None) -> None:
check_integrity=args.check_integrity,
write_out=args.write_out,
log_samples=args.log_samples,
gen_kwargs=args.gen_kwargs
gen_kwargs=args.gen_kwargs,
)
if results is not None:
......
......@@ -21,7 +21,7 @@ from lm_eval.utils import (
create_iterator,
get_git_commit_hash,
simple_parse_args_string,
eval_logger
eval_logger,
)
......@@ -41,7 +41,7 @@ def simple_evaluate(
decontamination_ngrams_path=None,
write_out: bool = False,
log_samples: bool = True,
gen_kwargs: str = None
gen_kwargs: str = None,
):
"""Instantiate and evaluate a model on a list of tasks.
......@@ -127,8 +127,8 @@ def simple_evaluate(
continue
config = task_obj._config
if config['output_type'] == 'greedy_until' and gen_kwargs is not None:
config['generation_kwargs'].update(gen_kwargs)
if config["output_type"] == "greedy_until" and gen_kwargs is not None:
config["generation_kwargs"].update(gen_kwargs)
if num_fewshot is not None:
if config["num_fewshot"] > 0:
......@@ -167,7 +167,7 @@ def simple_evaluate(
"use_cache": use_cache,
"limit": limit,
"bootstrap_iters": bootstrap_iters,
"gen_kwargs": gen_kwargs
"gen_kwargs": gen_kwargs,
}
results["git_hash"] = get_git_commit_hash()
return results
......
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