dendromatics

Automatic dendrometry and forest inventory for terrestrial point clouds


Keywords
forestry, lidar, tls, lidar-point-cloud, remote-sensing
License
GPL-3.0
Install
pip install dendromatics==0.5.0a0

Documentation

image

Dendromatics

Documentation Status PyPI status Tests status

Description

The src folder contains functionalities to detect the trees present in a terrestrial 3D point cloud from a forest plot, and compute individual tree parameters: tree height, tree location, diameters along the stem (including DBH), and stem axis. These are based on an updated version of the algorithm proposed by (Cabo et al., 2018).

The functionalities may be divided in four main steps:

  1. Height-normalization of the point cloud.
  2. Identification of stems among user-provided stripe.
  3. Tree individualization based on point-to-stems distances.
  4. Robust computation of stems diameter at different section heights.

Although individual, somewhat independent functions are provided, they are designed to be used in a script that calls one after the other following the algorithm structure. An example script can be found in example folder.

Examples

Height-normalization

Almost all functions in the module expect a height-normalized point cloud to work as intended. If your point cloud is not height-normalized, you can do it in a simple way using some of the module functions. I'ts based on 'Cloth simulation Filter' (Zhang et al., 2016).

If the point cloud is noisy, you might want to denoise it first before generating the DTM.

Identifying stems from a stripe

Simply provide a stripe (from a height-normalized point cloud) as follows to iteratively 'peel off' the stems.

Individualizing trees

Once the stems have been identified in the stripe, they can be used to individualize the trees in the point cloud.

Computing sections along the stems

compute_sections() can be used to compute sections along the stems of the individualized trees.

Tilt detection

tilt_detection() computes an 'outlier probability' for each section based on its tilting relative to neighbour sections and relative to the tree axis.

For further examples and more thorough explanations, please check example.py script in /examples folder.

References

Cabo, C., Ordóñez, C., López-Sánchez, C. A., & Armesto, J. (2018). Automatic dendrometry: Tree detection, tree height and diameter estimation using terrestrial laser scanning. International Journal of Applied Earth Observation and Geoinformation, 69, 164–174. https://doi.org/10.1016/j.jag.2018.01.011

Prendes, C., Cabo, C., Ordoñez, C., Majada, J., & Canga, E. (2021). An algorithm for the automatic parametrization of wood volume equations from Terrestrial Laser Scanning point clouds: application in Pinus pinaster. GIScience and Remote Sensing, 58(7), 1130–1150. https://doi.org/10.1080/15481603.2021.1972712

Zhang, W., Qi, J., Wan, P., Wang, H., Xie, D., Wang, X., & Yan, G. (2016). An easy-to-use airborne LiDAR data filtering method based on cloth simulation. Remote Sensing, 8(6). https://doi.org/10.3390/rs8060501

Install

dendromatics is available on PyPI and the full documentation can be consulted on ReadTheDocs.io

python -m pip install dendromatics

The list of dependencies is available in the pyproject.toml file.

dendromatics relies on hatch

Depending on your version of Python and your OS, you might also need a C/C++ compiler to compile some of the mandatory dependencies (CSF and jakteristics). But in any case you would not have to run the compiler by yourself, the build system will manage dependencies and compilation for you.

python -m pip install hatch

You can run tests to ensure it works on your computer.

hatch run cov

It is also possible to build doc locally.

hatch run docs:build
hatch run docs:serve

and then go to http://localhost:8000 to browse it.