ASTIGMATISM MEASUREMENT APPARATUS AND METHOD

Abstract: A computer (30) receives image data from a star-shaped optical target (18) in the object plane and calculates angle-dependent boundary sharpness. The horizontal, x-direction, amplitude derivative and the vertical, y-direction, amplitude derivative are computed over a portion of each star pattern image from a Z panning sequence (83). A microscope slide stage (16), carrying the target (18), is moved vertically from a level just below where the target is in focus to a level just above where the target is in focus. For each small increment of vertical motion, Z panning, an image of the star pattern is captured for analysis (85, 86, 89). Computations are performed on the differentiated images to search for evidence of elongation of the point spread function and variation with stage Z position of the angle of long axis of such an out-of-round point spread function (134). The presence of a distorted point spread function that varies along the optical axis indicates astigmatism (136).

Description: ASTIGMATISM MEASUREMENT APPARATUS AND METHOD This invention relates to a method and apparatus to measure astigmatism in an optical path and more particularly to a method and apparatus that uses a computer based imaging system to measure focal plane separation as a measure of astigmatism. BACKGROUND OF THE INVENTION An ideal optical path, such as a system of lenses for a microscope, would provide undistorted magnification of features in the object with uniform resolution over an entire field of view. However, practical lenses, mirrors, and camera systems introduce aberrations that cause the image resolution to vary over the image plane. One such well known aberration is astigmatism. Astigmatism is defined as the presence of separate focal lengths, along the principal axis, for rays of light traveling in different rotational planes through the optics system. Optical paths of all types suffer from astigmatism. A method is needed to measure the severity of this aberration so that optical paths that are excessively degraded by astigmatism can be repaired or adjusted. Therefore, the invention provides an automated system that measures astigmatism in an optical path and provides an optical quality signal to alert other system components that the optical path is so effected. SUMMARY OF THE INVENTION The invention provides a method for evaluating a condition of an optical system. The method of the invention acquires a plurality of images of a test pattern at different focus positions. The method of the invention then computes a plurality of center of gravity vectors, one center of gravity vector for each one of the plurality of images. The method of the invention then computes a focal plane separation from the plurality of center of gravity vectors and relates the condition of the optical system to the focal plane separation. The invention provides an apparatus and method for the measurement of astigmatism in at least one optical element in an optical path. An optics mount holds the optical elements. An objective lens is disposed to receive an image from the optical path. An optical stage holds a test pattern in view of the objective lens wherein the objective lens receives an image of the test pattern. A stage drive is attached to move the optical stage, wherein the optical stage drive has a positional control input . A test pattern illuminator is disposed to illuminate the test pattern. A video camera views the test pattern image through the optical path and generates a video signal . Image acquisition electronics are connected to the video signal . The image acquisition electronics have a digital image output . An image analysis computer is connected to receive the digital image output and analyze the test pattern image to determine astigmatism in the optical path. A computer processor controls the stage drive. In one embodiment, the apparatus of the invention further provides a control signal indicative of image degradation by astigmatism for instrument quality control . Other objects, features and advantages of the present invention will become apparent to those skilled in the art through the description of the preferred embodiment, claims and drawings herein wherein like numerals refer to like elements. BRIEF DESCRIPTION OF THE DRAWINGS To illustrate this invention, a preferred embodiment will be described herein with reference to the accompanying drawings. Figures IA and IB show an illustration of paraxial astigmatism in an optical path. Figure 2 shows an example of the effect of paraxial astigmatism on a point spread function. Figure 3 shows an apparatus of the invention for testing an optical property of an optical path. Figure 4 shows one method of the invention to test an optical property of an optical path. Figure 5A shows the method of the invention to find the test pattern center. Figure 5B shows a calibration plate test pattern. Figure 5C shows a thresholded image. Figure 5D shows a closing residue image. Figure 5E shows a diagonal erosion image . Figure 5F shows a final test pattern image center. Figure 6A shows the method of the invention to calculate the quality of focus. Figure 6B shows a graph of horizontal filter frequency response . Figure 6C shows a graph of horizontal filter impulse response. Figure 6D shows a graph of vertical filter frequency response. Figure 6E shows a graph of vertical filter impulse response. Figure 7A shows image acquisition and filtering steps of the invention. Figure 7B shows an X gradient test pattern image. Figure 8A shows an example of image analysis steps of the invention. Figure 8B shows an example of the boundary angle region analysis method of the invention. Figure 8C shows an example of a set of boundary angle regions for a test pattern. Figures 9A and 9B show one embodiment of focal plane separation steps of the invention. Figure 10 shows a mean residue versus boundary angle plot. Figure 11 shows an overall mean residue versus Z coordinate plot. Figure 12 shows a plot of the magnitude of the center of gravity versus Z coordinate. Figure 13 shows a plot of the angle of the center of gravity versus Z coordinate . Figure 14 shows a plot of MAG{z,θ) for two dominate angles . Figures 15A and 15B show curve fitting plots for two dominate angles. Figure 16 shows a surface map of the mean residue as a function of stage elevation and test pattern boundary angle. Figures 17A, 17B and 17C show a more detailed schematic of an astigmatism measuring apparatus employed by the invention. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT Figures IA and IB show an example of paraxial astigmatism. Figure IA shows an overhead view of an optical path wherein a lens 40 focuses light rays 41 and 43 through aberrating optical element 42 to focal point 52. Aberrating optical element 42 is shown in the XZ plane resulting in distortion in the XZ plane. Focal point 52 falls on focal plane 44. Figure IB shows a side view of the optical path of Figure IA wherein the lens 40 is focusing light rays 45 and 47 through aberrating optical element 42 to focal point 54. Aberrating optical element 42 is shown in the YZ plane in Figure IB. No distortion is present in the YZ plane. Focal point 54 falls on focal plane 48. A separation distance 50 between focal plane 44 and focal plane 48 is defined as the paraxial astigmatism. Figure 2 shows the effect of paraxial astigmatism on a point spread function of the optical system of Figures IA and IB. Outline 70 shows an overhead view of an XZ cross section of a point spread function of a typical optical path. Outline 72 shows a side view of the ZY cross section of the point spread function. Three example cross sections, where the cross sections are taken in the XY plane, are shown. Cross section 71, taken in plane 74, shows the plane of best focus for the ZY plane. Cross section 75, taken in plane 78, shows the plane of best focus for the ZX plane. The best focus plane for a given axis is defined as the plane where the point-spread function is the smallest. Astigmatism in the optical path is one cause of differing planes of best focus for different axes. As a result, there exists a plane where the point-spread functions for each axis, even though not at a minimum for either, creates a "plane of least confusion" 76. The plane of least confusion 76 is defined as the plane where the point spread function 73 is the same for both the ZX and ZY planes . Figure 3 shows a schematic diagram of one example of the astigmatism measurement apparatus of the invention. The optical path to be measured includes complex optical path 24 and objective 22. In one example embodiment the objective may comprise a 4x objective. Drive system 20 is connected to stage 16. Stage 16 holds a test pattern 18 illuminated by light source 12 through condenser 14. Objective 22 views test pattern 18 and sends light rays through complex optical path 24. Video camera 26, connected to image acquisition electronics 28, receives the light rays and converts them into electronic signals for processing by an image analysis computer 30. The image analysis computer 30 is connected to image acquisition electronics 28. Host processor 32 controls motor control electronics 34 that control the drive system 20. Refer now to Figure 4 which shows a process flow diagram of one method of the invention to measure astigmatism. The system 10 is initialized in step 82. Limits for panning in the Z axis are established in step 83. The center of the test pattern is found in step 84 and in steps 85, 86, 87 and 89 the image of the test pattern is analyzed by host processor 32. A check is made in step 87 to determine whether or not a predetermined requested number of images have been collected and analyzed. If the conditions of step 87 are met, the process flows to step 88 to find the focal plane separation. Otherwise, the process flows to step 89 to move the stage. In step 88 the focal plane separation, and thus the astigmatism of the optical system, is found. During the step 83 of initializing the system the lens turret 23, shown in Figure 17C, is rotated to bring the 4X objective into alignment with the optical axis of the automated microscope 502. The test pattern 18 is also moved into the optical path. The stage 521 is moved to an initial location in X, Y and Z that was previously determined during system calibration according to the method described below. The initial location delivers a focused image of the test pattern 18 approximately centered in the field of view. Refer now to Figures 5A-5F which illustrate the method of the invention for initially finding the center of the test pattern 18 in X, Y and Z Cartesian coordinates during system calibration. These steps are preliminary to step 84 where a more exact center of the test pattern 18 is found. The test pattern 18 is shown in Figure 5B as a star pattern but those skilled in the art will recognize that other patterns may be used. An original gray scale image 170, shown in Figure 5B, is acquired at step 140 by the image acquisition electronics 28. In step 142, the original gray scale image 170 is thresholded to create a binary thresholded image 172 as shown in Figure 5C. In step 144, a morphological closing residue operation is performed on the binary thresholded image 172. A closing residue operation generates a closing residue image 174 as shown in Figure 5D. The closing residue image 174 of the thresholded image 172 identifies a possible area where the star arms converge in the center. The closing residue image 174 is then eroded by a diagonal bar slanted down in step 146 and eroded by a diagonal bar slanted up at step 148. The two images are exclusive ORed together at step 150. The resulting image represents the area around the possible star center. Using the above steps, the method of the invention has filtered out other images that may be misinterpreted as a star pattern such as a horizontal or vertical cross image. The diagonal erosion image is shown as image 176 in Figure 5E. Image 176 is then morphologically closed at step 152. The resulting image of step 152 is opened in step 154, and the resulting image of step 154 is closed again at step 156 to merge the image elements around the star element to one object while filtering out any noise. The resulting final image is shown as image 178 in Figure 5F. If there is a central region 179 left in the image 178 that fits within a range of empirically determined limits, the central region 179 represents the center of the star and the central region 179 iε defined as the center of the test pattern in step 158. Refer again to Figure 3 and Figure 4, in step 83 the best focus position for the calibration plate holding the test pattern image is determined. In order to establish the motion limits for a Z axis panning sequence a series of images of the test pattern 18 are acquired and examined for overall resolution. The position yielding the best overall resolution is chosen for the middle of the Z axis panning range. A series of images is then collected beginning at the lower limit of the stage 16 elevation and extending to the upper limit of the stage 16 elevation. The extent of the Z axis panning range will be about twice the depth of field of the optical path in use. Because the stage 16 is moved in the Z direction from a position below the calibration Z coordinate to a position above the calibration Z coordinate the pattern on the calibration slide 18 will pass through optimum focus. The quality of focus is measured for each of the images in this panning sequence and the Z-coordinate of the highest resolution image is recorded. The quality of focus measurement used at each Z position in the Z panning sequence is illustrated in Figure 6A. In step 202 a difference image is generated by subtracting the value of a given pixel from the value of the pixel to its immediate right in each original gray scale image 170. In step 204 a difference image is generated by subtracting the value of a given pixel from the value of the pixel immediately below the given pixel in each original gray scale image 170. The differences are referred to as "gradients". These operations are described by the following equations. The horizontal-displacement difference image is described by Grad x ti] [j ] = ABS{A [i+1] [ j ] - A [i] [j ] } . The vertical -displacement dif ference image is described by GracL i] [j ] = ABS{A [i] [j +1] - A [i] [j ] } , where ABS is the absolute value operator, i = image coordinate in the X- direction, j = image coordinate in the Y- direction, and A = image amplitude (integer pixel value) . A histogram is then calculated for each of the difference images, shown as steps 206 and 208. Each histogram is comprised of 256 bins, one bin for each possible integer pixel value. The value of the histogram for each bin is equal to the number of pixels having the amplitude assigned to that bin. Thus, two dependent variables, N x (A) and N Y (A) , are described by the difference-image histograms where "A" can take on any integer value from 0 to 255. Values for the resolution in the horizontal and vertical directions taken over the entire image are obtained in steps 210 and 212 by identifying the values of N x (A) and N y (A) that exceed a certain threshold, N τ , and accumulating a sum of products of the squares of the amplitudes and their respective pixel counts, as follows: 255 R x = Ε N χW * A l f° r al1 N xW > N τ > =0 and 255 R γ = Σ N * * A l f° r al1 N 1 > N τ ■ A=0 In step 214 a single, overall score for image resolution, R tot , is obtained by adding the two terms: R to = R x + R γ- τ he Z coordinate of the image with the highest R cot is defined as the Z coordinate with optimum focusing. Once the Z coordinate for optimum focusing of the test pattern has been found, the beginning and ending Z coordinates for panning during the astigmatism test are placed at 50 microns below optimum focus and 50 microns above optimum focus, respectively in one embodiment. This span, equal to approximately twice the depth of field of a 4X objective, for example, allows the astigmatism test to accurately measure focal plane separations as large as one depth of field of the objective. For the purpose of the astigmatism test of the invention the depth of field may advantageously be defined as the distance along the Z axis for which the diameter of the point spread function of the objective lens is less than twice the diameter of the point spread function in the focal plane. Refer again to Figure 4, in step 84 the star pattern from the calibration slide 18 is precisely centered. Before collecting the images for the astigmatism test of the invention, a series of images of the test pattern 170 are collected to more exactly center the test pattern in the image field. The microscope stage 20 is moved over a search pattern, such as, for example a star pattern, until the star pattern is approximately aligned to the center of the camera 26 image field. Image analysis is performed by the image analysis computer 30 to find a more exact center of the test pattern 18 in the digitized image. The more exactly computed center is used in the astigmatism measurement method of the invention. In one embodiment of the method of the invention, the more exactly computed center of the star pattern is found by first locating the calibration plate that contains the star pattern 18 in the center of the field of view of the imaging system as described above with reference to Figures 5A-5F. An image is obtained of the initially centered test pattern 18 and converted into a binary image, for example, where all pixels that have a value less than a threshold, such as the pixel value 128 out of a range from 0 to 255, are considered to be black pixels. A linear array is formed of the peripheral pixels of the image where the top, right, bottom, and left peripheral pixels of the image are assembled into a linear array. The linear array is then scanned for transitions from white to black where a black transition is defined as 5 consecutive black pixels in one example embodiment. This is to avoid noise contaminating the transition detection. The true position relative to the pixel array, of the transition is located in the image X, Y coordinates. These X, Y coordinates are stored in individual arrays X, Y for each transition. This process is continued until the entire linear array has been scanned for transitions. If more or less than 32 transitions are detected the test pattern center detection is considered as having failed. The test pattern center detection may fail due to dust on the image, incorrect initial centering of the test pattern or other optical problems, preventing the detection of transitions. A more exact center of the test pattern 18 is computed using a slope intercept method where the slope for each pixel is computed as the Y difference over the X difference, where the Y difference is the difference between the pixel and the 16th adjacent pixel, and the X difference is computed as the difference between the pixel and the 16th adjacent pixel. Sixteen is chosen because the sixteenth pixel will be on or near the same line if there are 32 transitions. Accordingly, slope[ϊ] = y[i] - y[f ÷ i6] [I] - x[i + 16] for i 1, . . ., 16. Next the image center is computed based on each line and the 8th adjacent pixel according to the following equation where the i+8 pixel is on a line perpendicular to the i th pixel according to the following relationship. center x[i] = ( slo e W **H ~ y H ~ (* /o * + 8 * x[i + 8] -y[i + 8]) (slope[i] - slope[i + 8]) for i = 1, . . . , 8 . The Y center is computed using the slope intercept. The next step of the invention calculates the mean for the centers according to the equation center. y[ϊ] = (slope [ϊ] * (center. x[i\ -x[i])) +y[ϊ\ , for i = 1, . . . , 8 . If the center is properly located, it will be within 10 pixels of the 256 x 256 point for an imaging array of 512 x 512 pixels because the center of the test pattern has been located during calibration. Next the computed center is evaluated according to its standard deviation. If the standard deviation of the computed center is greater than 5 pixels then the center is considered to have not been found. If it is less than or equal to 5 pixels then the center is considered to have been found. Typically the method of the invention locates the center with a .1 pixel standard deviation in one example embodiment. Those skilled in the art will recognize that the test pattern may have more than 32 lines in which case the collinear pixel will not be 16 element transitions away but will be the number of test line segments divided by two away. Those skilled in the art will also recognize that the orthogonal line will be the number of test line segments divided by four. Those skilled in the art will also recognize that an accurate center calculation will typically use at least the first one fourth of the number of test segments, although fewer may also be used. Refer now to Figure 7A which shows the image acquisition and filtering step 85 of the invention in more detail. In step 90 the stage is moved along the Z axis. In one embodiment of the invention a step size for stage movement was chosen to be a small fraction, about 5%, of the depth of field of the 4X objective lens to allow the focal plane separation to be measured with high accuracy. By way of example, and not limitation, a step size of 2 microns is used to span the 100 micron range of stage elevation using 51 images. In step 91 an image of the test pattern 18 is captured from the video camera 26 by the image acquisition electronics 28 and transferred into memory in the image analysis computer 30 for processing. The video camera 26, having been designed to comply with NTSC video format specifications, limits the bandwidth of the video signal such that the horizontal resolution of the image is worse than the vertical resolution. To compensate for the loss of high frequencies, each horizontal line in the stored image is convolved in step 92 with an edge enhancement filter kernel . The purpose of the edge enhancement filter step 92 is to increase the bandwidth in the horizontal direction to match that of the vertical direction. Ideally, the filter would exactly reverse the effect of the camera lowpass filter, and measurement of the camera filter gain and phase versus frequency provides a basis for the edge enhancement filter design. The inverse in complex arithmetic of the Fourier Transform of the camera lowpass filter is taken as the frequency response of a hypothetical inverse filter. However, the gain of the hypothetical inverse filter increases radically as frequency approaches the Nyquist limit imposed by the image pixel spacing. A first modification, then, is to reduce the gain very near the Nyquist limit by adding a fourth- order pole at 0.8 * f (Nyquist) . The filter then becomes realizable. However, the application of this bandlimiter introduces a discontinuity at the Nyquist limit. As a consequence, the impulse response of the filter, which will become the kernel for the convolution operation used to filter the image, expands. An inordinate number of points in the kernel would be required to apply this filter at the expense of computational speed. In one embodiment, the number of required points is reduced by truncating the kernel, which introduces ringing in the filter step response, and then trimming the coefficients by trial and error to reduce the ringing to an acceptable level . The final horizontal filter frequency response and impulse response are shown in Figure 6B and Figure βC respectively. In Figure 6B the dashed line 61 represents filter phase shift in radians. The solid curve 63 represents filter gain. The edge enhancement filter is implemented by the image analysis computer 30 in step 92. In step 93 a lowpass filter is applied in the vertical direction. Because of the upper-end cutoff installed in the edge enhancement filter, the image must be filtered in the vertical direction to accomplish the final horizontal- to-vertical bandwidth matching. The vertical filter is a simple Gaussian filter with a time constant of 0.718 pixel increments. The equation for the impulse response is gain = e '1 /.718 2 The vertical filter frequency response and impulse response are shown in Figure 6D and Figure 6E, respectively. Those skilled in the art will recognize that other methods of acquiring a digital representation of the test pattern image are within the spirit and scope of the invention. Refer now to Figure 8A which shows the image analysis step 86 of the method of the invention in more detail. At step 102 filtered images of the test pattern image are presented for processing. The method of the invention then computes the X Gradients and Y Gradients of the image in step 104 according to the gradient equations shown hereinabove with reference to Figure 6A. The gradient operators are 2 pixel structure differences along each axis. For each filtered test pattern image, an X Gradient and Y Gradient image is generated. An example of an X- Gradient image is shown in Figure 7B. Refer also to Figures 8B and 8C which show an example of the boundary angle regions used in the method of the invention. Because each test pattern center can be precisely located by the above described methods, the invention can divide the test pattern image into predetermined boundary angle regions. These boundary angle regions contain those pixels that qualify for further analysis. Figure 8B shows a quarter of the combined X gradient and Y gradient test pattern gradient image and Figure 8C shows the entire combined test pattern gradient . In Figure 8B each pixel falls into a particular region, called boundary angle regions 290, preassigned an angle designation based on the center angle from the horizontal 292. For example, the center 280 defines radians 252, 254, 256 and 258 which define boundary angles 262, 264 and 268. The boundary angle region φ n 262, between radians 252 and 254 and bounded by outer circle 278 with center 280 and inner circle 276 with center 280, contains the boundary angle pixels 270. The boundary angle region 264 φ n+1 , between radians 254 and 256 and bounded by outer circle 278 with center 280 and inner circle 276 with center 280, contains the boundary angle pixels 272. Likewise, the boundary angle region 268 φ n+2/ between radians 256 and 258 and bounded by outer circle 278 and inner circle 276, contains the boundary angle pixels 274. At step 106 the pixels are sorted into bins by boundary angle. Pixels outside a predefined ring, defined by inner circle 276 and outer circle 278, are discarded in step 108. Note that pixels very near the center of the image are ignored because the boundaries of the star pattern converge to dimensions too small to be properly represented by the pixel array. The gradient image is shown for the entire test pattern in Figure 8C. Example boundary angle regions 290 for the test pattern include the 0 radian angle 282, the π/2 radian angle 284 and the π radian angle 286. In step 110, pixels in the gradient image are tested against a threshold. Since the amplitude derivative of any given boundary is projected on to the X gradient by the cosine of boundary angle and onto the Y gradient by the sine of the boundary angle, the magnitude of the gradient is the vector sum of the X and Y gradients. This vector sum would normally be calculated as the square root of the sum of the squares of the X gradient and Y gradient. However, the square root operation can be avoided by comparing the sum of the squares to a value that is the square of a predetermined threshold according to the relationships if Grad χ [i] [j] 2 + Grad γ [i] [j] 2 < threshold 2 , then Grad χ [i] [j] = 0, and Grad y [i] [j] = 0. These low gradient values are suppressed for the purpose of increasing the signal-to-noise ratio in the residue calculations. In step 112, a summation is performed for each boundary angle region over the qualified set of pixels for that angle and normalized by dividing by the number of pixels contributing to a boundary angle region, N. The gradient values for each pixel in a boundary angle region are squared and summed in step 112 and divided by the number of pixels. The summations may be expressed as SUM x (ø) = ( Σ Grad x (i,j) 2 ) / N, SUM γ (ø) = ( Σ Grad y (i,j) 2 ) / N, where pixel [i,j] lies in the boundary angle region at angle ø. N equals the average number of qualified pixels contributing to a boundary region, this average taken over all the boundary regions in the test pattern image. The division by N serves to scale SUM x (ø) and SUM γ (ø) so that the residue value from the calculation that follows is of the same order of magnitude as the original image amplitude scale. In step 114 the mean residue for each boundary angle region is computed by combining the two summations in quadrature as follows MAG(ø) = JSUM χ (ø) + SUM γ (ø) , where MAG(ø) is defined as the magnitude of the residue for each boundary angle region ø. MAG(ø) is also called the residue value. In step 115 the set of residue values, one for each boundary angle, for the current image is stored for later use in the calculation of focal plane separation. The residue value, MAG(ø) , is an expression of boundary sharpness divided into boundary angle bins that cover the angles of the boundaries in the star pattern. In step 116 a reading of the overall image resolution is obtained by averaging over this array as meanRES IM, where M is the number of boundary angle regions. In step 117 the value of the Mean Residue for the current image is stored for use in normalizing the Center of Gravity Vector. This mean resolution estimate, meanRes, may be used to check the Z panning image sequence to assure that it encompasses the region around the best focus for the calibration plate. A plot of the Overall Mean Residue versus Z Position is shown in Figure 11 for one example optical system. Although the actual point spread function of the optical path is not directly measured, its shape can be inferred from the boundary-angle-dependent resolution measurements. The higher the residue value, the higher the resolution. If the resolution is independent of boundary angle, the point-spread function is round. If the horizontal boundaries are sharper than the vertical boundaries, the point-spread function is elongated and its long axis lies along a horizontal line. The long axis of the point spread function operative on a given image is oriented at the angle of the sharpest boundary. In step 118 the Center of Gravity (COG) Vector is a mechanism for expressing the eccentricity of the shape of the point spread function, which is carried by the magnitude of the COG vector, and the angle of the major axis of the point spread function, which is carried by the angle of the COG vector. The Center of Gravity Vector is found by spreading the 180 degrees of boundary angles in the star pattern around a circle and taking the moments of the Mean Residue around the X axes and Y axes of this new circle. For a round point spread function, the residues balance around each axis, and the COG vector is zero. If some boundaries are sharper than others, however, they dominate the moments, and the COG vector has a non-zero magnitude and a definite angle. The COG vector is observed as stage Z position is varied to see if it rotates and where it peaks. The Moments are computed as M x = Σ [cos(2ø)*M4G(ø)], and M γ = [sin(2ø)* lG(ø)]. The moment calculation generates the Cartesian representation of the Center of Gravity vector. The magnitude of the COG, r_C0G, is computed as the quadrature sum of the two moments r COG / M χ + My This magnitude of the Center of Gravity is an expression of the eccentricity of the point spread function. A larger r_C0G indicates greater distortion in the optics system and a more pronounced angle dependence of the boundary sharpness . A plot of r_C0G versus Z position is shown in Figure 12 for one example optical system. The angle of the COG vector, θ_COG, is also computed from the X and Y moments Note that the division by 2 is the operation of unwrapping the boundary angle, which runs from 0 to T Γ , from the circle that was created for calculating the moments . In step 119 the values of r_COG and θ_COG are stored for later use in quantifying the severity and orientation of the astigmatism in the optics system. In step 120 the next image in the Z panning sequence is accessed and steps 104 through 119 are repeated. This cycle continues until all the images in the Z panning sequence have been processed. The values stored in steps 115, 117 and 119 form tables indexed by the stage elevation in the Z axis, and will be used in the analysis of the Z axis dependent behavior of the point spread function in later steps. For this computation, the bins for four angles are suppressed to zero and ignored in all further computations. These angles are 0, it/ , r/2, and 37r/4, which are the vertical, horizontal, and diagonal boundaries in the test pattern. In the case of the horizontal boundary of the star pattern, for example, the X Gradient would ideally take on a value of zero, which would be a useful result. However, in a real image, the horizontal boundary will sporadically cross into and out of adjacent pixel rows, yielding a non¬ zero, noisy value for the X Gradient. The same phenomenon occurs for the vertical and diagonal boundaries, which similarly lie parallel to lines that could be drawn through the centers of adjacent pixels. Those skilled in the art will recognize that an integral over the square of the gradients in X and Y, SUM x (ø) , SUM y (ø) , is one of a class of operators that offers four features: (1) sensitivity to changes in the sharpness of step-type boundaries, (2) rotational invariability in the limit of infinitely fine sampling of the image, (3) invariance to the sampling density of the image, and (4) second-order dependence on illumination level. Those skilled in the art will recognize that other operators may be used in place of the above integral without deviating from the scope of the invention. The Grad x (i,j) and Grad y (i,j) operators are first- order derivatives of the image, which take on positive values for any non-zero amplitude shifts along their respective paths. As the boundary sharpness falls, the derivative falls, but the number of pixels in a boundary increases. The integral of the first order gradient then will be unaffected by changes in boundary sharpness, whereas the integral of the gradient squared will express sharpness. Rotational invariance is provided by the orthogonality of the two gradients. For any boundary angle, SUM χ (ø) and SUM γ (ø) are related through cos 2 (ø) and sin 2 (ø) . The square root of the sum of the two terms provides an angle-independent resolution measurement. The measurement for scale invariance in the operator is found in the absence of units of length in the outcome, because the 1/length units in the derivative are canceled by the length units of the two- dimensional integration. Finally, the second-order dependence of the operator on image brightness guarantees the illumination dependence. The operator can be broadened to the general class expressed as [(grad l) 2 ] Λ (1 - π) * (-grad 2 I) Λ n , where I is the image. All members of this class of operators meet the first three critical features, but not the fourth. Figures 9A and 9B show the method of the invention to compute the focal plane separation. The method of the invention assumes that the point spread function is persistently eccentric over the Z panning sequence, as indicated by the magnitude of the Center of Gravity Vector. An initial test is performed in step 124 for this persistent eccentricity. The method of step 124 is elaborated in Figure 9B. In step 125 Normalized Magnitude of the Center of Gravity, r_COG-norm(Z) is computed for each image in the Z panning sequence. It is computed by dividing the Magnitude of the Center of Gravity for each image by the Mean Residue of that image. For each value of Z, an r_COG_norm(Z) is computed for each image in the Z panning sequence by r_COG(Z) r_COG_norm(Z) = mean_RES(Z) The r_C0G_norm(Z) is an expression of the eccentricity of the point spread function because it is equal to the fraction of the residue integrated over all boundary angle regions that is not nulled out by the computation of the moments in the Center of Gravity calculation. It is independent, then, of the variation in overall image resolution as Z is varied. The presence of astigmatism is precluded by the absence of persistent eccentricity of the point spread function. Therefore, the integral over Z of r_COG_norm(Z) is computed in step 127 as Sum_r_COG_norm = jT r_COG_norm(Z) , where n = number of images in the z-panning sequence. In step 129, Sum_r_COG_norm is compared with a threshold. If Sum_r_COG_norm falls below the threshold, the possibility of astigmatism is dismissed, and the instrument is given a "PASS" result for the Astigmatism Test in step 126. If Sum_r_COG_norm exceeds the threshold, the program proceeds on to the computation of the Focal Plane Separation. The threshold value for Sum_r_COG_norm is found from empirical evidence about its relationship to the Focal Plane Separation. Characterization data is gathered from a plurality of optical systems with astigmatism of varying severity. A criterion is set for the maximum allowable Focal Plane Separation, typically not exceeding 25% of the depth of field of the objective lens of the system. The threshold Sum_r_COG_norm value is found by interpolation of values in the neighborhood of the crossing of the established Focal Plane Separation threshold. Any image with a large value of r_COG_norm(Z) is the product of an eccentric point spread function, and the orientation of the major axis of the point spread function is θ_COG(Z) . The value of r_COG_norm(Z) expresses the eccentricity, as the aspect ratio between the major and minor axes, of the point spread function. In the presence of astigmatism, given that the limits of the Z pan bracket the Z location of best focus, r_COG_norm(Z) will pass through a minimum near the middle of the Z pan at what is known as the Plane of Least Confusion, for which the point spread function is round; refer to Figure 12. On either side of the Plane of Least Confusion, the value of r_COG_norm(Z) will rise, as the point spread function becomes eccentric. Furthermore, in the presence of astigmatism, the angle of the Center of Gravity vector, θ_COG(Z) , resides at a first angle at the beginning of the Z pan, becomes indeterminate at the Plane of Least Confusion, and settles near the end of the Z pan at a second angle separated by approximately 90 degrees from the first angle; refer to Figure 13. These first and second angles are called the Dominant Angles. In step 128, the two dominant angles are found by first locating the null in the stored r_C0G_norm(Z) curve. The null is the point where the value is at a local minimum and rises on either side. A first set of images is designated for the computation of the First Dominant Angle as that set of five adjacent images wherein the image nearest the null in the r_COG_nor (Z) curve resides five images below the null. Similarly, a second set of images is designated for the computation of the Second Dominant Angle as that set of five images wherein the image nearest the null in the r_COG_norm(Z) curve resides five images above the null. Each dominant angle is computed as the average of θ_COG(Z) for the five images in its designated image set. In step 130, the values of the two dominant angles are used to look up the MAG(ø,Z) curve for their corresponding star pattern boundary angles. These curves were calculated and stored by repeated executions of steps 114 and 115. For each dominant angle, the corresponding boundary angle region is taken as the non-excluded boundary angle region nearest the dominant angle. The excluded boundaries are the vertical, horizontal and diagonal boundaries of the star pattern. In step 132, the two selected MAG(ø,Z) curves are evaluated using curve fitting to find their peaks. Figure 14 shows an example of mean residue values versus Z position plots for two dominant angles, τr/8 and Iτ/Q . A separation 1401 of about 9 micrometers is noted between peaks of the mean residue. Figure 15A and Figure 15B show an example of an application of least-squares polynomial curve fitting to mean residue curves for two dominant angles. A quadratic is fit to each curve 1501, 1502, nominally using ten samples below the peak, ten samples above the peak, and the peak itself as the locus of points j to be fit. If the peak is too close to the end of the panning range to allow all 21 points to be used, the missing points are ignored and a fit using the remaining points in the set is performed. This is the case for the first dominant angle in this example, plot 1501, for which only 17 points 1503 were available for curve fitting. Once the coefficients for the two quadratics have been calculated, a new peak is found for each curve by finding the location at which the first derivative of the quadratic is equal to zero. The differences between the peak locations computed in this way is reported as the Focal Plane Separation. This calculation, being based on a best fit to a set of points, carries precision much better than the 1 Z Pan increment precision that could have been delivered using just the original curve peaks. The quadratic equations for the two dominant angles are Mag ZF1 = a 1 *Z 2 + b l * Z + c 1 , and Ma 8zF2 = a 2 * z2 + b 2 ≠ z + c 2- The two peak locations from curve fitting are -pkl 2 *a and b 2 Zpk2 = " 2^' where a λ , b_ and c are the coefficients for the best-fit quadratic for Dominant Angle 1, and a 2 , b 2 and c 2 are the coefficients for the best-fit quadratic for Dominant Angle 2. The Focal Plane Separation is reported in microns using the following relation: FPS = K z * (Z pk2 -Z pkl ), where K z = scale factor in microns per z -pan increment. In step 136, the focal plane separation is compared against a threshold. The system is given a "PASS" result if the separation is less than the threshold and a "FAIL" result if the separation exceeds the threshold. The threshold is established from empirical evidence about the effect of astigmatism on the performance of the optical system with considerations for the intended use of the system. Typically, the Focal Plane Separation will not be allowed to exceed 25% of the depth of field of the objective lens of the optical system. Figure 16 is an example of a surface plot of mean residue versus boundary angle versus stage Z position. The first dominant angle, θ_dl, resides at zero radians, which is identical to it radians, so that, as stage Z position increases, the residue contour first peaks at both ends of the boundary angle axis. The second dominant angle, Θ_d2, resides at 7r/2, so that as stage Z position further increases, the residue contour peaks in the middle of the boundary angle axis. The Focal Plane Separation is equal to the difference in stage Z position between the peaks for the two dominant angles. Now refer to Figures 17A, 17B and 17C which show a more detailed schematic diagram of one embodiment of the apparatus of the invention for measuring astigmatism in an image interpretation system integrated with a computer-driven microscope. The apparatus of the invention comprises an imaging system 502, a motion control system 504, an image processing system 536, a central processing system 540 and a workstation 542. The imaging system 502 is comprised of an illuminator 508, imaging optics 510, a CCD camera 512, an illumination sensor 514 and an image capture and focus system 516. The image capture and focus system 516 provides video timing data to the CCD cameras 512, the CCD cameras 512 provide images comprising scan lines to the image capture and focus system 516. An illumination sensor intensity is provided to the image capture and focus system 516 where an illumination sensor 514 receives the sample of the image from the optics 510. In one embodiment of the invention, the optics may further comprise an automated microscope. The illuminator 508 provides illumination of a slide. The image capture and focus system 516 provides data to a VME bus 538. The VME bus distributes the data to an image processing system 536. The image processing system 536 is comprised of field- of-view processors 568. The images are sent along the image bus 564 from the image capture and focus system 516. A central processor 540 controls the operation of the invention through the VME bus 538. In one embodiment the central processor 562 comprises a Motorola 68030 CPU. The motion controller 504 is comprised of a tray handler 518, a microscope stage controller 520, a microscope turret controller 522, and a calibration slide 524. The motor drivers 526 position the slide under the optics. A bar code reader 528 reads a barcode located on the slide 524. A touch sensor 530 determines whether a slide is under the microscope objectives, and a door interlock 532 prevents operation in case the doors are open. Motion controller 534 controls the motor drivers 526 in response to the central processor 540. An Ethernet (TM) communication system 560 communicates to a workstation 542 to provide control of the system. A hard disk 544 is controlled by workstation 550. In one embodiment, workstation 550 may comprise a SUN SPARC CLASSIC (TM) workstation. A tape drive 546 is connected to the workstation processor 550 as well as a modem 548, a monitor 552, a keyboard 554, and a mouse pointing device 556. A printer 558 is connected to the Ethernet (TM) network 560. During astigmatism testing, the central computer 540, running a real time operating system, controls the automated microscope and the processor to acquire and digitize images from the microscope. The flatness of the slide may be checked, for example, by contacting the four corners of the slide using a computer controlled touch sensor. The computer 540 also controls the microscope stage to position the specimen under the microscope objective, and from one to 15 field of view (FOV) processors 568 which receive images under control of the computer 540. Refer now to Figure 17C, Figure 17C shows the placement of a calibration slide 1 into an optical path of an automated microscope 3 having a turret 23. The slide may be mounted on a stage 521 substantially in a horizontal X,Y plane which intersects the optical path. The stage 21 is movable in the X,Y plane as well as along a Z axis which is perpendicular to the X,Y plane and which is parallel to the optical axis of the automated microscope. The turret 22 may comprise multiple objective lenses as is well known in the art. The microscope turret control 522 provides signals in a well known manner for positioning a selected objective lens into position for viewing a slide, for example. It is to be understood that the various processes described herein may be implemented in software suitable for running on a digital processor. The software may be embedded, for example, in the central processor 540. The invention has been described herein in considerable detail in order to comply with the Patent Statutes and to provide those skilled in the art with the information needed to apply the novel principles and to construct and use such specialized components as are required. However, it is to be understood that the invention can be carried out by specifically different equipment and devices, and that various modifications, both as to the equipment details and operating procedures, can be accomplished without departing from the scope of the invention itself. What is claimed is :

Claims: CLAIMS 1. A method for evaluating a condition of an optical system comprising the steps of: (a) acquiring a plurality of images of a test pattern at different focus positions (85, 89) ; (b) processing the plurality of images to compute a plurality of center of gravity vectors, one center of gravity vector for each one of the plurality of images (86) ; (c) computing a focal plane separation from the plurality of center of gravity vectors (88) ; and (d) relating the condition of the optical system to the focal plane separation (88) . 2. The method of claim 1 further comprising the step of calculating an eccentricity of a point spread function from the plurality of center of gravity vectors (118) . 3. The method of claim 2 further comprising the steps of: (a) calculating a first parameter, r_C0G_norm (125) , by dividing a value of one of the plurality of center of gravity vectors, r_C0G, for each image in a Z panning sequence by a mean resolution, mean_res, for that image to yield a normalized value for eccentricity according to r_COG_norm = r_C0G / mean_res; (b) calculating a second parameter, Sum_r_COG_norm (127) , as a summation of r_COG_norm over all images in the Z panning sequence according to Sum_r_COG_norm = ∑ r_COG_norm(z); and (c) relating a high value of Sum_r_COG_norm to eccentricity in the point spread function (129) . 4. The method of claim 3 further comprising the step of computing a PASS/FAIL threshold for Sum_r_COG_norm by measuring astigmatism of lens systems with known astigmatism (129) . 5. The method of claim 1 further including the step of finding a focus range comprising the steps of: (a) determining vertical motion limits for a Z panning sequence through a Z panning range by obtaining a plurality of focus images (83) ; (b) computing a resolution measure for each of the plurality of focus images (83) ; and (c) determining a vertical position yielding a best overall resolution for a middle position of the Z panning range (83) . 6. The method of claim 1, wherein the optical system includes a stage, wherein the step of acquiring a plurality of images further comprises the step of acquiring the plurality of images (91) , beginning at a lower limit of the stage elevation, passing through a plane of best focus, and extending to an upper limit of the stage elevation (90) . 7. The method of claim 1 further comprising the steps of: (a) edge enhancing the plurality of images in a first direction (92) ; and (b) lowpass filtering the plurality of images in a second direction wherein the first direction is orthogonal to the second direction to substantially equalize the plurality of images (93) . 8. The method of claim 1 wherein the step of computing a focal plane separation comprises the steps of: (a) computing a first derivative of one of the plurality of images to convey a location and a sharpness of boundaries in one of the plurality of images (132) ; (b) summing derivative values for each pixel belonging to a given boundary and placing a resultant summation into an array indexed by boundary angle, so as to build the array indexed by boundary angle with a plurality of summed derivatives (112) ; and (c) using the summed derivatives from the array to compute a center of gravity vector (118) . 9. The method of claim 1 wherein the step of computing a focal plane separation from the plurality of filtered test pattern images (124) further comprises the steps of : (a) summing the magnitude of the center of gravity vector over the set of images from the Z panning sequence (127) ; and (b) comparing the summation of the magnitude of the center of gravity vector against a threshold as a first estimate of the severity of astigmatism (129) . 10. The method of claim 9 wherein the threshold is an empirically derived fraction of the mean residue values integrated over all boundaries in the plurality of images in the Z panning sequence (116, 117) . 11. The method of claim 1 wherein the step of measuring a focal plane separation further comprises the steps of : (a) finding a first dominant angle for a first focal plane (128) ; (b) finding a second dominant angle for a second focal plane (128) ; (c) computing the focal plane separation of the first focal plane from the second focal plane to generate a focal plane separation (134) . 12. The method of claim 11 wherein the steps of finding the first and second dominant angles (128) comprises: (a) locating a plane of least confusion by finding an image in the Z panning sequence yielding the least value of the magnitude of the center of gravity vector (128) ; (b) reading the angle of the center of gravity vector for an image offset below the plane of least confusion to yield the first dominant angle (128) ; and (c) reading the angle of the center of gravity vector for an image offset above the plane of least confusion to yield the second dominant angle (128) . 13. The method of claim 12 wherein the step of finding the separation of focal planes (134) comprises the steps of : (a) finding a first Z panning position with the highest resolution for the first dominant angle (134) ; (b) finding a second Z panning position with the highest resolution for the second angle (134) ; and (c) computing the absolute value of the difference between the first Z panning position and the second Z panning position (134) . 14. The method of claim 5 wherein the step of determining a magnitude of a center of gravity vector for the plurality of images further comprises the steps of : (a) initially centering the test pattern (84) ; (b) finding an exact center of the test pattern to align test pattern objects with preassigned bins (84) ; (c) computing a plurality of X-Gradients and a plurality of Y-Gradients for each filtered test pattern image to produce a plurality of gradient image pixels (104) ; (d) sorting the plurality of gradient image pixels into bins by boundary angle (106) ; (e) rejecting each one of the plurality of gradient image pixels outside a predetermined region (108) ; (f) rejecting each one of the plurality of gradient image pixels with low gradient scores (110) ; (g) squaring each one of the plurality of gradient image pixels to produce a plurality of squared gradient values (112) ; (h) summing the squares of the plurality of X_gradients and the plurality of Y gradients to produce a sum of squares (127) ; (i) checking the sum of squares against a threshold (129) ; (j) adding the squared gradient values to a bin for each gradient image pixel' s boundary angle, if threshold requirement is met (129) ; (k) computing a mean residue for each boundary angle to produce a result (114) ; (1) normalizing the result by dividing by the average number of pixels per bin (116) ; (m) computing a third array by taking a quadratic sum of the two gradients; and (n) computing the magnitude of the center of gravity vector from the third array (118) . 15. The method of claim 10 wherein the step of computing the magnitude of the center of gravity vector (118) further comprises the operators, π M x = Σ IcosQ-®) *MAG(ø)] , M γ = [sin(2ø) *MAG(ø)] , and ø=0 where MAG(ø) is the residue value. 16. The method of claim 10 wherein the steps of computing a plurality of X_Gradients and Y_Gradients (104) summing the squares of the gradients, and sorting into boundary angle bins (106) comprise the operators Grad x [i,j] = ABS (A[i+1] fj] - A[i] [j]) , and Grad γ [i,j] = ABS (A[i] [j+1] - A[i] [j]) , where pixels [i,J] lie on the boundary at angle ø SUM y [ø] = ∑ Grady where pixels [i,j] lie on the boundary at angle 0. 17. The method of claim 5 wherein the computation of the angle of the center of gravity vector (88) comprises the operator 18. The method of claim 1 wherein the test pattern image is initially centered during system calibration and an initial center location of the test pattern is stored (Fig. 5A-5F) . 19. The method of claim 17 wherein the exact center of the test pattern is found from the initial center of the test pattern by morphological operations (158) . 20. A method for qualifying an optical system for compliance with a standard for low astigmatism, comprising the steps of : (a) finding a best focus position for an image of a test pattern (83) ; (b) centering the test pattern (84) ; (c) acquiring a set of images of the test pattern (90, 91) ; (d) determining vertical motion limits for a Z panning sequence through a Z panning range by obtaining a series of images on the test pattern and examining them for overall resolution (83) ; (e) determining a vertical position yielding a best overall resolution for the middle of the z-panning range (83) ; (f) acquiring the set of images, beginning at a lower limit of the stage elevation, passing through a plane of best focus, and extending to an upper limit of the stage elevation (85, 89) ; (g) filtering the set of images to generate a set of filtered test pattern images (93) ; (h) computing an estimate of the sharpness of each of a set of boundaries disposed at various angles (114) ; (i) finding the angle of highest resolution for each image in a z-panning sequence (114) ; (j) computing an estimate of the severity of eccentricity of the point spread function for each image in a Z panning sequence (118) ; (k) finding the two angles of best resolution, called the dominant angles, displaced above and below the plane of least confusion (128) ; (1) measuring a focal plane separation based on the z-dependent resolution for boundaries at the two dominant angles (130) ; and (m) applying test criteria to the outcome of the astigmatism measurement (136) . 21. The method of claim 19 wherein the step of applying test criteria comprises the steps of : (a) comparing the sum of the magnitude of the normalized center of gravity vector computed over the set of images in the z-panning sequence with a threshold, the threshold having been determined empirically as a small fraction of the mean residue values integrated over all boundaries in all images in the z-panning sequence (129) ; and (b) comparing the focal plane separation with a threshold, the threshold having been determined empirically from the depth of field of the optical system under test and the particular requirements of the application of the optical system (136) . 22. An apparatus for measurement of astigmatism of an optical system (22, 24) comprising: (a) means for focusing the optical system on a test pattern having a focus control input (20) ; (b) means for obtaining a digital representation (26) of the test pattern image (18) through the optical system, wherein the image gathering means has a digital image output; and (c) means for measuring astigmatism (30) in the optical system (22, 24) connected to the digital image output, wherein the means for measuring astigmatism (30) further has a focus control output connected to the focus control input. 23. The apparatus of claim 21 wherein the means for measuring astigmatism (30) in the optical system (22, 24) further comprises a digital computer (30) . 24. The apparatus of claim 21 wherein the test pattern (18) further comprises a star test pattern (Fig. 5B) . 25. The apparatus of claim 21 wherein the optical system (22, 24) further comprises a microscope. 26. The apparatus of claim 21 wherein the optical system (22, 24) further comprises the optical components of a camera. 27. The apparatus of claim 21 wherein the image gathering means (26) further comprises a charge coupled device array. 28. An astigmatism measurement apparatus for measuring of astigmatism in an optical train having an objective lens, the apparatus comprising: (a) an optical mount to hold the optical train (22, 24) ; (b) an optical stage (16) to hold a test pattern (18) in view of the objective lens (22) wherein the objective lens (22) receives an image of the test pattern (18) and transmits a test pattern image; (c) a stage drive (20) attached to move the optical stage (16) , wherein the optical stage drive (20) has a focus control input; (d) a computer processor (34) connected to control the stage drive (20) ; (e) a test pattern illuminator (12) disposed to illuminate the test pattern (18) ; (f) a video camera (26) for viewing the test pattern image through the optical train (22, 24) and generating a video signal; (g) image acquisition electronics (28) connected to the video signal, having a digital image output; and (h) an image analysis computer (30) connected to receive the digital image output including means for analyzing a plurality of test pattern images to measure astigmatism of the optical train (22, 24) . 29. The apparatus of claim 28 wherein the test pattern illuminator (12, 14) further comprises a light (12) and a condenser lens (14) . 30. The apparatus of claim 28 further comprising a microscope in the optical train (22, 24) , the microscope including an output converted to an electronically stored image. 31. The apparatus of claim 28 wherein the test pattern (18) is a star pattern (Fig. 5B) . 32. The apparatus of claim 28 further comprising the integration of an image interpretation system (30) with a computer driven microscope.

Inventors: FROST KEITH L, HANSEN KIM J, LINDOW WILLIAM C, PHAN TUAN, RILEY JAMES K, STEPHANICK JAMES A, FROST, KEITH, L., HANSEN, KIM, J., LINDOW, WILLIAM, C., PHAN, TUAN, RILEY, JAMES, K., STEPHANICK, JAMES, A.
Applicants: NEOPATH INC, NEOPATH, INC.
Application year: 1996
Main classification: G06K9
IPC codes: G01B11, G01M11, G06T1