• halcon车牌的识别


     1 read_image (Audi2, 'audi2')
     2 fill_interlace (Audi2, ImageFilled, 'odd')
     3 dev_set_color('green')
     4 threshold (ImageFilled, Region, 0, 90)
     5 connection (Region, ConnectedRegions)
     6 select_shape (ConnectedRegions, SelectedRegions, 'width', 'and', 30, 70)
     7 select_shape (SelectedRegions, Letters, 'height', 'and', 60, 110)
     8 *dev_clear_window ()
     9 *dev_set_colored (12)
    10 *dev_display (ImageFilled)
    11 *dev_display (Letters)
    12  
    13     
    14 read_ocr_class_mlp('Industrial_0-9A-Z.omc',OCRHandle) 
    15 do_ocr_multi_class_mlp(Letters,Audi2,OCRHandle, Class, Confidence)
    16    
    17 *显示识别的结果
    18 area_center(Letters, Area, Row, Column)
    19 for Index := 0 to 6 by 1
    20      disp_message(3600, Class[Index], 'window', Row[Index], Column[Index], 'black', 'true')
    21  endfor

    初始图片:

    处理后的图片,将车牌所在的区域识别出来:

    显示输出结果:

    *Class[0]--class[6]分别为GAPV329

    area_center(Letters, Area, Row, Column)
    for Index := 0 to 6 by 1
         disp_message(3600, Class[Index], 'window', Row[Index], Column[Index], 'black', 'true')
     endfor
  • 相关阅读:
    jvm
    java8新特性Lambada,Steam流
    数组链表栈队列 散列表
    数据结构算法基本知识
    设计模式七大原则
    java关键字
    Excel导出(适合项目开发)
    Excel导出(适合初学者)
    angular.min.js:80 Error:
    angular中出现错误的提示指令[ng:areq]的原因
  • 原文地址:https://www.cnblogs.com/liuzebei/p/5458715.html
Copyright © 2020-2023  润新知