Research and application of HTCC board dislocation detection algorithm based on improved LSD
In order to solve the problems that HTCC board used in camera module breaks away from the fixed slot,and the subse-quent parts are poorly installed,a dislocation detection algorithm of HTCC board based on improved LSD was proposed.Firstly,gamma transform was used to eliminate the shadow on the product image.Then,bilateral filtering was applied to the image.Com-pared with LSD algorithm,bilateral filtering can keep more complete edge information.Then,a scaling algorithm based on bilinear interpolation and improved mapping relation was proposed to eliminate quantization artifacts and reduce image distortion.Then,a disconnection and reconnection algorithm was proposed to solve the problem of over-segmentation of line segments in LSD algo-rithm.Finally,based on the improved LSD algorithm,the dislocation detection algorithm of HTCC board was designed,and the number and position of dislocation HTCC board in the product were obtained.The factory verification shows that the average de-tection time of this method is less than 800 ms,and the detection accuracy is over 97%.Compared with the traditional LSD algo-rithm,the detection time is reduced by at least 38%,and the accuracy is improved by at least 21%.This method can meet the re-al-time and accuracy of production.