Skip to main content

A Python package for 3D LiDAR point cloud processing, analysis, terrain modelling, and visualization.

Project description

LidarLens

LidarLens is a powerful Python package for processing, analyzing, and visualizing 3D LiDAR point cloud data. It provides a clean, pythonic API for common tasks such as I/O, noise removal, ground extraction, DTM/DSM generation, and terrain analysis.

Features

  • I/O: Read and write LAS/LAZ files (wraps laspy and open3d).
  • Preprocessing: Voxel downsampling, statistical/radius outlier removal.
  • Segmentation:
    • Ground extraction using CSF (Cloth Simulation Filter) or RANSAC.
    • Building and vegetation segmentation (heuristic).
    • DBSCAN clustering.
  • Terrain Modelling:
    • Generate DTM (Digital Terrain Model) and DSM (Digital Surface Model).
    • Compute Canopy Height Models (CHM).
    • Generate vector contours.
  • Analysis:
    • Point density maps, roughness, slope, aspect, and hillshade.
    • Cloud-to-cloud distance comparison.
    • Volume computation and cross-section profiling.
  • Geometry:
    • Normal estimation and orientation.
    • Mesh surface reconstruction (Poisson, Ball Pivoting).
    • ICP Registration.
  • Visualization: Helper functions for plotting point clouds, DEMs, and histograms.
  • CLI: Comprehensive command-line interface for batch processing.

Installation

pip install lidarlens

To install with CLI support:

pip install lidarlens[cli]

To install with Deep Learning support (coming soon):

pip install lidarlens[dl]

Quick Start

Python API

import lidarlens as ll

# 1. Load a point cloud
pcd, header, vlrs, wkt = ll.read("input.laz")

# 2. Preprocess
pcd = ll.denoise(pcd, method="statistical")
pcd = ll.downsample(pcd, voxel_size=0.5)

# 3. Extract Ground
ground, non_ground, plane = ll.extract_ground(pcd)

# 4. Generate DTM
dtm, meta = ll.generate_dtm(ground, resolution=1.0)

# 5. Save results
ll.save(ground, "ground.laz", header=header, wkt=wkt)
ll.dem_to_png(dtm, meta, "dtm.png")

Command Line Interface

# Info
lidarlens info input.laz

# Processing pipeline
lidarlens downsample input.laz -v 0.5 -o downsampled.laz
lidarlens denoise downsampled.laz -o clean.laz
lidarlens ground clean.laz -o ground.laz

# Terrain products
lidarlens dtm ground.laz -o dtm.png
lidarlens contours ground.laz -i 2.0 -o contours.geojson

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lidarlens-0.1.2.tar.gz (36.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lidarlens-0.1.2-py3-none-any.whl (32.1 kB view details)

Uploaded Python 3

File details

Details for the file lidarlens-0.1.2.tar.gz.

File metadata

  • Download URL: lidarlens-0.1.2.tar.gz
  • Upload date:
  • Size: 36.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lidarlens-0.1.2.tar.gz
Algorithm Hash digest
SHA256 45c092c44340e895f9acb9696da4674f950c2936e8875b19e33796a5c4126100
MD5 abf4d74c3fd5cd5e62a6a16edb404937
BLAKE2b-256 8a2317f91ce03a8c6123ed19fa0f8ebf035981ec6452842757572bc03acd43ee

See more details on using hashes here.

File details

Details for the file lidarlens-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: lidarlens-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 32.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lidarlens-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d2898aefdd5f02b0ea1cc3f72850705fed177b0cd916705f2e042f5c9e6a9272
MD5 af24e888c5439a8c6171bf10d28bb738
BLAKE2b-256 756d3378f373ddf709d1a0e6105223f9eb7a42eab3c986399defd1f6ed32a261

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page