Export classifed point cloud

etta-drone
Dan Howe 6 years ago
parent d2c8adc0ee
commit 78109f0e2d

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

Loading…
Cancel
Save