CN109784207A - A kind of face identification method and device - Google Patents
A kind of face identification method and device Download PDFInfo
- Publication number
- CN109784207A CN109784207A CN201811596767.XA CN201811596767A CN109784207A CN 109784207 A CN109784207 A CN 109784207A CN 201811596767 A CN201811596767 A CN 201811596767A CN 109784207 A CN109784207 A CN 109784207A
- Authority
- CN
- China
- Prior art keywords
- face
- sample
- convolutional neural
- callout box
- image
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Landscapes
- Image Analysis (AREA)
Abstract
The embodiment of the present invention provides a kind of face identification method and device, this method comprises: obtaining images to be recognized;Use the face in concatenated convolutional neural network recognization images to be recognized;The training data of concatenated convolutional neural network includes face positive sample and face negative sample, face positive sample includes first sample and the second sample, face negative sample includes third sample and the 4th sample, the set for the image segments that first sample is marked by face callout box, second sample is the set for being greater than first threshold and the image segments less than 1 with the registration of face callout box, third sample is the set for the image segments for being 0 with the registration of face callout box, and the 4th sample is the set for the image segments for being greater than 0 with the registration of face callout box and being less than second threshold.Implement the embodiment of the present invention, recognition of face efficiency and recognition of face accuracy can be balanced.
Description
Technical field
The present invention relates to technical field of face recognition, and in particular to a kind of face identification method and device.
Background technique
In order to not influence image detection efficiency while improving image detection accuracy, industry introduces concatenated convolutional mind
Through network.The sample of training concatenated convolutional neural network includes face positive sample and face negative sample, face positive sample and face
The selection of negative sample is random.Since the complexity of the sample randomly selected is unknown, trained concatenated convolutional neural network
Filter capacity is too poor so that many inhuman face images can be identified as facial image, reduce recognition of face efficiency or
Filter capacity is too strong, so that many facial images are filtered, reduces recognition of face accuracy.
Summary of the invention
The embodiment of the present invention provides a kind of face identification method and device, for balancing recognition of face efficiency and recognition of face
Accuracy.
First aspect of the embodiment of the present invention provides a kind of face identification method, comprising:
Obtain images to be recognized;
Use the face in images to be recognized described in concatenated convolutional neural network recognization;
The training data of the concatenated convolutional neural network includes face positive sample and face negative sample, the positive sample of face
This includes first sample and the second sample, and the face negative sample includes third sample and the 4th sample, and the first sample is
The set for the image segments that face callout box is marked, second sample are to be greater than the with the registration of the face callout box
The set of one threshold value and the image segments less than 1, the third sample are the image for being 0 with the registration of the face callout box
The set of segment, the 4th sample are the image sheet for being greater than 0 with the registration of the face callout box and being less than second threshold
The set of section.
As it can be seen that for identification the training data of the concatenated convolutional neural network of face include simple face positive sample (i.e.
First sample), simple face negative sample (i.e. third sample), complicated face positive sample (i.e. the second sample) and complicated people
Face negative sample (i.e. the 4th sample), therefore, the filter capacity for the concatenated convolutional neural network that training can be made to obtain i.e. will not be too
Difference will not be too strong, so as to balance the recognition of face efficiency and recognition of face accuracy of cascade convolutional neural networks.
In one embodiment, the method also includes:
Obtain the image set including face callout box, position of the face callout box for face in tag image;
The image segments, big with the registration of the face callout box that face callout box is marked are chosen from the first image
In the first threshold and less than 1 image segments, with the registration of the face callout box for 0 image segments and with institute
The registration for stating face callout box is greater than 0 and is less than the image segments of the second threshold, obtains the training data, and described the
One image is any image that described image is concentrated;
Using training data training concatenated convolutional neural network to be trained, the concatenated convolutional neural network is obtained.
As it can be seen that being extracted simple face positive sample and simple face when extracting training data from same image
Negative sample is also extracted complicated face positive sample and complicated face negative sample.
In one embodiment, the concatenated convolutional neural network is cascaded by M convolutional neural networks, and the M
The complexity of convolutional neural networks successively increases, and the M is the integer more than or equal to 3.
In one embodiment, described using training data training concatenated convolutional neural network to be trained, obtain institute
Stating concatenated convolutional neural network includes:
Using first convolutional neural networks in training data training concatenated convolutional neural network to be trained, and
Using i-th of convolutional neural networks in the i-th training data training concatenated convolutional neural network to be trained, the grade is obtained
Join convolutional neural networks, the i is the integer greater than 1 and less than M+1;
I-th training data includes the defeated of the first sample, the third sample and (i-1)-th convolutional neural networks
Out.
As it can be seen that the training data of back convolutional neural networks not only includes the convolution of front one in concatenated convolutional neural network
The output of neural network further includes the initial training data in part, when can reduce trained before convolutional neural networks to below
The influence of convolutional neural networks.
In one embodiment, the output of (i-1)-th convolutional neural networks includes the 5th sample and the 6th sample, institute
State the set that the registration that the 5th sample is callout box and the face callout box is greater than the image segments of third threshold value, described the
Set of six samples for the registration of callout box and the face callout box less than the image segments of the 4th threshold value.
As it can be seen that the output of previous convolutional neural networks includes simple face positive sample, simple face negative sample, answers
Miscellaneous face positive sample and complicated face negative sample.
In one embodiment, image segments quantity in the face positive sample and face negative sample that the training data includes
Ratio be equal to the 5th threshold value, the ratio etc. of image segments quantity in the third sample and the 4th sample that the training data includes
In the 6th threshold value.
As it can be seen that the ratio of face positive sample quantity and face negative sample quantity is certain value, simple sample in face negative sample
This quantity and complex samples quantity are another definite value, therefore, can further balance cascade by adjusting the ratio of sample size
The recognition of face efficiency and recognition of face accuracy of convolutional neural networks.
In one embodiment, image segments in the face positive sample and face negative sample that i-th training data includes
The ratio of quantity is equal to the 5th threshold value, simple sample and complicated sample in the face negative sample that i-th training data includes
Ratio of image segments quantity is equal to the 6th threshold value in this, and the simple sample includes the third sample and the described 6th
The set of image segments of the registration of callout box and the face callout box equal to 0 in sample, the complex samples include institute
The registration of callout box and face callout box in the 6th sample is stated to be greater than 0 and be less than the collection of the image segments of the 4th threshold value
It closes.
As it can be seen that in all convolutional neural networks each convolutional neural networks face positive sample quantity and face negative sample
The ratio of quantity is certain value, and simple sample quantity and complex samples quantity are another definite value in face negative sample, therefore,
The recognition of face efficiency and face of cascade convolutional neural networks can be further balanced by adjusting the ratio of sample size
Identify accuracy.
Second aspect of the embodiment of the present invention provides a kind of face identification device, including for executing first aspect or first party
The unit for the face identification method that any embodiment in face provides.
The third aspect of the embodiment of the present invention provides a kind of face identification device, including processor and memory, the processing
Device and the memory are connected with each other, wherein for the memory for storing computer program, the computer program includes journey
Sequence instruction, what the processor was used to that any embodiment of described program instruction execution first aspect or first aspect to be called to provide
Face identification method.
Fourth aspect provides a kind of readable storage medium storing program for executing, and the readable storage medium storing program for executing is stored with computer program, described
Computer program includes program instruction, described program instruction make when being executed by a processor the processor execute first aspect or
The face identification method that any embodiment of first aspect provides.
5th aspect provides a kind of application program, and the application program for executing first aspect or first party at runtime
The face identification method that any embodiment in face provides.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to needed in the embodiment
Attached drawing is briefly described, it should be apparent that, drawings in the following description are some embodiments of the invention, general for this field
For logical technical staff, without creative efforts, it is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of flow diagram of face identification method provided in an embodiment of the present invention;
Fig. 2 is the flow diagram of another face identification method provided in an embodiment of the present invention;
Fig. 3 is a kind of structural schematic diagram of face identification device provided in an embodiment of the present invention;
Fig. 4 is the structural schematic diagram of another face identification device provided in an embodiment of the present invention;
Fig. 5 is a kind of schematic diagram of image including face callout box provided in an embodiment of the present invention;
Fig. 6 is a kind of schematic diagram of concatenated convolutional neural network recognization face provided in an embodiment of the present invention;
Fig. 7 is the schematic diagram that a kind of callout box provided in an embodiment of the present invention and face callout box partially overlap.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are some of the embodiments of the present invention, instead of all the embodiments.Based on this hair
Embodiment in bright, every other implementation obtained by those of ordinary skill in the art without making creative efforts
Example, shall fall within the protection scope of the present invention.
The embodiment of the present invention provides a kind of face identification method and device, for balancing recognition of face efficiency and recognition of face
Accuracy.It is described in detail separately below.
Referring to Fig. 1, Fig. 1 is a kind of flow diagram of face identification method provided in an embodiment of the present invention.According to not
With demand, certain steps in flow chart shown in FIG. 1 can be split as several steps.As shown in Figure 1, the target object is known
Other method may comprise steps of.
101, images to be recognized is obtained.
In the present embodiment, when needing to identify the face in image, images to be recognized is obtained.Images to be recognized can be this
The image of ground storage is also possible to the image obtained from network or server, can also be through image acquisition device
Image, this embodiment is not limited.Wherein, images to be recognized can be all images for needing to identify, be also possible to need to know
One or more image in other image.
102, using the face in concatenated convolutional neural network recognization images to be recognized.
In the present embodiment, concatenated convolutional neural network is trained in advance, and the training data of concatenated convolutional neural network includes
Face positive sample and face negative sample, face positive sample include first sample (i.e. simple face positive sample) and the second sample
(i.e. complicated face positive sample), face negative sample includes third sample (i.e. simple face negative sample) and the 4th sample is (i.e.
Complicated face negative sample), the set for the image segments that first sample is marked by face callout box, the second sample is and face
The registration of callout box is greater than the set of first threshold and the image segments less than 1, and third sample is the weight with face callout box
The set of the right image segments for being 0, the 4th sample are the figure for being greater than 0 with the registration of face callout box and being less than second threshold
The set of photo section.It is the label that image is beaten that face callout box, which is user, the position for face in tag image.Please refer to figure
5, Fig. 5 be a kind of schematic diagram of image including face callout box provided in an embodiment of the present invention.As shown in figure 5, the packet in figure
Include the box i.e. face callout box of face.First threshold may be the same or different with second threshold.In first threshold and the
In the case that two threshold values are different, first threshold is greater than second threshold.
In the present embodiment, after getting images to be recognized, using in concatenated convolutional neural network recognization images to be recognized
Face, i.e., by images to be recognized input cascade convolutional neural networks, deposited in images to be recognized in the context of a person's face, cascade
Convolutional neural networks export the images to be recognized for marking out face, in the case where face is not present in images to be recognized, cascade
Convolutional neural networks do not export.The all areas of face can be marked out, most of region of face can also be marked out.
Referring to Fig. 6, Fig. 6 is a kind of signal of concatenated convolutional neural network recognization face provided in an embodiment of the present invention
Figure.Concatenated convolutional neural network in Fig. 6 is cascaded by 3 convolutional neural networks.As shown in fig. 6, input picture is inputted
After concatenated convolutional neural network, as face in first convolutional neural networks identification image in concatenated convolutional neural network
All areas simultaneously export after being labeled, it is seen then that and it include multiple callout box in the image of first convolutional neural networks output, this
There may be overlapping between a little callout box, further, since the network structure of first convolutional neural networks is fairly simple, therefore,
Detection accuracy is lower.The image including multiple callout box by first convolutional neural networks output inputs second convolution later
Neural network, second convolutional neural networks to first convolutional neural networks in image mark out as face region again
It is identified, since the accuracy of identification of second convolutional neural networks is higher than the accuracy of identification of first convolutional neural networks, because
This, second convolutional neural networks can filter out the region that the part that first convolutional neural networks identifies is not face,
As it can be seen that in the image that than first convolutional neural networks of callout box in the image of second convolutional neural networks output export
Callout box is few, and the region of mark is also more accurate.The image including callout box that second convolutional neural networks is exported later is defeated
Enter third convolutional neural networks, the picture people that third convolutional neural networks mark out second convolutional neural networks in image
The region of face identified again, due to third convolutional neural networks accuracy of identification than second convolutional neural networks knowledge
Other precision is also high, and therefore, the output of third convolutional neural networks is the facial image for including a callout box, this callout box
Most of region of face is marked out, while also including fraction not is the region of face.
In the face identification method described in Fig. 1, the training data of the concatenated convolutional neural network of face for identification
Including simple face positive sample, simple face negative sample, complicated face positive sample and complexity face negative sample, because
This, the filter capacity of concatenated convolutional neural network that training can be made to obtain i.e. will not it is too poor will not be too strong, so as to put down
The recognition of face efficiency and recognition of face accuracy for the concatenated convolutional neural network that weighs.
Referring to Fig. 2, Fig. 2 is the flow diagram of another face identification method provided in an embodiment of the present invention.According to
Different demands, certain steps in flow chart shown in Fig. 2 can be split as several steps.As shown in Fig. 2, the recognition of face
Method may comprise steps of.
201, the image set including face callout box is obtained.
In the present embodiment, the available image set including face callout box, face callout box is for people in tag image
The position of face.Referring to Fig. 5, Fig. 5 is a kind of schematic diagram of image including face callout box provided in an embodiment of the present invention.Such as
The box including face, that is, face callout box shown in Fig. 5, in figure.Every image in image set includes face.
202, image segments are chosen from the first image, obtains training data.
In the present embodiment, after getting image set, image segments are chosen from the first image and obtain training data, are chosen
Image segments include face callout box marked image segments, be greater than with the registration of face callout box first threshold and small
In 1 image segments, with the registration of face callout box be 0 image segments and with the registration of face callout box be greater than 0
And it is less than the image segments of second threshold.Training data includes face positive sample and face negative sample, and face positive sample includes the
One sample (i.e. simple face positive sample) and the second sample (i.e. complicated face positive sample), face negative sample includes third sample
This (i.e. simple face negative sample) and the 4th sample (i.e. complicated face negative sample), first sample is marked by face callout box
The set of the image segments of note, the second sample are to be greater than first threshold and the image sheet less than 1 with the registration of face callout box
The set of section, third sample are the set for the image segments for being 0 with the registration of face callout box, and the 4th sample is and face mark
The registration for infusing frame is greater than 0 and is less than the set of the image segments of second threshold.First image is any image in image set.
Due to only one face callout box in an image, the quantity of image segments is equal in image set and schemes in first sample
The quantity of picture.Image segments in second sample and the 4th sample are uniformly acquired around face callout box.Second sample
Originally it is acquired from the background in image, can be and uniformly acquire, may not be and uniformly acquire.First threshold and the
Two threshold values may be the same or different.In the case where first threshold is different from second threshold, first threshold is greater than the second threshold
Value.
203, using training data training concatenated convolutional neural network to be trained, concatenated convolutional neural network is obtained.
In the present embodiment, concatenated convolutional neural network is cascaded by M convolutional neural networks, M convolutional neural networks
Complexity successively increase, M is integer more than or equal to 3.Image segments, which are selected, from the first image obtains training data
Later, concatenated convolutional neural network is obtained using training data training concatenated convolutional neural network to be trained, the instruction can be used
Practice first convolutional neural networks in data training concatenated convolutional neural network to be trained, and is instructed using the i-th training data
Practice i-th of convolutional neural networks in concatenated convolutional neural network to be trained, obtains concatenated convolutional neural network.I-th training number
According to the output including first sample, third sample and (i-1)-th convolutional neural networks.The output of (i-1)-th convolutional neural networks
Including the 5th sample and the 6th sample, the 5th sample is the image that callout box is greater than third threshold value with the registration of face callout box
The set of segment, set of the 6th sample for the registration of callout box and face callout box less than the image segments of the 4th threshold value.
Callout box herein i.e. (i-1)-th convolutional neural networks are in the case where identifying image segments includes human face region, for marking
Belong to the callout box of the position of human face region in note image segments.Wherein, i is the integer greater than 1 and less than M+1.Third threshold value
It may be the same or different with first threshold.In the case where third threshold value is different from first threshold, third threshold value is less than
One threshold value.4th threshold value may be the same or different with second threshold.In the 4th threshold value situation different from second threshold
Under, the 4th threshold value is greater than first threshold.But third threshold value needs to be greater than or equal to the 4th threshold value.
In the present embodiment, the ratio etc. of image segments quantity in the face positive sample and face negative sample that training data includes
In the 5th threshold value, the ratio of image segments quantity is equal to the 6th threshold value in the third sample and the 4th sample that training data includes.
The ratio of image segments quantity is equal to the 5th threshold value, the i-th instruction in the face positive sample and face negative sample that i-th training data includes
Practice simple sample and the ratio of image segments quantity in complex samples in the face negative sample that data include and is equal to the 6th threshold value.Letter
Single sample includes the collection of image segments of the registration of callout box and face callout box equal to 0 in third sample and the 6th sample
It closes, complex samples include that the registration of callout box and face callout box in the 6th sample is greater than 0 and less than the image of the 4th threshold value
The set of segment.The registration of callout box and face callout box is greater than in the 6th sample that simple sample includes with complex samples
0 and in the case where being greater than the 6th threshold value less than the ratio of image segments quantity in the set of the image segments of the 4th threshold value, it is complicated
Sample can also include the parts of images segment in the 4th sample.The face positive sample of i-th training data include first sample and
5th sample, in the case where the total number of samples amount of first sample and the 5th sample is inadequate, the face positive sample of the i-th training data
It can also include the parts of images segment in the second sample.Third threshold value can be 1/3, or other values, it can basis
It needs to be configured, this embodiment is not limited.First threshold can be 1, or other values can according to need progress
Setting, this embodiment is not limited.
Referring to Fig. 7, Fig. 7 is the signal that a kind of callout box provided in an embodiment of the present invention and face callout box partially overlap
Figure.As shown in fig. 7, frame where abcd is face callout box, frame where efgh is callout box, and i and j are that callout box and face mark
Two different intersection points of frame.Registration I=(Lei*Lej)/(Lac*Lab+Lef*Leg- of callout box and face callout box
Lei*Lej), wherein length of the Lei between e and i, length of the Lej between e and j, length of the Lac between a and c, Lab
Length between a and b, length of the Lef between e and f, length of the Leg between e and g.
204, images to be recognized is obtained.
In the present embodiment, when needing to identify the face in image, images to be recognized is obtained.Images to be recognized can be this
The image of ground storage is also possible to the image obtained from network or server, can also be through image acquisition device
Image, this embodiment is not limited.Wherein, images to be recognized can be all images for needing to identify, be also possible to need to know
One or more image in other image.
205, using the face in concatenated convolutional neural network recognization images to be recognized.
In the present embodiment, after getting images to be recognized, using in concatenated convolutional neural network recognization images to be recognized
Face, i.e., by images to be recognized input cascade convolutional neural networks, deposited in images to be recognized in the context of a person's face, cascade
Convolutional neural networks export the images to be recognized for marking out face, in the case where face is not present in images to be recognized, cascade
Convolutional neural networks do not export.The all areas of face can be marked out, most of region of face can also be marked out.
Referring to Fig. 6, Fig. 6 is a kind of signal of concatenated convolutional neural network recognization face provided in an embodiment of the present invention
Figure.Concatenated convolutional neural network in Fig. 6 is cascaded by 3 convolutional neural networks.As shown in fig. 6, input picture is inputted
After concatenated convolutional neural network, as face in first convolutional neural networks identification image in concatenated convolutional neural network
All areas simultaneously export after being labeled, it is seen then that and it include multiple callout box in the image of first convolutional neural networks output, this
There may be overlapping between a little callout box, further, since the network structure of first convolutional neural networks is fairly simple, therefore,
Detection accuracy is lower.The image including multiple callout box by first convolutional neural networks output inputs second convolution later
Neural network, second convolutional neural networks to first convolutional neural networks in image mark out as face region again
It is identified, since the accuracy of identification of second convolutional neural networks is higher than the accuracy of identification of first convolutional neural networks, because
This, second convolutional neural networks can filter out the region that the part that first convolutional neural networks identifies is not face,
As it can be seen that in the image that than first convolutional neural networks of callout box in the image of second convolutional neural networks output export
Callout box is few, and the region of mark is also more accurate.The image including callout box that second convolutional neural networks is exported later is defeated
Enter third convolutional neural networks, the picture people that third convolutional neural networks mark out second convolutional neural networks in image
The region of face identified again, due to third convolutional neural networks accuracy of identification than second convolutional neural networks knowledge
Other precision is also high, and therefore, the output of third convolutional neural networks is the facial image for including a callout box, this callout box
Most of region of face is marked out, while also including fraction not is the region of face.
In the face identification method described in Fig. 2, the training data of the concatenated convolutional neural network of face for identification
Including simple face positive sample, simple face negative sample, complicated face positive sample and complexity face negative sample, because
This, the filter capacity of concatenated convolutional neural network that training can be made to obtain i.e. will not it is too poor will not be too strong, so as to put down
The recognition of face efficiency and recognition of face accuracy for the concatenated convolutional neural network that weighs.
Referring to Fig. 3, Fig. 3 is a kind of structural schematic diagram of face identification device provided in an embodiment of the present invention.Such as Fig. 3 institute
Show, which may include:
First acquisition unit 301, for obtaining images to be recognized;
Recognition unit 302, using concatenated convolutional neural network recognization first acquisition unit 301 obtain images to be recognized in
Face;
The training data of concatenated convolutional neural network includes face positive sample and face negative sample, and face positive sample includes the
One sample and the second sample, face negative sample include third sample and the 4th sample, and first sample is marked by face callout box
Image segments set, the second sample is to be greater than first threshold and the image segments less than 1 with the registration of face callout box
Set, third sample is the set for the image segments for being 0 with the registration of face callout box, and the 4th sample is and face marks
The registration of frame is greater than 0 and is less than the set of the image segments of second threshold.
As a kind of possible embodiment, which can also include:
Second acquisition unit 303, for obtaining the image set including face callout box, face callout box is used for tag image
The position of middle face;
Selection unit 304, for choosing the image segments and face mark that face callout box is marked from the first image
The registration of frame is greater than first threshold and image segments less than 1, is 0 with the registration of face callout box image segments and
It is greater than 0 with the registration of face callout box and is less than the image segments of second threshold, obtain training data, the first image is second
Any image in image set that acquiring unit 303 obtains;
Training unit 305, the training data training concatenated convolutional nerve net to be trained for being obtained using selection unit 304
Network obtains concatenated convolutional neural network.
Specifically, the concatenated convolutional neural network recognization images to be recognized that recognition unit 302 is obtained using training unit 305
In face.
As a kind of possible embodiment, concatenated convolutional neural network is cascaded by M convolutional neural networks, and M
The complexity of convolutional neural networks successively increases, and M is the integer more than or equal to 3.
As a kind of possible embodiment, training unit 305 are specifically used for cascading using training data training to training
First convolutional neural networks in convolutional neural networks, and use the i-th training data training concatenated convolutional nerve to be trained
I-th of convolutional neural networks in network, obtain concatenated convolutional neural network, and i is the integer greater than 1 and less than M+1;
I-th training data includes the output of first sample, third sample and (i-1)-th convolutional neural networks.
As a kind of possible embodiment, the output of (i-1)-th convolutional neural networks includes the 5th sample and the 6th sample
This, the 5th sample is greater than the set of the image segments of third threshold value, the 6th sample for the registration of callout box and face callout box
Set for the registration of callout box and face callout box less than the image segments of the 4th threshold value.
As a kind of possible embodiment, image segments in the face positive sample and face negative sample that training data includes
The ratio of quantity is equal to the 5th threshold value, the ratio etc. of image segments quantity in the third sample and the 4th sample that training data includes
In the 6th threshold value.
As a kind of possible embodiment, image in the face positive sample and face negative sample that the i-th training data includes
The ratio of number of fragments is equal to the 5th threshold value, in the face negative sample that the i-th training data includes in simple sample and complex samples
The ratio of image segments quantity is equal to the 6th threshold value, and simple sample includes callout box and face mark in third sample and the 6th sample
The set of image segments of the registration equal to 0 of frame is infused, complex samples include callout box and face callout box in the 6th sample
Registration is greater than the set of 0 and the image segments less than the 4th threshold value.
Related above-mentioned first acquisition unit 301, recognition unit 302, second acquisition unit 303, selection unit 304, training
The more detailed descriptions such as unit 305 can be directly direct with reference to the associated description in above-mentioned Fig. 1-embodiment of the method shown in Fig. 2
It obtains, is not added repeats here.
Referring to Fig. 4, Fig. 4 is the structural schematic diagram of another face identification device provided in an embodiment of the present invention.Such as Fig. 4
Shown, which may include processor 401, memory 402 and bus 403.Processor 401 can be one and lead to
With central processing unit (CPU) or multiple CPU, monolithic or muti-piece graphics processor (GPU), microprocessor, the integrated electricity of specific application
Road (application-specific integrated circuit, ASIC), or it is one or more for controlling present invention side
The integrated circuit that case program executes.Memory 402 can be read-only memory (read-only memory, ROM) or can store
The other kinds of static storage device of static information and instruction, random access memory (random access memory,
RAM) or the other kinds of dynamic memory of information and instruction can be stored, is also possible to the read-only storage of electric erazable programmable
Device (Electrically Erasable Programmable Read-Only Memory, EEPROM), CD-ROM
(Compact Disc Read-Only Memory, CD-ROM) or other optical disc storages, optical disc storage (including compression optical disc, swash
Optical disc, optical disc, Digital Versatile Disc, Blu-ray Disc etc.), magnetic disk storage medium or other magnetic storage apparatus or can use
In carry or storage have instruction or data structure form desired program code and can by computer access it is any its
His medium, but not limited to this.Memory 402, which can be, to be individually present, and bus 403 is connected with processor 401.Memory 402
It can also be integrated with processor 401.Bus 403 transmits information between said modules.Wherein:
Batch processing code is stored in memory 402, processor 401 is for calling the program stored in memory 402
Code executes following operation:
Obtain images to be recognized;
Use the face in concatenated convolutional neural network recognization images to be recognized;
The training data of concatenated convolutional neural network includes face positive sample and face negative sample, and face positive sample includes the
One sample and the second sample, face negative sample include third sample and the 4th sample, and first sample is marked by face callout box
Image segments set, the second sample is to be greater than first threshold and the image segments less than 1 with the registration of face callout box
Set, third sample is the set for the image segments for being 0 with the registration of face callout box, and the 4th sample is and face marks
The registration of frame is greater than 0 and is less than the set of the image segments of second threshold.
As a kind of possible embodiment, processor 401 is also used to that the program code stored in memory 402 is called to hold
The following operation of row:
Obtain the image set including face callout box, position of the face callout box for face in tag image;
Image segments that face callout box marked are chosen from the first image, are greater than the with the registration of face callout box
The image segments that the registration of one threshold value and image segments and face callout box less than 1 is 0 and the weight with face callout box
The right image segments for being greater than 0 and being less than second threshold, obtain training data, and the first image is any image in image set;
Using training data training concatenated convolutional neural network to be trained, concatenated convolutional neural network is obtained.
As a kind of possible embodiment, concatenated convolutional neural network is cascaded by M convolutional neural networks, and M
The complexity of convolutional neural networks successively increases, and M is the integer more than or equal to 3.
As a kind of possible embodiment, processor 401 uses training data training concatenated convolutional nerve net to be trained
Network, obtaining concatenated convolutional neural network includes:
Using first convolutional neural networks in training data training concatenated convolutional neural network to be trained, and use
I-th of convolutional neural networks in i-th training data training concatenated convolutional neural network to be trained, obtain concatenated convolutional nerve net
Network, i are the integer greater than 1 and less than M+1;
I-th training data includes the output of first sample, third sample and (i-1)-th convolutional neural networks.
As a kind of possible embodiment, the output of (i-1)-th convolutional neural networks includes the 5th sample and the 6th sample
This, the 5th sample is greater than the set of the image segments of third threshold value, the 6th sample for the registration of callout box and face callout box
Set for the registration of callout box and face callout box less than the image segments of the 4th threshold value.
As a kind of possible embodiment, image segments in the face positive sample and face negative sample that training data includes
The ratio of quantity is equal to the 5th threshold value, the ratio etc. of image segments quantity in the third sample and the 4th sample that training data includes
In the 6th threshold value.
As a kind of possible embodiment, image in the face positive sample and face negative sample that the i-th training data includes
The ratio of number of fragments is equal to the 5th threshold value, in the face negative sample that the i-th training data includes in simple sample and complex samples
The ratio of image segments quantity is equal to the 6th threshold value, and simple sample includes callout box and face mark in third sample and the 6th sample
The set of image segments of the registration equal to 0 of frame is infused, complex samples include callout box and face callout box in the 6th sample
Registration is greater than the set of 0 and the image segments less than the 4th threshold value.
Wherein, step 101-102, step 201-205 can be by the processor 401 and memory in face identification device
402 execute.
Wherein, first acquisition unit 301, recognition unit 302, second acquisition unit 303, selection unit 304 and training are single
Member 305 can by face identification device processor 401 and memory 402 realize.
Above-mentioned face identification device can be also used for executing the various methods executed in preceding method embodiment, no longer superfluous
It states.
A kind of readable storage medium storing program for executing is provided in one embodiment, which is used to store application program,
Application program for executing the face identification method of Fig. 1 or Fig. 2 at runtime.
A kind of application program is provided in one embodiment, and the application program for executing Fig. 1's or Fig. 2 at runtime
Face identification method.
Those of ordinary skill in the art will appreciate that all or part of the steps in the various methods of above-described embodiment is can
It is completed with instructing relevant hardware by program, which can store in computer readable storage medium, and storage is situated between
Matter may include: flash disk, read-only memory (Read-Only Memory, ROM), random access device (Random Access
Memory, RAM), disk or CD etc..
The embodiment of the present invention has been described in detail above, specific case used herein to the principle of the present invention and
Embodiment is expounded, and the above description of the embodiment is only used to help understand the method for the present invention and its core ideas;
At the same time, for those skilled in the art can in specific embodiments and applications according to the thought of the present invention
There is change place, in conclusion the contents of this specification are not to be construed as limiting the invention.
Claims (10)
1. a kind of face identification method characterized by comprising
Obtain images to be recognized;
Use the face in images to be recognized described in concatenated convolutional neural network recognization;
The training data of the concatenated convolutional neural network includes face positive sample and face negative sample, the face positive sample packet
First sample and the second sample are included, the face negative sample includes third sample and the 4th sample, and the first sample is face
The set for the image segments that callout box is marked, second sample are to be greater than the first threshold with the registration of the face callout box
The set of value and the image segments less than 1, the third sample are the image segments for being 0 with the registration of the face callout box
Set, the 4th sample is the image segments for being greater than 0 with the registration of the face callout box and being less than second threshold
Set.
2. the method according to claim 1, wherein the method also includes:
Obtain the image set including face callout box, position of the face callout box for face in tag image;
The registration that image segments and the face callout box that face callout box is marked are chosen from the first image is greater than institute
State first threshold and be 0 less than 1 image segments, with the registration of the face callout box image segments and with the people
The registration of face callout box is greater than 0 and is less than the image segments of the second threshold, obtains the training data, first figure
Any image as being described image concentration;
Using training data training concatenated convolutional neural network to be trained, the concatenated convolutional neural network is obtained.
3. according to the method described in claim 2, it is characterized in that, the concatenated convolutional neural network is by M convolutional Neural net
Network cascades, and the complexity of the M convolutional neural networks successively increases, and the M is the integer more than or equal to 3.
4. according to the method described in claim 3, it is characterized in that, described rolled up using training data training to training cascade
Product neural network, obtaining the concatenated convolutional neural network includes:
Using first convolutional neural networks in training data training concatenated convolutional neural network to be trained, and use
I-th of convolutional neural networks in the i-th training data training concatenated convolutional neural network to be trained obtain the cascade volume
Product neural network, the i are the integer greater than 1 and less than M+1;
I-th training data includes the output of the first sample, the third sample and (i-1)-th convolutional neural networks.
5. according to the method described in claim 4, it is characterized in that, the output of (i-1)-th convolutional neural networks includes the
Five samples and the 6th sample, the 5th sample are the figure that callout box is greater than third threshold value with the registration of the face callout box
The set of photo section, image sheet of the 6th sample for the registration of callout box and the face callout box less than the 4th threshold value
The set of section.
6. according to the method described in claim 5, it is characterized in that, face positive sample and face that the training data includes are negative
The ratio of image segments quantity is equal to the 5th threshold value in sample, the third sample that the training data includes and schemes in the 4th sample
The ratio of photo segment number is equal to the 6th threshold value.
7. according to the method described in claim 6, it is characterized in that, face positive sample that i-th training data includes and people
The ratio of image segments quantity is equal to the 5th threshold value, the face negative sample that i-th training data includes in face negative sample
The ratio of image segments quantity is equal to the 6th threshold value in middle simple sample and complex samples, and the simple sample includes described
The set of image segments of the registration of callout box and the face callout box equal to 0 in third sample and the 6th sample,
The complex samples include that the registration of callout box and face callout box in the 6th sample is greater than 0 and is less than the 4th threshold
The set of the image segments of value.
8. a kind of face identification device characterized by comprising
First acquisition unit, for obtaining images to be recognized;
Recognition unit, for use first acquisition unit described in concatenated convolutional neural network recognization obtain images to be recognized in
Face;
The training data of the concatenated convolutional neural network includes face positive sample and face negative sample, the face positive sample packet
First sample and the second sample are included, the face negative sample includes third sample and the 4th sample, and the first sample is face
The set for the image segments that callout box is marked, second sample are to be greater than the first threshold with the registration of the face callout box
The set of value and the image segments less than 1, the third sample are the image segments for being 0 with the registration of the face callout box
Set, the 4th sample is the image segments for being greater than 0 with the registration of the face callout box and being less than second threshold
Set.
9. a kind of face identification device, which is characterized in that including processor and memory, the processor and the memory phase
It connects, wherein the memory is for storing computer program, and the computer program includes program instruction, the processing
Device is for calling the described program instruction execution such as described in any item face identification methods of claim 1-7.
10. a kind of storage medium, which is characterized in that the storage medium is stored with computer program, the computer program packet
Program instruction is included, described program instruction executes the processor such as any one of claim 1-7 institute
The face identification method stated.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811596767.XA CN109784207B (en) | 2018-12-26 | 2018-12-26 | Face recognition method, device and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811596767.XA CN109784207B (en) | 2018-12-26 | 2018-12-26 | Face recognition method, device and medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109784207A true CN109784207A (en) | 2019-05-21 |
CN109784207B CN109784207B (en) | 2020-11-24 |
Family
ID=66498173
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811596767.XA Active CN109784207B (en) | 2018-12-26 | 2018-12-26 | Face recognition method, device and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109784207B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110879972A (en) * | 2019-10-24 | 2020-03-13 | 深圳云天励飞技术有限公司 | Face detection method and device |
CN111160263A (en) * | 2019-12-30 | 2020-05-15 | 中国电子科技集团公司信息科学研究院 | Method and system for obtaining face recognition threshold |
CN115050086A (en) * | 2022-08-15 | 2022-09-13 | 北京百度网讯科技有限公司 | Sample image generation method, model training method, image processing method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150347822A1 (en) * | 2014-05-29 | 2015-12-03 | Beijing Kuangshi Technology Co., Ltd. | Facial Landmark Localization Using Coarse-to-Fine Cascaded Neural Networks |
US20160180194A1 (en) * | 2014-12-23 | 2016-06-23 | Qualcomm Incorporated | Systems and methods for identifying a region of an image |
CN107145833A (en) * | 2017-04-11 | 2017-09-08 | 腾讯科技(上海)有限公司 | The determination method and apparatus of human face region |
CN107871102A (en) * | 2016-09-23 | 2018-04-03 | 北京眼神科技有限公司 | A kind of method for detecting human face and device |
CN108898547A (en) * | 2018-06-27 | 2018-11-27 | 太原理工大学 | A kind of facial image virtual sample extending method and system based on single sample |
-
2018
- 2018-12-26 CN CN201811596767.XA patent/CN109784207B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150347822A1 (en) * | 2014-05-29 | 2015-12-03 | Beijing Kuangshi Technology Co., Ltd. | Facial Landmark Localization Using Coarse-to-Fine Cascaded Neural Networks |
US20160180194A1 (en) * | 2014-12-23 | 2016-06-23 | Qualcomm Incorporated | Systems and methods for identifying a region of an image |
CN107871102A (en) * | 2016-09-23 | 2018-04-03 | 北京眼神科技有限公司 | A kind of method for detecting human face and device |
CN107145833A (en) * | 2017-04-11 | 2017-09-08 | 腾讯科技(上海)有限公司 | The determination method and apparatus of human face region |
CN108898547A (en) * | 2018-06-27 | 2018-11-27 | 太原理工大学 | A kind of facial image virtual sample extending method and system based on single sample |
Non-Patent Citations (2)
Title |
---|
ZEKUN HAO 等: "Scale-Aware Face Detection", 《ARXIV》 * |
余飞等: "多级联卷积神经网络人脸检测", 《五邑大学学报》 * |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110879972A (en) * | 2019-10-24 | 2020-03-13 | 深圳云天励飞技术有限公司 | Face detection method and device |
CN111160263A (en) * | 2019-12-30 | 2020-05-15 | 中国电子科技集团公司信息科学研究院 | Method and system for obtaining face recognition threshold |
CN111160263B (en) * | 2019-12-30 | 2023-09-05 | 中国电子科技集团公司信息科学研究院 | Method and system for acquiring face recognition threshold |
CN115050086A (en) * | 2022-08-15 | 2022-09-13 | 北京百度网讯科技有限公司 | Sample image generation method, model training method, image processing method and device |
Also Published As
Publication number | Publication date |
---|---|
CN109784207B (en) | 2020-11-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110210542B (en) | Picture character recognition model training method and device and character recognition system | |
CN109784207A (en) | A kind of face identification method and device | |
CN105955962B (en) | The calculation method and device of topic similarity | |
CN107832725A (en) | Video front cover extracting method and device based on evaluation index | |
CN110399890A (en) | Image-recognizing method, device, electronic equipment and readable storage medium storing program for executing | |
CN109712144A (en) | Processing method, training method, equipment and the storage medium of face-image | |
CN111723856B (en) | Image data processing method, device, equipment and readable storage medium | |
CN109934198A (en) | Face identification method and device | |
CN109583297A (en) | Retina OCT volume data identification method and device | |
CN109544554A (en) | A kind of segmentation of plant image and blade framework extracting method and system | |
CN109766949A (en) | Convolutional neural networks light weight method, device and electronic equipment | |
CN110264274A (en) | Objective group's division methods, model generating method, device, equipment and storage medium | |
CN109284700B (en) | Method, storage medium, device and system for detecting multiple faces in image | |
CN108665475A (en) | Neural metwork training, image processing method, device, storage medium and electronic equipment | |
CN110210278A (en) | A kind of video object detection method, device and storage medium | |
CN110175990A (en) | Quality of human face image determination method, device and computer equipment | |
CN107704890A (en) | A kind of generation method and device of four-tuple image | |
CN110037680A (en) | The recognition methods of electrocardiogram and device, storage medium, computer equipment | |
CN113887410A (en) | Deep learning-based multi-category food material identification system and method | |
CN110188780A (en) | Method and device for constructing deep learning model for positioning multi-target feature points | |
CN111881706B (en) | Living body detection, image classification and model training method, device, equipment and medium | |
CN109348287A (en) | Video abstraction generating method, device, storage medium and electronic equipment | |
CN106874922A (en) | A kind of method and device for determining service parameter | |
CN113869098A (en) | Plant disease identification method and device, electronic equipment and storage medium | |
WO2014192182A1 (en) | Image processing device, program, storage medium, and image processing method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |