Microscope automatic focusing method and device

By using the zoom mechanism in the laser autofocus system to adjust the focus, the problem of small focus range caused by sample jitter is solved, higher focus accuracy and applicability are achieved, and the stability and accuracy of autofocus are ensured.

CN118584641APending Publication Date: 2024-09-03HEFEI I TEK OPTOELECTRONICS CO LTD
View PDF 0 Cites 9 Cited by

Patent Information

Application Number
CN202410975065.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-19
Publication Date
2024-09-03

AI Technical Summary

Technical Problem

Existing laser autofocus technology has insufficient anti-interference ability in the focusing environment, causing high-magnification microscopes to easily leave the focus range when the sample vibrates, resulting in autofocus failure.

Method used

A zoom mechanism is used to replace the original focusing lens. By increasing the focal length of the zoom mechanism, the laser image of the reflected beam incident on the autofocus sensor is narrowed, making it more concentrated, increasing the luminous flux and brightness per unit area, thereby expanding the focus range and ensuring automatic Focus operates normally.

Benefits of technology

It effectively expands the focus range, ensures that the defocus amount can be accurately calculated and auto-focus is achieved even when the sample is shaking, improving focus accuracy and applicability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118584641A
    Figure CN118584641A
Patent Text Reader

Abstract

The invention belongs to the technical field of industrial cameras, and particularly relates to an automatic focusing method and device for a microscope, and the device comprises a zooming mechanism which is located at the front side of an automatic focusing sensor, replaces an original focus detection lens in the automatic focusing mechanism, and is used for enabling the magnification of the zooming mechanism to be reduced through increasing the focal length of the zooming mechanism, thereby achieving the automatic focusing of the microscope. Therefore, a laser image of the reflected light beam incident to the automatic focusing sensor is reduced, the defocused light beam is more concentrated, the luminous flux in unit area is increased, the brightness of the laser image is higher, and the gray average value of the laser image on the photosensitive surface of the automatic focusing sensor is greater than a threshold value. Effective information is extracted through an image signal corresponding to a laser image on the automatic focusing sensor so as to carry out centroid calculation, so that the defocusing amount of the focus of the objective lens and the surface of the sample to be detected is obtained; the problem that in the prior art, in the aspect of the anti-interference capability of a focusing environment, the focusing range is small, and the surface of a to-be-detected sample is prone to disengaging from the focusing range is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of laser auto-focusing, and in particular relates to a microscope auto-focusing method and device. Background Art

[0002] Optical microscopes magnify the surface image of an object by means of lens imaging. In order to obtain a meaningful image, the microscope objective must be precisely focused on the surface of the sample to be tested. However, the depth of field of a high-power microscope objective is generally only a few microns. Microscope operators often need to spend a lot of time manually adjusting the distance between the objective lens and the sample to be tested to achieve focus.

[0003] The autofocus technology calculates the current defocus amount of the objective lens through the feedback signal and converts it into the motion signal of the motor. The motor drives the objective lens to move to automate the focusing process. According to the different types of feedback signals, the autofocus technology can be divided into image autofocus technology and laser autofocus technology. Among them, the image autofocus technology calculates the clarity of the current image by digital image processing through the design of the image clarity evaluation function, and judges the current defocus amount based on the quantified clarity value. The laser autofocus technology projects the laser directly on the surface of the sample to be tested, and judges the defocus amount of the objective lens by the state of the laser reflected back from the surface of the sample to be tested; the image autofocus technology is completely dependent on the state of the collected image, and is easily affected by the lighting environment. It needs to scan back and forth near the focus to determine the best focus position, and the focusing speed is slow and the focusing range is small; in contrast, the laser focusing technology, based on the ordinary microscope, adds a laser signal, has a larger focusing range and faster focusing speed, and is widely used in the field of industrial inspection.

[0004] The commonly used implementation schemes of laser autofocus technology are semicircular spot and semicircular line spot. The position of the centroid of the spot can indicate the magnitude and direction of the defocus of the imaging system. This processing method that uses the centroid of the entire laser image as the defocus signal indicator is easy to deviate from the set focus range when the sample vibrates due to external factors during continuous focus tracking using a high-power lens, resulting in the camera grayscale value being too low to extract the centroid.

[0005] A Chinese patent discloses a microscope autofocus system and a focusing method for micro-nano step samples to be tested (application number CN202210642022.2). In this autofocus system, the optical path first passes through one side of the microscope objective lens and is focused and projected onto the micro-nano step sample to be tested, and then is reflected by the surface of the micro-nano step sample to be tested and passes through the other side of the microscope objective lens, and finally forms a spot image on the CMOS camera; by judging whether the spot image on the CMOS camera is formed by staggered arrangement of columnar protrusions and lines, the focal position of the microscope objective lens is determined, and the distance between the microscope objective lens and the micro-nano step sample to be tested is adjusted according to the focusing requirements, so as to focus the microscope objective lens on the top surface of the step or the bottom surface of the groove. However, in this focusing system, once the sample to be tested is disturbed by the environment and causes jitter and leaves the focus range, the position of the center of mass of the spot cannot be locked due to the low brightness of the laser image, so that the defocus amount cannot be calculated, resulting in the failure of autofocus.

[0006] In terms of the anti-interference ability of the focusing environment, the prior art has the problem that the focusing range is small and the surface of the sample to be tested is easily out of the focusing range.

[0007] Therefore, in order to solve the above problems, the present invention provides a microscope automatic focusing method and device, which can automatically expand the focus range and solve the problem of sample position being out of focus range. Summary of the invention

[0008] The purpose of the present invention is to overcome the above problems existing in the prior art and to provide a microscope automatic focusing method and device.

[0009] In order to achieve the above technical objectives and the above technical effects, the present invention is implemented through the following technical solutions: A microscope automatic focusing device, comprising: The autofocus mechanism uses the incident light beam entering from the incident area on one side of the objective lens, focuses on the surface of the sample to be tested through the objective lens, and then reflects through the surface of the sample to be tested and passes through the reflection area on the other side of the objective lens to obtain a reflected light beam. The reflected light beam passes through the original focus lens and converges to the photosensitive surface of the autofocus sensor to form a laser image, so as to calculate the defocus amount between the focus of the objective lens and the surface of the sample to be tested, and adjust the height of the objective lens so that the focus of the objective lens is located on the surface of the sample to be tested; Among them, when the focus of the objective lens does not fall on the surface of the sample to be measured, the reflected light beam generated partially deviates from the reflection area on the other side of the objective lens, so that the reflected light beam does not pass through the objective lens completely, causing the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor to drop below the threshold, so that the defocus amount cannot be calculated; The zoom mechanism is located in front of the autofocus sensor and replaces the original focus lens in the autofocus mechanism. It is used to reduce the magnification of the zoom mechanism by increasing the focal length of the zoom mechanism, thereby reducing the reflected light beam incident on the laser image on the autofocus sensor, making the defocused light beam more concentrated, resulting in an increase in the luminous flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor is greater than a threshold. At this time, effective information is extracted through the image signal corresponding to the laser image on the autofocus sensor to perform centroid calculation, thereby obtaining the defocus amount between the focus of the objective lens and the surface of the sample to be measured.

[0010] Furthermore, the zoom mechanism comprises: A variable focus lens for focusing the reflected light beam to an auto focus sensor; The second driving member is used to drive the variable focus lens to adjust the focal length.

[0011] Furthermore, the variable focus lens includes a liquid lens or a lens group.

[0012] A microscope automatic focusing method, comprising: Acquire a laser image on the photosensitive surface of the autofocus sensor, calculate the centroid of the spot shape, obtain the defocus amount between the focus of the objective lens and the surface of the sample to be measured, and confirm that the defocus amount is the separation amount; According to the separation amount, the focal length of the zoom mechanism is increased to reduce the magnification of the zoom mechanism, thereby reducing the laser image of the reflected light beam incident on the autofocus sensor, making the defocused light beam more concentrated, resulting in an increase in the luminous flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor is greater than the threshold, and the centroid of the spot shape is calculated again to obtain the defocus amount between the focus of the objective lens and the surface of the sample to be measured; According to the defocus amount, adjust the height of the objective lens so that the focal point of the objective lens is located on the surface of the sample to be measured.

[0013] Furthermore, the centroid calculation of the spot shape is used to obtain the defocus between the focus of the objective lens and the surface of the sample to be measured, including: The laser image formed by the focal point of the defocused light beam on the photosensitive surface of the autofocus sensor is obtained to calculate the current centroid, and the focus sensitivity and focus reference centroid corresponding to the focal length of the current zoom mechanism are obtained to calculate the defocus amount.

[0014] Furthermore, the focus sensitivity and the focus reference centroid are obtained by calibration using a calibration method.

[0015] Further, the confirming that the defocus amount is a separation amount includes: If the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor is less than the threshold value, the calculated defocus amount is the separation amount.

[0016] Further, the step of increasing the focal length of the zoom mechanism includes: The voltage change value of the zoom mechanism is calculated by the difference between the separation amount and the standard focus range and the corresponding proportional coefficient to obtain the focal length adjustment amount of the zoom mechanism; The standard focus range is the focus range distance value corresponding to the current focal length of the zoom mechanism.

[0017] Further, adjusting the height of the objective lens according to the defocus amount so that the focus of the objective lens is located on the surface of the sample to be measured includes: The defocus amount is converted into a motor driving signal to drive the motor to move the objective lens so that the focus of the objective lens falls on the surface of the sample to be tested, so as to determine whether the sample to be tested is in focus successfully.

[0018] Further, the step of determining whether the sample to be tested is focused successfully includes: The focus sensitivity and focus reference centroid corresponding to the focal length of the current zoom mechanism are obtained, and the current centroid is calculated through the laser image on the autofocus sensor to construct a relationship to determine whether the focus of the sample to be tested is successful.

[0019] The beneficial effects of the present invention are: 1. In the present invention, when the sample to be tested is out of the focusing range due to shaking during operation, the focus of the objective lens does not fall on the surface of the sample to be tested. After part of the light in the reflected light beam returns on the surface of the sample to be tested, it will leave the reflection area on the other side of the objective lens, so that the reflected light beam passes through the objective lens completely, causing the grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor to decrease and be lower than the preset threshold value, so that the accurate defocus amount cannot be calculated for autofocus. By setting a zoom mechanism, the focal length of the zoom mechanism can be increased. At this time, the magnification of the zoom mechanism is reduced, and the imaging height is correspondingly reduced, so that the laser image formed by the reflected light beam falling on the autofocus sensor after passing through the zoom mechanism becomes smaller. At this time, the convergent light is more concentrated, resulting in an increase in the luminous flux per unit area and a higher brightness of the laser image, so that the grayscale value of the laser image becomes larger, and the grayscale average value is greater than the preset threshold value, becoming an effective image that meets the centroid calculation, thereby expanding the focusing range of the sample to be tested, realizing the adjustment of the focusing range, and ensuring the normal operation of the autofocus.

[0020] 2. In the present invention, after completing one autofocus, the focal length is continuously adjusted to focus again, so that focusing is completed at the target focal length, and focusing accuracy is guaranteed; specifically, when the sample to be tested is successfully focused at the adjusted focal length, the distance between the objective lens and the sample to be tested changes accordingly, so that the sample to be tested returns to the corresponding focusing range at the previous focal length. Therefore, by lowering the focal length and performing autofocus again at the current focal length, the magnification of the zoom mechanism is increased, thereby increasing the imaging height of the laser image, facilitating the improvement of focusing accuracy, and repeating the above operation until the sample to be tested is successfully focused at the target focal length. At this time, the focusing accuracy of the sample to be tested is higher, and the autofocus process is completed.

[0021] 3. In the present invention, the change in the focal length of the zoom mechanism can be controlled by changing the defocus amount of the sample to be tested, thereby adjusting the focus range of the entire optical path, thereby improving the correlation between the focus range of the entire optical path and the zoom mechanism; specifically, the voltage value that needs to be applied to the zoom mechanism and the amplitude of the defocus amount of the sample to be tested deviating from the standard focus range are visualized through a formula, and the proportional coefficient in the formula can be obtained through calibration, that is, the voltage value that needs to be applied to the zoom mechanism can be calculated using the formula through the defocus amount of the sample to be tested, and the focal length that needs to be adjusted can be determined using the relationship between the applied voltage and the focal length, thereby improving the correlation between the focus range of the entire optical path and the zoom mechanism, and having strong applicability. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings: Figure 1 It is a schematic diagram of the focusing optical path of the automatic focusing device for a microscope in the present invention; Figure 2 It is a flow chart of the microscope automatic focusing method in the present invention.

[0023] In the figure, 1, laser; 2, cylindrical lens; 3, baffle; 4, reflector; 5, first beam splitter; 6, second beam splitter; 7, objective lens; 8, first driving member; 9, zoom mechanism; 10, autofocus sensor; 91, variable focus lens; 92, second driving member. DETAILED DESCRIPTION

[0024] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0025] Common implementation schemes for laser autofocus technology include semicircular spot and semicircular line spot. The position of the centroid of the spot can indicate the size and direction of the defocus amount of the imaging system. This processing method that uses the centroid of the entire laser image as a defocus signal indicator is easy to deviate from the set focus range when the sample vibrates due to external factors during continuous focus tracking using a high-power lens, causing the camera grayscale value to be too low to extract the centroid. In other words, the existing technology has the problem of anti-interference ability in the focus environment, and the surface of the sample to be tested is easy to deviate from the focus range when the focus range is small.

[0026] Therefore, if Figure 1 As shown, the present invention first provides a microscope autofocus device, comprising: The autofocus mechanism uses the incident light beam entering from the incident area on one side of the objective lens 7, focuses on the surface of the sample to be tested through the objective lens 7, and then reflects through the surface of the sample to be tested and passes through the reflection area on the other side of the objective lens 7 to obtain a reflected light beam. The reflected light beam passes through the original focus lens and converges to the photosensitive surface of the autofocus sensor 10 to form a laser image, so as to calculate the defocus amount between the focus of the objective lens 7 and the surface of the sample to be tested. , adjust the height of the objective lens 7 so that the focus of the objective lens 7 is located on the surface of the sample to be measured; When the focus of the objective lens 7 does not fall on the surface of the sample to be measured, the reflected light beam generated partially escapes from the reflection area on the other side of the objective lens 7, so that the reflected light beam does not completely pass through the objective lens 7, causing the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor 10 to drop below the threshold, thereby making it impossible to calculate the defocus amount. ; The zoom mechanism 9 is located in front of the autofocus sensor 10, and replaces the original focus lens in the autofocus mechanism. It is used to reduce the magnification of the zoom mechanism 9 by increasing the focal length of the zoom mechanism 9, thereby reducing the laser image of the reflected light beam incident on the autofocus sensor 10, making the defocused light beam more concentrated, resulting in an increase in the luminous flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor 10 is greater than the threshold value. At this time, effective information is extracted through the image signal corresponding to the laser image on the autofocus sensor 10 to perform centroid calculation, thereby obtaining the defocus amount between the focus of the objective lens 7 and the surface of the sample to be measured. .

[0027] For the autofocus mechanism, when the focus of the objective lens 7 falls entirely on the surface of the sample to be tested, the incident light beam entering from the incident area on one side of the objective lens 7 will pass through the reflection area on the other side of the objective lens 7 and symmetrically pass out to obtain a reflected light beam after being reflected by the surface of the sample to be tested. When the focus of the objective lens 7 does not fall on the surface of the sample to be tested, part of the light in the reflected light beam will escape from the reflection area on the other side of the objective lens 7 after returning on the surface of the sample to be tested, so that the reflected light beam will not pass through the objective lens 7 in its entirety, thereby causing the grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor 10 to decrease, so that the grayscale average value of the laser image decreases. When the grayscale average value is lower than a preset threshold value, the brightness of the laser image is lower than the brightness of the laser image that can be normally identified. In other words, effective information cannot be extracted from the image signal corresponding to the laser image, resulting in the inability to perform effective centroid calculation, thereby calculating the defocus amount. Inaccurate, it is difficult to perform autofocus, and it is determined that the sample to be tested is out of the focus range.

[0028] For the autofocus sensor 10, the centroid calculation can be performed using the laser image of the outgoing light beam or the out-of-focus light beam falling on the photosensitive surface. The premise for the centroid calculation is that the laser image needs to meet certain brightness conditions. If it meets the conditions, it means that the laser image is a valid image. The image grayscale value is used to represent the brightness level of each pixel in the image, which can be used as a standard for determining whether the image is valid. In the present invention, the grayscale value of the laser image is affected by the laser energy and exposure time, and both have upper limits. At the same time, in the present invention, when the automatic exposure is turned on, after the laser energy and exposure time reach the upper limit, the farther the sample to be tested is from the focus of the objective lens 7, the less the reflected light beam returned from the surface of the sample to be tested is received by the objective lens 7, resulting in a lower grayscale value of the laser image. When the calculated average grayscale value of the laser image is lower than a certain threshold, the image signal of the autofocus sensor 10 cannot extract valid information, indicating that the laser image is not a valid image, that is, the sample to be tested is out of focus.

[0029] In the present invention, a zoom mechanism 9 is used to replace the original focusing lens of the autofocus mechanism in the prior art. For the zoom mechanism 9, the focal length of the zoom mechanism 9 can be increased. At this time, the magnification of the zoom mechanism 9 is reduced, and the imaging height is correspondingly reduced, so that the laser image formed by the reflected light beam falling on the autofocus sensor 10 after passing through the zoom mechanism 9 becomes smaller. At this time, the convergent light is more concentrated, resulting in an increase in the luminous flux per unit area and a higher brightness of the laser image, thereby increasing the grayscale value of the laser image and making the grayscale average value greater than a preset threshold value, thereby becoming an effective image that satisfies the centroid calculation, thereby expanding the focusing range of the sample to be tested.

[0030] Then, a new centroid calculation is performed based on the effective laser image after the focal length is adjusted to obtain the accurate defocus value. , thus enabling automatic focus.

[0031] The autofocus mechanism includes: A laser 1, for providing a light beam; The light beam emitted by the laser 1 in the present invention is a single-wavelength laser, and its shape can be circular or elliptical. Preferably, circular parallel light is used in the present invention.

[0032] The objective lens 7 is used to converge the light beam emitted by the laser 1 to the surface of the sample to be measured, and transmit the reflected light beam returned from the surface of the sample to be measured; The auto-focus sensor 10 is used to receive the reflected light beam returned from the surface of the sample to be measured and passed through the objective lens 7 to form a laser image; A focus lens, used for converging the reflected light beam to the auto focus sensor 10; The first driving member 8 is used to control the distance between the objective lens 7 and the sample to be measured to achieve focusing.

[0033] The first driving member 8 in the present invention can be a motor, a cylinder or other driving elements that can drive the objective lens 7 to move. Preferably, the first driving member 8 in the present invention is a motor, which drives the objective lens 7 to move to adjust the distance from the sample to be measured to achieve focusing operation.

[0034] Specifically, when the first driving member 8 is a motor, the motor needs to cooperate with other components such as a screw assembly to connect with the objective lens 7, so as to realize the movement of the objective lens 7, so as to adjust the distance between the objective lens 7 and the sample to be measured and realize the focusing function.

[0035] The focusing optical path of the autofocus mechanism is as follows: The light beam emitted by the laser 1 enters the objective lens 7 and is focused on the surface of the sample to be tested. Due to the reflection of the surface of the sample to be tested, the light beam returns to the objective lens 7 again and passes through the focusing lens. It is focused by the focusing lens to the surface of the autofocus sensor 10 and then received to form a laser image.

[0036] The automatic focusing device of the present invention further comprises: The cylindrical lens 2 is used to modulate the light beam emitted by the laser 1 so as to transform it into an asymmetric light beam that diverges in the curvature direction of the cylindrical lens 2 and is collimated in the direction without curvature; The baffle 3 is used to block half of the asymmetric light beam so that the light beam propagates on one side of the optical axis; A reflector 4, used for reflecting the half of the asymmetric light beam that is not blocked by the baffle 3; The first beam splitter 5 is used to transmit the light beam and reflect the reflected light beam returned from the surface of the sample to be tested to the focusing lens; The second beam splitter 6 is used to reflect the light beam transmitted by the first beam splitter 5 to the objective lens 7 , and reflect the reflected light beam returned from the surface of the sample to be measured to the first beam splitter 5 .

[0037] The focusing optical path of the autofocus mechanism is as follows: The laser 1 emits a light beam, which, after being modulated by the cylindrical lens 2, becomes an asymmetric light beam that diverges in the curvature direction of the cylindrical lens 2 and is collimated in the direction without curvature. The asymmetric light beam propagates on one side of the optical axis after passing through the baffle 3, passes through the first beam splitter 5 and reaches the second beam splitter 6 after being reflected by the surface of the reflector 4, enters the objective lens 7 after being reflected by the second beam splitter 6, and is converged by the objective lens 7 on the surface of the sample to be tested. Due to the reflection of the surface of the sample to be tested, the light beam returns to the objective lens 7 again, and after being continuously reflected by the second beam splitter 6 and the first beam splitter 5, is converged by the focusing lens to the surface of the autofocus sensor 10 to form a laser image.

[0038] In the present invention, the zoom mechanism 9 is used to replace the above-mentioned focus lens; Specifically, the zoom mechanism 9 includes: A variable focus lens 91, used for focusing the reflected light beam to the auto focus sensor 10; The second driving member 92 is used to drive the variable focus lens 91 to adjust the focal length.

[0039] In the present invention, the variable focus lens 91 can perform different focal length changes, and the second driving member 92 can drive the variable focus lens 91 to adjust the focal length to change the incident angle of the reflected light beam after passing through the autofocus sensor 10, so that the size of the laser image of the reflected light beam falling on the photosensitive surface of the autofocus sensor 10 changes, so as to change the grayscale average value of the laser image, thereby adjusting the focus range of the overall optical path to solve the problem of the sample to be tested being out of focus due to jitter, and the smaller the focal length of the zoom mechanism 9, the larger the corresponding focus range.

[0040] The variable focus lens 91 includes a liquid lens or a lens group.

[0041] The current principle of liquid lens is a variable focus optical lens that uses the principle of electrowetting on the medium. It can change the shape of the droplet and thus change its focal length by applying an external voltage.

[0042] The lens group is a variable focus lens formed by combining two or more lenses with adjustable spacing. The focal length of the lens group can be adjusted by adjusting the spacing of the combined lenses.

[0043] In the embodiment of the present invention where the variable focus lens 91 is a liquid lens, the second driving member 92 can be an electrode or other driving element that can apply an external voltage to drive a droplet-shaped driving element inside the liquid lens.

[0044] In the embodiment of the present invention where the variable focus lens 91 is a lens group, the second driving member 92 can be a driving element such as a micro motor or a cylinder that can control the distance between the combined lenses in the lens group.

[0045] In summary, in the present invention, when the sample to be tested is out of focus due to shaking during operation, the focus of the objective lens 7 does not fall on the surface of the sample to be tested. After returning from the surface of the sample to be tested, part of the light in the reflected light beam will be out of the reflection area on the other side of the objective lens 7, so that the reflected light beam passes through the objective lens 7 completely, causing the grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor 10 to drop and be lower than the preset threshold value, so that the accurate defocus value cannot be calculated. To perform autofocus, by setting a zoom mechanism 9, the focal length of the zoom mechanism 9 can be increased. At this time, the magnification of the zoom mechanism 9 is reduced, and the imaging height is correspondingly reduced, so that the laser image formed by the reflected light beam falling on the autofocus sensor 10 after passing through the zoom mechanism 9 becomes smaller. At this time, the convergent light is more concentrated, resulting in an increase in the luminous flux per unit area and a higher brightness of the laser image, thereby increasing the grayscale value of the laser image and making the grayscale average value greater than a preset threshold value, thereby becoming a valid image that satisfies the centroid calculation, thereby expanding the focus range of the sample to be tested, realizing the adjustment of the focus range, and ensuring the normal operation of the autofocus.

[0046] like Figure 2 As shown, another aspect of the present invention provides a microscope autofocus method, comprising: The first step is to obtain the laser image on the photosensitive surface of the autofocus sensor 10, and obtain the defocus value between the focus of the objective lens 7 and the surface of the sample to be measured by calculating the centroid of the spot shape. , and confirm the defocus amount is the separation amount, at which point the sample to be tested is out of the focus range; In the present invention, the centroid is calculated by the shape of the light spot in the acquired laser image to obtain the defocus value from the focus of the objective lens 7 to the surface of the sample to be measured. , that is, the displacement between the two. For this displacement, it is necessary to determine whether it is a valid image by the gray value of the laser image. If it is a valid image, the defocus value Auto focus can be performed. If it is a non-valid image, the defocus amount This is the amount of separation, and accurate autofocus cannot be performed using the separation amount.

[0047] The second step is to increase the focal length of the zoom mechanism 9 according to the separation amount, so that the magnification of the zoom mechanism 9 is reduced, thereby reducing the laser image of the reflected light beam incident on the autofocus sensor 10, making the defocused light beam more concentrated, resulting in an increase in the light flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor 10 is greater than the threshold, and the centroid of the spot shape is calculated again to obtain the defocus amount between the focus of the objective lens 7 and the surface of the sample to be measured ; In the present invention, the defocus amount is determined After the defocus amount is reached, the focal length of the zoom mechanism 9 is increased to finally increase the grayscale average value of the laser image and make it greater than the preset threshold value, so that the laser image becomes a valid laser image, thereby accurately calculating the defocus amount. for auto focus.

[0048] Step 3: According to the defocus amount , adjust the height of objective lens 7 so that the focus of objective lens 7 is located on the surface of the sample to be measured.

[0049] In the present invention, according to the accurately calculated defocus amount The height change of the objective lens 7 is controlled to achieve automatic focusing.

[0050] In the present invention, the defocus value calculated by the gray value of the laser image is determined. Whether it is a defocusing amount, that is, whether the sample to be tested is out of the focus range, if so, the focal length of the zoom mechanism 9 is adjusted to reduce the laser image of the reflected light beam incident on the autofocus sensor 10, so that the defocused light beam is more concentrated, resulting in an increase in the luminous flux per unit area, and a higher brightness of the laser image, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor 10 is greater than the threshold, and the centroid of the spot shape is calculated again to obtain the defocusing amount between the focus of the objective lens 7 and the surface of the sample to be tested , with the defocus amount obtained by accurate calculation Automatic focusing is performed, thereby achieving an improvement in the focusing range and the device has strong applicability.

[0051] The centroid of the spot shape is calculated to obtain the defocus between the focus of the objective lens 7 and the surface of the sample to be measured. ,include: Obtain the laser image formed by the focus point of the defocused light beam on the photosensitive surface of the autofocus sensor 10 to calculate the current center of mass COG n , and obtain the focus sensitivity s and the focus reference center of mass COG corresponding to the focal length of the current zoom mechanism 9 ref , to calculate the defocus .

[0052] Specifically, it includes: Get the focus sensitivity s and focus reference center of mass COG corresponding to the preset current focal length ref Calculate the current center of mass COG of the sample to be tested in the Y direction through the laser image n , the calculation formula of the center of mass of the laser image in the Y direction is as follows: Wherein, f(i,j) is the gray value of the pixel in the i-th row and j-th column in the laser image, t=1, 2, ..., k; i=1, 2, ..., m; j=1, 2, ..., n.

[0053] By current center of mass COG n and the focus reference center of mass COG ref Calculating Defocus , the calculation formula is as follows: The above centroid calculation formula can be used to calculate the current centroid COG of the laser image in the Y direction in real time. n , to match the focus sensitivity s and the focus reference center of mass COG ref Calculating Defocus .

[0054] The focus sensitivity s and the focus reference center of mass COG ref It is calibrated by the calibration method.

[0055] Specifically, the calibration method process is as follows: Step S1: adjusting the focal length of the zoom mechanism 9 to the maximum; Step S2: Control the objective lens 7 to move by the first driving member 8 until the laser image obtained on the auto-focus sensor 10 is a straight line, which indicates that the focus is successful; Step S3: Use the centroid calculation formula of the laser image in the Y direction to calculate the centroid position of the sample under focus to obtain the first centroid COG y1 , and set it as the focus reference center of mass COG ref ; Step S4: Control the objective lens 7 to move by the first driving member 8, the moving distance is t micrometers, and calculate the center of mass of the laser image after the movement in the Y direction to obtain the second center of mass COG y2 ; Step S5: Through COG ref and COG y2 Calculate the sensitivity s of the focusing device using the following formula: Step S6: reducing the focal length of the zoom mechanism 9; Step S7: Repeat steps S2 to S6 to obtain the sensitivity s and focus reference center of mass COG corresponding to different focal lengths ref .

[0056] Determining the defocus amount The amount of separation includes: If the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor 10 is less than the threshold, the calculated defocus value The amount of separation.

[0057] In the present invention, the calculated defocus amount Whether it is accurate needs to be determined. The determination process is based on the gray value of the laser image. Specifically, the gray average value of the laser image is calculated and compared with the preset threshold. If the gray average value of the laser image is less than the threshold, the defocus value is is the defocus value, at which point the sample to be tested is out of focus; if the grayscale average value of the laser image is greater than or equal to the threshold, then the defocus value The movement of the objective lens 7 can be accurately controlled to achieve automatic focusing, and the sample to be measured does not leave the focusing range.

[0058] In the present invention, there is no limitation on the method for calculating the grayscale average value, including but not limited to methods for calculating the grayscale average value of laser images such as weighted average algorithm.

[0059] The preset threshold is set according to the actual situation. Specifically, it needs to be calibrated in advance by detecting whether the grayscale average value of the laser image meets the autofocus requirement.

[0060] The step of increasing the focal length of the zoom mechanism 9 includes: The voltage change value of the zoom mechanism 9 is calculated by the difference between the separation amount and the standard focus range and the corresponding proportional coefficient to obtain the focal length adjustment amount of the zoom mechanism 9; The standard focus range is the focusable range distance value corresponding to the current focal length of the zoom mechanism 9 .

[0061] The focusing range of the sample to be tested depends on the reflectivity of the object's surface. For an object with high reflectivity, the image reflected back to the autofocus sensor can meet the grayscale value requirements even if it is far out of focus. On the contrary, an object with low reflectivity may be out of focus by tens of microns and its image quality will drop sharply.

[0062] Therefore, you can calibrate and set the focus range distance value in advance as the standard focus range. .

[0063] In the present invention, the defocus amount of the sample to be tested can also be The change in the focal length of the zoom mechanism 9 is controlled by the change in the focal length of the zoom mechanism 9, thereby adjusting the focus range of the entire optical path, thereby improving the correlation between the focus range of the entire optical path and the zoom mechanism 9.

[0064] For example, the variable focus lens 91 is a liquid lens and the second driving element 92 is an electrode: When the sample to be tested is out of focus Beyond the standard focus range After that, according to the defocus amount of the sample to be tested With standard focus range The voltage value applied to the variable focus lens 91 is calculated based on the difference, and the formula is as follows: in is the voltage change value, that is, the voltage value to be applied, and h is the proportional coefficient, which can be calibrated in advance. It is related to the magnification of the high-power lens used and can be approximately determined by the ratio of the focus range distance change caused by the voltage change q volts. The formula is as follows: in, is the change in focus distance when the voltage changes by q volts, in mm, where q is the voltage applied during calibration.

