CN112255239B - Pollution position detection method, device, equipment and computer readable storage medium - Google Patents

Pollution position detection method, device, equipment and computer readable storage medium Download PDF

Info

Publication number
CN112255239B
CN112255239B CN202011116074.3A CN202011116074A CN112255239B CN 112255239 B CN112255239 B CN 112255239B CN 202011116074 A CN202011116074 A CN 202011116074A CN 112255239 B CN112255239 B CN 112255239B
Authority
CN
China
Prior art keywords
image
lens
shooting
focal length
pollutant
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.)
Active
Application number
CN202011116074.3A
Other languages
Chinese (zh)
Other versions
CN112255239A (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.)
Goertek Optical Technology Co Ltd
Original Assignee
Qingdao Goertek Technology Co 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 Qingdao Goertek Technology Co Ltd filed Critical Qingdao Goertek Technology Co Ltd
Priority to CN202011116074.3A priority Critical patent/CN112255239B/en
Publication of CN112255239A publication Critical patent/CN112255239A/en
Application granted granted Critical
Publication of CN112255239B publication Critical patent/CN112255239B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/01Arrangements or apparatus for facilitating the optical investigation
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/94Investigating contamination, e.g. dust
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/67Focus control based on electronic image sensor signals
    • H04N23/675Focus control based on electronic image sensor signals comprising setting of focusing regions
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/01Arrangements or apparatus for facilitating the optical investigation
    • G01N2021/0106General arrangement of respective parts
    • G01N2021/0112Apparatus in one mechanical, optical or electronic block
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/01Arrangements or apparatus for facilitating the optical investigation
    • G01N2021/0181Memory or computer-assisted visual determination

Landscapes

  • Biochemistry (AREA)
  • Analytical Chemistry (AREA)
  • Pathology (AREA)
  • Immunology (AREA)
  • Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • General Physics & Mathematics (AREA)
  • Chemical & Material Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Studio Devices (AREA)

Abstract

The invention discloses a method for detecting a pollution position, which comprises the following steps: acquiring a shooting view field of the shooting device, and dividing the shooting view field into a plurality of display areas; adjusting the focal length of the shooting device, and when a clear image of a pollutant on the lens module to be detected is obtained, obtaining the current focal length of the shooting device and a target display area of the pollutant in the shooting view field; and determining the position of the pollutant in the lens module to be detected according to the current focal length and the target display area. The invention also discloses a pollution position detection device, equipment and a computer readable storage medium. According to the invention, the position of the pollutant in the lens module to be detected is automatically obtained, so that the detection of the position of the pollutant in the lens module to be detected is improved, and the manpower is saved.

Description

Pollution position detection method, device, equipment and computer readable storage medium
Technical Field
The present invention relates to the field of detection, and in particular, to a method, an apparatus, a device, and a computer-readable storage medium for detecting a contamination location.
Background
With the rapid development of science and technology, lens modules with multilayer lenses (such as VR glasses) are more and more favored by people, while the lens modules with multilayer lenses inevitably produce dirt, dust, pollutants and the like in the production process, and the pollutants may exist on a certain surface between the lenses.
Disclosure of Invention
The invention mainly aims to provide a method, a device and equipment for detecting a pollution position and a computer readable storage medium, and aims to solve the technical problem of low detection precision in the existing pollution detection of a lens module to be detected with a plurality of layers of lenses.
Further, to achieve the above object, the present invention provides a contaminated site detection method including the steps of:
acquiring a shooting view field of the shooting device, and dividing the shooting view field into a plurality of display areas;
adjusting the focal length of the shooting device, and when a clear image of a pollutant on the lens module to be detected is obtained, obtaining the current focal length of the shooting device and a target display area of the pollutant in the shooting view field;
and determining the position of the pollutant in the lens module to be detected according to the current focal length and the target display area.
Optionally, the acquiring a shooting field of view of the shooting device, and the dividing the shooting field of view into a plurality of display areas includes:
acquiring a shooting view field of the shooting device and the lens type of the lens module to be detected;
and dividing the shooting field of view into a plurality of display areas according to the type of the lens.
Optionally, the adjusting the focal length of the shooting device, when a clear image of a contaminant on the lens module to be detected is obtained, the obtaining the current focal length of the shooting device, and the target display area where the contaminant is located in the shooting field of view includes:
adjusting the focal length of the shooting device, and acquiring a lens image of the lens module to be detected through the shooting device;
judging whether the lens image is a clear image;
if the lens image is not the clear image, the step of adjusting the focal length of the shooting device and acquiring the lens image of the lens module to be detected through the shooting device is executed again;
and if the lens image is the clear image, executing the step of acquiring the current focal length of the shooting device and the target display area of the pollutant in the shooting field of view.
Optionally, the adjusting the focal length of the shooting device includes, after the step of obtaining the lens image of the lens module to be detected by the shooting device:
acquiring the image size and the image resolution of the lens image;
if the image size is matched with the image resolution, determining that the lens image is a clear image;
and if the image size does not match the image resolution, judging that the lens image is not a clear image.
Optionally, the adjusting the focal length of the shooting device, when a clear image of a contaminant on the lens module to be detected is obtained, obtaining the current focal length of the shooting device, and the target display area where the contaminant is located in the shooting field of view, includes:
determining an image area where the pollutant is located in the clear image, and acquiring image brightness of the image area;
if the image brightness is smaller than a preset threshold value, determining that the pollutants are pollutants of one class;
and if the image brightness is greater than or equal to a preset threshold value, determining that the pollutants are of two types.
Optionally, the step of determining the position of the contaminant in the to-be-detected lens module according to the current focal length and the target display area includes:
acquiring an imaging light path generated by a preset simulation program;
determining a target mirror surface of a target lens where the pollutant is located according to the current focal length and the imaging optical path;
and determining the position of the pollutant in the lens module to be detected according to the target display area and the target mirror surface.
Optionally, the step of determining a target mirror surface of a target lens on which the contaminant is located according to the current focal length and the imaging optical path comprises:
calculating the virtual image distance of the pollutant according to the current focal length and the imaging light path;
according to the virtual image distance, photographing the lens module to be detected through the photographing device to obtain a target picture;
and determining the target lens surface of the target lens where the pollutants are located according to the target picture.
Further, to achieve the above object, the present invention also provides a contaminated site detection apparatus including:
the shooting view field acquisition module is used for acquiring the shooting view field of the shooting device and dividing the shooting view field into a plurality of display areas;
the focal length adjusting module is used for adjusting the focal length of the shooting device, and when a clear image of a pollutant on the lens module to be detected is obtained, the current focal length of the shooting device and a target display area where the pollutant is located in the shooting field of view are obtained;
and the position determining module is used for determining the position of the pollutant in the lens module to be detected according to the current focal length and the target display area.
Further, to achieve the above object, the present invention also provides a contaminated site detection apparatus including: the system comprises a memory, a processor and a polluted position detection program stored on the memory and capable of running on the processor, wherein the polluted position detection program realizes the steps of the polluted position detection method when being executed by the processor.
Further, to achieve the above object, the present invention also provides a computer-readable storage medium having a contamination position detection program stored thereon, which when executed by a processor, realizes the steps of the contamination position detection method as described above.
The embodiment of the invention provides a pollution position detection method, a pollution position detection device, pollution position detection equipment and a readable storage medium. The method comprises the steps that a pollution position detection program obtains a shooting view field of a preset shooting device and divides the shooting view field into a plurality of display areas, furthermore, the pollution position detection program enables the shooting device to shoot a clear image of pollutants on a lens module to be detected by adjusting the focal length of the shooting device, when the clear image of the pollutants is obtained, the pollution position detection program further obtains the current focal length of the shooting device and a target display area where the pollutants are located in the shooting view field, and finally the position where the pollutants are located in the lens module to be detected is determined according to the current focal length and the target display area. This embodiment is through the position of automatic acquisition pollutant in waiting to detect the lens module, has improved the detection to waiting to detect the position that pollutant is located in the lens module, and has saved the manpower.
Drawings
Fig. 1 is a schematic hardware structure diagram of an implementation manner of a contaminated location detection apparatus according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart illustrating a contaminated site detection method according to a first embodiment of the present invention;
FIG. 3 is a schematic flow chart of a contaminated site detection method according to a second embodiment of the present invention;
FIG. 4 is a schematic flow chart illustrating a method for detecting a contamination location according to a third embodiment of the present invention;
FIG. 5 is a functional block diagram of an exemplary contamination position detecting apparatus according to the present invention.
The implementation, functional features and advantages of the present invention will be further described with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and do not limit the invention.
In the following description, suffixes such as "module", "component", or "unit" used to denote elements are used only for facilitating the explanation of the present invention, and have no specific meaning in itself. Thus, "module", "component" or "unit" may be used mixedly.
The pollution position detection terminal (also called terminal, equipment or terminal equipment) in the embodiment of the invention can be a PC (personal computer), and can also be a mobile terminal equipment with a display function, such as a smart phone, a tablet personal computer and a portable computer.
As shown in fig. 1, the terminal may include: a processor 1001, such as a CPU, a network interface 1004, a user interface 1003, a memory 1005, a communication bus 1002. The communication bus 1002 is used to implement connection communication among these components. The user interface 1003 may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface). The memory 1005 may be a high-speed RAM memory or a non-volatile memory such as a disk memory. The memory 1005 may alternatively be a storage device separate from the processor 1001.
Optionally, the terminal may further include a camera, a Radio Frequency (RF) circuit, a sensor, an audio circuit, a WiFi module, and the like. Such as light sensors, motion sensors, and other sensors. Specifically, the light sensor may include an ambient light sensor that may adjust the brightness of the display screen according to the brightness of ambient light, and a proximity sensor that may turn off the display screen and/or the backlight when the mobile terminal is moved to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), detect the magnitude and direction of gravity when the mobile terminal is stationary, and can be used for applications (such as horizontal and vertical screen switching, related games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer and tapping) and the like for recognizing the attitude of the mobile terminal; of course, the mobile terminal may also be configured with other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which are not described herein again.
Those skilled in the art will appreciate that the terminal structure shown in fig. 1 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, a memory 1005, which is a kind of computer storage medium, may include therein an operating system, a network communication module, a user interface module, and a contaminated location detection program.
In the terminal shown in fig. 1, the network interface 1004 is mainly used for connecting to a backend server and performing data communication with the backend server; the user interface 1003 is mainly used for connecting a client (user side) and performing data communication with the client; and the processor 1001 may be configured to invoke a dirty position detection program stored in the memory 1005, which when executed by the processor, implements the operations in the dirty position detection method provided by the embodiments described below.
Based on the hardware structure of the equipment, the embodiment of the pollution position detection method is provided.
Referring to fig. 2, in a first embodiment of the contaminated site detection method of the present invention, the contaminated site detection method includes:
and step S10, acquiring the shooting field of view of the shooting device, and dividing the shooting field of view into a plurality of display areas.
The pollutant position detection method in this embodiment is applied to pollutant position detection equipment, wherein, pollutant position detection equipment is including the shooting device that is used for shooing, for example, the camera, still including the lens module that detects, for example, the lens module that detects of VR glasses, still including the equipment such as computer that acquires and handle relevant data, wherein, the pollutant position detection method in this embodiment is applicable to the special lens module that detects, promptly, contain the multilayer lens and have certain interval between every layer of lens, when having the pollutant on certain mirror surface of certain lens wherein, can't accurately learn the position of pollutant from the external world through naked eye, this also is the technical problem that this scheme will be solved.
It can be known that, the shooting device in this embodiment is exemplified by a camera, the shooting field of view in this embodiment refers to the maximum range that can be observed by a camera, which is usually expressed by angles, the larger the field of view is, the larger the observation range is, it can be understood that the shooting field of view of the camera is a circle, the shooting field of view of the camera is equal to the size of the lens module to be detected by adjusting the distance between the camera and the lens module to be detected, so that the shooting field of view of the camera completely covers the size of the lens module to be detected, and then the shooting field of view is divided into a plurality of display areas, this embodiment provides a division rule, with the center of the shooting field of view as the center, a plurality of concentric circles are drawn, the distances between adjacent concentric circles are generally unequal, the distance between adjacent concentric circles is related to the selected field of view interval, the number of the concentric circles is related to the thickness difference between the middle of the lens and the edge, the larger the difference, the more concentric circles are needed. This facilitates subsequent determination of the location of the contaminant, without limitation to the number of display areas.
And step S20, adjusting the focal length of the shooting device, and shooting the lens module to be detected in the shooting field.
Therefore, the purpose of adjusting the focus of camera in this embodiment is, aim at the shooting visual field of camera and wait to detect the lens module to make the shooting visual field just cover and wait to detect the lens module, wherein, it is circular to wait to detect the lens module, just cover when waiting to detect the lens module when shooting the visual field, acquires the focus of camera at this moment, then adjust the focus of camera once more, and when adjusting camera focus once more, continuously treat and detect the lens module and shoot, in order to acquire the image of waiting to detect the lens module.
And step S30, when a clear image of the pollutant on the lens module to be detected is obtained, obtaining the current focal length of the shooting device and the target display area of the pollutant in the shooting field of view.
As can be seen, the premise of adjusting the focal length of the camera in this embodiment is that the camera is fixed within a certain range from the lens module to be detected, and the initial focal length of the camera is equal to the shortest distance from the camera to the lens module to be detected, the purpose of focusing is mainly to make the focal length of the camera greater than the initial focal length, when the camera acquires a clear image of a contaminant at a certain position in the lens module to be detected, the focal length of the camera at that moment (i.e. the current focal length in this embodiment) is acquired, and after the current focal length of the camera is acquired, since the initial position and the initial focal length of the camera are fixed, according to the current focal length, which surface of which lens the contaminant is located can be determined, and according to a display area (i.e. a target display area in this embodiment) where the contaminant is located on the clear image, the specific position where the contaminant is located can be determined, this has greatly made things convenient for the detection and the trash removal of treating the detection lens module, compares in the people eye detects, has increased the degree of accuracy that detects, and has reduced the manpower.
Step S40, determining the position of the contaminant in the to-be-detected lens module according to the current focal length and the target display area.
Therefore, by obtaining the initial distance between the camera and the lens module to be detected and the current focal length, and further by obtaining the related information of the lens module to be detected, because the lens can focus or diverge the imaging light path of the pollutant, the imaging light path of the pollutant needs to be simulated, the scheme adopts zemax (an optical product design and simulation software) to simulate the imaging light path of the pollutant, so as to obtain the imaging light path, further calculates the virtual image distance of the pollutant according to the imaging light path of the pollutant, so as to determine the focusing distance of the camera according to the virtual image distance, after the focusing distance of the camera is determined, the focusing distance of the camera can be adjusted, and the center of the lens is taken as the center of a circle, the different areas divided by the field angle are respectively shot with clear photos, and finally the shot clear photos are compared with the preset standard relative ratio of the different areas, and finally, determining the position and the type of the pollutant according to the comparison result.
Specifically, the step S10 is detailed as follows:
step a1, acquiring the shooting field of view of the shooting device and the lens type of the lens module to be detected.
Step a2, dividing the shooting field of view into a plurality of display areas according to the lens type.
The method comprises the steps that a shooting field of view of a camera is circular, but display areas can be divided into a plurality of types, the division of the display areas depends on the type of a lens in a lens module to be detected, and the lens types comprise a plane mirror, a convex mirror, a concave mirror and the like, because the distance between each point on the concave mirror and each point on the convex mirror and the distance between each point on the camera are different, the focus of pollutants is calculated by taking the center of the concave mirror or the convex mirror as the center of a circle, and if the focus of the pollutants in a certain range is in a preset area, selection of a circular ring is related to the range, so that the division of the shooting field of view into the plurality of circular display areas is more beneficial to determining the positions of the pollutants, and each circular display area corresponds to one circular area on the surface of the concave mirror or the convex mirror; if the lens type is a plane mirror, distances from all points on the plane mirror to the camera are equal, so that the division of the display area is random, but the division of the display area is not too much or too little on the basis of convenience, and the number of the display areas is moderate.
Specifically, steps subsequent to step S20 include:
step b1, determining the image area where the pollutant is located in the clear image, and acquiring the image brightness of the image area.
Step b2, if the image brightness is less than the preset threshold, determining the pollutant is a kind of pollutant.
And b3, if the image brightness is greater than or equal to a preset threshold value, determining that the pollutants are of two types.
It should be noted that, after determining the position of the contaminant, the type of the contaminant may be determined according to the brightness of the image of the contaminant in the clear image, so as to facilitate the subsequent cleaning operation of the contaminant, where the brightness of the image in this embodiment refers to the ratio of the light intensity of the illuminant to the area of the light source seen by the human eye, where the light intensity of the illuminant may be obtained by a special sensor, and therefore, the brightness of the image is also information that can be automatically obtained by the device, and the preset threshold in this embodiment is a value in units of brightness of the image, which is determined through many experiments according to the brightness information of images of different contaminants in a specific environment, specifically, when the brightness of the image is smaller than the preset threshold, the contaminant position detection program determines the contaminants as a type of contaminant, where the type of the contaminant includes a contaminant, and a type of the contaminant includes a contaminant, and a type of the contaminant And the detection program of the polluted position determines that the pollutants are two types of pollutants when the brightness of the image is greater than a preset threshold value, wherein the two types of pollutants comprise bright spots, scratches, alcohol prints and the like. When the image brightness is equal to the preset threshold value, no pollutant is represented.
The pollutant position detection program acquires the shooting field of view of the preset shooting device in the embodiment, and divides the shooting field of view into a plurality of display areas, further, the pollutant position detection program adjusts the focal length of the shooting device, so that the shooting device shoots the clear image of the pollutant on the lens module to be detected, when the clear image of the pollutant is acquired, the pollutant position detection program further acquires the current focal length of the shooting device, and the target display area of the pollutant in the shooting field of view, finally, the pollutant position in the lens module to be detected is determined according to the current focal length and the target display area. This embodiment is through the position of automatic acquisition pollutant in waiting to detect the lens module, has improved the detection to waiting to detect the position that pollutant is located in the lens module, and has saved the manpower.
Further, referring to fig. 3, a second embodiment of the contaminated position detection method of the present invention is proposed on the basis of the above-described embodiment of the present invention.
This embodiment is a step of the first embodiment, which is a refinement of step S20, and the difference between this embodiment and the above-described embodiment of the present invention is:
and step S21, adjusting the focal length of the shooting device, and acquiring the lens image of the lens module to be detected through the shooting device.
Step S22, determine whether the lens image is a sharp image.
And step S23, if the lens image is not the clear image, the step of adjusting the focal length of the shooting device and acquiring the lens image of the lens module to be detected through the shooting device is executed again.
Step S24, if the lens image is the sharp image, performing the step of acquiring the current focal length of the camera and the target display area where the contaminant is located in the shooting field of view.
Therefore, when the initial position of the camera and the lens module to be detected is fixed and the initial focal length of the camera is determined, by continuously adjusting the focal length of the camera (making the focal length larger), and acquiring the image of the lens module to be detected after each focusing (i.e. the lens image in the embodiment), and judging whether the lens image is a clear image, if the lens image is a clear image after a certain focusing, the focal length of the camera after the focusing is the current focal length, if the lens image is still not a clear image after focusing, the focal length of the camera is continuously adjusted, namely, the step of adjusting the focal length of the camera again and acquiring the lens image of the lens module to be detected through the camera, and if the lens image is a clear image after focusing, acquiring the current focal length of the camera and a target display area where the pollutants are located in the shooting field of view.
Specifically, the step of step S22 refinement includes:
step c1, acquiring the image size and image resolution of the lens image.
And c2, if the image size is matched with the image resolution, determining that the lens image is a clear image.
And c3, if the image size does not match the image resolution, determining that the lens image is not a sharp image.
It is known that when the size of the lens image is determined, the resolution of the image is also determined, and the process of focusing the camera is essentially to rearrange the pixels of the image, and when the camera is focused, the picture is taken if it is not a sharp image, the total number of pixels contained in the image will be lower than the resolution of the image size, for example, if the size of the lens image is 1920 × 1080 and the total number of pixels (i.e. resolution) of the lens image is less than 2073600, it is proved that the mirror image is not a sharp image, i.e. if the image resolution is less than the product of the image sizes, it is proved that the image size does not match the image resolution, and similarly, if the size of the lens image is 1920 × 1080 and the total number of pixels (i.e. resolution) of the lens image is equal to 2073600, it is proved that the mirror image is a sharp image, i.e. if the image resolution is equal to the product of the image sizes, the image size is proved to match the image resolution, it is understood that the determination that the image size matches the image resolution is not necessarily the product of the image resolution and the image size, and may be weakly smaller, and the determination criterion is not strictly limited.
Whether the lens image that acquires is the clear image through judging in the focusing process in this embodiment, acquires the focus of camera, further confirms the region that the pollutant is located, and this embodiment is through the position of automatic acquisition pollutant in waiting to detect the lens module, has improved the detection to waiting to detect the position that the pollutant is located in the lens module, and has saved the manpower.
Further, referring to fig. 4, a third embodiment of the contaminated position detection method according to the present invention is proposed on the basis of the above-described embodiment of the present invention.
This embodiment is a step of the first embodiment, which is a refinement of step S30, and the difference between this embodiment and the above-described embodiment of the present invention is:
and step S31, acquiring an imaging optical path generated by a preset simulation program.
And step S32, determining the target mirror surface of the target lens where the pollutant is located according to the current focal length and the imaging optical path.
Step S33, determining the position of the contaminant in the lens module to be detected according to the target display area and the target mirror surface.
The simulation program of predetermineeing in this embodiment can be zemax software, use this software can obtain the simulation imaging optical path of pollutant, and then according to the imaging optical path, can calculate the virtual image distance of pollutant, again according to the virtual image distance that calculates, confirm the focus distance of camera, treat the focus distance of camera and confirm the back, alright adjust the focus distance of camera, and regard the center of waiting to detect the lens as the centre of a circle, shoot respectively to the different regions that the angle of vision divides, and acquire the clear photo that shoots, the clear photo that will shoot and the different regions that the angle of vision divides correspond predetermined standard relative ratio, finally, confirm the position and the kind of pollutant according to the comparison result.
Specifically, the step S32 is detailed as follows:
and d1, calculating the virtual image distance of the pollutant according to the current focal length and the imaging optical path.
And d2, photographing the lens module to be detected through the photographing device according to the virtual image distance to obtain a target picture.
And d3, determining the target mirror surface of the target lens where the pollutant is located according to the target picture.
The formation of image light path in this embodiment can obtain through zemax software simulation, and then according to the formation of image light path that the simulation obtained, calculate the virtual image distance of pollutant, again according to the virtual image distance that obtains that calculates, confirm the focus distance of camera, treat the focus distance of camera and confirm the back, alright adjust the focus distance of camera into definite focus distance, and use the center of treating lens in the lens module of treating and detect as the centre of a circle, shoot respectively to the different regions that the field angle was divided, and acquire the clear photo that shoots, the clear photo that will shoot finally obtains corresponds predetermined standard relative ratio with the different regions that the field angle was divided, finally, confirm position and the kind of pollutant according to the comparison result.
Confirm the position that the pollutant is located in waiting to detect the lens module through calculating in this embodiment, improved the detection to waiting to detect the position that the pollutant is located in the lens module, and saved the manpower.
In addition, referring to fig. 5, an embodiment of the present invention further provides a contaminated position detection apparatus, including:
a shooting view field acquiring module 10, configured to acquire a shooting view field of the shooting device, and divide the shooting view field into a plurality of display areas;
the focal length adjusting module 20 is configured to adjust a focal length of the shooting device, and when a clear image of a contaminant on the lens module to be detected is obtained, obtain a current focal length of the shooting device and a target display area where the contaminant is located in the shooting field of view;
and the position determining module 30 is configured to determine a position of the contaminant in the lens module to be detected according to the current focal length and the target display area.
Optionally, the captured field of view acquisition module 10 includes:
the lens type acquisition unit is used for acquiring the shooting field of view of the shooting device and the lens type of the lens module to be detected;
and the display area dividing unit is used for dividing the shooting field of view into a plurality of display areas according to the lens type.
Optionally, the focus adjusting module 20 includes:
the lens image acquisition unit is used for adjusting the focal length of the shooting device and acquiring a lens image of the lens module to be detected through the shooting device;
the judging unit is used for judging whether the lens image is a clear image;
the first execution unit is used for executing the step of adjusting the focal length of the shooting device again and acquiring the lens image of the lens module to be detected through the shooting device if the lens image is not the clear image;
and the second execution unit is used for executing the step of acquiring the current focal length of the shooting device and the target display area of the pollutant in the shooting field of view if the lens image is the clear image.
Optionally, the determining unit includes:
an acquisition unit configured to acquire an image size and an image resolution of the lens image;
a first determination unit configured to determine that the lens image is a clear image if the image size matches the image resolution;
a second determination unit configured to determine that the lens image is not a sharp image if the image size does not match the image resolution.
Optionally, the contaminated site detection apparatus includes:
the image brightness acquisition module is used for determining an image area where the pollutant is located in the clear image and acquiring the image brightness of the image area;
the first pollutant determination module is used for determining that the pollutants are of one type if the image brightness is smaller than a preset threshold value;
and the second pollutant determination module is used for determining that the pollutants are the second pollutants if the image brightness is greater than or equal to a preset threshold value.
Optionally, the position determining module 30 includes:
the imaging light path acquisition unit is used for acquiring an imaging light path generated by a preset simulation program;
the first target mirror surface determining unit is used for determining a target mirror surface of a target lens where the pollutant is located according to the current focal length and the imaging optical path;
and the position determining unit is used for determining the position of the pollutant in the lens module to be detected according to the target display area and the target mirror surface.
Optionally, the target mirror determining unit includes:
the virtual image distance calculation unit is used for calculating the virtual image distance of the pollutant according to the current focal length and the imaging light path;
the target picture acquisition unit is used for photographing the lens module to be detected through the photographing device according to the virtual image distance to obtain a target picture;
and the second target mirror surface determining unit is used for determining the target mirror surface of the target lens where the pollutant is located according to the target picture.
In addition, the embodiment of the invention also provides a computer storage medium.
The computer storage medium has a computer program stored thereon, and the computer program, when executed by a processor, implements the operations in the contaminated position detection method provided by the above-described embodiments.
The method executed by each program module can refer to each embodiment of the method of the present invention, and is not described herein again.
It should be noted that, in this document, relational terms such as first and second, and the like are only used for distinguishing one entity/operation/object from another entity/operation/object, and do not necessarily require or imply any actual relationship or order between these entities/operations/objects; the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
For the apparatus embodiment, since it is substantially similar to the method embodiment, it is described relatively simply, and reference may be made to some descriptions of the method embodiment for relevant points. The above-described apparatus embodiments are merely illustrative, in that elements described as separate components may or may not be physically separate. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of the invention. One of ordinary skill in the art can understand and implement it without inventive effort.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be substantially or partially embodied in the form of a software product, where the computer software product is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) as described above, and includes several instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the pollution location detection method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (7)

