2020path_simrdwn_core = os .path .dirname (os .path .realpath (__file__ ))
2121sys .path .append (path_simrdwn_core )
2222import simrdwn
23- reload (simrdwn )
2423###################
2524
2625
27- ###############################################################################
26+ ###############################################################################
2827def main ():
2928
3029 parser = argparse .ArgumentParser ()
@@ -33,41 +32,32 @@ def main():
3332 args = parser .parse_args ()
3433
3534 # inferred values
36- args .tf_model_output_directory = os .path .join (args .results_dir ,
35+ args .tf_model_output_directory = os .path .join (args .results_dir ,
3736 'frozen_model' )
3837 args .tf_cfg_train_file_out = os .path .join (args .results_dir ,
39- 'pipeline.config' )
40- print ("args:" , args )
41-
38+ 'pipeline.config' )
39+ print ("args:" , args )
40+
4241 # define command
4342 cmd_export_tf = simrdwn .tf_export_model_cmd (args .results_dir , )
44- # cmd_export_tf = simrdwn.tf_export_model_cmd(args.tf_cfg_train_file_out,
45- # args.results_dir,
43+ # cmd_export_tf = simrdwn.tf_export_model_cmd(args.tf_cfg_train_file_out,
44+ # args.results_dir,
4645# args.tf_model_output_directory)
4746
48-
4947 # Execute
50- print ("Running" , cmd_export_tf , "...\n \n " )
48+ print ("Running" , cmd_export_tf , "...\n \n " )
5149 t0 = time .time ()
5250 os .system (cmd_export_tf )
5351 t1 = time .time ()
5452 cmd_time_str = '"Length of time to run command: ' \
55- + cmd_export_tf + ' ' \
56- + str (t1 - t0 ) + ' seconds\n "'
57- print (cmd_time_str )
58- print ("output_dir:" , args .tf_model_output_directory )
53+ + cmd_export_tf + ' ' \
54+ + str (t1 - t0 ) + ' seconds\n "'
55+ print (cmd_time_str )
56+ print ("output_dir:" , args .tf_model_output_directory )
5957
6058 return
6159
60+
6261###############################################################################
6362if __name__ == "__main__" :
6463 main ()
65-
66- '''
67-
68-
69- python /raid/local/src/simrdwn/core/export_model.py \
70- --results_dir /raid/local/src/simrdwn/results/train_faster_rcnn_resnet101_3class_v5_2018_02_22_16-40-52/
71-
72-
73- '''
0 commit comments