WO2020248387A1 - Face recognition method and apparatus based on multiple cameras, and terminal and storage medium - Google Patents

Face recognition method and apparatus based on multiple cameras, and terminal and storage medium Download PDF

Info

Publication number
WO2020248387A1
WO2020248387A1 PCT/CN2019/103389 CN2019103389W WO2020248387A1 WO 2020248387 A1 WO2020248387 A1 WO 2020248387A1 CN 2019103389 W CN2019103389 W CN 2019103389W WO 2020248387 A1 WO2020248387 A1 WO 2020248387A1
Authority
WO
WIPO (PCT)
Prior art keywords
face image
face
camera device
angle
sample database
Prior art date
Application number
PCT/CN2019/103389
Other languages
French (fr)
Chinese (zh)
Inventor
戴磊
Original Assignee
平安科技(深圳)有限公司
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 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2020248387A1 publication Critical patent/WO2020248387A1/en

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/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/161Detection; Localisation; Normalisation
    • G06V40/166Detection; Localisation; Normalisation using acquisition arrangements
    • 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/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/172Classification, e.g. identification
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • This application relates to the field of image recognition technology, and in particular to a face recognition method based on multiple cameras, a face recognition device based on multiple cameras, a terminal and a storage medium.
  • face recognition technology as a high-end and reliable means of identity detection, has greatly improved the user experience in modern production and life applications, so it can be widely used in access management, Monitoring management, computer security protection, photo search, ATM machine intelligent video alarm, railway security inspection and identification and other applications.
  • a multi-channel camera device is generally used to capture the image of the face to be recognized, and then through a series of image preprocessing and image recognition processing, the face in the captured image is processed Recognition, obtain the identity recognition result of the face to be recognized.
  • the inventor found that the current general practice is that all camera devices share the same sample database, but the placement of each camera device, the environment, and the angle at which the face is captured may be different, resulting in the same sample database.
  • the adaptability is different. For example, the shooting angle, for a sample database where the face images in the sample database are all frontal images, the face recognition effect corresponding to the face image captured by the camera device with the frontal shooting angle is good, otherwise it will be worse. .
  • the first aspect of the embodiments of the present application provides a face recognition method based on multi-channel camera.
  • the face recognition method based on multi-channel camera includes:
  • the smallest angle difference is selected from the angle difference as the target angle difference
  • the second aspect of the embodiments of the present application also provides a face recognition device based on multi-channel camera, the face recognition device based on multi-channel camera includes:
  • a sample database establishment module for establishing a sample database corresponding to each camera device in the preset multi-channel camera device, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device;
  • the face image acquisition module is used to acquire multiple faces to be measured in the face images to be measured taken by each camera at the same time;
  • a shooting angle recognition module configured to recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model
  • An angle difference calculation module configured to calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device
  • the target difference determination module is configured to filter out the smallest angle difference from the angle difference as the target angle difference
  • a sample database determining module configured to determine the sample database of the camera device corresponding to the target angle difference as the target sample database
  • the face recognition module is configured to recognize, according to the face image in the target sample database, the face image to be measured taken by the camera device corresponding to the target angle difference.
  • the third aspect of the embodiments of the present application further provides a terminal, the terminal includes a processor, and the processor is configured to implement the multi-channel camera-based face of any one of the above when executing computer-readable instructions stored in the memory. recognition methods.
  • the fourth aspect of the embodiments of the present application also provides a non-volatile readable storage medium having computer readable instructions stored on the non-volatile readable storage medium, and the computer readable instructions are implemented when executed by a processor
  • the embodiment of the application provides a face recognition method based on multiple cameras, a face recognition device based on multiple cameras, a terminal, and a non-volatile readable storage medium, which are preset for each camera in the multiple camera
  • the device establishes a sample database, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device; acquiring a plurality of faces to be measured of the faces to be measured that are simultaneously photographed by each camera Image; recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model; calculate the angle difference between the shooting angle of the face image to be tested and the shooting angle of each camera The smallest angle difference is selected from the angle difference as the target angle difference; the sample database of the camera device corresponding to the target angle difference is determined as the target sample database; according to the target sample database The face image recognizes the face image to be measured taken by the camera device corresponding to the target angle difference.
  • a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device.
  • face recognition for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be tested is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
  • FIG. 1 is a flowchart of a face recognition method based on multi-channel camera provided by an embodiment of the present application.
  • FIG. 2 is a schematic structural diagram of a terminal according to an embodiment of the present application.
  • Fig. 3 is an exemplary functional block diagram of the terminal shown in Fig. 2.
  • FIG. 1 is a flowchart of a face recognition method based on multiple cameras in the first embodiment of the present application.
  • the face recognition method based on multiple cameras can be applied to a terminal 1, and the terminal 1 may be, for example, a smart phone, Smart devices such as notebook computers, desktop/tablet computers, smart watches, and personal digital assistants (PDAs).
  • the face recognition method based on multi-channel camera may include the following steps:
  • S101 Establish a sample database for each of the preset multi-channel camera devices, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device.
  • the preset multi-channel camera device is a camera device preset at multiple shooting positions. Due to the different shooting positions, the corresponding camera devices have different angles, and the angles of the captured face images are also different.
  • the camera device may be one or more of a camera, a digital camera, and a digital camera.
  • the number of the camera devices is not limited here, and the number of the camera devices can be set according to the actual shooting angle. Taking the number of the camera devices as three as an example, the preset multi-channel camera device includes a first camera device, a second camera device, and a third camera device arranged in a common center.
  • the shooting angle is relative.
  • the position of the first camera device located in the center as 0°, and the angle of the face image captured by the corresponding first camera device is 0°;
  • the position of the second camera on the right becomes a positive angle, and the angle of the face image taken by the corresponding second camera is positive;
  • all the third cameras located on the left of the first camera The position of the road camera device becomes a negative angle, and the corresponding angle of the face image taken by the third road camera device is negative.
  • the center is used as the center point
  • three different positions are set, namely the first position, the second position, and the third position.
  • the first position is 0°
  • the first position is installed with the first camera
  • the second position is +90°
  • the second position is installed with the second camera
  • the third position is -90°
  • a third camera is installed at the third position.
  • the angle of the face taken by the first camera is 0°, and the face taken at this angle is a front face
  • the angle of the face taken by the second camera is +90°, and the person taken at this angle
  • the face is the right face
  • the face angle taken by the third camera device is -90°
  • the face taken at this angle is the left face.
  • an independent sample database of left face/front face/right face is set up, and the independent sample database of left face/front face/right face is used to store the left face/front face/right face sample photos of different users.
  • the establishing a sample database for each camera device in the preset multi-channel camera device includes: taking the center as the center point, setting the shooting angle of the first camera device to 0°, and setting the second camera device
  • the shooting angle of the camera device is +90°
  • the shooting angle of the third camera device is set to -90°
  • the first camera device, the second camera device, and the third camera device are controlled Simultaneously photograph a preset number of target testers for each of the target testers to obtain face images of different shooting angles; take the preset number of faces of the target testers captured by the first camera
  • the image is used as the first sample database of the first camera, and the preset number of face images of the target tester captured by the second camera are used as the second
  • the sample database uses the preset number of face images of the target tester captured by the third camera device as the third sample database of the third camera device. Wherein, the preset number is preset, and the number of target testers who need to collect face images.
  • the sample database in addition to storing a preset number of face images of the target tester in the first sample database, the second sample database, and the third sample database, the sample database also includes human faces.
  • Image identification the face image identification of the same target tester is unique, and the face image identification is used to identify the identity information of the corresponding tester. Therefore, in one embodiment, it is also possible to perform face recognition by judging whether the face image identifiers are consistent. When the judgment result is that the face image identifiers are consistent, the face recognition is successful; when the judgment result is all When the face image identification is inconsistent, the face recognition fails. Performing face recognition through the face image identification can improve the efficiency of face recognition.
  • multiple target testers can be contacted, so that each target tester is facing the first camera device located in the center, and the target tester is photographed simultaneously through the first, second and third camera devices, namely Face images of different shooting angles can be obtained.
  • the multiple face images of multiple target testers captured by the first camera device are used as the first sample database corresponding to the first camera device; the multiple face images of multiple target testers captured by the second camera device One face image is used as the second sample database corresponding to the second camera; the multiple face images of multiple target testers captured by the third camera are taken as the third camera corresponding to the third camera.
  • Sample database In this way, it is possible to establish a sample database corresponding to the camera devices at a plurality of preset positions, and the shooting angle of the face image in each sample database corresponds to the shooting angle of the camera device.
  • S102 Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera.
  • the method further includes: photographing each camera device
  • the face image to be tested is preprocessed, and the preprocessing includes one or more of the following: image denoising processing; light normalization processing; posture calibration processing; gray-scale normalization processing. It is understandable that, after acquiring multiple face images of the face to be measured that are simultaneously captured by each camera device, preprocessing the face image to be measured can further improve the face of the face to be measured. The sharpness of the image facilitates the extraction of more discriminative facial features.
  • S103 Recognize the shooting angle of the face image to be tested according to the pre-trained face angle recognition model.
  • the shooting angle of the face image to be tested is recognized according to a pre-trained face angle recognition model.
  • the recognizing the shooting angle of the face image to be tested includes: acquiring the face image to be tested taken by the first camera; inputting the face image to be tested into a pre-trained face angle recognition model; Confirm the shooting angle of the face to be detected through the pre-trained face angle recognition model.
  • the pre-trained face angle recognition model is a model pre-trained by a terminal user for recognizing the shooting angle of a face image.
  • the training process of the face angle recognition model includes: acquiring a face image data set, the face image data set including a plurality of people's face images of different shooting angles; Divide to obtain a training set and a test set; input the face images in the training set into a preset neural network model for training to obtain a face angle recognition model; input the face images in the test set to the The face angle recognition model is tested to obtain a test pass rate; when the test pass rate is greater than or equal to the preset pass rate threshold, the training of the face angle recognition model ends; if the test pass rate is less than the When the pass rate threshold is preset, the number of face images in the training set is increased, and the face angle recognition model is retrained.
  • the preset pass rate threshold is preset by the terminal user according to an empirical value.
  • S104 Calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera.
  • the shooting angle of each camera device is known, and the difference between the shooting angle of the face image to be measured and the shooting angle of each camera device is obtained by calculation. Angle difference.
  • the smallest angle difference is selected from the angle difference as the target angle difference. It can be understood that the target angle difference indicates the shooting angle of the face image to be measured It is the closest to the shooting angle of the corresponding camera device, so the face recognition effect will be the best.
  • S106 Determine the sample database of the camera device corresponding to the target angle difference as the target sample database.
  • the sample database of the camera device corresponding to the target angle difference is determined as the target sample database. It can be understood that the face image in the target sample database is the same as the target sample database. The shooting angle of the face image is the closest, so the face recognition effect will be the best.
  • S107 Identify, according to the face image in the target sample database, the face image to be measured taken by the camera device corresponding to the target angle difference.
  • the recognizing, according to the face image in the target sample database, the face image to be measured taken by the camera corresponding to the target angle difference includes: extracting the face to be measured The facial features of the image and the facial features of the facial image in the target sample database; calculating the similarity between the facial features of the facial image to be tested and the facial features of the facial image in the target sample database; Determine whether the similarity is greater than or equal to the preset similarity threshold; if the judgment result is that the similarity is greater than or equal to the preset similarity threshold, output the face image corresponding to the similarity in the sample database as the result Describe the face recognition result of the face image to be tested.
  • the shooting angle of the corresponding face image in the target sample database is consistent with the shooting angle of the face image to be tested.
  • the preset similarity threshold can be flexibly set according to specific application scenarios, for example, a simulation can be performed with facial image features corresponding to multiple photos, and finally a threshold is determined as the preset similarity threshold.
  • the method further includes: identifying, according to the first sample database, the to-be-photographed by the first camera The first candidate face image of the face image to be tested; the second candidate face image of the face image to be tested taken by the second camera device is identified according to the second sample database; according to the third The sample database identifies the third candidate face image of the face image to be tested taken by the third-channel camera device; determines the first candidate face image, the second candidate face image, and the first candidate face image Whether the three candidate face images are the same person's face image; if the judgment result is that the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face Image, the first candidate face image is output as the final face recognition result.
  • the method further includes: respectively acquiring the face image identifiers corresponding to the first candidate face image, the second candidate face image, and the third candidate face image; and judging the first candidate face image; Whether the face image identification of a candidate face image, the face image identification of the second candidate face image, and the face image identification of the third candidate face image are the same; if the judgment result is the face image If the identifiers are the same, the first candidate face image corresponding to the facial image identifier is output as the final facial recognition result.
  • the number of the first candidate face image, the second candidate face image, and the third candidate face image may be one or more.
  • the number of the first candidate face image, the second candidate face image, and the third candidate face image is one and the face image of the same person, output the first candidate face The image is used as the final face recognition image.
  • the number of the first candidate's face image, the second candidate's face image, and the third candidate's face image is one and not the same person's face image, it means that each camera is taken If the received face image and the face image in the corresponding target sample database are not the same as the result of face recognition, the final face recognition fails; when the first candidate face image, the second candidate face image and When the number of the third candidate face images has the same face images but the number is not unique, acquiring the similarity between the face features corresponding to each same candidate face image and the face features in the target sample database, The three similarity values are summed to obtain the similarity and value of each identical candidate face image; the candidate face image with the highest similarity and value is output as the final face recognition result.
  • the embodiment of the present application provides a face recognition method based on multi-channel camera.
  • a sample database is established for each camera device in the preset multi-channel camera device.
  • the shooting angle of the face image in the sample database and the corresponding The shooting angles of the camera devices are the same; acquiring multiple face images to be tested of the face to be tested taken by each camera at the same time; identifying the face image of the face to be tested according to a pre-trained face angle recognition model Shooting angle; calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera; selecting the smallest angle difference from the angle difference as the target angle difference Determine the sample database of the camera device corresponding to the target angle difference as the target sample database; identify the person to be tested taken by the camera device corresponding to the target angle difference according to the face image in the target sample database Face image.
  • a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device.
  • face recognition for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be detected is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
  • An embodiment of the present application also provides a terminal 1, including a memory 10, a processor 30, and a computer program stored in the memory 10 and capable of running on the processor 30.
  • the processor 30 implements any of the foregoing when the program is executed. The steps of the face recognition method based on multi-channel camera described in the implementation mode.
  • FIG. 2 is a schematic structural diagram of a terminal 1 according to an embodiment of the present application.
  • the terminal 1 includes a memory 10 in which a face recognition device 100 based on multi-channel photography is stored.
  • the terminal 1 may be a terminal 1 with application display function, such as a mobile phone, a tablet computer, or a personal digital assistant.
  • the face recognition device 100 based on multi-channel camera can establish a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database corresponds to the corresponding camera device.
  • the shooting angles are the same; acquiring multiple face images to be measured of the face to be measured that are shot simultaneously by each camera device; identifying the shooting angle of the face image to be measured according to a pre-trained face angle recognition model; calculate The angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device; the smallest angle difference is selected from the angle difference as the target angle difference;
  • the sample database of the camera device of the target angle difference is determined as the target sample database; the face image to be measured taken by the camera device corresponding to the target angle difference is identified according to the face image in the target sample database.
  • a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device.
  • face recognition for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be detected is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
  • the terminal 1 may further include a display screen 20 and a processor 30.
  • the memory 10 and the display screen 20 may be electrically connected to the processor 30 respectively.
  • the memory 10 may be different types of storage devices for storing various types of data.
  • it can be the memory or internal memory of the terminal 1, or a memory card that can be externally connected to the terminal 1, such as flash memory, SM card (Smart Media Card), SD card (Secure Digital Card, secure digital card) Wait.
  • the memory 10 may include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a Secure Digital (SD) card, a flash memory card (Flash Card), At least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device.
  • the memory 10 is used to store various types of data.
  • the memory 10 can store various types of applications installed in the terminal 1, and the memory 10 can also store applications based on the multi-channel camera. Information such as data obtained by face recognition methods.
  • the display screen 20 is installed in the terminal 1 for displaying information.
  • the processor 30 is configured to execute the face recognition method based on multi-channel cameras and various software installed in the terminal 1, such as an operating system and application display software.
  • the processor 30 includes, but is not limited to, a processor (Central Processing Unit, CPU), a Micro Controller Unit (Micro Controller Unit, MCU) and other devices for interpreting computers and processing data in computer software.
  • a processor Central Processing Unit, CPU
  • MCU Micro Controller Unit
  • the multi-channel camera-based face recognition device 100 may include one or more modules, and the one or more modules are stored in the memory 10 of the terminal 1 and configured to be composed of one or more processors ( This embodiment is executed by a processor 30) to complete the embodiment of the present application.
  • the face recognition device 100 based on multi-channel cameras may include a sample database establishment module 101, a face image acquisition module 103, a shooting angle recognition module 105, an angle difference calculation module 107, and a target difference
  • the module referred to in the embodiment of the present application may be a program segment that completes a specific function, and is more suitable for describing the execution process of software in the processor 30 than a program.
  • the terminal 1 may include some or all of the functional modules shown in FIG. 3, and the functions of each module will be described in detail below . It should be noted that the same noun related terms and specific explanations in the above embodiments of the face recognition method based on multi-channel camera can also be applied to the following functional introduction of each module. To save space and avoid repetition, I won’t repeat them here.
  • the sample database establishment module 101 may be used to establish a sample database corresponding to each camera device in the preset multi-channel camera device, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device.
  • the face image acquisition module 103 may be used to acquire multiple faces to be measured in the face images to be measured that are simultaneously captured by each camera.
  • the shooting angle recognition module 105 may be used to recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model.
  • the angle difference calculation module 107 may be used to calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device.
  • the target difference value determining module 109 may be used to filter the smallest angle difference value from the angle difference values as the target angle difference value.
  • the sample database determining module 111 may be used to determine the sample database of the camera device corresponding to the target angle difference as the target sample database.
  • the face recognition module 113 may be configured to recognize, according to the face images in the target sample database, the face images to be measured taken by the camera device corresponding to the target angle difference.
  • the embodiments of the present application also provide a non-volatile readable storage medium, on which computer-readable instructions are stored, and when the computer-readable instructions are executed by the processor 30, the multi-channel camera-based system in any of the above embodiments is implemented The steps of the face recognition method.
  • the multi-channel camera-based face recognition device 100/terminal 1/computer equipment integrated module/unit is realized in the form of a software functional unit and sold or used as an independent product, it can be stored in a non-volatile memory. Read the storage medium.
  • this application implements all or part of the processes in the above-mentioned implementation methods, and can also be completed by instructing relevant hardware by a computer program, which can be stored in a non-volatile readable storage medium
  • the computer program is executed by the processor 30, the steps of the foregoing method embodiments can be implemented.
  • the computer program includes computer-readable instructions, and the computer-readable instructions may be in the form of source code, object code, executable files, or some intermediate forms.
  • a sample database is established for each of the preset multi-channel camera devices, and the photographing angle of the face image in the sample database is corresponding to the The shooting angles of the camera devices are the same; obtain multiple face images to be tested of the face to be tested that are simultaneously shot by each camera device; identify the shooting of the face images to be tested according to the pre-trained face angle recognition model Angle; calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device; selecting the smallest angle difference from the angle difference as the target angle difference; The sample database of the camera device corresponding to the target angle difference is determined as the target sample database; the face to be measured captured by the camera device corresponding to the target angle difference is identified according to the face image in the target sample database image.
  • the non-volatile readable storage medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM,
  • the so-called processor 30 may be a central processing unit (Central Processing Unit, CPU), other general processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Ready-made programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • the general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc.
  • the processor 30 is the control center of the multi-channel camera-based face recognition device 100/terminal 1, and uses various The interfaces and lines connect various parts of the entire face recognition device 100/terminal 1 based on multi-channel camera.
  • the memory 10 is used to store the computer program and/or module, and the processor 30 executes or executes the computer program and/or module stored in the memory and calls the data stored in the memory 10 to implement Various functions of the face recognition device 100/terminal 1 based on multi-channel camera.
  • the memory 10 may mainly include a storage program area and a storage data area.
  • the storage program area may store an operating system, an application program required by at least one function (such as a sound playback function, an image playback function, etc.), etc.; the storage data area may Store data (such as audio data, etc.) created according to the use of the terminal.

Abstract

A face recognition method based on multiple cameras, comprising: establishing a sample database for each camera; obtaining a face image to be detected photographed by each camera and recognizing a photographing angle of said face image; calculating an angle difference between the photographing angle of said face image and the photographing angle of each camera; screening out the minimum angle difference to serve as a target angle difference; determining the sample database of the camera corresponding to the target angle difference as a target sample database; and recognizing said face image photographed by the camera corresponding to the target angle difference according to the face image in the target sample database. The present application further provides a face recognition apparatus based on multiple cameras, a terminal and a storage medium. According to the present application, when face recognition is carried out, said face image obtained by each camera is only compared with the face image in the corresponding target sample database, the face recognition accuracy is improved, and the face recognition rate is improved.

Description

基于多路摄像的人脸识别方法、装置、终端及存储介质Face recognition method, device, terminal and storage medium based on multi-channel camera
本申请要求于2019年06月11日提交中国专利局,申请号为201910502775.1发明名称为“基于多路摄像的人脸识别方法、装置、终端及存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed with the Chinese Patent Office on June 11, 2019. The application number is 201910502775.1. The invention title is "Multi-channel camera-based face recognition method, device, terminal and storage medium". The content is incorporated in this application by reference.
技术领域Technical field
本申请涉及图像识别技术领域,具体涉及一种基于多路摄像的人脸识别方法、基于多路摄像的人脸识别装置、终端与存储介质。This application relates to the field of image recognition technology, and in particular to a face recognition method based on multiple cameras, a face recognition device based on multiple cameras, a terminal and a storage medium.
背景技术Background technique
随着图像处理技术的发展与进步,人脸识别技术作为一种高端、可靠的身份检测手段,在现代生产生活的应用中,极大地提高了用户的使用体验,因而可以广泛使用在出入管理、监控管理、电脑安全防范、照片搜索、ATM机智能视频报警、铁路安检识别等应用中。With the development and progress of image processing technology, face recognition technology, as a high-end and reliable means of identity detection, has greatly improved the user experience in modern production and life applications, so it can be widely used in access management, Monitoring management, computer security protection, photo search, ATM machine intelligent video alarm, railway security inspection and identification and other applications.
现有技术中,在进行人脸识别时,一般均使用多路摄像装置对待识别的人脸进行图像的拍摄,然后经过一系列的图像预处理和图像识别处理,对拍摄图像中的人脸进行识别,得到待识别人脸的身份识别结果。发明人发现目前一般的做法是所有的摄像装置共享同一个样本数据库,但是每个摄像装置的摆放位置、所处环境、拍摄到人脸的角度都可能不同,就造成了在同一个样本数据库上的适应性不同。比如拍摄角度,对于样本数据库中人脸图像均为正脸图像的样本数据库来说,则拍摄角度为正脸的摄像装置抓拍的人脸图像对应的人脸识别效果就好,否则就会变差。In the prior art, when performing face recognition, a multi-channel camera device is generally used to capture the image of the face to be recognized, and then through a series of image preprocessing and image recognition processing, the face in the captured image is processed Recognition, obtain the identity recognition result of the face to be recognized. The inventor found that the current general practice is that all camera devices share the same sample database, but the placement of each camera device, the environment, and the angle at which the face is captured may be different, resulting in the same sample database. The adaptability is different. For example, the shooting angle, for a sample database where the face images in the sample database are all frontal images, the face recognition effect corresponding to the face image captured by the camera device with the frontal shooting angle is good, otherwise it will be worse. .
发明内容Summary of the invention
鉴于以上内容,有必要提出一种基于多路摄像的人脸识别方法、基于多路摄像的人脸识别装置、终端与存储介质,能够在进行人脸识别时,每一路摄像装置获取的待测人脸图像只与对应的目标样本数据库中的人脸图像进行比对,提高人脸识别的准确性,并提高人脸识别速率。In view of the above, it is necessary to propose a face recognition method based on multiple cameras, a face recognition device based on multiple cameras, a terminal and a storage medium. When performing face recognition, each camera obtains the under-test The face image is only compared with the face image in the corresponding target sample database to improve the accuracy of face recognition and increase the rate of face recognition.
本申请实施例第一方面提供一种基于多路摄像的人脸识别方法,所述基于多路摄像的人脸识别方法包括:The first aspect of the embodiments of the present application provides a face recognition method based on multi-channel camera. The face recognition method based on multi-channel camera includes:
为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;Establishing a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database is the same as the shooting angle of the corresponding camera device;
获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera device;
根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;Identifying the shooting angle of the face image to be tested according to the pre-trained face angle recognition model;
计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;Calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
从所述角度差值中筛选出最小的角度差值作为目标角度差值;The smallest angle difference is selected from the angle difference as the target angle difference;
将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;Determining the sample database of the camera device corresponding to the target angle difference as the target sample database;
根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。Identify the face image to be measured taken by the camera device corresponding to the target angle difference according to the face image in the target sample database.
本申请实施例第二方面还提供一种基于多路摄像的人脸识别装置,所述基于多路摄像的人脸识别装置包括:The second aspect of the embodiments of the present application also provides a face recognition device based on multi-channel camera, the face recognition device based on multi-channel camera includes:
样本数据库建立模块,用于为预设多路摄像装置中的每一路摄像装置对应建立样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;A sample database establishment module for establishing a sample database corresponding to each camera device in the preset multi-channel camera device, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device;
人脸图像获取模块,用于获取每一路摄像装置同时进行拍摄的待测人脸图像的多个待测人脸;The face image acquisition module is used to acquire multiple faces to be measured in the face images to be measured taken by each camera at the same time;
拍摄角度识别模块,用于根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;A shooting angle recognition module, configured to recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model;
角度差值计算模块,用于计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;An angle difference calculation module, configured to calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
目标差值确定模块,用于从所述角度差值中筛选出最小的角度差值作为目标角度差值;The target difference determination module is configured to filter out the smallest angle difference from the angle difference as the target angle difference;
样本数据库确定模块,用于将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;A sample database determining module, configured to determine the sample database of the camera device corresponding to the target angle difference as the target sample database;
人脸识别模块,用于根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。The face recognition module is configured to recognize, according to the face image in the target sample database, the face image to be measured taken by the camera device corresponding to the target angle difference.
本申请实施例第三方面还提供一种终端,所述终端包括处理器,所述处理器用于执行存储器中存储的计算机可读指令时实现上述任意一项所述的基于多路摄像的人脸识别方法。The third aspect of the embodiments of the present application further provides a terminal, the terminal includes a processor, and the processor is configured to implement the multi-channel camera-based face of any one of the above when executing computer-readable instructions stored in the memory. recognition methods.
本申请实施例第四方面还提供一种非易失性可读存储介质,所述非易失性可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现上述任意一项所述的基于多路摄像的人脸识别方法。The fourth aspect of the embodiments of the present application also provides a non-volatile readable storage medium having computer readable instructions stored on the non-volatile readable storage medium, and the computer readable instructions are implemented when executed by a processor The face recognition method based on multi-channel camera described in any one of the above.
本申请实施例提供一种基于多路摄像的人脸识别方法、基于多路摄像的人脸识别装置、终端与非易失性可读存储介质,为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;从所述角度差值中筛选出最小的角度差值作为目标角度差值;将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。利用本申请实施例,对于多路摄像装置的每一路摄像设置都建立一个样本数据库,所述样本数据库中存放的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同。在进行人脸识别时,对于拍摄的待测人脸图像,选择与其拍摄角度最接近的样本数据库中人脸图像进行对比,使得待测的人脸图像与其拍摄角度以及所处环境最接近的样本进行人脸比对,从而提高人脸识别的准确性,并提高人脸识别速率。The embodiment of the application provides a face recognition method based on multiple cameras, a face recognition device based on multiple cameras, a terminal, and a non-volatile readable storage medium, which are preset for each camera in the multiple camera The device establishes a sample database, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device; acquiring a plurality of faces to be measured of the faces to be measured that are simultaneously photographed by each camera Image; recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model; calculate the angle difference between the shooting angle of the face image to be tested and the shooting angle of each camera The smallest angle difference is selected from the angle difference as the target angle difference; the sample database of the camera device corresponding to the target angle difference is determined as the target sample database; according to the target sample database The face image recognizes the face image to be measured taken by the camera device corresponding to the target angle difference. Using the embodiment of the present application, a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device. When performing face recognition, for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be tested is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
附图说明Description of the drawings
图1是本申请一实施方式提供的基于多路摄像的人脸识别方法的流程图。FIG. 1 is a flowchart of a face recognition method based on multi-channel camera provided by an embodiment of the present application.
图2是本申请一实施方式的终端的结构示意图。FIG. 2 is a schematic structural diagram of a terminal according to an embodiment of the present application.
图3是图2所示的终端的示例性的功能模块图。Fig. 3 is an exemplary functional block diagram of the terminal shown in Fig. 2.
如下具体实施方式将结合上述附图进一步说明本申请实施例。The following specific implementations will further illustrate the embodiments of the present application in conjunction with the above-mentioned drawings.
具体实施方式Detailed ways
图1是本申请第一实施方式的基于多路摄像的人脸识别方法的流程图,所述基于多路摄像的人脸识别方法可以应用于终端1,所述终端1可以是例如智能手机、笔记本电脑、台式/平板电脑、智能手表以及个人数字助理(Personal Digital Assistant,PDA)等智能设备。如图1所示,所述基于多路摄像的人脸识别方法可以包括如下步骤:FIG. 1 is a flowchart of a face recognition method based on multiple cameras in the first embodiment of the present application. The face recognition method based on multiple cameras can be applied to a terminal 1, and the terminal 1 may be, for example, a smart phone, Smart devices such as notebook computers, desktop/tablet computers, smart watches, and personal digital assistants (PDAs). As shown in Fig. 1, the face recognition method based on multi-channel camera may include the following steps:
S101:为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同。S101: Establish a sample database for each of the preset multi-channel camera devices, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device.
在本申请的至少一实施例中,预设多路摄像装置为预先设置在多个拍摄位置摄像装置。由于拍摄位置不同,对应的所述摄像装置的角度不同,拍摄到的人脸图像的角度也不同。所述摄像装置可以是摄像头、数码照相机、数字照相机中的一种或者多种。此处对所述摄像装置的个数不做限定,所述摄像装置的个数可以根据实际拍摄角度需要进行设置。以所述摄像装置的个数为3个为例,所述预设多路摄像装置包括共中心设置的第一路摄像装置、第二路摄像装置与第三路摄像装置。In at least one embodiment of the present application, the preset multi-channel camera device is a camera device preset at multiple shooting positions. Due to the different shooting positions, the corresponding camera devices have different angles, and the angles of the captured face images are also different. The camera device may be one or more of a camera, a digital camera, and a digital camera. The number of the camera devices is not limited here, and the number of the camera devices can be set according to the actual shooting angle. Taking the number of the camera devices as three as an example, the preset multi-channel camera device includes a first camera device, a second camera device, and a third camera device arranged in a common center.
需要说明的是,拍摄角度是相对而言的。例如,可以以位于正中心的第一路摄像装置所在的位置为0°,对应的所述第一路摄像装置拍摄的人脸图像的角度为0°;将所有位于所述第一路摄像装置右侧的第二路摄像装置所在的位置成为正的角度,对应的所述第二路摄像装置拍摄的人脸图像的角度为正;将所有位于所述第一路摄像装置左侧的第三路摄像装置所在的位置成为负的角度,对应的所述第三路摄像装置拍摄的人脸图像的角度为负。It should be noted that the shooting angle is relative. For example, it is possible to set the position of the first camera device located in the center as 0°, and the angle of the face image captured by the corresponding first camera device is 0°; The position of the second camera on the right becomes a positive angle, and the angle of the face image taken by the corresponding second camera is positive; all the third cameras located on the left of the first camera The position of the road camera device becomes a negative angle, and the corresponding angle of the face image taken by the third road camera device is negative.
示例性的,假设实现以所述中心为圆心点,设置三个不同的位置,分别为第一位置、第二位置及第三位置。其中,第一位置为0°,且第一位置处装设有第一路摄像装置;第二位置为+90°,且第二位置处装设有第二摄像;第三位置为-90°,且第三位置处装设有第三路摄像装置。那么,所述第一路摄像装置拍摄的人脸角度为0°,此角度下拍摄的人脸为正脸;第二路摄像装置拍摄的人脸角度为+90°,此角度下拍摄的人脸为右脸;第三路摄像装置拍摄的人脸角度为-90°,此角度下拍摄的人脸为左脸。然后,分别设置一个关于左脸/正脸/右脸的独立样本数据库,左脸/正脸/右脸的独立样本数据库中用于对应存放不同用户的左脸/正脸/右脸样本照片。Exemplarily, assuming that the center is used as the center point, three different positions are set, namely the first position, the second position, and the third position. Among them, the first position is 0°, and the first position is installed with the first camera; the second position is +90°, and the second position is installed with the second camera; the third position is -90° , And a third camera is installed at the third position. Then, the angle of the face taken by the first camera is 0°, and the face taken at this angle is a front face; the angle of the face taken by the second camera is +90°, and the person taken at this angle The face is the right face; the face angle taken by the third camera device is -90°, and the face taken at this angle is the left face. Then, an independent sample database of left face/front face/right face is set up, and the independent sample database of left face/front face/right face is used to store the left face/front face/right face sample photos of different users.
所述为预设多路摄像装置中的每一路摄像装置建立一个样本数据库包括:以所述中心为圆心点,设置所述第一路摄像装置的拍摄角度为0°,设置所述第二路摄像装置的拍摄角度为+90°,设置所述第三路摄像装置的拍摄角度为-90°;控制所述第一路摄像装置、所述第二路摄像装置与所述第三路摄像装置同时拍摄预设数量的目标测试者中的每一个所述目标测试者,得到不同拍摄角度的人脸图像;将所述第一路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第一路摄像装置的第一样本数据库,将所述第二路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第二路摄像装置的第二样本数据库,将所述第三路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第三路摄像装置的第三样本数据库。其中,所述预设数量为预先设置的,需要采集人脸图像的目标测试者的个数。The establishing a sample database for each camera device in the preset multi-channel camera device includes: taking the center as the center point, setting the shooting angle of the first camera device to 0°, and setting the second camera device The shooting angle of the camera device is +90°, and the shooting angle of the third camera device is set to -90°; the first camera device, the second camera device, and the third camera device are controlled Simultaneously photograph a preset number of target testers for each of the target testers to obtain face images of different shooting angles; take the preset number of faces of the target testers captured by the first camera The image is used as the first sample database of the first camera, and the preset number of face images of the target tester captured by the second camera are used as the second The sample database uses the preset number of face images of the target tester captured by the third camera device as the third sample database of the third camera device. Wherein, the preset number is preset, and the number of target testers who need to collect face images.
可以理解的是,所述第一样本数据库、所述第二样本数据库以及所述第三样本数据库中除了保存有预设数量的目标测试者的人脸图像外,样本数据库中还包括人脸图像标识,同一个目标测试者的人脸图像标识是唯一的,所述人脸图像标识用于标识对应测试者的身份信息。因而,在一实施方式中,还可以通过判断所 述人脸图像标识是否一致来进行人脸识别,当判断结果为所述人脸图像标识一致时,则人脸识别成功;当判断结果为所述人脸图像标识不一致时,则人脸识别失败。通过所述人脸图像标识来进行人脸识别能够提高人脸识别效率。It is understandable that, in addition to storing a preset number of face images of the target tester in the first sample database, the second sample database, and the third sample database, the sample database also includes human faces. Image identification, the face image identification of the same target tester is unique, and the face image identification is used to identify the identity information of the corresponding tester. Therefore, in one embodiment, it is also possible to perform face recognition by judging whether the face image identifiers are consistent. When the judgment result is that the face image identifiers are consistent, the face recognition is successful; when the judgment result is all When the face image identification is inconsistent, the face recognition fails. Performing face recognition through the face image identification can improve the efficiency of face recognition.
具体地,可以实现联系多个目标测试者,让每一个目标测试者正对着位于正中心的第一路摄像装置,通过第一、第二及第三路摄像装置同时拍摄目标测试者,即可得到不同拍摄角度的人脸图像。将第一路摄像装置拍摄的多个目标测试者的多张人脸图像作为对应所述第一路摄像装置的第一样本数据库;将第二路摄像装置拍摄的多个目标测试者的多张人脸图像作为对应所述第二路摄像装置的第二样本数据库;将第三路摄像装置拍摄的多个目标测试者的多张人脸图像作为对应所述第三路摄像装置的第三样本数据库。如此,便可以为预设多个位置处的摄像装置分别对应建立一个样本数据库,每一个样本数据库中的人脸图像的拍摄角度对应所述摄像装置的拍摄角度。Specifically, multiple target testers can be contacted, so that each target tester is facing the first camera device located in the center, and the target tester is photographed simultaneously through the first, second and third camera devices, namely Face images of different shooting angles can be obtained. The multiple face images of multiple target testers captured by the first camera device are used as the first sample database corresponding to the first camera device; the multiple face images of multiple target testers captured by the second camera device One face image is used as the second sample database corresponding to the second camera; the multiple face images of multiple target testers captured by the third camera are taken as the third camera corresponding to the third camera. Sample database. In this way, it is possible to establish a sample database corresponding to the camera devices at a plurality of preset positions, and the shooting angle of the face image in each sample database corresponds to the shooting angle of the camera device.
S102:获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像。S102: Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera.
在本申请的至少一实施例中,在所述获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像之后,所述方法还包括:对所述每一路摄像装置拍摄的待测人脸图像进行预处理,所述预处理包括以下中的一种或多种:图像去噪处理;光照归一化处理;姿态校准处理;灰度归一化处理。可以理解的是,在所述获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像之后,对所述待测人脸图像进行预处理,能够进一步提高待测人脸图像的清晰度,便于提取出更具辨别力的人脸特征。In at least one embodiment of the present application, after the acquiring multiple face images of the face to be measured that are simultaneously captured by each camera device, the method further includes: photographing each camera device The face image to be tested is preprocessed, and the preprocessing includes one or more of the following: image denoising processing; light normalization processing; posture calibration processing; gray-scale normalization processing. It is understandable that, after acquiring multiple face images of the face to be measured that are simultaneously captured by each camera device, preprocessing the face image to be measured can further improve the face of the face to be measured. The sharpness of the image facilitates the extraction of more discriminative facial features.
S103:根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度。S103: Recognize the shooting angle of the face image to be tested according to the pre-trained face angle recognition model.
在本申请的至少一实施例中,对于拍摄到的待测人脸图像,根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度。所述识别所述待测人脸图像的拍摄角度包括:获取第一路摄像装置拍摄的待测人脸图像;将所述待测人脸图像输入至预先训练好的人脸角度识别模型中;通过所述预先训练好的人脸角度识别模型确认所述待检测人脸的拍摄角度。所述预先训练好的人脸角度识别模型为终端用户预先训练好的,用于识别人脸图像拍摄角度的模型。In at least one embodiment of the present application, for the captured face image to be tested, the shooting angle of the face image to be tested is recognized according to a pre-trained face angle recognition model. The recognizing the shooting angle of the face image to be tested includes: acquiring the face image to be tested taken by the first camera; inputting the face image to be tested into a pre-trained face angle recognition model; Confirm the shooting angle of the face to be detected through the pre-trained face angle recognition model. The pre-trained face angle recognition model is a model pre-trained by a terminal user for recognizing the shooting angle of a face image.
具体地,所述人脸角度识别模型的训练过程包括:获取人脸图像数据集,所述人脸图像数据集中包括多个人的不同拍摄角度的人脸图像;对所述人脸图像数据集进行划分,得到训练集和测试集;将所述训练集中的人脸图像输入预先设置好的神经网络模型中进行训练,得到人脸角度识别模型;将所述测试集中的人脸图像输入至所述人脸角度识别模型中进行测试,获得测试通过率;当所述测试通过率大于或者等于预设通过率阈值时,结束所述人脸角度识别模型的训练;若所述测试通过率小于所述预设通过率阈值时,增加所述训练集中的人脸图像的数量,重新进行人脸角度识别模型的训练。其中,所述预设通过率阈值为终端用户根据经验值预先设置的。Specifically, the training process of the face angle recognition model includes: acquiring a face image data set, the face image data set including a plurality of people's face images of different shooting angles; Divide to obtain a training set and a test set; input the face images in the training set into a preset neural network model for training to obtain a face angle recognition model; input the face images in the test set to the The face angle recognition model is tested to obtain a test pass rate; when the test pass rate is greater than or equal to the preset pass rate threshold, the training of the face angle recognition model ends; if the test pass rate is less than the When the pass rate threshold is preset, the number of face images in the training set is increased, and the face angle recognition model is retrained. Wherein, the preset pass rate threshold is preset by the terminal user according to an empirical value.
S104:计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值。S104: Calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera.
在本申请的至少一实施例中,所述每一路摄像装置的拍摄角度为已知的,通过计算得到所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值。In at least one embodiment of the present application, the shooting angle of each camera device is known, and the difference between the shooting angle of the face image to be measured and the shooting angle of each camera device is obtained by calculation. Angle difference.
S105:从所述角度差值中筛选出最小的角度差值作为目标角度差值。S105: Screen the smallest angle difference from the angle difference as the target angle difference.
在本申请的至少一实施例中,从所述角度差值中筛选出最小的角度差值作为 目标角度差值,可以理解的是,所述目标角度差值表明待测人脸图像的拍摄角度与对应所述摄像装置的拍摄角度最接近,从而人脸识别效果会最佳。In at least one embodiment of the present application, the smallest angle difference is selected from the angle difference as the target angle difference. It can be understood that the target angle difference indicates the shooting angle of the face image to be measured It is the closest to the shooting angle of the corresponding camera device, so the face recognition effect will be the best.
S106:将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库。S106: Determine the sample database of the camera device corresponding to the target angle difference as the target sample database.
在本申请的至少一实施例中,将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库,可以理解的是,所述目标样本数据库中的人脸图像与所述待测人脸图像的拍摄角度最接近,因而人脸识别效果会最佳。In at least one embodiment of the present application, the sample database of the camera device corresponding to the target angle difference is determined as the target sample database. It can be understood that the face image in the target sample database is the same as the target sample database. The shooting angle of the face image is the closest, so the face recognition effect will be the best.
S107:根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。S107: Identify, according to the face image in the target sample database, the face image to be measured taken by the camera device corresponding to the target angle difference.
在本申请的至少一实施例中,所述根据所述目标样本数据库中的人脸图像识别对应所述目标角度差值的摄像装置拍摄的待测人脸图像包括:提取所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征;计算所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征的相似度;判断所述相似度是否大于或等于预设相似度阈值;若判断结果为所述相似度大于或等于预设相似度阈值,则输出所述样本数据库中对应所述相似度的人脸图像作为所述待测人脸图像的人脸识别结果。所述目标样本数据库中对应的人脸图像的拍摄角度与所述待测人脸图像的拍摄角度一致。所述预设相似度阈值可以根据具体的应用场景灵活设置,例如可以同多个照片对应的人脸图像特征进行模拟仿真,最后确定一个阈值作为预设相似度阈值。In at least one embodiment of the present application, the recognizing, according to the face image in the target sample database, the face image to be measured taken by the camera corresponding to the target angle difference includes: extracting the face to be measured The facial features of the image and the facial features of the facial image in the target sample database; calculating the similarity between the facial features of the facial image to be tested and the facial features of the facial image in the target sample database; Determine whether the similarity is greater than or equal to the preset similarity threshold; if the judgment result is that the similarity is greater than or equal to the preset similarity threshold, output the face image corresponding to the similarity in the sample database as the result Describe the face recognition result of the face image to be tested. The shooting angle of the corresponding face image in the target sample database is consistent with the shooting angle of the face image to be tested. The preset similarity threshold can be flexibly set according to specific application scenarios, for example, a simulation can be performed with facial image features corresponding to multiple photos, and finally a threshold is determined as the preset similarity threshold.
对于多路摄像装置,每一路摄像装置进行人脸识别时,其对应的人脸识别结果可能会存在多个候选对象,因而需要对多路摄像装置对应的候选对象进行综合分析,从而得到人脸识别结果。For multi-channel camera devices, when each camera device performs face recognition, there may be multiple candidate objects in its corresponding face recognition result. Therefore, it is necessary to comprehensively analyze the candidate objects corresponding to the multi-channel camera device to obtain the face Recognition results.
在一实施方式中,当判断所述相似度小于所述预设相似度阈值时,所述方法还包括:根据所述第一样本数据库识别出所述第一路摄像装置拍摄的所述待测人脸图像的第一候选人脸图像;根据所述第二样本数据库识别出所述第二路摄像装置拍摄的所述待测人脸图像的第二候选人脸图像;根据所述第三样本数据库识别出所述第三路摄像装置拍摄的所述待测人脸图像的第三候选人脸图像;判断所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像是否为同一人的人脸图像;若判断结果为所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像为同一人的人脸图像,则输出所述第一候选人脸图像作为最终人脸识别结果。In one embodiment, when it is determined that the similarity is less than the preset similarity threshold, the method further includes: identifying, according to the first sample database, the to-be-photographed by the first camera The first candidate face image of the face image to be tested; the second candidate face image of the face image to be tested taken by the second camera device is identified according to the second sample database; according to the third The sample database identifies the third candidate face image of the face image to be tested taken by the third-channel camera device; determines the first candidate face image, the second candidate face image, and the first candidate face image Whether the three candidate face images are the same person's face image; if the judgment result is that the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face Image, the first candidate face image is output as the final face recognition result.
可以理解的是,所述方法还包括:分别获取所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像对应的人脸图像标识;判断所述第一候选人脸图像的人脸图像标识、所述第二候选人脸图像的人脸图像标识以及所述第三候选人脸图像的人脸图像标识是否相同;若判断结果为所述人脸图像标识相同,则输出人脸图像标识对应的第一候选人脸图像作为最终人脸识别结果。It is understandable that the method further includes: respectively acquiring the face image identifiers corresponding to the first candidate face image, the second candidate face image, and the third candidate face image; and judging the first candidate face image; Whether the face image identification of a candidate face image, the face image identification of the second candidate face image, and the face image identification of the third candidate face image are the same; if the judgment result is the face image If the identifiers are the same, the first candidate face image corresponding to the facial image identifier is output as the final facial recognition result.
在其他实施方式中,所述第一候选人脸图像、所述第二候选人脸图像与所述第三候选人脸图像的数量可以为一个,也可以为多个。当所述第一候选人脸图像、所述第二候选人脸图像与所述第三候选人脸图像的数量为一个且为同一人的人脸图像时,则输出所述第一候选人脸图像作为最终人脸识别图像。当所述第一候选人脸图像、所述第二候选人脸图像与所述第三候选人脸图像的数量为一个且不为同一人的人脸图像时,则表明对每一路摄像装置拍摄到的人脸图像与对应目标样本数据库中人脸图像进行人脸识别的结果均不相同,则最终人脸识别失败;当所述第一候选人脸图像、所述第二候选人脸图像与所述第三候选人脸图像的数量 存在相同的人脸图像但数量不唯一时获取每一相同的候选人脸图像对应的人脸特征与所述目标样本数据库中的人脸特征的相似度,将三个相似度的值进行求和,得到每一相同的候选人脸图像的相似度和值;输出相似度和值最高的候选人脸图像作为最终人脸识别结果。In other implementation manners, the number of the first candidate face image, the second candidate face image, and the third candidate face image may be one or more. When the number of the first candidate face image, the second candidate face image, and the third candidate face image is one and the face image of the same person, output the first candidate face The image is used as the final face recognition image. When the number of the first candidate's face image, the second candidate's face image, and the third candidate's face image is one and not the same person's face image, it means that each camera is taken If the received face image and the face image in the corresponding target sample database are not the same as the result of face recognition, the final face recognition fails; when the first candidate face image, the second candidate face image and When the number of the third candidate face images has the same face images but the number is not unique, acquiring the similarity between the face features corresponding to each same candidate face image and the face features in the target sample database, The three similarity values are summed to obtain the similarity and value of each identical candidate face image; the candidate face image with the highest similarity and value is output as the final face recognition result.
本申请实施例提供一种基于多路摄像的人脸识别方法,为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;从所述角度差值中筛选出最小的角度差值作为目标角度差值;将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。利用本申请实施例,对于多路摄像装置的每一路摄像设置都建立一个样本数据库,所述样本数据库中存放的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同。在进行人脸识别时,对于拍摄的待测人脸图像,选择与其拍摄角度最接近的样本数据库中人脸图像进行对比,使得待检测的人脸图像与其拍摄角度以及所处环境最接近的样本进行人脸比对,从而提高人脸识别的准确性,并提高人脸识别速率。The embodiment of the present application provides a face recognition method based on multi-channel camera. A sample database is established for each camera device in the preset multi-channel camera device. The shooting angle of the face image in the sample database and the corresponding The shooting angles of the camera devices are the same; acquiring multiple face images to be tested of the face to be tested taken by each camera at the same time; identifying the face image of the face to be tested according to a pre-trained face angle recognition model Shooting angle; calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera; selecting the smallest angle difference from the angle difference as the target angle difference Determine the sample database of the camera device corresponding to the target angle difference as the target sample database; identify the person to be tested taken by the camera device corresponding to the target angle difference according to the face image in the target sample database Face image. Using the embodiment of the present application, a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device. When performing face recognition, for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be detected is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
以上是对本申请实施例所提供的方法进行的详细描述。根据不同的需求,所示流程图中方块的执行顺序可以改变,某些方块可以省略。下面对本申请实施例所提供的终端1进行描述。The foregoing is a detailed description of the method provided by the embodiment of the present application. According to different requirements, the execution order of the blocks in the flowchart shown can be changed, and some blocks can be omitted. The following describes the terminal 1 provided in the embodiment of the present application.
本申请实施例还提供一种终端1,包括存储器10、处理器30及存储在存储器10上并可在处理器30上运行的计算机程序,所述处理器30执行所述程序时实现上述任一实施方式中所述的基于多路摄像的人脸识别方法的步骤。An embodiment of the present application also provides a terminal 1, including a memory 10, a processor 30, and a computer program stored in the memory 10 and capable of running on the processor 30. The processor 30 implements any of the foregoing when the program is executed. The steps of the face recognition method based on multi-channel camera described in the implementation mode.
图2是本申请一实施方式的终端1的结构示意图,如图2所示,终端1包括存储器10,存储器10中存储有基于多路摄像的人脸识别装置100。所述的终端1可以是手机、平板电脑、个人数字助理等具有应用显示功能的终端1。所述基于多路摄像的人脸识别装置100可以为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;从所述角度差值中筛选出最小的角度差值作为目标角度差值;将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。利用本申请实施例,对于多路摄像装置的每一路摄像设置都建立一个样本数据库,所述样本数据库中存放的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同。在进行人脸识别时,对于拍摄的待测人脸图像,选择与其拍摄角度最接近的样本数据库中人脸图像进行对比,使得待检测的人脸图像与其拍摄角度以及所处环境最接近的样本进行人脸比对,从而提高人脸识别的准确性,并提高人脸识别速率。FIG. 2 is a schematic structural diagram of a terminal 1 according to an embodiment of the present application. As shown in FIG. 2, the terminal 1 includes a memory 10 in which a face recognition device 100 based on multi-channel photography is stored. The terminal 1 may be a terminal 1 with application display function, such as a mobile phone, a tablet computer, or a personal digital assistant. The face recognition device 100 based on multi-channel camera can establish a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database corresponds to the corresponding camera device. The shooting angles are the same; acquiring multiple face images to be measured of the face to be measured that are shot simultaneously by each camera device; identifying the shooting angle of the face image to be measured according to a pre-trained face angle recognition model; calculate The angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device; the smallest angle difference is selected from the angle difference as the target angle difference; The sample database of the camera device of the target angle difference is determined as the target sample database; the face image to be measured taken by the camera device corresponding to the target angle difference is identified according to the face image in the target sample database. Using the embodiment of the present application, a sample database is established for each camera setting of the multi-channel camera device, and the shooting angle of the face image stored in the sample database is the same as the shooting angle of the corresponding camera device. When performing face recognition, for the captured face image to be tested, select the face image in the sample database that is closest to its shooting angle for comparison, so that the face image to be detected is the closest to its shooting angle and environment Perform face comparison to improve the accuracy of face recognition and increase the rate of face recognition.
本实施方式中,终端1还可以包括显示屏20及处理器30。存储器10、显示屏20可以分别与处理器30电连接。In this embodiment, the terminal 1 may further include a display screen 20 and a processor 30. The memory 10 and the display screen 20 may be electrically connected to the processor 30 respectively.
所述的存储器10可以是不同类型存储设备,用于存储各类数据。例如,可 以是终端1的存储器、内存,还可以是可外接于该终端1的存储卡,如闪存、SM卡(Smart Media Card,智能媒体卡)、SD卡(Secure Digital Card,安全数字卡)等。此外,存储器10可以包括非易失性存储器,例如硬盘、内存、插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)、至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。存储器10用于存储各类数据,例如,所述存储器10中可以存储有所述终端1中安装的各类应用程序(Applications),所述存储器10中还可以存储有应用上述基于多路摄像的人脸识别方法而获取的数据等信息。The memory 10 may be different types of storage devices for storing various types of data. For example, it can be the memory or internal memory of the terminal 1, or a memory card that can be externally connected to the terminal 1, such as flash memory, SM card (Smart Media Card), SD card (Secure Digital Card, secure digital card) Wait. In addition, the memory 10 may include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a Secure Digital (SD) card, a flash memory card (Flash Card), At least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. The memory 10 is used to store various types of data. For example, the memory 10 can store various types of applications installed in the terminal 1, and the memory 10 can also store applications based on the multi-channel camera. Information such as data obtained by face recognition methods.
显示屏20安装于终端1,用于显示信息。The display screen 20 is installed in the terminal 1 for displaying information.
处理器30用于执行所述基于多路摄像的人脸识别方法以及所述终端1内安装的各类软件,例如操作系统及应用显示软件等。处理器30包含但不限于处理器(Central Processing Unit,CPU)、微控制单元(Micro Controller Unit,MCU)等用于解释计算机以及处理计算机软件中的数据的装置。The processor 30 is configured to execute the face recognition method based on multi-channel cameras and various software installed in the terminal 1, such as an operating system and application display software. The processor 30 includes, but is not limited to, a processor (Central Processing Unit, CPU), a Micro Controller Unit (Micro Controller Unit, MCU) and other devices for interpreting computers and processing data in computer software.
所述的基于多路摄像的人脸识别装置100可以包括一个或多个的模块,所述一个或多个模块被存储在终端1的存储器10中并被配置成由一个或多个处理器(本实施方式为一个处理器30)执行,以完成本申请实施例。例如,参阅图3所示,所述基于多路摄像的人脸识别装置100可以包括样本数据库建立模块101、人脸图像获取模块103、拍摄角度识别模块105、角度差值计算模块107、目标差值确定模块109、样本数据库确定模块111与人脸识别模块113。本申请实施例所称的模块可以是完成一特定功能的程序段,比程序更适合于描述软件在处理器30中的执行过程。The multi-channel camera-based face recognition device 100 may include one or more modules, and the one or more modules are stored in the memory 10 of the terminal 1 and configured to be composed of one or more processors ( This embodiment is executed by a processor 30) to complete the embodiment of the present application. For example, referring to FIG. 3, the face recognition device 100 based on multi-channel cameras may include a sample database establishment module 101, a face image acquisition module 103, a shooting angle recognition module 105, an angle difference calculation module 107, and a target difference The value determination module 109, the sample database determination module 111, and the face recognition module 113. The module referred to in the embodiment of the present application may be a program segment that completes a specific function, and is more suitable for describing the execution process of software in the processor 30 than a program.
可以理解的是,对应上述基于多路摄像的人脸识别方法中的各实施方式,终端1可以包括图3中所示的各功能模块中的一部分或全部,各模块的功能将在以下具体介绍。需要说明的是,以上基于多路摄像的人脸识别方法的各实施方式中相同的名词相关名词及其具体的解释说明也可以适用于以下对各模块的功能介绍。为节省篇幅及避免重复起见,在此就不再赘述。It can be understood that, corresponding to the above-mentioned implementations of the face recognition method based on multiple cameras, the terminal 1 may include some or all of the functional modules shown in FIG. 3, and the functions of each module will be described in detail below . It should be noted that the same noun related terms and specific explanations in the above embodiments of the face recognition method based on multi-channel camera can also be applied to the following functional introduction of each module. To save space and avoid repetition, I won’t repeat them here.
样本数据库建立模块101可以用于为预设多路摄像装置中的每一路摄像装置对应建立样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同。The sample database establishment module 101 may be used to establish a sample database corresponding to each camera device in the preset multi-channel camera device, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device.
人脸图像获取模块103可以用于获取每一路摄像装置同时进行拍摄的待测人脸图像的多个待测人脸。The face image acquisition module 103 may be used to acquire multiple faces to be measured in the face images to be measured that are simultaneously captured by each camera.
拍摄角度识别模块105可以用于根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度。The shooting angle recognition module 105 may be used to recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model.
角度差值计算模块107可以用于计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值。The angle difference calculation module 107 may be used to calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device.
目标差值确定模块109可以用于从所述角度差值中筛选出最小的角度差值作为目标角度差值。The target difference value determining module 109 may be used to filter the smallest angle difference value from the angle difference values as the target angle difference value.
样本数据库确定模块111可以用于将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库。The sample database determining module 111 may be used to determine the sample database of the camera device corresponding to the target angle difference as the target sample database.
人脸识别模块113可以用于根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。The face recognition module 113 may be configured to recognize, according to the face images in the target sample database, the face images to be measured taken by the camera device corresponding to the target angle difference.
本申请实施例还提供一种非易失性可读存储介质,其上存储有计算机可读指令,所述计算机可读指令被处理器30执行时实现上述任一实施方式中的基于多路摄像的人脸识别方法的步骤。The embodiments of the present application also provide a non-volatile readable storage medium, on which computer-readable instructions are stored, and when the computer-readable instructions are executed by the processor 30, the multi-channel camera-based system in any of the above embodiments is implemented The steps of the face recognition method.
所述基于多路摄像的人脸识别装置100/终端1/计算机设备集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个非易失性可读取存储介质中。基于这样的理解,本申请实现上述实施方式方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性可读存储介质中,该计算机程序在被处理器30执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机可读指令,所述计算机可读指令可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读指令被处理器30执行时实现以下步骤:为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;从所述角度差值中筛选出最小的角度差值作为目标角度差值;将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。所述非易失性可读存储介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)等。If the multi-channel camera-based face recognition device 100/terminal 1/computer equipment integrated module/unit is realized in the form of a software functional unit and sold or used as an independent product, it can be stored in a non-volatile memory. Read the storage medium. Based on this understanding, this application implements all or part of the processes in the above-mentioned implementation methods, and can also be completed by instructing relevant hardware by a computer program, which can be stored in a non-volatile readable storage medium When the computer program is executed by the processor 30, the steps of the foregoing method embodiments can be implemented. The computer program includes computer-readable instructions, and the computer-readable instructions may be in the form of source code, object code, executable files, or some intermediate forms. When the computer-readable instructions are executed by the processor 30, the following steps are implemented: a sample database is established for each of the preset multi-channel camera devices, and the photographing angle of the face image in the sample database is corresponding to the The shooting angles of the camera devices are the same; obtain multiple face images to be tested of the face to be tested that are simultaneously shot by each camera device; identify the shooting of the face images to be tested according to the pre-trained face angle recognition model Angle; calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device; selecting the smallest angle difference from the angle difference as the target angle difference; The sample database of the camera device corresponding to the target angle difference is determined as the target sample database; the face to be measured captured by the camera device corresponding to the target angle difference is identified according to the face image in the target sample database image. The non-volatile readable storage medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read -Only Memory) etc.
所称处理器30可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等,所述处理器30是所述基于多路摄像的人脸识别装置100/终端1的控制中心,利用各种接口和线路连接整个基于多路摄像的人脸识别装置100/终端1的各个部分。The so-called processor 30 may be a central processing unit (Central Processing Unit, CPU), other general processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), Ready-made programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The processor 30 is the control center of the multi-channel camera-based face recognition device 100/terminal 1, and uses various The interfaces and lines connect various parts of the entire face recognition device 100/terminal 1 based on multi-channel camera.
所述存储器10用于存储所述计算机程序和/或模块,所述处理器30通过运行或执行存储在所述存储器内的计算机程序和/或模块,以及调用存储在存储器10内的数据,实现所述基于多路摄像的人脸识别装置100/终端1的各种功能。所述存储器10可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据终端的使用所创建的数据(比如音频数据等)等。The memory 10 is used to store the computer program and/or module, and the processor 30 executes or executes the computer program and/or module stored in the memory and calls the data stored in the memory 10 to implement Various functions of the face recognition device 100/terminal 1 based on multi-channel camera. The memory 10 may mainly include a storage program area and a storage data area. The storage program area may store an operating system, an application program required by at least one function (such as a sound playback function, an image playback function, etc.), etc.; the storage data area may Store data (such as audio data, etc.) created according to the use of the terminal.
在本申请所提供的几个具体实施方式中,应该理解到,所揭露的终端和方法,可以通过其它的方式实现。例如,以上所描述的系统实施方式仅仅是示意性的,例如,所述模块的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。In the several specific implementation manners provided in this application, it should be understood that the disclosed terminal and method may be implemented in other ways. For example, the system implementation described above is only illustrative. For example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.
对于本领域技术人员而言,显然本申请实施例不限于上述示范性实施例的细节,而且在不背离本申请实施例的精神或基本特征的情况下,能够以其他的具体形式实现本申请实施例。因此,无论从哪一点来看,均应将实施例看作是示范性的,而且是非限制性的,本申请实施例的范围由所附权利要求而不是上述说明限定,因此旨在将落在权利要求的等同要件的含义和范围内的所有变化涵括在本申请实施例内。不应将权利要求中的任何附图标记视为限制所涉及的权利要求。权利要求中陈述的多个单元、模块或装置也可以由同一个单元、模块或装置通过软 件或者硬件来实现。For those skilled in the art, it is obvious that the embodiments of the present application are not limited to the details of the above exemplary embodiments, and can be implemented in other specific forms without departing from the spirit or basic characteristics of the embodiments of the present application. example. Therefore, no matter from which point of view, the embodiments should be regarded as exemplary and non-limiting. The scope of the embodiments of the present application is defined by the appended claims rather than the above description, and therefore it is intended to fall on All changes within the meaning and scope of equivalent elements of the claims are included in the embodiments of the present application. Any reference signs in the claims should not be regarded as limiting the claims involved. Multiple units, modules or devices stated in the claims can also be implemented by the same unit, module or device through software or hardware.
以上实施方式仅用以说明本申请实施例的技术方案而非限制,尽管参照以上较佳实施方式对本申请实施例进行了详细说明,本领域的普通技术人员应当理解,可以对本申请实施例的技术方案进行修改或等同替换都不应脱离本申请实施例的技术方案的精神和范围。The above implementation manners are only used to illustrate the technical solutions of the embodiments of the present application, not to limit them. Although the embodiments of the present application are described in detail with reference to the above preferred implementation manners, those of ordinary skill in the art should understand that the technical solutions of the embodiments of the application Modifications or equivalent replacements of the solutions should not depart from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims (20)

  1. 一种基于多路摄像的人脸识别方法,所述基于多路摄像的人脸识别方法包括:A face recognition method based on multi-channel camera, the face recognition method based on multi-channel camera includes:
    为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;Establishing a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database is the same as the shooting angle of the corresponding camera device;
    获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera device;
    根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;Identifying the shooting angle of the face image to be tested according to the pre-trained face angle recognition model;
    计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;Calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
    从所述角度差值中筛选出最小的角度差值作为目标角度差值;The smallest angle difference is selected from the angle difference as the target angle difference;
    将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;Determining the sample database of the camera device corresponding to the target angle difference as the target sample database;
    根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。Identify the face image to be measured taken by the camera device corresponding to the target angle difference according to the face image in the target sample database.
  2. 根据权利要求1所述的基于多路摄像的人脸识别方法,所述预设多路摄像装置包括共中心设置的第一路摄像装置、第二路摄像装置与第三路摄像装置,所述为预设多路摄像装置中的每一路摄像装置建立一个样本数据库包括:The face recognition method based on multi-channel cameras according to claim 1, wherein the preset multi-channel camera device includes a first camera device, a second camera device, and a third camera device arranged in a common center. Establishing a sample database for each of the preset multi-channel camera devices includes:
    以所述中心为圆心点,设置第一路摄像装置拍摄角度为0°,设置所述第二路摄像装置的拍摄角度为+90°,设置所述第三路摄像装置的拍摄角度为-90°;Taking the center as the center point, set the shooting angle of the first camera device to 0°, set the shooting angle of the second camera device to +90°, and set the shooting angle of the third camera device to -90 °;
    控制所述第一路摄像装置、所述第二路摄像装置与所述第三路摄像装置同时拍摄预设数量的目标测试者中的每一个所述目标测试者,得到不同拍摄角度的人脸图像;Control the first camera device, the second camera device, and the third camera device to simultaneously capture a preset number of target testers for each of the target testers to obtain faces with different shooting angles image;
    将所述第一路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第一路摄像装置的第一样本数据库,将所述第二路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第二路摄像装置的第二样本数据库,将所述第三路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第三路摄像装置的第三样本数据库。The face images of the preset number of target testers captured by the first camera device are used as the first sample database of the first camera device, and the second camera device A preset number of face images of the target tester are used as the second sample database of the second camera, and the preset number of face images of the target tester captured by the third camera are used as all The third sample database of the third camera device.
  3. 根据权利要求1所述的基于多路摄像的人脸识别方法,在所述获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像之后,所述方法还包括:The face recognition method based on multi-channel camera according to claim 1, after said acquiring a plurality of face images to be tested of the face to be tested taken by each camera at the same time, the method further comprises:
    对所述每一路摄像装置拍摄的待测人脸图像进行预处理,所述预处理包括以下中的一种或多种:图像去噪处理;光照归一化处理;姿态校准处理;灰度归一化处理。Preprocessing is performed on the face images to be measured taken by each camera device, and the preprocessing includes one or more of the following: image denoising processing; light normalization processing; posture calibration processing; gray scale restoration One treatment.
  4. 根据权利要求2所述的基于多路摄像的人脸识别方法,所述根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度包括:The face recognition method based on multi-channel camera according to claim 2, wherein the recognizing the shooting angle of the face image to be tested according to the pre-trained face angle recognition model comprises:
    获取第一路摄像装置拍摄的待测人脸图像;Obtain the face image to be tested taken by the first camera;
    将所述待测人脸图像输入至预先训练好的人脸角度识别模型中;Inputting the face image to be tested into a pre-trained face angle recognition model;
    通过所述预先训练好的人脸角度识别模型确认所述待测人脸图像的拍摄角度。Confirm the shooting angle of the face image to be tested by the pre-trained face angle recognition model.
  5. 根据权利要求4所述的基于多路摄像的人脸识别方法,所述人脸角度识别模型的训练过程包括:According to the method for face recognition based on multi-channel camera of claim 4, the training process of the face angle recognition model includes:
    获取人脸图像数据集,所述人脸图像数据集中包括多个人的不同拍摄角度的人脸图像;Acquiring a face image data set, where the face image data set includes face images of multiple people at different shooting angles;
    对所述人脸图像数据集进行划分,得到训练集和测试集;Dividing the face image data set to obtain a training set and a test set;
    将所述训练集中的人脸图像输入预先设置好的神经网络模型中进行训练,得到人脸角度识别模型;Inputting the face image in the training set into a preset neural network model for training to obtain a face angle recognition model;
    将所述测试集中的人脸图像输入至所述人脸角度识别模型中进行测试,获得测试通过率;Input the face images in the test set into the face angle recognition model for testing, and obtain a test pass rate;
    当所述测试通过率大于或者等于预设通过率阈值时,结束所述人脸角度识别模型的训练;若所述测试通过率小于所述预设通过率阈值时,增加所述训练集中的人脸图像的数量,重新进行人脸角度识别模型的训练。When the test pass rate is greater than or equal to the preset pass rate threshold, the training of the face angle recognition model ends; if the test pass rate is less than the preset pass rate threshold, increase the number of people in the training set For the number of face images, retrain the face angle recognition model.
  6. 根据权利要求1所述的基于多路摄像的人脸识别方法,所述根据所述目标样本数据库中的人脸图像识别对应所述目标角度差值的摄像装置拍摄的待测人脸图像包括:The face recognition method based on multi-channel photography according to claim 1, wherein the recognition of the face image to be measured taken by the camera device corresponding to the target angle difference according to the face image in the target sample database comprises:
    提取所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征;Extracting the facial features of the face image to be tested and the facial features of the face image in the target sample database;
    计算所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征的相似度;Calculating the similarity between the face feature of the face image to be tested and the face feature of the face image in the target sample database;
    判断所述相似度是否大于或等于预设相似度阈值;Judging whether the similarity is greater than or equal to a preset similarity threshold;
    若判断结果为所述相似度大于或等于预设相似度阈值,则输出所述样本数据库中对应所述相似度的人脸图像作为所述待测人脸图像的人脸识别结果。If the judgment result is that the similarity is greater than or equal to the preset similarity threshold, output the face image corresponding to the similarity in the sample database as the face recognition result of the face image to be tested.
  7. 根据权利要求6所述的基于多路摄像的人脸识别方法,当判断所述相似度小于所述预设相似度阈值时,所述方法还包括:The face recognition method based on multi-channel camera according to claim 6, when it is determined that the similarity is less than the preset similarity threshold, the method further comprises:
    根据所述第一样本数据库识别出所述第一路摄像装置拍摄的所述待测人脸图像的第一候选人脸图像;Identifying, according to the first sample database, the first candidate face image of the face image to be tested taken by the first camera device;
    根据所述第二样本数据库识别出所述第二路摄像装置拍摄的所述待测人脸图像的第二候选人脸图像;Identifying, according to the second sample database, the second candidate face image of the face image to be tested captured by the second camera device;
    根据所述第三样本数据库识别出所述第三路摄像装置拍摄的所述待测人脸图像的第三候选人脸图像;Identifying, according to the third sample database, the third candidate face image of the face image to be tested taken by the third camera device;
    判断所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像是否为同一人的人脸图像;Judging whether the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image;
    若判断结果为所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像为同一人的人脸图像,则输出所述第一候选人脸图像作为最终人脸识别结果。If the judgment result is that the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image, output the first candidate face image as the final Face recognition result.
  8. 一种基于多路摄像的人脸识别装置,所述基于多路摄像的人脸识别装置包括:A face recognition device based on multi-channel camera, the face recognition device based on multi-channel camera includes:
    样本数据库建立模块,用于为预设多路摄像装置中的每一路摄像装置对应建立样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;A sample database establishment module for establishing a sample database corresponding to each camera device in the preset multi-channel camera device, and the photographing angle of the face image in the sample database is the same as the photographing angle of the corresponding camera device;
    人脸图像获取模块,用于获取每一路摄像装置同时进行拍摄的待测人脸图像的多个待测人脸;The face image acquisition module is used to acquire multiple faces to be measured in the face images to be measured taken by each camera at the same time;
    拍摄角度识别模块,用于根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;A shooting angle recognition module, configured to recognize the shooting angle of the face image to be tested according to a pre-trained face angle recognition model;
    角度差值计算模块,用于计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;An angle difference calculation module, configured to calculate the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
    目标差值确定模块,用于从所述角度差值中筛选出最小的角度差值作为目标角度差值;The target difference determination module is configured to filter out the smallest angle difference from the angle difference as the target angle difference;
    样本数据库确定模块,用于将对应所述目标角度差值的摄像装置的样本数据 库确定为目标样本数据库;A sample database determining module, configured to determine the sample database of the camera device corresponding to the target angle difference as the target sample database;
    人脸识别模块,用于根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。The face recognition module is configured to recognize, according to the face image in the target sample database, the face image to be measured taken by the camera device corresponding to the target angle difference.
  9. 一种终端,所述终端包括处理器,所述处理器用于执行存储器中存储的计算机可读指令以实现以下步骤:A terminal includes a processor configured to execute computer-readable instructions stored in a memory to implement the following steps:
    为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;Establishing a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database is the same as the shooting angle of the corresponding camera device;
    获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera device;
    根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;Identifying the shooting angle of the face image to be tested according to the pre-trained face angle recognition model;
    计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;Calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
    从所述角度差值中筛选出最小的角度差值作为目标角度差值;The smallest angle difference is selected from the angle difference as the target angle difference;
    将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;Determining the sample database of the camera device corresponding to the target angle difference as the target sample database;
    根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。Identify the face image to be measured taken by the camera device corresponding to the target angle difference according to the face image in the target sample database.
  10. 根据权利要求9所述的终端,所述预设多路摄像装置包括共中心设置的第一路摄像装置、第二路摄像装置与第三路摄像装置,所述处理器在执行所述计算机可读指令以实现所述为预设多路摄像装置中的每一路摄像装置建立一个样本数据库时,包括以下步骤:The terminal according to claim 9, wherein the preset multi-channel camera device includes a first camera device, a second camera device, and a third camera device that are co-centered, and the processor executes the computer Reading instructions to realize the establishment of a sample database for each of the preset multi-channel camera devices includes the following steps:
    以所述中心为圆心点,设置第一路摄像装置拍摄角度为0°,设置所述第二路摄像装置的拍摄角度为+90°,设置所述第三路摄像装置的拍摄角度为-90°;Taking the center as the center point, set the shooting angle of the first camera device to 0°, set the shooting angle of the second camera device to +90°, and set the shooting angle of the third camera device to -90 °;
    控制所述第一路摄像装置、所述第二路摄像装置与所述第三路摄像装置同时拍摄预设数量的目标测试者中的每一个所述目标测试者,得到不同拍摄角度的人脸图像;Control the first camera device, the second camera device, and the third camera device to simultaneously capture a preset number of target testers for each of the target testers to obtain faces with different shooting angles image;
    将所述第一路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第一路摄像装置的第一样本数据库,将所述第二路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第二路摄像装置的第二样本数据库,将所述第三路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第三路摄像装置的第三样本数据库。The face images of the preset number of target testers captured by the first camera device are used as the first sample database of the first camera device, and the second camera device A preset number of face images of the target tester are used as the second sample database of the second camera, and the preset number of face images of the target tester captured by the third camera are used as all The third sample database of the third camera device.
  11. 根据权利要求10所述的终端,所述处理器在执行所述计算机可读指令以实现所述根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度时,包括以下步骤:The terminal according to claim 10, when the processor executes the computer-readable instruction to realize the recognition of the shooting angle of the face image to be measured according to a pre-trained face angle recognition model, the following steps are included: step:
    获取第一路摄像装置拍摄的待测人脸图像;Obtain the face image to be tested taken by the first camera;
    将所述待测人脸图像输入至预先训练好的人脸角度识别模型中;Inputting the face image to be tested into a pre-trained face angle recognition model;
    通过所述预先训练好的人脸角度识别模型确认所述待测人脸图像的拍摄角度。Confirm the shooting angle of the face image to be tested by the pre-trained face angle recognition model.
  12. 根据权利要求11所述的终端,所述处理器在执行所述计算机可读指令以实现所述人脸角度识别模型的训练过程时,包括以下步骤:The terminal according to claim 11, when the processor executes the computer-readable instructions to implement the training process of the face angle recognition model, the processor comprises the following steps:
    获取人脸图像数据集,所述人脸图像数据集中包括多个人的不同拍摄角度的人脸图像;Acquiring a face image data set, where the face image data set includes face images of multiple people at different shooting angles;
    对所述人脸图像数据集进行划分,得到训练集和测试集;Dividing the face image data set to obtain a training set and a test set;
    将所述训练集中的人脸图像输入预先设置好的神经网络模型中进行训练,得到人脸角度识别模型;Inputting the face image in the training set into a preset neural network model for training to obtain a face angle recognition model;
    将所述测试集中的人脸图像输入至所述人脸角度识别模型中进行测试,获得 测试通过率;Input the face images in the test set into the face angle recognition model for testing, and obtain a test pass rate;
    当所述测试通过率大于或者等于预设通过率阈值时,结束所述人脸角度识别模型的训练;若所述测试通过率小于所述预设通过率阈值时,增加所述训练集中的人脸图像的数量,重新进行人脸角度识别模型的训练。When the test pass rate is greater than or equal to the preset pass rate threshold, the training of the face angle recognition model ends; if the test pass rate is less than the preset pass rate threshold, increase the number of people in the training set For the number of face images, retrain the face angle recognition model.
  13. 根据权利要求9所述的终端,所述处理器在执行所述计算机可读指令以实现所述根据所述目标样本数据库中的人脸图像识别对应所述目标角度差值的摄像装置拍摄的待测人脸图像时,包括以下步骤:The terminal according to claim 9, wherein the processor is executing the computer-readable instructions to realize the recognition of the image taken by the camera device corresponding to the target angle difference according to the face image in the target sample database. When measuring a face image, it includes the following steps:
    提取所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征;Extracting the facial features of the face image to be tested and the facial features of the face image in the target sample database;
    计算所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征的相似度;Calculating the similarity between the face feature of the face image to be tested and the face feature of the face image in the target sample database;
    判断所述相似度是否大于或等于预设相似度阈值;Judging whether the similarity is greater than or equal to a preset similarity threshold;
    若判断结果为所述相似度大于或等于预设相似度阈值,则输出所述样本数据库中对应所述相似度的人脸图像作为所述待测人脸图像的人脸识别结果。If the judgment result is that the similarity is greater than or equal to the preset similarity threshold, output the face image corresponding to the similarity in the sample database as the face recognition result of the face image to be tested.
  14. 根据权利要求13所述的终端,当判断所述相似度小于所述预设相似度阈值时,所述处理器执行计算机可读指令还用以实现以下步骤:The terminal according to claim 13, when it is determined that the similarity is less than the preset similarity threshold, the processor executes computer-readable instructions to further implement the following steps:
    根据所述第一样本数据库识别出所述第一路摄像装置拍摄的所述待测人脸图像的第一候选人脸图像;Identifying, according to the first sample database, the first candidate face image of the face image to be tested taken by the first camera device;
    根据所述第二样本数据库识别出所述第二路摄像装置拍摄的所述待测人脸图像的第二候选人脸图像;Identifying, according to the second sample database, the second candidate face image of the face image to be tested captured by the second camera device;
    根据所述第三样本数据库识别出所述第三路摄像装置拍摄的所述待测人脸图像的第三候选人脸图像;Identifying, according to the third sample database, the third candidate face image of the face image to be tested taken by the third camera device;
    判断所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像是否为同一人的人脸图像;Judging whether the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image;
    若判断结果为所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像为同一人的人脸图像,则输出所述第一候选人脸图像作为最终人脸识别结果。If the judgment result is that the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image, output the first candidate face image as the final Face recognition result.
  15. 一种非易失性可读存储介质,所述非易失性可读存储介质上存储有计算机可读指令,所述计算机可读指令被处理器执行时实现以下步骤:A non-volatile readable storage medium having computer readable instructions stored on the non-volatile readable storage medium, and when the computer readable instructions are executed by a processor, the following steps are implemented:
    为预设多路摄像装置中的每一路摄像装置建立一个样本数据库,所述样本数据库中的人脸图像的拍摄角度与对应的所述摄像装置的拍摄角度相同;Establishing a sample database for each camera device in the preset multi-channel camera device, and the shooting angle of the face image in the sample database is the same as the shooting angle of the corresponding camera device;
    获取每一路摄像装置同时进行拍摄的待测人脸的多个待测人脸图像;Acquire multiple face images to be measured of faces to be measured that are simultaneously photographed by each camera device;
    根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度;Identifying the shooting angle of the face image to be tested according to the pre-trained face angle recognition model;
    计算所述待测人脸图像的拍摄角度与所述每一路摄像装置的拍摄角度之间的角度差值;Calculating the angle difference between the shooting angle of the face image to be measured and the shooting angle of each camera device;
    从所述角度差值中筛选出最小的角度差值作为目标角度差值;The smallest angle difference is selected from the angle difference as the target angle difference;
    将对应所述目标角度差值的摄像装置的样本数据库确定为目标样本数据库;Determining the sample database of the camera device corresponding to the target angle difference as the target sample database;
    根据所述目标样本数据库中的人脸图像识别所述对应所述目标角度差值的摄像装置拍摄的待测人脸图像。Identify the face image to be measured taken by the camera device corresponding to the target angle difference according to the face image in the target sample database.
  16. 根据权利要求15所述的非易性可读存储介质,所述预设多路摄像装置包括共中心设置的第一路摄像装置、第二路摄像装置与第三路摄像装置,所述计算机可读指令被处理器执行时实现所述为预设多路摄像装置中的每一路摄像装置建立一个样本数据库时,包括以下步骤:The non-readable storage medium of claim 15, wherein the preset multi-channel camera device includes a first camera device, a second camera device, and a third camera device that are arranged in a common center, and the computer can When the read instruction is executed by the processor to realize the establishment of a sample database for each of the preset multi-channel camera devices, the following steps are included:
    以所述中心为圆心点,设置第一路摄像装置拍摄角度为0°,设置所述第二 路摄像装置的拍摄角度为+90°,设置所述第三路摄像装置的拍摄角度为-90°;With the center as the center point, set the shooting angle of the first camera to 0°, set the shooting angle of the second camera to +90°, and set the shooting angle of the third camera to -90 °;
    控制所述第一路摄像装置、所述第二路摄像装置与所述第三路摄像装置同时拍摄预设数量的目标测试者中的每一个所述目标测试者,得到不同拍摄角度的人脸图像;Control the first camera device, the second camera device, and the third camera device to simultaneously capture a preset number of target testers for each of the target testers to obtain faces with different shooting angles image;
    将所述第一路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第一路摄像装置的第一样本数据库,将所述第二路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第二路摄像装置的第二样本数据库,将所述第三路摄像装置拍摄的所述预设数量的目标测试者的人脸图像作为所述第三路摄像装置的第三样本数据库。The face images of the preset number of target testers captured by the first camera device are used as the first sample database of the first camera device, and the second camera device A preset number of face images of the target tester are used as the second sample database of the second camera, and the preset number of face images of the target tester captured by the third camera are used as all The third sample database of the third camera device.
  17. 根据权利要求16所述的非易失性可读存储介质,所述计算机可读指令被处理器执行时实现所述根据预先训练好的人脸角度识别模型识别所述待测人脸图像的拍摄角度,包括以下步骤:The non-volatile readable storage medium according to claim 16, when the computer-readable instructions are executed by a processor, the photographing of the face image to be measured is recognized according to the pre-trained face angle recognition model Angle, including the following steps:
    获取第一路摄像装置拍摄的待测人脸图像;Obtain the face image to be tested taken by the first camera;
    将所述待测人脸图像输入至预先训练好的人脸角度识别模型中;Inputting the face image to be tested into a pre-trained face angle recognition model;
    通过所述预先训练好的人脸角度识别模型确认所述待测人脸图像的拍摄角度。Confirm the shooting angle of the face image to be tested by the pre-trained face angle recognition model.
  18. 根据权利要求17所述的非易失性可读存储介质,所述计算机可读指令被处理器执行时实现所述人脸角度识别模型的训练过程,包括以下步骤:According to the non-volatile readable storage medium of claim 17, when the computer readable instructions are executed by a processor, the training process of the face angle recognition model is realized, comprising the following steps:
    获取人脸图像数据集,所述人脸图像数据集中包括多个人的不同拍摄角度的人脸图像;Acquiring a face image data set, where the face image data set includes face images of multiple people at different shooting angles;
    对所述人脸图像数据集进行划分,得到训练集和测试集;Dividing the face image data set to obtain a training set and a test set;
    将所述训练集中的人脸图像输入预先设置好的神经网络模型中进行训练,得到人脸角度识别模型;Inputting the face image in the training set into a preset neural network model for training to obtain a face angle recognition model;
    将所述测试集中的人脸图像输入至所述人脸角度识别模型中进行测试,获得测试通过率;Input the face images in the test set into the face angle recognition model for testing, and obtain a test pass rate;
    当所述测试通过率大于或者等于预设通过率阈值时,结束所述人脸角度识别模型的训练;若所述测试通过率小于所述预设通过率阈值时,增加所述训练集中的人脸图像的数量,重新进行人脸角度识别模型的训练。When the test pass rate is greater than or equal to the preset pass rate threshold, the training of the face angle recognition model ends; if the test pass rate is less than the preset pass rate threshold, increase the number of people in the training set For the number of face images, retrain the face angle recognition model.
  19. 根据权利要求15所述的非易失性可读存储介质,所述计算机可读指令被处理器执行时以实现所述根据所述目标样本数据库中的人脸图像识别对应所述目标角度差值的摄像装置拍摄的待测人脸图像,包括以下步骤:The non-volatile readable storage medium according to claim 15, when the computer-readable instructions are executed by a processor to realize the recognition corresponding to the target angle difference according to the face image in the target sample database The face image to be tested captured by the camera device includes the following steps:
    提取所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征;Extracting the facial features of the face image to be tested and the facial features of the face image in the target sample database;
    计算所述待测人脸图像的人脸特征与所述目标样本数据库中人脸图像的人脸特征的相似度;Calculating the similarity between the face feature of the face image to be tested and the face feature of the face image in the target sample database;
    判断所述相似度是否大于或等于预设相似度阈值;Judging whether the similarity is greater than or equal to a preset similarity threshold;
    若判断结果为所述相似度大于或等于预设相似度阈值,则输出所述样本数据库中对应所述相似度的人脸图像作为所述待测人脸图像的人脸识别结果。If the judgment result is that the similarity is greater than or equal to the preset similarity threshold, output the face image corresponding to the similarity in the sample database as the face recognition result of the face image to be tested.
  20. 根据权利要求19所述的非易失性可读存在介质,当判断所述相似度小于所述预设相似度阈值时,所述计算机可读指令被处理器执行还用以实现以下步骤:According to the non-volatile readable storage medium of claim 19, when it is determined that the similarity is less than the preset similarity threshold, the computer-readable instructions are executed by the processor to further implement the following steps:
    根据所述第一样本数据库识别出所述第一路摄像装置拍摄的所述待测人脸图像的第一候选人脸图像;Identifying, according to the first sample database, the first candidate face image of the face image to be tested taken by the first camera device;
    根据所述第二样本数据库识别出所述第二路摄像装置拍摄的所述待测人脸 图像的第二候选人脸图像;Identifying, according to the second sample database, the second candidate face image of the face image to be tested captured by the second camera device;
    根据所述第三样本数据库识别出所述第三路摄像装置拍摄的所述待测人脸图像的第三候选人脸图像;Identifying, according to the third sample database, the third candidate face image of the face image to be tested taken by the third camera device;
    判断所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像是否为同一人的人脸图像;Judging whether the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image;
    若判断结果为所述第一候选人脸图像、所述第二候选人脸图像及所述第三候选人脸图像为同一人的人脸图像,则输出所述第一候选人脸图像作为最终人脸识别结果。If the judgment result is that the first candidate face image, the second candidate face image, and the third candidate face image are the same person's face image, output the first candidate face image as the final Face recognition result.
