How prbonn/kiss-icp works
Main Components
• Core Processing Modules (C++):
• Core registration: Includes modules for preprocessing, registration, thresholding, voxel management (VoxelHashMap, VoxelUtils).
• Pipeline: The “pipeline” directory under cpp/kiss_icp encapsulates the high-level orchestration logic (e.g., KissICP.cpp and KissICP.hpp) that chains the core components.
• Metrics: Modules used to evaluate performance and quality of the registration (Metrics.cpp, Metrics.hpp).
• Python Layer:
• Python Package: Contains an equivalent implementation or binding for the C++ algorithms (in python/kiss_icp) – including configuration, various datasets (handling different LiDAR data formats such as KITTI, Apollo, etc.), and tools (e.g., visualization, progress bar).
• Pybind Module: The “pybind” subdirectory specifies the interface that binds the C++ code to Python.
• ROS Integration:
• ROS Package: Provides additional wrappers and launchers (launch files, ROS node source in ros/src) to integrate the reception of sensor data (OdometryServer.cpp) and visualization (rviz configuration).
• Configuration & Evaluation:
• Config: Contains YAML files and advanced/basic parameter configurations.
• Eval: Contains Jupyter notebooks and scripts to test and evaluate the performance of the registration pipeline on certain datasets.
• External Dependencies:
• Third-party libraries (located inside “cpp/kiss_icp/3rdparty”) such as Eigen for linear algebra, Sophus for Lie groups, TBB for parallel processing, and tsl_robin for hash table implementations.
Relationships and Data Flow
• Input Sources:
• LiDAR data (raw point clouds) and possibly dataset files coming from various sensors/repositories (handled by the Python datasets).
• Core Flow:
• The data flows into the preprocessing modules where initial cleaning and adjustment happens.
• The preprocessed data is passed to the registration module where the point-to-point ICP algorithm is executed.
• Intermediate results (such as voxel representations) are managed by the voxel modules.
• The pipeline component coordinates these operations and applies thresholding and metric evaluation.
• External Interfacing:
• Python bindings wrap the C++ core, exposing functionalities via a CLI (e.g., kiss_icp_pipeline) and potentially visualizing or saving results.
• ROS wrappers encapsulate the core functionalities for real-time applications in robotics, with launch files coordinating node startup and rviz configuration for visualization.
• Feedback Loop:
• Metrics are computed post-registration to validate and potentially iterate over the processing steps.
Architectural Patterns and Design Principles
• Separation of Concerns:
• The system is clearly modularized into core computational logic, dataset handling, bindings, and ROS integration.
• Abstraction via Bindings:
• The use of Pybind abstracts the underlying C++ code, allowing the system to be used seamlessly from Python.
• Reusability:
• The segregation into modules (core, pipeline, metrics) shows an emphasis on reusable components across different interfaces (command line, ROS, notebooks).
• Dependency Management:
• Third-party libraries and configuration files are separated to ensure clear paths for updates and management.
• Main Areas to Include:
• C++ Core Modules: “Core”, “Pipeline”, “Metrics” (with pointers to underlying libraries such as Eigen and Sophus).
• Python Package: “Configuration”, “Datasets”, “Tools”, and “Pybind”.
• ROS Integration: “ROS Node (OdometryServer)”, “Launch Files”, “RViz Config”.
• Evaluation/Testing: “Eval Scripts and Notebooks”.
• Configuration: “YAML Config Files” and “CMake Files” for specifying builds.
• Relationships and Data Flow:
• That Python and ROS layers interface with the core modules (via Pybind for Python, and via direct C++ integration for ROS).