现代制造工程 ›› 2019, Vol. 460 ›› Issue (1): 126-131.doi: 10.16731/j.cnki.1671-3133.2019.01.024

• 仪器仪表/检测、监控 • 上一篇    下一篇

基于改进HOG特征的瓶口缺陷检测算法

赵妍1, 朱泽民1, 董蓉2, 李勃1   

  1. 1 南京大学电子科学与工程学院,南京 210046;
    2 南通大学电子信息学院,南通 226000
  • 收稿日期:2017-09-06 出版日期:2019-01-20 发布日期:2019-02-15
  • 作者简介:赵妍,硕士,主要研究方向为图像处理、计算机视觉。朱泽民,硕士,主要研究方向为计算机视觉、深度学习。董蓉,讲师,主要研究方向为计算机视觉、模式识别。李勃,副教授,主要研究方向为工业视觉检测、深度学习。E-mail:943132306@qq.com
  • 基金资助:
    国家自然科学基金项目(61401239);国家自然科学基金联合基金重点支持项目(U1613217);江苏省产学研项目(BY2016075-01)

Inspection algorithm of bottle defects based on improved HOG characteristics

Zhao Yan1, Zhu Zemin1, Dong Rong2, Li Bo1   

  1. 1 School of Electronic Science and Engineering,Nanjing University,Nanjing 210046,China;
    2 School of Electronic Information,Nantong University,Nantong 226000,Jiangsu,China
  • Received:2017-09-06 Online:2019-01-20 Published:2019-02-15

摘要: 传统瓶口缺陷检测算法通过边缘检测和滤波等操作区分和定位缺陷,该算法受瓶口光照影响较大,瓶口粗糙毛刺区域和缺陷部分在图像中均表现为亮色,难以区分,且传统检测算法对检测阈值设置精度要求极高,因此结合瓶口图像灰度值的分布一致性和缺陷的亮度突变性特征,提出基于四线性插值梯度方向直方图(Histogram of Oriented Gradients,HOG)特征的瓶口缺陷检测算法。由于缺陷与背景具有较大的灰度对比度,通过HOG可以对瓶口圆环区域中的所有灰度值突变像素点进行统计,在统计过程中,根据梯度方向对梯度幅值进行竖直方向上的增强和水平方向上的抑制,得到适用于瓶口缺陷场景的特征向量。结合支持向量机(Support Vector Machine,SVM)二类别判决器,实现瓶口的缺陷检测。实验结果表明,检测耗时为170 ms,相较于传统检测方法具有更高的准确率。

关键词: 缺陷检测, 梯度方向直方图, 线性插值, 特征向量, 支持向量机

Abstract: The traditional bottle defect inspection algorithm distinguishes and locates defects through edge detection and filtering,greatly affected by bottle illumination,and the rough burr area and defect part of the mouth are bright and difficult to distinguish in the image.As a result,the traditional algorithm requires extremely high precision for detecting thresholds.Therefore,a defect inspection algorithm is proposed based on the Histogram of Oriented Gradients (HOG) feature which has four-linear interpolation.This algorithm combines with the uniformity of the image gray value and the brightness mutation characteristic of the defect.Because of the large gray scale contrast between the defect and the background,the gradient direction histogram can be used to calculate the pixel gray value mutations of the bottle ring.During the statistical process,the gradient amplitude is amplified vertically and suppressed horizontally according to the gradient direction,forming a feature vector suitable for the inspection of bottle defects.The bottle defect detection method is combined with the Support Vector Machine (SVM) for two categories judgment.The experimental results show that the algorithm proposed has a higher accuracy compared with the traditional detection method.

Key words: defects detection, histogram of oriented gradients, linear interpolation, feature vector, support vector machine

中图分类号: 


版权所有 © 《现代制造工程》编辑部 
地址:北京市东城区东四块玉南街28号 邮编:100061 电话:010-67126028 电子信箱:2645173083@qq.com
本系统由北京玛格泰克科技发展有限公司设计开发 技术支持:support@magtech.com.cn
访问总数:,当日访问:,当前在线: