CN114782574A - Image generation method, face recognition device, electronic equipment and medium - Google Patents

Image generation method, face recognition device, electronic equipment and medium Download PDF

Info

Publication number
CN114782574A
CN114782574A CN202210371370.0A CN202210371370A CN114782574A CN 114782574 A CN114782574 A CN 114782574A CN 202210371370 A CN202210371370 A CN 202210371370A CN 114782574 A CN114782574 A CN 114782574A
Authority
CN
China
Prior art keywords
map
image
face
amplitude
module
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.)
Pending
Application number
CN202210371370.0A
Other languages
Chinese (zh)
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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202210371370.0A priority Critical patent/CN114782574A/en
Publication of CN114782574A publication Critical patent/CN114782574A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/80Geometric correction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10028Range image; Depth image; 3D point clouds
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20024Filtering details
    • G06T2207/20028Bilateral filtering
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30196Human being; Person
    • G06T2207/30201Face

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)

Abstract

The disclosure provides an image generation method based on a time-of-flight camera, which can be used in the financial field or other fields. The method comprises the following steps: acquiring original data shot by a flight time camera; calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and using the amplitude map as a guide map, and performing guide filtering on the depth map based on a Gaussian Laplacian operator to obtain a target image. The disclosure also provides a face recognition method, apparatus, device, storage medium and program product for an automatic teller machine.

Description

