CN108052915A - A kind of method and device that Face datection is carried out to video and is identified - Google Patents
A kind of method and device that Face datection is carried out to video and is identified Download PDFInfo
- Publication number
- CN108052915A CN108052915A CN201711405674.XA CN201711405674A CN108052915A CN 108052915 A CN108052915 A CN 108052915A CN 201711405674 A CN201711405674 A CN 201711405674A CN 108052915 A CN108052915 A CN 108052915A
- Authority
- CN
- China
- Prior art keywords
- face
- video
- video data
- characteristic value
- cryptographic hash
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V40/00—Recognition of biometric, human-related or animal-related patterns in image or video data
- G06V40/10—Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
- G06V40/16—Human faces, e.g. facial parts, sketches or expressions
- G06V40/161—Detection; Localisation; Normalisation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V40/00—Recognition of biometric, human-related or animal-related patterns in image or video data
- G06V40/10—Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
- G06V40/16—Human faces, e.g. facial parts, sketches or expressions
- G06V40/168—Feature extraction; Face representation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V40/00—Recognition of biometric, human-related or animal-related patterns in image or video data
- G06V40/10—Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
- G06V40/16—Human faces, e.g. facial parts, sketches or expressions
- G06V40/172—Classification, e.g. identification
Landscapes
- Engineering & Computer Science (AREA)
- Health & Medical Sciences (AREA)
- Oral & Maxillofacial Surgery (AREA)
- General Health & Medical Sciences (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Television Signal Processing For Recording (AREA)
Abstract
Face datection is carried out to video and know method for distinguishing the present invention provides a kind of, it includes step:Video data are subjected to hardware decoding, and data conversion is carried out to decoded video data, export yuv video data;Yuv video data are converted to BGR video datas;The detection of user's face detection algorithm is detected identification to the face in BGR video datas;Face characteristic value is subjected to hashed, obtains face characteristic cryptographic Hash;Face characteristic cryptographic Hash and the face characteristic cryptographic Hash in the face database that pre-establishes are compared roughly;Face characteristic value in face characteristic value and rough comparison result is subjected to precise alignment;Export comparison result, if human face similarity degree is high, alert.The recognition methods can substitute artificial lookup, effectively save manpower, and greatly improve the speed that target person is searched in video recording, and instant alarming can be generated after recognizing target face.
Description
Technical field
The present invention relates to a kind of Face datection and the method and device that identifies, refer in particular to it is a kind of to video into pedestrian
The method and device that face is detected and identified.
Background technology
Traditional security protection needs manually to go browsing video, the target person being likely to occur from the lookup in video
Object is manually alarmed when finding target person, but more and more wider with the scope of video monitoring, and target person occurs
There is uncertainty in the time of monitoring range, the personage's occurred in monitor video is large number of, depends merely on and lookup is manually gone to regard
The manpower and materials that frequency picture target personage needs expend are also higher and higher, and the attention of people is limited, more in video pictures number
When, target person is easily omitted, and see that video the time it takes cost is also very high again, manually go out to find target person
Reliability it is not high, therefore, in order to improve to video monitoring efficiency, the Realtime Alerts when finding target person, it is necessary to
A kind of method and device that can be carried out Face datection to video and identify is provided.
The content of the invention
The technical problems to be solved by the invention are:It provides and a kind of Face datection is carried out to video and knows method for distinguishing
And device.
In order to solve the above-mentioned technical problem, the technical solution adopted by the present invention is:It is a kind of that face inspection is carried out to video
It surveys and knows method for distinguishing, including step,
S20 video data), are subjected to hardware decoding, and data conversion is carried out to decoded video data,
Export yuv video data;
S30 yuv video data), are converted to BGR video datas;
S40), user's face detection algorithm detection is detected the face in BGR video datas and extracts characteristic value;
S50 face characteristic value), is subjected to hashed, obtains face characteristic cryptographic Hash;
S60), face characteristic cryptographic Hash and the face characteristic cryptographic Hash in the face database that pre-establishes are compared roughly
It is right, then with the characteristic value of the face in face characteristic value and rough comparison result precise alignment is carried out using Euclidean distance;
S70 comparison result, if human face similarity degree is high, alert), are exported;
The step S40 includes,
S41), the position coordinates of the number of face in identification video, the position coordinates of face and face key point, institute
Stating face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth;
S42), according to the position coordinates of face and the position coordinates of face key point, picture is cut by affine transformation, is obtained
To face picture;
S43 face characteristic value), is extracted from the face picture using deep learning algorithm;
The step S60 includes,
S61), known face characteristic cryptographic Hash in face characteristic cryptographic Hash and face database is carried out using Hamming distances thick
It slightly compares, the threshold value that Hamming distances are less than setting had both been the face characteristic cryptographic Hash for the condition that meets;
S62), face characteristic value is compared with the characteristic value of the face in rough comparison result using Euclidean distance,
If Euclidean distance is less than the threshold value of setting, it is judged as human face similarity degree height.
Further, Face datection is carried out to video and knows method for distinguishing, is further included first with the face of known personage
Picture detects face, then extracts characteristic value, and then hashed obtains feature cryptographic Hash, then characteristic value and feature cryptographic Hash
The step being added into face database.
Further, further included before step S20 from hard disk and read video data, including step,
S11 it is), hard according to where timestamp in the video file name of lane database lookup video data and video file
Disk drive number and its deviation post in video file;
S12 video data), are read in the deviation post found out;
S13 frame head data parsing), is carried out to video data, according to frame head data size information, reads corresponding size
Frame video data;
S14), video data are put into buffering area pointed by intelligent pointer, intelligent pointer is put into video pointer
Chained list.
Further, the step S20 includes,
S21 hard decoder parameter), is initialized, the picture format of yuv video data is set as I420, decoded video lattice
Formula is set as h264 or h265;
S22 a video decoded instance), is created, the form for decoded video data is set;
S23 a Video Quality Metric example), is created, event call-back function is set;
S24), it is hit by a bullet out video intelligent pointer from video pointer chained list, the h264 or h265 that then intelligent pointer is directed toward
Video data is sent into Video decoding module and carries out hard decoder;
S25 resolution ratio scaling), is carried out using ffmpeg to decoded yuv video data.
In order to solve the above-mentioned technical problem, another technical solution for using of the present invention for:It is a kind of to video into pedestrian
The device that face is detected and identified, it includes,
Video decoding module, for video data to be carried out hardware decoding, and to decoded video data
Data conversion is carried out, yuv video data is exported, then goes to data conversion module;
Data conversion module for yuv video data to be converted to BGR video datas, then goes to detection and extracts spy
Value indicative module;
Detect and extract characteristic value module, for user's face detection algorithm detection to the face in BGR video datas into
Row detects and extracts characteristic value, then goes to face characteristic value hashed module;
Face characteristic value hashed module for face characteristic value to be carried out hashed, obtains face characteristic cryptographic Hash, and
After go to face characteristic value comparing module;
Face characteristic value comparing module, for by the face characteristic in face characteristic cryptographic Hash and the face database that pre-establishes
Cryptographic Hash is compared roughly, then with the characteristic value of the face in face characteristic cryptographic Hash and rough comparison result using it is European away from
From precise alignment is carried out, result output module is then gone to;
As a result output module, for exporting comparison result, if human face similarity degree is high, alert;
The detection identification module includes,
Face identification unit, for identifying the position coordinates of the number of the face in video, face and face key point
Position coordinates, the face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth, then go to picture cut it is single
Member;
Picture cuts unit, for the position coordinates according to face and the position coordinates of face key point, passes through affine change
Cutting picture is changed, obtains face picture, then goes to face characteristic extraction unit;
Face characteristic extraction unit, for deep learning algorithm to be used to extract face characteristic value from the face picture;
The face characteristic value comparing module includes,
Hamming distances comparing unit, for face characteristic cryptographic Hash and known face characteristic cryptographic Hash in face database to be made
It being compared roughly with Hamming distances, the threshold value that Hamming distances are less than setting is the face characteristic cryptographic Hash for the condition that meets, and
After go to Euclidean distance comparing unit;
Euclidean distance comparing unit, for face characteristic value to be used Europe with the characteristic value of the face in rough comparison result
Formula distance is compared, if Euclidean distance is less than the threshold value of setting, is judged as human face similarity degree height.
Further, Face datection and the device identified are carried out to video, it is further included,
Face characteristic add module first detects face with the face picture of known personage, then extracts characteristic value, then breathe out
Uncommonization obtains feature cryptographic Hash, then characteristic value and feature cryptographic Hash are added into face database.
Further, Face datection and the device identified are carried out to video, it further includes video read module, bag
It includes,
Video retrieval unit, for searching the video file name and video recording of video data in lane database according to timestamp
Disk identifier of hard disk number and its deviation post in video file where file, then go to video reading unit;
Video reading unit for reading video data in the deviation post found out, then goes to video solution
Analyse unit;
Video parsing unit, for carrying out frame head data parsing to video data, according to frame head data size information,
The video data of the frame of corresponding size are read, then go to intelligent pointer unit;
Intelligent pointer unit, for video data to be put into the buffering area pointed by intelligent pointer, by intelligent pointer
It is put into video pointer chained list.
Further, the Video decoding module includes,
For initializing hard decoder parameter, the picture format of yuv video data is set as parameter initialization unit
I420, decoded video format are set as h264 or h265, then go to decoded instance creating unit;
Decoded instance creating unit, for creating a video decoded instance, decoded video data are wanted in setting
Form then goes to transform instances creating unit;
Transform instances creating unit for creating a Video Quality Metric example, sets event call-back function, then goes to intelligence
It can pointer pop-up unit;
Intelligent pointer pops up unit, for being hit by a bullet out video intelligent pointer from video pointer chained list, then intelligent pointer
H264 the or h265 video datas of direction are sent into Video decoding module and carry out hard decoder, then go to resolution ratio unit for scaling;
Resolution ratio unit for scaling, for carrying out resolution ratio scaling using ffmpeg to decoded yuv video data.
The beneficial effects of the present invention are:Video intelligent analytical technology is employed, reads HD recording video data, then
Hard decoder is carried out, carries out video intelligent analysis after the decoding, face location coordinate is detected by Face datection algorithm, extracts people
Then the characteristic value of face is compared the characteristic value of the face of extraction with face characteristic value known to face database, can be quick
Face is identified, if face and known human face similarity degree that detection recognizes are high, alert.The identification
Method can substitute artificial lookup, effectively save manpower, and greatly improve the speed that target person is searched in video recording.
Description of the drawings
The concrete structure of the present invention is described in detail below in conjunction with the accompanying drawings
Fig. 1 is flow chart of the method for the present invention;
Fig. 2 is the device of the invention module frame chart.
Specific embodiment
In order to describe the technical content, the structural feature, the achieved object and the effect of this invention in detail, below in conjunction with embodiment
And attached drawing is coordinated to be explained in detail.
With reference to figure 1, a kind of technical solution that the present invention uses for:It is a kind of to video carry out Face datection and identify
Method, including step,
S20 video data), are subjected to hardware decoding, and data conversion is carried out to decoded video data,
Export yuv video data;
S30 yuv video data), are converted to BGR video datas;
S40), user's face detection algorithm detection is detected the face in BGR video datas and extracts characteristic value;
S50 face characteristic value), is subjected to hashed, obtains face characteristic cryptographic Hash;
S60), face characteristic cryptographic Hash and the face characteristic cryptographic Hash in the face database that pre-establishes are compared roughly
It is right, then with the characteristic value of the face in face characteristic value and rough comparison result precise alignment is carried out using Euclidean distance;
S70 comparison result, if human face similarity degree is high, alert), are exported;
The step S40 includes,
S41), the position coordinates of the number of face in identification video, the position coordinates of face and face key point, institute
Stating face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth;
S42), according to the position coordinates of face and the position coordinates of face key point, picture is cut by affine transformation, is obtained
To face picture;
S43 face characteristic value), is extracted from the face picture using deep learning algorithm;
The step S60 includes,
S61), known face characteristic cryptographic Hash in face characteristic cryptographic Hash and face database is carried out using Hamming distances thick
It slightly compares, the threshold value that Hamming distances are less than setting had both been the face characteristic cryptographic Hash for the condition that meets;
S62), face characteristic value is compared with the characteristic value of the face in rough comparison result using Euclidean distance,
If Euclidean distance is less than the threshold value of setting, it is judged as human face similarity degree height.
Present invention employs video intelligent analytical technologies, read HD recording video data, then carry out hard decoder, solving
Video intelligent analysis is carried out after code, face location coordinate is detected by Face datection algorithm, extracts the characteristic value of face, then
The characteristic value of the face of extraction with face characteristic value known to face database is compared, quickly face can be identified,
If it detects the face recognized and known human face similarity degree is high, alert.The recognition methods can substitute manually
It searches, effectively saves manpower, and greatly improve the speed that target person is searched in video recording.
Embodiment one
Further, a kind of that Face datection is carried out to video and knows method for distinguishing, it is further included first with known personage
Face picture detection face, then extract characteristic value, then hashed obtains feature cryptographic Hash, then characteristic value and feature
Cryptographic Hash is added into face database.
By this method, a face database is established, by the characteristic value of face, face characteristic cryptographic Hash is added to face database
In, for carrying out comparison identification with the face in video data, the number of the face picture of the known personage in face database
For one or more, face can be different angle face, can effectively improve the accuracy rate of face characteristic comparison.
Embodiment two
Further, further included before step S20 from hard disk and read video data, including step,
S11 it is), hard according to where timestamp in the video file name of lane database lookup video data and video file
Disk drive number and its deviation post in video file;
S12 video data), are read in the deviation post found out;
S13 frame head data parsing), is carried out to video data, according to frame head data size information, reads corresponding size
Frame video data;
S14), video data are put into buffering area pointed by intelligent pointer, intelligent pointer is put into video pointer
Chained list.
By this method, the position of video is read, the disk identifier of hard disk number of video is identified first, then according to right
The deviation post of hard disk where video file is found in the hard disk answered, then read video data, this reading from deviation post
Method is taken, the retrieval rate of the data of video can be effectively improved;Video data are put into pointed by intelligent pointer
Buffering area in, intelligent pointer is put into video pointer chained list, when the video data buffer zone quilt pointed by intelligent pointer
After the completion of calling, when being directed toward it without intelligent pointer, memory release, the convenient pipe to video data can be automatically performed
Reason, and effectively prevent program crashing problem caused by frequently applying for releasing memory between multithreading
Embodiment three
Further, the step S20 includes,
S21 hard decoder parameter), is initialized, the picture format of yuv video data is set as I420, decoded video lattice
Formula is set as h264 or h265;
S22 a video decoded instance), is created, the form for decoded video data is set;
S23 a Video Quality Metric example), is created, event call-back function is set;
S24), it is hit by a bullet out video intelligent pointer from video pointer chained list, the h264 or h265 that then intelligent pointer is directed toward
Video data carries out hard decoder;
S25 resolution ratio scaling), is carried out using ffmpeg to decoded yuv video data.
This method sets decoding parametric, is decoded by the video data being directed toward to video intelligent pointer, right
Decoded yuv video data carry out resolution ratio and zoom in and out, the purpose for reducing yuv video data resolution be in order to reduce after
Phase carries out the occupied expense of intellectual analysis (including CPU overhead, GPU expenses etc.).
With reference to figure 2, another technical solution that the present invention uses for:It is a kind of to video carry out Face datection and identify
Device, it includes,
Video decoding module, for video data to be carried out hardware decoding, and to decoded video data
Data conversion is carried out, yuv video data is exported, then goes to data conversion module;
Data conversion module for yuv video data to be converted to BGR video datas, then goes to detection and extracts spy
Value indicative module;
Detect and extract characteristic value module, for user's face detection algorithm detection to the face in BGR video datas into
Row detects and extracts characteristic value, then goes to face characteristic value hashed module;
Face characteristic value hashed module for face characteristic value to be carried out hashed, obtains face characteristic cryptographic Hash, and
After go to face characteristic value comparing module;
Face characteristic value comparing module, for by the face characteristic in face characteristic cryptographic Hash and the face database that pre-establishes
Cryptographic Hash is compared roughly, then with the characteristic value of the face in face characteristic value and rough comparison result using Euclidean distance into
Row precise alignment then goes to result output module;
As a result output module, for exporting comparison result, if human face similarity degree is high, alert;
The detection identification module includes,
Face identification unit, for identifying the position coordinates of the number of the face in video, face and face key point
Position coordinates, the face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth, then go to picture cut it is single
Member;
Picture cuts unit, for the position coordinates according to face and the position coordinates of face key point, passes through affine change
Cutting picture is changed, obtains face picture, then goes to face characteristic extraction unit;
Face characteristic extraction unit, for deep learning algorithm to be used to extract face characteristic value from the face picture;
The face characteristic value comparing module includes,
Hamming distances comparing unit, for face characteristic cryptographic Hash and known face characteristic cryptographic Hash in face database to be made
It being compared roughly with Hamming distances, the threshold value that Hamming distances are less than setting had both been the face characteristic cryptographic Hash for the condition that meets, and
After go to Euclidean distance comparing unit;
Euclidean distance comparing unit, for face characteristic value to be used Europe with the characteristic value of the face in rough comparison result
Formula distance is compared, if Euclidean distance is less than the threshold value of setting, is judged as human face similarity degree height.
Present invention employs video intelligent analytical technologies, read HD recording video data, then carry out hard decoder, solving
Video intelligent analysis is carried out after code, face location coordinate is detected by Face datection algorithm, extracts the characteristic value of face, then
The characteristic value of the face of extraction with face characteristic value known to face database is compared, quickly face can be identified,
If it detects the face recognized and known human face similarity degree is high, alert.The recognition methods can substitute manually
It searches, effectively saves manpower, and greatly improve the speed that target person is searched in video recording.
Example IV
Further, Face datection and the device identified are carried out to video, it is further included,
Face characteristic add module first detects face with the face picture of known personage, then extracts characteristic value, then breathe out
Uncommonization obtains feature cryptographic Hash, then characteristic value and feature cryptographic Hash are added into face database.
By this method, a face database is established, by the characteristic value of face, face characteristic cryptographic Hash is added to face database
In, for carrying out comparison identification with the face in video data, the number of the face of the known personage in face database is one
It is a or more than one, face can be different angle face, can effectively improve face characteristic comparison accuracy rate.
Embodiment five
Further, Face datection and the device identified are carried out to video, it further includes video read module, bag
It includes,
Video retrieval unit, for searching the video file name and video recording of video data in lane database according to timestamp
Disk identifier of hard disk number and its deviation post in video file where file;
Video reading unit, for reading video data in the deviation post found out;
Video parsing unit, for carrying out frame head data parsing to video data, according to frame head data size information,
Read the video data of the frame of corresponding size;
Intelligent pointer unit, for video data to be put into the buffering area pointed by intelligent pointer, by intelligent pointer
It is put into video pointer chained list.
By this method, the position of video is read, the disk identifier of hard disk number of video is identified first, then according to right
The deviation post of hard disk where video file is found in the hard disk answered, then read video data, this reading from deviation post
Method is taken, the retrieval rate of the data of video can be effectively improved;Video data are put into signified into intelligent pointer
To buffering area, intelligent pointer is put into video pointer chained list, when the video data pointed by intelligent pointer have been called
Cheng Hou when being directed toward it without intelligent pointer, can be automatically performed memory release, the convenient management to video data, and have
Effect applies for program crashing problem caused by releasing memory between avoiding multithreading.
Embodiment six
Further, Face datection is carried out to video and the device identified, the Video decoding module includes,
For initializing hard decoder parameter, the picture format of yuv video data is set as parameter initialization unit
I420, decoded video format are set as h264 or h265;
Decoded instance creating unit, for creating a video decoded instance, decoded video data are wanted in setting
Form;
Transform instances creating unit for creating a Video Quality Metric example, sets event call-back function;
Intelligent pointer pops up unit, for being hit by a bullet out video intelligent pointer from video pointer chained list, then intelligent pointer
H264 the or h265 video datas of direction are sent into Video decoding module and carry out hard decoder;
Resolution ratio unit for scaling, for carrying out resolution ratio scaling using ffmpeg to decoded yuv video data.
This method sets decoding parametric, is decoded by the video data being directed toward to video intelligent pointer, right
Decoded yuv video data carry out resolution ratio and zoom in and out, and reduce the later stage to shared by yuv video data progress intellectual analysis
Resource overhead.
In summary present invention employs video intelligent analytical technology, HD recording video data is read, identification first regards
The disk identifier of hard disk number of frequency, then according to the deviation post of hard disk where video file is found in corresponding hard disk, then from offset
Video data are read in position, and this read method can effectively improve the retrieval rates of the data of video;It will video recording
Video data is put into the buffering area pointed by intelligent pointer, and intelligent pointer is put into video pointer chained list, when intelligent pointer is signified
To video data be called after the completion of, when being directed toward it without intelligent pointer, memory release can be automatically performed, convenient pair
The management of video data, and effectively prevent applying for program crashing problem caused by releasing memory between multithreading.Then it is right
Video data carries out hard decoder, carries out video intelligent analysis after the decoding, detects that face location is sat by Face datection algorithm
Mark extracts the characteristic value of face, and then the characteristic value of the face of extraction is carried out with the face characteristic value of personage known to face database
It compares, quickly face can be identified, if the face that detection recognizes is high with known human face similarity degree, send report
Alert information.The recognition methods can substitute artificial lookup, effectively save manpower, and greatly improve and target person is searched in video recording
The speed of object.
The foregoing is merely the embodiment of the present invention, are not intended to limit the scope of the invention, every to utilize this hair
The equivalent structure or equivalent flow shift that bright specification and accompanying drawing content are made directly or indirectly is used in other relevant skills
Art field, is included within the scope of the present invention.
Claims (8)
1. a kind of carry out Face datection to video and know method for distinguishing, it is characterised in that:Including step,
S20 video data), are subjected to hardware decoding, and decoded video data are carried out with data conversion, output
Yuv video data;
S30 yuv video data), are converted to BGR video datas;
S40), user's face detection algorithm detection is detected the face in BGR video datas and extracts characteristic value;
S50 face characteristic value), is subjected to hashed, obtains face characteristic cryptographic Hash;
S60), face characteristic cryptographic Hash and the face characteristic cryptographic Hash in the face database that pre-establishes are compared roughly, then
With the characteristic value of the face in face characteristic value and rough comparison result precise alignment is carried out using Euclidean distance;
S70 comparison result, if human face similarity degree is high, alert), are exported;
The step S40 includes,
S41), the position coordinates of the number of face in identification video, the position coordinates of face and face key point, the people
Face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth;
S42), according to the position coordinates of face and the position coordinates of face key point, picture is cut by affine transformation, obtains people
Face picture;
S43 face characteristic value), is extracted from the face picture using deep learning algorithm;
The step S60 includes,
S61), known face characteristic cryptographic Hash in face characteristic cryptographic Hash and face database is compared roughly using Hamming distances
Right, the threshold value that Hamming distances are less than setting had both been the face characteristic cryptographic Hash for the condition that meets;
S62), face characteristic value is compared with the characteristic value of the face in rough comparison result using Euclidean distance, if
Euclidean distance is less than the threshold value of setting, then is judged as human face similarity degree height.
2. Face datection is carried out to video as described in claim 1 and knows method for distinguishing, it is characterised in that:Further include elder generation
Face is detected with the face picture of known personage, then extracts characteristic value, then hashed obtains feature cryptographic Hash, then feature
Value and feature cryptographic Hash are added into the step in face database.
3. Face datection is carried out to video as described in claim 1 and knows method for distinguishing, it is characterised in that:In step
It is further included before S20 from hard disk and reads video data, including step,
S11), the hard disk disk according to where timestamp in the video file name of lane database lookup video data and video file
Symbol and its deviation post in video file;
S12 video data), are read in the deviation post found out;
S13 frame head data parsing), is carried out to video data, according to frame head data size information, reads the frame for corresponding to size
Video data;
S14), video data are put into buffering area pointed by intelligent pointer, intelligent pointer is put into video pointer chained list.
4. Face datection is carried out to video as described in claim 1 and knows method for distinguishing, it is characterised in that:The step
S20 includes,
S21 hard decoder parameter), is initialized, the picture format of yuv video data is set as I420, decoded video format is set
It is set to h264 or h265;
S22 a video decoded instance), is created, the form for decoded video data is set;
S23 a Video Quality Metric example), is created, event call-back function is set;
S24), it is hit by a bullet out video intelligent pointer from video pointer chained list, h264 the or h265 videos that then intelligent pointer is directed toward
Data are sent into Video decoding module and carry out hard decoder;
S25 resolution ratio scaling), is carried out using ffmpeg to decoded yuv video data.
5. a kind of device that Face datection is carried out to video and is identified, it is characterised in that:It includes,
Video decoding module for video data to be carried out hardware decoding, and carries out decoded video data
Data conversion exports yuv video data, then goes to data conversion module;
Data conversion module for yuv video data to be converted to BGR video datas, then goes to detection and extracts characteristic value
Module;
It detects and extracts characteristic value module, the face in BGR video datas is examined for the detection of user's face detection algorithm
It surveys and extracts characteristic value, then go to face characteristic value hashed module;
Face characteristic value hashed module for face characteristic value to be carried out hashed, obtains face characteristic cryptographic Hash, then turns
To face characteristic value comparing module;
Face characteristic value comparing module, for by the face characteristic Hash in face characteristic cryptographic Hash and the face database that pre-establishes
Value is compared roughly, then carries out essence using Euclidean distance with the characteristic value of the face in face characteristic value and rough comparison result
It really compares, then goes to result output module;
As a result output module, for exporting comparison result, if human face similarity degree is high, alert;
The detection identification module includes,
Face identification unit, for identifying the position of the position coordinates of the number of the face in video, face and face key point
Coordinate is put, the face key point includes, left eye, right eye, nose, the left corners of the mouth, the right corners of the mouth, then goes to picture and cuts unit;
Picture cuts unit, for the position coordinates according to face and the position coordinates of face key point, is cut out by affine transformation
Picture is cut, obtains face picture, then goes to face characteristic extraction unit;
Face characteristic extraction unit, for deep learning algorithm to be used to extract face characteristic value from the face picture;
The face characteristic value comparing module includes,
Hamming distances comparing unit, for known face characteristic cryptographic Hash in face characteristic cryptographic Hash and face database to be used sea
Prescribed distance is compared roughly, and the threshold value that Hamming distances are less than setting had both been the face characteristic cryptographic Hash for the condition that meets, and was then turned
To Euclidean distance comparing unit;
Euclidean distance comparing unit, for by face characteristic value with the face in rough comparison result characteristic value using it is European away from
From being compared, if Euclidean distance is less than the threshold value of setting, it is judged as human face similarity degree height.
6. Face datection and the device identified are carried out to video as claimed in claim 5, it is characterised in that:It is also wrapped
It includes,
Face characteristic add module first detects face with the face picture of known personage, then extracts characteristic value, then hashed
Feature cryptographic Hash is obtained, then characteristic value and feature cryptographic Hash are added into face database.
7. Face datection and the device identified are carried out to video as claimed in claim 5, it is characterised in that:It is further included
Video read module, including,
Video retrieval unit, for searching the video file name and video file of video data in lane database according to timestamp
The disk identifier of hard disk number at place and its deviation post in video file, then go to video reading unit;
For reading video data in the deviation post found out, it is single then to go to video parsing for video reading unit
Member;
Video parsing unit for carrying out frame head data parsing to video data, according to frame head data size information, is read
The video data of the frame of corresponding size, then go to intelligent pointer unit;
For video data to be put into the buffering area pointed by intelligent pointer, intelligent pointer is put into for intelligent pointer unit
Video pointer chained list.
8. Face datection and the device identified are carried out to video as claimed in claim 5, it is characterised in that:The video
Decoder module includes,
The picture format of yuv video data for initializing hard decoder parameter, is set as I420 by parameter initialization unit, solution
The video format of code is set as h264 or h265, then goes to decoded instance creating unit;
Decoded instance creating unit for creating a video decoded instance, sets the form for wanting decoded video data,
Then go to transform instances creating unit;
Transform instances creating unit for creating a Video Quality Metric example, sets event call-back function, then goes to and intelligently refer to
Pin pops up unit;
Intelligent pointer pops up unit, and for being hit by a bullet out video intelligent pointer from video pointer chained list, then intelligent pointer is directed toward
H264 or h265 video datas be sent into Video decoding module carry out hard decoder, then go to resolution ratio unit for scaling;
Resolution ratio unit for scaling, for carrying out resolution ratio scaling using ffmpeg to decoded yuv video data.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711405674.XA CN108052915A (en) | 2017-12-22 | 2017-12-22 | A kind of method and device that Face datection is carried out to video and is identified |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711405674.XA CN108052915A (en) | 2017-12-22 | 2017-12-22 | A kind of method and device that Face datection is carried out to video and is identified |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108052915A true CN108052915A (en) | 2018-05-18 |
Family
ID=62130453
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711405674.XA Pending CN108052915A (en) | 2017-12-22 | 2017-12-22 | A kind of method and device that Face datection is carried out to video and is identified |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108052915A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109543432A (en) * | 2018-11-23 | 2019-03-29 | 济南中维世纪科技有限公司 | Facial image encrypts anti-tamper and retrieval method in a kind of video |
CN111078914A (en) * | 2019-12-18 | 2020-04-28 | 书行科技(北京)有限公司 | Method and device for detecting repeated pictures |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101420301A (en) * | 2008-04-21 | 2009-04-29 | 林格灵 | Human face recognizing identity authentication system |
CN101547360A (en) * | 2009-05-08 | 2009-09-30 | 南京师范大学 | Localizable video file format and method for collecting data of formatted file |
CN103207898A (en) * | 2013-03-19 | 2013-07-17 | 天格科技(杭州)有限公司 | Method for rapidly retrieving similar faces based on locality sensitive hashing |
CN104394460A (en) * | 2014-11-24 | 2015-03-04 | 深圳市华宝电子科技有限公司 | Audio-video file locating method and device |
CN105046217A (en) * | 2015-07-06 | 2015-11-11 | 江苏先发信息科技有限公司 | Face recognition large data amount concurrency scheme processing method |
CN106169067A (en) * | 2016-07-01 | 2016-11-30 | 恒东信息科技无锡有限公司 | A kind of police dynamic human face of high flux gathers comparison method and system |
CN106600774A (en) * | 2016-12-07 | 2017-04-26 | 深圳市万睿智能科技有限公司 | Face identification gate inhibition control method provided with door opening detection area and system thereof |
CN107230267A (en) * | 2017-05-08 | 2017-10-03 | 谢剑锋 | Intelligence In Baogang Kindergarten based on face recognition algorithms is registered method |
CN107318045A (en) * | 2016-04-27 | 2017-11-03 | 阿里巴巴集团控股有限公司 | The method and device of playing video data stream |
CN107341507A (en) * | 2017-06-20 | 2017-11-10 | 华中科技大学 | A kind of rapid image SIFT feature matching process based on GPU with cascade Hash |
CN107403086A (en) * | 2017-09-13 | 2017-11-28 | 上海中信信息发展股份有限公司 | Purview certification method, apparatus and system |
-
2017
- 2017-12-22 CN CN201711405674.XA patent/CN108052915A/en active Pending
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101420301A (en) * | 2008-04-21 | 2009-04-29 | 林格灵 | Human face recognizing identity authentication system |
CN101547360A (en) * | 2009-05-08 | 2009-09-30 | 南京师范大学 | Localizable video file format and method for collecting data of formatted file |
CN103207898A (en) * | 2013-03-19 | 2013-07-17 | 天格科技(杭州)有限公司 | Method for rapidly retrieving similar faces based on locality sensitive hashing |
CN104394460A (en) * | 2014-11-24 | 2015-03-04 | 深圳市华宝电子科技有限公司 | Audio-video file locating method and device |
CN105046217A (en) * | 2015-07-06 | 2015-11-11 | 江苏先发信息科技有限公司 | Face recognition large data amount concurrency scheme processing method |
CN107318045A (en) * | 2016-04-27 | 2017-11-03 | 阿里巴巴集团控股有限公司 | The method and device of playing video data stream |
CN106169067A (en) * | 2016-07-01 | 2016-11-30 | 恒东信息科技无锡有限公司 | A kind of police dynamic human face of high flux gathers comparison method and system |
CN106600774A (en) * | 2016-12-07 | 2017-04-26 | 深圳市万睿智能科技有限公司 | Face identification gate inhibition control method provided with door opening detection area and system thereof |
CN107230267A (en) * | 2017-05-08 | 2017-10-03 | 谢剑锋 | Intelligence In Baogang Kindergarten based on face recognition algorithms is registered method |
CN107341507A (en) * | 2017-06-20 | 2017-11-10 | 华中科技大学 | A kind of rapid image SIFT feature matching process based on GPU with cascade Hash |
CN107403086A (en) * | 2017-09-13 | 2017-11-28 | 上海中信信息发展股份有限公司 | Purview certification method, apparatus and system |
Non-Patent Citations (2)
Title |
---|
严严等: "基于深度学习的人脸分析研究进展", 《厦门大学学报(自然科学版)》 * |
李慧贞等: "基于WinCE610智能手机视频监控终端软件设计", 《计算机测量与控制》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109543432A (en) * | 2018-11-23 | 2019-03-29 | 济南中维世纪科技有限公司 | Facial image encrypts anti-tamper and retrieval method in a kind of video |
CN111078914A (en) * | 2019-12-18 | 2020-04-28 | 书行科技(北京)有限公司 | Method and device for detecting repeated pictures |
CN111078914B (en) * | 2019-12-18 | 2023-04-18 | 书行科技(北京)有限公司 | Method and device for detecting repeated pictures |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108038462A (en) | A kind of method and device that Face datection is carried out to real-time video and is identified | |
CN109344787B (en) | Specific target tracking method based on face recognition and pedestrian re-recognition | |
CN109858371B (en) | Face recognition method and device | |
Deniz et al. | Fast violence detection in video | |
CN105550257B (en) | A kind of audio/video fingerprint recognition methods and a kind of tamper resistant systems based on audio/video fingerprint Streaming Media | |
US9699419B2 (en) | Image processing apparatus and image processing method | |
Cour et al. | Talking pictures: Temporal grouping and dialog-supervised person recognition | |
Khelifi et al. | Perceptual video hashing for content identification and authentication | |
EP2891990A1 (en) | Method and device for monitoring video digest | |
US10409491B2 (en) | Method of data analysis and extraction for embedded security devices | |
US10635908B2 (en) | Image processing system and image processing method | |
Yu et al. | Exposing frame deletion by detecting abrupt changes in video streams | |
TWI704505B (en) | Face recognition system, establishing data method for face recognition, and face recognizing method thereof | |
CN104298748A (en) | Device and method for face search in videos | |
Tian et al. | A multimodal video copy detection approach with sequential pyramid matching | |
CN108052915A (en) | A kind of method and device that Face datection is carried out to video and is identified | |
CN110210274A (en) | Safety cap detection method, device and computer readable storage medium | |
Mou et al. | Content-based copy detection through multimodal feature representation and temporal pyramid matching | |
Lee et al. | Robust video fingerprinting based on symmetric pairwise boosting | |
KR20200042979A (en) | Method and System for Non-Identification of Personal Information in Imaging Device | |
CN114220136A (en) | Method, system and device for training user behavior recognition model and face recognition | |
Wanjale et al. | Use of haar cascade classifier for face tracking system in real time video | |
CN202979108U (en) | Face identification intelligent camera | |
CN109614893B (en) | Intelligent abnormal behavior track identification method and device based on situation reasoning | |
Yu et al. | Image robust hashing based on DCT sign |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180518 |
|
RJ01 | Rejection of invention patent application after publication |