1. A contaminated position detection method characterized by being applied to a contaminated position detection apparatus including a photographing device, the contaminated position detection method comprising the steps of:
acquiring a shooting view field of the shooting device, and dividing the shooting view field into a plurality of display areas;
adjusting the focal length of the shooting device, and shooting by aiming at the lens module to be detected in the shooting field;
when a clear image of the pollutant on the lens module to be detected is obtained, the current focal length of the shooting device and a target display area where the pollutant is located in the shooting field of view are obtained;
determining the position of the pollutant in the lens module to be detected according to the current focal length and the target display area;
the step of determining the position of the pollutant in the lens module to be detected according to the current focal length and the target display area comprises the following steps:
acquiring an imaging light path generated by a preset simulation program;
calculating the virtual image distance of the pollutant according to the current focal length and the imaging light path;
determining the focusing distance of a shooting device according to the virtual image distance, adjusting the focusing distance of the shooting device to the determined focusing distance, and shooting the lens module to be detected through the shooting device to obtain a target picture;
comparing the target picture with preset standards corresponding to different areas, and determining a target mirror surface of a target lens where the pollutants are located;
and determining the position of the pollutant in the lens module to be detected according to the target display area and the target mirror surface.
2. The contamination position detection method according to claim 1, wherein the step of acquiring a photographing field of view of the photographing device, the step of dividing the photographing field of view into a plurality of display areas includes:
acquiring a shooting view field of the shooting device and the lens type of the lens module to be detected;
and dividing the shooting field of view into a plurality of display areas according to the type of the lens.
3. The method for detecting the contaminated position according to claim 1, wherein the step of adjusting the focal length of the photographing device, and when a clear image of the contaminant on the lens module to be detected is obtained, obtaining the current focal length of the photographing device and the target display area where the contaminant is located in the photographing field of view includes:
adjusting the focal length of the shooting device, and acquiring a lens image of the lens module to be detected through the shooting device;
judging whether the lens image is a clear image;
if the lens image is not a clear image, the step of adjusting the focal length of the shooting device and acquiring the lens image of the lens module to be detected through the shooting device is executed again;
and if the lens image is a clear image, acquiring the current focal length of the shooting device and a target display area where the pollutant is located in the shooting field of view.
4. The contamination position detection method according to claim 3, wherein the step of judging whether the lens image is a clear image comprises:
acquiring the image size and the image resolution of the lens image;
if the image size is matched with the image resolution, determining that the lens image is a clear image;
and if the image size does not match the image resolution, judging that the lens image is not a clear image.
5. The method for detecting the contaminated position according to claim 1, wherein the step of adjusting the focal length of the photographing device, and when acquiring the clear image of the contaminant on the lens module to be detected, acquiring the current focal length of the photographing device and the target display area where the contaminant is located in the photographing field of view, comprises the following steps:
determining an image area where the pollutant is located in the clear image, and acquiring image brightness of the image area;
if the image brightness is smaller than a preset threshold value, determining that the pollutants are pollutants of the same type;
and if the image brightness is greater than or equal to a preset threshold value, determining that the pollutants are of two types.
6. A contaminated site detection apparatus, characterized in that the contaminated site detection apparatus comprises: memory, a processor and a contaminated location detection program stored on the memory and executable on the processor, the contaminated location detection program when executed by the processor implementing the steps of the contaminated location detection method according to any of claims 1 to 5.
7. A computer-readable storage medium, characterized in that the computer-readable storage medium has stored thereon a contamination location detection program which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 5.
CN202011116074.3A 2020-10-22 2020-10-22 Pollution position detection method, device, equipment and computer readable storage medium Active CN112255239B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011116074.3A CN112255239B (en) 2020-10-22 2020-10-22 Pollution position detection method, device, equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011116074.3A CN112255239B (en) 2020-10-22 2020-10-22 Pollution position detection method, device, equipment and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN112255239A CN112255239A (en) 2021-01-22
CN112255239B true CN112255239B (en) 2022-09-20

