CN104463827A - Image acquisition module automatic detection method and corresponding electronic device - Google Patents

Image acquisition module automatic detection method and corresponding electronic device Download PDF

Info

Publication number
CN104463827A
CN104463827A CN201310425088.7A CN201310425088A CN104463827A CN 104463827 A CN104463827 A CN 104463827A CN 201310425088 A CN201310425088 A CN 201310425088A CN 104463827 A CN104463827 A CN 104463827A
Authority
CN
China
Prior art keywords
image
region
camera lens
sample
sample image
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
Application number
CN201310425088.7A
Other languages
Chinese (zh)
Other versions
CN104463827B (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.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing Ltd
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 Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201310425088.7A priority Critical patent/CN104463827B/en
Publication of CN104463827A publication Critical patent/CN104463827A/en
Application granted granted Critical
Publication of CN104463827B publication Critical patent/CN104463827B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/30Determination of transform parameters for the alignment of images, i.e. image registration
    • G06T7/33Determination of transform parameters for the alignment of images, i.e. image registration using feature-based methods
    • G06T7/337Determination of transform parameters for the alignment of images, i.e. image registration using feature-based methods involving reference images or patches
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N17/00Diagnosis, testing or measuring for television systems or their details
    • H04N17/002Diagnosis, testing or measuring for television systems or their details for television cameras

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Studio Devices (AREA)

Abstract

An image acquisition module automatic detection method and a corresponding electronic device are provided; the method uses the image acquisition module to collect a plurality of images, and at least two images are selected to serve as sample images; analyzes the sample image so as to determine whether the image acquisition module complies with acquisition requirements or not; if not, a corresponding instruction is generated and executed; correspondingly, the electronic device comprises a selection module, an analysis module, and a processing module; the method and device can timely detect a blot zone, formed by defects of the image acquisition device, in a digital image, so a user can timely learn about the state of the image acquisition device so as to take measures, thus stopping videoing after the image acquisition device is polluted, and causing bad quality image to lost usage and preservation values.

Description

A kind of automatic testing method of image capture module and corresponding electronic equipment
Technical field
The present invention relates to technical field of image processing, particularly relate to a kind of detection method of image capture module and corresponding electronic equipment.
Background technology
Day by day universal at present along with digital vedio recording series products, the electronic equipment such as mobile terminal or Pad generally has camera, and the happy application software of enjoying wherein of the users such as microblogging, also promote the demand of user to the pickup quality of the handheld devices such as Phone/Pad.Therefore, the enhancement and treatment of digital picture becomes a new research field.
Affect a lot of because have of photographic quality in actual use, one of them more typical reason is exactly because apparatus for making a video recording is poorly sealed, trickle dust can enter filming apparatus inside, and be adsorbed under the effect of electrostatic on photo-sensitive cell, when thus taking imaging, stains can be left in photo.
The present inventor is realizing in process of the present invention, finds that prior art at least exists following technological deficiency:
User is when taking pictures, often be difficult to pick out at digital vedio recording series products as whether the camera lens at Phone/Pad back has stains only according to naked eyes, when user find take pictures quality be reduced to a certain degree time, camera lens is covered with the pollutions such as fingerprint in fact, has a strong impact on captured photographic quality.
Summary of the invention
Technical matters to be solved by this invention is to provide a kind of automatic testing method of image capture module and corresponding electronic equipment, automatically can detect the problem of image capture module, avoid affecting image quality.
In order to solve the problems of the technologies described above, the invention provides a kind of automatic testing method of image capture module, being applied to electronic equipment, comprising:
Gather multiple image by image capture module, from described multiple image, select at least two width images as sample image;
Described sample image is analyzed, determines whether described image capture module meets collection requirement;
As described in image capture module do not meet collection requirement, generate the corresponding command and also perform.
Preferably, described sample image is analyzed, determines whether described image capture module meets collection requirement, comprising according to analysis result:
Described sample image is compared, be extracted in one or more characteristic areas with same characteristic features that different sample image all exists, to each characteristic area, statistics possesses the sample image number of this characteristic area, as this sample image number be greater than predetermined threshold time, determine that described image acquisition units does not meet collection requirement, wherein, described characteristic area is that described image capture module does not meet the subregion gathering and formed on image when requiring.
Preferably, described image capture module comprises camera lens;
Described sample image is analyzed, determine whether described image capture module meets collection requirement according to analysis result, comprise: determine whether described camera lens exists stains according to described sample image analysis result, if there are stains, then determine that described camera lens does not meet collection requirement;
As described in image capture module do not meet collection requirement, generate the corresponding command and perform described order, comprise: as described in camera lens do not meet collection requirement, then generating prompting camera lens has the order of stains and has stains by the display unit of described electronic equipment prompting user camera lens.
Preferably, described sample image refers in image have solid color regions to cover at least one region to be detected and acquisition time distance current time is less than the image of setting duration threshold value, wherein, described region to be detected is whole image-region or whole image-region is divided to the subregion obtained.
Preferably, determine whether described camera lens exists stains according to described sample image analysis result, comprising:
After the association sample image having solid color regions to cover same region to be detected is more than or equal to the first sample number threshold value k1 of setting, start the analysis to this region to be detected, k1 >=2;
If have at least k2 to associate sample image at this region memory to be detected at shape first image-region identical with position, then determine that described camera lens exists stains, wherein, k2 is the second sample number threshold value of setting, 2≤k2≤k1;
Wherein, described first image-region be this region memory to be detected connected region, and in this connected region the average brightness value of all pixels lower than the average brightness value of all pixels in other regions in this region to be detected and the absolute value of difference is greater than the brightness value threshold value of setting.
Preferably, described sample image comprises m1 group image, and often organize image and comprise the image of several continuous acquisition and acquisition time distance current time is less than the duration threshold value of setting, wherein, m1 is the first image sets number threshold value of setting, m1 >=2;
Determine whether described camera lens exists stains according to described sample image analysis result, comprising:
To each group image, find out the moving object that exists in this group image and record shape and the size of each moving object;
If have at least m2 group image to there is the moving object of same shape and size, then determine that described camera lens exists stains, wherein, m2 is the second image sets number threshold value of setting, 2≤m2≤m1.
Preferably, described sample image is when performing pre-acquired operation, by the multiple image of camera lens continuous acquisition;
Determine whether described camera lens exists stains according to described sample image analysis result, comprising:
Image region is extracted from described sample image, obtain described subregion coordinate information in the picture, the coordinate information of image region described in more each sample image, when as having at least two width sample images existing the constant image region of at least one coordinate, then determine that described camera lens exists stains.
The present invention also provides a kind of electronic equipment, and comprise the automatic detection device to image capture module, automatic detection device comprises:
Select module, for selecting at least two width images as sample image from the multiple image gathered by image capture module;
Analysis module, analyzes described sample image, determines whether described image capture module meets collection requirement;
Processing module, for do not meet at described image capture module collection require time, generate the corresponding command and also perform.
Preferably, described analysis module is analyzed described sample image, determines whether described image capture module meets collection requirement, comprising according to analysis result:
Described sample image is compared, be extracted in one or more characteristic areas with same characteristic features that different sample image all exists, to each characteristic area, statistics possesses the sample image number of this characteristic area, as this sample image number be greater than predetermined threshold time, determine that described image acquisition units does not meet collection requirement, wherein, described characteristic area is that described image capture module does not meet the subregion gathering and formed on image when requiring.
Preferably, described image capture module comprises camera lens;
Described analysis module is analyzed described sample image, determine whether described image capture module meets collection requirement according to analysis result, comprise: determine whether described camera lens exists stains according to described sample image analysis result, if there are stains, then determine that described camera lens does not meet collection requirement;
Described processing module described image capture module do not meet collection require time, generate the corresponding command and perform described order, comprise: as described in camera lens do not meet collection requirement, then generating prompting camera lens has the order of stains and has stains by the display unit of described electronic equipment prompting user camera lens.
Preferably, the sample image of described selection model choice has solid color regions to cover at least one region to be detected and acquisition time distance current time is less than the image of setting duration threshold value, wherein, described region to be detected is whole image-region or whole image-region is divided to the subregion obtained.
Preferably, described analysis module comprises again:
Start unit, after being more than or equal to the first sample number threshold value k1 of setting at the association sample image having solid color regions to cover same region to be detected, starts the analysis to this region to be detected, k1 >=2;
Arithmetic element, for determine described association sample image this region memory to be detected the first image-region and the shape of described first image-region and the positional information in whole image;
Judging unit, for have at least k2 associate sample image this region memory to be detected at the first image-region that shape is identical with position time, determine that described camera lens exists stains, wherein, k2 be setting the second sample number threshold value, 2≤k2≤k1;
Wherein, described first image-region refer to this region memory to be detected connected region, and in this connected region the average brightness value of all pixels lower than the average brightness value of all pixels in other regions in this region to be detected and the absolute value of difference is greater than the brightness value threshold value of setting.
Preferably, the described sample image of described selection model choice comprises m1 group image, often organizes image and comprises the image of several continuous acquisition and acquisition time distance current time is less than the duration threshold value of setting, wherein, m1 is the first image sets number threshold value of setting, m1 >=2;
Described analysis module comprises again:
Capture unit, to each group image, finds out the moving object that exists in this group image and records shape and the size of each moving object;
Judging unit, for when having at least m2 group image to there is the moving object of same shape and size, then determines that described camera lens exists stains, and wherein, m2 is the second image sets number threshold value of setting, 2≤m2≤m1.
Preferably, the sample image of described selection model choice is when performing pre-acquired operation, by the multiple image of camera lens continuous acquisition;
Described analysis module comprises again:
Collecting unit, for extracting image region from described sample image, obtains described image region coordinate information in the picture;
Judging unit, for the coordinate information of characteristic area described in more each sample image, when as having at least two width sample images existing the constant characteristic area of at least one coordinate, then determines that described camera lens exists stains.
Such scheme can detect the such as stains region, region formed because of the defect of image collecting device in digital picture in time, user can be recognized in time, and the state of image collecting device is gone forward side by side row relax, such as stains region is cleaned in time, avoid continuing shooting in the contaminated situation of image collecting device, and cause image quality mistake to go the value using and preserve.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet of the automatic testing method of the image capture module of the embodiment of the present invention one;
Fig. 2 is the structural representation of the automatic detection device of the electronic equipment of the embodiment of the present invention one;
Fig. 3 is the schematic flow sheet of the automatic testing method of the image capture module of the embodiment of the present invention two;
Fig. 4 is the local schematic flow sheet of step S20 in Fig. 3;
Fig. 5, Fig. 6 and Fig. 7 are a kind of schematic diagram that image is divided into multiple region to be detected by the embodiment of the present invention respectively;
Fig. 8 is the local schematic flow sheet of step S21 in Fig. 3;
Fig. 9 is the structural representation of the analysis module of the automatic detection device of the embodiment of the present invention two;
Figure 10 is the schematic flow sheet of the automatic testing method of the image capture module of the embodiment of the present invention three;
Figure 11 is the local schematic flow sheet of step S32 in Figure 10;
Figure 12 is the structural representation of the analysis module of the automatic detection device of the embodiment of the present invention three;
Figure 13 is the schematic flow sheet of the automatic testing method of the image capture module of the embodiment of the present invention four;
Figure 14 is the structural representation of the analysis module of the automatic detection device of the embodiment of the present invention four.
Embodiment
For making the object, technical solutions and advantages of the present invention clearly understand, hereinafter will be described in detail to embodiments of the invention by reference to the accompanying drawings.It should be noted that, when not conflicting, the embodiment in the application and the feature in embodiment can combination in any mutually.
Embodiment one
The present invention relates to a kind of automatic testing method of image capture module, can be applicable to the electronic equipment arbitrarily with shooting imaging function, as digital camera, video camera, handheld terminal is as mobile phone, PDA, notebook computer etc.
The present embodiment provides a kind of automatic testing method of image capture module, as shown in Figure 1, comprising:
Step S10: gather image by image capture module, selects at least two width images as sample image from the multiple image of described collection;
Can using all images all as sample image, also can according to the defect that will detect first corresponding selection sample image.
Step S11: analyzing samples image, judges whether image capture module meets collection requirement, if not, then performs step S12; If so, then this operation is terminated.
When analyzing samples image, can compare to described sample image, be extracted in the one or more characteristic areas with same characteristic features all existed in different sample image, to each characteristic area, statistics possesses the number of the sample image of this characteristic area, as for certain characteristic area, when the sample image number possessing this characteristic area is greater than predetermined threshold, can determine that described image acquisition units does not meet collection requirement.Wherein, described characteristic area has described image capture module and does not meet the provincial characteristics gathering and formed on image when requiring.Such as, during the severe flower screen that detected image acquisition module internal connection line generation problem causes, using large-area color block areas as characteristic area, slight flower screen can be detected in this way, can using zonal patch region as characteristic area.The stains that exist of the camera lens of detected image acquisition module in this way, can using the position that image presents identical and brightness lower than neighboring area as characteristic area.
Step S12: generate and perform prompt command.
Such as, if there are stains in judgement image capture module, then generate command cue image capture module and do not meet collection requirement, stains region is there is by prompting interface display camera lens, and provide the positional information in stains region, prompting user searches stains region to relevant position, completes clean operation, enables the stains on user's removing camera lens promptly and accurately.
As shown in Figure 2, the present embodiment also provides a kind of electronic equipment, comprises the automatic detection device to image capture module, and this automatic detection device comprises selects module 10, analysis module 20 and processing module 30, wherein:
Select module 10, for selecting at least two width images as sample image from the multiple image gathered by image capture module.
Analysis module 20, for analyzing sample image, determines whether image capture module meets collection requirement.Such as, when sample image is compared, be extracted in one or more characteristic areas with same characteristic features that different sample image all exists, to each characteristic area, statistics possesses the sample image number of this characteristic area, as this sample image number be greater than predetermined threshold time, determine that image acquisition units does not meet collection requirement, wherein, characteristic area is that image capture module does not meet the subregion gathering and formed on image when requiring.
Processing module 30, for do not meet at image capture module collection require time, generate the corresponding command and also perform.
Embodiment two
The image capture module of the present embodiment comprises camera lens, if detected, camera lens exists stains, and with regard to display reminding information, prompting user camera lens exists stains region.
As Fig. 3 shows, the camera lens automatic testing method that the present embodiment provides, comprising:
Step S20: gather image by camera lens, selects at least two width images as sample image from the multiple image gathered;
In the present embodiment, can setting-up time cycle parameter, according to the regular start detection program of time cycle parameter; Also amount of images parameter can be set, according to the cumulative amount detection trigger program gathering image; Also can manually irregular start detection program.Certainly the mode of above start detection program can combination in any, also can adopt the mode start detection program of other hommization more, meet diversity and the dirigibility of triggering to greatest extent.
Step S21: determine whether described camera lens exists stains according to described sample image analysis result;
Step S22: as there are stains, generates and performs prompt command.
This order produces man-machine interface first information by electronic equipment, the content of the first information can comprise prompting user camera lens and there is the information such as the region at stains and prompting stains place, this order needs user to confirm, " confirmation " button clicking the first information as user then representative of consumer has received this first information, next display second information can be continued, second information inquires whether user completes clean operation further, to guarantee that user completes clean operation, " confirmation " button clicking the second information as user then representative of consumer completes clean operation.
If user completes the confirmation of above-mentioned two informations, then image collecting device upper once start shooting time no longer prompt facility there are stains, also no longer start detection program, until detection trigger program next time.If when user does not click " confirmation " button of the first information and the second information, so then again can there is the information of stains by prompt facility when image collecting device start next time, until user clicks " confirmation " button, or until detection trigger program next time of the first information and the second information simultaneously.
Further, choose in the process of sample image in step S20, to each image in described multiple image, can process according to the following steps, as shown in Figure 4:
Step S201: judge whether the acquisition time distance current time of this image is less than default duration threshold value, if be less than duration threshold value, then performs step S202; If be greater than or equal to duration threshold value, then this collection image as sample image, can not terminate the selection operation to this image;
Above-mentioned duration threshold might be set is the absolute value of the acquisition time of image and the difference of current time, can be that unit calculates according to the date.When carrying out sample image screening, first the mistiming of each collection image and current time is calculated, compare with duration threshold value, the collection image that the absolute value of only time difference is less than duration threshold value just can enter next step sample image screening operation, for the image being greater than or equal to duration threshold value, then not as sample image.Due to when electronic equipment starts, the image that may gather before the storage area comparatively early time in equipment, if this kind of image is also detected as sample image, even if detect and there is stains region or there is not stains region, all can not the clean level of camera lens under accurate representation current state, be lost reference value.Therefore by arranging duration threshold value, the efficiency and accuracy of choosing effective sample image can be improved.
Step S202: the solid color regions determining this image;
In the present embodiment, by the detection algorithm of outline line, silhouettes detection is carried out to image, obtain multiple region, if the maximum difference of color parameter as RGB of each pixel is less than corresponding predetermined threshold in certain region, can think that this region is solid color regions.But also can define solid color regions according to other criterion.Why will detect solid color regions, be because when whether a detection image existing stains region on solid color regions, relative to ninsolid color region, stains are more easily identified in solid color regions.
Step S203: judge that whether collection image exists at least one region to be detected is covered by solid color regions, if so, performs step S204; If not, then terminate this processing procedure;
Can using whole image as region to be detected, also the subregion of more than 2 or 2 can be divided, each subregion is as a region to be detected, and position and the picture material in the region multiple to be detected now on image have nothing to do, and the position of same region to be detected on all images is identical.As shown in Figures 5 to 7, piece image can be divided into 3,4,5, but is not limited to this.How to divide and can determine according to pre-configured number and dividing mode.
Image is divided into multiple region to be detected, because the present embodiment detects stains region in the identical solid color regions of multiple image, and in the image naturally gathered, seldom there is large-area solid color regions, if be not divided into multiple region to be detected, the just more difficult sample image picking out sufficient amount.But region to be detected can not be too little, if too little, just may cover by stains region, effective detection can not be realized.
Step S204: using this collection image as sample image;
As shown in Figure 8, in step S21, for each region to be detected in sample image, can analyze whether there are stains according to the following steps:
Step S211: the association sample image determining this region to be detected;
Whether for certain region to be detected, analyzing each sample image has solid color regions to cover this region to be detected.The one or more sample images having solid color regions to cover this region to be detected are called the association sample image in this region to be detected.
Such as, sample image A1, A2, A3 and A4, four sample images are divided into four regions to be detected B1, B2, B3, B4 according to a certain division rule, in A1, B1 and B4 has solid color regions to cover, in A2, B1 and B2 has solid color regions to cover, in A3, B1, B3 and B4 have solid color regions to cover, and in A4, B2, B3 have solid color regions to cover, then analyze and draw:
Association sample image for region B1, B1 to be detected is A1, A2 and A3;
Association sample image for region B2, B2 to be detected is A2 and A4;
Association sample image for region B3, B3 to be detected is A3 and A4;
Association sample image for region B4, B4 to be detected is A1, A3.
Step S212: the quantity k adding up association sample image corresponding to this region to be detected;
Step S213: the value judging k, if k >=k1, then starts the analysis to this region to be detected, and perform step S214, wherein, k1 is the first sample number threshold value, k1 >=2;
For piece image, due to the impact of picture material, the detection in stains region is not easy, and time the feature in stains region is to there is stains region, shape and the position of taking the stains region of the every piece image come are identical.This consistance is the Main Basis judging stains region, so need the sample image of sufficient amount more accurately to judge making.Therefore first sample number threshold value k1 can be set, just determine that needs do further detection when only relevant sample image number reaches default k1, its objective is raising detection efficiency, improve the accuracy detected.
Such as, preset k1=6, for certain region B to be detected, when only having the association sample image number of B to reach 6, just judge whether this association sample exists doubtful stains; If the association sample image number of B is 5, does not then possess the condition detected further, do not perform detecting step.
Step S214: to each region to be detected, according to the detection to the first image-region on its association sample image, determines whether camera lens exists stains.
This step can be divided into following steps again to the process in a region to be detected:
Step one, detects each association sample image and whether there is the first image-region in this region to be detected, if existed, and the shape of each first image-region that record exists and positional information;
Described first image-region refers to the connected region determined according to silhouettes detection in this region to be detected, and the average brightness value of all pixels is lower than the average brightness value of all pixels in other regions in this region to be detected and the absolute value of difference is greater than the brightness value threshold value of setting in this connected region, luminance threshold can preset.With region to be detected unlike, the first image-region is by obtaining the detection of picture material, instead of according to pre-configured division.
Usually, for the image taken when camera lens not existing stains, in image, the difference of the average brightness value of all pixels of brightness value and this solid color regions of each pixel in solid color regions is less, if there is certain image-region in solid color regions, the average brightness value of each pixel in this region is starkly lower than the average brightness value in other regions in solid color regions, then this region is likely caused owing to there are stains.
Stains on described camera lens can the fingerprint, washmarking, oil stain etc. of camera lens surface attachment, also can be the indenture on camera lens surface.
The shape of the first image-region and position can represent with its boundary pixel point coordinate in the picture, if have the overwhelming majority (as more than 95%, can set) coordinate of boundary pixel point is identical, can think that the shape of two the first image-regions is identical with position.
Step 2, for each first image-region, according to its shape and positional information, counts the association sample image number g with this first image-region;
Step 3, judges the value of g, if g >=k2, then determines that camera lens exists stains, and wherein, k2 is the second sample number threshold value of setting, 2≤k2≤k1.
Such as, k1=15, k2=7 is preset, association sample image number k for region B, B to be detected is 15, if detect in this association sample image, there are 9 width sample image numbers to have the first identical image-region, i.e. g=9, just can think that camera lens exists stains region; If detected in this association sample image, only have 6 width sample image numbers to have identical or approximately uniform first image-region, i.e. g=6, just do not think that camera lens exists stains region.
Correspondingly, the present embodiment additionally provides a kind of electronic equipment, comprises the automatic detection device to image capture module, and wherein each module of comprising of automatic detection device is identical with embodiment one, namely comprises and selects module 10, analysis module 20 and processing module 30.Wherein select module identical with the corresponding module of embodiment one with the function of processing module.
Further, as shown in Figure 9, the analysis module 20 of the present embodiment can comprise:
Start unit 201, after being more than or equal to the first sample number threshold value k1 of setting at the association sample image having solid color regions to cover same region to be detected, starts the analysis to this region to be detected, k1 >=2;
Arithmetic element 202, for determine described association sample image this region memory to be detected the first image-region and the shape of described first image-region and the positional information in whole image;
Judging unit 203, for have at least k2 associate sample image this region memory to be detected at the first image-region that shape is identical with position time, determine that described camera lens exists stains, wherein, k2 be setting the second sample number threshold value, 2≤k2≤k1.
Embodiment three
The automatic testing method of the present embodiment image capture module comprises the following steps, as shown in Figure 10:
Step S30: gather image by camera lens, chooses the image of many group continuous acquisition as sample image;
The sample image that the present embodiment is chosen comprises m1 group image, often organizes the image that image comprises several continuous acquisition, and the acquisition time of these images distance current time is all less than default duration threshold value, and wherein, m1 is the first image sets number threshold value of setting, m1 >=2.
The image of several continuous acquisition can be the image collected under continuous shooting or image pickup mode.
Step S31: determine whether described camera lens exists stains according to described sample image analysis result;
Step S32: as there are stains, generates and performs prompt command.
Further, as shown in figure 11, whether stains can be there are according to following steps analysis to each group sample image in step S31:
Step S311: judge whether there is moving object in this group sample image, if there is moving object, then performs step S312;
In the present embodiment, because sample image is the image that many groups are taken continuously, for the image that each group is taken continuously, content of shooting in image is similar to identical, if camera lens has stains, the image due to reference is the approximately uniform one group of image of content, then the stains region formed on image is constant relative to the absolute position of image, then displacement be there occurs for relative position other objects in image, create the effect of the moving object existed in image.Therefore, the detection method of existing moving object can be adopted to detect it.
Step S312: the shape and the size information that record each moving object, using moving object identical with size for the shape that exists in different images group as same moving object;
Step S313: for each moving object, there is the image sets number m of this moving object in statistics;
Step S314: if m >=m2, then determine that described image capture module exists stains, and wherein, m2 is the second image sets number threshold value of setting.
In the present embodiment, if all there is shape and moving object in the same size in many groups photo of shooting continuously, and the quantity that there is the image sets of this situation is greater than default threshold value, just thinks that image capture module exists stains region.
Correspondingly, the present embodiment additionally provides a kind of electronic equipment comprising automatic detection device to image capture module, wherein automatic detection device comprises and selects module 10, analysis module 20 and processing module 30, wherein processing module function can the processing module function of embodiment one identical.
The sample image that the selection module 10 of the present embodiment is selected can comprise m1 group image, often organize image and comprise the image of several continuous acquisition and acquisition time distance current time is less than the duration threshold value of setting, wherein, m1 is the first image sets number threshold value of setting, m1 >=2.
Further, as shown in figure 12, the analysis module 20 in the present embodiment can comprise:
Capture unit 204, to each group image, finds out the moving object that exists in this group image and records shape and the size of each moving object;
Judging unit 205, for when having at least m2 group image to there is the moving object of same shape and size, then determines that described camera lens exists stains, and wherein, m2 is the second image sets number threshold value of setting, 2≤m2≤m1.
Embodiment four
The automatic testing method of the present embodiment image capture module comprises the following steps, as shown in figure 13:
Step S40: when pre-acquired operates, by camera lens continuous acquisition multiple image as sample image;
Before the operation of so-called pre-acquired refers to formal shooting, the function that user can open, this function class is similar to the function of continuous shooting or shooting continuously, the automatic detection that user can realize image capture module by this function.This pre-acquired function can as of an electronic equipment new function, and electronic equipment just automatically will detect image capture module after pre-acquired completes, thus increases the initiative and dirigibility that detect.
Because when continuous acquisition image, electronic equipment inevitably has some shakes, and this makes the content of the multiple image of continuous acquisition there are some displacements.But the image region formed stains impact, its coordinate is constant.The present embodiment just utilizes this feature to come whether detector lens exists stains.
Step S41: extract image region from described sample image, obtains the coordinate information of each image region in sample image;
The detection of above-mentioned image region is all not identical with the detection of the moving object in embodiment three with the detection of the first image-region in embodiment two, each image region in the image determined by silhouettes detection exactly, does not have other additional condition.Generally multiple image region can be there is in sample image.
Step S42: the coordinate information of image region in more each sample image, judges whether to have at least on two width sample images and there is the constant image region of at least one coordinate, if so, performs step S43, otherwise, terminate;
In the present embodiment, can judge image region physical location in the picture by coordinate information, coordinate constant then representative image subregion position is in the picture constant.
Such as, for the three width sample images that all there is a certain image region, just illustrate that the coordinate information of this image region in three width sample images is identical.In the present embodiment, when there is the identical image region of coordinate information at least two width sample images, just can determine that camera lens exists stains region.
Step S43: determine that camera lens exists stains, sends hint instructions prompting user.
Correspondingly, the present embodiment additionally provides a kind of electronic equipment, and comprise the automatic detection device of image capture module, identical with embodiment one, automatic detection device comprises selects module 10, analysis module 20 and processing module 30.Wherein the function of processing module can be identical with the processing module of embodiment one.
In the present embodiment, the sample image selecting module 10 to select is when performing pre-acquired operation, by the multiple image of camera lens continuous acquisition.
Further, analysis module 20 comprises again:
Collecting unit 206, extracts image region from described sample image, obtains described image region coordinate information in the picture;
Judging unit 207, the coordinate information of image region described in more each sample image, when as having at least two width sample images existing the constant image region of at least one coordinate, then determines that camera lens exists stains.
The foregoing is only the preferred embodiments of the present invention, be not limited to the present invention, for a person skilled in the art, the present invention can have various modifications and variations.Within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (14)

1. an automatic testing method for image capture module, is applied to electronic equipment, and described method comprises:
Gather multiple image by image capture module, from described multiple image, select at least two width images as sample image;
Described sample image is analyzed, determines whether described image capture module meets collection requirement;
As described in image capture module do not meet collection requirement, generate the corresponding command and also perform.
2. the method for claim 1, is characterized in that:
Described sample image is analyzed, determines whether described image capture module meets collection requirement, comprising according to analysis result:
Described sample image is compared, be extracted in one or more characteristic areas with same characteristic features that different sample image all exists, to each characteristic area, statistics possesses the sample image number of this characteristic area, as this sample image number be greater than predetermined threshold time, determine that described image acquisition units does not meet collection requirement, wherein, described characteristic area is that described image capture module does not meet the subregion gathering and formed on image when requiring.
3. the method for claim 1, is characterized in that:
Described image capture module comprises camera lens;
Described sample image is analyzed, determine whether described image capture module meets collection requirement according to analysis result, comprise: determine whether described camera lens exists stains according to described sample image analysis result, if there are stains, then determine that described camera lens does not meet collection requirement;
As described in image capture module do not meet collection requirement, generate the corresponding command and perform described order, comprise: as described in camera lens do not meet collection requirement, then generating prompting camera lens has the order of stains and has stains by the display unit of described electronic equipment prompting user camera lens.
4. the method as described in claim 1 or 2 or 3, is characterized in that:
Described sample image refers in image have solid color regions to cover at least one region to be detected and acquisition time distance current time is less than the image of setting duration threshold value, wherein, described region to be detected is whole image-region or whole image-region is divided to the subregion obtained.
5. method as claimed in claim 4, is characterized in that:
Determine whether described camera lens exists stains according to described sample image analysis result, comprising:
After the association sample image having solid color regions to cover same region to be detected is more than or equal to the first sample number threshold value k1 of setting, start the analysis to this region to be detected, k1 >=2;
If have at least k2 to associate sample image at this region memory to be detected at shape first image-region identical with position, then determine that described camera lens exists stains, wherein, k2 is the second sample number threshold value of setting, 2≤k2≤k1;
Wherein, described first image-region be this region memory to be detected connected region, and in this connected region the average brightness value of all pixels lower than the average brightness value of all pixels in other regions in this region to be detected and the absolute value of difference is greater than the brightness value threshold value of setting.
6. method as claimed in claim 3, is characterized in that:
Described sample image comprises m1 group image, and often organize image and comprise the image of several continuous acquisition and acquisition time distance current time is less than the duration threshold value of setting, wherein, m1 is the first image sets number threshold value of setting, m1 >=2;
Determine whether described camera lens exists stains according to described sample image analysis result, comprising:
To each group image, find out the moving object that exists in this group image and record shape and the size of each moving object;
If have at least m2 group image to there is the moving object of same shape and size, then determine that described camera lens exists stains, wherein, m2 is the second image sets number threshold value of setting, 2≤m2≤m1.
7. method as claimed in claim 3, is characterized in that:
Described sample image is when performing pre-acquired operation, by the multiple image of camera lens continuous acquisition;
Determine whether described camera lens exists stains according to described sample image analysis result, comprising:
Image region is extracted from described sample image, obtain described subregion coordinate information in the picture, the coordinate information of image region described in more each sample image, when as having at least two width sample images existing the constant image region of at least one coordinate, then determine that described camera lens exists stains.
8. an electronic equipment, is characterized in that, comprises the automatic detection device to image capture module, and described automatic detection device comprises:
Select module, for selecting at least two width images as sample image from the multiple image gathered by image capture module;
Analysis module, analyzes described sample image, determines whether described image capture module meets collection requirement;
Processing module, for do not meet at described image capture module collection require time, generate the corresponding command and also perform.
9. electronic equipment as claimed in claim 8, is characterized in that:
Described analysis module is analyzed described sample image, determines whether described image capture module meets collection requirement, comprising according to analysis result:
Described sample image is compared, be extracted in one or more characteristic areas with same characteristic features that different sample image all exists, to each characteristic area, statistics possesses the sample image number of this characteristic area, as this sample image number be greater than predetermined threshold time, determine that described image acquisition units does not meet collection requirement, wherein, described characteristic area is that described image capture module does not meet the subregion gathering and formed on image when requiring.
10. electronic equipment as claimed in claim 8, is characterized in that:
Described image capture module comprises camera lens;
Described analysis module is analyzed described sample image, determine whether described image capture module meets collection requirement according to analysis result, comprise: determine whether described camera lens exists stains according to described sample image analysis result, if there are stains, then determine that described camera lens does not meet collection requirement;
Described processing module described image capture module do not meet collection require time, generate the corresponding command and perform described order, comprise: as described in camera lens do not meet collection requirement, then generating prompting camera lens has the order of stains and has stains by the display unit of described electronic equipment prompting user camera lens.
11. electronic equipments as described in claim 8 or 9 or 10, is characterized in that:
The sample image of described selection model choice has solid color regions to cover at least one region to be detected and acquisition time distance current time is less than the image of setting duration threshold value, wherein, described region to be detected is whole image-region or whole image-region is divided to the subregion obtained.
12. electronic equipments as claimed in claim 11, is characterized in that:
Described analysis module comprises again:
Start unit, after being more than or equal to the first sample number threshold value k1 of setting at the association sample image having solid color regions to cover same region to be detected, starts the analysis to this region to be detected, k1 >=2;
Arithmetic element, for determine described association sample image this region memory to be detected the first image-region and the shape of described first image-region and the positional information in whole image;
Judging unit, for have at least k2 associate sample image this region memory to be detected at the first image-region that shape is identical with position time, determine that described camera lens exists stains, wherein, k2 be setting the second sample number threshold value, 2≤k2≤k1;
Wherein, described first image-region refer to this region memory to be detected connected region, and in this connected region the average brightness value of all pixels lower than the average brightness value of all pixels in other regions in this region to be detected and the absolute value of difference is greater than the brightness value threshold value of setting.
13. electronic equipments as claimed in claim 10, is characterized in that:
The described sample image of described selection model choice comprises m1 group image, and often organize image and comprise the image of several continuous acquisition and acquisition time distance current time is less than the duration threshold value of setting, wherein, m1 is the first image sets number threshold value of setting, m1 >=2;
Described analysis module comprises again:
Capture unit, to each group image, finds out the moving object that exists in this group image and records shape and the size of each moving object;
Judging unit, for when having at least m2 group image to there is the moving object of same shape and size, then determines that described camera lens exists stains, and wherein, m2 is the second image sets number threshold value of setting, 2≤m2≤m1.
14. electronic equipments as claimed in claim 10, is characterized in that:
The sample image of described selection model choice is when performing pre-acquired operation, by the multiple image of camera lens continuous acquisition;
Described analysis module comprises again:
Collecting unit, for extracting image region from described sample image, obtains described image region coordinate information in the picture;
Judging unit, for the coordinate information of characteristic area described in more each sample image, when as having at least two width sample images existing the constant characteristic area of at least one coordinate, then determines that described camera lens exists stains.
CN201310425088.7A 2013-09-17 2013-09-17 A kind of automatic testing method and corresponding electronic equipment of image capture module Active CN104463827B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310425088.7A CN104463827B (en) 2013-09-17 2013-09-17 A kind of automatic testing method and corresponding electronic equipment of image capture module

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310425088.7A CN104463827B (en) 2013-09-17 2013-09-17 A kind of automatic testing method and corresponding electronic equipment of image capture module

Publications (2)

Publication Number Publication Date
CN104463827A true CN104463827A (en) 2015-03-25
CN104463827B CN104463827B (en) 2019-02-05

Family

ID=52909813

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310425088.7A Active CN104463827B (en) 2013-09-17 2013-09-17 A kind of automatic testing method and corresponding electronic equipment of image capture module

Country Status (1)

Country Link
CN (1) CN104463827B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105100606A (en) * 2015-06-23 2015-11-25 联想(北京)有限公司 Information processing method and electronic equipment
CN110278348A (en) * 2018-03-16 2019-09-24 厦门歌乐电子企业有限公司 A kind of camera module, shooting imaging method and terminal device
WO2020019352A1 (en) * 2018-07-27 2020-01-30 深圳市大疆创新科技有限公司 Method, device and system for inspecting camera module, and machine readable storage medium
CN111175221A (en) * 2020-02-28 2020-05-19 西安石油大学 Detection device for corrosivity of metal product
CN111815705A (en) * 2020-06-09 2020-10-23 季华实验室 Laser tracker light filtering protective lens pollution identification method and device and electronic equipment
CN111833340A (en) * 2020-07-21 2020-10-27 北京百度网讯科技有限公司 Image detection method, image detection device, electronic equipment and storage medium
CN111861980A (en) * 2020-05-29 2020-10-30 合肥联宝信息技术有限公司 Imaging detection method, electronic equipment and computer readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0585759A1 (en) * 1992-08-21 1994-03-09 Eastman Kodak Company Process for detecting and mapping dirt on the surface of a photographic element
CN101001318A (en) * 2006-01-12 2007-07-18 佳能株式会社 Image capturing apparatus and control method thereof
CN101729921A (en) * 2008-10-29 2010-06-09 宏碁股份有限公司 Electronic device and detection method thereof
CN102111532A (en) * 2010-05-27 2011-06-29 周渝斌 Camera lens occlusion detecting system and method
CN102413354A (en) * 2011-10-05 2012-04-11 深圳市联德合微电子有限公司 Automatic optical detection method, device and system of mobile phone camera module

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0585759A1 (en) * 1992-08-21 1994-03-09 Eastman Kodak Company Process for detecting and mapping dirt on the surface of a photographic element
CN101001318A (en) * 2006-01-12 2007-07-18 佳能株式会社 Image capturing apparatus and control method thereof
CN101729921A (en) * 2008-10-29 2010-06-09 宏碁股份有限公司 Electronic device and detection method thereof
CN102111532A (en) * 2010-05-27 2011-06-29 周渝斌 Camera lens occlusion detecting system and method
CN102413354A (en) * 2011-10-05 2012-04-11 深圳市联德合微电子有限公司 Automatic optical detection method, device and system of mobile phone camera module

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105100606A (en) * 2015-06-23 2015-11-25 联想(北京)有限公司 Information processing method and electronic equipment
CN105100606B (en) * 2015-06-23 2018-10-12 联想(北京)有限公司 A kind of information processing method and electronic equipment
CN110278348A (en) * 2018-03-16 2019-09-24 厦门歌乐电子企业有限公司 A kind of camera module, shooting imaging method and terminal device
CN110278348B (en) * 2018-03-16 2022-03-18 厦门歌乐电子企业有限公司 Camera module, shooting and imaging method and terminal equipment
WO2020019352A1 (en) * 2018-07-27 2020-01-30 深圳市大疆创新科技有限公司 Method, device and system for inspecting camera module, and machine readable storage medium
CN110800294A (en) * 2018-07-27 2020-02-14 深圳市大疆创新科技有限公司 Method, equipment and system for detecting camera module and machine-readable storage medium
CN111175221A (en) * 2020-02-28 2020-05-19 西安石油大学 Detection device for corrosivity of metal product
CN111861980B (en) * 2020-05-29 2022-02-01 合肥联宝信息技术有限公司 Imaging detection method, electronic equipment and computer readable storage medium
CN111861980A (en) * 2020-05-29 2020-10-30 合肥联宝信息技术有限公司 Imaging detection method, electronic equipment and computer readable storage medium
CN111815705A (en) * 2020-06-09 2020-10-23 季华实验室 Laser tracker light filtering protective lens pollution identification method and device and electronic equipment
CN111815705B (en) * 2020-06-09 2024-05-07 季华实验室 Method and device for identifying pollution of filter protection lens of laser tracker and electronic equipment
CN111833340A (en) * 2020-07-21 2020-10-27 北京百度网讯科技有限公司 Image detection method, image detection device, electronic equipment and storage medium
CN111833340B (en) * 2020-07-21 2024-03-26 阿波罗智能技术(北京)有限公司 Image detection method, device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN104463827B (en) 2019-02-05

Similar Documents

Publication Publication Date Title
CN104463827A (en) Image acquisition module automatic detection method and corresponding electronic device
GB2529943B (en) Tracking processing device and tracking processing system provided with same, and tracking processing method
CN112837302B (en) Method and device for monitoring state of die, industrial personal computer, storage medium and system
KR100841497B1 (en) Method for inspecting unevenness, manufacturing method for display panel and apparatus for inspecting unevenness
CN106060419B (en) A kind of photographic method and mobile terminal
CN109951635B (en) Photographing processing method and device, mobile terminal and storage medium
CN103188434B (en) Method and device of image collection
US8189942B2 (en) Method for discriminating focus quality of image pickup device
CN107749268A (en) Screen detection method and equipment
CN104349045A (en) Image collecting method and electronic equipment
CN104486552A (en) Method and electronic device for obtaining images
CN104866804A (en) Palm print information identification method and palm print information identification device
CN106575223A (en) Image classification method and image classification apparatus
CN104601876A (en) Method and device for detecting passerby
CN103763458A (en) Scene change detection method and device
CN105262948A (en) Panorama capturing method and mobile terminal
CN110738629A (en) lens contamination detection method, terminal and computer readable storage medium
CN111724383A (en) Camera module black spot detection system based on turntable
KR102592231B1 (en) Method for diagnosing fault of camera
CN103543916A (en) Information processing method and electronic equipment
CN103942523A (en) Sunshine scene recognition method and device
CN105450973A (en) Method and device of video image acquisition
CN110770786A (en) Shielding detection and repair device based on camera equipment and shielding detection and repair method thereof
CN112637588B (en) Method and device for detecting contamination of camera and electronic equipment
KR101559338B1 (en) System for testing camera module centering and method for testing camera module centering using the same

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant