MCPcopy Create free account
hub / github.com/PolymathicAI/AstroCLIP / get_args_parser

Function get_args_parser

astroclip/astrodino/trainer.py:37–70  ·  view source on GitHub ↗
(add_help: bool = True)

Source from the content-addressed store, hash-verified

35
36
37def get_args_parser(add_help: bool = True):
38 parser = argparse.ArgumentParser("DINOv2 training", add_help=add_help)
39 parser.add_argument(
40 "--config-file",
41 "-c",
42 "--config",
43 default="",
44 metavar="FILE",
45 help="path to config file",
46 )
47 parser.add_argument(
48 "--no-resume",
49 action="store_true",
50 help="Whether to not attempt to resume from the checkpoint directory. ",
51 )
52 parser.add_argument(
53 "--eval-only", action="store_true", help="perform evaluation only"
54 )
55 parser.add_argument("--eval", type=str, default="", help="Eval type to perform")
56 parser.add_argument(
57 "opts",
58 help="""
59Modify config options at the end of the command. For Yacs configs, use
60space-separated "PATH.KEY VALUE" pairs.
61For python-based LazyConfig, use "path.key=value".
62 """.strip(),
63 default=None,
64 nargs=argparse.REMAINDER,
65 )
66 parser.add_argument("--run-name", default="00", help="run name for wandb")
67
68 parser.add_argument("--group-name", default="test", help="group name for wandb")
69
70 return parser
71
72
73def build_optimizer(cfg, params_groups):

Callers 1

main_cliFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected