Commit a603b304 authored by Gaetano Raffaele's avatar Gaetano Raffaele

ENH: Made classification step parallel (using Nproc)

parent 6814b207
......@@ -672,7 +672,7 @@ def main(argv):
for cshp in shp_list:
map_out = final_fld + '/MAPS/VECTOR_' + cfield + '/' + os.path.basename(cshp).replace('.shp','_' + cfield + '.shp')
map_out_tmp = final_fld + '/MAPS/VECTOR_' + cfield + '/' + os.path.basename(cshp).replace('.shp','_' + cfield + '_tmp.shp')
classify([cshp],'p'+cfield,stat_file,model_file,map_out_tmp,var_list)
classify([cshp],'p'+cfield,stat_file,model_file,map_out_tmp,var_list,Nproc=N_proc)
keepFields(map_out_tmp,map_out,['Segment_ID','p'+cfield])
shpd.DeleteDataSource(map_out_tmp)
map_list.append(map_out)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment