Disclosed apparatus, systems, and methods relate to placing probes on an image of a pattern for image processing applications.
Digital images are formed by many devices and used for many practical purposes. Devices include cameras with image sensors operating on visible or infrared light, such as a charge-coupled device (CCD) image sensor or a complementary metal-oxide-semiconductor (CMOS) image sensor, line-scan sensors, flying spot scanners, electron microscopes, X-ray devices including computed tomography (CT) scanners, magnetic resonance imagers, and other devices known to those skilled in the art. Practical applications are found in industrial automation, medical diagnosis, satellite imaging for a variety of military, civilian, and scientific purposes, photographic processing, surveillance and traffic monitoring, document processing, and many others.
To serve these applications, the images formed by the various devices are analyzed by machine vision systems to extract appropriate information. One form of analysis that is of considerable practical importance is determining the position, orientation, and size of patterns in an image that correspond to objects in the field of view of the imaging device. Pattern detection methods are of particular importance in industrial automation, where they are used to guide robots and other automation equipment in semiconductor manufacturing, electronics assembly, pharmaceuticals, food processing, consumer goods manufacturing, and many others.
In some cases, pattern detection methods can model patterns using one or more probes. A probe can refer to a position in an image at which the pattern detection methods examine a gradient vector of the image. Therefore, each probe can be associated with a position vector and an orientation vector. Since probes can effectively indicate the position and orientation of a pattern in an image, a machine vision system can use the probes to align the position and orientation of patterns.
Some embodiments include a system for choosing placement of three-dimensional (3D) probes used for evaluating a 3D alignment pose of a runtime 3D image inside a 3D alignment system for estimating the pose of a trained 3D model image in that 3D runtime image. The system includes a processor in communication with a memory, wherein the processor is configured to run a computer program stored in the memory that is configured to: generate a plurality of features associated with a first plurality of points of interest from a 3D image, wherein each feature comprises data indicative of 3D properties of an associated point from the plurality of points of interest; select a second plurality of points of interest from among the first plurality of points of interest, based at least in part on the plurality of features associated with the first plurality of points of interest; and determine placements of a plurality of 3D probes based at least in part on the second plurality of points of interest.
In some embodiments, each of the plurality of features incorporates at least one measure of usefulness of an associated point from among the first plurality of points for alignment in at least one translational degree of freedom. In some embodiments, each of the plurality of features incorporates at least one measure of usefulness of an associated point from among the first plurality of points for alignment in at least one rotational degree of freedom. In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one less represented translational degree of freedom provided by a placement on each of the first plurality of points of interest. In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one less represented translational degree of freedom and in a less represented rotational degree of freedom provided by a placement on each of the first plurality of points of interest. In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one less represented rotational degree of freedom provided by placement on each of the first plurality of points of interest. In some embodiments, the processor is further configured to: determine a center of rotation that minimizes a sum of rotational moments of the plurality of features; and determine a first, second, and third axis of rotation that minimizes the sum of rotational moments of the plurality of features.
In some embodiments, a center of rotation and rotational axes that fit a subset of the first plurality of points are determined such that the center of rotation and rotational axes are associated with rotationally symmetric features of a pattern. In some embodiments, finding the center of rotation and rotational axes from a subset of the first plurality of points comprises using a RANSAC technique. In some embodiments, finding the center of rotation and rotational axes from a subset of the first plurality of points comprises using a Monte Carlo technique. In some embodiments, the plurality of features includes a plurality of surface normal vectors. In some embodiments, the plurality of features includes a plurality of edge proximity vectors. In some embodiments, the plurality of features includes a plurality of edge direction vectors. In some embodiments, the plurality of features includes a plurality of surface curvature vectors.
In some embodiments, selecting a second plurality of points of interest from among the first plurality of points of interest based at least in part on the plurality of features associated with the first plurality of points of interest comprises: fitting a probability distribution to the first plurality of points; determining a target distribution, wherein the target distribution is indicative of a desired placement of the probes on one or more of the interest points; determining placements of probes at least in part by utilizing the relative probabilities of the fitted distribution and target distribution at proposed probe sites. In some embodiments, determining the interest point distribution comprises fitting the plurality of interest points to a probability distribution comprising a mixture model, wherein the probability distribution is indicative of at least a distribution of orientations measured at the plurality of interest points. In some embodiments, the processor is further configured to determine a number of components of the mixture model of the interest point distribution by clustering the plurality of interest points into at least one cluster. In some embodiments, the processor is further configured to: identify one or more horizon points from the first plurality of interest points; and remove from consideration the one or more horizon points such that the second plurality of interest points does not comprise the one or more horizon points. In some embodiments, selecting the second plurality of points of interest comprises using a Monte Carlo technique.
Some embodiments include a method for choosing placement of three-dimensional (3D) probes used for evaluating a 3D alignment pose of a runtime 3D image inside a 3D alignment system for estimating the pose of a trained 3D model image in that 3D runtime image. The method includes: generating a plurality of features associated with a first plurality of points of interest from a 3D image, wherein each feature comprises data indicative of 3D properties of an associated point from the plurality of points of interest; selecting a second plurality of points of interest from among the first plurality of points of interest, based at least in part on the plurality of features associated with the first plurality of points of interest; and determining placements of a plurality of 3D probes based at least in part on the second plurality of points of interest.
In some embodiments, each of the plurality of features incorporates at least one measure of usefulness of an associated point from among the first plurality of points for alignment in at least one translational degree of freedom. In some embodiments, each of the plurality of features incorporates at least one measure of usefulness of an associated point from among the first plurality of points for alignment in at least one rotational degree of freedom. In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one less represented translational degree of freedom provided by a placement on each of the first plurality of points of interest. In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one less represented translational degree of freedom and in a less represented rotational degree of freedom provided by a placement on each of the first plurality of points of interest.
In some embodiments, the placement of the plurality of 3D probes provides an increase in ensemble alignment ability in at least one of the less represented rotational degrees of freedom provided by placement on each of the first plurality of points of interest. In some embodiments, a center of rotation is determined such that the sum of rotational moments of the plurality of features is minimized; and first, second, and third axes of rotation are determined such that the sum of rotational moments of the plurality of features is minimized. In some embodiments, a center of rotation and rotational axes that fit a subset of the first plurality of points are determined such that the center of rotation and rotational axes are associated with rotationally symmetric features of a pattern. In some embodiments, finding the center of rotation and rotational axes from a subset of the first plurality of points comprises using a RANSAC technique. In some embodiments, finding a center of rotation and rotational axes from a subset of the first plurality of points comprises using a Monte Carlo technique In some embodiments, the plurality of features includes a plurality of surface normal vectors. In some embodiments, the plurality of features includes a plurality of edge proximity vectors. In some embodiments, the plurality of features includes a plurality of edge direction vectors. In some embodiments, the plurality of features includes a plurality of surface curvature vectors.
In some embodiments, selecting a second plurality of points of interest from among the first plurality of points of interest based at least in part on the plurality of features associated with the first plurality of points of interest comprises: fitting a probability distribution to the first plurality of points; determining a target distribution, wherein the target distribution is indicative of a desired placement of the probes on one or more of the interest points; determining placements of probes at least in part by utilizing the relative probabilities of the fitted distribution and target distribution at proposed probe sites. In some embodiments, determining the interest point distribution comprises fitting the plurality of interest points to a probability distribution comprising a mixture model, wherein the probability distribution is indicative of at least a distribution of orientations measured at the plurality of interest points. In some embodiments, the method further comprises determining a number of components of the mixture model of the interest point distribution by clustering the plurality of interest points into at least one cluster. In some embodiments, the method further comprises: identifying one or more horizon points from the first plurality of interest points; and removing from consideration the one or more horizon points such that the second plurality of interest points does not comprise the one or more horizon points. In some embodiments, selecting the second plurality of points of interest comprises using a Monte Carlo technique.
Some embodiments include a non-transitory computer readable medium has executable instructions associated with a system for choosing placement of three-dimensional (3D) probes used for evaluating a 3D alignment pose of a runtime 3D image inside a 3D alignment system for estimating the pose of a trained 3D model image in that 3D runtime image. The executable instructions are operable to cause the system to: generate a plurality of features associated with a first plurality of points of interest from a 3D image, wherein each feature comprises data indicative of 3D properties of an associated point from the plurality of points of interest; select a second plurality of points of interest from among the first plurality of points of interest, based at least in part on the plurality of features associated with the first plurality of points of interest; and determine placements of a plurality of 3D probes based at least in part on the second plurality of points of interest.
There has thus been outlined, rather broadly, the features of the disclosed subject matter in order that the detailed description thereof that follows may be better understood, and in order that the present contribution to the art may be better appreciated. There are, of course, additional features of the disclosed subject matter that will be described hereinafter and which will form the subject matter of the claims appended hereto. It is to be understood that the phraseology and terminology employed herein are for the purpose of description and should not be regarded as limiting.
The patent or application file contains at least one drawing executed in color. Copies of this patent or patent application publication with color drawing(s) will be provided by the Office upon request and payment of the necessary fee.
Various objects, features, and advantages of the disclosed subject matter can be more fully appreciated with reference to the following detailed description of the disclosed subject matter when considered in connection with the following drawings, in which like reference numerals identify like elements.
In the following description, numerous specific details are set forth regarding the systems and methods of the disclosed subject matter and the environment in which such systems and methods may operate, etc., in order to provide a thorough understanding of the disclosed subject matter. It will be apparent to one skilled in the art, however, that the disclosed subject matter may be practiced without such specific details, and that certain features, which are well known in the art, are not described in detail in order to avoid complication of the disclosed subject matter. In addition, it will be understood that the examples provided below are exemplary, and that it is contemplated that there are other systems and methods that are within the scope of the disclosed subject matter.
The specification is generally organized in the following manner. The specification begins by describing exemplary embodiments that generally relate to two-dimensional images. Some exemplary two-dimensional techniques are explained, for example, in U.S. patent application Ser. No. 14/603,969, entitled “Probe Placement for Image Processing,” filed on Jan. 23, 2015, the contents of which are hereby incorporated by reference herein in its entirety. The specification then describes exemplary embodiments that generally relate to three-dimensional images. Although the first portion generally relates to exemplary embodiments involving two-dimensional images and the second portion generally relates to exemplary embodiments involving three-dimensional images, the skilled artisan will appreciate that the disclosure in one portion can be applicable to the disclosure in the other portion and vice versa. Additionally, the skilled artisan will appreciate that some exemplary embodiments rely on the teachings of both portions. For example, in some exemplary embodiments, systems and methods use both two-dimensional images and three-dimensional images. Additionally, the skilled artisan will appreciate that teachings from first portion that are also applicable to the 3D case are not necessarily repeated in full in the second section to avoid unnecessary repetition and vice versa. In other words, although the specification is generally divided into the two-dimensional and the three-dimensional case for organizational purposes and for ease of comprehension, this organization is not intended to limit the scope of the disclosure.
The following introduces exemplary explanations of terms, according to one or more embodiments. These explanations are not intended to be limiting.
Object—Any physical or simulated object, or portion thereof, having characteristics that can be measured by an image forming device or simulated by a data processing device.
Image—A 2D image is a two-dimensional function whose values correspond to physical characteristics of an object, such as brightness (radiant energy, reflected or otherwise), color, temperature, height above a reference plane (e.g., range image), etc., and measured by any image-forming device, or whose values correspond to simulated characteristics of an object, and generated by any data processing device. A 3D image can, for example, be represented as a range image or as a point cloud. A point cloud is a collection of 3D points in space where each point i can be represented as (xi, yi, zi).
Boundary—An imaginary contour, open-ended or closed, straight or curved, smooth or sharp, along which a discontinuity of image brightness occurs at a specified granularity, the direction of said discontinuity being normal to the boundary at each point.
Gradient—A vector at a given point in an image giving the direction and magnitude of greatest change in brightness at a specified granularity at said point.
Pattern—A specific geometric arrangement of contours lying in a bounded subset of the plane of the contours, said contours representing the boundaries of an idealized image of an object to be located and/or inspected. A 3D pattern can, for example, be represented as a arrangement of contours in a range image or as a point cloud.
Model—A set of data encoding characteristics of a pattern to be found for use by a pattern finding method.
Training—A process of creating a model from an image of an example object or from a geometric description of an object or a pattern.
A machine vision system can be configured to determine the absence or presence of one or more instances of a predetermined pattern in an image, and determine the location of each found instance. The process of locating patterns in a 2D image occurs within a multidimensional space that can include, but is not limited to, x-y position (also called translation), orientation, and size. For a 3D image, location can, for example, include x-y-z position (also called translation), tilt and rotation (also called roll, pitch, and yaw).
To determine the absence or presence of one or more instances of a predetermined pattern in an image, a machine vision system can represent the pattern to be found using a model. The machine vision system can generate a model for a pattern from one or more training images or one or more synthesized images from a geometric description that contain examples of the pattern to be located and/or inspected. Once the model is available, the machine vision system can compare the model to a test image at each of an appropriate set of poses, compute a match score at each pose, and determine candidate poses that correspond to a local maximum in match score. The machine vision system can consider candidate poses whose match scores are above a suitable threshold to be instances of the pattern in the image.
A model can include a set of data elements called probes. Each probe represent a relative position at which certain measurements and tests are to be made in an image at a given pose, each such test contributing evidence that the pattern exists at the associated pose. A probe can be placed in a manner substantially perpendicular to a structure (e.g., boundary) of the underlying pattern.
During the training stage, existing machine vision systems place the probes on the boundary of a 2D pattern in a uniform manner. For example, a machine vision system places probes on the pattern boundary so that the distance between adjacent probes is roughly identical for all pairs of adjacent probes. This strategy, which is herein referred to as a “uniform placement strategy,” can be effective in modeling patterns with a balanced orientation profile (e.g., a 2D pattern with a boundary that points to a large number of orientations and the proportions of the boundary pointing to various orientations are similar). For example, the uniform placement strategy has been useful in modeling square patterns because the number of probes pointing to different orientations (e.g., up, down, left, and right) is roughly the same on each edge of the pattern in the 2D image, which can lead to accurate information on the location and orientation of the 2D pattern.
Unfortunately, a uniform placement strategy is often ineffective in modeling patterns with an unbalanced orientation profile (e.g., patterns with varying side lengths). For example, the uniform placement strategy is generally not as effective in aligning 2D patterns with an elongated rectangular shape.
There has been an effort to vary the distance between adjacent probes to address issues associated with the uniform placement strategy. However, the effort was limited to manual adjustment of probe locations, which can be labor intensive and expensive.
The techniques described herein provide for an automated probe placement module for placing probes on a pattern (both 2D and 3D patterns). The probe placement module is configured to place probes on interest points of an image so that the probes can accurately represent a pattern depicted in the image. The probe placement module can be configured to place the probes so that the probes can extract balanced information on all degrees of freedom associated with the pattern's movement, which improves the accuracy of the model generated from the probes. For example, when an object associated with the pattern is known to move in two dimensions (e.g., translational motion), the probe placement module can place the probes so that the probes can extract balanced information in the two dimensions (assuming a 2D pattern and image). The probe placement module can also take into account the shape of the pattern so that the probes can extract balanced information regardless of the shape of the pattern. This is in contrast to techniques that extract unbalanced information, such as extracting more vertical information compared to horizontal information when more probes are placed along the long edge compared to the short edge as shown in
In step 202, the probe placement module can be configured to receive information on the location of interest points in a 2D image. For example, the probe placement module can receive, from an interest point detection module, a boundary of a 2D pattern in a 2D image.
In step 204, the probe placement module can determine the distribution of the interest points. For example, the probe placement module can represent each interest point using a feature (e.g., a perpendicular orientation measured at the interest point) and determine a distribution of features associated with the interest points.
In step 206, the probe placement module can determine the target distribution of probes. In some cases, the target distribution of probes can be determined based on features associated with the interest points and/or the distribution of interest points determined in step 204. For example, the probe placement module can determine that the target distribution of probes is the inverse of the distribution of interest points determined in step 204. In step 208, the probe placement module can determine the location of probes so that the actual distribution of probes matches the target distribution of probes.
The general framework illustrated in
For example, in step 204, the probe placement module can determine the histogram of perpendicular orientations measured at the plurality of interest points in a 2D image. In step 206, the probe placement module can determine that the target distribution of perpendicular orientations, as measured at probe locations, is a uniform distribution. In step 208, the probe placement module can place probes at one or more of the interest points so that the histogram of perpendicular orientations, as measured by the placed probes, is close to the uniform distribution.
Under the second mechanism, the probe placement module can determine the location of probes such that the distribution of the probes is substantially similar to the target distribution. In step 204, the probe placement module can represent interest points using variables corresponding to the degree of freedom of the pattern. For example, when an object associated with the 2D pattern is known to move in two-dimensions, the probe placement module can represent an interest point using a two-dimensional gradient vector at the interest point. Then the probe placement module can determine the distribution of interest points by modeling the distribution of perpendicular orientations associated with the interest points.
In step 206, the probe placement module can determine the desired target distribution based on features associated with the interest points. For example, the probe placement module can determine the desired target distribution based on the perpendicular orientations measured at the plurality of interest points. More particularly, the probe placement module can determine the desired target distribution to be an inverse of the distribution of perpendicular orientations measured at the interest points. Similarly, the probe placement module can take into account the rotation vectors and scale information measured at the interest points to determine the target distribution. Subsequently, in step 208, the probe placement module can place the probes on one or more interest points by sampling from the target distribution. The second mechanism is discussed throughout the specification, and in particular in regards to
In some embodiments, the processor 402 can execute instructions and one or more memory devices 404 for storing instructions and/or data. The memory device 404 can be a non-transitory computer readable medium, such as a dynamic random access memory (DRAM), a static random access memory (SRAM), flash memory, a magnetic disk drive, an optical drive, a programmable read-only memory (PROM), a read-only memory (ROM), or any other memory or combination of memories. The memory device 404 can be used to temporarily store data. The memory device 404 can also be used for long-term data storage. The processor 402 and the memory device 404 can be supplemented by and/or incorporated into special purpose logic circuitry.
In some embodiments, the IPD module 406 can be configured to detect interest points from an input image. For example, the IPD module 406 can receive, via an interface 410, an image from another device, such as a camera module or another computing device in communication with the IPD module 406. Subsequently, the IPD module 406 can perform image processing operations to detect interest points.
In some embodiments, interest points can include an edge of a 2D pattern, a boundary (e.g., a chain of edges) of a 2D pattern, a texture boundary, a pixel with a large gradient magnitude, a pixel with a large intensity difference from neighboring pixels, a pixel with a large color difference from neighboring pixels, a Scale-Invariant Feature Transform (SIFT) feature point, any pixel that is distinct from neighboring pixels, or any combinations thereof. Therefore, the IPD module 406 can be configured to perform an edge detection operation to determine a set of edges that form a boundary of a 2D pattern, a differentiation operation to detect a pixel with a large gradient magnitude, a SIFT operator to detect SIFT feature points, or any combinations thereof.
In some embodiments, the IPD module 406 can be configured to determine the orientation perpendicular to structures (hereinafter referred to as a perpendicular orientation) underlying the interest points. In some cases, the perpendicular orientation can be determined by determining a gradient orientation of the underlying structure. For example, a gradient vector of the underlying pattern can be determined at the interest point and an orientation associated with the gradient vector can be determined. In other cases, the perpendicular orientation can be determined through simple calculation. For example, two points on a boundary of the structure can be taken and a line that connects the two points can be determined. The orientation perpendicular to the line can be determined to be the perpendicular orientation. In other cases, the perpendicular orientation of a structure can be determined based on information received from other computational modules, for example, a computer aided design (CAD) modeling module.
In some embodiments, the probe placement module 408 can be configured to determine the location of probes based on interest points in an image. The probe placement module 408 can include a target distribution computation (TDC) module 412, a feature distribution computation (FDC) module 414, and a probe distribution match module (PDM) module 416. The TDC module 412 can determine a target distribution of probes to be placed on one or more interest points; the FDC module 414 can determine the distribution of interest points in an image; and the PDM module 416 can determine the location of probes so that the distribution of the probes and the target distribution of the probes are substantially matched. As discussed below, when the TDC module 412 only deals with a histogram of perpendicular orientations, the target distribution can be a uniform distribution. In other embodiments, the probe placement module 408 may include a different set of modules to perform substantially similar operations.
In some embodiments, the interface 410 can be implemented in hardware to send and receive signals in a variety of mediums, such as optical, copper, and wireless, and in a number of different protocols some of which may be non-transient.
In some embodiments, one or more of the modules 406, 408, 412, 414, 416 can be implemented in software using the memory 404. The software can run on a processor 402 capable of executing computer instructions or computer code. The processor 402 is implemented in hardware using an application specific integrated circuit (ASIC), programmable logic array (PLA), digital signal processor (DSP), field programmable gate array (FPGA), or any other integrated circuit. The processor 402 suitable for the execution of a computer program include, by way of example, both general and special purpose microprocessors, digital signal processors, and any one or more processors of any kind of digital computer. Generally, the processor 402 receives instructions and data from a read-only memory or a random access memory or both.
In some embodiments, disclosed method steps can be performed by one or more processors 402 executing a computer program to perform functions of the invention by operating on input data and/or generating output data. One or more of the modules (e.g., modules 406, 408, 412, 414, 416) can be implemented in hardware using an ASIC (application-specific integrated circuit), PLA (programmable logic array), DSP (digital signal processor), FPGA (field programmable gate array), or other integrated circuit. In some embodiments, two or more modules 406, 408, 412, 414, 416 can be implemented on the same integrated circuit, such as ASIC, PLA, DSP, or FPGA, thereby forming a system on chip. Subroutines can refer to portions of the computer program and/or the processor/special circuitry that implement one or more functions.
The modules 406, 408, 412, 414, 416 can be implemented in digital electronic circuitry, or in computer hardware, firmware, software, or in combinations of them. The implementation can be as a computer program product, e.g., a computer program tangibly embodied in a machine-readable storage device, for execution by, or to control the operation of, a data processing apparatus, e.g., a programmable processor, a computer, and/or multiple computers. A computer program can be written in any form of computer or programming language, including source code, compiled code, interpreted code and/or machine code, and the computer program can be deployed in any form, including as a stand-alone program or as a subroutine, element, or other unit suitable for use in a computing environment. A computer program can be deployed to be executed on one computer or on multiple computers at one or more sites.
The computing device 400 can be operatively coupled to external equipment, for example factory automation or logistics equipment, or to a communications network, for example a factory automation or logistics network, in order to receive instructions and/or data from the equipment or network and/or to transfer instructions and/or data to the equipment or network. Computer-readable storage devices suitable for embodying computer program instructions and data include all forms of volatile and non-volatile memory, including by way of example semiconductor memory devices, e.g., DRAM, SRAM, EPROM, EEPROM, and flash memory devices; magnetic disks, e.g., internal hard disks or removable disks; magneto-optical disks; and optical disks, e.g., CD, DVD, HD-DVD, and Blu-ray disks.
In some embodiments, the computing device 400 can include user equipment. The user equipment can communicate with one or more radio access networks and with wired communication networks. The user equipment can be a cellular phone. The user equipment can also be a smart phone providing services such as word processing, web browsing, gaming, e-book capabilities, an operating system, and a full keyboard. The user equipment can also be a tablet computer providing network access and most of the services provided by a smart phone. The user equipment operates using an operating system such as Symbian OS, iPhone OS, RIM's Blackberry, Windows Mobile, Linux, HP WebOS, and Android. The screen might be a touch screen that is used to input data to the mobile device, in which case the screen can be used instead of the full keyboard. The user equipment can also keep global positioning coordinates, profile information, or other location information.
In some embodiments, the computing device 400 can include a server. The server can operate using an operating system (OS) software. In some embodiments, the OS software is based on a Linux software kernel and runs specific applications in the server such as monitoring tasks and providing protocol stacks. The OS software allows server resources to be allocated separately for control and data paths. For example, certain packet accelerator cards and packet services cards are dedicated to performing routing or security control functions, while other packet accelerator cards/packet services cards are dedicated to processing user session traffic. As network requirements change, hardware resources can be dynamically deployed to meet the requirements in some embodiments.
First Probe Placement Mechanism—Balancing Perpendicular Orientations of Probes
In some embodiments, the probe placement module 408 can be configured to place probes to balance the perpendicular orientations measured at probe locations. More particularly, the probe placement module 408 can be configured to place probes on one or more interest points in a 2D image so that the histogram of perpendicular orientations, as measured at the location of the probes, is roughly uniform. This mode of operation can allow the probe placement module 408 to improve the accuracy of a model for objects with two degrees of freedom.
In some embodiments, the histogram of perpendicular orientations can include a plurality of orientation bins. Each orientation bin can correspond to a predetermined range of orientations. For example, the histogram of perpendicular orientations can include 180 bins, in which each orientation bin can cover the 2-degree range of an angle. Therefore, the histogram of perpendicular orientations can be indicative of a profile of perpendicular orientations as measured at interest points. In some embodiments, the histogram of perpendicular orientations can be represented as a continuous distribution.
In some embodiments, the probe placement module 408 can be configured to determine the histogram of perpendicular orientations associated with interest points. To this end, the probe placement module 408 can determine a perpendicular orientation associated with each of the interest points. For example, the probe placement module 408 can receive, from the IPD module 406 module, information that is representative of the perpendicular orientation at each of the interest points. As another example, the probe placement module 408 can compute the perpendicular orientation associated with each of the interest points. Subsequently, the probe placement module 408 can determine a histogram of perpendicular orientations measured at the plurality of interest points.
In step 502, the IPD module 406 can determine interest points in an image. In some embodiments, the interest points can comprise a boundary of a 2D pattern depicted in an image. In some cases, the IPD module 406 can identify the boundary of a 2D pattern using an edge detection technique. For example, the IPD module 406 can perform an edge detection operation to identify a set of edge points believed to correspond to an edge. Each point can be associated with a position vector and a perpendicular vector that is perpendicular to a underlying structure. Subsequently, the IPD module 406 can chain the edge points to form a coherent boundary of a 2D pattern. The edge detection technique can include, for example, a canny edge detection technique or a Hough transform technique. The edge detection technique can use one or more edge detection operators, including, for example, a Sobel operator, a Kirsch operator, a Prewitt operator, a Gabor filter, a Haar wavelet filter, any other filters that can detect a change in a pixel value in an image (e.g., a high frequency component of an image), and/or any combinations thereof.
In other embodiments, the interest points can include SIFT feature points. In such cases, the IPD module 406 can perform SIFT operations to identify SIFT feature points.
In some embodiments, the interest points can be placed uniformly on the boundary of a pattern. For example, the distance between any two adjacent interest points can be substantially identical. In this case, one may consider each interest point to be associated with the same arc length of the boundary.
Once at least one interest point is available, the FDC module 414 can receive, from the IPD module 406, the location of the at least one interest point. Then, the FDC module 414 can iterate the steps 504-508 to generate a histogram of perpendicular orientations measured at the at least one interest point.
In step 504, the FDC module 414 can select one of the at least one interest point and determine a perpendicular orientation at the selected interest point. In some embodiments, the FDC module 414 can receive perpendicular orientation information from the IPD module 406. In other embodiments, the FDC module 414 can itself determine the perpendicular orientation at the selected interest point. For example, the FDC module 414 convolves a gradient operator with the interest point to determine a perpendicular orientation. The gradient operator can include a Gabor filter, a Haar wavelet filter, a steerable filter, a x-directional gradient filter [−1, 0, 1], a y-directional gradient filter [−1, 0, 1]T, and/or any combinations thereof. As another example, the FDC module 414 computes the perpendicular orientation associated with each of the interest points by, for instance, determining a gradient vector of a structure underling the interest points or determining an orientation of a line that joins two nearby points on the boundary of the structure.
In step 506, the FDC module 414 can add a contribution of the perpendicular orientation at the selected interest point to the histogram of perpendicular orientations. To this end, the FDC module 414 can determine an orientation bin, in the histogram, corresponding to the perpendicular orientation determined in step 504. For example, when the perpendicular orientation is 3-degrees with respect to the x-axis, the FDC module 414 can determine that the perpendicular orientation is associated with an orientation bin #1 that covers the orientation between 2-degrees and 4-degrees with respect to the x-axis. Subsequently, the FDC module 414 can add a vote to the orientation bin associated with the perpendicular orientation. For example, the FDC module 414 can increase a value of the orientation bin by one. As another example, the FDC module 414 can increase a value of the orientation bin by a weight. The weight can depend on the gradient vector associated with the interest point. For example, the weight can depend on a magnitude of the gradient vector.
In step 508, the FDC module 414 can determine whether there is any interest point that the FDC module 414 has not considered for the histogram of perpendicular orientations. If so, the FDC module 414 can go back to step 504 and iterate steps 504-508 until all interest points are considered by the FDC module 414. If the FDC module 414 has considered all interest points, then the FDC module 414 can output the histogram of perpendicular orientations.
Therefore, the FDC module 414 can increase a value associated with the orientation bin by one. As illustrated in
In some embodiments, the TDC module 412 can be configured to generate a target distribution of probes. The target distribution of probes can be indicative of a desired placement of probes on one or more interest points. In some embodiments, the target distribution can include a plurality of orientation bins, where each orientation bin is associated with a value. In some cases, the target distribution can be a uniform distribution. In essence, the uniform target distribution indicates that the number of probes on interest points pointing to a particular orientation should be the same as the number of probes on interest points pointing to another orientation. This way, the probe placement module 408 can balance the number of probes pointing to different orientations.
In some cases, the target distribution can be a partially uniform distribution. For example, some of the orientation bins in the target distribution can have a value of zero and the remaining orientation bins can have the same value. In such cases, the target distribution's orientation bin can have a value of zero when the corresponding orientation bin in the histogram of perpendicular orientations 604 has a value of zero.
Once the FDC module 414 determines the histogram of perpendicular orientations and the TDC module 412 determines the target distribution, the PDM module 416 can determine the location of probes so that the distribution of the probes on one or more interest points matches the target distribution.
For example, referring to an example illustrated in
In step 704, the PDM module 416 can place probes on the scaled boundary in a uniform manner.
In some embodiments, the PDM module 416 can place probes uniformly on the scaled boundary sequentially. For example, the PDM module 416 starts at an initial interest point (which may be arbitrarily selected) and place a first probe at the initial interest point. Subsequently, the PDM module 416 can place the second probe at an interest point that is separated by the predetermined distance from the first probe. This process can be iterated until the PDM module 416 has considered all the plurality of interest points.
In step 706, the PDM module 416 can reverse the scaling operation from step 702, thereby also adjusting the distance between uniformly placed probes.
In some embodiments, the PDM module 416 can be configured to perform the arc length scaling and reverse scaling without actually stretching the arc length of interest points (e.g., boundary sections) graphically. For example, the PDM module 416 can be configured to increase or decrease the resolution of the underlying coordinate system around the interest point in order to effectively scale the arc length of the interest point.
In some embodiments, the PDM module 416 can merge the steps 704 and 706 by sequentially placing probes. For example, the PDM module 416 can determine the uniform distance that should separate two probes. Then the PDM module 416 starts at an initial interest point (which may be arbitrarily selected) and places a first probe at the initial interest point. Subsequently, the PDM module 416 can determine the arc length associated with the initial interest point based on the histogram of perpendicular orientations. Then, the PDM module 416 can scale the uniform distance as a function of the arc length to determine the scaled distance between the first probe and a second probe to be placed adjacent to the first probe. Subsequently, the PDM module 416 can place the second probe at an interest point that is separated by the scaled distance from the first probe. This process can be iterated until the PDM module 416 has considered all the plurality of interest points. This way, the PDM module 416 can perform the steps 704 and 706 without graphically scaling the boundary of a pattern.
In some embodiments, the FDC module 414 can perform a low-pass filtering operation on the histogram of perpendicular orientations prior to scaling the arc length of interest points in step 702. There may be several benefits to performing a low-pass filtering operation prior to scaling the arc length of interest points. First, the low-pass filtering operation can allow the probe placement module to remove noise from the histogram of perpendicular orientations.
Second, the low-pass filtering can address the division by zero problem. The PDM module 416, which performs the arc length scaling, would often use the value of an orientation bin in the histogram of perpendicular orientations as a denominator. However, there may be some orientation bins with the value of 0, which may cause the division by zero problem. The low-pass filtering operation can address this issue by effectively eliminating orientation bins with a value of zero.
Third, the low-pass filtering operation can allow the probe placement module to discount a particular orientation bin that is grossly under-represented when the neighboring orientation bins are well represented. For example, the histogram of perpendicular orientations can indicate that the pattern has 100 interest points on a structure with a perpendicular orientation of 89 degrees, 100 interest points on a structure with a perpendicular orientation of 91 degrees, but only 1 interest point on a structure with a perpendicular orientation of 90 degrees. Without low-pass filtering, the PDM module 416 would likely increase the number of probes around the interest point with a perpendicular orientation of 90 degrees while limiting the number of probes around the interest points with a perpendicular orientation of 89 or 91 degrees. Such a drastic measure to balance the histogram of perpendicular orientations may be ineffective in capturing balanced information from probes because similar orientations can capture similar information. In other words, probes pointing to a perpendicular orientation of 89 or 91 degrees can capture substantially similar information as probes pointing to a perpendicular orientation of 90 degrees. Therefore, increasing the number of probes pointing to a perpendicular orientation of 90 degrees may be ineffective in capturing balanced information across the full range of angles, especially when the total number of probes is limited.
Low-pass filtering can address this issue because by low-pass filtering the histogram of perpendicular orientations, the value of the orientation bin for 90 degrees can be smoothed (e.g., averaged) with the values of the orientation bins for 89 degrees and 91 degrees. Therefore, the low-pass filtering operation can substantially increase the value of the orientation bin for 90 degrees. This way, the PDM module 416 can recognize that the information around the perpendicular orientations of 90 degrees is well captured by probes pointing to 89 degrees and 91 degrees. Therefore, the PDM module 416 would not drastically increase the number of probes pointing to 90 degrees.
In some embodiments, the FDC module 414 can perform the low-pass filtering operation by convolving the histogram with a kernel. In some cases, the FDC module 414 can be configured to perform a circular convolution. For example, under the circular convolution, the FDC module 414 can wrap the kernel around the limits of the orientation domain (e.g., 0-2π) of the histogram. The kernel for the low-pass filtering operation can include a raised cosine kernel, a cosine-squared kernel, or any other circular functions that can smooth the histogram. The FDC module 414 can control the width of the kernel to control an amount of smoothing to be performed on the histogram. For example, the width of the kernel can cover 2π/N, where N can be any integer number.
In some embodiments, instead of increasing the density of probes along the shorter edge as in
Second Probe Placement Mechanism—Sampling Probes from a Distribution
In some embodiments, the probe placement module 408 can be configured to place probes on one or more interest points by sampling probes from a target distribution of probes. The target distribution of probes can include random variables corresponding to degrees of freedom associated with the pattern. For example, when an object associated with the pattern is allowed to move in two dimensions (e.g., translational movement), the target distribution can have two random variables: x coordinate and y coordinate (or other equivalent representations.) As another example, when an object associated with the pattern is allowed to make a translational movement and a rotational movement, the target distribution can have three random variables: x coordinate, y coordinate, and a rotational vector (e.g., an orientation.) As another example, when an object associated with the pattern is allowed to make a translational movement, a rotational movement, and a scaling movement (e.g. a movement away from or towards an imaging device), the target distribution can include four random variables: x coordinate, y coordinate, rotation, and scale.
In some embodiments, the probe placement module 408 can represent the target distribution as a non-parametric distribution. For example, the probe placement module 408 can quantize the domain of each random variable into a plurality of bins, and simply count the number of interest points that fall into corresponding bins. In other embodiments, the probe placement module 408 can represent the target distribution as a parametric distribution.
In some embodiments, the probe placement module 408 can determine the target distribution using a TDC module 412. The TDC module 412 can be configured to determine the target distribution of probes based on features associated with the interest points. For example, the TDC module 412 can determine the target distribution based on one or more of, for example, the coordinate of the interest points, the perpendicular orientation associated with the interest points, the rotation of the interest points, or the scale of the interest points.
In some embodiments, the TDC module 412 is configured to determine the target distribution such that the distribution of perpendicular orientations sampled from the target distribution is substantially balanced. For instance, suppose that the pattern of interest is a horizontal rectangle, as shown in
In some embodiments, the TDC module 412 is configured to determine the target distribution so that the target distribution has a similar support as the distribution of interest points. This is important because in these embodiments the probe placement module 408 is configured to sample the probes by re-sampling (e.g., importance sampling) from the existing set of interest points. To this end, the TDC module 412 is configured to use a mixture model for both the interest point distribution and the target distribution, as discussed below.
In some embodiments, the TDC module 412 provides the target distribution to the PDM module 414, and the PDM module 414 is configured to draw samples from the target distribution to determine the location of probes.
In some embodiments, the PDM module 414 can use an importance sampling technique to draw samples from the target distribution. In other embodiments, the PDM module 414 can be configured to determine a boundary of a pattern, and generate probe samples along the boundary of a pattern. This technique can be useful when drawing only a small number of probes from the target distribution. This technique has the advantage that the set of probes generated by the sampling may not be affected by random fluctuations in the re-sampling process and can guarantee that the probes are dispersed across the full geometric extent of the pattern's boundary.
Target Distribution Computation
When a pattern has two degrees of freedom (e.g., translational movement,) the TDC module 412 can determine a weighting function ƒ(x,y) that satisfies the following relationships:
where i indexes the ith interest point. The objective of this optimization routine is to identify a function ƒ(x,y) that equates (1) the weighted summation of gradient vectors' x-components measured at the interest points and (2) the weighted summation of gradient vectors' y-components measured at the interest points. In some cases, the TDC module 412 can balance only the magnitude of the gradient vectors. Therefore, xi can refer to the absolute value of the x component of the gradient vector measured at the ith interest point; and yi can refer to the absolute value of the y component of the gradient vector measured at the ith interest point.
Once the TDC module 412 determines the weighting function ƒ(x,y), the TDC module 412 can provide the weighting function ƒ(x,y) to the PDM module 416. In some embodiments the weighting function may take the form of a probability distribution which the PDM module 416 can use to place the probes on one or more interest points. Since the PDM module 416 in this case uses the weighting function ƒ(x,y) as a probability distribution from which to sample probes, it must be constrained to be non-negative and can be positive at least for some gradient components (x,y). For such embodiments the term “target distribution” will be used to refer to the probability distribution here denoted ƒ(x,y).
In some embodiments, the weighting function is used to weight an existing set of probes chosen through some other means, to affect their relative importance in such a way as to minimize:
When a pattern has three degrees of freedom (e.g., translational movement and rotational movement,) the TDC module 412 can incorporate, into the target distribution, a rotational variable θ corresponding to a rotational movement. The TDC module 412 can define the rotational variable θ with respect to an origin.
In some embodiments, the origin can be the center-of-mass of the plurality of interest points. In some embodiments, the origin can be the center of rotation. The center of rotation can be the point about which the moment of rotation is minimized. The center of rotation corresponds to a unique global minimum, and is independent of the choice of basis vectors (e.g., a coordinate system). Therefore, the center of rotation is a geometric quantity that is intrinsic to the plurality of interest points. The center of rotation can be computed as follows:
Cr=[φuuTds]−1X−1φupTXuds
where p is a reference vector with respect to a reference point (which may be arbitrary), u is a unit normal vector at a particular interest point, and X is a cross product matrix.
For computational purposes, the center of rotation in a coordinate system with orthonormal basis can be computed as follows:
where the subscripts x and y refer to the x and y components of the corresponding vector.
Once the origin is determined, the TDC module 412 can determine the rotational variable θ using a position vector vi of the ith interest point, which is a vector from the origin to the center of the ith interest point, and a rotational unit vector uθ
In some embodiments, the rotational variable θi can be independent of the norm of the position vector vi. The rotational variable θi that is independent of the norm of the position vector vi can provide a target distribution that would not distinguish probe locations based on the norm of the position vector vi. For example, the TDC module 412 can define the rotational variable θi for the ith interest point as follows:
This representation of the rotational variable θi may be useful for coarsely aligning shapes with large angular step sizes ω.
In some embodiments, the rotational variable θi can take into account the norm of the position vector vi. Since
the TDC module 412 can emphasize the contribution of interest points that are further away from the origin in order to increase the angular precision. For example, the TDC module 412 can define the rotational variable θi for the ith interest point as follows:
The rotational variable θi that depends on the norm of the position vector vi can provide a target distribution that would favor placing probes at locations further away from the origin. This way, the target distribution can cause more probes to be sampled in interest points further away from the origin.
In some embodiments, the TDC module 412 can determine the representation for the rotational variable θi based on the shape of the pattern. For example, the TDC module 412 can determine that the pattern includes a lever arm. In this case, the TDC module 412 can take into account the lever arm in determining which of the representations to use for the rotational variable θ. As another example, the TDC module 412 can determine that the pattern includes concentric circles, or a nut inside of another nut. In this case, the TDC module 412 can take into account the concentric circles or a nut inside of another nut in determining which of the representations to use for the rotational variable θ.
Once the TDC module 412 determines the representation for the rotational variable, the TDC module 412 can use the determine representation to represent each of the interest points. Subsequently, the TDC module 412 can be configured to determine the target distribution based on the representation of the interest points by finding a weighting function ƒ(x,y,θ) that satisfies the following relationships:
with the constraints that:
where i indexes the ith interest point.
Once the TDC module 412 determines the target distribution ƒ(x,y,θ), the TDC module 412 can provide the target distribution ƒ(x,y,θ) to the PDM module 416. Subsequently, the PDM module 416 can use the target distribution ƒ(x,y,θ) as a probability distribution to sample probes on the pattern.
To facilitate the above optimization process, the probe placement module 408 can assume a functional form for the target distribution ƒ(x,y,θ).
In some embodiments, the probe placement module 408 can assume that the target distribution ƒ(x,y,θ) has a linear form. Although a linear function can become negative, the constraint ƒ(xi, yj, θi)≥0, ∀i can force the target distribution to be positive at all interest points. When the target distribution ƒ(x,y,θ) has a linear form, the optimization routine for finding the target distribution may be simple. However, because the space of linear functions is limited, it may be difficult to find a linear function that satisfies all the constraints.
In some embodiments, the probe placement module 408 can assume that the target distribution ƒ(x,y,θ) has a non-linear form. When the target distribution ƒ(x,y,θ) has a non-linear form, the optimization routine for finding the target distribution may be complex. However, because the space of non-linear functions is wide, it may be easier to find a non-linear function that satisfies all the constraints.
In some embodiments, the TDC module 412 can set the target distribution ƒ(x,y,θ) as an inverse of an interest point distribution pp(x,y,θ|parameter). In this case, the TDC module 412 can receive, from the FDC module 414, the interest point distribution pp(x,y,θ), and indirectly determine the target distribution ƒ(x,y,θ) by computing an inverse:
When the target distribution ƒ(x,y,θ) defined as an inverse of an interest point distribution pp(x,y,θ), the target distribution ƒ(x,y,θ) will cause more probes to be sampled at locations with interest points that are relatively dissimilar compared to rest of the interest points.
The FDC module 414 can model the interest point distribution pp(x,y,θ) as a mixture model. In some embodiments, the mixture model can include a Gaussian Mixture Model (GMM):
The GMM has four parameters: the number of Gaussian distributions N, the weight αk of the kth Gaussian distribution, the mean vector
In some embodiments, the FDC module 414 can estimate the number of Gaussian distributions N for the GMM by clustering the interest points and determining the number of clusters that best fit the interest points. For example, the FDC module 414 can perform a k-means clustering operation on the interest points to estimate the number of Gaussian distributions N.
The remaining set of parameters {αk,
As discussed above, the TDC module 412 can determine the target distribution ƒ(x,y,θ) by simply inverting the interest point distribution pp(x,y,θ). However, this target distribution ƒ(x,y,θ) may cause most of the probes to be placed on edges with the least common perpendicular orientations. For example, when a pattern is capable of making only 2D translational movements and the pattern has a rectangular boundary with rounded corners, this target distribution ƒ(x,y) may cause the PDM module 416 to sample the mostly around the corner locations.
To address such issues, in some embodiments, the TDC module 412 can transform the interest point distribution pp(x,y,θ) and invert the transformed interest point distribution (x,y,θ) to determine the target distribution ƒ(x,y,θ).
In “the first probe placement mechanism” described previously, this transformation takes the form of applying a smoothing kernel to pp(x,y,θ).
In some cases, the TDC module 412 can determine the target distribution by transforming the interest point distribution in ways other than performing an inversion. One such embodiment transforms the interest point distribution pp(xi,yi,θi|{αk,
For example, the TDC module 412 can denote
In this representation, the TDC module 412 can be configured to find the weights that minimize the following relationship:
with the constraint:
Using a Lagrange Multiplier, the TDC module 412 can reduce this problem as a set of linear equations:
The TDC module 412 could solve this set of linear equations with respect to , but the TDC module 412 is subject to additional constraints. The above set of linear equations does not prevent the transformed weights from turning negative, or prevent a large weight from being assigned to Gaussians that were estimated from small groups of interest points (e.g., whose original weights αk in the interest point distribution pp(x,y,θ) was small). The TDC module 412 can programmatically apply these constraints.
Also, the TDC module 412 is configured to impose the minimum probe distance between adjacent probes by requiring the transformed weight to be greater than a predefined value:
where αk is the weight of the kth Gaussian distribution in the interest point distribution pp(x,y,θ); Nedges is the number of interest points used to estimate the weights αk in the interest point distribution pp(x,y,θ); Nprobes is the target number of probes (e.g., 64); and dmax is the maximum allowable distance between probes in units of interest points or any predetermined units. The above equation can be re-arranged as follows:
This new relationship illustrates that the ratio of the number of edges to number of probes for mixture component k is bounded by dmax units and 1 unit. Therefore, adjacent probes in cluster k can be placed no further apart than dmax units and no closer than 1 unit.
When the set of linear equations produces a result with at least one weight αk violating a constraint, the TDC module 412 can iterate over all possible combinations of boundary cases, calculate the optimal remaining weights, and select the constrained minimum.
For example, the TDC module 412 can determine all possible sets of boundary conditions (e.g., {α0low}, {α0high}, {α0low, α1low}, {α0high, α1low}, . . . ) for the linear equations. Each set of boundary conditions may include boundary conditions for a subset of transformed weights . Subsequently, for each set of boundary conditions, the TDC module 412 can fix the value of a subset of weights to be the value of the corresponding boundary conditions, and solve the set of linear equations for the remaining free weights without boundary conditions. This way, the TDC module 412 can determine the global solution to the set of linear equations given the constraints by selecting, amongst the solutions under all possible sets of boundary conditions, the solution with the minimum score.
In some cases, when the number of Gaussian distributions in the GMM is greater than the number of dimensions in which the interest points lie, some of the parameters in the GMM may be linearly dependent. For example, mean vectors of Gaussian distributions may become linearly dependent when the number of Gaussian distributions is greater than the number of dimensions in which the interest points lie.
To address this issue, the TDC module 412 can be configured to regularize the parameters for the GMM, for example, using Tikhonov regularization. To this end, the TDC module 412 can reformulate the optimization problem to minimize the following relationship:
The new Lagrangian formulation seeks to quantify the change in transformed weights between the interest point distribution pp(x,y,θ) and the target distribution (x,y,θ), subject to the constraints that the (x,y,θ) components of the mean vectors are balanced and the sum of the transformed weights is 1.
The TDC module 412 could directly find the weights that satisfy the Lagrangian relationship stated above. However, as before, this relationship does not prevent the weights from turning negative, or prevent a large weight from being assigned to Gaussians that were estimated from small groups of interest points (e.g., whose original weights αk in the interest point distribution pp(x,y,θ) was small). The TDC module 412 can programmatically apply these constraints, as illustrated above. This is mathematically valid because the above Lagrangian relationship is quadratic in , so if one of the weights is negative, then the optimal value should lie on one (or more) of the boundary conditions.
In summary, in order to identify parameters for the target distribution (x,y,θ) based on parameters of the interest point distribution pp(x,y,θ), the TDC module 412 can use the following procedure:
Sampling of Probes from Target Distribution
Once the TDC module 412 determines the transformed interest point distribution (x,y,θ), the TDC module 412 can provide the transformed interest point distribution (x,y,θ) (or an inverse of the transformed interest point distribution) to the PDM module 416. Subsequently, the PDM module 416 can sample from the inverse of the transformed interest point distribution (x,y,θ) to determine the location of probes one or more interest points in an image.
Intuitively speaking, the TDC module 412 is configured to choose the transformed interest point distribution (x,y,θ) such that the expected value of x, y and 0 with respect to the transformed interest point distribution (x,y,θ) are as similar as possible:
Importance sampling allows the PDM module 416 to draw samples from a target distribution by weighting samples drawn from another different distribution with the condition that the samples have similar support. In other words:
where Sprobes is the set of probes and SIP is a set of interest points. Therefore, the PDM module 416 can use this relationship to weigh samples drawn from the interest point distribution pp(s|{αk,
Thus, when the PDM module 416 draws probes by placing probes at every interest point along a boundary of a pattern, then the PDM module 416 can weigh the probes by the above ratio
In some embodiments, the PDM module 416 can achieve similar effects by (1) spacing out adjacent probes by a distance that is the inverse of the above ratio along the pattern boundary and (2) compensating for the desired number of probes and the number of initial edges.
Therefore, in some embodiments, sampling from the inverse of the transformed interest point distribution (x,y,θ|{,
where Nedges indicates a number of interest points used to determine parameters for the interest point distribution pp(x,y,θ|{αk,
To require the adjacent probes to be spaced out as such, the PDM module 416 can place probes on one or more interest points sequentially. For example, the PDM module 416 starts at an initial interest point (which may be arbitrarily selected) and place a first probe at the initial interest point. Then the PDM module 416 can use the relationship above to determine the distance between the first probe and a second probe to be placed adjacent to the first probe. Subsequently, the PDM module 416 can place the second probe at an interest point that is separated by the determined distance from the first probe. This process can be iterated until the PDM module 416 has considered all the plurality of interest points used in determining the interest point distribution pp(x,y,θ|{αk,
Requiring adjacent probes to be spaced out by a certain amount can be interpreted as modifying (e.g., stretching) the arc length of adjacent interest points. As described previously, an interest point can be considered a representation of an initialized probe placed at the center of the interest point. Therefore, requiring adjacent probes to be spaced out by a certain amount can be interpreted as modifying the arc length between the centers of adjacent interest points. Thus, the first mechanism for placing probes (illustrated in regards to
While much of the discussion herein focused on a case in which the probability space spanned by the mixture model included a x-directional component, a y-directional component, and a rotational vector, the disclosed technique can be extended to increase the dimensionality of the probability space spanned by the mixture model. For example, the probe placement module 408 can be configured to balance information in a four-dimensional space:
where φ denotes scale. While the optimization step may be a bit more complicated, the probe placement module 408 can employ the same technique as in the three-dimensional space scenario. For example, the probe placement module 408 can be configured to minimize:
with the constraint:
using a Lagrange multiplier to reduce to a set of linear equations (as before). The probe placement module 408 can be configured to ensure that the weights do not become negative or cause the probes to be highly concentrated on a few edge locations. To this end, as in the three-dimensional space scenario, the probe placement module 408 can be configured to apply boundary constraints programmatically.
As in the three-dimensional space scenario, the probe placement module 408 can apply Tikhonov regularization when the mean vector set is not linearly independent and when the number of components in the mixture model (N) exceeds the number of dimension (now 4):
In step 1302, the IPD module 406 can determine interest points in an image. In some cases, the IPD module 406 can use an edge detection technique to identify the interest points. The edge detection technique can include, for example, a canny edge detection technique or a Hough transform technique. The edge detection technique can use one or more edge detection operators, including, for example, a Sobel operator, a Kirsch operator, a Prewitt operator, a Gabor filter, a Haar wavelet filter, any other filters that can detect a change in a pixel value in an image (e.g., a high frequency component of an image), and/or any combinations thereof.
In some embodiments, the IPD module 406 can provide the location information of interest points to the FDC module 414. The FDC module 414 can represent each interest point using variables that represent the degrees of freedom associated with the interest point. For example, when an interest point is known to move in two dimensions, an interest point can be represented as a two dimensional vector corresponding to (x,y) gradient components of the interest point. As another example, when an interest point is known to move in three dimensions, an interest point can be represented as a three dimensional vector corresponding to (x,y) gradient components of the interest point and a rotational orientation of the interest point (or a function thereof).
In step 1304, the FDC module 414 can be configured to cluster the interest points. For example, the FDC module 414 can cluster the interest points by clustering interest points that are close to one another in the Euclidian distance in their representations. In some embodiments, the FDC module 414 can use k-means clustering technique, a mean-shift clustering technique, a “balanced iterative reducing and clustering using hierarchies” (BIRCH) clustering technique, or any other suitable clustering techniques that are capable of grouping interest points with similar characteristics.
In step 1306, the FDC module 414 can determine the interest point distribution based on the clusters from step 1304. For example, the FDC module 414 can be configured to represent the interest point distribution using a Gaussian Mixture Model. In this case, the FDC module 414 can be configured to determine the number of Gaussian distributions for the Gaussian Mixture Model using the number of clusters from the cluster step. Also, the FDC module 414 can be configured to perform an expectation-maximization operation to determine the maximum likelihood estimates of the set of parameters for the Gaussian Mixture Model. This way, the FDC module 414 can determine the interest point distribution pp(x,y,θ|{αx,
In step 1308, the TDC module 412 can determine the transformed interest point distribution (x,y,θ|{,
In step 1310, the PDM module 416 is configured to sample the target distribution (e.g., the inverse of the transformed interest point distribution) to determine the location of probes on one or more interest points. In some cases, the PDM module 416 can use the following relationship to determine the spacing between two adjacent probes:
The PDM module 416 can use the above relationship to determine or modify the distance between centers of all adjacent interest points (or between centers of a subset of adjacent interest points).
In this case, the PDM module 416 increased the density of probes along the short edge of the rectangle compared to the long edge of the rectangle, as in
which incorporates radius in a linear fashion to model a quantity that could be thought of as angular momentum; and
which uses the square to form a quantity akin to angular moment of inertia. Depending on the application, one of these formulations can be more preferable. The increase in order of the radius term tends to push the probes whose angular component is highest to the outermost regions of the pattern. This has implications when picking a spacing over which to apply the probes when searching for the pattern in an image. It also has implications to the angular alignment accuracy.
These figures illustrate an interesting case because the four Gaussian distributions in the interest point distribution have dependent mean vectors:
In this case, the unregularized optimization can provide a solution in which the weights may have large values (e.g., α0≅+large, α1≅−large, α2≅+large α3≈−large,) but can add up to one. To address such singularities, the TDC module 412 can regularize the optimization problem.
The probe placement module 408 can be used in a variety of applications. For example, the probe placement module 408 can be useful in aligning and inspecting patterns, such as electronic devices. Also, the probe placement module 408 can be useful in robot guidance. For example, when a robot is configured to pick up a long, skinny battery, the probe placement module 408 can be configured to place probes to improve the accuracy of the model representing the skinny battery.
A machine vision system can also be configured to determine the absence or presence of one or more instances of a predetermined pattern in a 3D image, and determine the location of each found instance. This information can be used in subsequent inspection (or other) operations to search for defects and/or perform other operations, such as part rejection.
3D images are acquired using 3D cameras which may be based on a variety of technologies—for example, a laser displacement sensor (profiler), a stereoscopic camera, a sonar, laser or LIDAR range-finding camera, and a variety of other passive or active range-sensing technologies. Such cameras can produce a range image wherein an array of image pixels (typically characterized as positions along orthogonal x and y axes) is produced that also contain a third (height) dimension for each pixel (typically characterized along a z axis perpendicular to the x-y plane). Alternatively, for example, such cameras can generate a point cloud representation of an imaged object. A point cloud is a collection of 3D points in space where each point i can, for example, be represented as (xi,yi,zi). A point cloud can represent a complete 3D object including the object's back and sides, top and bottom. 3D points (xi,yi,zi) can represent locations in space where the object is visible to the camera. In this representation, empty space can be represented by the absence of points.
By way of comparison, in some embodiments, a 3D range image representation Z(x,y) is analogous to a 2D image representation I(x,y) where the depth or height Z replaces what would be the brightness/intensity I at a location (x,y) in an image. In some embodiments, a range image can exclusively represent the front face of an object that is directly facing a camera, because only a single depth is associated with any point location (x,y). The range image typically does not represent an object's back or sides, top or bottom, although in some embodiments in can represent an object's back or sides, top or bottom. A range image typically has data at every location (x,y) even if the camera is free of information at such locations, however it is also possible to represent the absence of data at any point location (x,y). It is possible to convert a range image to a 3D point cloud in a manner clear to those of skill in the art.
To determine the absence or presence of one or more instances of a predetermined 3D pattern in a 3D image, a machine vision system can represent the 3D pattern to be found using a model. The machine vision system can generate a model for a 3D pattern from one or more 3D training images or one or more synthesized 3D images from a geometric description that contain examples of the 3D pattern to be located and/or inspected. Once the model is available, the machine vision system can compare the model to a test 3D image at each of an appropriate set of poses, compute a match score at each pose, and determine candidate poses that correspond to a local maximum in match score. The machine vision system can consider candidate poses whose match scores are above a suitable threshold to be instances of the 3D pattern in the 3D image.
The process of locating 3D patterns occurs within a multidimensional space that can include, but is not limited to, x-y-z position (also called translational), location, orientation, size, and/or rotational degrees of freedom (e.g., pitch, roll, and yaw).
A model can include a set of data elements called 3D probes. Each 3D probe represents a relative position at which certain measurements and tests are to be made in a 3D image at a given pose, each such test contributing evidence that the 3D pattern exists at the associated pose. A 3D probe can be placed in a manner substantially normal to a structure (e.g., surface) of the underlying 3D pattern.
During the training stage, machine vision systems can place the 3D probes on the surface of a 3D pattern in a uniform manner. For example, in some embodiments a machine vision system can be configured to place 3D probes on the 3D pattern surface so that the distance between adjacent 3D probes is roughly identical for all pairs of adjacent 3D probes. This strategy, which is herein referred to as a “uniform placement strategy,” can be effective in modeling 3D patterns with a balanced orientation profile (e.g., a 3D pattern with orthogonal surfaces and the proportions of the surfaces pointing to various orientations are similar). For example, the uniform placement strategy can be useful in modeling cubic 3D patterns because the number of 3D probes pointing to different orientations (e.g., up, down, left, and right) is roughly the same on each edge of the 3D pattern in the 3D image, which can lead to accurate information on the location and orientation of the 3D pattern.
Unfortunately, a uniform placement strategy may be ineffective in modeling 3D patterns with an unbalanced orientation profile (e.g., patterns whose surface normals do not provide alignment information in all considered degrees of freedom). For example, the uniform placement strategy is generally not as effective in aligning 3D patterns with an elongated and irregular pipe shape.
The techniques described herein can provide for an automated probe placement module for placing 3D probes on a 3D pattern in three dimensions. In some embodiments, probe placements may be distributed to balance their ability to resolve in x, y and z. In some embodiments, the 3 translational degrees of freedom are jointly balanced along with the three rotational degrees of freedom. Additionally, in some embodiments, x, y, and z are balanced while maximizing the smallest rotational component. In some embodiments, limitations imposed by the geometry of 3D pattern can make it difficult to achieve absolute balance in resolving ability between the considered degrees of freedom. In such cases the absolute difference between the resolving abilities in the considered degrees of freedom can be minimized. This can have the effect of increasing the resolving ability of the 3D pattern in the degrees of freedom least represented in a model where probes were placed evenly over the 3D pattern's surface. The probe placement module is configured to place 3D probes on interest points of a 3D image so that the 3D probes can accurately represent a 3D pattern depicted in the 3D image. The probe placement module can be configured to place the 3D probes so that the 3D probes can extract balanced information on all degrees of freedom associated with the 3D pattern's movement, which improves the accuracy of the model generated from the 3D probes. For example, when an object associated with the 3D pattern is known to move in three dimensions, the probe placement module can place the 3D probes so that the 3D probes can extract balanced information in the three dimensions. The probe placement module can also take into account the shape of the 3D pattern so that the 3D probes can extract balanced information regardless of the shape of the 3D pattern. This is in contrast to techniques that may extract unbalanced information, such as extracting more information in the degrees of freedom orthogonal to the long axis compared to along that axis when 3D probes are placed uniformly over the surface of the 3D pattern shown in
In step 2001, the probe placement module 408 can be configured to generate a plurality of features associated with a first plurality of points of interest from a 3D image. For example, the probe placement module 408 can receive, from an interest point detection module 406, the surface of a 3D pattern in a 3D image represented by a first plurality of points of interest. The probe placement module 408 can then generate a plurality of features associated with the first plurality of points of interest from a 3D image.
In step 2002, the probe placement module 408 can select a second plurality of points of interest from among the first plurality of points of interest based at least in part on the plurality of features. In some embodiments, a goal of the selection process is for the second plurality of points of interest to exhibit some desired ensemble property with regard to a 3D alignment system. In some embodiments the probe placement module 408 can select a second plurality points using the statistical model fitting and Monte-Carlo sampling techniques described in further detail herein. However, other selection techniques might be utilized, for example sorting the first plurality of points into bins pertaining to their features then selecting points from those bins in an even manner.
In step 2003, the probe placement module 408 can determine placements of a plurality of 3D probes based at least in part on the second plurality of points of interest. For example, the probe placement module 408 can place probes on each of the second plurality of points of interest. Alternatively, in a further embodiment the probe placement model may, for example, place probes by interpolating between neighboring points of interest from the second plurality of points of interest.
In some embodiments, to allow the point selection process in step 2002 to select a second plurality of points of interest that achieve a desired ensemble property, features generated in step 2001 may be used. In some embodiments, for each point of interest, its features should be descriptive of its contribution to the desired ensemble property. For example, if the algorithm is trying to balance the ability to align the 3D pattern in each of the three translational degrees of freedom, then the feature vector for each point might have three components, each component of which would be indicative of the point's contribution to an alignment algorithm's ability to resolve the 3D pattern in each of the three translational degrees of freedom. In another example, the desired ensemble property might be to maximize the ability to resolve in a single particular rotational degree of freedom while simultaneously ensuring the ability to align in each of the translational degrees of freedom. In this case the features will also include information descriptive of each point's contribution to the resolving ability in the particular rotational degree of freedom.
In some embodiments, the feature generation step 2001 of
For example, in some embodiments, the feature generation process may use the location and/or surface normal direction of a point of interest to quantify its contribution to an ensemble property. In a particular embodiment the ensemble property might be to ensure the alignment ability in the 3 translational degrees of freedom is identical. To achieve this, in some embodiments, the step 2004 would comprise calculating the surface normals for each point, step 2005 would take these feature vectors and calculate a rotation of the Euclidean coordinate system (possibly using principal components analysis), and step 2006 would project the plurality of surface normals onto the unit vectors defining the new coordinate system to produce the values for the plurality of feature vectors.
In another embodiment the ensemble property might be chosen to ensure the difference in alignment ability between each of the 3 rotational coordinate systems was minimized. To achieve this, the feature vectors might comprise 3 components, each of which would be set equal to the projection of the point of interest's surface normal onto one of the rotational unit vectors defined by the 3D pattern's rotational coordinate system. Thus, in this example, step 2005 would comprise calculating the 3D pattern's center of rotation and axes of rotation.
In a further embodiment it may be useful to quantify a point's contribution in directions orthogonal to the surface normal direction. This can allow the comparative usefulness of probe sites close to the edge of a plane (as opposed to those at its center) when aligning in directions parallel to that plane to be quantified. By contrast, in some embodiments, simply using the surface normal vectors gives no information for alignment in the degrees of freedom parallel to the surface of the plane. In a further example, placement of probes at the end of the pipe shown in
In step 2101, the probe placement module 408 locates at each point of interest, all adjacent points within a N×N×N region centered on that point. For example, a point pcenter could have four points p1, p2, p3, and p4 within an N×N×N region centered on the point pcenter.
In step 2102, the probe placement module 408 projects these neighboring points onto the surface plane orthogonal to the surface normal for the point. For example, the points p1, p2, p3, and p4 within an N×N×N region centered on the point pcenter can be projected onto the surface plane orthogonal to the surface normal for the point.
In step 2103, the probe placement module 408 regularizes the surface plane into a pixel grid so that each pixel's value equates the surface depth from the plane at the pixel center. To do this, the probe placement module 408 finds a 2D bilinear mapping from the unit square onto the closest four surrounding projected points (spaced arbitrarily), and then uses the inverse of this mapping to place the pixel grid center point into the unit square as illustrated in
a1, a2, a3, a4, b1, b2, b3, b4:
xi=a1+a2ui+a3vi+a4uivi
yi=b1+b2ui+b3vi+b4uivi
where u and v are the components of pit=(ui,vi). In matrix form:
There are two sets of linear equation that are solvable for the mapping parameters. Once the mapping is obtained from the unit square to the set of points, the inverse mapping is computed to find the location of the pixel grid center mapped into the unit square. The inverse mapping is non-linear, first define:
Continuing with step 2103, having obtained the location of pcentert, the location can now be used to do a bilinear interpolation between the values of depth at each of the four locations, p1, p2, p3 and p4 to get a depth value for the pixel grid center.
In step 2103, if a surrounding point is not available (e.g., because the point might be at the edge of the surface) then a depth value equal to N can be used.
Thus, step 2103 can produce a pixel grid regularized depth map. For example the depth map 2201 shown in
In step 2104, the probe placement module 408 extracts directional information from the depth map. The probe placement module 408 can perform this step by finding the angle of the principal axes 2301 (e.g., shown in
δi,j=N−di,j
IXX=Σi,jδi,jxi,j2
IYY=Σi,jδi,jyi,j2
IXY=Σi,jδi,jxi,jyi,j
θ=a tan 2(2IXY,IYY−IXX)
In step 2105, having obtained the principal axes (e.g., the principle axes 2301 shown in
In step 2106, the probe placement module 408 maps the 2-d unit vectors (in the directions of the principal axes) back into the 3-d domain. The probe placement module 408 can be configured to perform this step by first scaling these vectors by the resolving powers calculated in the previous step 2016 (e.g., multiplying the 2-d unit vectors by their respective resolving powers). The final results for this example are shown in
Continuing with the above procedure, for each point, there are now three vectors u0, u1 and u2, whose magnitudes are indicative of the point's contribution to being able to resolve the object in space. The overall goal of the process in this example is to pick a subset of these points that will allow a registration process to resolve the 3D object with equal determination and robustness in each of the translational degrees of freedom and/or rotational degrees of freedom. To do this, the probe placement module 408 can be configured to construct two probability distributions. The first is fitted to the set of points and is indicative of their relative frequency in the data set. The second “target” distribution is constructed in such a way that it models the relative frequency of a set of points having the desired property. That property could, for example, be that the set of points when combined would give equal resolving power in the three translational degrees of freedom. In another embodiment the property might be that the ability to resolve in the rotational degrees of freedom be improved while simultaneously minimizing the differences between the resolving powers in the translational degrees of freedom.
Sampling Probes from a Distribution
In some embodiments, the probe placement module 408 can be configured to place probes on one or more interest points by sampling probes from a target distribution of probes. The target distribution of probes can include random variables corresponding to degrees of freedom associated with the pattern. For example, when an object associated with the pattern is allowed to move in three dimensions (e.g., translational movement), the target distribution can have three random variables: x coordinate, y coordinate and z coordinate (or other equivalent representations.) As another example, when a 3D object associated with the pattern is allowed to make a translational movement and rotational movement, the target distribution will have six random variables: x coordinate, y coordinate, z coordinate and three for rotation (e.g. pitch θp, roll θr and yaw θy).
In some embodiments, the probe placement module 408 can determine the target distribution using a TDC module 412. The TDC module 412 can be configured to determine the target distribution of probes based on features associated with the interest points. For example, the TDC module 412 can determine the target distribution based on one or more of, for example, the coordinate of the interest points, the perpendicular orientation associated with the interest points, and/or the rotation of the interest points.
In some embodiments, the TDC module 412 is configured to determine the target distribution such that the distribution of perpendicular orientations sampled from the target distribution is substantially balanced. For instance, suppose that the object of interest is a thin pipe. A set of points evenly distributed on the surface of such an object contain far more resolving information in the plane of its cross section as opposed to the longitudinal direction (e.g., along it central axis). Therefore, the target distribution for the object should be such that the set of probes drawn from the target distribution would in combination have a more equal resolving information in the cross sectional direction as the longitudinal direction. The majority of probe positions in such a set would be positioned toward the two ends of the pipe.
In some embodiments, the TDC module 412 is configured to determine the target distribution so that the target distribution has a similar support as the distribution of interest points. This can be important because, e.g., in these embodiments, the probe placement module 408 can be configured to sample the probes by re-sampling (e.g., importance sampling) from the existing set of interest points. To this end, the TDC module 412 can be configured to use a mixture model for both the interest point distribution and the target distribution, as discussed below.
In some embodiments, the TDC module 412 provides the target distribution to the PDM module 416, and the PDM module 416 is configured to draw samples from the target distribution to determine the location of probes.
In some embodiments, the FDC 414 module is configured to transform the x, y, z random variables into a new coordinate space. To this end, in some embodiments, the FDC 414 finds the principal 3D spatial axes using PCA without mean centering. This determines the 3D spatial coordinate system for the remainder of the process in this example. The coordinate system in this example is denoted (x,y,z), which is a rotation of the original Cartesian coordinate system denoted (x,y,z) such that the unit vectors for the new coordinate system in Cartesian coordinates are {circumflex over (x)}, ŷ, {circumflex over (z)}. In this example, the FDC 414 may not be configured to use mean centering because it may not be necessary to pick the axes in directions of maximum variance of resolving power. Rather, in some embodiments, it may be desirable to align the axes in the directions of maximum and minimum resolving power (e.g., to choose a balanced set of probes later). In other words, the FDC 414 in this example can be configured to find the rotation of the coordinate system whose first axis is orientated in the direction of maximum resolving power for the object (principal direction). By definition, one of the other two axes will be in the direction of minimum resolving power, and thus the probe placement module 408 will later be able to select probes sites that tend to increase the overall resolving power in this direction (e.g., at the expense of resolving in the principal direction). In some other embodiments, this process can also be performed with mean-centering.
In some embodiments, once the probe placement module 408 determines the axes that will define the probability distribution, the probe placement module 408 projects out points onto this space before fitting to a distribution. For example, for a single point, its feature vector would be:
For consistency with the 2D examples discussed above, xi can be considered a measure of the point's contribution to the ability to resolve the object in the x direction, yi is the measure in they direction, and zi the measure in the z direction.
Target Distribution Computation
In some embodiments, when an object is to be aligned using three degrees of freedom (e.g., translational movement in three dimensions), it may be desirable for the TDC module 412 to determine a weighting function ƒ(x,y,z) that satisfies the following relationships:
where i indexes the ith interest point. The objective of this optimization routine is to identify a function ƒ(x,y,z) that equates (1) the weighted summation of feature vectors' x-components measured at the interest points and (2) the weighted summation of feature vectors' y-components measured at the interest points, and (3) the weighted summation of feature vectors' z-components measured at the interest points.
In some embodiments, once the TDC module 412 determines the weighting function ƒ(x,y,z), the TDC module 412 can provide the weighting function ƒ(x,y,z) to the PDM module 416. In some embodiments, the weighting function may take the form of a probability distribution which the PDM module 416 can use to place the probes on one or more interest points. Since the PDM module 416 in this case uses the weighting function ƒ(x,y,z) as a probability distribution from which to sample probes, it must be constrained to be non-negative and can be positive at least for some of the supported domain. The target distribution can be the probability distribution here denoted ƒ(x,y,z).
In some embodiments, the weighting function is used to weight an existing set of probes chosen through some other means, to affect their relative importance in such a way as to minimize:
In some embodiments, when a pattern has six degrees of freedom (e.g., translational movement and rotational movement in three dimensions), the TDC module 412 can incorporate, into the target distribution, three rotational variables θp, θr and θy corresponding to a rotational movement. The TDC module 412 can define the rotational variables θp, θr and θy with respect to an origin and set of axes.
In some embodiments, to apply a balancing technique to the three rotational degrees of freedom, the center and axes of rotation are found. For example, the probe placement module 408 can be configured to find the center of rotation by finding the point that minimizes the sum of the rotation moments of the normal vectors and then finds the individual axes using the same criteria.
For example, as illustrated in
[ni×(pi−c)]
Thus, to find the center of rotation, the techniques can minimize:
Σi∥ni×(pi−c)∥=Σi[ni×(pi−c)]T[ni×(pi−c)]
Setting:
The previous equation can be re-written:
Σi[pi−c]TNiTNi[pi−c]
Which after differentiating with respect to c and setting to zero yields the following solution for the center of rotation:
c=[ΣiNiTNi]−1[ΣiNiNiTpi]
Now, with the center of rotation c, the moment of the normal vector ni about the rotational axis given by a=bt+c is given by:
b·[ni×(pi−c)]
The axes of rotation can therefore be found by finding the null space of the symmetric matrix given by:
Σi[ni×(pi−c)][ni×(pi−c)]T
However, it may be the case that there are objects that are largely rotational symmetric (e.g. the image in
where ai lies on the proposed principal rotational axis (as illustrated in
In applications where an alignment model is being trained from an image recorded from a single field-of-view, curved surfaces may have horizon points apparent to the imaging device. For example, only a fraction of a cylinder's surface may be visible to a camera. Placing probes close to these horizon edges is not very desirable. For example, if the cylinder is rotated about its central axis, all the probes along one bottom edge will disappear from view. Since an alignment algorithm will likely be searching over rotational as well as translational degrees of freedom, in some embodiments, it can be desirable to have as many of the probe sites be visible across the entire search range as possible.
In some embodiments, horizon points can be removed from consideration when selecting probe sites. In some embodiments, one or both of two conditions can be used to determine if a point is in fact a horizon point. For example, with reference to
In some embodiments, once the center of rotation c and rotational axes are determined (parameterized by their respective unit vectors {circumflex over (r)}θ
θpi={circumflex over (r)}θ
θri={circumflex over (r)}θ
θyi={circumflex over (r)}θ
In some embodiments, the rotational variable θpi can take into account the norm of the distance between the point and the rotation axes, i.e. vector dθ
the TDC module 412 can emphasize the contribution of interest points that are further away from the origin in order to increase the angular precision. For example, the TDC module 412 can define the rotational variable θpi for the ith interest point as follows:
The rotational variable θpi that depends on the norm of the position vector vi can provide a target distribution that would favor placing probes at locations further away from the axes of rotation. This way, the target distribution can cause more probes to be sampled in interest points further away from the center of rotation.
In some embodiments, once the TDC module 412 determines the representation for the rotational variable, the TDC module 412 can use the determined representation to represent each of the interest points. Subsequently, the TDC module 412 can be configured to determine the target distribution based on the representation of the interest points by finding a weighting function ƒ(x,y,z,θp,θr,θy) that satisfies the following relationships:
with the constraints that:
where i indexes the ith interest point. This can have the effect of jointly balancing the ability to resolve the part in both translational and rotation degrees of freedom.
In some embodiments, the TDC module 412 can be configured to determine the target distribution based on the representation of the interest points by finding a weighting function ƒ(x,y,z,θp,θr,θy) that jointly balances the resolving ability in the translational degrees of freedom while maximizing the resolving ability in the rotational degree of freedom that is found to have the least resolving information using the full set of interest points, i.e. pitch if Σiθpi>Σiθri and Σiθpi>Σiθy, yaw if Σiθyi>Σiθri and Σiθyi>Σiθpi, otherwise roll. This may be advantageous under conditions where, for example, one rotational variable is small causing the previously described optimization to reduce the discrepancy between the three rotational variables by minimizing the contributions of other two. This can have the undesirably effect of placing most of the probes near the center of rotation.
In some embodiments, the TDC module 412 can be configured to determine a weighting function ƒ(x,y,z,θp,θr,θy) that balances the resolving ability in the translational degrees of freedom while maximizing the resolving ability in the rotational degree of freedom by carrying out the following optimization:
with the constraints that:
and where the parameters wS and wR prescribe a relative bias in the optimization between the minimization of the difference between the translational components and the maximization of smallest rotation component.
In some embodiments, once the TDC module 412 determines the target distribution ƒ(x,y,z,θp,θr,θy), the TDC module 412 can provide the target distribution ƒ(x,y,z,θp,θr,θy) to the PDM module 416. Subsequently, the PDM module 416 can use the target distribution ƒ(x,y,z,θp,θr,θy) as a probability distribution to sample probes on the pattern.
In some embodiments, to facilitate the above optimization process, the probe placement module 408 can assume a functional form for the target distribution ƒ(x,y,z,θp,θr,θy).
In some embodiments, the probe placement module 408 can assume that the target distribution ƒ(x,y,z,θp,θr,θy) has a linear form. Although a linear function can become negative, the constraint ƒ(xi,yi,zi,θpi,θri,θyi)≥0, ∀i can force the target distribution to be positive at all interest points. When the target distribution ƒ(x,y,z,θp,θr,θy) has a linear form, the optimization routine for finding the target distribution can be configured to use the linear form. However, because the space of linear functions is limited, it may be difficult to find a linear function that satisfies all the constraints.
In some embodiments, the probe placement module 408 can assume that the target distribution ƒ(x,y,z,θp,θr,θy) has a non-linear form. When the target distribution ƒ(x,y,z,θp,θr,θy) has a non-linear form, the optimization routine for finding the target distribution may be configured differently to use the non-linear form. However, because the space of non-linear functions is wide, it may be easier to find a non-linear function that satisfies all the constraints.
In some embodiments, the TDC module 412 can set the target distribution ƒ(x,y,z,θp,θr,θy) as an inverse of an interest point distribution pp(x,y,θ|parameter). In this case, the TDC module 412 can receive, from the FDC module 414, the interest point distribution pp(x,y,z,θp,θr,θy), and indirectly determine the target distribution ƒ(x,y,z,θp,θr,θy) by computing an inverse:
When, for example, the target distribution ƒ(x,y,z,θp,θr,θy) defined as an inverse of an interest point distribution pp(x,y,z,θp,θr,θy), the target distribution ƒ(x,y,z,θp,θr,θy) will cause more probes to be sampled at locations with interest points that are relatively dissimilar compared to rest of the interest points.
In some embodiments, the FDC module 414 can model the interest point distribution pp(x,y,z,θp,θr,θy) as a mixture model. In some embodiments, the mixture model can include a Gaussian Mixture Model (GMM):
The GMM has four parameters: the number of Gaussian distributions N, the weight αk of the kth Gaussian distribution, the mean vector
In some embodiments, the FDC module 414 can estimate the number of Gaussian distributions N for the GMM by clustering the interest points and determining the number of clusters that best fit the interest points. For example, the FDC module 414 can perform a k-means clustering operation on the interest points to estimate the number of Gaussian distributions N.
The remaining set of parameters {αk,
As discussed above, the TDC module 412 can determine the target distribution ƒ(x,y,z,θp,θr,θy) by simply inverting the interest point distribution pp(x,y,z,θp,θr,θy). However, this target distribution ƒ(x,y,z,θp,θr,θy) may cause most of the probes to be placed on edges with the least common values of x, y, z, θp, θr, θy. For example, when an object is capable of making only 3D translational movements and the object is box shaped with rounded corners, this target distribution ƒ(x,y,z) may cause the PDM module 416 to sample the mostly around the corner locations. In such scenarios, an alignment model with probes placed only on the corner locations will be vulnerable to occlusion and noise.
To address such issues, in some embodiments, the TDC module 412 can transform the interest point distribution pp(x,y,z,θp,θr,θy) and invert the transformed interest point distribution to determine the target distribution ƒ(x,y,z,θp,θr,θp). This transformation may take the form of applying a smoothing kernel to pp(x,y,z,θp,θr,θy).
In some embodiments, the TDC module 412 can determine the target distribution by transforming the interest point distribution in ways other than performing an inversion. One such embodiment transforms the interest point distribution pp(x,y,z,θp,θr,θy|{αk,
For example, the TDC module 412 can denote:
with the constraint:
The minimization can reduce to a linear programming problem through the use of a Lagrange multiplier φ to form the Lagrangian:
In some embodiments, the relative weighting between translational and rotational components of the optimization can be set using a single parameter RBIAS and using the following formulas for the weights:
The effect of varying RBIAS on probe placement is illustrated in the examples shown in
In some embodiments, the TDC module 412 could solve the minimization with respect to using additional constraints. For example, the above-described technique does not prevent the transformed weights from turning negative, or prevent a large weight from being assigned to Gaussians that were estimated from small groups of interest points (e.g., whose original weights αk in the interest point distribution pp(x,y,z,θp,θr,θy) was small). The TDC module 412 can programmatically apply these and/or other constraints.
Also, in some embodiments, the TDC module 412 is configured to limit the amount an individual cluster may be over or under-represented in the final set of probes. This can be achieved by adding a set of constraints:
αkClim>>αk/Clim,∀k
where Clim is a constant that provides the limiting factor.
Examples of the effects of varying the limiting factor are illustrated in
In some embodiments, when the set of linear equations (e.g., formed by differentiation of the Lagrangian and equating to zero) produces a result with at least one weight αk violating a constraint, the TDC module 412 can be configured to iterate over all possible combinations of boundary cases, calculate the optimal remaining weights, and select the constrained minimum.
For example, the TDC module 412 can determine all possible sets of boundary conditions (e.g., {α0low}, {α0high}, {α0low, α1low}, {α0high, α1low}, . . . ) for the linear equations. Each set of boundary conditions may include boundary conditions for a subset of transformed weights . Subsequently, for each set of boundary conditions, the TDC module 412 can fix the value of a subset of weights to be the value of the corresponding boundary conditions, and solve the set of linear equations for the remaining free weights without boundary conditions. This way, the TDC module 412 can determine the global solution to the set of linear equations given the constraints by selecting, amongst the solutions under all possible sets of boundary conditions, the solution with the minimum score.
In some cases, when the number of Gaussian distributions in the GMM is greater than the number of dimensions in which the interest points lie, some of the parameters in the GMM may be linearly dependent. For example, mean vectors of Gaussian distributions may become linearly dependent when the number of Gaussian distributions is greater than the number of dimensions in which the interest points lie.
To address this issue, the TDC module 412 can be configured to regularize the parameters for the GMM, for example, using Tikhonov regularization. Should such an approach fail, the TDC module 412 can reformulate the optimization problem to minimize the following function
This new Lagrangian formulation seeks to maximize the resolving power in the rotational degree of freedom with the smallest fitted resolving power while constraining the solution to be perfectly balance in the translational degrees of freedom and the sum of the transformed weights to be 1.
In some embodiments, the TDC module 412 could directly find the weights that satisfy the Lagrangian relationship stated above. However, this relationship may not prevent the weights from turning negative, or prevent a large weight from being assigned to Gaussians that were estimated from small groups of interest points (e.g., whose original weights αk in the interest point distribution pp(x,y,z,θp,θr,θy) was small). The TDC module 412 can programmatically apply these constraints, as illustrated above. This is mathematically valid because the above Lagrangian relationship is quadratic in , so if one of the weights is negative, then the optimal value should lie on one (or more) of the boundary conditions.
In summary, in some exemplary embodiments, in order to identify parameters for the target distribution (x,y,z,θp,θr, αy) based on parameters of the interest point distribution pp(x,y,z,θp, θr, By) the TDC module 412 can use the following procedure:
Sampling of Probes from Target Distribution
Once the TDC module 412 determines the transformed interest point distribution (x,y,z,θp,θr,θy), the TDC module 412 can provide the transformed interest point distribution (x,y,z,θp,θr,θy) (or an inverse of the transformed interest point distribution) to the PDM module 416. Subsequently, the PDM module 416 can sample from the inverse of the transformed interest point distribution (x,y,z,θp,θr,θy) to determine the location of probes on one or more interest points in an image.
The TDC module 412 can be configured to choose the transformed interest point distribution (x,y,z,θp,θr,θy) such that the expected value of x, y and z with respect to the transformed interest point distribution (x,y,z,θp,θr,θy) are as similar as possible:
Importance sampling can be used to allow the PDM module 416 to draw samples from a target distribution by weighting samples drawn from another different distribution with the condition that the samples have similar support. In other words:
where Sprobes is the set of probes and SIP is a set of interest points. Therefore, the PDM module 416 can use this relationship to weigh samples drawn from the interest point distribution pp(s|{αk,
It is to be understood that the disclosed subject matter is not limited in its application to the details of construction and to the arrangements of the components set forth in the following description or illustrated in the drawings. The disclosed subject matter is capable of other embodiments and of being practiced and carried out in various ways. Also, it is to be understood that the phraseology and terminology employed herein are for the purpose of description and should not be regarded as limiting.
As such, those skilled in the art will appreciate that the conception, upon which this disclosure is based, may readily be utilized as a basis for the designing of other structures, methods, and apparatus for carrying out the several purposes of the disclosed subject matter. It is important, therefore, that the claims be regarded as including such equivalent constructions insofar as they do not depart from the spirit and scope of the disclosed subject matter. For example, some of the disclosed embodiments relate one or more variables. This relationship may be expressed using a mathematical equation. However, one of ordinary skill in the art may also express the same relationship between the one or more variables using a different mathematical equation by transforming the disclosed mathematical equation. It is important that the claims be regarded as including such equivalent relationships between the one or more variables.
Although the disclosed subject matter has been described and illustrated in the foregoing exemplary embodiments, it is understood that the present disclosure has been made only by way of example, and that numerous changes in the details of implementation of the disclosed subject matter may be made without departing from the spirit and scope of the disclosed subject matter.
Number | Name | Date | Kind |
---|---|---|---|
6765570 | Cheung | Jul 2004 | B1 |
7016539 | Silver | Mar 2006 | B1 |
8259998 | Okugi | Sep 2012 | B2 |
8705846 | Ishigami | Apr 2014 | B2 |
20070086658 | Kido | Apr 2007 | A1 |
20090310828 | Kakadiaris | Dec 2009 | A1 |
20100079741 | Kraehmer | Apr 2010 | A1 |
20100259537 | Ben-Himane | Oct 2010 | A1 |
20100298705 | Pelissier | Nov 2010 | A1 |
20110205338 | Choi | Aug 2011 | A1 |
20130187919 | Medioni | Jul 2013 | A1 |
20140043329 | Wang | Feb 2014 | A1 |
20140105506 | Drost | Apr 2014 | A1 |
20140267623 | Bridges | Sep 2014 | A1 |
20140285619 | Acquavella | Sep 2014 | A1 |
20150130906 | Bridges | May 2015 | A1 |
20150213617 | Kim | Jul 2015 | A1 |
20160055268 | Bell | Feb 2016 | A1 |
20160216107 | Barker | Jul 2016 | A1 |
20170164848 | Nadeau | Jun 2017 | A1 |
20170243352 | Kutliroff | Aug 2017 | A1 |
20180046885 | Barker | Feb 2018 | A1 |
20180150974 | Abe | May 2018 | A1 |
Number | Date | Country |
---|---|---|
1193642 | Apr 2002 | EP |
Entry |
---|
Michael E. Weiser et al. “Projection model snakes for tracking using a Monte Carlo approach”; Journal of Electronic Imaging vol. 13, No. 2, pp. 384-398, published in Apr. 2004; XP001196026. |
Behrens, A. and Röllinger, H., “Analysis of Feature Point Distributions for Fast Image Mosaicking Algorithms,” Acta Polytechnica Journal of Advanced Engineering, vol. 50, No. 4, pp. 12-18 (Jan. 2010) (8 pages). |
Extended European Search Report issued by the European Patent Office for European Patent Application No. 16152487.1 dated Jun. 24, 2016 (12 pages). |
Nistér, D., et al., “Visual Odometry for Ground Vehicle Applications,” Journal of Field Robotics, vol. 23, No. 1, pp. 3-20 (2006). |
Number | Date | Country | |
---|---|---|---|
20180046885 A1 | Feb 2018 | US |