CN105072330A - Linear array camera automatic focusing method - Google Patents
Linear array camera automatic focusing method Download PDFInfo
- Publication number
- CN105072330A CN105072330A CN201510423786.2A CN201510423786A CN105072330A CN 105072330 A CN105072330 A CN 105072330A CN 201510423786 A CN201510423786 A CN 201510423786A CN 105072330 A CN105072330 A CN 105072330A
- Authority
- CN
- China
- Prior art keywords
- image
- picture
- collected
- automatic focusing
- linear array
- 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.)
- Granted
Links
Landscapes
- Image Analysis (AREA)
- Image Processing (AREA)
- Automatic Focus Adjustment (AREA)
Abstract
The invention discloses a linear array camera automatic focusing method, belonging to the image acquisition field, and especially relates to a linear array camera focusing method. The method comprises: first changing the distance between a shot object and a camera, and meanwhile collecting a target image by a linear array camera; analyzing each collected image and the size of values of image pixels, determining an image not to meet requirements if the image is all black or white, and re-collecting images; splicing all images collected in a whole distance change process into an image; performing gray-scale treatment, de-noising treatment and enhancing treatment on the spliced image; and finally calculating the clearest position in the image, wherein the position at which the image of an object corresponding to the clearest position is collected is a best shooting position. Compared with the prior art, the method has the advantages of low cost, fast speed and small computational complexity.
Description
Technical field
Belong to IMAQ field, particularly a kind of focus adjustment method of line-scan digital camera.
Background technology
Present stage requires higher resolution and precision, makes to adopt line-scan digital camera more and more in the large image scanning field of elongated, belt-shaped.In order to ensure certainty of measurement, wherein most critical is exactly the automatic focusing of line-scan digital camera, and it can affect the picture quality collected, and later image process also can be made to meet difficulty, and even cannot carry out.
Traditional machine visual detection device based on line-scan digital camera, need on the basis of line-scan digital camera increase an area array cameras for auto-focusing, this method problems faced have following some:
1. add equipment cost;
2. equipment needing the space additionally increasing an area array cameras, also needing to carry out extra maintenance to area array cameras when debugging, mechanical complications and the debugging complexity of equipment all increase a lot.
3. traditional face battle array focusing principle is when out of focus, mobile object lens, and gather two pictures and carry out definition contrast, then object lens move to the direction that definition is high.This method needs to gather plurality of pictures and carries out definition analysis, and focusing speed is slow and efficiency is low.
Summary of the invention
The present invention is directed to the weak point of background technology, design the automatic focusing method of the line-scan digital camera that a kind of cost is low, speed is fast, amount of calculation is little.
Technical scheme of the present invention is a kind of automatic focusing method of line-scan digital camera, and the method comprises:
Step 1: change the distance between shot object and camera, with line-scan digital camera, target image is gathered simultaneously;
Step 2: analyze each two field picture collected, analyzed by the size of the value to image slices vegetarian refreshments, if image is entirely black or entirely white, then image is undesirable, re-starts collection;
Step 3: it is piece image that whole distance change procedure is obtained all image mosaic;
Step 4: gray processing process, denoising, enhancing process are carried out to stitching image;
Step 5: to calculate in this image position the most clearly, position during the collected image of object corresponding to this position is optimum photographing position.
The concrete steps of wherein said step 5 are:
Step 5.1: little picture segmentation is carried out to stitching image;
Step 5.2: adopt energy gradient function to carry out preliminary definition judgment to the little picture that 5.1 split, finds in picture of publishing picture and splits picture more clearly;
Step 5.3: adopt wavelet transformation to find out the pixel that in the segmentation picture that step 5.1 obtains, definition is the highest.
The advantage of this method has:
The picture collected have employed energy gradient function and comes Primary Location articulation point position, avoids and uses wavelet transformation to cause a large amount of calculating at the very start; Arithmetic speed can be caught up with actual productive temp completely, finally use wavelet transformation accurately to locate and also ensure that accuracy rate, can the automatic focusing of extensive use line-scan digital camera, large degree saved production cost.
Accompanying drawing explanation
Fig. 1 is that the automatic focusing method of a kind of line-scan digital camera of the present invention adopts drawing system schematic diagram;
Fig. 2 is that the automatic focusing with fuzzy-clear-fuzzy gradual change collected gathers image;
Fig. 3 is the articulation curve calculated with gradient function algorithm, abscissa presentation video coordinate, and ordinate represents definition, and value is more large more clear;
Fig. 4 is the articulation curve calculated by Wavelet Transformation Algorithm.
Embodiment
Step 1: position object being placed on distance camera certain distance, and light filling operation is carried out to object.Then reduce the distance between shot object and camera, with line-scan digital camera, target image is gathered simultaneously;
Step 2: each two field picture using multithread analyzing to collect, is analyzed by the size of the value to image slices vegetarian refreshments, if image is entirely black or entirely white, then image is undesirable, re-starts collection;
Step 3: it is piece image that whole distance reduction process is obtained image mosaic;
Step 4: use floating-point arithmetic to carry out gray processing process, carry out denoising based on medium filtering to stitching image, use the linear transformation in greyscale transformation, between the gray area at outstanding interested target place, between those uninterested gray areas of relative suppression, the dynamic range of image is increased, contrast is expanded, and makes image streak feature more obvious;
Step 5: to calculate in this image position the most clearly, position during the collected image of object corresponding to this position is optimum photographing position.
Step 5.1: obtaining image has fuzzy-clear-fuzzy progressive formation, and stitching image is horizontally divided into multiple little pictures.
Step 5.2: each little picture that step 5.1 obtains has obvious marginal band.To focus good position, namely have the image at more sharp-pointed edge, the gradient function value that Ying Yougeng is large.First use energy gradient function, by the Grad of a Difference Calculation point of consecutive points, this Grad is characterized by the definition numerical value of this position.Obtain the definition values of each little image in this approach, then which little picture the most articulation point of Primary Location is positioned at.As Fig. 3, image does not have enough sharp-pointed crest, so just reach the effect of preliminary focusing, the partial trace that ordinate is greater than 0.9, general 10 little pictures namely, these 10 positions of little picture in stitching image are exactly the articulation point position of Primary Location.
Step 5.3: the image after step 5.2 processes can Primary Location articulation point position, then carries out articulation point to the image of this fraction and accurately locates.Equally first carry out the segmentation of 5.1 steps, then wavelet transformation is used to each little picture, definition can be asked further to image.The degree of clear picture or focusing is primarily of how many decisions of the high fdrequency component in image, and when image is the most clear, the high frequency coefficient energy after wavelet decomposition is maximum.As Fig. 4, because figure has obviously sharp-pointed crest, this crest location, the 6th little picture namely, corresponding image coordinate is exactly articulation point position.
Claims (2)
1. an automatic focusing method for line-scan digital camera, the method comprises:
Step 1: change the distance between shot object and camera, with line-scan digital camera, target image is gathered simultaneously;
Step 2: analyze each two field picture collected, analyzed by the size of the value to image slices vegetarian refreshments, if image is entirely black or entirely white, then image is undesirable, re-starts collection;
Step 3: it is a sub-picture that whole distance change procedure is obtained all image mosaic;
Step 4: gray processing process, denoising, enhancing process are carried out to stitching image;
Step 5: to calculate in this image position the most clearly, position during the collected image of object corresponding to this position is optimum photographing position.
2. the automatic focusing method of a kind of line-scan digital camera as claimed in claim 1, is characterized in that the concrete steps of described step 5 are:
Step 5.1: little picture segmentation is carried out to stitching image;
Step 5.2: adopt energy gradient function to carry out preliminary definition judgment to the little picture that 5.1 split, finds in picture of publishing picture and splits picture more clearly;
Step 5.3: adopt wavelet transformation to find out the pixel that in the segmentation picture that step 5.1 obtains, definition is the highest.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510423786.2A CN105072330B (en) | 2015-07-17 | 2015-07-17 | A kind of automatic focusing method of line-scan digital camera |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510423786.2A CN105072330B (en) | 2015-07-17 | 2015-07-17 | A kind of automatic focusing method of line-scan digital camera |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105072330A true CN105072330A (en) | 2015-11-18 |
CN105072330B CN105072330B (en) | 2019-01-11 |
Family
ID=54501599
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510423786.2A Active CN105072330B (en) | 2015-07-17 | 2015-07-17 | A kind of automatic focusing method of line-scan digital camera |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105072330B (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105635590A (en) * | 2016-02-29 | 2016-06-01 | 中国工程物理研究院流体物理研究所 | Focusing method and device based on digital holographic reconstruction algorithm |
CN105892003A (en) * | 2016-06-15 | 2016-08-24 | 长安大学 | Automatic focusing device and method for line-scan digital camera |
CN109286751A (en) * | 2018-09-28 | 2019-01-29 | 深圳市盛世智能装备有限公司 | A kind of line-scan digital camera focusing method, device, equipment and storage medium |
CN110530889A (en) * | 2018-05-25 | 2019-12-03 | 上海翌视信息技术有限公司 | A kind of optical detecting method suitable for industrial production line |
CN113382134A (en) * | 2021-04-28 | 2021-09-10 | 石家庄铁道大学 | Focusing debugging method of linear array industrial camera |
CN113805304A (en) * | 2021-11-16 | 2021-12-17 | 浙江双元科技股份有限公司 | Automatic focusing system and method for linear array camera |
CN115242982A (en) * | 2022-07-28 | 2022-10-25 | 业成科技(成都)有限公司 | Lens focusing method and system |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102724401A (en) * | 2012-05-18 | 2012-10-10 | 深圳大学 | System and method of linear array CCD camera multi-point automatic focusing |
CN102752511A (en) * | 2012-07-09 | 2012-10-24 | 宁波江丰生物信息技术有限公司 | Linear array scanning system, method and device for obtaining focal point of linear array scanning system |
CN102914320A (en) * | 2012-10-22 | 2013-02-06 | 中国科学院西安光学精密机械研究所 | Linear array CCD (Charge Coupled Device) camera bidirectional modulation transfer function testing device and method |
CN103458158A (en) * | 2013-09-09 | 2013-12-18 | 电子科技大学 | Method and system for controlling time of exposure of line-scan digital camera |
-
2015
- 2015-07-17 CN CN201510423786.2A patent/CN105072330B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102724401A (en) * | 2012-05-18 | 2012-10-10 | 深圳大学 | System and method of linear array CCD camera multi-point automatic focusing |
CN102752511A (en) * | 2012-07-09 | 2012-10-24 | 宁波江丰生物信息技术有限公司 | Linear array scanning system, method and device for obtaining focal point of linear array scanning system |
CN102914320A (en) * | 2012-10-22 | 2013-02-06 | 中国科学院西安光学精密机械研究所 | Linear array CCD (Charge Coupled Device) camera bidirectional modulation transfer function testing device and method |
CN103458158A (en) * | 2013-09-09 | 2013-12-18 | 电子科技大学 | Method and system for controlling time of exposure of line-scan digital camera |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105635590A (en) * | 2016-02-29 | 2016-06-01 | 中国工程物理研究院流体物理研究所 | Focusing method and device based on digital holographic reconstruction algorithm |
CN105635590B (en) * | 2016-02-29 | 2018-10-26 | 中国工程物理研究院流体物理研究所 | A kind of focusing method and device based on digital hologram restructing algorithm |
CN105892003A (en) * | 2016-06-15 | 2016-08-24 | 长安大学 | Automatic focusing device and method for line-scan digital camera |
CN110530889A (en) * | 2018-05-25 | 2019-12-03 | 上海翌视信息技术有限公司 | A kind of optical detecting method suitable for industrial production line |
CN109286751A (en) * | 2018-09-28 | 2019-01-29 | 深圳市盛世智能装备有限公司 | A kind of line-scan digital camera focusing method, device, equipment and storage medium |
CN113382134A (en) * | 2021-04-28 | 2021-09-10 | 石家庄铁道大学 | Focusing debugging method of linear array industrial camera |
CN113382134B (en) * | 2021-04-28 | 2022-04-26 | 石家庄铁道大学 | Focusing debugging method of linear array industrial camera |
CN113805304A (en) * | 2021-11-16 | 2021-12-17 | 浙江双元科技股份有限公司 | Automatic focusing system and method for linear array camera |
CN115242982A (en) * | 2022-07-28 | 2022-10-25 | 业成科技(成都)有限公司 | Lens focusing method and system |
CN115242982B (en) * | 2022-07-28 | 2023-09-22 | 业成科技(成都)有限公司 | Lens focusing method and system |
Also Published As
Publication number | Publication date |
---|---|
CN105072330B (en) | 2019-01-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105072330A (en) | Linear array camera automatic focusing method | |
CN106856002B (en) | Unmanned aerial vehicle shooting image quality evaluation method | |
GB2569751A (en) | Static infrared thermal image processing-based underground pipe leakage detection method | |
CN111047568B (en) | Method and system for detecting and identifying steam leakage defect | |
CN109472788B (en) | Method for detecting flaw on surface of airplane rivet | |
CN101387493B (en) | Shape and position dimension non-contact photoelectric detection method for pylon component hole | |
CN107742307A (en) | Based on the transmission line galloping feature extraction and parameters analysis method for improving frame difference method | |
CN113284154B (en) | Steel coil end face image segmentation method and device and electronic equipment | |
CN113252568A (en) | Lens surface defect detection method, system, product and terminal based on machine vision | |
CN110717909A (en) | Metal surface scratch detection method and device | |
Feng et al. | A separating method of adjacent apples based on machine vision and chain code information | |
CN104749801B (en) | High Precision Automatic optical detecting method and system | |
CN114812450B (en) | Asphalt pavement construction uniformity detection and evaluation method based on machine vision | |
CN110363734B (en) | Thick sample microscopic fluorescence image reconstruction method and system | |
CN115760893A (en) | Single droplet particle size and speed measuring method based on nuclear correlation filtering algorithm | |
Fu et al. | Research on image-based detection and recognition technologies for cracks on rail surface | |
CN109003228B (en) | Dark field microscopic large-view-field automatic stitching imaging method | |
CN105389820A (en) | Infrared image definition evaluating method based on cepstrum | |
CN105608674B (en) | A kind of image enchancing method based on image registration, interpolation and denoising | |
CN102564924B (en) | Automatic scanning method of single-frame image of blood cell | |
CN114170165A (en) | Chip surface defect detection method and device | |
CN112080829B (en) | Binding yarn detection image system | |
CN116681879B (en) | Intelligent interpretation method for transition position of optical image boundary layer | |
CN203479711U (en) | Crankshaft surface detection device | |
TWI381735B (en) | Image processing system and method for automatic adjustment of image resolution for image surveillance apparatus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |