Duckiebot Intersection Navigation with DBSCAN
Project Resources
- Objective: Enable Duckiebots to navigate intersections safely, smoothly and efficiently.
- Approach: Using the DBSCAN (A Density-Based Algorithm for Discovering Clusters in Large Spatial Databases with Noise) algorithm to detect stoplines and guide Duckiebots along precomputed optimal trajectories.
- Authors: Christian Leopoldseder, Matthias Wieland, Sebastian Seb Giles, Merlin Hosner, Amaury Camus.
Why intersection navigation using DBSCAN?
Navigating intersections is obviously important when driving in Duckietown. It is not as obvious that the mechanics of intersection navigation for autonomous vehicles are very different from those used for standard lane following. There typically is a finite state machine that transitions the agent behavior from one set of algorithms, appropriate for driving down the road, and a different set of algorithms, to actually solve the “intersections” problem.
The intersection problem in Duckietown has several steps:
- Identifying the beginning of the intersection (identified with a horizontal red line on the road floor)
- Stopping at the red line, before engaging the intersection
- Identifying what kind of intersection it is (3-way or 4-way, according to the Duckietown appearance specifications at the time of writing)
- Identifying the relative position of the Duckiebot at the intersection, hence the available routes forward
- Choosing a route
- Identifying when it is appropriate to engage the intersection to avoid potentially colliding with other Duckiebots (e.g., is there a centralized coordinator – a traffic light – or not?)
- Engaging and navigating the intersection toward the chosen feasible route
- Switching the state back to lane following.
Easier said than done, right?
For each of the points above different approaches could be used. This project focuses on improving the baseline solutions for points 2., and most importantly, 7. of the above.
The real challenge is the actual driving across the intersection (in a safe way, i.e., by “keeping your lane”), because the features that provide robust feedback control in the lane following pipeline are not present inside intersections. The baseline solution for this problem in Duckietown is open loop control, relying on the model of the Duckiebots and the Duckietown to magic-tune a few parameters and the curves just about right.
As all students of autonomy know, open-loop control is ideally perfect (when all models are known exactly), but it is practically pretty useless on its own, as “all models are wrong” [learn why, e.g., in the Modeling of a Differential Drive robot class].
In this project, the authors seek to close the loop around intersection navigation, and chose to use an algorithm called “DBSCAN” (Density-Based Algorithm for Discovering Clusters in Large Spatial Databases with Noise) to do it.
DBSCAN (Density-Based Spatial Clustering of Applications with Noise – wiki) is a clustering algorithm that groups data points based on density, identifying clusters of varying shapes and filtering out noise. It is used to find the red stop lines at intersections without needing predefined geometric priors (colors, shapes, or fixed positions). This allows to track meaningful visual features in intersections efficiently, localize with respect to them, and hence attempt to navigate along optimal precomputed trajectories depending on the chosen direction.
Intersection navigation using DBSCAN: the challenges
Some of the challenges in this intersection navigation project are:
Initial position uncertainty: Duckiebot’s starting alignment at the stop line may vary, requiring the system to handle inconsistent initial conditions.
Real-time feedback: the current system lacks real-time feedback, relying on pre-configured instructions that cannot adjust for unexpected events, such as slippage of the wheels, inconsistencies between different Duckiebots, and misalignment of road tiles (non-compliant assembly).
Processing speed: previous closed-loop solution attempts used April tags and Kalman filters – with implementations that ended up being too slow: with low update rates and delays.
Transition to lane following: ensuring a smooth handover from intersection navigation to lane following requires precise control to avoid collisions and lane invasion.
Project Highlights
Here is a visual tour of the output of the authors’ work. Check out the GitHub repository for more details!
Intersection Navigation using DBSCAN: Results
Intersection Navigation using DBSCAN: Authors
Christian Leopoldseder is a former Duckietown student of class Autonomous Mobility on Demand at ETH Zurich, and currently works as a Software Engineer at Google, Switzerland.
Matthias Wieland is a former Duckietown student of class Autonomous Mobility on Demand at ETH Zurich, and currently works as a Senior Consultant at abaQon, Switzerland.
Sebastian Nicolas Giles is a former Duckietown student of class Autonomous Mobility on Demand at ETH Zurich, and currently works as a Autonomous Driving Systems Engineer at embotech, Switzerland.
Merlin Hosner is a former Duckietown student of class Autonomous Mobility on Demand at ETH Zurich, and currently works as a Process Development Engineer at Climeworks, Switzerland. Merlin was a mentor on this project.
Amaury Camus is a former Duckietown student of class Autonomous Mobility on Demand at ETH Zurich, and currently works as a Lead Robotics Engineer at Hydromea, Switzerland. Amaury was a mentor on this project.
Learn more
Duckietown is a modular, customizable and state-of-the-art platform for creating and disseminating robotics and AI learning experiences.
It is designed to teach, learn, and do research: from exploring the fundamentals of computer science and automation to pushing the boundaries of knowledge.