@@ -21,23 +21,26 @@ def main():
2121 exit ()
2222 parser = argparse .ArgumentParser ()
2323 parser .add_argument ("cfg" , help = "configuration file for testing" )
24- parser .add_argument ("-test_csv" , help = "the csv file for testing images" ,
25- required = False , default = None )
26- parser .add_argument ("-output_dir" , help = "the output dir for inference results" ,
24+ parser .add_argument ("--test_csv" , help = "the csv file for testing images" ,
2725 required = False , default = None )
28- parser .add_argument ("-ckpt_dir " , help = "the dir for trained model " ,
26+ parser .add_argument ("--test_dir " , help = "the dir for testing images " ,
2927 required = False , default = None )
30- parser .add_argument ("-ckpt_mode " , help = "the mode for chekpoint: 0-latest, 1-best, 2-customized " ,
28+ parser .add_argument ("--output_dir " , help = "the output dir for inference results " ,
3129 required = False , default = None )
32- parser .add_argument ("-ckpt_name " , help = "the name chekpoint if ckpt_mode = 2 " ,
30+ parser .add_argument ("--ckpt_dir " , help = "the dir for trained model " ,
3331 required = False , default = None )
34- parser .add_argument ("-gpus" , help = "the gpus for runing, e.g., [0]" ,
32+ parser .add_argument ("--ckpt_mode" , help = "the mode for chekpoint: 0-latest, 1-best, 2-customized" ,
33+ required = False , default = None )
34+ parser .add_argument ("--ckpt_name" , help = "the name chekpoint if ckpt_mode = 2" ,
35+ required = False , default = None )
36+ parser .add_argument ("--gpus" , help = "the gpus for runing, e.g., [0]" ,
3537 required = False , default = None )
3638 args = parser .parse_args ()
3739 if (not os .path .isfile (args .cfg )):
3840 raise ValueError ("The config file does not exist: " + args .cfg )
3941 config = parse_config (args )
4042 config = synchronize_config (config )
43+ print (config )
4144 log_dir = config ['testing' ]['output_dir' ]
4245 if (not os .path .exists (log_dir )):
4346 os .makedirs (log_dir , exist_ok = True )
0 commit comments