Image generation method, face recognition device, electronic device and medium
Technical Field
The present disclosure relates to the field of computer vision, and may also be used in the field of finance or other fields, and more particularly, to an image generation method, a face recognition method, an apparatus, a device, a medium, and a program product.
Background
Three-dimensional vision technology is an important research hotspot for cross-fusing machine vision and graphics processing. In recent years, with the rapid development of three-dimensional depth sensor technology, the research of three-dimensional vision technology breaks through the imaging thinking of two-dimensional space, and the analysis and interaction of three-dimensional space are realized. As one of the mainstream three-dimensional sensing technologies, a Time of Flight (ToF) camera has the advantages of small and exquisite structure, fast response Time, simple algorithm, high frame rate acquisition of three-dimensional images, and the like, and is widely applied to the fields of intelligent vehicles, robots, security monitoring, and the like. The time-of-flight camera indirectly calculates the time-of-flight of the light through the phase difference between the transmitted signal and the received signal, and further calculates the distance.
In the process of implementing the disclosed concept, the inventor finds that the accuracy of the current time-of-flight camera in image reconstruction is insufficient, and further optimization of an image generation algorithm is required.
Disclosure of Invention
In view of the above, the present disclosure provides an image generation method, a face recognition method, an apparatus, a device, a medium, and a program product.
According to a first aspect of the present disclosure, there is provided a time-of-flight camera based image generation method comprising: acquiring original data shot by a flight time camera; calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and using the amplitude map as a guide map, and performing guide filtering on the depth map based on a Gaussian Laplacian operator to obtain a target image.
According to the embodiment of the disclosure, the step of performing guided filtering on the depth map based on the laplacian of gaussian to obtain the target image comprises: constructing a weight factor of the self-adaptive regularization parameter based on a Gaussian Laplacian operator; calculating a parameter expression of a guide filtering algorithm by using a least square method based on the weight factor; obtaining a guided filtering algorithm based on optimization of a Gaussian Laplace operator based on the parameter expression of the guided filtering algorithm; and performing guided filtering on the depth map by using the guided filtering algorithm based on the optimization of the Gaussian Laplace operator to obtain a target image.
According to an embodiment of the present disclosure, the amplitude map includes a first amplitude map and a second amplitude map, the first amplitude map has a frequency smaller than the second amplitude map, the step of using the amplitude map as a guide map includes: using the second amplitude map as a guidance map.
According to an embodiment of the present disclosure, before the step of using the second amplitude map as a guidance map, the method further comprises: and carrying out joint bilateral filtering processing on the second amplitude map by using the first amplitude map.
According to an embodiment of the present disclosure, before the step of performing guided filtering on the depth map based on the laplacian of gaussian, the method further includes: and correcting the depth map by using a pinhole imaging model.
A second aspect of the present disclosure provides a face recognition method for an automated teller machine, the automated teller machine including a time-of-flight camera, the method comprising: obtaining authorization of a user for inputting a face; after the authorization that a user inputs a face is obtained, acquiring face information by using a flight time camera of an automatic teller machine; generating a target face image by using the method based on the face information; comparing the target face image with a pre-stored standard face image; and when the comparison results are consistent, determining that the face recognition result is passed.
A third aspect of the present disclosure provides an apparatus for generating an image of an object based on a time-of-flight camera, comprising: the first acquisition module is used for acquiring original data shot by the time-of-flight camera; the calculation module is used for calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and the first image generation module is used for utilizing the amplitude map as a guide map and carrying out guide filtering on the depth map based on a Gaussian laplacian operator to obtain a target image.
A fourth aspect of the present disclosure provides a face recognition apparatus for an automatic teller machine, comprising: the second acquisition module is used for acquiring the authorization of the user for inputting the face; the system comprises an acquisition module, a display module and a display module, wherein the acquisition module is used for acquiring face information by using a flight time camera of an automatic teller machine after obtaining authorization of a face input by a user; a second image generation module, configured to generate a target face image by using any one of the above methods based on the face information; the comparison module is used for comparing the target face image with a pre-stored standard face image; and the result output module is used for determining that the face recognition result is passed when the comparison result is consistent.
A fifth aspect of the present disclosure provides an electronic device, comprising: one or more processors; memory for storing one or more programs, wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to perform the above-described method.
A sixth aspect of the present disclosure also provides a computer-readable storage medium having stored thereon executable instructions that, when executed by a processor, cause the processor to perform the above-described method.
A seventh aspect of the present disclosure also provides a computer program product comprising a computer program which, when executed by a processor, implements the above method.
Drawings
The foregoing and other objects, features and advantages of the disclosure will be apparent from the following description of embodiments of the disclosure, taken in conjunction with the accompanying drawings of which:
fig. 1 schematically illustrates an application scenario diagram of an image generation method, apparatus, device, medium, and program product according to embodiments of the present disclosure;
FIG. 2 schematically shows a flow chart of an image generation method according to an embodiment of the present disclosure;
FIG. 3 schematically illustrates an imaging model between different coordinate systems in a pinhole imaging model according to an embodiment of the disclosure;
FIG. 4 schematically illustrates pixel coordinates versus image coordinates in an aperture imaging model according to an embodiment of the disclosure;
FIG. 5 schematically illustrates a flow chart of a face recognition method according to an embodiment of the present disclosure;
fig. 6 schematically shows a block diagram of the structure of an image generation apparatus according to an embodiment of the present disclosure;
fig. 7 schematically shows a block diagram of a structure of a face recognition apparatus according to an embodiment of the present disclosure; and
fig. 8 schematically shows a block diagram of an electronic device adapted to implement an image generation method, a face recognition method according to an embodiment of the present disclosure.
Detailed Description
Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. It should be understood that these descriptions are illustrative only and are not intended to limit the scope of the present disclosure. In the following detailed description, for purposes of explanation, numerous specific details are set forth in order to provide a thorough understanding of the embodiments of the disclosure. It may be evident, however, that one or more embodiments may be practiced without these specific details. Moreover, in the following description, descriptions of well-known structures and techniques are omitted so as to not unnecessarily obscure the concepts of the present disclosure.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The terms "comprises," "comprising," and the like, as used herein, specify the presence of stated features, steps, operations, and/or components, but do not preclude the presence or addition of one or more other features, steps, operations, or components.
All terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art unless otherwise defined. It is noted that the terms used herein should be interpreted as having a meaning that is consistent with the context of this specification and should not be interpreted in an idealized or overly formal sense.
Where a convention analogous to "at least one of A, B and C, etc." is used, in general such a construction is intended in the sense one having skill in the art would understand the convention (e.g., "a system having at least one of A, B and C" would include but not be limited to systems that have a alone, B alone, C alone, a and B together, a and C together, B and C together, and/or A, B, C together, etc.).
Three-dimensional vision technology is an important research hotspot for cross-fusing machine vision and graphics processing. In recent years, with the rapid development of three-dimensional depth sensor technology, the research of three-dimensional vision technology breaks the imaging thinking of two-dimensional space, and realizes the analysis and interaction of three-dimensional space. As one of the mainstream three-dimensional sensing technologies, a Time of Flight (ToF) camera has the advantages of small and exquisite structure, fast response Time, simple algorithm, high frame rate acquisition of three-dimensional images, and the like, and is widely applied to the fields of intelligent vehicles, robots, security monitoring, and the like. The time-of-flight camera indirectly calculates the time of flight of the light through the phase difference between the transmitting signal and the receiving signal, and then calculates the distance. However, when reconstructing a high-precision image, the measurement result and the measurement precision may be affected by various factors such as the inside of the camera system and the external environment during the measurement process of the time-of-flight camera, and it is important to perform a depth image optimization algorithm research on the time-of-flight camera in order to obtain higher-precision distance information.
The time-of-flight camera error sources are mainly divided into two types, firstly, errors caused by camera hardware, such as pinhole imaging errors, pixel response non-uniformity, odd harmonics and the like, are called system errors, and the measured distance is generally corrected by a pinhole imaging model and a distance error model according to the characteristics of high occurrence frequency and fixed form; and secondly, errors caused by the influence of uncertain factors such as illumination, material, motion, color and the like of the measured object are called non-system errors, the expression form of the errors is random and unfixed, and the errors are difficult to correct by using a unified standard or model.
It is contemplated that the time-of-flight camera may acquire both a depth map and an amplitude map, wherein the amplitude map directly reflects the number of light signals received by the receiver of the emitted modulated light signal, the number of receptions excluding the amount of extraneous ambient light and irrelevant stray light; the reliability of the measured distance is indirectly reflected, and generally, the larger the amplitude value is, the higher the reliability is. In addition, the guide filtering is a self-adaptive filtering method for guiding the input image by establishing a dynamic filtering kernel according to a guide image, and the overall characteristics and edge detail information of the image to be filtered and the guide image can be fully utilized. Therefore, a guiding filtering algorithm based on the amplitude image is provided, and the effect of reducing the non-system error of the time-of-flight camera is achieved.
Based on this, an embodiment of the present disclosure provides an image generation method based on a time-of-flight camera, including: acquiring original data shot by a flight time camera; calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and using the amplitude map as a guide map, and performing guide filtering on the depth map based on a Gaussian Laplacian operator to obtain a target image.
In addition, an embodiment of the present disclosure also provides a face recognition method for an automatic teller machine including a time-of-flight camera, the method including: obtaining authorization of a user for inputting a face; after the authorization that a user inputs a face is obtained, acquiring face information by using a flight time camera of an automatic teller machine; based on the face information, generating a target face image by using the method; comparing the target face image with a pre-stored standard face image; and when the comparison results are consistent, determining that the face recognition result is passed.
It should be noted that the method and apparatus determined by the present disclosure may be used for image generation in the financial field, and may also be used for image generation in any field other than the financial field.
In the technical scheme of the disclosure, the processes of collecting, storing, using, processing, transmitting, providing, disclosing and applying the personal information of the related users are all in accordance with the regulations of related laws and regulations, necessary security measures are taken, and the customs of public sequences is not violated.
In the technical scheme of the disclosure, before the personal information of the user is obtained or collected, the authorization or the consent of the user is obtained.
Fig. 1 schematically illustrates an application scenario diagram of an image generation method, apparatus, device, medium, and program product according to embodiments of the present disclosure.
As shown in fig. 1, the application scenario 100 according to this embodiment may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to receive or send messages or the like. The terminal devices 101, 102, 103 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 101, 102, 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 105 may be a server providing various services, such as a background management server (for example only) providing support for websites browsed by users using the terminal devices 101, 102, 103. The backend management server may analyze and process the received data such as the user request, and feed back a processing result (for example, a web page, information, or data obtained or generated according to the user request) to the terminal device.
It should be noted that the image generation method provided by the embodiment of the present disclosure may be generally executed by the server 105. Accordingly, the image generation apparatus provided by the embodiment of the present disclosure may be generally disposed in the server 105. The image generation method provided by the embodiments of the present disclosure may also be performed by a server or a server cluster that is different from the server 105 and is capable of communicating with the terminal devices 101, 102, 103 and/or the server 105. Accordingly, the image generating apparatus provided in the embodiment of the present disclosure may also be disposed in a server or a server cluster different from the server 105 and capable of communicating with the terminal devices 101, 102, 103 and/or the server 105.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
The image generation method of the disclosed embodiment will be described in detail below with reference to fig. 2 based on the scenario described in fig. 1.
Fig. 2 schematically shows a flow chart of an image generation method according to an embodiment of the present disclosure.
As shown in fig. 2, the image generation method of this embodiment includes operations S201 to S203.
In operation S201, raw data photographed by a time-of-flight camera is acquired.
According to the embodiment of the disclosure, the raw data includes a phase difference between the time-of-flight camera emission signal and the reception signal, and the time-of-flight of light can be indirectly calculated based on the phase difference, and then the distance is calculated, thereby reconstructing an image.
In operation S202, an amplitude map and a depth map are calculated using a four-step phase shift method based on the raw data.
The four-step phase shift method is characterized in that four sampling calculation windows are adopted for measurement, the phase delay of each calculation window is 90 degrees (0 degrees, 90 degrees, 180 degrees and 270 degrees), the original raw data acquired by the receiving camera are respectively Q0, Q1, Q2 and Q3, and the depth value d is calculated according to the following formula.
Figure BDA0003587031960000071
Figure BDA0003587031960000072
In the formula: arctan (×) represents the arctangent function, modulation frequency f, speed of light c.
The amplitude diagram confidence calculation formula is as follows:
confidence=abs(Q3-Q1)+abs(Q0-Q2)
in the formula: abs (, denotes absolute values), and Q0, Q1, Q2, and Q3 represent raw data of four phases acquired by the camera, respectively.
According to an embodiment of the present disclosure, the amplitude map includes a first amplitude map and a second amplitude map, the first amplitude map has a frequency smaller than the second amplitude map, and the step of using the amplitude map as a guide map includes: using the second amplitude map as a guidance map. The time-of-flight camera generally adopts two modulation frequency modes for data acquisition, and different frequencies obtain amplitude graphs of different light intensities, so that when the time-of-flight camera is used for acquiring data, photos of different frequency amplitudes can be obtained. The low frequency and the high frequency are obtained by comparing the magnitudes of two modulation frequency patterns adopted by the time-of-flight camera, and the amplitude diagram with the smaller frequency amplitude is the low frequency amplitude diagram, and the amplitude diagram with the larger frequency amplitude is the high frequency amplitude diagram. Since the frequency of the first amplitude map is smaller than that of the second amplitude map, the first amplitude map is a low frequency amplitude map, and the second amplitude map is a high frequency amplitude map. For example, if the frequency amplitudes of two taken pictures are 40 and 60, respectively, the frequency amplitude of the first amplitude map is 40, i.e., a low frequency amplitude map; the frequency amplitude of the second amplitude diagram is 60, i.e. a high frequency amplitude diagram.
It should be noted that the amplitude image is used as a measure of the confidence level, and the quality of the amplitude image directly determines the effect of the guided filtering on the depth map. Compared with a low-frequency amplitude map, the high-frequency amplitude map can acquire more obvious edge information, and the intensity change of light in different areas is obvious, so that the high-frequency amplitude map is selected as a guide map in a guide filtering algorithm.
According to an embodiment of the present disclosure, before the step of using the second amplitude map as a guidance map, the method further comprises: and carrying out joint bilateral filtering processing on the second amplitude map by using the first amplitude map.
It should be noted that although the high-frequency amplitude map can obtain more obvious edge information and the intensity change of light in different regions is more obvious, the low-frequency amplitude map can obtain stronger light signal intensity and can more accurately reflect the reliability of the distance measurement in the low-frequency mode, so that the reliability of image information can be further improved by performing the joint bilateral filtering process on the high-frequency amplitude map by using the low-frequency amplitude map.
In operation S203, the amplitude map is used as a guide map, and the depth map is subjected to guide filtering based on a laplacian of gaussian to obtain a target image.
According to the embodiment of the disclosure, the step of performing guided filtering on the depth map based on the laplacian of gaussian to obtain a target image comprises: constructing a weight factor of the self-adaptive regularization parameter based on a Gaussian Laplacian operator; calculating a parameter expression of a guide filtering algorithm by using a least square method based on the weight factor; obtaining a guided filtering algorithm based on the optimization of the Gaussian Laplace operator based on the parameter expression of the guided filtering algorithm; and performing guided filtering on the depth map by using the guided filtering algorithm based on the optimization of the Gaussian Laplace operator to obtain a target image. The guiding filtering algorithm based on the optimization of the Gaussian Laplace operator can be self-adapted to different region characteristics of the image, and the edge detail information is stored, so that the accuracy of the generated image is improved.
Wherein, in the classical guided filtering algorithm, there is a relationship between the output image D and the guide image amp, where k denotes the neighborhood window ω with radius rkInner center point pixel position:
Figure BDA0003587031960000091
in the formula: a isk,bkAs a neighborhood window omegakAn internal fixed constant; amp ofiThe pixel value of a certain pixel position i of the image is guided in the neighborhood window.
The core of the guided filtering is akAnd bkSolving the optimal solution. The calculation is performed by a least squares method so that the difference between the input image I and the output image D is minimized, and its minimum cost function is expressed as:
Figure BDA0003587031960000092
in the formula: ε is a regularization parameter, is a constant, usingIn preventing akToo large to maintain stability of the data.
The cost function is related to akAnd bkCan be determined by pairing akAnd bkSolving the partial derivative to carry out optimal solution, namely:
Figure BDA0003587031960000093
the optimal solution a is obtained by making the partial derivative of the formula (3) 0kAnd bk
Figure BDA0003587031960000094
In the formula: | ω | is the number of elements in the neighborhood window, | ω | ═ 2r +1)2
Figure BDA0003587031960000095
Respectively representing the average value in the neighborhood window of the guide image amp and the average value in the neighborhood window of the input image I;
Figure BDA0003587031960000096
the standard deviation in the neighborhood window of the guide image amp.
The same pixel position i can be included in multiple windows, and the same pixel position a is different due to different central positions of the multiple windowskAnd bkAre different, so that the same pixel position i calculates akAnd bkRespectively calculating a in the neighborhood window by taking the position i as a centerkAnd bkAverage value of (2)
Figure BDA0003587031960000097
And
Figure BDA0003587031960000098
so solve for DiCan be expressed as:
Figure BDA0003587031960000101
it can be seen from the above classical guided filtering algorithm that, by applying uniform regularization parameters in the whole image processing process, different region characteristics of the image cannot be adapted to the application, resulting in some edge detail information being lost.
In the embodiment of the disclosure, based on the idea of improving the guided filtering method by the adaptivity of the regularization parameter, considering that the laplacian operator can obviously highlight the change of different regions and the characteristic of being sensitive to noise, the idea based on the laplacian operator is proposed to improve the guided filtering algorithm, the distance information and the local variance of the pixel position in the neighborhood window are adopted as the weight factor of the adaptive regularization parameter, and the minimum cost function of the method is changed as compared with the formula (2):
Figure BDA0003587031960000102
in the formula: l isamp(i) A weighting factor for the adaptive regularization parameter based on the laplacian of gaussian operator.
The Gaussian Laplace operator is an operator for solving a second-order partial derivative based on a Gaussian kernel function, is a combination of the Gaussian function and the Laplace operator, and has the characteristics of smoothing of the Gaussian function and edge detection of the Laplace operator. Assuming a two-dimensional gaussian kernel function with a standard deviation σ is expressed as:
Figure BDA0003587031960000103
solving the second order partial derivative of the Gaussian kernel function to obtain a Gaussian Laplace convolution kernel, wherein the formula is as follows:
Figure BDA0003587031960000104
the distance information and local variance of the pixel position within the neighborhood window are referenced to the gaussian laplacian convolution kernel, which can be expressed as:
Figure BDA0003587031960000105
in the formula: is the position (x, y) of other pixel i in the neighborhood window relative to the position (x) of the window center kc,yc) The distance of (a) to (b),
Figure BDA0003587031960000111
Figure BDA0003587031960000112
to guide the variance of a certain point in the neighborhood window of the image amp.
Based on the above-mentioned Gauss Laplace operator Delta Gσ(i) According to the delta G of a certain point pixel and a central point pixel in the windowσ(i) The weight factor that constructs the adaptive regularization parameter is expressed as:
Figure BDA0003587031960000113
in the formula: zetaσFor regularization factors, take the value 0.1 max (amp (i))
Figure BDA0003587031960000114
Based on the weight factor, a parameter a of a guide filtering algorithm is obtained by using a least square methodkAnd bkThe expression of the optimal solution of (a) is:
Figure BDA0003587031960000115
a of the filtering algorithm to be guidedkAnd bkAnd substituting the expression of the optimal solution into the classical guided filtering algorithm to obtain a guided filtering algorithm based on the optimization of the Gaussian Laplace operator.
And performing guided filtering on the depth map by using the guided filtering algorithm based on the optimization of the Gaussian Laplacian, and performing convolution on the input image I according to the optimized formula (5) to obtain a target image.
According to an embodiment of the present disclosure, before the step of performing guided filtering on the depth map based on the laplacian of gaussian, the method further includes: and correcting the depth map by using a pinhole imaging model. When the time-of-flight camera images, the measured distance is corrected through the pinhole imaging model due to pinhole imaging errors caused by camera hardware.
Fig. 3 schematically illustrates an imaging model between different coordinate systems in a pinhole imaging model according to an embodiment of the disclosure. FIG. 4 schematically illustrates a relationship of pixel coordinates to image coordinates in an aperture imaging model according to an embodiment of the disclosure.
The specific correction method of the pinhole imaging model comprises the following steps: modeling by image imaging model between different coordinate systems, as shown in FIG. 3, camera coordinate system Oc-XcYcZcThe coordinate of the point P in the world coordinate system is P (X) in the camera coordinate systemc,Yc,Zc) The coordinate in the image coordinate system is p (x, y), and the camera focal length f is the distance from the origin of the camera coordinate to the origin of the image coordinate, i.e. f ═ Oco. As can be seen from this model, there is a triangle similarity relationship, such as ABOCAnd oCOCSimilarly, PBOCAnd pCOCSimilarly, the measured distance and the corrected distance satisfy the following relationship:
Figure BDA0003587031960000121
in the formula: o iscP is a camera measurement distance; to correct the distance; according to a right triangle poOcThe bevel distance can be calculated.
As shown in fig. 4, a pixel coordinate system ouvIn the relation between uv and the image coordinate system o-xy, the origin of the image coordinates is located at the very center of the pixel coordinates, so one can deduce:
Figure BDA0003587031960000122
in the formula: dx and dy represent the actual distance represented by each pixel in the x and y directions of the camera, respectively, in mm; u. of0,v0The ideal situation represents the coordinates of the center point of the pixel coordinate system, and the coordinates are actually cx and cy obtained by calibrating the camera.
Therefore, the distance after imaging correction obtained from the camera measurement distance is:
Figure BDA0003587031960000123
according to the image generation method based on the time-of-flight camera, the classical guided filtering algorithm is optimized based on the Gaussian operator, different region characteristics of the image can be self-adapted, edge detail information is stored, and therefore the accuracy of the generated image is improved.
The current automatic teller machine carries out safety verification in a password mode. Because the security level of the manual input password is not high, the user property loss is easily caused once the password is divulged, and certain financial risk is brought, the face recognition can be carried out on the automatic teller machine by using an image generation method based on a flight time camera, and the password verification is carried out by replacing the manual input password mode through the face recognition mode, so that the safety of service handling of the automatic teller machine is improved.
An embodiment of the present disclosure provides a face recognition method for an automatic teller machine including a time-of-flight camera, the method including: obtaining authorization of a user for inputting a face; after the authorization that a user inputs a face is obtained, acquiring face information by using a flight time camera of an automatic teller machine; generating a target face image by using the method based on the face information; comparing the target face image with a pre-stored standard face image; and when the comparison results are consistent, determining that the face recognition result is passed.
Fig. 5 schematically shows a flow chart of a face recognition method according to an embodiment of the present disclosure.
As shown in fig. 5, the face recognition method for an automatic teller machine according to this embodiment includes operations S501 to S505.
In operation S501, authorization of a user to enter a face is obtained.
In operation S502, after authorization for a user to enter a face is obtained, face information is collected using a flight time camera of an automatic teller machine.
In embodiments of the present disclosure, prior to obtaining information of a user, consent or authorization of the user may be obtained. For example, a request for obtaining user information may be issued to the user before operation S502. In case that the user information can be acquired with the user' S consent or authorization, the operation S502 is performed.
In operation S503, a target face image is generated based on the face information using the above-described image generation method based on the time-of-flight camera.
In operation S504, the target face image is compared with a pre-stored standard face image.
In operation S505, when the comparison results are consistent, it is determined that the face recognition result is a pass.
According to the face recognition method for the automatic teller machine, the high-precision three-dimensional face imaging is reconstructed by the image generation method based on the flight time camera, the method is used for verifying the password of the automatic teller machine in a face recognition mode, the mode of manually inputting the password of a bank card for verification is replaced, and the safety and the efficiency of the business operation of the automatic teller machine are greatly improved.
Based on the image generation method based on the time-of-flight camera, the disclosure also provides an image generation device based on the time-of-flight camera. The apparatus will be described in detail below with reference to fig. 6.
Fig. 6 schematically shows a block diagram of the structure of an image generation apparatus according to an embodiment of the present disclosure.
As shown in fig. 6, the image generation apparatus 600 based on a time-of-flight camera of this embodiment includes a first acquisition module 610, a calculation module 620, and a first image generation module 630.
The first acquisition module 610 is used to acquire raw data captured by a time-of-flight camera. In an embodiment, the first obtaining module 610 may be configured to perform the operation S201 described above, which is not described herein again.
The calculating module 620 is configured to calculate an amplitude map and a depth map by using a four-step phase shift method based on the raw data. In an embodiment, the calculating module 620 may be configured to perform the operation S202 described above, which is not described herein again.
The first image generation module 630 is configured to utilize the amplitude map as a guide map, and perform guide filtering on the depth map based on a laplacian of gaussian operator to obtain a target image. In an embodiment, the first image generating module 630 may be configured to perform the operation S203 described above, which is not described herein again.
Based on the face recognition method for the automatic teller machine, the disclosure also provides a face recognition device for the automatic teller machine. The apparatus will be described in detail below with reference to fig. 7.
Fig. 7 schematically shows a block diagram of a structure of a face recognition apparatus according to an embodiment of the present disclosure.
As shown in fig. 7, the face recognition apparatus 700 for an automatic teller machine of this embodiment includes a second obtaining module 710, an acquiring module 720, a second image generating module 730, a comparing module 740, and a result outputting module 750.
The second obtaining module 710 is used for obtaining the authorization of the user to enter the face. In an embodiment, the second obtaining module 710 may be configured to perform the operation S501 described above, which is not described herein again.
The collecting module 720 is configured to collect face information by using a flight time camera of an automatic teller machine after obtaining authorization of a user to enter a face. In an embodiment, the acquisition module 720 may be configured to perform the operation S502 described above, which is not described herein again.
In embodiments of the present disclosure, prior to obtaining information of a user, consent or authorization of the user may be obtained. For example, a request to obtain user information may be issued to the user before the acquisition module 720 acquires face information. In the case where the user information is available with the user's consent or authorization, the acquisition module 720 acquires face information.
The second image generating module 730 is configured to generate a target face image by using the above target image generating method based on the face information. In an embodiment, the second image generation module 730 may be configured to perform the operation S503 described above, which is not described herein again.
The comparison module 740 is configured to compare the target face image with a pre-stored standard face image. In an embodiment, the comparing module 740 may be configured to perform the operation S504 described above, which is not described herein again.
The result output module 750 is configured to determine that the face recognition result is a pass if the comparison result is consistent. In an embodiment, the result output module 750 may be configured to perform the operation S505 described above, which is not described herein again.
According to an embodiment of the present disclosure, the first obtaining module 610, the calculating module 620, the first image generating module 630, the second obtaining module 710, the collecting module 720, the second image generating module 730, the comparing module 740, and the result outputting module 750 may be combined and implemented in one module, or any one of them may be split into a plurality of modules. Alternatively, at least part of the functionality of one or more of these modules may be combined with at least part of the functionality of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the first obtaining module 610, the calculating module 620, the first image generating module 630, the second obtaining module 710, the acquiring module 720, the second image generating module 730, the comparing module 740, and the result outputting module 750 may be at least partially implemented as a hardware circuit, such as a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), a system on a chip, a system on a substrate, a system on a package, an Application Specific Integrated Circuit (ASIC), or may be implemented by hardware or firmware in any other reasonable manner of integrating or packaging a circuit, or implemented by any one of three implementations of software, hardware, and firmware, or by a suitable combination of any several of them. Alternatively, at least one of the first obtaining module 610, the calculating module 620, the first image generating module 630, the second obtaining module 710, the acquiring module 720, the second image generating module 730, the comparing module 740 and the result outputting module 750 may be at least partially implemented as a computer program module which, when executed, may perform a corresponding function.
Fig. 8 schematically shows a block diagram of an electronic device adapted to implement an image generation method, a face recognition method according to an embodiment of the present disclosure.
As shown in fig. 8, an electronic device 800 according to an embodiment of the present disclosure includes a processor 801 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)802 or a program loaded from a storage section 808 into a Random Access Memory (RAM) 803. The processor 801 may include, for example, a general purpose microprocessor (e.g., CPU), an instruction set processor and/or associated chipset, and/or a special purpose microprocessor (e.g., Application Specific Integrated Circuit (ASIC)), among others. The processor 801 may also include on-board memory for caching purposes. The processor 801 may include a single processing unit or multiple processing units for performing different actions of the method flows according to embodiments of the present disclosure.
In the RAM 803, various programs and data necessary for the operation of the electronic apparatus 800 are stored. The processor 801, the ROM 802, and the RAM 803 are connected to each other by a bus 804. The processor 801 performs various operations of the method flows according to the embodiments of the present disclosure by executing programs in the ROM 802 and/or RAM 803. Note that the programs may also be stored in one or more memories other than the ROM 802 and the RAM 803. The processor 801 may also perform various operations of method flows according to embodiments of the present disclosure by executing programs stored in the one or more memories.
Electronic device 800 may also include input/output (I/O) interface 805, input/output (I/O) interface 805 also connected to bus 804, according to an embodiment of the present disclosure. Electronic device 800 may also include one or more of the following components connected to I/O interface 805: an input portion 806 including a keyboard, a mouse, and the like; an output section 807 including components such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and a speaker; a storage portion 808 including a hard disk and the like; and a communication section 809 including a network interface card such as a LAN card, a modem, or the like. The communication section 809 performs communication processing via a network such as the internet. A drive 810 is also connected to the I/O interface 805 as necessary. A removable medium 811 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 810 as necessary, so that a computer program read out therefrom is mounted on the storage section 808 as necessary.
The present disclosure also provides a computer-readable storage medium, which may be contained in the apparatus/device/system described in the above embodiments; or may exist alone without being assembled into the device/apparatus/system. The computer-readable storage medium carries one or more programs which, when executed, implement the method according to an embodiment of the disclosure.
According to embodiments of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, which may include, for example but is not limited to: a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. For example, according to embodiments of the present disclosure, a computer-readable storage medium may include the ROM 802 and/or RAM 803 described above and/or one or more memories other than the ROM 802 and RAM 803.
Embodiments of the present disclosure also include a computer program product comprising a computer program containing program code for performing the method illustrated by the flow chart. The program code is for causing a computer system to carry out the methods of the embodiments of the disclosure when the computer program product is run on the computer system.
The computer program performs the above-described functions defined in the system/apparatus of the embodiments of the present disclosure when executed by the processor 801. The above described systems, devices, modules, units, etc. may be implemented by computer program modules according to embodiments of the present disclosure.
In one embodiment, the computer program may be hosted on a tangible storage medium such as an optical storage device, a magnetic storage device, or the like. In another embodiment, the computer program may also be transmitted in the form of a signal, distributed over a network medium, downloaded and installed via communications portion 809, and/or installed from removable media 811. The computer program containing program code may be transmitted using any suitable network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the foregoing.
In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 809 and/or installed from the removable medium 811. The computer program, when executed by the processor 801, performs the above-described functions defined in the system of the embodiments of the present disclosure. The systems, devices, apparatuses, modules, units, etc. described above may be implemented by computer program modules according to embodiments of the present disclosure.
In accordance with embodiments of the present disclosure, program code for executing computer programs provided by embodiments of the present disclosure may be written in any combination of one or more programming languages, and in particular, these computer programs may be implemented using high level procedural and/or object oriented programming languages, and/or assembly/machine languages. The programming language includes, but is not limited to, programming languages such as Java, C + +, python, the "C" language, or the like. The program code may execute entirely on the user computing device, partly on the user device, partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
It will be appreciated by a person skilled in the art that various combinations or/and combinations of features recited in the various embodiments of the disclosure and/or in the claims may be made, even if such combinations or combinations are not explicitly recited in the disclosure. In particular, various combinations and/or combinations of the features recited in the various embodiments and/or claims of the present disclosure may be made without departing from the spirit or teaching of the present disclosure. All such combinations and/or associations are within the scope of the present disclosure.
The embodiments of the present disclosure are described above. However, these examples are for illustrative purposes only and are not intended to limit the scope of the present disclosure. Although the embodiments are described separately above, this does not mean that the measures in the embodiments cannot be used in advantageous combination. The scope of the disclosure is defined by the appended claims and equivalents thereof. Various alternatives and modifications can be devised by those skilled in the art without departing from the scope of the present disclosure, and such alternatives and modifications are intended to be within the scope of the present disclosure.

