Install the required packages using pip:
pip install -r requirements.txt
If you install all dependencies with development packages
pip install -r requirements.dev.txt
Alternatively, if you use Poetry:
poetry install
To run this program, you should check config.py
. This file allows you to modify several parameters, such as the input file name and output file name. To use your own LAS file, place it in the data/input
directory and update the configuration accordingly.
Note
The program performs pre-processing tasks, including thinning the LAS file and removing outliers. The first execution might take more time. Pre-processed files are saved under the data/input
directory, which speeds up subsequent runs.
Note
Due to the high time complexity of the ground filtering algorithm and interpolation, processing a 500m by 500m extent can take a considerable amount of time. For testing purposes, it is recommended to use a smaller extent, such as 100m by 100m. This can be adjusted in config.py
.
make main
make step3
make step4
make step5
preprocess.py
: Contains functions for pre-processing, such as thinning, outlier removal, and data clipping with a bounding box.gftin.py
: Processes ground filtering tests. It returns points that pass the ground test and, in debug mode, writes a GeoJSON file exporting the TIN.tin.py
: Creates a TIN (Triangulated Irregular Network) with ground points. This class interfaces with TIN creation and rasterization for any given extent.benchmark.py
: Provides benchmarks for the program. It allows modification of three key parameters in the ground filtering test and outputs statistical results.ptio.py
: Manages input and output operations.geojson.py
: Exports points as a GeoJSON file with specified coordinate transformations, mainly for debugging purposes.pipeline.py
: Utilizes PDAL pipeline to run DBSCAN. This class and its functions let you modify parameters such aseps
andmin_points
for DBSCAN.vegetation.py
: Extracts tree points from unclassified points. Implementation details are in the report.step3.py
: Main file for step 3.step4.py
: Main file for step 4.step5.py
: Main file for step 5.