[0065] In the present invention, the defocus amount of the sample to be tested can also be The change of the focal length of the zoom mechanism 9 is used to control the change of the focal length of the zoom mechanism 9 and then adjust the focus range of the overall optical path, thereby improving the correlation between the focus range of the overall optical path and the zoom mechanism 9; specifically, the voltage value to be applied to the zoom mechanism 9 is related to the defocus amount of the sample to be tested. The deviation from the standard focus range can be visualized by a formula, and the proportional coefficient in the formula can be obtained by calibration, that is, the defocus amount of the sample to be tested The voltage value to be applied to the zoom mechanism 9 is calculated using a formula, and the focal length to be adjusted is determined using a relationship between the applied voltage and the focal length, thereby improving the correlation between the overall optical path focusing range and the zoom mechanism 9, and having strong applicability.

[0066] In fact, in order to reduce the amount of calculation in the actual program, the actual change in applied voltage is determined by step assignment, which is called the focal length position. With standard focus range Difference When in a certain divided range, the voltage value output by the electrode is determined according to the focal length corresponding to the range.

[0067] The defocus amount , adjusting the height of the objective lens 7 so that the focus of the objective lens 7 is located on the surface of the sample to be measured, including: Convert defocus is a motor driving signal, which drives the motor to move the objective lens 7 so that the focus of the objective lens 7 falls on the surface of the sample to be tested, so as to determine whether the sample to be tested is focused successfully.

[0068] Defocus The first driving member 8 converts the objective lens 7 into a driving signal, and the first driving member 8 drives the objective lens 7 to move to adjust the distance between the objective lens 7 and the sample to be tested for focusing, so that the focus of the objective lens 7 falls on the surface of the sample to be tested, so as to determine that the sample to be tested is focused successfully.

[0069] The step of determining whether the sample to be tested is focused successfully includes: Get the focus sensitivity s and focus reference center of mass COG corresponding to the focal length of the current zoom mechanism 9 ref , and calculate the current center of mass COG through the laser image on the autofocus sensor 10 n , in order to construct a relationship to determine whether the sample under test is focused successfully.

[0070] Specifically, it includes: Get the focus sensitivity s and focus reference center of mass COG ref , calculate the current center of mass COG of the sample to be tested in the Y direction of the laser image n , the relationship is constructed as follows: ; The determination process includes: When satisfied When <0.5s, the current center of mass COG is determined n If it falls within the reference range, it means that the sample under test is in focus successfully at the current focal length. When the current center of mass COG is determined n If it does not fall within the reference range, it means that the sample under test is not focused successfully at the current focal length.

[0071] The above automatic focusing method specifically includes the following steps: Step 1: Turn on the laser 1 and the autofocus sensor 10, so that the light beam passes through the objective lens 7 and is projected onto the surface of the sample to be tested; Step 2: The auto-focus sensor 10 receives the reflected light beam returned from the surface of the sample to be tested and forms a laser image; Step 3: Calculate the current center of mass COG of the laser image corresponding to the current sample to be tested in the Y direction n ; Step 4: Set the current center of mass COG n and the focus reference center of mass COG at the current focal length ref Make a comparison, when satisfied When <0.5s, COG is determined nIf it falls within the reference range, it means that the sample under test is focused successfully at the current focal length, and then execute step 9; otherwise, it is determined that COG n If it is not within the reference range, it means that the sample under test is not focused successfully at the current focal length. Go to step 5, where s is the focus sensitivity in pixels, s and COG ref It is calibrated by the pre-focus calibration method; Step 5: Obtain the laser image formed in the autofocus sensor 10, and calculate the grayscale average value of the laser image, and compare the grayscale average value of the laser image with the threshold value. If the average value reaches the threshold value, it means that the sample to be tested is within the focus range corresponding to the current focal length, and step 7 is executed; if the average value does not reach the threshold value, it means that the sample to be tested is out of the focus range corresponding to the current focal length, and step 6 is executed; Step 6: Increase the focal length of the zoom mechanism 9 to expand the focus range, and repeat steps 2 to 6 until the sample to be tested is within the focus range; Step 7: Pass the current center of mass COG n and the focus reference center of mass COG ref Calculating Defocus , the calculation formula is as follows: Step 8: Adjust the Defocus Amount Converted into a driving signal of the first driving member 8, the first driving member 8 drives the objective lens 7 to move to adjust the distance between the objective lens 7 and the sample to be tested for focusing, and determines whether the sample to be tested is successfully focused at the current focal length, until it is determined that the sample to be tested is successfully focused; Step nine: reduce the focal length of the zoom mechanism 9 to improve the focusing accuracy, and repeat steps two to nine until focusing is completed at the target focal length.

[0072] As the focal length of the zoom mechanism increases, the magnification of the zoom mechanism decreases, resulting in a smaller laser image on the autofocus sensor 10, which affects the calculation of the defocus amount by the centroid. accuracy, thus affecting the final focusing accuracy.

[0073] In the present invention, after completing one autofocus, the focal length can be adjusted continuously to focus again, so that focusing is completed at the target focal length, and the focusing accuracy is guaranteed; specifically, when the sample to be tested is successfully focused at the adjusted focal length, the distance between the objective lens 7 and the sample to be tested changes accordingly, so that the sample to be tested returns to the corresponding focusing range at the previous focal length. Therefore, by lowering the focal length and performing autofocus again at the current focal length, the magnification of the zoom mechanism is increased, thereby increasing the imaging height of the laser image, facilitating the improvement of the focusing accuracy, and repeating the above operation until the sample to be tested is successfully focused at the target focal length. At this time, the focusing accuracy of the sample to be tested is higher, and the autofocus process is completed.

[0074] In the description of this specification, the description with reference to the terms "one embodiment", "example", "specific example", etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.

