FixTheRobot Explore Robotics / Perception / P8 / P8-L4

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

Perception · Sensor Fusion and Scene Understanding · P8-L4 · Advanced

Fuse Simulated Observations with Uncertainty

The camera knows exactly which way the pallet is and has no idea how far it is. The lidar knows exactly how far and is a little vague about the direction. Together they know both, if the robot trusts each one where it is good.

You will weigh them by direction, write the fusion of two Gaussians, and refuse to fuse readings that cannot be about the same object.

Your task

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

    Plain Python with math (and slamkit for small matrix helpers: matmul, transpose, solve, inverse, identity). Images, point clouds and detections arrive as lists inside the dictionary D; an image is a list of rows, each row a list of pixels. There is no NumPy or OpenCV: you write the algorithm yourself, which is the point of the lab. Print with print().

    Hints

    What this lab teaches

    Stage 1 explores per-direction weights. Stage 2 writes the information-form fusion with 2 × 2 covariances. Stage 3 adds a chi-square consistency test that rejects conflicting observations. All observations are simulated with stated covariances. Your code is graded on hidden data; the true positions are kept by the grader.

    Theory for this lab

    Sensor Fusion and Scene Understanding labs

    1. P8-L1: Combine Camera Detections with Depth Information
    2. P8-L2: Compare Camera-Only and Depth-Assisted Distance Estimates
    3. P8-L3: Diagnose Incorrect Coordinate Transforms
    4. P8-L4: Fuse Simulated Observations with Uncertainty: this lab.

    Educational simplification: 2D positions, independent Gaussian errors with exactly known covariances, two sensors and known correspondence apart from the injected conflicts. In practice the covariances are estimated and often wrong, errors are correlated between sensors that share a platform, and association itself fails. Fusion is only valid after calibration, synchronisation and frame alignment (Lab P8-L3). All data in this lab are simulated.

    Get the next lab

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