当前位置:网站首页>Shape template matching based on Halcon learning [vi] find_ mirror_ dies. Hdev routine
Shape template matching based on Halcon learning [vi] find_ mirror_ dies. Hdev routine
2022-07-05 07:55:00 【BoomBiuBiu】
* Many molds are usually etched on the wafer . Before the single track, the mold can be picked up by the mold bonding machine and placed on the lead frame , They have to be cut from the wafer . The mirror mold is used to determine the parameters of the cutting process .
* ad locum , The position of the mirror mold is based on shape matching .
1、 Read the picture
dev_update_off ()
* close window
dev_close_window ()
* Read the picture
read_image (Image, 'wafer/wafer_mirror_dies_01')
* Open the adaptive picture window
dev_open_window_fit_image (Image, 0, 0, -1, -1, WindowHandle)
* Set display font
set_display_font (WindowHandle, 16, 'mono', 'true', 'false')
* Set the width of the line
dev_set_line_width (3)
* display picture
dev_display (Image)
disp_message (WindowHandle, 'Determine the position of mirror dies on the wafer', 'window', 12, 12, 'black', 'true')
disp_continue_message (WindowHandle, 'black', 'true')
stop ()
2、 Create a template
* Cutout
gen_rectangle1 (Rectangle, 362, 212, 414, 262)
reduce_domain (Image, Rectangle, ImageReduced)
* Create a template
create_shape_model (ImageReduced, 'auto', rad(0), rad(1), 'auto', 'auto', 'use_polarity', 'auto', 'auto', ModelID)
* Get the outline
get_shape_model_contours (ModelContours, ModelID, 1)

3、 Start matching
* Read the picture and deal with it
* To begin for loop
for Index := 1 to 4 by 1
read_image (Image, 'wafer/wafer_mirror_dies_' + Index$'02')
* Determine the position of the rearview mirror mold , And calculate the running time required to find the location
count_seconds (S1)
* Begin to match
find_shape_model (Image, ModelID, rad(0), rad(1), 0.5, 0, 0.0, 'least_squares', 2, 0.5, Row, Column, Angle, Score)
count_seconds (S2)
Runtime := (S2 - S1) * 1000
* Show results
gen_cross_contour_xld (Cross, Row, Column, 6, rad(45))
dev_display (Image)
dev_display_shape_matching_results (ModelID, 'lime green', Row, Column, Angle, 1, 1, 0)
dev_set_color ('orange')
dev_display (Cross)
disp_message (WindowHandle, |Score| + ' mirror dies located in ' + Runtime$'.1f' + ' ms', 'window', 12, 12, 'black', 'true')
if (Index != 4)
disp_continue_message (WindowHandle, 'black', 'true')
stop ()
endif
endfor

notes : Here is a special operator , Make the results more visible
* Generate a cross shape for each input point XLD outline .
gen_cross_contour_xld (Cross, Row, Column, 6, rad(45))

边栏推荐
- RF ride side door processing of prompt box
- 如何进行导电滑环选型
- Day01 markdown log entry tips
- Extern keyword function
- MySQL - storage engine
- Detailed explanation of pragma usage
- 如何将EasyCVR平台RTSP接入的设备数据迁移到EasyNVR中?
- Reasons for rapid wear of conductive slip rings
- .NET服务治理之限流中间件-FireflySoft.RateLimit
- How to select conductive slip ring
猜你喜欢

Network communication model -- Network OSI tcp/ip layering

Beijing Winter Olympics opening ceremony display equipment record 3

Altium designer 19.1.18 - hide the fly line of a network

Screen record of the opening ceremony of the Beijing winter olympics 2

Practical application cases of digital Twins - fans

The printer encountered an abnormal configuration problem 0x8007007e (win10)

Interview catalogue

Makefile application

如何进行导电滑环选型

Shell脚本基本语法
随机推荐
High end electronic chips help upgrade traditional oil particle monitoring
Altium designer learning (I)
Improve lighting C program
Embedded composition and route
Process communication mode between different hosts -- socket
Altium designer 19.1.18 - clear information generated by measuring distance
Create inf module in AMI code
Acwing - the collection of pet elves - (multidimensional 01 Backpack + positive and reverse order + two forms of DP for the answer)
Gradle composite construction
Numpy——1.數組的創建
1089 Insert or Merge 含测试点5
Consul installation
Basic embedded concepts
About yolov3, conduct map test directly
Calibre garbled
PIL's image tool image reduction and splicing.
Can't find real-time chat software? Recommend to you what e-commerce enterprises are using!
Query the table name used by kettle in Oracle
Day07 type of mathematical operator automatic conversion relational operator bitwise operator blind date math
UEFI development learning series