zoukankan      html  css  js  c++  java
  • Halcon学习之六:获取Image图像中Region区域的特征参数

    area_center_gray ( Regions, Image : : : Area, Row, Column )    计算Image图像中Region区域的面积Area和重心(Row,Column)。

    cooc_feature_image ( Regions, Image : : LdGray, Direction : Energy,Correlation, Homogeneity, Contrast )   计算共生矩阵和推导出灰度特征值

       Direction:灰度共生矩阵计算的方向    Energy:灰度值能量     Correlation:灰度值的相互关系 Homogeneity:灰度值的均匀性 Contrast:灰度值的对比度

    cooc_feature_matrix ( CoocMatrix : : : Energy, Correlation,Homogeneity, Contrast ) 根据共生矩阵计算灰度特征值

    elliptic_axis_gray ( Regions, Image : : : Ra, Rb, Phi ) 计算Image图像的Region区域的Ra,Rb和Phi。

    entropy_gray ( Regions, Image : : : Entropy, Anisotropy ) Image图像中Region区域的计算熵Entropy和各向异性Anisotropy。

    estimate_noise ( Image : : Method, Percent : Sigma ) 从单一图像 Image中估计图像的噪声。

    Sigma:加性噪声的标准偏差 Method :估计噪声的方法 Method∈{foerstner、immerkaer、least_squares、mean}、

    fit_surface_first_order ( Regions, Image : : Algorithm, Iterations, ClippingFactor : Alpha, Beta, Gamma ) 计算一阶灰度平面的灰度矩阵和灰度值的逼近参数。

    Algorithm:采用的算法 Algorithm:迭代次数 ClippingFactor:消除临界值的削波系数

    fit_surface_second_order ( Regions, Image : : Algorithm, Iterations, ClippingFactor : Alpha, Beta, Gamma, Delta, Epsilon, Zeta ) 计算二阶灰度平面的灰度矩阵和灰度值的逼近参数。

    fuzzy_entropy ( Regions, Image : : Apar, Cpar : Entropy ) 确定区域Regions的模糊熵 将图像视为模糊集合 Apar为模糊区域的起始点 Cpar为模糊区域的结束点 Entropy为Regions的模糊熵

    fuzzy_perimeter ( Regions, Image : : Apar, Cpar : Perimeter ) 计算Region区域的模糊周长

    gen_cooc_matrix ( Regions, Image : Matrix : LdGray, Direction : ) 生成Image图像Region区域的共生矩阵

    gray_histo ( Regions, Image : : : AbsoluteHisto, RelativeHisto ) 获取Image图像Region区域的灰度相对直方图RelativeHisto和绝对直方图AbsoluteHisto。 注意:Region区域必须先计算过它的直方图。

    gray_histo_abs ( Regions, Image : : Quantization : AbsoluteHisto ) 获取Image图像Region区域的灰度绝对直方图AbsoluteHisto。 Quantization:灰度值的量化、

    gray_projections ( Region, Image : : Mode : HorProjection, VertProjection ) 计算Region区域在水平方向和垂直方向的灰度值投影。

    histo_2dim ( Regions, ImageCol, ImageRow : Histo2Dim : : ) 计算二通道灰度图像的直方图

    intensity ( Regions, Image : : : Mean, Deviation ) 计算region区域的灰度平均值和偏差

    min_max_gray ( Regions, Image : : Percent : Min, Max, Range ) 计算Region区域的最大最小灰度值。 Range:最大灰度值和最小灰度值之间的差距

    moments_gray_plane ( Regions, Image : : : MRow, MCol, Alpha, Beta,Mean ) 计算平面的灰度矩阵和灰度值的逼近参数。

    plane_deviation ( Regions, Image : : : Deviation ) 逼近的图象平面计算灰度值偏差 

    select_gray ( Regions, Image : SelectedRegions : Features, Operation,Min, Max : )

    根据灰度值选择区域

    Features∈{area、row、column、ra、rb、phi、min、max、mean、deviation、plane_deviation、anisotropy、entropy、fuzzy_entropy、fuzzy_perimeter、moments_row、moments_column、alpha、beta}

    Operation∈{and、or}

    shape_histo_all ( Region, Image : : Feature : AbsoluteHisto, RelativeHisto )

    shape_histo_point ( Region, Image : : Feature, Row,Column : AbsoluteHisto, RelativeHisto )

    获取阈值特征直方图

    Feature∈{connected_components、convexity、compactness、anisometry、holes}

     程序:

    [c-sharp] view plain copy
     
    1. read_image (Image, 'G:/Halcon/机器视觉/images/bin_switch/bin_switch_3.png')  
    2. regiongrowing (Image, Regions, 3, 3, 1, 500)  
    3. area_center_gray (Regions, Image, Area, Row, Column)  
    4. cooc_feature_image (Regions, Image, 6, 0, Energy, Correlation, Homogeneity, Contrast)  
    5. elliptic_axis_gray (Regions, Image, Ra, Rb, Phi)  
    6. entropy_gray (Regions, Image, Entropy, Anisotropy)  
    7. estimate_noise (Image, 'mean', 20, Sigma)  
    8. fit_surface_first_order (Regions, Image, 'regression', 5, 2, Alpha, Beta, Gamma)  
    9. fit_surface_second_order (Regions, Image, 'regression', 5, 2, Alpha1, Beta1, Gamma1, Delta, Epsilon, Zeta)  
    10. fuzzy_entropy (Regions, Image, 0, 255, Entropy1)  
    11. fuzzy_perimeter (Regions, Image, 0, 255, Perimeter)  
    12. gen_cooc_matrix (Regions, Image, Matrix, 6, 0)  
    13. dev_set_paint ('histogram')  
    14. gray_projections (Regions, Image, 'simple', HorProjection, VertProjection)  
    15. histo_2dim (Regions, Image, Image, Histo2Dim)  

     

    运行结果:

     
  • 相关阅读:
    我这里面所用的DBHelper
    同时向主表和从表里面导入execl数据 (asp.net webform)
    在asp.net webform中的 gridview 里面的一些基本操作
    在ASP.NET WEBFORM 中后台实现gridview全选功能
    asp.net webform 发送电子邮件
    Asp.Net中的三种分页方式
    asp.net获取客户端浏览器及主机信息
    在asp.net webfrom 中上传execl (读取单个sheet的数据)
    Linux五种IO模型性能分析
    epoll/poll/select的原理
  • 原文地址:https://www.cnblogs.com/qqhfeng/p/7247800.html
Copyright © 2011-2022 走看看