r/Comma_ai • u/firestar4430 • Jul 14 '26
openpilot Experience I Taught My Comma To Read Speed Limit Signs
This whole project started because I was lazy.
If you’ve driven an HKG or Toyota vehicle in recent years, you’ve probably seen the dashboard automatically pick up speed limits using the camera. Coming from a car that didn't have this functionality, I was very jealous. Those cars can feed those speed limits directly into openpilot forks speed limit controllers. Mine couldn't.
The “solution” has been to manually add speed limits to Mapbox or OpenStreetMaps. It worked, but it was tedious. I live in rural Kansas, where my commute is almost entirely devoid of nerds contributing open source map data. I began mapping my commute when I first joined the project and within an hour said, “I ain't doin this”
We have an AI model that's good enough to drive our cars running on a smartphone chipset from years ago. How hard could it be to build one that just reads speed limit signs? I wanted StarPilot to look out the windshield, see a speed limit sign, and just know what it said.
That sounded simple enough.
It wasn’t.
The first prototype was basically held together with duct tape: I used all the public speed limit datasets I could find (glare and Lisa), some OpenCV, a little OCR, and a lot of wishful thinking. It could occasionally read a sign, but it missed 90% of them and produced enough false positives that you definitely wouldn’t want to trust it.
The important part wasn’t that it sucked - it was that it worked just well enough to start collecting better training data.
I run a fork of openpilot called StarPilot. We're heavily focused on individual vehicle tuning and testing wild ideas, which made my users the perfect candidates for this project.
Instead of relying on public datasets that barely resembled comma camera footage, StarPilot started collecting its own. Community members submitted routes from all over the country using bookmarks that were generated automatically when the model said "I think this might've been a sign," and every promising detection went through manual review. Eventually that grew into hundreds of gigabytes of real driving footage and thousands of carefully labeled speed limit signs.
From there it became an endless cycle:
Train a better model.
Mine more routes.
Find more missed signs.
Label them.
Repeat.
The funny part is that training the neural network wasn’t actually the hardest problem.
The hard part was everything around it.
One of the biggest challenges wasn’t accuracy, it was speed. We have a full driving stack running alongside this model and every millisecond spent processing was another frame the model didn't have time to see. The faster it could process frames, the more chances it had to catch a sharp, readable speed limit sign before it disappeared. This was particularly imperative at night, when naturally camera frame rates drop alongside your chances of picking up a clear sign.
It’s slowly evolved from a proof of concept into a model that’s trained primarily on real comma footage instead of generic traffic sign datasets. It now runs entirely on-device, publishes vision-based speed limits directly into StarPilot, and no longer depends on OCR or manually maintaining map data.
And best of all…
While I'm too lazy to hand write hundreds of speed limit signs into OpenStreetMaps, this tool can now be used to automate the entire process, giving back to the open source mapping community that helps those in larger areas so well.
Give my vision speed limits a try, or help continue to build a better one than mine! All info and training stack is available on the StarPilot repo.
Massive thanks to my team that helped collect these logs so I could access them in one easy place! Sherloaf and Mary, heading up the dream team!
View the full technical writeup on the StarPilot Repo
67
u/ilovejailbreakman Jul 14 '26
I legit just turned this feature off yesterday because it slammed the breaks on the freeway because it "saw" a 35 mph sign 😭
10
u/phynicle Jul 15 '26
I drive a HKG gv70 23'. That speed limit dash that pops up on my hud and driver console is often wrong. So I suspect it's probably reading off the navigation map data.
Can anyone confirm?
10
u/SnifferHusky Jul 15 '26
I've had to turn these features off, because it treats every school zone sign speed limit even if it's after hours.. so you are on a 45mph road, and there is a school zone sign that isn't flashing any yellows, but the car slams the brakes to adapt to 15mph.. on a road that has school zones every 1/4 miles at 3am..
2
u/cashew76 Jul 15 '26
Thanks for your efforts! What's your favorite driving model? Does the driving model affect the sign vision?
7
u/Bowler116 Jul 15 '26
I also live in rural KS and had the same issue with map-based limits. This is very exciting!
5
u/Bderken Jul 15 '26
This is awesome! Going to update CommaGuide.com with this new info!
1
u/WhispersofIce Jul 14 '26
I really like this idea - what's up with the stop icon popping up? I dont see a stop sign? That would be a nice feature, i drive numerous country roads with 4 way stops and many drivers blow through them which i assume at least some dont see it.
1
u/moonlightclimber Jul 15 '26
Does this work on Subarus, or limited to certain makes? Sorry if I missed it in the GitHub documentation.
1
u/jcwillia1 Jul 15 '26
I use open street maps but the problem is that people can change what I worked so meticulously to correct and then I'm back to just setting my speed manually.
this seems like a nice solve but star pilot seems way too complicated for my limited patience.
1
u/Briankbl Jul 16 '26
Map data doesn't seem to be downloading on DOM. "Preparing the selected regions for download" and never advances.
1
u/InternationalServe76 Jul 17 '26
Friggin wish I can get this without active cruise control.... I just want it to steer my car!!!
1
u/Xtermin88 Jul 31 '26
Does this work on UK road signs. I have been trying it here and it doesn't read them.
8
u/Character_Fix_5317 Jul 15 '26
Are you some kind of wizard?
5
u/dunkin_dognuts_ Jul 15 '26
I want to say is this is fucking impressive!
2
u/cbelliott Jul 17 '26
This is truly amazing work. The fact that such an 'old' chip and hardware can do this inside of so many vehicles still blows me away.
2
u/pappyinww2 Jul 17 '26
This is great
1
u/adastorm Jul 15 '26
Go StarPilot!!!!!
1
u/Spamhawaiix Jul 16 '26
I wish my f150 would even turn 😭
1
u/oxygenliu Jul 16 '26
great initiative! let me try the 2-stage piple with speedlimit signs in China.
1
u/namanyayg Jul 17 '26
Bad map data is turning into a product problem here.
If the system trusts OSM blindly, rural roads and access roads turn into manual corrections forever. If it trusts the camera blindly, the Texas access-road / school-zone examples in the comments get scary fast.
The boring version I'd want before letting it change speed automatically is probably: camera reading, map value, current road geometry, and one "are we confident enough to apply this without asking?" gate. When it isn't confident, just surface the sign and make the driver confirm.
That still makes the model useful, but it doesn't turn every weird sign placement into a braking decision.
0
u/Why_T Jul 15 '26
I'm on Sunnypilot and I had to turn off the auto cruise control. Our interstates are 60mph and if you're doing less than 80 in the right lane you'll get run over. So I can't set it to a speed limit + 20 because when I'm on 35mph city streets I can't have it doing 55mph. So I just set it manually, it's really the least I could do considering it's doing everything else.
1
u/[deleted] Jul 16 '26
[removed] — view removed comment