File tree 1 file changed +0
-27
lines changed
1 file changed +0
-27
lines changed Original file line number Diff line number Diff line change @@ -73,37 +73,10 @@ def parse_args():
73
73
return args
74
74
75
75
76
- def copy_prev_models (prev_models_dir , model_dir ):
77
- import shutil
78
-
79
- vc_folder = '/hdfs/' \
80
- + '/' + os .environ ['PHILLY_VC' ]
81
- source = prev_models_dir
82
- # If path is set as "sys/jobs/application_1533861538020_2366/models" prefix with the location of vc folder
83
- source = vc_folder + '/' + source if not source .startswith (vc_folder ) \
84
- else source
85
- destination = model_dir
86
-
87
- if os .path .exists (source ) and os .path .exists (destination ):
88
- for file in os .listdir (source ):
89
- source_file = os .path .join (source , file )
90
- destination_file = os .path .join (destination , file )
91
- if not os .path .exists (destination_file ):
92
- print ("=> copying {0} to {1}" .format (
93
- source_file , destination_file ))
94
- shutil .copytree (source_file , destination_file )
95
- else :
96
- print ('=> {} or {} does not exist' .format (source , destination ))
97
-
98
-
99
76
def main ():
100
77
args = parse_args ()
101
78
update_config (cfg , args )
102
79
103
- if args .prevModelDir and args .modelDir :
104
- # copy pre models for philly
105
- copy_prev_models (args .prevModelDir , args .modelDir )
106
-
107
80
logger , final_output_dir , tb_log_dir = create_logger (
108
81
cfg , args .cfg , 'train' )
109
82
You can’t perform that action at this time.
0 commit comments