# remove all the files in the tiled subfolders except the *segmented.ply and tile_index.dat files
find $data_folder/segmented_point_clouds/tiled/*/ -type f !-name'*segmented.ply'!-name'tile_index.dat'-delete# delete all the files except the segmented.ply files
# delete all the folders in the tiled subfolders
find $data_folder/segmented_point_clouds/tiled/*/*-type d -execrm-rf{} +
# # merge the segmented point clouds
echo"Merging the segmented point clouds"
# iterate over all the directories in the tiled folder
for d in$data_folder/segmented_point_clouds/tiled/*/;do
# print path to the results folder and the subfolders
echo"Results can be found here: $data_folder/results"
echo"Results containing the input point clouds can be found here: $data_folder/results/input_data"
echo"Results containing the segmented point clouds can be found here: $data_folder/results/segmented_point_clouds"
echo"Results containing the instance segmented point clouds can be found here: $data_folder/results/instance_segmented_point_clouds"
echo"Results containing the instance segmented point clouds with ground can be found here: $data_folder/results/instance_segmented_point_clouds_with_ground"