METHOD AND APPARATUS FOR INSPECTING THE SURFACE OF ORKPIECES
Field of the Invention The present invention relates to machine vision systems, and more particularly to a method and apparatus for determining the physical characteristics of the surface of workpieces, particularly ceramic tiles.
Background of the Invention It is well known during the manufacture of ceramic tiles, for example, a number of factors may contribute to a defective surface of the tile. Typical defects are warps in the body of the tile and roughness of the tile surface caused by defective polishing, grinding or moulding. In addition, some designs of tiles may include a degree of surface roughness for cosmetic reasons, but it is important in the manufacturing process to ensure that the roughness is kept within tolerated variation.
More particularly, it is well known to use structured light in the field of optical ranging, encompassing techniques such as triangulation ranging and Moire fringe analysis. In triangulation ranging, a pattern of light is projected from a light source onto the object. An image of the reflected pattern is obtained from a camera placed at a different angle of view to that of the light source. Deviation in the pattern corresponds to displacements in depth relative to the
angles of view of the light source and the camera. In a typical application, a workpiece is moved through the projected pattern so that range samples can be obtained along the workpiece. Structured light projectors as light sources are widely available. A typical such projector consists of a low-power laser emitting light through a slit, and a cylindrical lens is used to form a sheet of light, which reflects off the surface of the object to form a curved stripe pattern. The curvature of the pattern, when viewed from a different angle of view, provides information regarding variations in the range (distance) from the viewpoint to a point on the pattern. One characteristic of this approach is that at each instant in time, a two- dimensional area must be imaged, and the image processed to find the pattern as the workpiece moves under the projected pattern. There are consequent trade-offs between object speed, image size and resolution, angles of projections and view, exposure time, illumination power, and the accuracy of the estimated range. A typical example is to use high-speed analogue or digital signal processing for a small (hundreds of pixels square) image so that image frames can be processed at a rate of hundreds or thousands per second. For example, if the workpiece is moving at a rate of one metre per second, and if it is desired to sample the range variation at a resolution of 0.5 millimetre, it is necessary to process two thousand two-dimensional images per second.
In some applications, this solution is not suitable because a large image (thousands of pixels square) is required to subtend the workpiece at the
required resolution, and it is not feasible to process such large images at the rate required. Therefore, in applications of this type in which structured light is not used, it is common to use line-scan cameras, either synchronising line acquisition with conveyor belt movement, or using a free-rurining camera above a belt moving at a precise constant speed. The fact that only a line is sampled instead of an area of pixels has hitherto ruled out the use of line-scan cameras in structured light applications.
Another type of line-scan sensor is known as a Time-Delay Integration (TDI) sensor. A TDI sensor consists of a number of rows R (typically from 32 to 96) of photosensitive sites ("photosites"). Each row may contain a number C (say from 1024 to 4096) of such sites. The sensor is placed in such a way as to subtend the width of the object as it moves under the sensor, thus scanning the object in its entirety. In a TDI sensor, all rows are exposed at the same time, but at each line interval, the charge in each row of photosites is shifted to the next row in a given direction and added so that the charge accumulates in successive photosites along each column. If the rate of this row transfer (the "transfer rate") is synchronised precisely with the movement of the workpiece, and if the movement of the workpiece is precisely orthogonal to the rows of photosites, a given point on the workpiece will be exposed repeatedly as many times as there are rows in the TDI sensor. The effect on this repeated exposure and accumulation is to greatly increase the sensitivity without degrading image quality and resolution, while retaining the high speed and large linewidth of line-scan acquisition. Furthermore, random
noise in the image is reduced by approximately the square root of R (the number of rows). There is a time delay between the moment a line of pixels is exposed to the moment it is outputted from the camera, during which the exposure has been integrated R times, hence the name time-delay integration. TDI cameras using the TDI sensors are widely available, and a method as just disclosed is found in, for example, U.S. Patent Nos. 4,922,397 and 5,040,057 as well as in U.S. Patent Nos. 4,314,275, 4,382,267 and 4,952,809.
Summary of the Invention It is an object of the present invention to create a method that is capable of measuring the surface planarity and roughness of a ceramic tile product (the "workpiece") quickly, and more efficiently than hitherto known.
According to one aspect of the present invention there is provided a method of determining physical characteristics of the surface of a workpiece, comprising passing the workpiece below a structured light beam, and utilising a time delay integration camera to capture the structured light reflected from the surface of the workpiece.
According to another aspect of the present invention there is provided an inspection apparatus to determine the physical characteristics of the surface of a workpiece, comprising light source means for emitting a structured light beam onto a workpiece arranged to pass under the light source, and a time delay integration camera located to capture structured light reflected by the surface of the workpiece.
When using a TDI sensor or camera according to prior techniques as described above, it is necessary to carefully arrange the camera, illumination, and workpiece so that successive exposures will preserve the consistency of viewing conditions. Normally this is accomplished by synchronising the movement of the object with the transfer rate of the TDI sensor.
By contrast, the present invention deliberately, but systematically, disrupts the viewing conditions during scanning. Structured illumination in the form of a sheet of light is projected onto the workpiece and reflects onto the photosites of the TDI sensor. As the workpiece moves through the stripe synchronised with the row transfer within the sensor the charge transferred from one row to the next is systematically related to the distortion of the stripe due to changes in surface image. Therefore, the output of the camera will not be the result of successive exposure of similar viewing conditions, but will instead be the accumulation of the effect of distortion in the illuminated stripe. Because the distortion of the stripe is caused by variation in range to points on the object, the variation in pixel intensity will correspond to variation in range from the camera to a corresponding point on the object. Therefore, the image produced by the system, in which variations of brightness correspond to variations in surface profile and roughness of the workpiece, is for convenience referred to as a "structogram" which is not a recognised optical term, but one evolved by the applicant for the purpose of clarity of this description.
The present invention requires that the recommended usage of the TDI camera, namely that viewing conditions are to remain constant during exposure, be violated in a systematic manner in order to encode information about the distance from the sensor to points on the workpiece. Therefore, the TDI camera is employed in a way hitherto undisclosed, namely that accumulated exposure of a column of photosites is directly affected by the distortion of the reflected pattern of structured illumination that occurs when the surface of the object is not flat. US Patent 5,668,887 also discloses an arrangement based on a combination of TDI camera and structured light in which the TDI camera is deliberately not synchronised to the speed of the web. Because the effect of the lack of synchronisation is to smear the image, that arrangement is designed to emphasize longitudinal streak imperfections in a paper or fabric web, and is not designed to provide information about range (distance) variations and does not therefore provide information regarding range information such as a planarity and roughness of the observed surface.
After a workpiece is scanned using the present combination of structure light and a TDI camera in accordance with the present invention, the result is an image (structogram) of the tile in which variations in brightness correspond to the surface relief of the tile. The variations in brightness do not correspond linearly to the range to the surface from the camera, but correspond in a nonlinear manner to the partial derivative of surface range with respect to an axis parallel to the direction of tile movement. Using assumptions that apply in
practice, it is possible to process the stractogram to solve for an estimate of the range to each point on the surface of the tile. Alternatively, the variations in structogram brightness may be used directly to measure surface planarity and roughness relative to a known sample. In a first embodiment of the present invention a method of the tile inspection requires:
1. A workpiece which is known to be free of defects to be placed on the conveyor belt so it may be inspected by the light source/camera combination in a training mode. The training mode provides the system with a reference structogram against which structograms of production workpieces are compared in turn. Alternatively, it is possible to store reference structograms, thereby forming a data base of samples taken from different batches of workpieces.
2. Production workpieces fed onto the conveyor belt, are inspected by the system, and resulting structograms are compared with the reference structogram. If a production structogram is in excess of the reference structogram by more than given tolerances, the workpiece is reported as a reject. Otherwise the workpiece is reported as normal.
In a second preferred form in accordance with the present invention a plurality of reference structograms previously obtained from workpieces of different types, and stored in the memory of the control processor, are retrievable individually from the memory data base, thereby providing the
system with preset references against which production workpieces of a selected type may be compared at will.
The present invention advantageously utilises a TDI line-scan camera in such a manner as to obtain the image necessary for estimating the range to the surface from the camera; an area-scan camera is not required. This is advantageous because it is not necessary to process a large two-dimensional image to recover stripe shape information at each incremental step of workpiece movement.
Furthermore, range information can be obtained in real time (limited by the conveyor speed) because immediately each image row is outputted from the camera in the form of an electrical signal, the stractogram image has encoded information that can be used to estimate range directly.
Brief Description of the Drawings An embodiment of the present invention will now be described by way of example with reference to the accompanying drawings in which:
Figure 1 illustrates an apparatus mounted over a conveyor belt; and Figure 2 illustrates an optical path of a structured light and TDI sensor.
Detailed Description of the Preferred Embodiments
One embodiment in accordance with the present invention will now be described with reference to Figures 1 and 2.
In Figure 1 there is shown an apparatus 1 comprising an elongate conveyor belt 2 arranged to extend through a rigid support frame 3 which supports a Time Delay Integrated (TDI) camera 4 and a light source or projector 5, both spaced from the conveyor belt by an amount which at the very least allows a workpiece 6, such as a ceramic tile, to pass on the conveyor belt 2 beneath the camera 4 and light source 5.
A control processor 7 is conveniently mounted on a base 8 of the support frame 3. The control processor 7 is connected, although not illustrated for clarification purposes, by electrical connections of any form to the camera 4, light source 5 and the conveyor belt 2 via a shaft encoder 9 located at one end 10 of the conveyor belt to control the speed of movement of the conveyor belt.
When a workpiece 6 is located on the conveyor belt 2 the workpiece is moved by the conveyor belt past the light source 5. As clearly shown in Figure 2 the light source 5 emits a diverging sheet of light 15 from a narrow slit 16 extending diametrically across the output surface of light source 5. The emitted light beam is therefore a structured light beam and falls onto the workpiece as a strip of light 17. An image pattern (known as a stripe) is reflected from the workpiece to be received by camera 4 which is located to optimise the light reflected from the workpiece 6.
The light source 5 is adjusted on the support 3 to project the sheet of
light 15 at an angle α relative to an imaginary line extending perpendicularly
through the workpiece at the point of intersection of the light beam 15 with the workpiece. The camera 4 is located on an opposite side of the support 3 and focussed on the point of intersection of the light beam 15 with a workpiece to receive a reflected light beam 18 also at an angle α. relative to
the above mentioned perpendicularly extending imaginary line.
More particularly, camera 4 comprises a lens 20 which is arranged so as to focus the stripe 17 onto an array of photosensitive sites 21 (photosites) to produce an image 22 of the stripe pattern upon the photosites. Such image 22 is usually referred to as a structogram. By using an apparatus such as that just described it is possible to monitor or sense the physical characteristics of the surface of the workpiece 6 such as the planarity and roughness of the workpiece as the workpiece is moved through the field of view of the camera 4.
Because of the consistency of the stripe 17, a constant value is accumulated by the TDI camera 4, and the resulting structogram image data
•contains constant pixel values. In practice there will be a small variation in pixel values do to random scattering illumination and variations on the performance of the optical and electronic apparatus in the camera, but within given tolerances the image can be assumed to be constant. When an imperfect workpiece is placed on the conveyor belt 2 and the workpiece passes through the field of view of the camera 4, the stripe 17 will be distorted in a systematic manner that depends on the surface topology. As the workpiece passes under the stripe 17, the shape of the stripe will change at
a speed depending on the surface topology and the speed that the workpiece is being transported by the conveyor belt. The key principle is that the TDI camera will be integrating an image at the time during which the stripe is undergoing distortion, the change in shape causing non-constant integration of the image in a non-linear proportion to the amount and speed of distortion. A theoretical model that expresses the image intensity I(x) at point x resulting from surface shape is as follows:
I(x) Qc E(x) dt oc (1 + tan A tan Theta) dx/m
where E is exposure at point x, A is the angle of incidence of the structured light sheet (a constant measured from the surface normal), Theta is the surface slope (measured from the horizontal), and m is the magnification (a constant determined by the focal length of the camera).
Therefore, product inspection apparatus and the method of inspection of the product in accordance with the present invention advantageously utilise a reference structogram image of a defect-free master workpiece, which is then compared directly with the structogram image of a production workpiece to obtain a measure of error, if any, between the two structograms.
If an error occurs between these structograms the difference signal is utilised in a known manner to instruct a sorting apparatus, not shown, to divert that particular workpiece to an imperfect workpiece bin.
Furthermore, the error signal can be correlated with human judgements of deviation from the defect free workpiece and it is therefore not necessary to obtain an absolute depth map from the structogram.
Conveniently, the light source 5 may comprise a laser, light emitting diode(s), a fluorescent lamp, or an incandescent lamp. Moreover, the slit 16 which is more suitable for use with a laser may be replaced by any other shaped opening suitable for the purpose of producing structured light. Conveniently the fluorescent can be a fluorescent strip lamp to provide the structured light source. Alternatively, the structured broad-spread sheet of light can be provided with the use of optical lenses, such as a cylindrical lens.
In an alternative embodiment of the present invention an algorithm may be specified from recovering a metric profile from the reference structogram image data. This algorithm converts each basic image pixel into a relative profile measurement (for example, relative height of each sampled point on the surface) by low-pass filtering the image to reduce noise, and integrating the structogram pixel values along the direction of workpiece movement profile recovery algorithms required for converting the measured image into height information are not unrelated to phase unwrapping, a technique known to practitioners of interferometry. This is not a precise comparison because the images obtained are not interferograms and therefore do not exhibit the discontinuities that occur in interferograms when phase changes by a multiple of 2 pi. However, like phase unwrapping, the profile recovery algorithm is sensitive to noise, and error propagates through the data. Also like phase unwrapping, there is no general solution to the problem and therefore the performance of the profile recovery algorithm depends on image quality. In turn, image quality depends on embodiment details such as the relative
locations of the projector and sensor, the speed of movement of the workpiece, the intensity and shape of the projected illumination, and the row transfer frequency of the TDI camera. The present invention does not exclude embodiments that contain the method step of calculating the metric profile from the raw structogram data.