缺陷分割是液晶显示器(LCD)缺陷检测算法中的重要一步。为了检测背景不均匀LCD的缺陷,设计了一种基于离散余弦变换(DCT)和最大类间方差法(Otsu)的分割算法。首先通过DCT变换获取背景信息;然后利用DCT反变换重构出背景图像;最后通过求取原图和背景图像的差值图像,排除不均匀背景干扰,增强缺陷对比度,并利用Otsu分割算法分割出差值图像中的缺陷。实验结果表明,该算法能够检测常见的液晶屏缺陷,效果良好。
Defect segmentation is an important step in the liquid crystal display (LCD) defect detection algorithm. To detect the defect of uneven background LCD, a segmentation algorithm based on discrete cosine transform (DCT) and maximum variance between classes (Otsu) is designed. Firstly, the DCT transformation is used to obtain background information. Then, the background image is reconstructed by inverse DCT transform. Lastly, uneven background interference is excluded and the defect contrast is enhanced by obtaining the difference image between the original image and the background image. The Otsu segmentation algorithm is used to segment the defects in the difference image. The experimental results show that the algorithm can detect the defects of the LCD screen.