CN111582045A - Living body detection method and device and electronic equipment - Google Patents

Living body detection method and device and electronic equipment Download PDF

Info

Publication number
CN111582045A
CN111582045A CN202010295930.XA CN202010295930A CN111582045A CN 111582045 A CN111582045 A CN 111582045A CN 202010295930 A CN202010295930 A CN 202010295930A CN 111582045 A CN111582045 A CN 111582045A
Authority
CN
China
Prior art keywords
living body
identified
object image
color space
preset
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010295930.XA
Other languages
Chinese (zh)
Other versions
CN111582045B (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.)
Core Computing Integrated Shenzhen Technology Co ltd
Original Assignee
Shenzhen Aishen Yingtong Information 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 Shenzhen Aishen Yingtong Information Technology Co Ltd filed Critical Shenzhen Aishen Yingtong Information Technology Co Ltd
Priority to CN202010295930.XA priority Critical patent/CN111582045B/en
Publication of CN111582045A publication Critical patent/CN111582045A/en
Application granted granted Critical
Publication of CN111582045B publication Critical patent/CN111582045B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/40Spoof detection, e.g. liveness detection
    • G06V40/45Detection of the body part being alive
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/56Extraction of image or video features relating to colour

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Biophysics (AREA)
  • Data Mining & Analysis (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Human Computer Interaction (AREA)
  • Computational Linguistics (AREA)
  • Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Image Analysis (AREA)

Abstract

The embodiment of the invention relates to the technical field of detection, in particular to a method and a device for detecting a living body and electronic equipment. The method comprises the following steps: acquiring a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera; identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is the living body according to the second object image and combining a preset neural network; and if the object to be recognized is recognized as a living body according to the color space of the first object image and the object to be recognized is recognized as a living body according to the second object image, determining that the object to be recognized is the living body. By the method, the detection of the living body can be realized, and the attack of a black-white non-living body can be resisted.

Description

Living body detection method and device and electronic equipment
Technical Field
The embodiment of the invention relates to the technical field of detection, in particular to a method and a device for detecting a living body and electronic equipment.
Background
The living body detection is that for any given image, a certain strategy is adopted to search the image to determine whether the image contains a human face, if so, the position of the human face is returned, then the human face is scaled to a fixed size and input into a neural network model to judge whether the image is a living body. The existing in-vivo detection algorithm comprises a detection method based on texture, a detection method based on motion information, a detection method based on multi-feature fusion and a detection method based on a deep neural network. Among them, the detection method based on the deep neural network is currently used most widely. In the infrared camera, because the real person's pupil has a large reflectivity to near-infrared light, there is an obvious bright pupil effect, which a dummy does not have. In addition, the artificial face made of paper has traces of light reflection, and the contour of the face is slightly blurred. Therefore, the method based on the deep neural network can accurately distinguish the living body from the non-living body.
However, in the process of implementing the embodiment of the present invention, the inventors of the present invention found that: at present, an infrared living body judgment method based on a deep neural network has a good prevention effect aiming at general paper printing attacks, and if the infrared living body judgment method is in the face of the printing attacks of the infrared living body, the infrared living body judgment method is easy to break through.
Disclosure of Invention
In view of the above problems, embodiments of the present invention provide a method, an apparatus, and an electronic device for detecting a living body, which overcome or at least partially solve the above problems.
According to an aspect of an embodiment of the present invention, there is provided a method of detecting a living body, including: acquiring a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera; identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is the living body according to the second object image and combining a preset neural network; if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining that the object to be recognized is the living body; otherwise, determining that the object to be identified is not a living body.
In an optional manner, the step of identifying whether the object to be identified is a living body according to the color space of the first object image further includes: converting the RGB color space of the first object image into HSV color space; obtaining hue and saturation of HSV color space of the first object image; judging whether the HSV color space of the first object image is located in a preset living body area or a preset non-living body area based on the hue and the saturation; if the object to be identified is located in the preset living body area, determining that the object to be identified is a living body; and if the object to be identified is located in the preset non-living body area, determining that the object to be identified is not a living body.
In an alternative mode, the predetermined living body area and the predetermined non-living body area are obtained by detecting a plurality of living body samples and non-living body samples.
In an optional manner, the step of identifying whether the object to be identified is a living body according to the second object image and in combination with a preset neural network further includes: reducing the size of the second object image to a preset size; inputting the reduced second object image into a preset neural network for detection; and judging whether the reduced object to be identified is a living body or not according to the detection result.
In an optional manner, the preset neural network is a network based on a network structure of MobilenetV3, and is obtained by optimizing the number of cores per layer of MobilenetV3 by using a model pruning algorithm, wherein an activation layer of MobilenetV3 is a Relu layer.
According to an aspect of an embodiment of the present invention, a living body detection apparatus is provided, including an acquisition module configured to acquire a first object image of an object to be recognized captured by a color camera and a second object image of the object to be recognized captured by an infrared camera; the identification module is used for identifying whether the object to be identified is a living body according to the color space of the first object image and identifying whether the object to be identified is the living body according to the second object image and by combining a preset neural network; the first determining module is used for determining that the object to be identified is a living body if the object to be identified is identified as the living body according to the color space of the first object image and the object to be identified is identified as the living body according to the second object image and by combining a preset neural network; and the second determination module is used for determining that the object to be identified is not a living body.
In an alternative form, the identification module includes: a conversion unit configured to convert an RGB color space of the first object image into an HSV color space; an acquisition unit configured to acquire hue and saturation of an HSV color space of the first object image; a first determination unit configured to determine whether an HSV color space of the first object image is located in a preset living body region or a preset non-living body region based on the hue and saturation; the first determining unit is used for determining that the object to be identified is a living body if the HSV color space of the first object image is located in a preset living body area; and the second determining unit is used for determining that the object to be identified is not a living body if the HSV color space of the first object image is located in a preset non-living body area.
In an alternative mode, the predetermined living body area and the predetermined non-living body area are obtained by detecting a plurality of living body samples and non-living body samples.
In an alternative form, the identification module includes: a reduction unit configured to reduce a size of the second object image to a preset size; the input unit is used for inputting the reduced second object image into a preset neural network for detection; and the second judging unit is used for judging whether the reduced object to be identified is a living body according to the detection result.
In an optional manner, the preset neural network is a network based on a network structure of MobilenetV3, and is obtained by optimizing the number of cores per layer of MobilenetV3 by using a model pruning algorithm, wherein an activation layer of MobilenetV3 is a Relu layer.
According to an aspect of an embodiment of the present invention, there is provided an electronic apparatus including: at least one processor, and a memory communicatively coupled to the at least one processor, the memory storing instructions executable by the at least one processor to enable the at least one processor to perform a method as described above.
According to an aspect of embodiments of the present invention, there is provided a non-transitory computer-readable storage medium storing computer-executable instructions that, when executed by an electronic device, cause the electronic device to perform the method as described above.
The embodiment of the invention has the beneficial effects that: different from the existing living body detection method, the embodiment of the invention acquires a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera; identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is the living body according to the second object image and combining a preset neural network; if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining that the object to be recognized is the living body; otherwise, the mode of determining that the object to be identified is not a living body can realize the detection of the living body and can resist the attack of black and white non-living bodies, and the method can resist the print attack of the infrared living body because the print attack of the infrared living body is black and white.
Drawings
One or more embodiments are illustrated by way of example in the accompanying drawings, which correspond to the figures in which like reference numerals refer to similar elements and which are not to scale unless otherwise specified.
FIG. 1 is a schematic flow chart of a method for detecting a living body according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of identifying whether an object to be identified is a living body according to a color space of a first object image according to an embodiment of the present invention;
FIG. 3 is a hue and saturation plot for both living and non-living organisms provided by an embodiment of the present invention;
FIG. 4 is a schematic flowchart of a process for identifying whether an object to be identified is a living body according to a second object image and in combination with a preset neural network according to an embodiment of the present invention;
FIG. 5 is a schematic view of a living body detecting apparatus according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a hardware structure of an electronic device that executes a method for detecting a living body according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Example one
Referring to fig. 1, fig. 1 is a schematic flow chart of a method for detecting a living body according to an embodiment of the present invention, the method including the following steps:
step S101, a first object image of an object to be recognized shot by a color camera and a second object image of the object to be recognized shot by an infrared camera are obtained.
The color camera, in some embodiments, is an RGB camera. In some embodiments, the color camera and the infrared camera shoot the object to be recognized at the same time.
Step S102, identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is a living body according to the second object image and combining a preset neural network.
The living body shot by the color camera is colored, the color space of the living body is RGB color space, the black and white non-living body is black and white, and the living body and the black and white non-living body are obviously different, so that the attack of the black and white non-living body can be resisted by judging whether the first object image is colored or black and white. Specifically, referring to fig. 2, step S102 includes:
step S1021, converting the RGB color space of the first object image into an HSV color space.
The HSV color space includes hue, saturation, and value. In the HSV color space, the hue and saturation of the first object image of the living body and the black-and-white non-living body are significantly different. The infrared living body attack can be resisted by comparing the hue and the saturation of the first object image of the living body with the hue and the saturation of the black and white non-living body. Since the first object image captured by the color camera is an RGB color space, the RGB color space of the first object image needs to be converted into an HSV color space.
Step S1022, the hue and saturation of the HSV color space of the first object image are acquired.
And step S1023, judging whether the HSV color space of the first object image is located in a preset living body area or a preset non-living body area based on the hue and the saturation, executing step S1024 if the HSV color space of the first object image is located in the preset living body area, and executing step S1025 if the HSV color space of the first object image is located in the preset non-living body area.
The preset living body area and the preset non-living body area are obtained by detecting a plurality of living body samples and non-living body samples. Since the hue and saturation of the first object image of the living body and the hue and saturation of the black and white non-living body are significantly different, it is only necessary to collect the hue and saturation in the HSV color space of the image of the first object of the living bodies, and collect the hue and saturation in the HSV color spaces of the black and white non-living bodies, so that whether the HSV color space of the first object image is located in a preset living body region or a preset non-living body region can be determined through the region of the hue and saturation.
For example, a large number of facial image samples of living body samples and a large number of black and white non-living body samples are collected, converted into HSV color space, and hue and saturation are obtained and plotted, as shown in fig. 3. In fig. 3, real is the living body, fake is the non-living body, hue is, and saturation is. As can be seen from fig. 3, a straight line L1 in fig. 3 divides a corresponding region of hue and saturation into a living region and a non-living region, where a region where a point representing real is located is a living region and a region where a point representing fake is located is a non-living region. When the first object image is a face image, whether the object to be identified is a living body or a non-living body can be determined by judging whether the HSV color space of the first object image is located in the living body region in fig. 3 or the non-living body region in fig. 3. For example, if the hue of the HSV color space of the first object image is 120 and the saturation is 150, the object to be identified is determined to be a living body. For another example, if the hue of the HSV color space of the first object image is 120 and the saturation thereof is 25, it is determined that the object to be identified is a non-living body.
And step S1024, determining that the object to be recognized is a living body.
Step S1025, determining that the object to be recognized is not a living body.
Further, it is also necessary to identify whether the image of the second object captured by the infrared camera is a living body. Specifically, referring to fig. 4, step S102 further includes:
in step S1026, the size of the second object image is reduced to a preset size.
When the living body detection method is applied to embedded equipment such as an entrance guard, an attendance machine and the like, if a good effect is achieved, the calculation amount is large, the equipment is easy to operate at a low speed, the real-time performance is poor, and the user experience is influenced. In order to improve the calculation speed, the size of the second object image can be reduced, so that the number of channels of each residual module is reduced, the calculation amount is reduced, and the speed of processing one image by a network is increased. In some embodiments, the second object image has a size of 224x224, and the predetermined size is 112x 112.
Step S1027, inputting the reduced second object image into a preset neural network for detection.
The preset neural network is obtained by optimizing the number of cores of each layer of the MobileneetV 3 by using a model pruning algorithm and taking a network structure of the MobileneetV 3 as a basic network, wherein an activation layer of the MobileneetV 3 is a Relu layer. The Relu layer is simple, and the operation efficiency can be improved on the premise of ensuring the detection accuracy.
Step S1028, judging whether the reduced object to be recognized is a living body according to the detection result.
For example, the face of the living body has a bright pupil effect when infrared shooting is performed, and non-living bodies except for the printing attack of the infrared living body have no bright pupil effect, so that whether the to-be-identified object is a living body except for the printing attack of the infrared living body can be judged through the preset neural network according to whether the face of the to-be-identified object has the bright pupil effect.
Step S103, if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining that the object to be recognized is the living body, otherwise, executing step S104.
Normally, only the second object image is needed, and a preset neural network is combined to identify whether the object to be identified is a living body, but a printing attack on the infrared living body is easily mistaken as a living body. Since the printing attack of the infrared living body is black and white, and the first object image is taken by a color camera in color, the two are clearly distinguished. And identifying the object to be identified as a living body according to the first object image, identifying the object to be identified as the living body according to the second object image and combining a preset neural network, and determining that the object to be identified is the living body, otherwise, determining that the object to be identified is not the living body.
And step S104, determining that the object to be identified is not a living body.
In the embodiment of the invention, a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera are obtained; identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is the living body according to the second object image and combining a preset neural network; if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining that the object to be recognized is the living body; otherwise, the mode of determining that the object to be identified is not a living body can realize the detection of the living body and can resist the attack of black and white non-living bodies, and the method can resist the print attack of the infrared living body because the print attack of the infrared living body is black and white.
Example two
Referring to fig. 5, fig. 5 is a schematic diagram of a living body detection device according to an embodiment of the present invention, the device 400 includes: an acquisition module 401, an identification module 402, a first determination module 403, and a second determination module 404. The acquiring module 401 is configured to acquire a first object image of an object to be recognized, which is captured by a color camera, and a second object image of the object to be recognized, which is captured by an infrared camera; an identifying module 402, configured to identify whether the object to be identified is a living body according to the color space of the first object image, and identify whether the object to be identified is a living body according to the second object image and in combination with a preset neural network; a first determining module 403, configured to determine that the object to be recognized is a living body if the object to be recognized is recognized as a living body according to the color space of the first object image and the object to be recognized is recognized as a living body according to the second object image and in combination with a preset neural network; a second determining module 404, configured to determine that the object to be identified is not a living body.
In some embodiments, the identification module 402 comprises: a conversion unit 4021, an acquisition unit 4022, a first judgment unit 4023, a first determination unit 4024, and a second determination unit 4025. The conversion unit 4021 is configured to convert an RGB color space of the first object image into an HSV color space; an acquisition unit 4022 that acquires hue and saturation of the HSV color space of the first object image; a first determination unit 4023 configured to determine whether the HSV color space of the first object image is located in a preset living body area or a preset non-living body area, based on the hue and saturation; a first determining unit 4024, configured to determine that the object to be identified is a living body if the HSV color space of the first object image is located in a preset living body area; a second determining unit 4025, configured to determine that the object to be identified is not a living body if the HSV color space of the first object image is located in a preset non-living body area.
In some embodiments, the predetermined living body area and the predetermined non-living body area are obtained by detecting a plurality of living body samples and non-living body samples.
Further, the identifying module 402 comprises: a reduction unit 4026, an input unit 4027, and a second judgment unit 4028. The reducing unit 4026 is configured to reduce the size of the second object image to a preset size; the input unit 4027 is configured to input the reduced second object image to a preset neural network for detection; a second determining unit 4028, configured to determine whether the reduced object to be identified is a living body according to the detection result.
In some embodiments, the preset neural network is a network based on a network structure of MobilenetV3, and is obtained by optimizing the number of cores per layer of MobilenetV3 by using a model pruning algorithm, wherein the activation layer of MobilenetV3 is a Relu layer.
In the embodiment of the invention, a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera are obtained through an obtaining module; identifying whether the object to be identified is a living body or not according to the color space of the first object image and identifying whether the object to be identified is the living body or not according to the second object image and combining a preset neural network through an identification module; if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining the object to be recognized as a living body through a first determination module; otherwise, determining that the object to be identified is not a living body through a second determination module. By the device, the detection of the living body can be realized, and the attack of a black-white non-living body can be resisted.
EXAMPLE III
Referring to fig. 6, fig. 6 is a schematic hardware structure diagram of an electronic device for executing a method for detecting a living body according to an embodiment of the present invention. As shown in fig. 6, the electronic device 500 includes: one or more processors 501 and memory 502, one for example in fig. 6.
The processor 501 and the memory 502 may be connected by a bus or other means, such as the bus connection in fig. 6.
The memory 502, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as program instructions/modules (e.g., the respective modules shown in fig. 5) corresponding to the detection method of a living body in the embodiment of the present invention. The processor 501 executes various functional applications and data processing of the living body detection apparatus, that is, the living body detection method of the above-described method embodiment, by executing the nonvolatile software program, instructions, and modules stored in the memory 502.
The memory 502 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of the detection device of the living body, and the like. Further, the memory 502 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, memory 502 optionally includes memory located remotely from processor 501, which may be connected to a living detection device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 502, and when executed by the one or more processors 501, the method for detecting a living body in any of the above-described method embodiments is executed, for example, the above-described method steps S101 to S104 in fig. 1, the method steps S1021 to S1025 in fig. 2, and the method steps S1026 to S1028 in fig. 4 are executed, so as to implement the functions of the module 401 and the module 4021 and 4028 in fig. 5.
The product can execute the method provided by the embodiment of the invention, and has corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in this embodiment, reference may be made to the method provided by the embodiment of the present invention.
An embodiment of the present invention provides a non-volatile computer-readable storage medium, where the non-volatile computer-readable storage medium stores computer-executable instructions, where the computer-executable instructions are executed by an electronic device to perform the method for detecting a living body in any of the above-mentioned method embodiments, for example, the method steps S101 to S104 in fig. 1, the method steps S1021 to S1025 in fig. 2, and the method steps S1026 to S1028 in fig. 4 described above are executed to implement the functions of the module 401-.
Embodiments of the present invention provide a computer program product comprising a computer program stored on a non-volatile computer-readable storage medium, wherein the computer program comprises program instructions that, when executed by a computer, cause the computer to perform the method for detecting a living body in any of the above-described method embodiments, for example, the method steps S101 to S104 in fig. 1, the method steps S1021 to S1025 in fig. 2, and the method steps S1026 to S1028 in fig. 4 described above are performed, so as to implement the functions of the module 401-.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a general hardware platform, and certainly can also be implemented by hardware. It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a computer readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; within the idea of the invention, also technical features in the above embodiments or in different embodiments may be combined, steps may be implemented in any order, and there are many other variations of the different aspects of the invention as described above, which are not provided in detail for the sake of brevity; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A method of detecting a living body, comprising:
acquiring a first object image of an object to be identified shot by a color camera and a second object image of the object to be identified shot by an infrared camera;
identifying whether the object to be identified is a living body according to the color space of the first object image, and identifying whether the object to be identified is the living body according to the second object image and combining a preset neural network;
if the object to be recognized is recognized as a living body according to the color space of the first object image, and the object to be recognized is recognized as a living body according to the second object image and by combining a preset neural network, determining that the object to be recognized is the living body;
otherwise, determining that the object to be identified is not a living body.
2. The method according to claim 1, wherein the step of identifying whether the object to be identified is a living body based on the color space of the first object image further comprises:
converting the RGB color space of the first object image into HSV color space;
obtaining hue and saturation of HSV color space of the first object image;
judging whether the HSV color space of the first object image is located in a preset living body area or a preset non-living body area based on the hue and the saturation;
if the object to be identified is located in the preset living body area, determining that the object to be identified is a living body;
and if the object to be identified is located in the preset non-living body area, determining that the object to be identified is not a living body.
3. The method according to claim 2, wherein the predetermined living body area and the predetermined non-living body area are obtained by detecting a plurality of living body samples and non-living body samples.
4. The method for detecting a living body according to claim 1, wherein the step of identifying whether the object to be identified is a living body according to the second object image and in combination with a preset neural network further comprises:
reducing the size of the second object image to a preset size;
inputting the reduced second object image into a preset neural network for detection;
and judging whether the reduced object to be identified is a living body or not according to the detection result.
5. The method for detecting a living body according to claim 1,
the preset neural network is obtained by optimizing the number of cores of each layer of the MobileneetV 3 by using a model pruning algorithm and taking a network structure of the MobileneetV 3 as a basic network, wherein an activation layer of the MobileneetV 3 is a Relu layer.
6. A device for detecting a living body, comprising:
the device comprises an acquisition module, a recognition module and a display module, wherein the acquisition module is used for acquiring a first object image of an object to be recognized shot by a color camera and a second object image of the object to be recognized shot by an infrared camera;
the identification module is used for identifying whether the object to be identified is a living body according to the color space of the first object image and identifying whether the object to be identified is the living body according to the second object image and by combining a preset neural network;
the first determining module is used for determining that the object to be identified is a living body if the object to be identified is identified as the living body according to the color space of the first object image and the object to be identified is identified as the living body according to the second object image and by combining a preset neural network;
and the second determination module is used for determining that the object to be identified is not a living body.
7. The apparatus for detecting a living body according to claim 6, wherein the identification module includes:
a conversion unit configured to convert an RGB color space of the first object image into an HSV color space;
an acquisition unit configured to acquire hue and saturation of an HSV color space of the first object image;
a determination unit configured to determine whether an HSV color space of the first object image is located in a preset living body region or a preset non-living body region based on the hue and saturation;
the first determining unit is used for determining that the object to be identified is a living body if the HSV color space of the first object image is located in a preset living body area;
and the second determining unit is used for determining that the object to be identified is not a living body if the HSV color space of the first object image is located in a preset non-living body area.
8. The apparatus for detecting the living body according to claim 7, wherein the predetermined living body area and the predetermined non-living body area are obtained by detecting a plurality of living body samples and non-living body samples.
9. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor, the memory storing instructions executable by the at least one processor to enable the at least one processor to perform the method of any of claims 1-5.
10. A non-transitory computer-readable storage medium having stored thereon computer-executable instructions that, when executed by the electronic device, cause the electronic device to perform the method of any of claims 1-5.
CN202010295930.XA 2020-04-15 2020-04-15 Living body detection method and device and electronic equipment Active CN111582045B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010295930.XA CN111582045B (en) 2020-04-15 2020-04-15 Living body detection method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010295930.XA CN111582045B (en) 2020-04-15 2020-04-15 Living body detection method and device and electronic equipment

Publications (2)

Publication Number Publication Date
CN111582045A true CN111582045A (en) 2020-08-25
CN111582045B CN111582045B (en) 2024-05-10

Family

ID=72124380

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010295930.XA Active CN111582045B (en) 2020-04-15 2020-04-15 Living body detection method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN111582045B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112329612A (en) * 2020-11-03 2021-02-05 北京百度网讯科技有限公司 Living body detection method and device and electronic equipment
CN112613470A (en) * 2020-12-30 2021-04-06 山东山大鸥玛软件股份有限公司 Face silence living body detection method, device, terminal and storage medium
WO2022099989A1 (en) * 2020-11-10 2022-05-19 深圳市商汤科技有限公司 Liveness identification and access control device control methods, apparatus, electronic device, storage medium, and computer program

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105354554A (en) * 2015-11-12 2016-02-24 西安电子科技大学 Color and singular value feature-based face in-vivo detection method
CN108009534A (en) * 2017-11-20 2018-05-08 上海聚虹光电科技有限公司 Biopsy method based on pupil gray scale
CN108596082A (en) * 2018-04-20 2018-09-28 重庆邮电大学 Human face in-vivo detection method based on image diffusion velocity model and color character
CN108921041A (en) * 2018-06-06 2018-11-30 深圳神目信息技术有限公司 A kind of biopsy method and device based on RGB and IR binocular camera
CN110059607A (en) * 2019-04-11 2019-07-26 深圳市华付信息技术有限公司 Living body multiple detection method, device, computer equipment and storage medium
CN110163078A (en) * 2019-03-21 2019-08-23 腾讯科技(深圳)有限公司 The service system of biopsy method, device and application biopsy method
CN110520865A (en) * 2019-06-27 2019-11-29 深圳市汇顶科技股份有限公司 The method, apparatus and electronic equipment of recognition of face

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105354554A (en) * 2015-11-12 2016-02-24 西安电子科技大学 Color and singular value feature-based face in-vivo detection method
CN108009534A (en) * 2017-11-20 2018-05-08 上海聚虹光电科技有限公司 Biopsy method based on pupil gray scale
CN108596082A (en) * 2018-04-20 2018-09-28 重庆邮电大学 Human face in-vivo detection method based on image diffusion velocity model and color character
CN108921041A (en) * 2018-06-06 2018-11-30 深圳神目信息技术有限公司 A kind of biopsy method and device based on RGB and IR binocular camera
CN110163078A (en) * 2019-03-21 2019-08-23 腾讯科技(深圳)有限公司 The service system of biopsy method, device and application biopsy method
CN110059607A (en) * 2019-04-11 2019-07-26 深圳市华付信息技术有限公司 Living body multiple detection method, device, computer equipment and storage medium
CN110520865A (en) * 2019-06-27 2019-11-29 深圳市汇顶科技股份有限公司 The method, apparatus and electronic equipment of recognition of face

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112329612A (en) * 2020-11-03 2021-02-05 北京百度网讯科技有限公司 Living body detection method and device and electronic equipment
WO2022099989A1 (en) * 2020-11-10 2022-05-19 深圳市商汤科技有限公司 Liveness identification and access control device control methods, apparatus, electronic device, storage medium, and computer program
CN112613470A (en) * 2020-12-30 2021-04-06 山东山大鸥玛软件股份有限公司 Face silence living body detection method, device, terminal and storage medium

Also Published As

Publication number Publication date
CN111582045B (en) 2024-05-10

Similar Documents

Publication Publication Date Title
CN111488756B (en) Face recognition-based living body detection method, electronic device, and storage medium
CN109711243B (en) Static three-dimensional face in-vivo detection method based on deep learning
CN110084135B (en) Face recognition method, device, computer equipment and storage medium
CN107862247B (en) A kind of human face in-vivo detection method and terminal device
CN111582045A (en) Living body detection method and device and electronic equipment
CN105893920B (en) Face living body detection method and device
CN113033465A (en) Living body detection model training method, device, equipment and storage medium
CN113705426B (en) Face verification method, device, server and readable storage medium
CN108416291B (en) Face detection and recognition method, device and system
CN111178252A (en) Multi-feature fusion identity recognition method
CN110443224A (en) Page turning detection method and device, electronic equipment and storage medium
EP2528037A1 (en) Image processing device
CN116229528A (en) Living body palm vein detection method, device, equipment and storage medium
CN113221842A (en) Model training method, image recognition method, device, equipment and medium
CN111310703B (en) Identity recognition method, device, equipment and medium based on convolutional neural network
KR101336834B1 (en) Usb iris recognition device
CN111797735A (en) Face video recognition method, device, equipment and storage medium
CN110569692B (en) Multi-vehicle identification method, device and equipment
CN112215045A (en) Living body detection method and device
CN116797500B (en) Image processing method, device, storage medium, electronic equipment and product
CN111860079A (en) Living body image detection method and device and electronic equipment
CN114445898B (en) Face living body detection method, device, equipment, storage medium and program product
KR100973832B1 (en) image authentication method, Apparatus and computer readable record-medium on which program for executing method thereof
CN113920556A (en) Face anti-counterfeiting method and device, storage medium and electronic equipment
US10521907B2 (en) Image processing apparatus, program, and radiation image capturing apparatus

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
TA01 Transfer of patent application right

Effective date of registration: 20240410

Address after: Building 9, Building 203B, Phase II, Nanshan Yungu Entrepreneurship Park, No. 2 Pingshan 1st Road, Pingshan Community, Taoyuan Street, Nanshan District, Shenzhen, Guangdong Province, 518033

Applicant after: Core Computing Integrated (Shenzhen) Technology Co.,Ltd.

Country or region after: China

Address before: 518000 1001, building G3, TCL International e city, Shuguang community, Xili street, Nanshan District, Shenzhen City, Guangdong Province

Applicant before: Shenzhen Aishen Yingtong Information Technology Co.,Ltd.

Country or region before: China

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant