Skip to main content

Robotics Lab

A field robot mapping an apple orchard, live in your browser. It explores on its own, builds a 2D occupancy grid and a 3D point cloud with scan-matching SLAM, localizes with a particle filter and maps every fruit it can see in 3D. Take over whenever you like.

Nothing here is pre-recorded and there is no server: the world, the sensors and every algorithm are written from scratch in TypeScript and run in this tab, rendered with three.js.

What’s running

Localization

Monte Carlo Localization with 800 particles against a surveyed prior map, using a likelihood-field laser model, low variance resampling and random particle injection. Tree rows look identical to a laser, so a ±1.5 m GNSS fix is fused in to break the symmetry. Kidnap the robot to watch it recover.

Occupancy grid mapping

A 10 cm log-odds grid updated with an inverse sensor model: Bresenham ray tracing marks free space along each of the 360 laser beams, endpoints become obstacles. Each occupied cell also keeps the mean of its hits for sub-cell accuracy.

SLAM

Scan-to-map SLAM: drifting wheel odometry predicts the motion, ICP against the map built so far corrects it, and the corrected scan is fused into the map. Compare the red odometry track with the green SLAM track and the white ground truth.

Point clouds & ICP

A simulated 16-channel LiDAR ray casts trunks, porous canopies, fruit and the ground. Scans are registered with the SLAM pose into a voxel-filtered global cloud with semantic labels. The 2D ICP is point-to-point with a shrinking gate, Huber weights and a closed-form solve.

Autonomous exploration

Frontier-based exploration: frontiers between known free space and unknown space are clustered, scored by travel cost and size, and reached with Dijkstra/A* on an inflated costmap and a pure pursuit controller, with stuck detection and recovery.

3D fruit mapping

Two side-looking RGB-D cameras detect fruit that faces them and isn’t hidden by leaves, with noise growing with depth. Detections are put in the map frame with the SLAM pose and associated in a spatial hash; a fruit counts once it’s been seen three times. Precision and recall are measured against the ground truth.