CN111970444B - Method and system for realizing distance identification of objects in scene and robot - Google Patents
Method and system for realizing distance identification of objects in scene and robot Download PDFInfo
- Publication number
- CN111970444B CN111970444B CN202010827775.1A CN202010827775A CN111970444B CN 111970444 B CN111970444 B CN 111970444B CN 202010827775 A CN202010827775 A CN 202010827775A CN 111970444 B CN111970444 B CN 111970444B
- Authority
- CN
- China
- Prior art keywords
- scene
- far
- image
- objects
- camera
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 23
- 238000011156 evaluation Methods 0.000 claims abstract description 25
- 230000001419 dependent effect Effects 0.000 claims description 3
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/60—Control of cameras or camera modules
- H04N23/67—Focus control based on electronic image sensor signals
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01C—MEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
- G01C3/00—Measuring distances in line of sight; Optical rangefinders
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Electromagnetism (AREA)
- General Physics & Mathematics (AREA)
- Radar, Positioning & Navigation (AREA)
- Remote Sensing (AREA)
- Measurement Of Optical Distance (AREA)
- Studio Devices (AREA)
Abstract
A method, a system and a robot for realizing the distance identification of objects in a scene acquire images focused on different positions of the scene through an automatic focusing camera and number the acquired images according to focusing position information; selecting a reference image in a scene, selecting a point or a region on the reference image, and finding points or regions corresponding to the point or the region on other images; calculating the near-far evaluation index of the selected point or area in the scene; and repeating the steps to obtain the far and near evaluation indexes of the scene points or the scene areas corresponding to any points or any areas in the reference image, and identifying the far and near of the objects in the scene by using the evaluation indexes. The invention also provides a system for realizing the distance identification of the objects in the scene and a robot. According to the invention, through the automatic focusing camera, the robot can identify the distance of an object by only carrying one camera.
Description
Technical Field
The invention belongs to the field of machine vision, and relates to a method, a system and a robot for realizing far and near identification of objects in a scene.
Background
The robot is characterized in that the distance is identified as a key function of the robot moving along the autonomous direction, the binocular stereo vision technology is mostly adopted at present, two cameras are needed by the binocular stereo vision technology, and if the robot can use a single camera to realize the distance discrimination of an object, the hardware cost of a robot vision system can be greatly reduced, the structural size of the robot is reduced, and the flexibility of the robot is improved.
Disclosure of Invention
The invention aims to solve the problem that two cameras are needed to be used for identifying distance through a binocular stereo vision technology in the prior art, and provides a method, a system and a robot for identifying distance of an object in a scene.
In order to achieve the purpose, the invention has the following technical scheme:
a method for realizing far and near identification of objects in a scene by utilizing an automatic focusing camera comprises the following steps:
acquiring images focused at different positions of a scene through an automatic focusing camera, and recording focusing position information;
and identifying the distance of an object in the scene by using the acquired image and the recorded focusing position information.
Preferably, the method specifically comprises the following steps:
the method comprises the following steps: collecting images focused at different positions of a scene through an automatic focusing camera, and numbering the collected images according to focusing position information;
step two: selecting a reference image in a scene, selecting a point or a region on the reference image, and finding points or regions corresponding to the point or the region on other images;
step three: calculating the near-far evaluation index of the selected point or area in the scene;
step four: and repeating the second step and the third step to obtain far and near evaluation indexes of scene points or scene areas corresponding to any points or any areas in the reference image, and identifying the far and near of objects in the scene by using the evaluation indexes.
Preferably, the number in the step one is determined according to an object distance of the auto-focusing camera to the focus, or a focusing control parameter value of the auto-focusing camera, or a number automatically set from near to far or from far to near according to the position of the focus.
Preferably, the reference image selected in step two is the image with the closest focus in the scene.
Preferably, the method for calculating the near-far evaluation index includes: calculating the focus metric values of corresponding points or corresponding areas of the reference image and other images, finding out the image corresponding to the maximum focus metric value and two images adjacent to the image, taking the image number of the three images as an independent variable x, the focus metric value of the corresponding point or corresponding area of the image as a dependent variable y, and fitting a quadratic curve y to ax2+ bx + c, the image number-b/2 a corresponding to the maximum value of the quadratic curve is used as the evaluation index.
Preferably, the basis for identifying the distance of the object in the scene in the fourth step is as follows: if the smaller the image number is, the closer the position of the automatic focusing camera to the focus is, the smaller the evaluation index is, the closer the object in the scene is to the automatic focusing camera is; if the image number is larger, the position of the focus of the camera is closer, the evaluation index is larger, and the object in the scene is closer to the camera.
The invention also provides a system for realizing the distance identification of the objects in the scene, which comprises the following steps:
the image acquisition module acquires images focused on different positions of a scene through the automatic focusing camera, records focusing position information, and sends the acquired images and the recorded focusing position information to the data processing module;
and the data processing module is used for identifying the distance of an object in the scene by utilizing the acquired image and the recorded focusing position information.
The invention also provides a robot with the system for realizing the far and near identification of the objects in the scene.
Compared with the prior art, the invention has the following beneficial effects: the robot can complete the far and near identification of objects by only carrying one camera by utilizing the automatic focusing camera, compared with the existing binocular stereo vision identification system, the far and near identification of the objects in a scene is carried out by the identification method provided by the invention, and the method has the advantages of low hardware cost, small structural size of a vision system, high motion flexibility of the robot and the like, and in addition, the three-dimensional reconstruction of the scene is easy to realize.
Drawings
FIG. 1 is a flowchart of a method for implementing distance recognition of objects in a scene according to the present invention;
the following describes in detail specific embodiments of the present invention. It should be understood by those skilled in the art that the specific embodiments described herein are for purposes of illustration and explanation only and are not intended to be limiting.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings.
The invention provides a method for identifying the distance of an object in a scene, which comprises the steps of collecting images focused on different positions of the scene by changing the position of a camera to a focus, recording focusing position information, and identifying the distance of the object in the scene by utilizing the collected images and the recorded focusing position information. The embodiment of the invention specifically comprises the following steps:
the method comprises the following steps: collecting images focused at different positions of a scene by using an automatic focusing camera, and numbering the images according to focusing position information;
step two: selecting a reference image, selecting a point or a region on the reference image, and finding the point or the region corresponding to the point or the region on other images;
step three: calculating the near-far evaluation index of the point or the area in the scene;
step four: and repeating the second step and the third step to obtain far and near evaluation indexes of scene points or scene areas corresponding to any points or any areas in the reference image, and identifying the far and near of objects in the scene by using the evaluation indexes.
And numbering the images according to focusing position information, wherein the number is an object distance of a camera to a focus, or a focusing control parameter value of the camera, or a number which is set from near to far or from far to near according to the position of the focus.
And the reference image selected in the step two is the image with the narrowest visual field in the acquired scene images, namely the image with the focus at the nearest position.
Step three, calculating farThe method for evaluating the index comprises the following steps: calculating the focus metric values of corresponding points or corresponding areas of the reference image and other images, finding out the image corresponding to the maximum focus metric value and two images adjacent to the image, taking the image number of the three images as an independent variable x, the focus metric value of the corresponding point or corresponding area of the image as a dependent variable y, and fitting a quadratic curve y to ax2+ bx + c, the image number-b/2 a corresponding to the maximum value of the quadratic curve is used as the evaluation index.
The basis for identifying the distance of the object in the scene in the fourth step is as follows: if the smaller the image number is, the closer the position of the camera to the focus is, the smaller the evaluation index is, the closer the object in the scene is to the camera is; if the image number is larger, the position of the focus of the camera is closer, the evaluation index is larger, and the object in the scene is closer to the camera.
In the following, taking the camera focusing control parameters (0 to 1023) as image numbers as an example, how to identify the distance of an object in a scene by using the evaluation index is illustrated, and other image number manners can be implemented in comparison with the embodiment.
The larger the camera focus control parameter is, for example 1023, the closer the position of the camera to the focus point is, and therefore the larger the evaluation index calculated by quadratic curve fitting is, the closer the object in the scene is to the camera.
It should be noted that the autofocus camera of the present invention refers to a vision system having an autofocus function or capable of implementing an autofocus function, including a camera with an electric focus lens or a motorized zoom lens.
The above-mentioned embodiments are only preferred embodiments of the present invention, and are not intended to limit the technical solution of the present invention, and it should be understood by those skilled in the art that the technical solution can be modified and replaced by a plurality of simple modifications and replacements without departing from the spirit and principle of the present invention, and the modifications and replacements also fall into the protection scope covered by the claims.
Claims (6)
1. A method for realizing distance identification of objects in a scene is characterized in that:
acquiring images focused at different positions of a scene through an automatic focusing camera, and recording focusing position information;
identifying the distance of an object in the scene by using the acquired image and the recorded focusing position information;
the method specifically comprises the following steps:
the method comprises the following steps: collecting images focused at different positions of a scene through an automatic focusing camera, and numbering the collected images according to focusing position information;
step two: selecting a reference image in a scene, selecting a point or a region on the reference image, and finding points or regions corresponding to the point or the region on other images;
step three: calculating the near-far evaluation index of the selected point or area in the scene;
step four: repeating the second step and the third step to obtain far and near evaluation indexes of scene points or scene areas corresponding to any points or any areas in the reference image, and identifying the distance of objects in the scene by using the evaluation indexes;
the method for calculating the near-far evaluation index comprises the following steps: calculating the focus metric values of corresponding points or corresponding areas of the reference image and other images, finding out the image corresponding to the maximum focus metric value and two images adjacent to the image, taking the image number of the three images as an independent variable x, the focus metric value of the corresponding point or corresponding area of the image as a dependent variable y, and fitting a quadratic curve y to ax2+ bx + c, the image number-b/2 a corresponding to the maximum value of the quadratic curve is used as the evaluation index.
2. The method for realizing the far and near recognition of the objects in the scene according to claim 1, wherein:
the numbering in the step one is based on the object distance of the automatic focusing camera to the focus, or the focusing control parameter value of the automatic focusing camera, or the numbering which is set by the automatic focusing camera from near to far or from far to near according to the position of the focus.
3. The method for realizing the far and near recognition of the objects in the scene according to claim 1, wherein:
and step two, the selected reference image is the image with the focus closest to the scene.
4. The method for realizing the far and near recognition of the objects in the scene according to claim 1, wherein:
fourthly, identifying the distance of the objects in the scene according to the following basis: if the smaller the image number is, the closer the position of the automatic focusing camera to the focus is, the smaller the evaluation index is, the closer the object in the scene is to the automatic focusing camera is; if the image number is larger, the position of the focus of the camera is closer, the evaluation index is larger, and the object in the scene is closer to the camera.
5. A system for realizing far and near object identification in a scene is characterized by executing the method for realizing far and near object identification in a scene in any one of claims 1-4; the system for realizing far and near identification of objects in a scene comprises:
the image acquisition module acquires images focused on different positions of a scene through the automatic focusing camera, records focusing position information, and sends the acquired images and the recorded focusing position information to the data processing module;
and the data processing module is used for identifying the distance of an object in the scene by utilizing the acquired image and the recorded focusing position information.
6. A robot, characterized by: the system for realizing the far and near recognition of the objects in the scene as claimed in claim 5 is provided.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010827775.1A CN111970444B (en) | 2020-08-17 | 2020-08-17 | Method and system for realizing distance identification of objects in scene and robot |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010827775.1A CN111970444B (en) | 2020-08-17 | 2020-08-17 | Method and system for realizing distance identification of objects in scene and robot |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111970444A CN111970444A (en) | 2020-11-20 |
CN111970444B true CN111970444B (en) | 2021-11-23 |
Family
ID=73389163
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010827775.1A Active CN111970444B (en) | 2020-08-17 | 2020-08-17 | Method and system for realizing distance identification of objects in scene and robot |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111970444B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102843510A (en) * | 2011-06-14 | 2012-12-26 | 宾得理光映像有限公司 | Imaging device and distance information detecting method |
CN105025219A (en) * | 2014-04-30 | 2015-11-04 | 齐发光电股份有限公司 | Image acquisition method |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP3059949A1 (en) * | 2015-02-23 | 2016-08-24 | Thomson Licensing | Method and apparatus for generating lens-related metadata |
-
2020
- 2020-08-17 CN CN202010827775.1A patent/CN111970444B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102843510A (en) * | 2011-06-14 | 2012-12-26 | 宾得理光映像有限公司 | Imaging device and distance information detecting method |
CN105025219A (en) * | 2014-04-30 | 2015-11-04 | 齐发光电股份有限公司 | Image acquisition method |
Also Published As
Publication number | Publication date |
---|---|
CN111970444A (en) | 2020-11-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109696788B (en) | Quick automatic focusing method based on display panel | |
US10552964B2 (en) | Object tracking device and a control method for object tracking device | |
CN1716078B (en) | Image pickup apparatus and image pickup method | |
CN105282443B (en) | A kind of panorama depth panoramic picture imaging method | |
US9501834B2 (en) | Image capture for later refocusing or focus-manipulation | |
CN103973957B (en) | Binocular 3D automatic focusing system for camera and method | |
CN105578029B (en) | A kind of auto-focusing searching algorithm of multi-scale variable step size | |
WO2015137635A1 (en) | Image pickup apparatus and method for generating image having depth information | |
CN108387517B (en) | Slice scanning method and system | |
CN106105193A (en) | For producing image pick up equipment and the method for the image with depth information | |
CN104902182A (en) | Method and device for realizing continuous auto-focus | |
CN106019550A (en) | High speed micro scanning dynamic focusing device and focusing tracking method | |
CN104735350A (en) | Information processing method and electronic equipment | |
CN107133982A (en) | Depth map construction method, device and capture apparatus, terminal device | |
CN106412400A (en) | Bionic vision imaging system based on visible light and near infrared and focusing method thereof | |
JP2014123805A (en) | Image processing apparatus, imaging apparatus, image processing program, and image processing method | |
CN106254855B (en) | A kind of three-dimensional modeling method and system based on zoom ranging | |
CN111970444B (en) | Method and system for realizing distance identification of objects in scene and robot | |
Yang et al. | A rapid auto-focus method in automatic microscope | |
CN109151319B (en) | Method and device for processing focusing sequence of mark points of multi-mark-point target object | |
JP2008089811A (en) | Imaging apparatus and control method therefor | |
US8179471B2 (en) | Focusing device and image pickup apparatus | |
JP2018017876A (en) | Imaging apparatus and control method of the same, and image processing apparatus and method | |
CN105812669A (en) | Curved automatic imaging focusing method and system | |
CN104079817A (en) | Multi-camera coordination control and quick precise target recognition system |
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 | ||
EE01 | Entry into force of recordation of patent licensing contract |
Application publication date: 20201120 Assignee: Xi'an Lianke Information Technology Co.,Ltd. Assignor: CHANG'AN University Contract record no.: X2023980048491 Denomination of invention: A Method, System, and Robot for Realizing Distance and Proximity Identification of Objects in Scenes Granted publication date: 20211123 License type: Common License Record date: 20231127 |
|
EE01 | Entry into force of recordation of patent licensing contract |