Family

ID=74245669

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011116074.3A Active CN112255239B (en) 2020-10-22 2020-10-22 Pollution position detection method, device, equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN112255239B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114778558B (en) * 2022-06-07 2022-09-09 成都纵横通达信息工程有限公司 Bridge monitoring device, system and method based on video image
CN115183989B (en) * 2022-09-13 2023-01-10 武汉精立电子技术有限公司 Near-to-eye display module detection method and detection system

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4672200A (en) * 1985-11-05 1987-06-09 Emhart Industries, Inc. Optical inspection of transparent layers
US9696264B2 (en) * 2013-04-03 2017-07-04 Kla-Tencor Corporation Apparatus and methods for determining defect depths in vertical stack memory
WO2014200648A2 (en) * 2013-06-14 2014-12-18 Kla-Tencor Corporation System and method for determining the position of defects on objects, coordinate measuring unit and computer program for coordinate measuring unit
US10430939B1 (en) * 2017-08-28 2019-10-01 Facebook Technologies, Llc Full display panel grid-based virtual image distance test subsystem for eyecup assemblies of head mounted displays
CN108012146B (en) * 2017-12-15 2019-06-25 歌尔科技有限公司 Virtual image distance detection method and equipment
CN208285458U (en) * 2018-06-08 2018-12-25 深圳惠牛科技有限公司 The detection device of display module image quality
CN110800294A (en) * 2018-07-27 2020-02-14 深圳市大疆创新科技有限公司 Method, equipment and system for detecting camera module and machine-readable storage medium

Also Published As

Publication number Publication date
CN112255239A (en) 2021-01-22

Similar Documents

Publication Publication Date Title
JP6626954B2 (en) Imaging device and focus control method
US10083522B2 (en) Image based measurement system
KR102085766B1 (en) Method and Apparatus for controlling Auto Focus of an photographing device
TWI585436B (en) Method and apparatus for measuring depth information
CN112255239B (en) Pollution position detection method, device, equipment and computer readable storage medium
CN107111863B (en) Apparatus and method for corneal imaging
RU2612892C2 (en) Method and device of auto focus
WO2019015571A1 (en) Method for zooming by switching between dual cameras, mobile terminal and storage device
JP3781028B2 (en) Eye imaging device
WO2017219515A1 (en) Method for photographing focusing and electronic device
US8983227B2 (en) Perspective correction using a reflection
US20220083775A1 (en) Detection of Projected Infrared Patterns Using Difference of Gaussian and Blob Identification
CN105227948B (en) The method and device of distorted region in a kind of lookup image
CN105180802A (en) Identification method and device of object size information
JP6283329B2 (en) Augmented Reality Object Recognition Device
WO2016197494A1 (en) Method and device for adjusting focusing area
CN110956054B (en) Iris image acquisition method and terminal
CN112651270B (en) Gaze information determining method and device, terminal equipment and display object
CN109901716B (en) Sight point prediction model establishing method and device and sight point prediction method
JP2011120076A (en) Image detection apparatus and image detection method
US10514591B2 (en) Camera apparatus, image processing device, and image processing method
CN111899615B (en) Scoring method, device, equipment and storage medium for experiment
CN113645404A (en) Automatic focusing method, system, intelligent device, computer device and computer readable storage medium
CN111212228B (en) Image processing method and electronic device
TWI506535B (en) Electronic device and content updating method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20240510

Address after: 261031 workshop 1, phase III, Geer Photoelectric Industrial Park, 3999 Huixian Road, Yongchun community, Qingchi street, high tech Zone, Weifang City, Shandong Province

Patentee after: GoerTek Optical Technology Co.,Ltd.

Country or region after: China

Address before: 266000 room 401-436, 4th floor, building 3, Guozhan wealth center, No.18 Qinling Road, Laoshan District, Qingdao City, Shandong Province

Patentee before: QINGDAO GOERTEK TECHNOLOGY Co.,Ltd.

Country or region before: China