[go: up one dir, main page]

CN100451807C - Hadamard transformation based digital micro imaging automatic focusing method - Google Patents

Hadamard transformation based digital micro imaging automatic focusing method Download PDF

Info

Publication number
CN100451807C
CN100451807C CNB2006100530520A CN200610053052A CN100451807C CN 100451807 C CN100451807 C CN 100451807C CN B2006100530520 A CNB2006100530520 A CN B2006100530520A CN 200610053052 A CN200610053052 A CN 200610053052A CN 100451807 C CN100451807 C CN 100451807C
Authority
CN
China
Prior art keywords
image
hadamard transformation
hadamard
focusing
evaluation function
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CNB2006100530520A
Other languages
Chinese (zh)
Other versions
CN1908801A (en
Inventor
蒋刚毅
郁梅
易文娟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ningbo University
Original Assignee
Ningbo University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ningbo University filed Critical Ningbo University
Priority to CNB2006100530520A priority Critical patent/CN100451807C/en
Publication of CN1908801A publication Critical patent/CN1908801A/en
Application granted granted Critical
Publication of CN100451807C publication Critical patent/CN100451807C/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Studio Devices (AREA)
  • Automatic Focus Adjustment (AREA)

Abstract

The disclosed digital micro-imaging auto-focus method based on Hadamard transformation comprises: taking Hadamard transformation to 2D signal of every image to obtain the transformation coefficient matrix and define the focus evaluation function F as the weight sum of the coefficients; calculating the F value for every image to decide the variation trend to regulate and obtain the optimal image. Compared with prior art, this invention has well imaging performances and anti-noise feature, and convenient to hardware implementation.

Description

Based on the digital micro imaging of the Hadamard conversion method of focusing automatically
Technical field
The present invention relates to the digital image-forming method of focusing automatically, especially relate to a kind of digital micro imaging method of focusing automatically based on the Hadamard conversion.
Background technology
In imaging system, camera lens has a best image planes position to object image-forming, departs from this position and will cause image blurringly, and image quality descends; Can therefore, accurately focus to an imaging system be crucial.Imaging system based on digital picture adopts automatic focusing method, and its key is focusing evaluation function.Desirable focusing evaluation function curve shows as the class parabolic shape, and its peak value is corresponding to the optimal imaging position, and the focusing evaluation function value reduces when leaving optimum.Therefore automatic focusing process essence is to ask for the peaked process of focusing evaluation function.
Usually, the energy major part of image concentrates on the low frequency and the Mid Frequency of image frequency domain, but the richness of the acutance of image outline and details then depends on the high frequency composition of image.When clear picture, details is abundant, and eigenwert (as gray scale, the color etc.) variation that shows as neighbor on the spatial domain is bigger, and the high fdrequency component that then shows as frequency spectrum at frequency domain is many.Focusing evaluation function commonly used is divided into two kinds: the spatial domain with frequency domain.Several spatial domains focusing evaluation function commonly used comprises Laplacian operator, Sobel operator, Prewitt operator and energy variance operator etc.Less relatively based on the operand that the focusing evaluation method in spatial domain is required, but its shortcoming is to be subjected to The noise bigger, and promptly noise immunity is relatively poor.Frequency domain focusing evaluation method then needs earlier image to be carried out Fourier transform or other conversion, comes the sharpness of evaluation map picture again according to conversion coefficient.The focusing evaluation method of frequency domain is utilized the overall permanence of image, but calculated amount is often very big.Therefore, how to reduce the key issue that computation complexity is a frequency domain focusing evaluation method.
The invention provides a kind of fast automatic focusing method based on the Hadamard conversion, this method not only possesses the advantage of frequency domain focusing evaluation method, and calculated amount is little, is easy to hardware and realizes.
Summary of the invention
Technical matters to be solved by this invention provide a kind of calculated amount little, be easy to the hard-wired digital micro imaging method of focusing automatically.
The present invention solves the problems of the technologies described above the technical scheme that is adopted: a kind of digital micro imaging based on Hadamard conversion method of focusing automatically, it may further comprise the steps: 1. for the digital micro imaging system, continuously focusing is with the two-dimentional input signal f of the image that obtains sharpness and have nothing in common with each other; 2. the two-dimentional input signal f to every width of cloth image carries out the Hadamard conversion, obtains Hadamard transform coefficient matrix H=h nFh n, h wherein nBe the Hadarmard transformation matrix; 3. define focusing evaluation function F and be Hadamard conversion coefficient in the region R ange weighted energy and F = Σ ( i , j ) ∈ Range w k H i , j 2 Or F = Σ ( i , j ) ∈ Range w k | H i , j | , In the formula, H I, jBe Hadamard conversion coefficient, w kBe H I, jWeight, k=1,2, ..., K, K are the number of Hadamard conversion coefficient among the Range, Range represents the coordinate set of some conversion coefficients selected among the Hadamard transform coefficient matrix H, the input signal of every width of cloth image is calculated the value of its focusing evaluation function F; 4. when the variation tendency of focusing back focusing evaluation function F value changed continuously, the readjustment focal length occurred until the image input signal corresponding to focusing evaluation function F maximum value, finishes the focusing process then; 5. get the image that promptly obtains sharpness the best of correct focusing corresponding to the image of the focusing evaluation function F maximum value of input signal.
Two dimension input signal f can be Zone Full signal or the regional area signal or the down-sampled signal of digital micro imaging image.
Region R ange can be the coordinate set of some high frequency conversion coefficients selected among the Hadamard transform coefficient matrix H.
Hadamard transform coefficient matrix H can be refined as 4 * 4 zoned format, and choose the focusing evaluation function F calculating selected region R ange of the zone of the 3rd row the 3rd row as the Hadamard conversion.
Compare with existing classical focusing evaluation method, the method for focusing automatically of the digital micro imaging based on the Hadamard conversion of the present invention not only has unimodality, unbiasedness, can reflect the fundamental characteristics such as polarity of out of focus, and has good noiseproof feature.Simultaneously, because the Hadamard conversion has only plus and minus calculation, need not to carry out multiplying, the calculated amount of conversion own is very low, so the inventive method also possesses characteristics such as algorithm is simple, fast operation.
Description of drawings
Fig. 1 (a) is the micro-image of the fuzzy axis section of focusing;
Fig. 1 (b) is the micro-image of the axis section clearly of focusing;
Fig. 2 is 4 * 4 zoned formats of Hadamard transform coefficient matrix H;
Fig. 3 is the focusing evaluation result of different focus evaluation method to 1024 * 1280 input pictures;
Fig. 4 is the focusing evaluation result of different focus evaluation method to 512 * 512 central areas of intercepting original image;
Fig. 5 is the focusing evaluation result of different focus evaluation method to the noisy image in 512 * 512 central areas of intercepting original image.
Embodiment
Embodiment describes in further detail the present invention below in conjunction with accompanying drawing.
A kind of digital micro imaging based on Hadamard conversion method of focusing automatically is characterized in that it may further comprise the steps: 1. for the digital micro imaging system, focusing is with the input signal of the image that obtains sharpness and have nothing in common with each other continuously; 2. the two-dimentional input signal f to every width of cloth image carries out the Hadamard conversion, obtains Hadamard transform coefficient matrix H=h nFh n, the Hadamard transformation matrix h of 2D signal nCan be by kernel matrix h 1 = 1 2 1 1 1 - 1 Recursion obtains: h n = h n - 1 ⊗ h 1 = h 1 ⊗ h n - 1 = 1 2 h n - 1 h n - 1 h n - 1 - h n - 1 , Wherein
Figure C20061005305200053
It is the symbol of the straight base of matrix (Kronecker); 3. define focusing evaluation function F and be Hadamard conversion coefficient in the region R ange weighted energy and F = Σ ( i , j ) ∈ Range w k H i , j 2 , In the formula, H I, jBe Hadamard conversion coefficient, i.e. H I, jFor being positioned at position (i, coefficient j), w among the H kBe H I, jWeight, k=1,2, ..., K, K are the number of Hadamard conversion coefficient among the Range, Range represents the coordinate set of some conversion coefficients selected among the Hadamard transform coefficient matrix H, the input signal of every width of cloth image is calculated the value of its focusing evaluation function F; 4. when continuously the variation tendency of focusing back focusing evaluation function F value changes (becoming successively decreases or become by successively decreasing increases progressively by increasing progressively), the readjustment focal length finishes the focusing process then until the image input signal appearance corresponding to focusing evaluation function F maximum value; 5. get the image that promptly obtains sharpness the best of correct focusing corresponding to the image of the focusing evaluation function F maximum value of input signal.
In order to reduce computation complexity, reach the purpose of rapid focus, the focusing evaluation function in the said method also can adopt as giving a definition F = Σ ( i , j ) ∈ Range w k | H i , j | .
In said method, the Zone Full that two-dimentional input signal f can be the digital micro imaging image or the combination or the down-sampled signal of regional area or regional area.
Because the high frequency composition of image has characterized the acutance of image outline and the richness of details, therefore the high frequency coefficient that can choose the Hadamard transform coefficient matrix usually calculates focusing evaluation function, even Range is the coordinate set of some high frequency conversion coefficient among the Hadamard transform coefficient matrix H.But consider the noiseproof feature of focusing evaluation function F, also can suitably select part intermediate frequency and low frequency coefficient weighting to count among the focusing evaluation function F, promptly choose Range and be the coordinate set of some high frequency and medium and low frequency conversion coefficient among the Hadamard transform coefficient matrix H.
The part coefficient that digital micro imaging focusing method automatically based on the Hadamard conversion of the present invention has been chosen the Hadamard frequency domain particularly high frequency coefficient calculates focusing evaluation function, the advantage of existing frequency domain focusing method, utilize the Hadamard conversion to need not the very low characteristics of multiplying, calculated amount again, overcome the big shortcomings of general frequency domain focusing method calculated amount such as Fourier transform, discrete cosine transform, sine transform, wavelet transformation.
The micro-image (picture size is 1024 * 1280) of the pumpkin stem section that the sharpness that is obtained for one group of continuous focusing has nothing in common with each other has carried out the focusing test, Fig. 1 (a) has provided the different image of 2 width of cloth focusing degree wherein with Fig. 1 (b), and Fig. 1 (a) is fuzzy, Fig. 1 (b) is clear.In the practical application since the image of gathering often size is bigger, for quickening the speed of focusing automatically, can be from original image the selection portion subregion as the focusing zone.In the present embodiment, Hadamard transform coefficient matrix H is refined as shown in Figure 24 * 4 zoned format, and chooses wherein zone 11 as the medium-high frequency part of Hadamard transform domain, selected region R ange during promptly focusing evaluation function F calculates.
In image acquisition process, because the relation of actual imaging condition tends to introduce certain noise, therefore good focusing evaluation method need possess good noiseproof feature.Present embodiment provides the contrast and experiment of utilizing the automatic focusing evaluation method based on the Hadamard conversion of the present invention and classical focusing evaluation method under following three kinds of situations:
Situation-1. adopt original image, picture size is 1024 * 1280;
The middle section of the intercepting of situation-2. original image 512 * 512;
The middle section of the intercepting of situation-3. original image 512 * 512, and to apply variance after the normalization be 0.1 white Gaussian noise.
Fig. 3, Fig. 4, Fig. 5 have provided respectively under above-mentioned three kinds of situations, automatic focusing method and the classics experimental result contrast of focusing method automatically based on the Hadamard conversion of the present invention.
Classics that present embodiment is selected for use focusing evaluation method comprises: Laplacian operator, Sobel operator, Prewitt operator, energy variance operator and based on the focusing evaluation method of wavelet transformation.In Fig. 3, Fig. 4, Fig. 5, curve hadamard represents the present invention's evaluation method of focusing, laplacian represents to adopt the focusing evaluation method of Laplacian operator, sobel represents to adopt the focusing evaluation method of Sobel operator, prewitt represents to adopt the focusing evaluation method of Prewitt operator, standard represents to adopt the focusing evaluation method of energy variance operator, and wavelet represents the focusing evaluation method based on wavelet transformation.
Desirable focusing evaluation function not only should have unimodality, unbiasedness, the polarity fundamental characteristics such as (still are defocused position in burnt front position) that can reflect out of focus, and reply is subjected to the image of noise to have good noiseproof feature, also should possess characteristics such as algorithm is simple, fast operation simultaneously.Interpretation to Fig. 3, Fig. 4 and Fig. 5 can get: under above-mentioned preceding two kinds of situations (being situation-1, situation-2), the peak value of classical focusing evaluation function and the focusing evaluation function based on the Hadamard conversion of the present invention is all corresponding to the 8th width of cloth image, can think that this image is the accurate focusing position of this series micro-image, wherein the focusing evaluation function curve based on the automatic focusing evaluation method of Hadamard conversion is the most precipitous, shows its focusing best performance.Under the third situation (being situation-3), be subjected to when input picture under the situation of noise, show by experimental result shown in Figure 5, classical focusing evaluation method generally is subjected to influence in various degree, even generation peakdeviation, it is the picture numbers that evaluation result has departed from actual accurate focusing, focusing evaluation method based on the Hadamard conversion of the present invention has then kept good unimodality and accuracy, demonstrates the automatic focusing method based on the Hadamard conversion of the present invention and has good noise immunity.
In sum, compare with existing classical focusing evaluation method, the focusing evaluation method based on the Hadamard conversion of the present invention not only has unimodality, unbiasedness, can reflect the fundamental characteristics such as polarity of out of focus, and has good noiseproof feature.Simultaneously, because the Hadamard conversion only need carry out signed magnitude arithmetic(al), do not have multiplying, the calculated amount of conversion own is very low, so the inventive method also possesses characteristics such as algorithm is simple, fast operation.
Obviously, digital micro imaging focusing method automatically based on the Hadamard conversion of the present invention is not limited in the digital micro imaging field, can utilize the present invention well at digital image capture devices such as image scanner, video camera, digital cameras, therefore under the situation of the spirit and scope of the universal that does not deviate from claim and equal scope and limited, the example that the present invention is not limited to specific details and illustrates here and describe.

Claims (4)

1、一种基于Hadamard变换的数码显微成像自动对焦方法,其特征在于它包括以下步骤:①对于数码显微成像系统,连续调焦以获得清晰度各不相同的图像的二维输入信号f;②对每幅图像的二维输入信号f进行Hadamard变换,获得Hadamard变换系数矩阵H=hnfhn,其中hn为Hadamard变换矩阵;③定义对焦评价函数F为区域Range内Hadamard变换系数的加权能量和 F = Σ ( i , j ) ∈ Range w k H i , j 2 F = Σ ( i , j ) ∈ Range w k | H i , j | , 式中,Hij为Hadamard变换系数,wk为Hi,j的权重,k=1,2,...,K,K为Range中Hadamard变换系数的个数,Range代表Hadamard变换系数矩阵H中所选定的变换系数的坐标集合,对每幅图像的输入信号计算其对焦评价函数F的值;④当连续调焦后对焦评价函数F值的变化趋势变化时,回调焦距直至对应于对焦评价函数F极大值的图像输入信号出现,然后结束调焦过程;⑤取对应于输入信号的对焦评价函数F极大值的图像即获得正确对焦的清晰度最佳的图像。1, a kind of digital microscopic imaging autofocus method based on Hadamard transformation, it is characterized in that it comprises the following steps: 1. for digital microscopic imaging system, continuous focusing obtains the two-dimensional input signal f of the image that clarity is different ; 2. Perform Hadamard transformation on the two-dimensional input signal f of each image to obtain the Hadamard transformation coefficient matrix H=h n fh n , where h n is the Hadamard transformation matrix; 3. Define the focus evaluation function F as the Hadamard transformation coefficient in the area Range weighted energy and f = Σ ( i , j ) ∈ Range w k h i , j 2 or f = Σ ( i , j ) ∈ Range w k | h i , j | , In the formula, H ij is the Hadamard transformation coefficient, w k is the weight of Hi , j , k=1, 2, ..., K, K is the number of Hadamard transformation coefficients in Range, and Range represents the Hadamard transformation coefficient matrix H The coordinate set of the transformation coefficient selected in , calculate the value of the focus evaluation function F for the input signal of each image; ④ When the change trend of the focus evaluation function F value changes after continuous focusing, the focal length is called back until it corresponds to the focus The image input signal with the maximum value of the evaluation function F appears, and then the focusing process ends; ⑤ Take the image corresponding to the maximum value of the focus evaluation function F of the input signal to obtain the image with the best definition and correct focus. 2、如权利要求1所述的基于Hadamard变换的数码显微成像自动对焦方法,其特征在于二维输入信号f是数码显微成像图像的全部区域信号或局部区域信号或下采样信号。2. The digital microscopic imaging autofocus method based on Hadamard transform as claimed in claim 1, characterized in that the two-dimensional input signal f is the whole area signal or local area signal or downsampled signal of the digital microscopic imaging image. 3、如权利要求1所述的基于Hadamard变换的数码显微成像自动对焦方法,其特征在于区域Range为Hadamard变换系数矩阵H中所选定的高频变换系数的坐标集合。3. The digital microscopic imaging autofocus method based on Hadamard transformation as claimed in claim 1, characterized in that the range Range is the coordinate set of high-frequency transformation coefficients selected in the matrix H of Hadamard transformation coefficients. 4、如权利要求1所述的基于Hadamard变换的数码显微成像自动对焦方法,其特征在于:将Hadamard变换系数矩阵H细化为4×4的划分形式,并选取第3行第3列的区域作为Hadamard变换的对焦评价函数F计算所选取的区域Range。4. The digital microscopic imaging autofocus method based on Hadamard transformation as claimed in claim 1, characterized in that: the Hadamard transformation coefficient matrix H is refined into a 4 × 4 division form, and the third row and the third column are selected. The area is used as the focus evaluation function F of the Hadamard transformation to calculate the selected area Range.
CNB2006100530520A 2006-08-22 2006-08-22 Hadamard transformation based digital micro imaging automatic focusing method Expired - Fee Related CN100451807C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006100530520A CN100451807C (en) 2006-08-22 2006-08-22 Hadamard transformation based digital micro imaging automatic focusing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006100530520A CN100451807C (en) 2006-08-22 2006-08-22 Hadamard transformation based digital micro imaging automatic focusing method

Publications (2)

Publication Number Publication Date
CN1908801A CN1908801A (en) 2007-02-07
CN100451807C true CN100451807C (en) 2009-01-14

Family

ID=37699940

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006100530520A Expired - Fee Related CN100451807C (en) 2006-08-22 2006-08-22 Hadamard transformation based digital micro imaging automatic focusing method

Country Status (1)

Country Link
CN (1) CN100451807C (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101813823A (en) * 2010-03-22 2010-08-25 中国科学院长春光学精密机械与物理研究所 A method for automatic focusing of an astronomical telescope

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9398205B2 (en) * 2010-09-01 2016-07-19 Apple Inc. Auto-focus control using image statistics data with coarse and fine auto-focus scores
CN102788682B (en) * 2012-07-25 2015-02-04 宁波大学 Method for detecting parfocality of continuous zoom stereo microscope
CN106249325B (en) * 2016-10-14 2017-12-19 北京信息科技大学 A kind of quick focus adjustment method of bionical vision based on liquid lens
CN109934801A (en) * 2019-01-25 2019-06-25 淮阴师范学院 A method for realizing image focus measurement based on block Hadamard transform

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0678202A (en) * 1992-08-28 1994-03-18 Konica Corp Automatic focusing device
JP2003121392A (en) * 2001-10-19 2003-04-23 Mitsui Eng & Shipbuild Co Ltd Radiation detector
US6996292B1 (en) * 2002-04-18 2006-02-07 Sandia Corporation Staring 2-D hadamard transform spectral imager
CN1767655A (en) * 2005-10-18 2006-05-03 宁波大学 A method for disparity estimation of multi-viewpoint video images

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0678202A (en) * 1992-08-28 1994-03-18 Konica Corp Automatic focusing device
JP2003121392A (en) * 2001-10-19 2003-04-23 Mitsui Eng & Shipbuild Co Ltd Radiation detector
US6996292B1 (en) * 2002-04-18 2006-02-07 Sandia Corporation Staring 2-D hadamard transform spectral imager
CN1767655A (en) * 2005-10-18 2006-05-03 宁波大学 A method for disparity estimation of multi-viewpoint video images

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101813823A (en) * 2010-03-22 2010-08-25 中国科学院长春光学精密机械与物理研究所 A method for automatic focusing of an astronomical telescope

Also Published As

Publication number Publication date
CN1908801A (en) 2007-02-07

Similar Documents

Publication Publication Date Title
CN100399183C (en) Adaptive Autofocus Method in Digital Camera
US6268611B1 (en) Feature-free registration of dissimilar images using a robust similarity metric
CN102970547B (en) Image processing apparatus, image capture apparatus and image processing method
CN101441320B (en) A high dynamic image acquisition device and method based on microscopic imaging detection
Zhang et al. A new focus measure method using moments
CN100451807C (en) Hadamard transformation based digital micro imaging automatic focusing method
US7990462B2 (en) Simple method for calculating camera defocus from an image scene
US7583442B2 (en) Extended depth of field optical systems
JP2009239908A (en) Method, system and software for multiframe reconstruction
JPH11500235A (en) Optical system with extended depth of field
CN105657237B (en) Image acquisition device and digital zooming method thereof
TW200828994A (en) Autofocus searching method
CN114119367B (en) Interpolation method for super-resolution reconstruction of regional synchronous phase-shift interferogram
US6710806B1 (en) Automatically focusing system and focusing method therefor
CN113852761B (en) Automatic focusing method for intelligent digital microscope
Li et al. Learning dual-pixel alignment for defocus deblurring
CN101726829A (en) Method for automatically focusing zoom lens
CN113810615A (en) Focusing processing method and device, electronic equipment and storage medium
Kwon et al. All-in-focus imaging using average filter-based relative focus measure
CN107959767B (en) Focusing and dimming method using television tracking result as guide
JP2019016975A (en) Image processing system and image processing method, imaging apparatus, program
CN116489513A (en) Automatic focusing method and device, electronic equipment and storage medium
Widjaja et al. Use of wavelet analysis for improving autofocusing capability
Favaro Depth from focus/defocus
CN109102476B (en) A Defocus Blur Kernel Estimation Method for Multispectral Images Based on Dispersion Circle Fitting

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20090114

Termination date: 20160822

CF01 Termination of patent right due to non-payment of annual fee