femic.lidar_canopy

Native-resolution CHM, canopy structure, and VRI uncertainty helpers.

P79.7 derives a canopy height model from aligned DSM/DEM rasters, summarizes canopy height and cover, and compares CHM evidence with VRI inventory fields. It does not reproject, resample, segment individual trees, or claim field-level inventory accuracy.

Functions

build_canopy_products(dsm_path, dem_path, ...)

Build CHM/canopy products, optional VRI comparison, and QA reports.

compare_canopy_to_vri(chm_path, vri_path, *)

Compare polygon-level CHM p95/cover with VRI height/cover fields.

derive_canopy_height_model(dsm_path, ...[, ...])

Derive CHM = DSM - DEM on exactly aligned native grids.

derive_canopy_structure(chm_path, *[, ...])

Summarize canopy height and cover from a CHM raster.

write_canopy_qa_report(report, path)

Write the canopy QA report as pretty-printed JSON.

write_canopy_qa_summary_csv(report, path)

Write a one-row-per-product canopy QA summary CSV.

write_vri_comparison_csv(comparison, path)

Write polygon-level VRI comparison rows as CSV.

Classes

CanopyHeightResult(path, dsm_path, dem_path, ...)

Derived CHM raster and its QA summary.

CanopyProcessingError

Raised when canopy inputs, grids, or VRI comparisons are invalid.

CanopyQaReport(generated_utc, dsm, dem, chm, ...)

QA report for one CHM/canopy build.

CanopyStructureResult(path, metadata, ...[, ...])

Canopy height and cover summary for one CHM raster.

VriComparison(vri_path, height_field, ...[, ...])

Summary uncertainty comparison between CHM and VRI polygons.

VriComparisonRow(polygon_id, vri_height_m, ...)

One polygon-level CHM versus VRI comparison.