TIRT Vision Self-Driving Car Contest
A homemade lane-detection algorithm I built for a vision-based self-driving car contest, taking on the challenge of not using an off-the-shelf AI camera.

Background
In the summer of 2022, I saw the poster for that year’s TIRT competition, and the vision-based self-driving car event caught my eye the most. Computer vision was a field I’d never touched, so I figured it was the perfect excuse to dive in and step out of my comfort zone a bit. I immediately recruited a couple of classmates who love building things, and our three-person team started working on our little self-driving car.
Design Approach for the Vision System
To get the car to follow a track made of two white lane lines, most people just buy an off-the-shelf AI camera module and get line-following working the easy way. But we still had three months, and I didn’t want to go with something that had zero technical depth, so I set off on building our own lane-detection system from scratch.
Since I had no experience with machine learning at all, I decided to challenge myself to build the lane detection without any ML. Below is a detailed walkthrough of how my vision system works.
How It Works and Results


Reflections
If you’re wondering why there isn’t more here: even though we started preparing three months ahead, our teamwork didn’t go well. I ended up focusing entirely on the vision system and trusted our car-body teammate a little too much. A few days before the competition, my vision code was almost done and just needed parameter tuning, but the car body and the hardware circuits still weren’t assembled.
So the night before the competition, I had to take on everything myself: writing the Arduino motor-control code, adjusting the car body, and so on. Then, unfortunately, at 2 a.m. on competition day, our Raspberry Pi died without warning and wouldn’t boot. After 30 minutes of trying to fix it, there was nothing we could do, so I had to break the bad news in our group chat that we’d have to withdraw.
This experience taught me how important time management is, and gave me some really valuable lessons in leading a team as captain. I hope to do better in future competitions.
That said, building the vision system taught me a lot about image processing. To filter out noise, I eroded the pixels and then dilated them again. I thought I was using some cursed hack, but later I saw people doing the exact same thing on GitHub, and suddenly I felt like I was thinking on the same level as the pros lol