Refactor pipeline en modules + logging verbose/debug + options CLI
- Découpage du monolithe process_lidar.py (~2750 lignes) en package lidar_pipeline/ avec 9 modules (gpu, dtm, visualizations, ign, rendering, pipeline, cli, __init__, __main__) - Logging configurable: -v (verbose avec timestamps) et --debug (détails internes fichier:ligne) - Option --force pour régénérer tous les fichiers (par défaut skip les WebP existants) - Option --file NOM pour traiter un seul fichier LAZ (tests rapides) - ProcessPoolExecutor avec répertoires temporaires uniques par worker - Suppression du code mort (geomorphons, hillshade_ne, nodata_mask) - Aucun fichier TIFF résiduel après conversion WebP - setup.py pour installation pip, stub process_lidar.py compatible Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
21
lidar_pipeline/__init__.py
Normal file
21
lidar_pipeline/__init__.py
Normal file
@ -0,0 +1,21 @@
|
||||
"""LiDAR Archaeological Pipeline — detection of archaeological structures from LiDAR data.
|
||||
|
||||
Usage:
|
||||
python -m lidar_pipeline /path/to/input -o /path/to/output -r 0.5 -v
|
||||
"""
|
||||
|
||||
# Lazy imports to avoid importing heavy dependencies at package import time
|
||||
|
||||
|
||||
def __getattr__(name):
|
||||
"""Lazy-load heavy submodules only when accessed."""
|
||||
if name == 'LidarArchaeoPipeline':
|
||||
from .pipeline import LidarArchaeoPipeline
|
||||
return LidarArchaeoPipeline
|
||||
if name == 'VIZ_STEPS':
|
||||
from .pipeline import VIZ_STEPS
|
||||
return VIZ_STEPS
|
||||
if name == 'main':
|
||||
from .cli import main
|
||||
return main
|
||||
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|
||||
Reference in New Issue
Block a user