FixTheRobot Explore Robotics / Localization & SLAM / M5 / M5-L3

This lab works on phones, but writing code is much easier on a laptop.

Localization & SLAM · LiDAR SLAM · M5-L3 · Intermediate

Understand the LOAM Pipeline

A colleague asks why LOAM works on a laptop when registering every point would not. The answer is two decisions: use very few, well-chosen points, and do the expensive part rarely.

You implement both: the smoothness test that chooses the points, then the publisher that combines 10 Hz odometry with a late, accurate 1 Hz mapping result.

Your task

    Simulation
    solution.pyLoading Python…
    Ctrl+Enter runs
    What Python can I use?

    Plain Python with math and, for matrices, slamkit (matmul, transpose, solve, inverse, identity). The data arrive as the dictionary D. There is no NumPy, random, json or copy in the browser runtime. Your code runs locally and never leaves this page.

    Hints

    What this lab teaches

    Stage 1 is the curvature measure of M5-T3 with its practical guard against occlusion edges, graded against the true corners of a hidden room. Stage 2 is the architecture of M5-T5: a transform between the odometry and map frames that is refreshed by each mapping result, graded against the true trajectory.

    Why it matters

    The same split reappears everywhere: LIO-SAM’s IMU odometry and keyframe optimisation, Cartographer’s local and global SLAM, and ROS’s map → odom → base_link transforms.

    Theory for this lab

    LiDAR SLAM labs

    1. M5-L1: Fix Point-Cloud Preprocessing
    2. M5-L2: Diagnose Poor Scan Registration
    3. M5-L3: Understand the LOAM Pipeline: this lab.
    4. M5-L4: Diagnose LiDAR SLAM Drift
    5. M5-L5: Investigate a Failed LiDAR Mapping Run

    Educational simplification: 2D scans with a fixed neighbour count and fixed thresholds; synthetic mapping results (true pose plus noise) instead of a real scan-to-map registration; constant latency. LOAM does the selection per ring and sector in 3D and runs the mapping as a real optimisation.

    Get the next lab

    Get notified when new robotics labs are released. One email per new lab, nothing else.