基于百度AI實(shí)現(xiàn) 車牌識(shí)別

AI系列網(wǎng)址:AI 系列 總目錄


我的博客地址:http://www.cnblogs.com/linbin524/p/8036158.html

前言

目前百度的AI接口相對(duì)完善,對(duì)于文字識(shí)別類的操作還需要開發(fā)者一一去嘗試,去評(píng)估這效果到底是怎么的。

文字識(shí)別的接口相對(duì)簡單,官方提供的SDK也集成很好,筆者只是在這上面做了一些前期性的功能數(shù)據(jù)校驗(yàn)和過濾,以及返回結(jié)果的處理。

實(shí)驗(yàn)效果

先來看一下識(shí)別效果:

1、精細(xì)化車牌(識(shí)別準(zhǔn)確)

2、實(shí)際場(chǎng)景車牌 (識(shí)別準(zhǔn)確)

3、多車牌(只識(shí)別到一個(gè)車牌)

實(shí)際拓展思路

鑒于上述結(jié)果,目前百度車牌識(shí)別可以做到 實(shí)際應(yīng)用場(chǎng)景的處理,但要真正結(jié)合、融合,需要開發(fā)者們自己做些前期處理,比如說,你需要在攝像頭捕捉車牌時(shí)候,自己去動(dòng)態(tài)抓取行駛車牌的車牌,

在使用單個(gè)請(qǐng)求將車牌發(fā)送給百度,從而實(shí)現(xiàn)在真實(shí)環(huán)境中的車牌識(shí)別。

ps:有關(guān)相關(guān)的技術(shù) 可以參考我另外一篇博客,動(dòng)態(tài)視頻中的人臉捕捉與人臉識(shí)別。 博客地址:http://www.cnblogs.com/linbin524/p/linbin524.html

///

/// 車牌識(shí)別 返回實(shí)體結(jié)果

///

///

///

public static APIBaseModel GetPlateLicense(Image tempImage)

{

APIBaseModel tempModel = new APIBaseModel();

tempModel.contextModel = new DrivingLicenseModel();

var client = new Ocr.Ocr(Config.clientId, Config.clientSecret);

var image = ImageHelper.ImageToBytes(tempImage, System.Drawing.Imaging.ImageFormat.Png);

string result = client.PlateLicense(image).ToString();

if (result.Contains("\"error_code\""))//說明異常

{

tempModel.state = false;

tempModel.contextModel.errorTypeModel = Json.ToObject(result);

tempModel.errorMsg = tempModel.contextModel.errorTypeModel.error_discription = OCR_CharacterRecognitionErrorType.GetErrorCodeToDescription(tempModel.contextModel.errorTypeModel.error_code);

}

else

{

tempModel.state = true;

tempModel.contextModel.successModel = Json.ToObject(result);

}

return tempModel;

}

源碼地址:https://github.com/linbin524/AI_Project

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

  • Spring Cloud為開發(fā)人員提供了快速構(gòu)建分布式系統(tǒng)中一些常見模式的工具(例如配置管理,服務(wù)發(fā)現(xiàn),斷路器,智...
    卡卡羅2017閱讀 136,533評(píng)論 19 139
  • Android 自定義View的各種姿勢(shì)1 Activity的顯示之ViewRootImpl詳解 Activity...
    passiontim閱讀 178,872評(píng)論 25 709
  • 來贏家也好幾個(gè)月了,明天自己也在念用心用心,只是自己在嘴上念,還是按照以前的固有模式,今天下午去地推,找回訪找了好...
    沒有未來的胖子閱讀 176評(píng)論 0 0
  • 之前偶然看到一個(gè)關(guān)于旅游的微信公眾號(hào),羅列了一些被我們說的快爛的旅游目的地,云南麗江大理,廈門鼓浪嶼,四川九寨溝等...
    貳鷲閱讀 454評(píng)論 2 1
  • 想關(guān)注我,請(qǐng)戳右邊:http://www.angelen.me我的處女作:http://www.angelen.m...
    angelen閱讀 10,424評(píng)論 51 282

友情鏈接更多精彩內(nèi)容