- Ajout classification automatique du sol (SMRF/PMF/CSF) avec détection
heuristique (ratio retours uniques > 0.6 → PMF urbain, sinon SMRF)
- Pré-traitement PDAL recommandé avant classification: ELM + outlier
removal (cell=5.0, threshold=2.0 adapté au calcaire rocailleux)
- Options CLI: --ground-classification {auto,smrf,pmf,csf} et
--force-classification pour forcer la reclassification
- Fix double logging (logger.propagate = False)
- Fix --force non transmis dans run.sh (réécriture parsing arguments)
- Fix warning numpy 'partition will ignore mask': conversion MaskedArray
en ndarray avant np.percentile()
- Ajout liblaszip8 + lazrs pour support LAZ dans Docker et laspy
- Tests unitaires pour PMF, CSF et auto-détection
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
60 lines
1.4 KiB
Docker
60 lines
1.4 KiB
Docker
FROM nvidia/cuda:12.4.0-devel-ubuntu22.04
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
ENV TZ=Europe/Paris
|
|
|
|
# Install PDAL and system packages
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
pdal \
|
|
liblaszip8 \
|
|
gdal-bin \
|
|
python3-gdal \
|
|
python3-pip \
|
|
python3-dev \
|
|
build-essential \
|
|
wget \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /app
|
|
|
|
# Install Python packages via pip
|
|
COPY requirements.txt .
|
|
RUN pip3 install --no-cache-dir \
|
|
numpy \
|
|
matplotlib \
|
|
whitebox \
|
|
rasterio \
|
|
'laspy[lazrs]' \
|
|
lazrs \
|
|
scikit-image \
|
|
scikit-learn \
|
|
scipy \
|
|
tqdm \
|
|
Pillow \
|
|
pytest
|
|
|
|
# Install CuPy for GPU acceleration (optional - will fallback to numpy if not available)
|
|
RUN pip3 install --no-cache-dir cupy-cuda12x || echo "CuPy not available - GPU acceleration disabled"
|
|
|
|
# Copy and install the pipeline package
|
|
COPY setup.py .
|
|
COPY lidar_pipeline/ ./lidar_pipeline/
|
|
RUN pip3 install --no-cache-dir .
|
|
|
|
# Copy backward-compatible entry point
|
|
COPY process_lidar.py /usr/local/bin/
|
|
RUN chmod +x /usr/local/bin/process_lidar.py
|
|
|
|
# Create user with uid/gid 1000:1000 and run as that user
|
|
RUN groupadd -g 1000 lidar && \
|
|
useradd -u 1000 -g lidar -m lidar && \
|
|
mkdir -p /data/output /data/input && \
|
|
chown -R lidar:lidar /data /data/output /data/input
|
|
|
|
WORKDIR /data
|
|
|
|
USER lidar
|
|
|
|
VOLUME ["/data"]
|
|
|
|
CMD ["python3", "-m", "lidar_pipeline", "/data/input", "-o", "/data/output"] |