PCT/CN2019/103389 2019-06-11 2019-08-29 Face recognition method and apparatus based on multiple cameras, and terminal and storage medium WO2020248387A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910502775.1 2019-06-11
CN201910502775.1A CN110443110B (en) 2019-06-11 2019-06-11 Face recognition method, device, terminal and storage medium based on multipath camera shooting

Publications (1)

Publication Number Publication Date
WO2020248387A1 true WO2020248387A1 (en) 2020-12-17

Family

ID=68429503

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/103389 WO2020248387A1 (en) 2019-06-11 2019-08-29 Face recognition method and apparatus based on multiple cameras, and terminal and storage medium

Country Status (2)

Country Link
CN (1) CN110443110B (en)
WO (1) WO2020248387A1 (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112614168A (en) * 2020-12-21 2021-04-06 浙江大华技术股份有限公司 Target face tracking method and device, electronic equipment and storage medium
CN112861825A (en) * 2021-04-07 2021-05-28 北京百度网讯科技有限公司 Model training method, pedestrian re-identification method, device and electronic equipment
CN113042171A (en) * 2021-03-30 2021-06-29 桐乡秦一纺织股份有限公司 Waste recovery device for coated fabric and recovery method thereof
CN113420739A (en) * 2021-08-24 2021-09-21 北京通建泰利特智能系统工程技术有限公司 Intelligent emergency monitoring method and system based on neural network and readable storage medium
CN113780172A (en) * 2021-09-10 2021-12-10 济南博观智能科技有限公司 Pedestrian re-identification method, device, equipment and storage medium
CN114324330A (en) * 2021-12-24 2022-04-12 深圳一信泰质量技术有限公司 Ultrahigh-definition intelligent interactive display terminal performance detection device and method
CN114938425A (en) * 2021-06-15 2022-08-23 义隆电子股份有限公司 Photographing apparatus and object recognition method using artificial intelligence
CN117238032A (en) * 2023-09-18 2023-12-15 以萨技术股份有限公司 Gait feature comparison method, storage medium and electronic equipment

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112016508B (en) * 2020-09-07 2023-08-29 杭州海康威视数字技术股份有限公司 Face recognition method, device, system, computing device and storage medium
CN113128427A (en) * 2021-04-24 2021-07-16 新疆爱华盈通信息技术有限公司 Face recognition method and device, computer readable storage medium and terminal equipment
CN113657379A (en) * 2021-08-09 2021-11-16 杭州华橙软件技术有限公司 Image processing method, image processing device, computer-readable storage medium and processor
CN115273264A (en) * 2022-08-09 2022-11-01 平安付科技服务有限公司 Attendance system, method, storage medium and computer equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107480658A (en) * 2017-09-19 2017-12-15 苏州大学 Face identification device and method based on multi-angle video
CN107506702A (en) * 2017-08-08 2017-12-22 江西高创保安服务技术有限公司 Human face recognition model training and test system and method based on multi-angle
CN207530944U (en) * 2017-12-18 2018-06-22 北京旷视科技有限公司 Face recognition cameras
WO2019089014A1 (en) * 2017-10-31 2019-05-09 The Hong Kong University Of Science And Technology Facilitation of visual tracking

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9230158B1 (en) * 2012-12-18 2016-01-05 Amazon Technologies, Inc. Fraud detection for facial recognition systems

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107506702A (en) * 2017-08-08 2017-12-22 江西高创保安服务技术有限公司 Human face recognition model training and test system and method based on multi-angle
CN107480658A (en) * 2017-09-19 2017-12-15 苏州大学 Face identification device and method based on multi-angle video
WO2019089014A1 (en) * 2017-10-31 2019-05-09 The Hong Kong University Of Science And Technology Facilitation of visual tracking
CN207530944U (en) * 2017-12-18 2018-06-22 北京旷视科技有限公司 Face recognition cameras

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112614168A (en) * 2020-12-21 2021-04-06 浙江大华技术股份有限公司 Target face tracking method and device, electronic equipment and storage medium
CN112614168B (en) * 2020-12-21 2023-08-29 浙江大华技术股份有限公司 Target face tracking method and device, electronic equipment and storage medium
CN113042171A (en) * 2021-03-30 2021-06-29 桐乡秦一纺织股份有限公司 Waste recovery device for coated fabric and recovery method thereof
CN113042171B (en) * 2021-03-30 2023-01-31 桐乡秦一纺织股份有限公司 Waste recovery device for coated fabric and recovery method thereof
CN112861825A (en) * 2021-04-07 2021-05-28 北京百度网讯科技有限公司 Model training method, pedestrian re-identification method, device and electronic equipment
CN112861825B (en) * 2021-04-07 2023-07-04 北京百度网讯科技有限公司 Model training method, pedestrian re-recognition method, device and electronic equipment
CN114938425A (en) * 2021-06-15 2022-08-23 义隆电子股份有限公司 Photographing apparatus and object recognition method using artificial intelligence
CN113420739B (en) * 2021-08-24 2022-10-18 北京通建泰利特智能系统工程技术有限公司 Intelligent emergency monitoring method and system based on neural network and readable storage medium
CN113420739A (en) * 2021-08-24 2021-09-21 北京通建泰利特智能系统工程技术有限公司 Intelligent emergency monitoring method and system based on neural network and readable storage medium
CN113780172A (en) * 2021-09-10 2021-12-10 济南博观智能科技有限公司 Pedestrian re-identification method, device, equipment and storage medium
CN113780172B (en) * 2021-09-10 2024-01-23 济南博观智能科技有限公司 Pedestrian re-identification method, device, equipment and storage medium
CN114324330A (en) * 2021-12-24 2022-04-12 深圳一信泰质量技术有限公司 Ultrahigh-definition intelligent interactive display terminal performance detection device and method
CN114324330B (en) * 2021-12-24 2023-09-12 深圳一信泰质量技术有限公司 Device and method for detecting performance of ultra-high definition intelligent interactive display terminal
CN117238032A (en) * 2023-09-18 2023-12-15 以萨技术股份有限公司 Gait feature comparison method, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN110443110B (en) 2023-08-25
CN110443110A (en) 2019-11-12

Similar Documents

Publication Publication Date Title
WO2020248387A1 (en) Face recognition method and apparatus based on multiple cameras, and terminal and storage medium
CN109948408B (en) Activity test method and apparatus
WO2018028546A1 (en) Key point positioning method, terminal, and computer storage medium
JP3954484B2 (en) Image processing apparatus and program
WO2020093634A1 (en) Face recognition-based method, device and terminal for adding image, and storage medium
CN110659397B (en) Behavior detection method and device, electronic equipment and storage medium
WO2019033572A1 (en) Method for detecting whether face is blocked, device and storage medium
CA3152812A1 (en) Facial recognition method and apparatus
CN111126098B (en) Certificate image acquisition method, device, equipment and storage medium
JP6969663B2 (en) Devices and methods for identifying the user's imaging device
CN108509994B (en) Method and device for clustering character images
CN111553266A (en) Identification verification method and device and electronic equipment
US10423817B2 (en) Latent fingerprint ridge flow map improvement
CN112434556A (en) Pet nose print recognition method and device, computer equipment and storage medium
CN112149615A (en) Face living body detection method, device, medium and electronic equipment
CN113378804A (en) Self-service sampling detection method and device, terminal equipment and storage medium
CN111079687A (en) Certificate camouflage identification method, device, equipment and storage medium
CN111241873A (en) Image reproduction detection method, training method of model thereof, payment method and payment device
CN111881740A (en) Face recognition method, face recognition device, electronic equipment and medium
CN111027450A (en) Bank card information identification method and device, computer equipment and storage medium
WO2022082401A1 (en) Noseprint recognition method and apparatus for pet, computer device, and storage medium
CN112287905A (en) Vehicle damage identification method, device, equipment and storage medium
WO2020244076A1 (en) Face recognition method and apparatus, and electronic device and storage medium
CN111241945A (en) Method and device for testing face recognition performance, computer equipment and storage medium
CN116091963A (en) Quality evaluation method and device for clinical test institution, electronic equipment and storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19932366

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 19932366

Country of ref document: EP

Kind code of ref document: A1