|
|
|
@ -365,6 +365,7 @@ def main():
|
|
|
|
|
check_value = row['CHECK VALUE']
|
|
|
|
|
direct = row['DIRECTION']
|
|
|
|
|
check_distance = row['CHECK DISTANCE']
|
|
|
|
|
las_dir = row['LAS CLASSIFIED FOLDER']
|
|
|
|
|
shp_dir = row['SHP SWASH FOLDER']
|
|
|
|
|
tmp_dir = row['TMP FOLDER']
|
|
|
|
|
|
|
|
|
@ -381,13 +382,18 @@ def main():
|
|
|
|
|
las_data = call_lastools('lasground_new', input=las_data, output='-stdout',
|
|
|
|
|
args=['-step', lasground_step], verbose=False)
|
|
|
|
|
|
|
|
|
|
# Save classified point cloud
|
|
|
|
|
las_name = os.path.join(las_dir, las_basename + '.las')
|
|
|
|
|
with open (las_name, 'wb') as f:
|
|
|
|
|
f.write(las_data)
|
|
|
|
|
|
|
|
|
|
# Interpolate point cloud onto a grid
|
|
|
|
|
print('Interpolating to grid...')
|
|
|
|
|
xyz_name = os.path.join(tmp_dir, las_basename + '.xyz')
|
|
|
|
|
call_lastools('las2dem', input=las_data, output=xyz_name,
|
|
|
|
|
args=['-step', 1], verbose=False)
|
|
|
|
|
|
|
|
|
|
# Make runup clipping mask
|
|
|
|
|
# Make runup clipping mask from gridded point cloud
|
|
|
|
|
print('Calculating runup clipping mask...')
|
|
|
|
|
shp_name = os.path.join(shp_dir, las_basename + '.shp')
|
|
|
|
|
polygon_wave_runup(xyz_name, direct, shp_name, check_value, check_distance, zone_MGA)
|
|
|
|
|