Weekend YOLOv8-LPRNet Plate Recognizer Tops CCPD but Fails on Real Photos
A developer built a runnable license-plate recognition pipeline in two days using YOLOv8n for detection, LPRNet with CTC decoding for text recognition, and HSV heuristics for plate color. The author reported 99% performance on CCPD, but real mobile-phone images exposed failures involving out-of-province plates, angled or distant shots, double-layer plates, screenshots, scans, and poor lighting. The article provides runnable code and recommends broader data, stronger augmentation, grouped evaluation, and a learned color classifier for production use.
The account illustrates how strong benchmark results can mask dataset bias and deployment failures in real vehicle-photo workflows.
前言
事情是这样的。
公司做车险业务,录单的时候要从车辆照片里提取车牌号。我们一直用的是蓝兴AI的车牌号识别接口,传张图过去,几百毫秒就返回车牌号、颜色和单双层,用着挺省心。
但作为一个有好奇心的程序员,我总觉得:"不就是个车牌识别吗?YOLO 一把梭,能有多难?"
于是某个周末,我决定自己从零撸一个。
剧透一下结局:模型跑通了,指标很好看,然后在真实照片上被教做人了。 😅
#YOLOv8n#LPRNet#CCPD#ONNX Runtime#FastAPI#OpenCV#Blue Xing AI