Sort values in enumerated domain for print. Fix typo in print in DEMtoFullShoreline...

parent 1fe10d38
......@@ -423,7 +423,7 @@ def report_fc_values(df, field_defs, xmlfile, fill=-99999):
elif field_defs[fld]['type'] == 'enumerated':
# for val in ptscol.unique():
# eavals += enum_xml.format(val, field_defs['enum_domain'][val], field_defs['producer'])
print('{:.<20} {:}'.format(fld, ' | '.join(str(x) for x in ptscol.unique())))
print('{:.<20} {:}'.format(fld, ' | '.join(str(x) for x in sorted(ptscol.unique()))))
eainfo += '<attr>xxx{}xxx</attr>'.format(fld)
# Unique domain fields
elif field_defs[fld]['type'] == 'unique':
......
......@@ -712,9 +712,9 @@ def DEMtoFullShorelinePoly(elevGrid, MTL, MHW, inletLines, ShorelinePts, SA_boun
bndMTL = 'bndpoly_mtl' + suffix
bndMHW = 'bndpoly_mhw' + suffix
bndpoly = 'bndpoly' + suffix
print("Creating the MTL contour polgon from the DEM...")
print("Creating the MTL contour polygon from the DEM...")
RasterToLandPerimeter(elevGrid, bndMTL, MTL, agg_dist='10', min_area='300', min_hole_sz='300') # Polygon of MTL contour
print("Creating the MHW contour polgon from the DEM...")
print("Creating the MHW contour polygon from the DEM...")
RasterToLandPerimeter(elevGrid, bndMHW, MHW, agg_dist='10', min_area='300', min_hole_sz='300') # Polygon of MHW contour
print("Combining the two polygons...")
bndpoly = CombineShorelinePolygons(bndMTL, bndMHW, inletLines, ShorelinePts, bndpoly, SA_bounds)
......@@ -1370,7 +1370,7 @@ def JoinDFtoFC_2(df, in_fc, join_id, target_id=False, out_fc='', overwrite=True,
arcpy.Delete_management(out_tbl) # delete if already exists
arcpy.da.NumPyArrayToTable(arr, out_tbl)
# Wait 5 seconds. We've been having problems with the next step that may have been caused by not pausing here.
# Wait 5 seconds. We've been having problems with the next step that may have been caused by not pausing here.
time.sleep(5)
# Join table from DF to the copy of the extended transects.
......
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