MCPcopy Create free account
hub / github.com/MotrixLab/ViMoGen / register_subparsers

Function register_subparsers

mbench/cli/evaluate.py:7–46  ·  view source on GitHub ↗
(subparser)

Source from the content-addressed store, hash-verified

5
6CUR_DIR = os.path.dirname(os.path.abspath(__file__))
7def register_subparsers(subparser):
8 parser = subparser.add_parser('evaluate', formatter_class=argparse.RawTextHelpFormatter)
9 parser.add_argument(
10 "--ngpus",
11 type=int,
12 default=1,
13 help="Number of GPUs to run evaluation on"
14 )
15 parser.add_argument(
16 "--output_path",
17 type=str,
18 default='./evaluation_results/',
19 help="output path to save the evaluation results",
20 )
21 parser.add_argument(
22 "--full_json_dir",
23 type=str,
24 default=f'{CUR_DIR}/../MBench_full_info.json',
25 help="path to save the json file that contains the prompt and dimension information",
26 )
27 parser.add_argument(
28 "--evaluation_path",
29 type=str,
30 required=True,
31 help="folder that contains the model generated results",
32 )
33 parser.add_argument(
34 "--dimension",
35 type=str,
36 required=True,
37 help="list of evaluation dimensions, usage: --dimension <dim_1> <dim_2>",
38 )
39 parser.add_argument(
40 "--load_ckpt_from_local",
41 type=bool,
42 required=False,
43 help="whether load checkpoints from local default paths (assuming you have downloaded the checkpoints locally",
44 )
45
46 parser.set_defaults(func=evaluate)
47
48def stringify_cmd(cmd_ls):
49 cmd = ""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected