Method and apparatus using image subtraction and dynamic thresholding
First Claim
1. A method for providing dynamic thresholding in an automated inspection system:
- said method comprising the steps of;
capturing with an image acquisition device a first image comprising a plurality of first image pixels and a second image comprising a plurality of second image pixels;
subtracting gray level values of said second image pixels from gray level values of said first image pixels to provide a subtracted image having a plurality of subtracted image pixel values;
processing said subtracted image pixel values with a positive image pixel map to generate a positive difference image consisting of positive difference values from said subtracted image pixels values;
processing said subtracted image pixel values with a negative image pixel map to generate a negative difference image consisting of negative difference values from said subtracted image pixels values;
generating a positive dynamic threshold image as a function of said gray level values of said first image pixels and said gray level values of said second image pixels;
generating a negative dynamic threshold image as a function of said gray level values of said first image pixels and said gray level values of said second image pixels;
subtracting said positive difference image from said positive dynamic threshold image, to implement thresholding and provide a subtracted positive image;
subtracting said negative difference image from said negative dynamic threshold image, to implement thresholding and provide a subtracted negative image;
converting said subtracted positive image and said subtracted negative image to provide, respectively, a positive results image and a negative results image wherein pixels that exceed respective threshold values are set to a first number and pixels that do not exceed respective threshold values are set to a second number;
merging said positive results image and said negative results image to provide a merged image; and
binarizing said merged image to provide a binarized foreground/background detection output wherein all positive values representing features of interest are set to a first binarization number and all zero values are set to a second binarization number.
1 Assignment
0 Petitions
Accused Products
Abstract
A method and apparatus implementing dynamic thresholding techniques in processes that use image subtraction. The subtracted image is separated into a positive difference image using a positive image map and a negative difference image using a negative image map. A positive threshold map and a negative threshold map process a Gaussian filtered first image to generate respective positive and negative dynamic threshold images. The positive and negative threshold map mask out irrelevant areas and implement adaptive gain in pixel thresholds proportional to a difference or contrast between foreground or feature of interest and local background. Dynamic thresholding is a subtraction providing a subtracted positive image and a subtracted negative image. The subtracted positive and subtracted negative images are combined to provide a merged image which is binarized. Edge or Interface detection involves edge detection and true peak detection to find the edge peaks in a pre-image and post image. A binarization map converts edge peak pre and post images and the post image is then dilated to compensate any mis-registration. The dilated post image is subtracted from the binary edge pre-image to form an edge subtraction image. Pixels absent from the post image are assumed to be occluded by a feature of interest. The two binary images are merged, filtered, and connectivity is effected to obtain position and size of contiguous regions of interest.
-
Citations
22 Claims
-
1. A method for providing dynamic thresholding in an automated inspection system:
- said method comprising the steps of;
capturing with an image acquisition device a first image comprising a plurality of first image pixels and a second image comprising a plurality of second image pixels; subtracting gray level values of said second image pixels from gray level values of said first image pixels to provide a subtracted image having a plurality of subtracted image pixel values; processing said subtracted image pixel values with a positive image pixel map to generate a positive difference image consisting of positive difference values from said subtracted image pixels values; processing said subtracted image pixel values with a negative image pixel map to generate a negative difference image consisting of negative difference values from said subtracted image pixels values; generating a positive dynamic threshold image as a function of said gray level values of said first image pixels and said gray level values of said second image pixels; generating a negative dynamic threshold image as a function of said gray level values of said first image pixels and said gray level values of said second image pixels; subtracting said positive difference image from said positive dynamic threshold image, to implement thresholding and provide a subtracted positive image; subtracting said negative difference image from said negative dynamic threshold image, to implement thresholding and provide a subtracted negative image; converting said subtracted positive image and said subtracted negative image to provide, respectively, a positive results image and a negative results image wherein pixels that exceed respective threshold values are set to a first number and pixels that do not exceed respective threshold values are set to a second number; merging said positive results image and said negative results image to provide a merged image; and binarizing said merged image to provide a binarized foreground/background detection output wherein all positive values representing features of interest are set to a first binarization number and all zero values are set to a second binarization number. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14)
- said method comprising the steps of;
-
15. A method for inspecting solder paste deposited on a circuit board having solder pads disposed thereon for receiving solder paste, comprising:
-
capturing a pre-image of said circuit board before solder paste is deposited thereon, said pre-image comprising a plurality of pre-image pixels, said image an image acquisition device capturing a post-image of said circuit board after solder paste is deposited thereon, said post-image comprising a plurality of post-image pixels; filtering said pre-image and said post-image to provide, respectively filtered pre-image pixels and filtered post-image pixels; subtracting gray level values of said filtered post-image pixels from gray level values of said filtered pre-image pixels to provide a subtracted image having a plurality of subtracted image pixel values; processing said subtracted image pixel values with a positive image pixel map to generate a positive difference image consisting of positive difference values from said subtracted image pixels values; processing said subtracted image pixel values with a negative image pixel map to generate a negative difference image consisting of negative difference values from said subtracted image pixels values; filtering said pre-image with an averaging filter to generate average filtered pre-image pixels; generating a positive dynamic threshold image as a function gray level values of said average filtered pre-image pixels and said gray level values of said post-image pixels; generating a negative dynamic threshold image as a function of gray level values of said average filtered pre-image pixels and said gray level values of said post-image pixels; subtracting said positive difference image from said positive dynamic threshold image, to implement thresholding and provide a subtracted positive image; subtracting said negative difference image from said negative dynamic threshold image, to implement thresholding and provide a subtracted negative image; converting said subtracted positive image and said subtracted negative image by passing each of said subtracted positive image and said subtracted negative image through a common conversion map to eliminate negative values to provide, respectively, a positive results image and a negative results image wherein pixels that exceed respective threshold values are set to a first number and pixels that do not exceed respective threshold values are set to a second number; merging said positive results image and said negative results image to provide a merged image; and binarizing said merged image to provide a binarized foreground/background detection output wherein all positive values represent one of solder paste disposed on solder pads and solder paste disposed on said circuit board, said positive values being set to a first binarization number and all zero values being set to a second binarization number. - View Dependent Claims (16, 17, 18, 19, 20, 21, 22)
-
Specification