Skip to main content
Log in

Automatic marking point positioning of printed circuit boards based on template matching technique

  • Published:
Journal of Intelligent Manufacturing Aims and scope Submit manuscript

Abstract

The traditional global template matching is time consuming, has low accuracy, and cannot be adapted to rotation and scale change. The template matching technique proposed in this study improves the time, accuracy and robustness for printed circuit boards (PCB). In order to shorten the image positioning time, the image preprocessing is implemented on PCB image and the image blocks are labeled to obtain the tagged image, and the feature vector is extracted and the marking point region image is selected. The feature vector with rotation change and scale change robustness is extracted from the tagged image after labeling in the PCB image by using artificial neural network, combined with image moments for training. The marking point region image in the PCB image is selected. The scale value of the marking point region image is estimated by parametric template vector matching. The deflection angle of marking point region image is calculated by Hough transform. The obtained scale value and deflection angle value are used for fast template matching to determine the marking point positioning. The three-dimensional (3D) parabolic curve fitting is implemented in marking point positioning and adjacent pixel position to reach the sub-pixel level accuracy. The experiment showed that the proposed template matching technique for the PCB image with or without noise or angle rotation, the average position accuracy error of each translated image is lower than 7 \(\upmu \)m, and the error standard deviation is lower than 5 \(\upmu \)m. The rotation angle error average and standard deviation of angular error of Hough transform are lower than 0.2\(^{\circ }\), more accurate than orientation code (OC) method. The scale value estimation, relative error average and error standard deviation are lower than 0.004 and 0.006 for the image with or without noise. The average complete positioning time of PCB image at resolution of \(2500\times 2500\) is only 0.55 s, which is better than the 3.97 s of traditional global template matching. The results prove that the template matching technique of this study not only has sub-pixel level high accuracy and short computing time, but also has the robustness of rotation change and scale change interference. It can implement rapid, efficient and accurate positioning.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7

Similar content being viewed by others

References

  • Adelson, E., Abderson, C., Bergen, J. R., Burt, P. J., & Ogden, J. M. (1984). Pyramid methods in image processing. RCA Engineer, 29(6), 33–41.

    Google Scholar 

  • Burt, P. J. (1981). Fast filter transforms for image processing. Computer Graphics and Image Processing, 16(1), 20–51.

    Article  Google Scholar 

  • Burt, P. J., & Adelson, E. H. (1983). The Laplacian pyramid as a compact image code. IEEE Transactions on Communications, 31(4), 532–540.

    Article  Google Scholar 

  • Chen, C. S., & Huang, C. L. (2016). A novel image alignment algorithm based on rotation-discriminating ring-shifted projection for automatic optical inspection. Applied Sciences, 6(5), 140.

    Article  Google Scholar 

  • Choi, M. S., & Kim, W. Y. (2002). A novel two stage template matching method for rotation and illumination invariance. Pattern Recognition, 35(1), 119–129.

    Article  Google Scholar 

  • Hassaballah, M., & Awad, A. I. (2016). Detection and description of image features: An introduction. In Image feature detectors and descriptors (pp. 1–8). Switzerland: Springer.

  • Kim, H. Y. (2010). Rotation-discriminating template matching based on Fourier coefficients of radial projections with robustness to scaling and partial occlusion. Pattern Recognition, 43(3), 859–872.

    Article  Google Scholar 

  • Kim, H. Y., & Araújo, S. A. (2007). Grayscale template-matching invariant to rotation, scale, translation, brightness and contrast. IEEE Pacific-Rim Symposium on Image and Video Technology, Lecture Notes in Computer Science, 4872(1), 100–113.

    Google Scholar 

  • Lee, W. C., & Chen, C. H. (2012). A fast template matching method with rotation invariance by combining the circular the circular projection transform process and bounded partial correlation. IEEE Signal Processing Letter, 19(11), 737–740.

    Article  Google Scholar 

  • Li, Z. H., Liu, C., Cui, J., & Shen W. F. (2011). Improved rotation invariant template matching method using relative orientation codes. In Proceedings of the 30th Chinese Control Conference, Yanta (pp. 3119–3123).

  • Lin, Y. H., & Chen, C. H. (2008). Template matching using the parametric template vector with translation, rotation and scale invariance. Pattern Recognition, 41(7), 2413–2421.

    Article  Google Scholar 

  • Lewis, J. P. (1995). Fast normalized cross correlation. Vision Interface, 10, 120–123.

    Google Scholar 

  • Lowe, D. G. (1999). Object recognition from local scale-invariant features. International Conference on Computer Vision, Canada, 2(1), 1150–1157.

    Google Scholar 

  • Park, Y. S., & Kim, W. Y. (1996). A fast template matching method using vector summation of sub-image projection. Proceedings KSPC, 96, 565–568.

    Google Scholar 

  • Qiao, N., & Sun, P. (2014). Study of improved Otsu algorithm and its ration evaluation analysis for PCB photoelectric image segmentation. Optik-International Journal for Light and Electron Optics, 125(17), 4784–4787.

    Article  Google Scholar 

  • Szymanski, C., & Stemmer, M. R. (2015). Automated PCB inspection in small series production based on SIFT algorithm. In 2015 IEEE 24th International Symposium on Industrial Electronics (ISIE) (pp. 594–599).

  • Tanaka, K., Sano, M., Ohara, S., & Okudaira, M. (2000). A parametric template method and its application to robust matching. IEEE Conference on Computer Vision and Pattern Recognition, Hilton Head Island, 1, 620–627.

    Google Scholar 

  • Ullah, F., & Kanekoi, S. (2004). Using orientation codes for rotation-invariant template matching. Pattern Recognition, 37(2), 201–209.

    Article  Google Scholar 

  • Wu, X., Yuan, P., Peng, Q., Ngo, C. W., & He, J. Y. (2016). Detection of bird nests in overhead catenary system images for high-speed rail. Pattern Recognition, 51, 242–254.

    Article  Google Scholar 

  • Zanganeh, O., Srinivasan, B., & Bhattacharjee, N. (2014). Partial fingerprint matching through region-based similarity. Digital lmage Computing: Techniques and Applications (DlCTA). In 2014 International Conference, IEEE (pp. 1–8).

  • Zhang, Y., Wang, S., Sun, P., & Phillips, P. (2015). Pathological brain detection based on wavelet entropy and Hu moment invariants. Bio-medical Materials and Engineering, 26(s1), S1283–S1290.

    Article  Google Scholar 

  • Zheng, Z., & Wang, H. (1999). Analysis of gray level corner detection. Pattern Recognition Letters, 20(2), 149–162.

    Article  Google Scholar 

Download references

Acknowledgements

The research was supported by the Ministry of Science and Technology of the Republic of China under Grant No. 104-2221-E-011-156.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Chung-Feng Jeffrey Kuo.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Kuo, CF.J., Tsai, CH., Wang, WR. et al. Automatic marking point positioning of printed circuit boards based on template matching technique. J Intell Manuf 30, 671–685 (2019). https://doi.org/10.1007/s10845-016-1274-2

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10845-016-1274-2

Keywords

Navigation