Claims (11)

1. An image generation method based on a time-of-flight camera, comprising:
acquiring original data shot by a flight time camera;
calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and
and using the amplitude map as a guide map, and performing guide filtering on the depth map based on a Gaussian Laplacian operator to obtain a target image.
2. The method of claim 1, wherein the step of performing guided filtering on the depth map based on the laplacian of gaussian to obtain the target image comprises:
constructing a weight factor of the self-adaptive regularization parameter based on a Gaussian Laplacian operator;
calculating a parameter expression of a guide filtering algorithm by using a least square method based on the weight factor;
obtaining a guided filtering algorithm based on the optimization of the Gaussian Laplace operator based on the parameter expression of the guided filtering algorithm; and
and performing guided filtering on the depth map by using the guided filtering algorithm based on the optimization of the Gaussian Laplacian operator to obtain a target image.
3. The method of claim 1, wherein the amplitude map comprises a first amplitude map and a second amplitude map, wherein the first amplitude map has a frequency less than the second amplitude map, and wherein the step of using the amplitude map as a guide map comprises:
using the second amplitude map as a guidance map.
4. The method of claim 3, wherein prior to the step of using the second amplitude map as a guidance map, the method further comprises:
and carrying out joint bilateral filtering processing on the second amplitude map by utilizing the first amplitude map.
5. The method of claim 1, wherein the step of guided filtering the depth map based on the laplacian of gaussian is preceded by the method further comprising:
and correcting the depth map by using a pinhole imaging model.
6. A face recognition method for an automated teller machine including a time-of-flight camera, the method comprising:
obtaining authorization of a user for inputting a face;
after the authorization that a user inputs a face is obtained, acquiring face information by using a flight time camera of an automatic teller machine;
generating a target face image using the method of any one of claims 1-5 based on the face information;
comparing the target face image with a pre-stored standard face image; and
and when the comparison results are consistent, determining that the face recognition result is passed.
7. An apparatus for generating an image of an object based on a time-of-flight camera, comprising:
the first acquisition module is used for acquiring original data shot by the time-of-flight camera;
the calculation module is used for calculating to obtain an amplitude map and a depth map by using a four-step phase shift method based on the original data; and
and the first image generation module is used for performing guide filtering on the depth map based on a Gaussian Laplacian operator by using the amplitude map as a guide map to obtain a target image.
8. A face recognition apparatus for an automatic teller machine, comprising:
the second acquisition module is used for acquiring the authorization of the user for inputting the face;
the system comprises an acquisition module, a face information acquisition module and a face information acquisition module, wherein the acquisition module is used for acquiring face information by using a flight time camera of the automatic teller machine after obtaining authorization of a face input by a user;
a second image generation module for generating a target face image based on the face information by using the method of any one of claims 1 to 5;
the comparison module is used for comparing the target face image with a pre-stored standard face image; and
and the result output module is used for determining that the face recognition result is passed when the comparison results are consistent.
9. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to perform the method of any of claims 1-6.
10. A computer readable storage medium having stored thereon executable instructions which, when executed by a processor, cause the processor to perform the method of any one of claims 1 to 6.
11. A computer program product comprising a computer program which, when executed by a processor, carries out the method according to any one of claims 1 to 6.
CN202210371370.0A 2022-04-08 2022-04-08 Image generation method, face recognition device, electronic equipment and medium Pending CN114782574A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210371370.0A CN114782574A (en) 2022-04-08 2022-04-08 Image generation method, face recognition device, electronic equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210371370.0A CN114782574A (en) 2022-04-08 2022-04-08 Image generation method, face recognition device, electronic equipment and medium

Publications (1)

Publication Number Publication Date
CN114782574A true CN114782574A (en) 2022-07-22

Family

ID=82428474

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210371370.0A Pending CN114782574A (en) 2022-04-08 2022-04-08 Image generation method, face recognition device, electronic equipment and medium

Country Status (1)

Country Link
CN (1) CN114782574A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115797347A (en) * 2023-02-06 2023-03-14 临沂农业科技职业学院(筹) Automatic production line abnormity monitoring method based on computer vision

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115797347A (en) * 2023-02-06 2023-03-14 临沂农业科技职业学院(筹) Automatic production line abnormity monitoring method based on computer vision
CN115797347B (en) * 2023-02-06 2023-04-28 临沂农业科技职业学院(筹) Automatic production line abnormality monitoring method based on computer vision

Similar Documents

Publication Publication Date Title
CN110427917B (en) Method and device for detecting key points
US9952036B2 (en) Systems, methods, and apparatuses for implementing maximum likelihood image binarization in a coded light range camera
CN107123142B (en) Pose estimation method and device
US10645309B2 (en) Systems, methods, and apparatuses for implementing maximum likelihood image binarization in a coded light range camera
US20200293793A1 (en) Methods and systems for video surveillance
US20170008650A1 (en) Attitude estimation method and system for on-orbit three-dimensional space object under model restraint
US10852208B2 (en) Quantifying gas leak rates using frame images acquired by a camera
CN113607185B (en) Lane line information display method, lane line information display device, electronic device, and computer-readable medium
CN109640066B (en) Method and device for generating high-precision dense depth image
US20230084728A1 (en) Systems and methods for object measurement
CN110231832B (en) Obstacle avoidance method and obstacle avoidance device for unmanned aerial vehicle
CN110288625B (en) Method and apparatus for processing image
Belhedi et al. Noise modelling in time‐of‐flight sensors with application to depth noise removal and uncertainty estimation in three‐dimensional measurement
CN114648675A (en) Countermeasure training method, image processing method, apparatus, device, and medium
CN114782574A (en) Image generation method, face recognition device, electronic equipment and medium
WO2022247406A1 (en) Systems and methods for determining key frame images of video data
US10838487B2 (en) Mixed pixel unwrapping error mitigation by filtering optimization
US20200374443A1 (en) Image processing method and apparatus
CN109785312B (en) Image blur detection method and system and electronic equipment
US20230019751A1 (en) Method and apparatus for light estimation
CN116071280A (en) Video complement method, device, medium and electronic equipment
He et al. Error correction of depth images for multiview time-of-flight vision sensors
CN113393508A (en) Laser ranging imaging method and device, electronic equipment and storage medium
CN116416290A (en) Method and device for calculating speckle structure light depth and electronic equipment
Fuersattel et al. Distance error correction for time-of-flight cameras

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