Skip to content

Commit

Permalink
added error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
jim-schwoebel committed Aug 14, 2020
1 parent 5c95a3c commit fd32c76
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion features/csv_features/featurize_csv_regression.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ def element_featurize(sampletype, default_features, filepaths, directory):

os.mkdir(basedir+'/train_dir/'+folder)
for i in range(len(filepaths)):
shutil.copy(filepaths[i], directory+'/'+filepaths[i].split('/')[-1])
try:
shutil.copy(filepaths[i], directory+'/'+filepaths[i].split('/')[-1])
except:
pass
try:
shutil.copy(filepaths[i][0:-4]+'.json', directory+'/'+filepaths[i].split('/')[-1][0:-4]+'.json')
except:
Expand Down

0 comments on commit fd32c76

Please sign in to comment.