1 Star 2 Fork 2

xiaodelea/CodeRecognition

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
huahuaniu1109.hdev 3.54 KB
一键复制 编辑 原始数据 按行查看 历史
朱为 提交于 2018-11-09 20:15 . add huahuaniu;affine trans images
<?xml version="1.0" encoding="UTF-8"?>
<hdevelop file_version="1.0" halcon_version="10.0" cs="393775701">
<procedure name="main">
<interface/>
<body>
<l>read_image (Image, 'D:/实习/图片/1109/0.bmp')</l>
<l>emphasize (Image, ImageEmphasize, 7, 7, 1)</l>
<l>threshold (ImageEmphasize, Region, 0, 20)</l>
<l>closing_circle (Region, RegionClosing, 7.5)</l>
<l>closing_rectangle1 (RegionClosing, RegionClosing1, 30, 20)</l>
<l>connection (RegionClosing1, ConnectedRegions)</l>
<l>select_shape (ConnectedRegions, SelectedRegions, 'area', 'and', 8000, 12500)</l>
<l>intersection (Region, SelectedRegions, RegionIntersection)</l>
<l>smallest_rectangle2 (RegionIntersection, Row1, Column1, Phi, Length1, Length2)</l>
<l>hom_mat2d_identity (HomMat2DIdentity)</l>
<l>hom_mat2d_rotate (HomMat2DIdentity, -Phi, 0, 0, HomMat2DRotate)</l>
<l>affine_trans_region (RegionIntersection, RegionAffineTrans, HomMat2DRotate, 'false')</l>
<l>affine_trans_image (Image, ImageAffinTrans, HomMat2DRotate, 'bilinear', 'false')</l>
<l>area_center (RegionAffineTrans, Area, Row, Column)</l>
<l>connection (RegionAffineTrans, ConnectedRegions1)</l>
<l>select_shape (ConnectedRegions1, SelectedRegions1, 'row', 'and', Row-30, Row)</l>
<l>union1 (SelectedRegions1, RegionUnion)</l>
<l>hom_mat2d_rotate (HomMat2DIdentity, -0.1, 0, 0, HomMat2DRotate1)</l>
<l>affine_trans_region (RegionUnion, RegionAffineTrans1, HomMat2DRotate1, 'false')</l>
<l>dilation_circle (RegionAffineTrans1, RegionDilation1, 1.5)</l>
<l>dilation_rectangle1 (RegionDilation1, RegionDilation, 3, 3)</l>
<l>connection (RegionDilation, ConnectedRegions2)</l>
<l>shape_trans (ConnectedRegions2, RegionTrans, 'convex')</l>
<l>partition_dynamic (RegionTrans, Partitioned, 30, 20)</l>
<l>select_shape (Partitioned, SelectedRegions2, 'height', 'and', 22, 32)</l>
<l>intersection (SelectedRegions2, RegionAffineTrans1, RegionIntersection1)</l>
<l>hom_mat2d_rotate (HomMat2DIdentity, 0.1, 0, 0, HomMat2DRotate2)</l>
<l>affine_trans_region (RegionIntersection1, RegionAffineTrans2, HomMat2DRotate2, 'false')</l>
<l>sort_region (RegionAffineTrans2, SortedRegions1, 'first_point', 'true', 'column')</l>
<l>count_obj (SortedRegions1, Number1)</l>
<c></c>
<l>select_shape (ConnectedRegions1, SelectedRegions2, 'row', 'and', Row, Row+30)</l>
<l>union1 (SelectedRegions2, RegionUnion2)</l>
<l>hom_mat2d_rotate (HomMat2DIdentity, -0.1, 0, 0, HomMat2DRotate3)</l>
<l>affine_trans_region (RegionUnion2, RegionAffineTrans3, HomMat2DRotate3, 'false')</l>
<l>dilation_circle (RegionAffineTrans3, RegionDilation3, 1.5)</l>
<l>dilation_rectangle1 (RegionDilation3, RegionDilation4, 3, 3)</l>
<l>connection (RegionDilation4, ConnectedRegions3)</l>
<l>shape_trans (ConnectedRegions3, RegionTrans2, 'convex')</l>
<l>partition_dynamic (RegionTrans2, Partitioned2, 30, 20)</l>
<l>select_shape (Partitioned2, SelectedRegions3, 'height', 'and', 22, 32)</l>
<l>intersection (SelectedRegions3, RegionAffineTrans3, RegionIntersection2)</l>
<l>hom_mat2d_rotate (HomMat2DIdentity, 0.1, 0, 0, HomMat2DRotate4)</l>
<l>affine_trans_region (RegionIntersection2, RegionAffineTrans4, HomMat2DRotate4, 'false')</l>
<l>sort_region (RegionAffineTrans4, SortedRegions2, 'first_point', 'true', 'column')</l>
<l>count_obj (SortedRegions2, Number2)</l>
<c></c>
<l>read_ocr_class_mlp ('C:/Program Files/MVTec/HALCON-10.0/ocr/Industrial_0-9A-Z.omc', OCRHandle)</l>
<l>do_ocr_multi_class_mlp (SortedRegions1, ImageAffinTrans, OCRHandle, Class, Confidence)</l>
<l>do_ocr_multi_class_mlp (SortedRegions2, ImageAffinTrans, OCRHandle, Class1, Confidence1)</l>
<c></c>
</body>
<docu id="main">
<parameters/>
</docu>
</procedure>
</hdevelop>
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/xiaodelea/CodeRecognition.git
git@gitee.com:xiaodelea/CodeRecognition.git
xiaodelea
CodeRecognition
CodeRecognition
master

搜索帮助