[0075] The above shows and describes the basic principles, main features and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments, and the above embodiments and descriptions are only for explaining the principles of the present invention. Without departing from the spirit and scope of the present invention, the present invention may have various changes and improvements, and these changes and improvements all fall within the scope of the present invention to be protected.

Claims

1. A microscope autofocus device, characterized in that: include: The autofocus mechanism uses the incident light beam entering from the incident area on one side of the objective lens, focuses on the surface of the sample to be tested through the objective lens, and then reflects through the surface of the sample to be tested and passes through the reflection area on the other side of the objective lens to obtain a reflected light beam. The reflected light beam passes through the original focus lens and converges to the photosensitive surface of the autofocus sensor to form a laser image, so as to calculate the defocus amount between the focus of the objective lens and the surface of the sample to be tested, and adjust the height of the objective lens so that the focus of the objective lens is located on the surface of the sample to be tested; Among them, when the focus of the objective lens does not fall on the surface of the sample to be measured, the reflected light beam generated partially deviates from the reflection area on the other side of the objective lens, so that the reflected light beam does not pass through the objective lens completely, causing the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor to drop below the threshold, so that the defocus amount cannot be calculated; The zoom mechanism is located in front of the autofocus sensor and replaces the original focus lens in the autofocus mechanism. It is used to reduce the magnification of the zoom mechanism by increasing the focal length of the zoom mechanism, thereby reducing the reflected light beam incident on the laser image on the autofocus sensor, making the defocused light beam more concentrated, resulting in an increase in the luminous flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor is greater than a threshold. At this time, effective information is extracted through the image signal corresponding to the laser image on the autofocus sensor to perform centroid calculation, thereby obtaining the defocus amount between the focus of the objective lens and the surface of the sample to be measured.

2. The microscope autofocus device according to claim 1, characterized in that: The zoom mechanism comprises: A variable focus lens for focusing the reflected light beam to an auto focus sensor; The second driving member is used to drive the variable focus lens to adjust the focal length.

3. The microscope autofocus device according to claim 2, characterized in that: The variable focus lens includes a liquid lens or a lens group.

4. A microscope autofocus method, characterized in that: include: Acquire a laser image on the photosensitive surface of the autofocus sensor, calculate the centroid of the spot shape, obtain the defocus amount between the focus of the objective lens and the surface of the sample to be measured, and confirm that the defocus amount is the separation amount; According to the separation amount, the focal length of the zoom mechanism is increased to reduce the magnification of the zoom mechanism, thereby reducing the laser image of the reflected light beam incident on the autofocus sensor, making the defocused light beam more concentrated, resulting in an increase in the luminous flux per unit area, and making the brightness of the laser image higher, so that the grayscale average value of the laser image on the photosensitive surface of the autofocus sensor is greater than the threshold, and the centroid of the spot shape is calculated again to obtain the defocus amount between the focus of the objective lens and the surface of the sample to be measured; According to the defocus amount, adjust the height of the objective lens so that the focal point of the objective lens is located on the surface of the sample to be measured.

5. A microscope autofocus method according to claim 4, characterized in that: The method of calculating the centroid of the light spot shape to obtain the defocus between the focus of the objective lens and the surface of the sample to be measured includes: The laser image formed by the focal point of the defocused light beam on the photosensitive surface of the autofocus sensor is obtained to calculate the current centroid, and the focus sensitivity and focus reference centroid corresponding to the focal length of the current zoom mechanism are obtained to calculate the defocus amount.

6. A microscope autofocus method according to claim 5, characterized in that: The focus sensitivity and the focus reference centroid are obtained by calibration using a calibration method.

7. A microscope autofocus method according to claim 4, characterized in that: The step of confirming that the defocus amount is a separation amount includes: If the average grayscale value of the laser image formed on the photosensitive surface of the autofocus sensor is less than the threshold value, the calculated defocus amount is the separation amount.

8. A microscope autofocus method according to claim 4, characterized in that: The step of increasing the focal length of the zoom mechanism comprises: The voltage change value of the zoom mechanism is calculated by the difference between the separation amount and the standard focus range and the corresponding proportional coefficient to obtain the focal length adjustment amount of the zoom mechanism; The standard focus range is the focus range distance value corresponding to the current focal length of the zoom mechanism.

9. A microscope autofocus method according to claim 4, characterized in that: The step of adjusting the height of the objective lens according to the defocus amount so that the focal point of the objective lens is located on the surface of the sample to be measured comprises: The defocus amount is converted into a motor driving signal to drive the motor to move the objective lens so that the focus of the objective lens falls on the surface of the sample to be tested, so as to determine whether the sample to be tested is in focus successfully.

10. A microscope autofocus method according to claim 9, characterized in that: The step of determining whether the sample to be tested is focused successfully includes: The focus sensitivity and focus reference centroid corresponding to the focal length of the current zoom mechanism are obtained, and the current centroid is calculated through the laser image on the autofocus sensor to construct a relationship to determine whether the focus of the sample to be tested is successful.

Citation Information

Cited By

  • Rapid automatic focusing module and method suitable for fluorescence microscope

    CN119270491A

  • Automatic focusing method and system of high-resolution objective lens

    CN120428412A

  • Industrial focusing method, device and equipment and storage medium

    CN120630432A

  • Double-layer focusing method and system

    CN120762188A

  • Dynamic focusing method and system based on light spot image and medium

    CN120762189A