CN-116989667-B - Microscope objective table displacement error calibration method based on Hough transformation image analysis
Abstract
Aiming at the stage displacement error of a microscope, the invention acquires a plurality of images of a universal microscope scale, obtains transverse and longitudinal scale marks of the scale by utilizing Hough transformation image analysis, obtains the actual center point and the horizontal displacement length and the error set by a system through feature analysis and detection, and realizes the accurate center positioning and the accurate horizontal movement of the stage through error compensation. The invention does not need mechanical detection and manual operation, and realizes simple, quick and stable calibration of the microscope stage by an image analysis method.
Inventors
- ZHANG YU
- ZUO CHAO
- CHEN QIAN
- SUN JIASONG
- FAN YAO
- Xiong Tingxiang
- LIU NA
- ZHENG CHENYUE
Assignees
- 南京理工大学
Dates
- Publication Date
- 20260505
- Application Date
- 20230330
Claims (3)
- 1. A microscope stage displacement error calibration method based on Hough transform image analysis is characterized by comprising the following specific steps: The method comprises the steps of firstly, moving an objective table to an uncorrected system optical axis center position, placing a microscope scale in the objective table, and respectively obtaining a plurality of scale images in the transverse direction and the longitudinal direction by taking the uncorrected optical axis center position as the center, specifically, respectively moving the microscope objective table in the transverse direction and the longitudinal direction by controlling 10 equidistant positions, collecting images corresponding to each position, and calculating the center position of the objective table and the real moving position of the objective table in the transverse direction and the longitudinal direction by using scale mark distribution characteristics of the scale in each picture; Converting all recorded color scale images into gray images, performing inverse binary thresholding treatment on the gray images, and binarizing and separating scale marks from a scale background plate; step three, processing the binary image by using Hough transformation, screening transverse and longitudinal scale marks by setting different thresholds, and obtaining coordinates of start and end points of all straight lines, wherein the method comprises the following specific steps: all points of the picture in the space coordinate system are converted into a parameter coordinate system, wherein the transverse scale base lines in the parameter coordinate system all meet the requirement The main scale mark and the auxiliary scale mark of the longitudinal scale are all satisfied According to the specific conditions of the angles and the voting results of the parameter space, reversely pushing out all straight lines meeting the conditions in the space coordinate system, and calculating to obtain start-end coordinates of the straight lines; by setting a threshold value of width of straight line All straight lines are subjected to threshold processing, and the distance is smaller than Is considered as the same straight line, and the coordinates of the most middle straight line are taken as the start and end coordinates of the straight line, the distance is larger than The straight lines of the (a) are identified as different straight lines, and start and end coordinates of all the transverse bottom lines and the longitudinal scale lines are obtained; selecting an image at an uncorrected central position, and calculating a difference value between the central coordinates of the object stage marked by the transverse graduation marks and the longitudinal central graduation marks and the central coordinates of the optical axis marked by the central point of the image, wherein the specific steps are as follows: Setting a length threshold for the transverse scale mark of the scale, and taking only a transverse straight line with the length of the straight line being greater than the length threshold, wherein the straight line is the transverse base line of the scale, so as to further obtain the coordinate of the transverse base line in the longitudinal direction ; For longitudinal graduation lines with regular arrangement of length, a length threshold value between the longitudinal graduation lines is set Screening out long scale marks, and making the length of straight line be greater than The straight line of (2) is used as a longitudinal main scale line, and the central long scale line is identified by the number marked by the scale to obtain the coordinates in the transverse direction ; Will be Stage center coordinates as scale marks; the coordinate is compared with the optical axis center coordinate of the image center point Subtracting to obtain coordinate error And According to the scaling relation from the image surface to the object surface of the optical system, the transverse error between the center coordinate of the object stage of the actual object surface and the center of the optical axis of the system is calculated And longitudinal error ; Detecting the relative movement length in the adjacent images of the same characteristic scale mark on the result after Hough transformation, calculating the actual movement value of the objective table, and subtracting the actual movement distance from the nominal movement distance of the objective table to obtain a return error of the objective table; step six, compensating the error value obtained in the step four on the uncorrected objective table center coordinate to obtain corrected objective table center coordinate, and setting the corrected objective table center coordinate as the corrected objective table center position; And step seven, compensating the obtained return error value on the stage stepping, and setting the compensated value as a new stepping distance, so that the actual displacement length of each movement is consistent with the nominal value.
- 2. The method for calibrating displacement errors of a microscope stage based on Hough transform image analysis according to claim 1, wherein the set length threshold for the scale transverse graduation line is , Is the transverse length of the scale.
- 3. The method for calibrating displacement error of a microscope stage based on hough transform image analysis according to claim 1, wherein the specific steps of detecting the relative movement length in adjacent images of the same characteristic scale line and calculating the actual movement value of the stage from the result of hough transform in step five are: calculating the average distance of 9 times of movement of the transverse scale mark in the longitudinal adjacent images; Converting the average distance to object plane to obtain the actual distance of the longitudinal movement of the object stage ; Calculating the average distance of 9 times of movement of the same longitudinal scale line in the adjacent transverse images; converting the average distance to object plane to obtain the actual distance of the stage moving in transverse direction 。
Description
Microscope objective table displacement error calibration method based on Hough transformation image analysis Technical Field The invention belongs to the technology of optical microscopic imaging and system calibration, and particularly relates to a microscope stage displacement error calibration method based on Hough transformation image analysis. Background The brand new concept of 'computing optics' gives the optical microscope powerful performance, provides specialized observation tools for diversified biological applications, and brings the optical microscope into a totally new era of intellectualization, automation and digitization. The optical microscope is calculated by relying on forward modulation means such as illumination control, aperture regulation and control and the like, microscopic sample information which cannot be observed by naked eyes is extracted by combining strict physical modeling of an optical system, and strict registration, accurate correction and high-precision image processing algorithm of the system are the basis for ensuring the realization of a subsequent imaging function. However, limited by hardware manufacturing level, optical deployment means and detection means, errors often exist in the actual construction of the system and its physical model, which makes it difficult to implement a stable imaging function and acquire high-quality observation images for a computing optical microscope. Disclosure of Invention In order to solve the technical defects in the prior art, the invention provides a microscope stage displacement error calibration method based on Hough transform image analysis. The technical scheme for achieving the purpose of the invention is that the microscope stage displacement error calibration method based on Hough transform image analysis comprises the following specific processes: Step one, moving an objective table to an uncorrected system optical axis center position, placing a microscope scale in the objective table, and respectively acquiring 10 scale images in the transverse direction and the longitudinal direction by taking the uncorrected optical axis center position as a center; Converting all recorded color scale images into gray images, performing inverse binary thresholding treatment on the gray images, and binarizing and separating scale marks from a scale background plate; Step three, processing the binary image by using Hough transformation, deleting transverse and longitudinal scale marks by setting different thresholds, and obtaining start and end point coordinates of all straight lines; Selecting an image at an uncorrected central position, and calculating the difference value between the central coordinates of the object stage marked by the transverse graduation mark and the longitudinal central graduation mark and the central coordinate of the optical axis marked by the central point of the image; detecting the relative movement length in the adjacent images of the same characteristic scale mark on the result after Hough transformation, calculating the actual movement value of the objective table, and subtracting the actual movement distance from the nominal movement distance of the objective table to obtain a return error of the objective table; step six, compensating the error value obtained in the step four on the uncorrected objective table center coordinate to obtain corrected objective table center coordinate, and setting the corrected objective table center coordinate as the corrected objective table center position; And step seven, compensating the obtained return error value on the stage stepping, and setting the compensated value as a new stepping distance, so that the actual displacement length of each movement is consistent with the nominal value. Preferably, in the first step, the microscope stage is controlled to move 10 equidistant positions in the transverse direction and the longitudinal direction respectively, images corresponding to each position are acquired, and the center position of the stage and the actual moving positions of the stage in the transverse direction and the longitudinal direction can be calculated through the scale mark distribution characteristics of the scale in each picture. Preferably, in the third step, the hough transform is used to process the binary image, and the specific steps of deleting the transverse scale line and the longitudinal scale line by setting different thresholds and obtaining the coordinates of the start point and the end point of all the straight lines are as follows: all points of the picture in a space coordinate system are converted into a parameter coordinate system, in the parameter coordinate system, the transverse scale base lines meet θ=90°, the longitudinal scale main scale lines and the auxiliary scale lines meet θ=0, and according to specific conditions of angles and voting results of a parameter space, all straight lines meeting the conditions in the space coo