WO2021004137A1 - Information pushing method and apparatus based on face recognition and computer device - Google Patents

Information pushing method and apparatus based on face recognition and computer device Download PDF

Info

Publication number
WO2021004137A1
WO2021004137A1 PCT/CN2020/087133 CN2020087133W WO2021004137A1 WO 2021004137 A1 WO2021004137 A1 WO 2021004137A1 CN 2020087133 W CN2020087133 W CN 2020087133W WO 2021004137 A1 WO2021004137 A1 WO 2021004137A1
Authority
WO
WIPO (PCT)
Prior art keywords
information
user
face
feature vector
push
Prior art date
Application number
PCT/CN2020/087133
Other languages
French (fr)
Chinese (zh)
Inventor
张娟
Original Assignee
深圳壹账通智能科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳壹账通智能科技有限公司 filed Critical 深圳壹账通智能科技有限公司
Publication of WO2021004137A1 publication Critical patent/WO2021004137A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/16Human faces, e.g. facial parts, sketches or expressions
    • G06V40/168Feature extraction; Face representation

Definitions

  • This application relates to the field of computer technology, and in particular to an information push method, device, computer equipment and storage medium based on face recognition.
  • the existing information push method has a problem that it cannot accurately push information.
  • the embodiments of the application provide an information push method, device, computer equipment and storage medium based on face recognition, which are suitable for the field of artificial intelligence and aim to solve the problem of the inability to accurately push information in the prior art methods .
  • an embodiment of the present application provides an information push method based on face recognition, which includes: if user information input by an administrator is received, extracting a model from each photo of the user information according to a preset vector Extract feature vectors in the, to obtain a feature vector set, where the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; The preset face recognition model and the feature vector set recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
  • an embodiment of the present application provides an information pushing device based on face recognition, which includes: a feature vector extraction unit, configured to extract a model from all users according to a preset vector if the user information input by the administrator is received The feature vector is extracted from each photo of the user information to obtain a feature vector set, wherein the user information includes a plurality of the photos, and each photo corresponds to a user; the face information acquisition unit is used to obtain a feature vector set.
  • the face information recognition unit is used to recognize the face information according to the preset face recognition model and the feature vector set to obtain whether the current user is Is the recognition result of a certain user in the user information;
  • the target push information pushing unit is configured to, if the recognition result is that the current user is a certain user in the user information, information to be pushed from a preset according to the recognition result
  • the target push information matching the face information is acquired from the library to push the current user.
  • an embodiment of the present application further provides a computer device, which includes: one or more processors; a memory; one or more computer programs, wherein the one or more computer programs are stored in the memory And configured to be executed by the one or more processors, and the one or more computer programs are configured to execute an information push method based on face recognition, wherein the information push based on face recognition
  • the method includes the following steps: if the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set, wherein the user information includes multiple For the photos, each of the photos corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; the face information is performed according to the preset face recognition model and the feature vector set Recognition to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is a certain user in the user information, the information to be pushed from the
  • the embodiments of the present application also provide a computer-readable storage medium with a computer program stored on the computer-readable storage medium, and when the computer program is executed by a processor, a type of information push based on face recognition is realized
  • the method wherein the information push method based on face recognition includes the following steps: if the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain A feature vector set, wherein the user information includes a plurality of the photos, each of the photos corresponds to a user; if the preset information push time point is reached, the current user's face information is obtained; according to the preset face recognition model And the feature vector set to recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is a certain user in the user information The user obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result
  • the embodiment of the present application can obtain target push information matching user information based on the face recognition technology through the above method, so as to realize accurate push of information and greatly improve the effect of pushing information.
  • FIG. 1 is a schematic flowchart of an information push method based on face recognition provided by an embodiment of the application
  • FIG. 2 is a schematic diagram of a sub-process of a method for pushing information based on face recognition provided by an embodiment of the application;
  • FIG. 3 is a schematic diagram of another sub-flow of the method for pushing information based on face recognition according to an embodiment of the application;
  • FIG. 4 is a schematic diagram of another process of the method for pushing information based on face recognition provided by an embodiment of the application;
  • FIG. 5 is a schematic diagram of another sub-flow of the method for pushing information based on face recognition according to an embodiment of the application;
  • FIG. 6 is a schematic block diagram of an information pushing device based on face recognition provided by an embodiment of the application.
  • Fig. 7 is a schematic block diagram of a subunit of a face recognition-based information pushing device provided by an embodiment of the application.
  • FIG. 8 is a schematic block diagram of another subunit of the information pushing device based on face recognition according to an embodiment of the application.
  • FIG. 9 is another schematic block diagram of an information push device based on face recognition provided by an embodiment of the application.
  • FIG. 10 is a schematic block diagram of another subunit of the information pushing device based on face recognition according to an embodiment of the application.
  • FIG. 11 is a schematic block diagram of a computer device provided by an embodiment of the application.
  • FIG. 1 is a schematic flowchart of a method for pushing information based on face recognition provided by an embodiment of the present application.
  • the information push method based on face recognition is applied to a user terminal, and the method is executed by application software installed in the user terminal.
  • the user terminal is used to execute the information push method based on face recognition to push information Terminal equipment.
  • the user terminal is a terminal equipment with camera or video function.
  • the above-mentioned information push method based on face recognition can be applied to vehicles that have been set up to push user terminals such as pictures and videos, such as high-speed trains, airplanes, etc. .
  • the method includes steps S110 to S140.
  • a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set.
  • User information can be uniformly input to the user terminal by the administrator.
  • the administrator is the person who inputs user information and manages the pushed information.
  • the administrator can be the staff on the plane, the staff on the high-speed rail, etc.
  • the user needs to provide detailed information when ticket information).
  • the input user information includes multiple users' information
  • a user's information includes a photo of the user (such as the user's ID photo) and the user's personal information
  • the user's personal information includes gender , Age, education, marriage, occupation and residence information.
  • the feature vector corresponding to each user can be obtained from the photos contained in the user information, and all feature vectors can be obtained to obtain the feature vector set.
  • the vector extraction model includes vector conversion rules and feature vector calculations Formula, the feature vector set contains the feature vector corresponding to each photo in the user information.
  • the feature vector can be used to digitize each photo in the user information. Based on the above feature vector set, the photos of other users are calculated and analyzed. It is the specific process of face recognition.
  • step S110 includes sub-steps S111, S112, and S113.
  • Decolorization processing is performed on each photo in the user information to obtain a photo collection.
  • the photos included in the user information are all color photos.
  • the photos can be decolorized to obtain decolorized photos containing only grayscale pixels. After all photos are decolorized, the photo collection can be obtained.
  • S112 Convert the photos in the photo set according to the vector conversion rule in the vector extraction model to obtain a vector set.
  • the photos in the photo collection are converted according to the vector conversion rules in the vector extraction model to obtain a vector collection.
  • the vector conversion rule is the conversion rule used to convert the decolorized photos in the photo collection to obtain a one-dimensional vector.
  • the decolorized photo contains multiple pixels, and each pixel corresponds to a gray value. That is, each pixel in the decolorized photo can be represented by a numerical value.
  • the gray value is represented by a non-negative integer
  • the value range of the corresponding gray value of the pixel is [0, 255]
  • a gray value of 0 indicates that the pixel is black
  • a gray value of 255 indicates that the pixel If the point is white, and the gray value is other values, the pixel point is a specific gray level between white and black.
  • S113 Calculate the feature vector corresponding to each photo according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  • the feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  • the feature vector calculation formula is a formula used to calculate the vector set to obtain the feature vector corresponding to each photo.
  • the preset information push time point can be a certain time node when the user uses the application in the user terminal, for example, the information push time point preset by the user before playing the video through the video player program, or the time point preset in the terminal display on the flight or high-speed rail.
  • the set information push time point When the preset information push time point is reached, the current user’s face information can be acquired through the image acquisition device in the user terminal.
  • the image acquisition device can acquire pictures or videos.
  • the image acquisition device can be a camera in the user terminal. A picture obtained or a picture intercepted from a video is used as the face information of the current user.
  • S130 Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information.
  • the face recognition model is a model used to identify whether the acquired face information is a certain user in the user information.
  • the face recognition model includes vector extraction rules, difference calculation formulas and difference thresholds.
  • step S130 includes sub-steps S131, S132, and S133.
  • the face information includes an acquired picture
  • the vector extraction rules can extract the face feature vector corresponding to the face information from the picture.
  • the specific steps include cropping the size of the photo
  • the face feature vector ⁇ x corresponding to the photo is obtained, and the face feature vector ⁇ x is a 1 ⁇ N one-dimensional vector.
  • the decolorized photo corresponding to the face information contains multiple pixels, and each pixel corresponds to a gray value.
  • each pixel in the decolorized photo can be represented by a numerical value, and the facial feature vector is extracted
  • the specific process is the same as the step of obtaining the one-dimensional vector corresponding to each photo from the photo collection, and will not be repeated here.
  • S132 Calculate the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model.
  • the difference value between the face feature vector and each feature vector in the feature vector set is calculated according to the difference calculation formula in the face recognition model.
  • the difference calculation formula is the calculation formula used to calculate the difference between the face feature vector and each feature vector in the feature vector set.
  • the difference between the face feature vector and the feature vector can be used to determine the difference between the face information and the feature vector.
  • the difference is quantified. The smaller the difference value, the more similar the face information and the photo corresponding to the feature vector.
  • 2 , ⁇ x is the face feature vector, ⁇ i is the difference value between the face feature vector and the i-th feature vector in the feature vector set, and ⁇ i is the feature The i-th feature vector in the vector set.
  • the face feature vector ⁇ x is a 1 ⁇ N one-dimensional vector, and ⁇ i is also a 1 ⁇ N one-dimensional vector.
  • the difference calculation formula is to calculate the Euclidean distance of the above two vectors.
  • the difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information.
  • the recognition result can be obtained by judging the difference value corresponding to each feature vector through the difference threshold.
  • the recognition result is that the current user is a certain user in the user information; if the difference value corresponding to all feature vectors is not less than the difference threshold, it indicates that the photo in the face information matches the photo in the user information failed to match , The recognition result is that the current user is not a certain user in the user information; if the difference value corresponding to multiple feature vectors is smaller than the difference threshold, it indicates that the photo in the obtained face information is not a face, The recognition result is also that the current user is not a certain user in the user information.
  • the recognition result is that the current user is the user The third user in the message.
  • step S130 a step S130a is further included.
  • S130a If the recognition result is that the current user is not a certain user in the user information, send a prompt message to the current user to obtain face information again and obtain the face information of the current user again.
  • a prompt message for obtaining the face information again is issued to the current user and the face information of the current user is obtained again. If the recognition result is that the current user is not a certain user in the user information, a prompt message may be sent to the current user to obtain the face information of the current user again. After obtaining the new face information, the new face information can be recognized again by the above method to obtain the recognition result.
  • the recognition result is that the current user is a certain user in the user information
  • the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it.
  • the information library to be pushed is an information library for storing information to be pushed.
  • the information library to be pushed contains multiple information push categories and user classification rules, and each information push category contains at least one piece of information to be pushed.
  • Information, the information to be pushed in the information database to be pushed can be files such as pictures, videos, audios, etc.
  • the target push information that matches the facial information can be obtained, and the target push information is displayed to the current user in the user terminal. Pushing to achieve accurate information push can greatly improve the effect of information push.
  • step S140 includes sub-steps S141, S142, and S143.
  • the user information includes multiple users' information.
  • a user's information includes a photo of the user (for example, a photo of the user's ID card) and personal information of the user.
  • the personal information includes gender, age, Education, marriage, occupation and residence information, etc. According to the recognition result, the personal information corresponding to the face information can be obtained from the user information.
  • the recognition result is that the current user is the third user in the user information
  • the personal information of the third user in the user information includes gender: male, age: 29, education: high school, marriage: unmarried, occupation: White-collar workers can use the above personal information as personal information corresponding to the face information.
  • Each information push category corresponds to a user group, and each information push category contains at least one piece of information to be pushed, that is, through information Push category can classify all the information to be pushed contained in the information database to be pushed.
  • a user group matching the personal information can be obtained, and each user group corresponds to an information push category, that is, the target user group, specifically,
  • users can be classified into the first category according to age, users are classified into the first category of the first category according to gender, and users are classified into the first subcategory of the first category according to marriage and love.
  • users are classified into the first sub-category in the first sub-category, and a user group matching the user in the first sub-category is obtained as the target user group according to the educational background.
  • the target user group can be matched with After the user corresponding to the personal information is classified, the target user group matching the user is obtained as the user group d1H6p.
  • the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user. Since each user group corresponds to an information push category, after obtaining the target user group that matches the personal information, obtain the information to be pushed contained in the information push category corresponding to the target user group, and you can get the information that matches the personal information Target push information, where the target push information contains at least one piece of information to be pushed, and the target push information is sequentially pushed in the user terminal to the current user to achieve accurate push of the information.
  • the information to be pushed contained in the information push category is used as the target push information that matches the above personal information and pushes the current user.
  • the feature vector set is extracted from the user information input by the administrator according to the vector extraction model, and the current user is automatically acquired when the preset information push time point is reached. According to the recognition result, obtain the target push information from the preset to-be-push information database and push the current user.
  • the above method it is possible to obtain target push information that matches the user information based on the face recognition technology, so as to achieve accurate push of information, which greatly improves the push effect of information.
  • the embodiment of the present application also provides an information pushing device based on face recognition, and the information pushing device based on face recognition is used to execute any embodiment of the aforementioned information pushing method based on face recognition.
  • FIG. 6, is a schematic block diagram of an information pushing device based on face recognition provided by an embodiment of the present application.
  • the information pushing device based on face recognition can be configured in a user terminal.
  • the information pushing device 100 based on face recognition includes a feature vector extraction unit 110, a face information acquisition unit 120, a face information recognition unit 130 and a target push information pushing unit 140.
  • the feature vector extraction unit 110 is configured to, if user information input by the administrator is received, extract feature vectors from each photo of the user information according to a preset vector extraction model to obtain a feature vector set.
  • a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set.
  • User information can be uniformly input to the user terminal by the administrator.
  • the administrator is the person who inputs user information and manages the pushed information.
  • the administrator can be the staff on the plane, the staff on the high-speed rail, etc.
  • the user needs to provide detailed information when ticket information).
  • the input user information includes multiple users' information
  • a user's information includes a photo of the user (such as the user's ID photo) and the user's personal information
  • the user's personal information includes gender , Age, education, marriage, occupation and residence information.
  • the feature vector corresponding to each user can be obtained from the photos contained in the user information, and all feature vectors can be obtained to obtain the feature vector set.
  • the vector extraction model includes vector conversion rules and feature vector calculations Formula, the feature vector set contains the feature vector corresponding to each photo in the user information.
  • the feature vector can be used to digitize each photo in the user information. Based on the above feature vector set, the photos of other users are calculated and analyzed. It is the specific process of face recognition.
  • the feature vector extraction unit 110 includes sub-units: a decolorization unit 111, a vector conversion unit 112 and a feature vector calculation unit 113.
  • the decolorization unit 111 is configured to decolorize each photo in the user information to obtain a photo collection.
  • Decolorization processing is performed on each photo in the user information to obtain a photo collection.
  • the photos included in the user information are all color photos.
  • the photos can be decolorized to obtain decolorized photos containing only grayscale pixels. After all photos are decolorized, the photo collection can be obtained.
  • the vector conversion unit 112 is configured to convert the photos in the photo set according to the vector conversion rules in the vector extraction model to obtain a vector set.
  • the photos in the photo collection are converted according to the vector conversion rules in the vector extraction model to obtain a vector collection.
  • the vector conversion rule is the conversion rule used to convert the decolorized photos in the photo collection to obtain a one-dimensional vector.
  • the decolorized photo contains multiple pixels, and each pixel corresponds to a gray value. That is, each pixel in the decolorized photo can be represented by a numerical value.
  • the gray value is represented by a non-negative integer
  • the value range of the corresponding gray value of the pixel is [0, 255]
  • a gray value of 0 indicates that the pixel is black
  • a gray value of 255 indicates that the pixel If the point is white, and the gray value is other values, the pixel point is a specific gray level between white and black.
  • the feature vector calculation unit 113 is configured to calculate the feature vector corresponding to each photo according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  • the feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  • the feature vector calculation formula is a formula used to calculate the vector set to obtain the feature vector corresponding to each photo.
  • the face information acquiring unit 120 is configured to acquire the face information of the current user if the preset information push time point is reached.
  • the preset information push time point can be a certain time node when the user uses the application in the user terminal, for example, the information push time point preset by the user before playing the video through the video player program, or the time point preset in the terminal display on the flight or high-speed rail.
  • the set information push time point When the preset information push time point is reached, the current user’s face information can be acquired through the image acquisition device in the user terminal.
  • the image acquisition device can acquire pictures or videos.
  • the image acquisition device can be a camera in the user terminal. A picture obtained or a picture intercepted from a video is used as the face information of the current user.
  • the face information recognition unit 130 is configured to recognize the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information.
  • the face recognition model is a model used to identify whether the acquired face information is a certain user in the user information.
  • the face recognition model includes vector extraction rules, difference calculation formulas and difference thresholds.
  • the face information recognition unit 130 includes sub-units: a face feature vector acquisition unit 131, a vector difference value calculation unit 132 and a difference value judgment unit 133.
  • the face feature vector acquiring unit 131 is configured to acquire the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model.
  • the face information includes an acquired picture
  • the vector extraction rules can extract the face feature vector corresponding to the face information from the picture.
  • the specific steps include cropping the size of the photo
  • the face feature vector ⁇ x corresponding to the photo is obtained, and the face feature vector ⁇ x is a 1 ⁇ N one-dimensional vector.
  • the decolorized photo corresponding to the face information contains multiple pixels, and each pixel corresponds to a gray value.
  • each pixel in the decolorized photo can be represented by a numerical value, and the facial feature vector is extracted
  • the specific process is the same as the step of obtaining the one-dimensional vector corresponding to each photo from the photo collection, and will not be repeated here.
  • the vector difference value calculation unit 132 is configured to calculate the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model.
  • the difference value between the face feature vector and each feature vector in the feature vector set is calculated according to the difference calculation formula in the face recognition model.
  • the difference calculation formula is the calculation formula used to calculate the difference between the face feature vector and each feature vector in the feature vector set.
  • the difference between the face feature vector and the feature vector can be used to determine the difference between the face information and the feature vector.
  • the difference is quantified. The smaller the difference value, the more similar the face information and the photo corresponding to the feature vector.
  • 2 , ⁇ x is the face feature vector, ⁇ i is the difference value between the face feature vector and the i-th feature vector in the feature vector set, and ⁇ i is the feature The i-th feature vector in the vector set.
  • the face feature vector ⁇ x is a 1 ⁇ N one-dimensional vector, and ⁇ i is also a 1 ⁇ N one-dimensional vector.
  • the difference calculation formula is to calculate the Euclidean distance of the above two vectors.
  • the difference value judgment unit 133 is configured to judge the difference value corresponding to each feature vector according to the difference threshold value in the face recognition model to obtain whether the current user in the user information is in the user information The recognition result of a certain user.
  • the difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information.
  • the recognition result can be obtained by judging the difference value corresponding to each feature vector through the difference threshold.
  • the recognition result is that the current user is a certain user in the user information; if the difference value corresponding to all feature vectors is not less than the difference threshold, it indicates that the photo in the face information matches the photo in the user information failed to match , The recognition result is that the current user is not a certain user in the user information; if the difference value corresponding to multiple feature vectors is smaller than the difference threshold, it indicates that the photo in the obtained face information is not a face, The recognition result is also that the current user is not a certain user in the user information.
  • the information pushing device 100 based on face recognition further includes a subunit: a face information reacquiring unit 130a.
  • the face information reacquiring unit 130a is configured to, if the recognition result is that the current user is not a certain user in the user information, send a prompt message to the current user to obtain face information again and obtain the current user’s information again. Face information.
  • a prompt message for obtaining the face information again is issued to the current user and the face information of the current user is obtained again. If the recognition result is that the current user is not a certain user in the user information, a prompt message may be sent to the current user to obtain the face information of the current user again. After obtaining the new face information, the new face information can be recognized again by the above method to obtain the recognition result.
  • the target push information playback unit 140 is configured to, if the recognition result is that the current user is a certain user in the user information, obtain the information that matches the face information from a preset to-be-push information database according to the recognition result The target pushes information to push the current user.
  • the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it.
  • the information library to be pushed is an information library for storing information to be pushed.
  • the information library to be pushed contains multiple information push categories and user classification rules, and each information push category contains at least one piece of information to be pushed.
  • Information, the information to be pushed in the information database to be pushed can be files such as pictures, videos, audios, etc.
  • the target push information that matches the facial information can be obtained, and the target push information is displayed to the current user in the user terminal. Pushing to achieve accurate information push can greatly improve the effect of information push.
  • the target push information playing unit 140 includes sub-units: a personal information acquisition unit 141, a user group matching unit 142, and a target push information acquisition unit 143.
  • the personal information obtaining unit 141 is configured to obtain personal information corresponding to the face information in the user information according to the recognition result.
  • the user information includes multiple users' information.
  • a user's information includes a photo of the user (for example, a photo of the user's ID card) and personal information of the user.
  • the personal information includes gender, age, Education, marriage, occupation and residence information, etc. According to the recognition result, the personal information corresponding to the face information can be obtained from the user information.
  • the user group matching unit 142 is configured to obtain a user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed.
  • each information push category corresponds to a user group, and each information push category contains at least one piece of information to be pushed, that is, through information Push category can classify all the information to be pushed contained in the information database to be pushed.
  • a user group matching the personal information can be obtained, and each user group corresponds to an information push category, that is, the target user group, specifically,
  • users can be classified into the first category according to age, users are classified into the first category of the first category according to gender, and users are classified into the first subcategory of the first category according to marriage and love.
  • users are classified into the first sub-category in the first sub-category, and a user group matching the user in the first sub-category is obtained as the target user group according to the educational background.
  • the target push information acquiring unit 143 is configured to acquire the to-be-pushed information contained in the push category of the information corresponding to the target user group in the to-be-push information library as target push information to push the current user.
  • the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user. Since each user group corresponds to an information push category, after obtaining the target user group that matches the personal information, obtain the information to be pushed contained in the information push category corresponding to the target user group, and you can get the information that matches the personal information Target push information, where the target push information contains at least one piece of information to be pushed, and the target push information is sequentially pushed in the user terminal to the current user to achieve accurate push of the information.
  • FIG. 11 is a schematic block diagram of a computer device according to an embodiment of the present application.
  • the computer device 500 includes a processor 502, a memory, and a network interface 505 connected through a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
  • the non-volatile storage medium 503 can store an operating system 5031 and a computer program 5032.
  • the processor 502 can execute an information push method based on face recognition.
  • the processor 502 is used to provide calculation and control capabilities, and support the operation of the entire computer device 500.
  • the internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503.
  • the processor 502 can make the processor 502 execute an information push method based on face recognition.
  • the network interface 505 is used for network communication, such as providing data information transmission.
  • the structure shown in FIG. 11 is only a block diagram of part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device 500 to which the solution of the present application is applied.
  • the specific computer device 500 may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
  • the processor 502 is configured to run a computer program 5032 stored in the memory to realize the following function: if user information input by the administrator is received, a model is extracted from each photo of the user information according to a preset vector Extract feature vectors in the, to obtain a feature vector set, where the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; The preset face recognition model and the feature vector set recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
  • the processor 502 executes the step of extracting feature vectors from each photo of the user information according to a preset vector extraction model to obtain a feature vector set if the user information input by the administrator is received, Perform the following operations: decolorize each photo in the user information to obtain a photo set; convert the photos in the photo set to obtain a vector set according to the vector conversion rule in the vector extraction model; The feature vector calculation formula in the vector extraction model and the vector set are calculated to obtain the feature vector corresponding to each photo to obtain the feature vector set.
  • the processor 502 is performing recognition of the face information according to a preset face recognition model and the feature vector set to obtain the recognition of whether the current user is a certain user in the user information
  • the processor 502 is performing recognition of the face information according to a preset face recognition model and the feature vector set to obtain the recognition of whether the current user is a certain user in the user information After the result step, the following operations are also performed: if the recognition result is that the current user is not a certain user in the user information, a prompt message is issued to the current user to obtain face information again, and the current user's information is obtained again. Face information.
  • the processor 502 executes the step of acquiring target push information matching the face information from a preset to-be-pushing information database according to the recognition result to push the current user
  • the operations are as follows: obtain personal information corresponding to the face information in the user information according to the recognition result; obtain the user group matching the personal information according to the user classification rule of the information database to be pushed As a target user group; acquiring the information to be pushed contained in the information push category corresponding to the target user group in the information database to be pushed as the target push information to push the current user.
  • the embodiment of the computer device shown in FIG. 11 does not constitute a limitation on the specific configuration of the computer device.
  • the computer device may include more or less components than those shown in the figure. Or combine certain components, or different component arrangements.
  • the computer device may only include a memory and a processor. In such embodiments, the structures and functions of the memory and the processor are the same as those of the embodiment shown in FIG. 11, which will not be repeated here.
  • the processor 502 may be a central processing unit (Central Processing Unit, CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (Digital Signal Processors, DSPs), Application Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • the general-purpose processor may be a microprocessor or the processor may also be any conventional processor.
  • a computer-readable storage medium may be a non-volatile computer-readable storage medium.
  • the computer-readable storage medium stores a computer program, where the computer program is executed by the processor to implement the following steps: if user information input by the administrator is received, a model is extracted from each photo of the user information according to a preset vector The feature vector is extracted to obtain a feature vector set, wherein the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; Set the face recognition model and the feature vector set to recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is the A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.

Abstract

An information pushing method and apparatus based on face recognition and a computer device. The method comprises: if user information input by an administrator is received, extracting a feature vector from each image of the user information according to a preset vector extraction model to obtain a feature vector set (S110); if a preset information pushing time point is reached, obtaining face information of a current user (S120); recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result about whether the current user is a certain user in the user information (S130); and if the recognition result is that the current user is a certain user in the user information, obtaining, according to the recognition result, target push information matched with the face information from a preset information base to be pushed, so as to push the target push information to the current user (S140). According to the method, the target push information matched with the user information can be obtained on the basis of the face recognition technology, so that information is accurately pushed, and the information push effect is greatly improved.

Description

基于人脸识别的信息推送方法、装置、计算机设备Information push method, device and computer equipment based on face recognition
本申请要求于2019年7月5日提交中国专利局、申请号为201910605454.4,发明名称为“基于人脸识别的信息推送方法、装置、计算机设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on July 5, 2019, the application number is 201910605454.4, and the invention title is "Information Push Method, Apparatus, and Computer Equipment Based on Face Recognition". The reference is incorporated in this application.
技术领域Technical field
本申请涉及计算机技术领域,尤其涉及一种基于人脸识别的信息推送方法、装置、计算机设备及存储介质。This application relates to the field of computer technology, and in particular to an information push method, device, computer equipment and storage medium based on face recognition.
背景技术Background technique
企业可通过推送图片、视频等信息的方式对自身的产品进行商业宣传,然而传统的信息推送方式为了提高受众面,均是将图片、视频信息在人流量大的公共场所进行推送,或将信息插入于电视剧、电影等视频中并在电视、电脑、手机等终端中进行推送,虽然接收到信息的人数较多,但发明人发现由于这种信息推送方式并不具有针对性而导致信息推送效果受到限制,所推送的信息无法精准推送到目标人群。因而,现有的信息推送方法存在无法对信息进行精准推送的问题。Enterprises can commercialize their products by pushing pictures, videos and other information. However, in order to increase the audience's reach, the traditional information push methods are to push pictures and video information in public places with a large number of people, or send information Inserted in TV series, movies and other videos and pushed on TV, computer, mobile phone and other terminals. Although the number of people receiving information is large, the inventor found that this information push method is not targeted and leads to information push effect Due to restrictions, the pushed information cannot be accurately pushed to the target population. Therefore, the existing information push method has a problem that it cannot accurately push information.
发明内容Summary of the invention
本申请实施例提供了一种基于人脸识别的信息推送方法、装置、计算机设备及存储介质,适用于人工智能领域,旨在解决现有技术方法中所存在的无法对信息进行精准推送的问题。The embodiments of the application provide an information push method, device, computer equipment and storage medium based on face recognition, which are suitable for the field of artificial intelligence and aim to solve the problem of the inability to accurately push information in the prior art methods .
第一方面,本申请实施例提供了一种基于人脸识别的信息推送方法,其包括:若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;若到达预置信息推送时间点,获取当前用户的人脸信息;根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。In the first aspect, an embodiment of the present application provides an information push method based on face recognition, which includes: if user information input by an administrator is received, extracting a model from each photo of the user information according to a preset vector Extract feature vectors in the, to obtain a feature vector set, where the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; The preset face recognition model and the feature vector set recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
第二方面,本申请实施例提供了一种基于人脸识别的信息推送装置,其包括:特征向量提取单元,用于若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;人脸信息获取单元,用于若到达预置信息推送时间点,获取当前用户的人脸信息;人脸信息识别单元,用于根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;目 标推送信息推送单元,用于若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。In the second aspect, an embodiment of the present application provides an information pushing device based on face recognition, which includes: a feature vector extraction unit, configured to extract a model from all users according to a preset vector if the user information input by the administrator is received The feature vector is extracted from each photo of the user information to obtain a feature vector set, wherein the user information includes a plurality of the photos, and each photo corresponds to a user; the face information acquisition unit is used to obtain a feature vector set. Set the information push time point to obtain the face information of the current user; the face information recognition unit is used to recognize the face information according to the preset face recognition model and the feature vector set to obtain whether the current user is Is the recognition result of a certain user in the user information; the target push information pushing unit is configured to, if the recognition result is that the current user is a certain user in the user information, information to be pushed from a preset according to the recognition result The target push information matching the face information is acquired from the library to push the current user.
第三方面,本申请实施例又提供了一种计算机设备,其包括:一个或多个处理器;存储器;一个或多个计算机程序,其中所述一个或多个计算机程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个计算机程序配置用于执行一种基于人脸识别的信息推送方法,其中,所述基于人脸识别的信息推送方法包括以下步骤:若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;若到达预置信息推送时间点,获取当前用户的人脸信息;根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。In a third aspect, an embodiment of the present application further provides a computer device, which includes: one or more processors; a memory; one or more computer programs, wherein the one or more computer programs are stored in the memory And configured to be executed by the one or more processors, and the one or more computer programs are configured to execute an information push method based on face recognition, wherein the information push based on face recognition The method includes the following steps: if the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set, wherein the user information includes multiple For the photos, each of the photos corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; the face information is performed according to the preset face recognition model and the feature vector set Recognition to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is a certain user in the user information, the information to be pushed from the preset according to the recognition result The target push information matching the face information is acquired from the library to push the current user.
第四方面,本申请实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,该计算机程序被处理器执行时实现一种基于人脸识别的信息推送方法,其中,所述基于人脸识别的信息推送方法包括以下步骤:若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;若到达预置信息推送时间点,获取当前用户的人脸信息;根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。In a fourth aspect, the embodiments of the present application also provide a computer-readable storage medium with a computer program stored on the computer-readable storage medium, and when the computer program is executed by a processor, a type of information push based on face recognition is realized The method, wherein the information push method based on face recognition includes the following steps: if the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain A feature vector set, wherein the user information includes a plurality of the photos, each of the photos corresponds to a user; if the preset information push time point is reached, the current user's face information is obtained; according to the preset face recognition model And the feature vector set to recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is a certain user in the user information The user obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
本申请实施例通过上述方法,能够基于人脸识别技术获取与用户信息相匹配的目标推送信息,以实现对信息进行精准推送,大幅提升了信息的推送效果。The embodiment of the present application can obtain target push information matching user information based on the face recognition technology through the above method, so as to realize accurate push of information and greatly improve the effect of pushing information.
附图说明Description of the drawings
图1为本申请实施例提供的基于人脸识别的信息推送方法的流程示意图;FIG. 1 is a schematic flowchart of an information push method based on face recognition provided by an embodiment of the application;
图2为本申请实施例提供的基于人脸识别的信息推送方法的子流程示意图;FIG. 2 is a schematic diagram of a sub-process of a method for pushing information based on face recognition provided by an embodiment of the application;
图3为本申请实施例提供的基于人脸识别的信息推送方法的另一子流程示意图;FIG. 3 is a schematic diagram of another sub-flow of the method for pushing information based on face recognition according to an embodiment of the application;
图4为本申请实施例提供的基于人脸识别的信息推送方法的另一流程示意图;4 is a schematic diagram of another process of the method for pushing information based on face recognition provided by an embodiment of the application;
图5为本申请实施例提供的基于人脸识别的信息推送方法的另一子流程示意图;FIG. 5 is a schematic diagram of another sub-flow of the method for pushing information based on face recognition according to an embodiment of the application;
图6为本申请实施例提供的基于人脸识别的信息推送装置的示意性框图;FIG. 6 is a schematic block diagram of an information pushing device based on face recognition provided by an embodiment of the application;
图7为本申请实施例提供的基于人脸识别的信息推送装置的子单元示意性 框图;Fig. 7 is a schematic block diagram of a subunit of a face recognition-based information pushing device provided by an embodiment of the application;
图8为本申请实施例提供的基于人脸识别的信息推送装置的另一子单元示意性框图;FIG. 8 is a schematic block diagram of another subunit of the information pushing device based on face recognition according to an embodiment of the application;
图9为本申请实施例提供的基于人脸识别的信息推送装置的另一示意性框图;FIG. 9 is another schematic block diagram of an information push device based on face recognition provided by an embodiment of the application;
图10为本申请实施例提供的基于人脸识别的信息推送装置的另一子单元示意性框图;FIG. 10 is a schematic block diagram of another subunit of the information pushing device based on face recognition according to an embodiment of the application;
图11为本申请实施例提供的计算机设备的示意性框图。FIG. 11 is a schematic block diagram of a computer device provided by an embodiment of the application.
具体实施方式Detailed ways
请参阅图1,图1是本申请实施例提供的基于人脸识别的信息推送方法的流程示意图。该基于人脸识别的信息推送方法应用于用户终端中,该方法通过安装于用户终端中的应用软件进行执行,用户终端即是用于执行基于人脸识别的信息推送方法以对信息进行推送的终端设备,用户终端为具有拍照或录像功能的终端设备,上述基于人脸识别的信息推送方法可适用于已设置用于推送图片、视频等信息的用户终端的载具中,例如高铁、飞机等。如图1所示,该方法包括步骤S110~S140。Please refer to FIG. 1, which is a schematic flowchart of a method for pushing information based on face recognition provided by an embodiment of the present application. The information push method based on face recognition is applied to a user terminal, and the method is executed by application software installed in the user terminal. The user terminal is used to execute the information push method based on face recognition to push information Terminal equipment. The user terminal is a terminal equipment with camera or video function. The above-mentioned information push method based on face recognition can be applied to vehicles that have been set up to push user terminals such as pictures and videos, such as high-speed trains, airplanes, etc. . As shown in Figure 1, the method includes steps S110 to S140.
S110、若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集。S110: If the user information input by the administrator is received, extract a feature vector from each photo of the user information according to a preset vector extraction model to obtain a feature vector set.
若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集。用户信息可以由管理员统一输入用户终端,管理员即是对用户信息进行输入并对所推送的信息进行管理的人员,管理员可以是飞机上的工作人员、高铁上的工作人员等(办理购票信息时用户需提供详细信息)。其中,所输入的用户信息中包含多个用户的信息,一个用户的信息中包括该用户的一张照片(例如该用户的身份证照片)以及该用户的个人信息,用户的个人信息中包括性别、年龄、学历、婚恋、职业和居住信息等。通过向量提取模型即可从用户信息所包含的照片中获取得到每一用户对应的特征向量,获取所有特征向量即可得到特征向量集,具体的,向量提取模型中包括向量转换规则及特征向量计算公式,特征向量集中包含与用户信息中每一张照片对应的特征向量,特征向量即可用于对用户信息中每一张照片进行数字化,基于上述特征向量集对其他用户的照片进行计算分析也即是人脸识别的具体过程。If the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set. User information can be uniformly input to the user terminal by the administrator. The administrator is the person who inputs user information and manages the pushed information. The administrator can be the staff on the plane, the staff on the high-speed rail, etc. The user needs to provide detailed information when ticket information). Among them, the input user information includes multiple users' information, a user's information includes a photo of the user (such as the user's ID photo) and the user's personal information, and the user's personal information includes gender , Age, education, marriage, occupation and residence information. Through the vector extraction model, the feature vector corresponding to each user can be obtained from the photos contained in the user information, and all feature vectors can be obtained to obtain the feature vector set. Specifically, the vector extraction model includes vector conversion rules and feature vector calculations Formula, the feature vector set contains the feature vector corresponding to each photo in the user information. The feature vector can be used to digitize each photo in the user information. Based on the above feature vector set, the photos of other users are calculated and analyzed. It is the specific process of face recognition.
在一实施例中,如图2所示,步骤S110包括子步骤S111、S112和S113。In one embodiment, as shown in FIG. 2, step S110 includes sub-steps S111, S112, and S113.
S111、对所述用户信息中的每一照片进行去色处理以得到照片集。S111. Decolorize each photo in the user information to obtain a photo collection.
对所述用户信息中的每一照片进行去色处理以得到照片集。用户信息中所包含的照片均为彩色照片,为方便后续对照片进行处理,同时最大限度地保留照片中的信息,可通过对照片进行去色处理以得到仅包含灰度像素的去色照片,对所有照片进行去色处理后即可得到照片集。Decolorization processing is performed on each photo in the user information to obtain a photo collection. The photos included in the user information are all color photos. In order to facilitate subsequent processing of the photos, while keeping the information in the photos to the maximum extent, the photos can be decolorized to obtain decolorized photos containing only grayscale pixels. After all photos are decolorized, the photo collection can be obtained.
S112、根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合。S112: Convert the photos in the photo set according to the vector conversion rule in the vector extraction model to obtain a vector set.
根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合。具体的,向量转换规则即是用于将照片集中的去色照片进行转换以得到一维向量的转换规则,去色照片中包含多个像素,每一像素对应一个灰度值,通过灰度值即可将去色照片中的每一个像素采用数值进行表示。通过以逐行或逐列的方式从去色照片中获取每一像素的灰度值,即可得到一个一维向量,获取照片集中所有照片对应的一维向量即可得到向量集合S。若一个向量集合中包含M个一维向量,则可采用S={C 1,C 2,……,C M}进行表示,其中,C即是向量集合中所包含的一维向量。 The photos in the photo collection are converted according to the vector conversion rules in the vector extraction model to obtain a vector collection. Specifically, the vector conversion rule is the conversion rule used to convert the decolorized photos in the photo collection to obtain a one-dimensional vector. The decolorized photo contains multiple pixels, and each pixel corresponds to a gray value. That is, each pixel in the decolorized photo can be represented by a numerical value. By obtaining the gray value of each pixel from the decolorized photo in a row-by-row or column-by-column manner, a one-dimensional vector can be obtained, and one-dimensional vectors corresponding to all photos in the photo set can be obtained to obtain a vector set S. If a vector set contains M one-dimensional vectors, it can be represented by S={C 1 , C 2 ,..., C M }, where C is the one-dimensional vector contained in the vector set.
其中,灰度值采用非负整数进行表示,像素对应灰度值的取值范围为[0,255],灰度值为0则表示该像素点为黑色,灰度值为255则表示该像素点为白色,灰度值为其他数值则表面该像素点为介于白色与黑色之间的一个具体灰度。Among them, the gray value is represented by a non-negative integer, the value range of the corresponding gray value of the pixel is [0, 255], a gray value of 0 indicates that the pixel is black, and a gray value of 255 indicates that the pixel If the point is white, and the gray value is other values, the pixel point is a specific gray level between white and black.
例如,某一去色照片的由a×b个像素组成,a为横向所包含的像素数量,b为纵向所包含的像素数量,则对应得到的一维向量中所包含灰度值的数量为N=a×b,也即是该去色照片对应的一维向量为C1={c1,c2,…,cN}。For example, a decolorized photo is composed of a×b pixels, a is the number of pixels included in the horizontal direction, and b is the number of pixels included in the vertical direction, then the number of gray values contained in the corresponding one-dimensional vector is N=a×b, that is, the one-dimensional vector corresponding to the decolorized photo is C1={c1, c2,..., cN}.
S113、根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。S113: Calculate the feature vector corresponding to each photo according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。具体的,特征向量计算公式即是用于对向量集合进行计算以获取每一照片对应特征向量的公式,计算每一照片对应特征向量的步骤为:(1)计算向量集合S中所包含一维向量的平均值以得到一维平均向量Ψ,
Figure PCTCN2020087133-appb-000001
所得到的Ψ为一个1×N(1行N列)的一维向量;(2)计算向量集合S中每一个一维向量与上述一维平均向量Ψ之间的差值,Φ i=C i-Ψ,i=1,2,3,…,M,则可对应得到向量矩阵Φ={Φ 1,Φ 2,…,Φ M};所得到的Φ i为一个1×N的一维向量,所得到的Φ为一个M行N列的向量矩阵;(3)计算得到M个正交的单位向量u i,其中i=1,2,3,…,M,单位向量即可用于描述每一个Φ i的分布。u i可通过计算协方差矩阵得到,协方差矩阵X=Φ T×Φ,其中,X={x 1,x 2,…,x M},Φ T为对Φ进行转制后的向量矩阵,Φ为一个M行N列的向量矩阵,则Φ T为一个N行M列的向量矩阵,其中,X为一个M行M列的向量矩阵,计算得到协方差矩阵的特征向量U,其中U={u 1,u 2,…,u M},u i为一个M×1的向量,且u T i×u i=1、u T i×u k=0(i≠k),i=1,2,3,…,M;(4)计算得到每一向量Φ i对应的特征向量Ω i,Ω i也即是与每一照片相对应的特征向量,Ω i=u T i×Φ i,i=1,2,3,…,M,所得到的Ω i为一个1×N的一维向量。获取每一照片对应的特征向量,即可组成一个特征向量集Ω={Ω 1,Ω 2,…,Ω M}。
The feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set. Specifically, the feature vector calculation formula is a formula used to calculate the vector set to obtain the feature vector corresponding to each photo. The steps for calculating the feature vector corresponding to each photo are: (1) Calculate the one-dimensional contained in the vector set S The average value of the vector to obtain the one-dimensional average vector Ψ,
Figure PCTCN2020087133-appb-000001
The obtained Ψ is a 1×N (1 row and N column) one-dimensional vector; (2) Calculate the difference between each one-dimensional vector in the vector set S and the above-mentioned one-dimensional average vector Ψ, Φ i = C i -Ψ, i=1, 2, 3,..., M, the corresponding vector matrix Φ={Φ 1 , Φ 2 ,..., Φ M } can be obtained; the obtained Φ i is a 1×N one-dimensional Vector, the obtained Φ is a vector matrix with M rows and N columns; (3) Calculate M orthogonal unit vectors u i , where i = 1, 2, 3,..., M, the unit vector can be used to describe The distribution of each Φ i . u i can be obtained by calculating the covariance matrix, the covariance matrix X=Φ T ×Φ, where X={x 1 , x 2 ,..., x M }, Φ T is the vector matrix after transforming Φ, Φ Is a vector matrix with M rows and N columns, then Φ T is a vector matrix with N rows and M columns, where X is a vector matrix with M rows and M columns. The eigenvector U of the covariance matrix is calculated, where U={ u 1 , u 2 ,..., u M }, u i is a vector of M×1, and u T i ×u i =1, u T i ×u k =0 (i≠k), i=1, 2,3, ..., M; (4 ) calculate each vector corresponding eigenvectors Φ i Ω i, Ω i that is, with the picture corresponding to each feature vector, Ω i = u T i × Φ i, i=1, 2, 3,..., M, and the obtained Ω i is a 1×N one-dimensional vector. By obtaining the feature vector corresponding to each photo, a feature vector set Ω={Ω 1 , Ω 2 ,..., Ω M } can be formed.
S120、若到达预置信息推送时间点,获取当前用户的人脸信息。S120: If the preset information push time point is reached, obtain the face information of the current user.
若到达用户终端中预置信息推送时间点,获取当前用户的人脸信息。预置信息推送时间点可以是用户在用户终端中使用应用程序的某一时间节点,例如用户通过视频播放程序播放视频之前所预置的信息推送时间点,或航班、高铁上终端显示器中所预置的信息推送时间点。到达预置信息推送时间点,即可通 过用户终端中的图像采集设备获取当前用户的人脸信息,图像采集设备可以采集得到图片或者视频,图像采集设备可以是用户终端中的相机,将所获取到的一张图片或从视频中截取的一张图片作为当前用户的人脸信息。If it arrives at the preset information push time point in the user terminal, the face information of the current user is obtained. The preset information push time point can be a certain time node when the user uses the application in the user terminal, for example, the information push time point preset by the user before playing the video through the video player program, or the time point preset in the terminal display on the flight or high-speed rail. The set information push time point. When the preset information push time point is reached, the current user’s face information can be acquired through the image acquisition device in the user terminal. The image acquisition device can acquire pictures or videos. The image acquisition device can be a camera in the user terminal. A picture obtained or a picture intercepted from a video is used as the face information of the current user.
S130、根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果。S130: Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information.
根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到识别结果。人脸识别模型即是用于对所获取到的人脸信息是否为所述用户信息中某一用户进行识别的模型,人脸识别模型中包括向量提取规则、差别计算公式及差别阈值。Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result. The face recognition model is a model used to identify whether the acquired face information is a certain user in the user information. The face recognition model includes vector extraction rules, difference calculation formulas and difference thresholds.
在一实施例中,如图3所示,步骤S130包括子步骤S131、S132和S133。In an embodiment, as shown in FIG. 3, step S130 includes sub-steps S131, S132, and S133.
S131、根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量。S131. Obtain a face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model.
根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量。具体的,人脸信息中包括所获取到的一张图片,向量提取规则即可从该图片中提取得到与人脸信息对应的人脸特征向量,具体的步骤包括,对该照片的尺寸进行裁剪以得到与所述照片集中照片尺寸相同的照片,对进行尺寸调整后的照片进行去色处理以得到人脸信息对应的去色照片,根据向量提取规则从人脸信息对应的去色照片中提取得到该照片对应的人脸特征向量Ω x,人脸特征向量Ω x为一个1×N的一维向量。人脸信息对应的去色照片中包含多个像素,每一像素对应一个灰度值,通过灰度值即可将去色照片中的每一个像素采用数值进行表示,提取得到人脸特征向量的具体过程与从所述照片集中获取每一照片对应的一维向量的步骤相同,在此不做赘述。 Obtain the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model. Specifically, the face information includes an acquired picture, and the vector extraction rules can extract the face feature vector corresponding to the face information from the picture. The specific steps include cropping the size of the photo To obtain photos with the same size as the photos in the photo collection, perform decolorization processing on the photos after size adjustment to obtain decolorized photos corresponding to face information, and extract them from decolorized photos corresponding to face information according to the vector extraction rules The face feature vector Ω x corresponding to the photo is obtained, and the face feature vector Ω x is a 1×N one-dimensional vector. The decolorized photo corresponding to the face information contains multiple pixels, and each pixel corresponds to a gray value. Through the gray value, each pixel in the decolorized photo can be represented by a numerical value, and the facial feature vector is extracted The specific process is the same as the step of obtaining the one-dimensional vector corresponding to each photo from the photo collection, and will not be repeated here.
S132、根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值。S132: Calculate the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model.
根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值。差别计算公式即是用于计算所述人脸特征向量与特征向量集中每一特征向量差别值的计算公式,人脸特征向量与特征向量的差别值即可用于对人脸信息与特征向量之间的差别进行量化,差别值越小则表明人脸信息与该特征向量对应的照片之间越相似。差别计算公式可表示为ε i=||Ω x-Ω i|| 2,Ω x为人脸特征向量,ε i为人脸特征向量与特征向量集中第i个特征向量的差别值,Ω i为特征向量集中第i个特征向量。人脸特征向量Ω x为一个1×N的一维向量,Ω i也是一个1×N的一维向量,差别计算公式即是计算上述两个向量的欧式距离。 The difference value between the face feature vector and each feature vector in the feature vector set is calculated according to the difference calculation formula in the face recognition model. The difference calculation formula is the calculation formula used to calculate the difference between the face feature vector and each feature vector in the feature vector set. The difference between the face feature vector and the feature vector can be used to determine the difference between the face information and the feature vector. The difference is quantified. The smaller the difference value, the more similar the face information and the photo corresponding to the feature vector. The difference calculation formula can be expressed as ε i =||Ω x- Ω i || 2 , Ω x is the face feature vector, ε i is the difference value between the face feature vector and the i-th feature vector in the feature vector set, and Ω i is the feature The i-th feature vector in the vector set. The face feature vector Ω x is a 1×N one-dimensional vector, and Ω i is also a 1×N one-dimensional vector. The difference calculation formula is to calculate the Euclidean distance of the above two vectors.
S133、根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。S133. Judging the difference value corresponding to each feature vector according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information .
根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。具体的,通过差别阈值对每一所述特征向量对应的差别值进行判断即可得到识别结果,若某一特征向量对应的差别值小于差别阈值,且其他特征 向量的差别值不小于差别阈值,则识别结果为所述当前用户为所述用户信息中某一用户;若所有特征向量对应的差别值均不小于差别阈值,则表明人脸信息中的照片与所述用户信息中的照片匹配失败,则识别结果为所述当前用户不为所述用户信息中某一用户;若存在多个特征向量对应的差别值小于差别阈值,则表明所获取到的人脸信息中的照片不是人脸,识别结果同样为所述当前用户不为所述用户信息中某一用户。The difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information. Specifically, the recognition result can be obtained by judging the difference value corresponding to each feature vector through the difference threshold. If the difference value corresponding to a certain feature vector is less than the difference threshold, and the difference value of other feature vectors is not less than the difference threshold, Then the recognition result is that the current user is a certain user in the user information; if the difference value corresponding to all feature vectors is not less than the difference threshold, it indicates that the photo in the face information matches the photo in the user information failed to match , The recognition result is that the current user is not a certain user in the user information; if the difference value corresponding to multiple feature vectors is smaller than the difference threshold, it indicates that the photo in the obtained face information is not a face, The recognition result is also that the current user is not a certain user in the user information.
例如,预置差别阈值为500,所有特征向量对应的差别值中某一个差别值ε 3为362,其他特征向量对应的差别值均不小于500,则识别结果为所述当前用户为所述用户信息中的第三个用户。 For example, if the preset difference threshold is 500, one of the difference values ε 3 corresponding to all feature vectors is 362, and the difference values corresponding to other feature vectors are not less than 500, the recognition result is that the current user is the user The third user in the message.
在一实施例中,如图4所示,步骤S130之后还包括步骤:S130a。In one embodiment, as shown in FIG. 4, after step S130, a step S130a is further included.
S130a、若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。S130a: If the recognition result is that the current user is not a certain user in the user information, send a prompt message to the current user to obtain face information again and obtain the face information of the current user again.
若识别结果为所述当前用户不为所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。若识别结果为所述当前用户不为所述用户信息中某一用户,则可向当前用户发出提示信息,以再次获取当前用户的人脸信息。获取到新的人脸信息后,可再次通过上述方法对新的人脸信息进行识别以得到识别结果。If the recognition result is that the current user is not a certain user in the user information, a prompt message for obtaining the face information again is issued to the current user and the face information of the current user is obtained again. If the recognition result is that the current user is not a certain user in the user information, a prompt message may be sent to the current user to obtain the face information of the current user again. After obtaining the new face information, the new face information can be recognized again by the above method to obtain the recognition result.
S140、若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。S140. If the recognition result is that the current user is a certain user in the user information, according to the recognition result, obtain target push information that matches the face information from a preset to-be-push information database, to target the The current user pushes.
若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。具体的,待推送信息库即是用于存放待推送信息的信息库,所述待推送信息库中包含多个信息推送类别及用户分类规则,每一信息推送类别中均对应包含至少一条待推送信息,待推送信息库中的待推送信息可以是图片、视频、音频等文件,根据识别结果即可获取与人脸信息相匹配的目标推送信息,并将目标推送信息在用户终端中对当前用户进行推送,以实现对信息的精准推送,能够大幅提高信息的推送效果。If the recognition result is that the current user is a certain user in the user information, the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it. Specifically, the information library to be pushed is an information library for storing information to be pushed. The information library to be pushed contains multiple information push categories and user classification rules, and each information push category contains at least one piece of information to be pushed. Information, the information to be pushed in the information database to be pushed can be files such as pictures, videos, audios, etc. According to the recognition results, the target push information that matches the facial information can be obtained, and the target push information is displayed to the current user in the user terminal. Pushing to achieve accurate information push can greatly improve the effect of information push.
在一实施例中,如图5所示,步骤S140包括子步骤S141、S142和S143。In an embodiment, as shown in FIG. 5, step S140 includes sub-steps S141, S142, and S143.
S141、根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息。S141. Acquire personal information corresponding to the face information in the user information according to the recognition result.
根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息。具体的,用户信息中包含多个用户的信息,其中,一个用户的信息中包括该用户的一张照片(例如该用户的身份证照片)以及该用户的个人信息,个人信息包括性别、年龄、学历、婚恋、职业和居住信息等。根据识别结果即可从用户信息中获取到与人脸信息对应的个人信息。Acquire personal information corresponding to the face information in the user information according to the recognition result. Specifically, the user information includes multiple users' information. Among them, a user's information includes a photo of the user (for example, a photo of the user's ID card) and personal information of the user. The personal information includes gender, age, Education, marriage, occupation and residence information, etc. According to the recognition result, the personal information corresponding to the face information can be obtained from the user information.
例如,识别结果为所述当前用户为所述用户信息中的第三个用户,用户信息中第三个用户的个人信息包括性别:男、年龄:29、学历:高中、婚恋:未婚、职业:白领,即可将上述个人信息作为与所述人脸信息对应的个人信息。For example, the recognition result is that the current user is the third user in the user information, and the personal information of the third user in the user information includes gender: male, age: 29, education: high school, marriage: unmarried, occupation: White-collar workers can use the above personal information as personal information corresponding to the face information.
S142、根据所述待推送信息库的用户分类规则获取与所述个人信息相匹配的一个用户群作为目标用户群。S142. Obtain a user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed.
根据所述待推送信息库的用户分类规则获取与所述个人信息相匹配的一个用户群作为目标用户群。通过用户群分类规则即可将对应的用户分类至相应的用户群,每一信息推送类别与一个用户群对应,,每一信息推送类别中均对应包含至少一条待推送信息,也即是通过信息推送类别即可将待推送信息库中所包含的所有待推送信息进行分类。通过用户分类规则及与人脸信息对应的个人信息,即可将获取与该个人信息相匹配的一个用户群,每一用户群均对应一个信息推送类别,也即是目标用户群,具体的,根据用户分类规则可根据年龄段将用户分至第一大类,根据性别将用户分至第一大类中的第一支类,根据婚恋将用户分至第一支类中的第一子类,根据职业将用户分至第一子类中的第一小类,根据学历获取第一小类中与该用户相匹配的一个用户群作为目标用户群。Acquire a user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed. According to the user group classification rules, the corresponding users can be classified into the corresponding user groups. Each information push category corresponds to a user group, and each information push category contains at least one piece of information to be pushed, that is, through information Push category can classify all the information to be pushed contained in the information database to be pushed. Through user classification rules and personal information corresponding to the face information, a user group matching the personal information can be obtained, and each user group corresponds to an information push category, that is, the target user group, specifically, According to user classification rules, users can be classified into the first category according to age, users are classified into the first category of the first category according to gender, and users are classified into the first subcategory of the first category according to marriage and love. According to occupation, users are classified into the first sub-category in the first sub-category, and a user group matching the user in the first sub-category is obtained as the target user group according to the educational background.
例如,用户分类规则如表1所示。For example, user classification rules are shown in Table 1.
Figure PCTCN2020087133-appb-000002
Figure PCTCN2020087133-appb-000002
表1Table 1
根据表1中所示的用户分类规则获取与上述人脸信息对应的个人信息(男、年龄:29、学历:高中、婚恋:未婚、职业:白领)相匹配的目标用户群,则可将与该个人信息对应的用户进行分类后,得到与该用户相匹配的目标用户群为用户群d1H6p。According to the user classification rules shown in Table 1, to obtain personal information corresponding to the above-mentioned face information (male, age: 29, education: high school, marriage: unmarried, occupation: white-collar), the target user group can be matched with After the user corresponding to the personal information is classified, the target user group matching the user is obtained as the user group d1H6p.
S143、获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。S143. Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user.
获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。由于每一用户群均对应一个信息推送类别,获取与个人信息相匹配的目标用户群后,获取该目标用户群对应信息推送类别中所包含的待推送信息,即可得到与个人信息相匹配的目标推送信息,其中,目标推送信息中至少包含一条待推送信息,依次将目标推送信息在用户终端中对当前用户进行推送,即可实现对信息的精准推送。Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user. Since each user group corresponds to an information push category, after obtaining the target user group that matches the personal information, obtain the information to be pushed contained in the information push category corresponding to the target user group, and you can get the information that matches the personal information Target push information, where the target push information contains at least one piece of information to be pushed, and the target push information is sequentially pushed in the user terminal to the current user to achieve accurate push of the information.
例如,用户群d1H6p对应的信息推送类别为婚恋类信息,则将该信息推送 类别中所包含的待推送信息作为与上述个人信息相匹配的目标推送信息并对当前用户进行推送。For example, if the information push category corresponding to the user group d1H6p is marriage and love information, the information to be pushed contained in the information push category is used as the target push information that matches the above personal information and pushes the current user.
在本申请实施例所提供的基于人脸识别的信息推送方法中,根据向量提取模型从管理员所输入的用户信息中提取得到特征向量集,若到达预置信息推送时间点则自动获取当前用户的人脸信息,并对当前用户是否为用户信息中的某一用户进行识别,根据识别结果从预置待推送信息库中获取目标推送信息并对当前用户进行推送。通过上述方法,能够基于人脸识别技术获取与用户信息相匹配的目标推送信息,以实现对信息进行精准推送,大幅提升了信息的推送效果。In the information push method based on face recognition provided by the embodiment of this application, the feature vector set is extracted from the user information input by the administrator according to the vector extraction model, and the current user is automatically acquired when the preset information push time point is reached. According to the recognition result, obtain the target push information from the preset to-be-push information database and push the current user. Through the above method, it is possible to obtain target push information that matches the user information based on the face recognition technology, so as to achieve accurate push of information, which greatly improves the push effect of information.
本申请实施例还提供一种基于人脸识别的信息推送装置,该基于人脸识别的信息推送装置用于执行前述基于人脸识别的信息推送方法的任一实施例。具体地,请参阅图6,图6是本申请实施例提供的基于人脸识别的信息推送装置的示意性框图。该基于人脸识别的信息推送装置可以配置于用户终端中。The embodiment of the present application also provides an information pushing device based on face recognition, and the information pushing device based on face recognition is used to execute any embodiment of the aforementioned information pushing method based on face recognition. Specifically, please refer to FIG. 6, which is a schematic block diagram of an information pushing device based on face recognition provided by an embodiment of the present application. The information pushing device based on face recognition can be configured in a user terminal.
如图6所示,基于人脸识别的信息推送装置100包括特征向量提取单元110、人脸信息获取单元120、人脸信息识别单元130和目标推送信息推送单元140。As shown in FIG. 6, the information pushing device 100 based on face recognition includes a feature vector extraction unit 110, a face information acquisition unit 120, a face information recognition unit 130 and a target push information pushing unit 140.
特征向量提取单元110,用于若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集。The feature vector extraction unit 110 is configured to, if user information input by the administrator is received, extract feature vectors from each photo of the user information according to a preset vector extraction model to obtain a feature vector set.
若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集。用户信息可以由管理员统一输入用户终端,管理员即是对用户信息进行输入并对所推送的信息进行管理的人员,管理员可以是飞机上的工作人员、高铁上的工作人员等(办理购票信息时用户需提供详细信息)。其中,所输入的用户信息中包含多个用户的信息,一个用户的信息中包括该用户的一张照片(例如该用户的身份证照片)以及该用户的个人信息,用户的个人信息中包括性别、年龄、学历、婚恋、职业和居住信息等。通过向量提取模型即可从用户信息所包含的照片中获取得到每一用户对应的特征向量,获取所有特征向量即可得到特征向量集,具体的,向量提取模型中包括向量转换规则及特征向量计算公式,特征向量集中包含与用户信息中每一张照片对应的特征向量,特征向量即可用于对用户信息中每一张照片进行数字化,基于上述特征向量集对其他用户的照片进行计算分析也即是人脸识别的具体过程。If the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set. User information can be uniformly input to the user terminal by the administrator. The administrator is the person who inputs user information and manages the pushed information. The administrator can be the staff on the plane, the staff on the high-speed rail, etc. The user needs to provide detailed information when ticket information). Among them, the input user information includes multiple users' information, a user's information includes a photo of the user (such as the user's ID photo) and the user's personal information, and the user's personal information includes gender , Age, education, marriage, occupation and residence information. Through the vector extraction model, the feature vector corresponding to each user can be obtained from the photos contained in the user information, and all feature vectors can be obtained to obtain the feature vector set. Specifically, the vector extraction model includes vector conversion rules and feature vector calculations Formula, the feature vector set contains the feature vector corresponding to each photo in the user information. The feature vector can be used to digitize each photo in the user information. Based on the above feature vector set, the photos of other users are calculated and analyzed. It is the specific process of face recognition.
其他发明实施例中,如图7所示,所述特征向量提取单元110包括子单元:去色单元111、向量转换单元112和特征向量计算单元113。In other embodiments of the invention, as shown in FIG. 7, the feature vector extraction unit 110 includes sub-units: a decolorization unit 111, a vector conversion unit 112 and a feature vector calculation unit 113.
去色单元111,用于对所述用户信息中的每一照片进行去色处理以得到照片集。The decolorization unit 111 is configured to decolorize each photo in the user information to obtain a photo collection.
对所述用户信息中的每一照片进行去色处理以得到照片集。用户信息中所包含的照片均为彩色照片,为方便后续对照片进行处理,同时最大限度地保留照片中的信息,可通过对照片进行去色处理以得到仅包含灰度像素的去色照片,对所有照片进行去色处理后即可得到照片集。Decolorization processing is performed on each photo in the user information to obtain a photo collection. The photos included in the user information are all color photos. In order to facilitate subsequent processing of the photos, while keeping the information in the photos to the maximum extent, the photos can be decolorized to obtain decolorized photos containing only grayscale pixels. After all photos are decolorized, the photo collection can be obtained.
向量转换单元112,用于根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合。The vector conversion unit 112 is configured to convert the photos in the photo set according to the vector conversion rules in the vector extraction model to obtain a vector set.
根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合。具体的,向量转换规则即是用于将照片集中的去色照片进行转换以得到一维向量的转换规则,去色照片中包含多个像素,每一像素对应一个灰度值,通过灰度值即可将去色照片中的每一个像素采用数值进行表示。通过以逐行或逐列的方式从去色照片中获取每一像素的灰度值,即可得到一个一维向量,获取照片集中所有照片对应的一维向量即可得到向量集合S。若一个向量集合中包含M个一维向量,则可采用S={C 1,C 2,……,C M}进行表示,其中,C即是向量集合中所包含的一维向量。 The photos in the photo collection are converted according to the vector conversion rules in the vector extraction model to obtain a vector collection. Specifically, the vector conversion rule is the conversion rule used to convert the decolorized photos in the photo collection to obtain a one-dimensional vector. The decolorized photo contains multiple pixels, and each pixel corresponds to a gray value. That is, each pixel in the decolorized photo can be represented by a numerical value. By obtaining the gray value of each pixel from the decolorized photo in a row-by-row or column-by-column manner, a one-dimensional vector can be obtained, and one-dimensional vectors corresponding to all photos in the photo set can be obtained to obtain a vector set S. If a vector set contains M one-dimensional vectors, it can be represented by S={C 1 , C 2 ,..., C M }, where C is the one-dimensional vector contained in the vector set.
其中,灰度值采用非负整数进行表示,像素对应灰度值的取值范围为[0,255],灰度值为0则表示该像素点为黑色,灰度值为255则表示该像素点为白色,灰度值为其他数值则表面该像素点为介于白色与黑色之间的一个具体灰度。Among them, the gray value is represented by a non-negative integer, the value range of the corresponding gray value of the pixel is [0, 255], a gray value of 0 indicates that the pixel is black, and a gray value of 255 indicates that the pixel If the point is white, and the gray value is other values, the pixel point is a specific gray level between white and black.
特征向量计算单元113,用于根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。The feature vector calculation unit 113 is configured to calculate the feature vector corresponding to each photo according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。具体的,特征向量计算公式即是用于对向量集合进行计算以获取每一照片对应特征向量的公式,计算每一照片对应特征向量的步骤为:(1)计算向量集合S中所包含一维向量的平均值以得到一维平均向量Ψ,
Figure PCTCN2020087133-appb-000003
所得到的Ψ为一个1×N(1行N列)的一维向量;(2)计算向量集合S中每一个一维向量与上述一维平均向量Ψ之间的差值,Φ i=C i-Ψ,i=1,2,3,…,M,则可对应得到向量矩阵Φ={Φ 1,Φ 2,…,Φ M};所得到的Φ i为一个1×N的一维向量,所得到的Φ为一个M行N列的向量矩阵;(3)计算得到M个正交的单位向量u i,其中i=1,2,3,…,M,单位向量即可用于描述每一个Φ i的分布。u i可通过计算协方差矩阵得到,协方差矩阵X=Φ T×Φ,其中,X={x 1,x 2,…,x M},Φ T为对Φ进行转制后的向量矩阵,Φ为一个M行N列的向量矩阵,则Φ T为一个N行M列的向量矩阵,其中,X为一个M行M列的向量矩阵,计算得到协方差矩阵的特征向量U,其中U={u 1,u 2,…,u M},u i为一个M×1的向量,且u T i×u i=1、u T i×u k=0(i≠k),i=1,2,3,…,M;(4)计算得到每一向量Φ i对应的特征向量Ω i,Ω i也即是与每一照片相对应的特征向量,Ω i=u T i×Φ i,i=1,2,3,…,M,所得到的Ω i为一个1×N的一维向量。获取每一照片对应的特征向量,即可组成一个特征向量集Ω={Ω 1,Ω 2,…,Ω M}。
The feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set. Specifically, the feature vector calculation formula is a formula used to calculate the vector set to obtain the feature vector corresponding to each photo. The steps for calculating the feature vector corresponding to each photo are: (1) Calculate the one-dimensional contained in the vector set S The average value of the vector to obtain the one-dimensional average vector Ψ,
Figure PCTCN2020087133-appb-000003
The obtained Ψ is a 1×N (1 row and N column) one-dimensional vector; (2) Calculate the difference between each one-dimensional vector in the vector set S and the above-mentioned one-dimensional average vector Ψ, Φ i = C i -Ψ, i=1, 2, 3,..., M, the corresponding vector matrix Φ={Φ 1 , Φ 2 ,..., Φ M } can be obtained; the obtained Φ i is a 1×N one-dimensional Vector, the obtained Φ is a vector matrix with M rows and N columns; (3) Calculate M orthogonal unit vectors u i , where i = 1, 2, 3,..., M, the unit vector can be used to describe The distribution of each Φ i . u i can be obtained by calculating the covariance matrix, the covariance matrix X=Φ T ×Φ, where X={x 1 , x 2 ,..., x M }, Φ T is the vector matrix after transforming Φ, Φ Is a vector matrix with M rows and N columns, then Φ T is a vector matrix with N rows and M columns, where X is a vector matrix with M rows and M columns. The eigenvector U of the covariance matrix is calculated, where U={ u 1 , u 2 ,..., u M }, u i is a vector of M×1, and u T i ×u i =1, u T i ×u k =0 (i≠k), i=1, 2,3, ..., M; (4 ) calculate each vector corresponding eigenvectors Φ i Ω i, Ω i that is, with the picture corresponding to each feature vector, Ω i = u T i × Φ i, i=1, 2, 3,..., M, and the obtained Ω i is a 1×N one-dimensional vector. By obtaining the feature vector corresponding to each photo, a feature vector set Ω={Ω 1 , Ω 2 ,..., Ω M } can be formed.
人脸信息获取单元120,用于若到达预置信息推送时间点,获取当前用户的人脸信息。The face information acquiring unit 120 is configured to acquire the face information of the current user if the preset information push time point is reached.
若到达用户终端中预置信息推送时间点,获取当前用户的人脸信息。预置信息推送时间点可以是用户在用户终端中使用应用程序的某一时间节点,例如用户通过视频播放程序播放视频之前所预置的信息推送时间点,或航班、高铁上终端显示器中所预置的信息推送时间点。到达预置信息推送时间点,即可通过用户终端中的图像采集设备获取当前用户的人脸信息,图像采集设备可以采集得到图片或者视频,图像采集设备可以是用户终端中的相机,将所获取到的 一张图片或从视频中截取的一张图片作为当前用户的人脸信息。If it arrives at the preset information push time point in the user terminal, the face information of the current user is obtained. The preset information push time point can be a certain time node when the user uses the application in the user terminal, for example, the information push time point preset by the user before playing the video through the video player program, or the time point preset in the terminal display on the flight or high-speed rail. The set information push time point. When the preset information push time point is reached, the current user’s face information can be acquired through the image acquisition device in the user terminal. The image acquisition device can acquire pictures or videos. The image acquisition device can be a camera in the user terminal. A picture obtained or a picture intercepted from a video is used as the face information of the current user.
人脸信息识别单元130,用于根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果。The face information recognition unit 130 is configured to recognize the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information.
根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到识别结果。人脸识别模型即是用于对所获取到的人脸信息是否为所述用户信息中某一用户进行识别的模型,人脸识别模型中包括向量提取规则、差别计算公式及差别阈值。Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result. The face recognition model is a model used to identify whether the acquired face information is a certain user in the user information. The face recognition model includes vector extraction rules, difference calculation formulas and difference thresholds.
其他发明实施例中,如图8所示,所述人脸信息识别单元130包括子单元:人脸特征向量获取单元131、向量差别值计算单元132和差别值判断单元133。In other embodiments of the invention, as shown in FIG. 8, the face information recognition unit 130 includes sub-units: a face feature vector acquisition unit 131, a vector difference value calculation unit 132 and a difference value judgment unit 133.
人脸特征向量获取单元131,用于根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量。The face feature vector acquiring unit 131 is configured to acquire the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model.
根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量。具体的,人脸信息中包括所获取到的一张图片,向量提取规则即可从该图片中提取得到与人脸信息对应的人脸特征向量,具体的步骤包括,对该照片的尺寸进行裁剪以得到与所述照片集中照片尺寸相同的照片,对进行尺寸调整后的照片进行去色处理以得到人脸信息对应的去色照片,根据向量提取规则从人脸信息对应的去色照片中提取得到该照片对应的人脸特征向量Ω x,人脸特征向量Ω x为一个1×N的一维向量。人脸信息对应的去色照片中包含多个像素,每一像素对应一个灰度值,通过灰度值即可将去色照片中的每一个像素采用数值进行表示,提取得到人脸特征向量的具体过程与从所述照片集中获取每一照片对应的一维向量的步骤相同,在此不做赘述。 Obtain the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model. Specifically, the face information includes an acquired picture, and the vector extraction rules can extract the face feature vector corresponding to the face information from the picture. The specific steps include cropping the size of the photo To obtain photos with the same size as the photos in the photo collection, perform decolorization processing on the photos after size adjustment to obtain decolorized photos corresponding to face information, and extract them from decolorized photos corresponding to face information according to the vector extraction rules The face feature vector Ω x corresponding to the photo is obtained, and the face feature vector Ω x is a 1×N one-dimensional vector. The decolorized photo corresponding to the face information contains multiple pixels, and each pixel corresponds to a gray value. Through the gray value, each pixel in the decolorized photo can be represented by a numerical value, and the facial feature vector is extracted The specific process is the same as the step of obtaining the one-dimensional vector corresponding to each photo from the photo collection, and will not be repeated here.
向量差别值计算单元132,用于根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值。The vector difference value calculation unit 132 is configured to calculate the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model.
根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值。差别计算公式即是用于计算所述人脸特征向量与特征向量集中每一特征向量差别值的计算公式,人脸特征向量与特征向量的差别值即可用于对人脸信息与特征向量之间的差别进行量化,差别值越小则表明人脸信息与该特征向量对应的照片之间越相似。差别计算公式可表示为ε i=||Ω x-Ω i|| 2,Ω x为人脸特征向量,ε i为人脸特征向量与特征向量集中第i个特征向量的差别值,Ω i为特征向量集中第i个特征向量。人脸特征向量Ω x为一个1×N的一维向量,Ω i也是一个1×N的一维向量,差别计算公式即是计算上述两个向量的欧式距离。 The difference value between the face feature vector and each feature vector in the feature vector set is calculated according to the difference calculation formula in the face recognition model. The difference calculation formula is the calculation formula used to calculate the difference between the face feature vector and each feature vector in the feature vector set. The difference between the face feature vector and the feature vector can be used to determine the difference between the face information and the feature vector. The difference is quantified. The smaller the difference value, the more similar the face information and the photo corresponding to the feature vector. The difference calculation formula can be expressed as ε i =||Ω x- Ω i || 2 , Ω x is the face feature vector, ε i is the difference value between the face feature vector and the i-th feature vector in the feature vector set, and Ω i is the feature The i-th feature vector in the vector set. The face feature vector Ω x is a 1×N one-dimensional vector, and Ω i is also a 1×N one-dimensional vector. The difference calculation formula is to calculate the Euclidean distance of the above two vectors.
差别值判断单元133,用于根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。The difference value judgment unit 133 is configured to judge the difference value corresponding to each feature vector according to the difference threshold value in the face recognition model to obtain whether the current user in the user information is in the user information The recognition result of a certain user.
根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。具体的,通过差别阈值对每一所述特征向量对应的差别值进行判断即可得到识别结果,若某一特征向量对应的差别值小于差别阈值,且其他特征 向量的差别值不小于差别阈值,则识别结果为所述当前用户为所述用户信息中某一用户;若所有特征向量对应的差别值均不小于差别阈值,则表明人脸信息中的照片与所述用户信息中的照片匹配失败,则识别结果为所述当前用户不为所述用户信息中某一用户;若存在多个特征向量对应的差别值小于差别阈值,则表明所获取到的人脸信息中的照片不是人脸,识别结果同样为所述当前用户不为所述用户信息中某一用户。The difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information. Specifically, the recognition result can be obtained by judging the difference value corresponding to each feature vector through the difference threshold. If the difference value corresponding to a certain feature vector is less than the difference threshold, and the difference value of other feature vectors is not less than the difference threshold, Then the recognition result is that the current user is a certain user in the user information; if the difference value corresponding to all feature vectors is not less than the difference threshold, it indicates that the photo in the face information matches the photo in the user information failed to match , The recognition result is that the current user is not a certain user in the user information; if the difference value corresponding to multiple feature vectors is smaller than the difference threshold, it indicates that the photo in the obtained face information is not a face, The recognition result is also that the current user is not a certain user in the user information.
其他发明实施例中,如图9所示,所述基于人脸识别的信息推送装置100还包括子单元:人脸信息再次获取单元130a。In other embodiments of the invention, as shown in FIG. 9, the information pushing device 100 based on face recognition further includes a subunit: a face information reacquiring unit 130a.
人脸信息再次获取单元130a,用于若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。The face information reacquiring unit 130a is configured to, if the recognition result is that the current user is not a certain user in the user information, send a prompt message to the current user to obtain face information again and obtain the current user’s information again. Face information.
若识别结果为所述当前用户不为所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。若识别结果为所述当前用户不为所述用户信息中某一用户,则可向当前用户发出提示信息,以再次获取当前用户的人脸信息。获取到新的人脸信息后,可再次通过上述方法对新的人脸信息进行识别以得到识别结果。If the recognition result is that the current user is not a certain user in the user information, a prompt message for obtaining the face information again is issued to the current user and the face information of the current user is obtained again. If the recognition result is that the current user is not a certain user in the user information, a prompt message may be sent to the current user to obtain the face information of the current user again. After obtaining the new face information, the new face information can be recognized again by the above method to obtain the recognition result.
目标推送信息播放单元140,用于若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。The target push information playback unit 140 is configured to, if the recognition result is that the current user is a certain user in the user information, obtain the information that matches the face information from a preset to-be-push information database according to the recognition result The target pushes information to push the current user.
若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。具体的,待推送信息库即是用于存放待推送信息的信息库,所述待推送信息库中包含多个信息推送类别及用户分类规则,每一信息推送类别中均对应包含至少一条待推送信息,待推送信息库中的待推送信息可以是图片、视频、音频等文件,根据识别结果即可获取与人脸信息相匹配的目标推送信息,并将目标推送信息在用户终端中对当前用户进行推送,以实现对信息的精准推送,能够大幅提高信息的推送效果。If the recognition result is that the current user is a certain user in the user information, the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it. Specifically, the information library to be pushed is an information library for storing information to be pushed. The information library to be pushed contains multiple information push categories and user classification rules, and each information push category contains at least one piece of information to be pushed. Information, the information to be pushed in the information database to be pushed can be files such as pictures, videos, audios, etc. According to the recognition results, the target push information that matches the facial information can be obtained, and the target push information is displayed to the current user in the user terminal. Pushing to achieve accurate information push can greatly improve the effect of information push.
其他发明实施例中,如图10所示,所述目标推送信息播放单元140包括子单元:个人信息获取单元141、用户群匹配单元142和目标推送信息获取单元143。In other embodiments of the invention, as shown in FIG. 10, the target push information playing unit 140 includes sub-units: a personal information acquisition unit 141, a user group matching unit 142, and a target push information acquisition unit 143.
个人信息获取单元141,用于根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息。The personal information obtaining unit 141 is configured to obtain personal information corresponding to the face information in the user information according to the recognition result.
根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息。具体的,用户信息中包含多个用户的信息,其中,一个用户的信息中包括该用户的一张照片(例如该用户的身份证照片)以及该用户的个人信息,个人信息包括性别、年龄、学历、婚恋、职业和居住信息等。根据识别结果即可从用户信息中获取到与人脸信息对应的个人信息。Acquire personal information corresponding to the face information in the user information according to the recognition result. Specifically, the user information includes multiple users' information. Among them, a user's information includes a photo of the user (for example, a photo of the user's ID card) and personal information of the user. The personal information includes gender, age, Education, marriage, occupation and residence information, etc. According to the recognition result, the personal information corresponding to the face information can be obtained from the user information.
用户群匹配单元142,用于根据所述待推送信息库的用户分类规则获取与所述个人信息相匹配的一个用户群作为目标用户群。The user group matching unit 142 is configured to obtain a user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed.
根据所述待推送信息库的用户分类规则获取与所述个人信息相匹配的一个 用户群作为目标用户群。通过用户群分类规则即可将对应的用户分类至相应的用户群,每一信息推送类别与一个用户群对应,,每一信息推送类别中均对应包含至少一条待推送信息,也即是通过信息推送类别即可将待推送信息库中所包含的所有待推送信息进行分类。通过用户分类规则及与人脸信息对应的个人信息,即可将获取与该个人信息相匹配的一个用户群,每一用户群均对应一个信息推送类别,也即是目标用户群,具体的,根据用户分类规则可根据年龄段将用户分至第一大类,根据性别将用户分至第一大类中的第一支类,根据婚恋将用户分至第一支类中的第一子类,根据职业将用户分至第一子类中的第一小类,根据学历获取第一小类中与该用户相匹配的一个用户群作为目标用户群。According to the user classification rules of the information database to be pushed, a user group matching the personal information is obtained as a target user group. According to the user group classification rules, the corresponding users can be classified into the corresponding user groups. Each information push category corresponds to a user group, and each information push category contains at least one piece of information to be pushed, that is, through information Push category can classify all the information to be pushed contained in the information database to be pushed. Through user classification rules and personal information corresponding to the face information, a user group matching the personal information can be obtained, and each user group corresponds to an information push category, that is, the target user group, specifically, According to user classification rules, users can be classified into the first category according to age, users are classified into the first category of the first category according to gender, and users are classified into the first subcategory of the first category according to marriage and love. According to occupation, users are classified into the first sub-category in the first sub-category, and a user group matching the user in the first sub-category is obtained as the target user group according to the educational background.
目标推送信息获取单元143,用于获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。The target push information acquiring unit 143 is configured to acquire the to-be-pushed information contained in the push category of the information corresponding to the target user group in the to-be-push information library as target push information to push the current user.
获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。由于每一用户群均对应一个信息推送类别,获取与个人信息相匹配的目标用户群后,获取该目标用户群对应信息推送类别中所包含的待推送信息,即可得到与个人信息相匹配的目标推送信息,其中,目标推送信息中至少包含一条待推送信息,依次将目标推送信息在用户终端中对当前用户进行推送,即可实现对信息的精准推送。Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user. Since each user group corresponds to an information push category, after obtaining the target user group that matches the personal information, obtain the information to be pushed contained in the information push category corresponding to the target user group, and you can get the information that matches the personal information Target push information, where the target push information contains at least one piece of information to be pushed, and the target push information is sequentially pushed in the user terminal to the current user to achieve accurate push of the information.
上述基于人脸识别的信息推送装置可以实现为计算机程序的形式,该计算机程序可以在如图11所示的计算机设备上运行。请参阅图11,图11是本申请实施例提供的计算机设备的示意性框图。The aforementioned information pushing device based on face recognition can be implemented in the form of a computer program, and the computer program can be run on a computer device as shown in FIG. 11. Please refer to FIG. 11, which is a schematic block diagram of a computer device according to an embodiment of the present application.
参阅图11,该计算机设备500包括通过系统总线501连接的处理器502、存储器和网络接口505,其中,存储器可以包括非易失性存储介质503和内存储器504。Referring to FIG. 11, the computer device 500 includes a processor 502, a memory, and a network interface 505 connected through a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
该非易失性存储介质503可存储操作系统5031和计算机程序5032。该计算机程序5032被执行时,可使得处理器502执行基于人脸识别的信息推送方法。The non-volatile storage medium 503 can store an operating system 5031 and a computer program 5032. When the computer program 5032 is executed, the processor 502 can execute an information push method based on face recognition.
该处理器502用于提供计算和控制能力,支撑整个计算机设备500的运行。The processor 502 is used to provide calculation and control capabilities, and support the operation of the entire computer device 500.
该内存储器504为非易失性存储介质503中的计算机程序5032的运行提供环境,该计算机程序5032被处理器502执行时,可使得处理器502执行基于人脸识别的信息推送方法。The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can make the processor 502 execute an information push method based on face recognition.
该网络接口505用于进行网络通信,如提供数据信息的传输等。本领域技术人员可以理解,图11中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备500的限定,具体的计算机设备500可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。The network interface 505 is used for network communication, such as providing data information transmission. Those skilled in the art can understand that the structure shown in FIG. 11 is only a block diagram of part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device 500 to which the solution of the present application is applied. The specific computer device 500 may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
其中,所述处理器502用于运行存储在存储器中的计算机程序5032,以实现如下功能:若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;若到达预置信息推送时间点,获取当前用户的人脸信息;根据预置人脸识别模型及所述特征向量集对所 述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。Wherein, the processor 502 is configured to run a computer program 5032 stored in the memory to realize the following function: if user information input by the administrator is received, a model is extracted from each photo of the user information according to a preset vector Extract feature vectors in the, to obtain a feature vector set, where the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; The preset face recognition model and the feature vector set recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
在一实施例中,处理器502在执行若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集的步骤时,执行如下操作:对所述用户信息中的每一照片进行去色处理以得到照片集;根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合;根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。In one embodiment, when the processor 502 executes the step of extracting feature vectors from each photo of the user information according to a preset vector extraction model to obtain a feature vector set if the user information input by the administrator is received, Perform the following operations: decolorize each photo in the user information to obtain a photo set; convert the photos in the photo set to obtain a vector set according to the vector conversion rule in the vector extraction model; The feature vector calculation formula in the vector extraction model and the vector set are calculated to obtain the feature vector corresponding to each photo to obtain the feature vector set.
在一实施例中,处理器502在执行根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果的步骤时,执行如下操作:根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量;根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值;根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。In an embodiment, the processor 502 is performing recognition of the face information according to a preset face recognition model and the feature vector set to obtain the recognition of whether the current user is a certain user in the user information In the result step, perform the following operations: obtain the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model; calculate according to the difference calculation formula in the face recognition model The difference value between the face feature vector and each feature vector in the feature vector set; the difference value corresponding to each feature vector is judged according to the difference threshold value in the face recognition model to obtain the difference value in the user information The identification result of whether the current user is a certain user in the user information.
在一实施例中,处理器502在执行根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果的步骤之后,还执行如下操作:若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。In an embodiment, the processor 502 is performing recognition of the face information according to a preset face recognition model and the feature vector set to obtain the recognition of whether the current user is a certain user in the user information After the result step, the following operations are also performed: if the recognition result is that the current user is not a certain user in the user information, a prompt message is issued to the current user to obtain face information again, and the current user's information is obtained again. Face information.
在一实施例中,处理器502在执行根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送的步骤时,执行如下操作:根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息;根据所述待推送信息库的用户分类规则获取所述与所述个人信息相匹配的一个用户群作为目标用户群;获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。In an embodiment, the processor 502 executes the step of acquiring target push information matching the face information from a preset to-be-pushing information database according to the recognition result to push the current user The operations are as follows: obtain personal information corresponding to the face information in the user information according to the recognition result; obtain the user group matching the personal information according to the user classification rule of the information database to be pushed As a target user group; acquiring the information to be pushed contained in the information push category corresponding to the target user group in the information database to be pushed as the target push information to push the current user.
本领域技术人员可以理解,图11中示出的计算机设备的实施例并不构成对计算机设备具体构成的限定,在其他实施例中,计算机设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。例如,在一些实施例中,计算机设备可以仅包括存储器及处理器,在这样的实施例中,存储器及处理器的结构及功能与图11所示实施例一致,在此不再赘述。Those skilled in the art can understand that the embodiment of the computer device shown in FIG. 11 does not constitute a limitation on the specific configuration of the computer device. In other embodiments, the computer device may include more or less components than those shown in the figure. Or combine certain components, or different component arrangements. For example, in some embodiments, the computer device may only include a memory and a processor. In such embodiments, the structures and functions of the memory and the processor are the same as those of the embodiment shown in FIG. 11, which will not be repeated here.
应当理解,在本发明实施例中,处理器502可以是中央处理单元(Central Processing Unit,CPU),该处理器502还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。其中, 通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。It should be understood that, in the embodiment of the present invention, the processor 502 may be a central processing unit (Central Processing Unit, CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (Digital Signal Processors, DSPs), Application Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Wherein, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor.
在本申请的另一实施例中提供计算机可读存储介质。该计算机可读存储介质可以为非易失性的计算机可读存储介质。该计算机可读存储介质存储有计算机程序,其中计算机程序被处理器执行时实现以下步骤:若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;若到达预置信息推送时间点,获取当前用户的人脸信息;根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。In another embodiment of the present application, a computer-readable storage medium is provided. The computer-readable storage medium may be a non-volatile computer-readable storage medium. The computer-readable storage medium stores a computer program, where the computer program is executed by the processor to implement the following steps: if user information input by the administrator is received, a model is extracted from each photo of the user information according to a preset vector The feature vector is extracted to obtain a feature vector set, wherein the user information includes multiple photos, and each photo corresponds to a user; if the preset information push time point is reached, the face information of the current user is obtained; Set the face recognition model and the feature vector set to recognize the face information to obtain the recognition result of whether the current user is a certain user in the user information; if the recognition result is that the current user is the A certain user in the user information obtains target push information that matches the face information from a preset to-be-push information database according to the recognition result to push the current user.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到各种等效的修改或替换,这些修改或替换都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以权利要求的保护范围为准。The above are only specific implementations of this application, but the protection scope of this application is not limited to this. Anyone familiar with the technical field can easily think of various equivalents within the technical scope disclosed in this application. Modifications or replacements, these modifications or replacements shall be covered within the protection scope of this application. Therefore, the protection scope of this application shall be subject to the protection scope of the claims.

Claims (20)

  1. 一种基于人脸识别的信息推送方法,包括:An information push method based on face recognition includes:
    若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;If the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set, wherein the user information includes a plurality of the photos, each One said photo corresponds to one user;
    若到达预置信息推送时间点,获取当前用户的人脸信息;If it reaches the preset information push time point, obtain the current user's face information;
    根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information;
    若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。If the recognition result is that the current user is a certain user in the user information, the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it.
  2. 根据权利要求1所述的基于人脸识别的信息推送方法,所述向量提取模型包括向量转换规则及特征向量计算公式,所述若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,包括:The method for pushing information based on face recognition according to claim 1, wherein the vector extraction model includes a vector conversion rule and a feature vector calculation formula, and if the user information input by the administrator is received, the model is extracted according to a preset vector Extracting a feature vector from each photo of the user information to obtain a feature vector set includes:
    对所述用户信息中的每一照片进行去色处理以得到照片集;Decolorize each photo in the user information to obtain a photo collection;
    根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合;Transform the photos in the photo collection according to the vector conversion rules in the vector extraction model to obtain a vector collection;
    根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。The feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  3. 根据权利要求1所述的基于人脸识别的信息推送方法,所述人脸识别模型包括向量提取规则、差别计算公式计算及差别阈值,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果,包括:The information push method based on face recognition according to claim 1, wherein the face recognition model includes vector extraction rules, difference calculation formula calculations and difference thresholds, and the preset face recognition model and the feature vector set Recognizing the face information to obtain the recognition result of whether the current user is a certain user in the user information includes:
    根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量;Acquiring the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model;
    根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值;Calculating the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model;
    根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。The difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information.
  4. 根据权利要求1所述的基于人脸识别的信息推送方法,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果之后,还包括:The method for pushing information based on face recognition according to claim 1, wherein the face information is recognized according to a preset face recognition model and the feature vector set to obtain whether the current user is the user After the identification result of a certain user in the information, it also includes:
    若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。If the recognition result is that the current user is not a certain user in the user information, a prompt message for obtaining face information again is issued to the current user and the face information of the current user is obtained again.
  5. 根据权利要求1所述的基于人脸识别的信息推送方法,所述待推送信息库中包含多个信息推送类别及用户分类规则,所述根据所述识别结果从预置待 推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送,包括:The method for pushing information based on face recognition according to claim 1, wherein the information library to be pushed includes multiple information pushing categories and user classification rules, and the information is obtained from a preset information library to be pushed according to the recognition result Pushing target information matching the face information to push the current user includes:
    根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息;Acquiring personal information corresponding to the face information in the user information according to the recognition result;
    根据所述待推送信息库的用户分类规则获取所述与所述个人信息相匹配的一个用户群作为目标用户群;Acquiring the user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed;
    获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user.
  6. 一种基于人脸识别的信息推送装置,包括:An information push device based on face recognition includes:
    特征向量提取单元,用于若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;The feature vector extraction unit is configured to extract feature vectors from each photo of the user information according to the preset vector extraction model to obtain a feature vector set if the user information input by the administrator is received, wherein the user information includes A plurality of said photos, each said photo corresponds to a user;
    人脸信息获取单元,用于若到达预置信息推送时间点,获取当前用户的人脸信息;The face information acquiring unit is used to acquire the face information of the current user when the preset information push time point is reached;
    人脸信息识别单元,用于根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;The face information recognition unit is configured to recognize the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information;
    目标推送信息推送单元,用于若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。The target push information push unit is configured to, if the recognition result is that the current user is a certain user in the user information, obtain a target matching the face information from a preset to-be-push information database according to the recognition result Push information to push the current user.
  7. 根据权利要求6所述的基于人脸识别的信息推送装置,所述特征向量提取单元,包括:The information pushing device based on face recognition according to claim 6, wherein the feature vector extraction unit comprises:
    去色单元,用于对所述用户信息中的每一照片进行去色处理以得到照片集;A decolorization unit for decolorizing each photo in the user information to obtain a photo collection;
    向量转换单元,用于根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合;A vector conversion unit, configured to convert the photos in the photo collection according to the vector conversion rules in the vector extraction model to obtain a vector collection;
    特征向量计算单元,用于根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。The feature vector calculation unit is configured to calculate the feature vector corresponding to each photo according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  8. 根据权利要求6所述的基于人脸识别的信息推送装置,所述人脸信息识别单元,包括:The information pushing device based on face recognition according to claim 6, wherein the face information recognition unit comprises:
    人脸特征向量获取单元,用于根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量;A face feature vector obtaining unit, configured to obtain a face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model;
    向量差别值计算单元,用于根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值;The vector difference value calculation unit is configured to calculate the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model;
    差别值判断单元,用于根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。The difference value judging unit is configured to judge the difference value corresponding to each feature vector according to the difference threshold in the face recognition model to obtain whether the current user in the user information is a certain one in the user information The recognition result of a user.
  9. 根据权利要求6所述的基于人脸识别的信息推送装置,所述基于人脸识别的信息推送装置还包括:The information pushing device based on face recognition according to claim 6, the information pushing device based on face recognition further comprising:
    人脸信息再次获取单元,用于若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。The face information reacquisition unit is configured to, if the recognition result is that the current user is not a certain user in the user information, send a prompt message to the current user to obtain face information again and obtain the person of the current user again Face information.
  10. 根据权利要求6所述的基于人脸识别的信息推送装置,所述目标推送信息推送单元,包括:According to the information pushing device based on face recognition of claim 6, the target pushing information pushing unit comprises:
    个人信息获取单元,用于根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息。The personal information obtaining unit is configured to obtain personal information corresponding to the face information in the user information according to the recognition result.
    用户群匹配单元,用于根据所述待推送信息库的用户分类规则获取与所述个人信息相匹配的一个用户群作为目标用户群。The user group matching unit is configured to obtain a user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed.
    目标推送信息获取单元,用于获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。The target push information acquiring unit is configured to acquire the to-be-pushed information contained in the push category of the information corresponding to the target user group in the to-be-push information library as target push information to push the current user.
  11. 一种计算机设备,包括:A computer device including:
    一个或多个处理器;One or more processors;
    存储器;Memory
    一个或多个计算机程序,其中所述一个或多个计算机程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个计算机程序配置用于执行一种基于人脸识别的信息推送方法,其中,所述基于人脸识别的信息推送方法包括以下步骤:One or more computer programs, wherein the one or more computer programs are stored in the memory and configured to be executed by the one or more processors, and the one or more computer programs are configured to execute An information push method based on face recognition, wherein the information push method based on face recognition includes the following steps:
    若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;If the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set, wherein the user information includes a plurality of the photos, each One said photo corresponds to one user;
    若到达预置信息推送时间点,获取当前用户的人脸信息;If it reaches the preset information push time point, obtain the current user's face information;
    根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information;
    若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。If the recognition result is that the current user is a certain user in the user information, the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it.
  12. 根据权利要求11所述的计算机设备,所述向量提取模型包括向量转换规则及特征向量计算公式,所述若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,包括:The computer device according to claim 11, wherein the vector extraction model includes a vector conversion rule and a feature vector calculation formula, and if the user information input by the administrator is received, the vector extraction model from the user information is The feature vector is extracted from each photo to obtain the feature vector set, including:
    对所述用户信息中的每一照片进行去色处理以得到照片集;Decolorize each photo in the user information to obtain a photo collection;
    根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合;Transform the photos in the photo collection according to the vector conversion rules in the vector extraction model to obtain a vector collection;
    根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。The feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  13. 根据权利要求11所述的计算机设备,所述人脸识别模型包括向量提取规则、差别计算公式计算及差别阈值,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果,包括:The computer device according to claim 11, wherein the face recognition model includes a vector extraction rule, a difference calculation formula calculation, and a difference threshold, and the face information is compared with the preset face recognition model and the feature vector set. Performing identification to obtain the identification result of whether the current user is a certain user in the user information includes:
    根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量;Acquiring the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model;
    根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值;Calculating the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model;
    根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。The difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information.
  14. 根据权利要求11所述的计算机设备,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果之后,还包括:The computer device according to claim 11, wherein the face information is recognized according to a preset face recognition model and the feature vector set to obtain whether the current user is a certain user in the user information After identifying the result, it also includes:
    若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。If the recognition result is that the current user is not a certain user in the user information, a prompt message for obtaining face information again is issued to the current user and the face information of the current user is obtained again.
  15. 根据权利要求11所述的计算机设备,所述待推送信息库中包含多个信息推送类别及用户分类规则,所述根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送,包括:The computer device according to claim 11, wherein the information library to be pushed includes multiple information push categories and user classification rules, and the facial information is obtained from a preset information library to be pushed according to the recognition result. The matched target push information to push the current user includes:
    根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息;Acquiring personal information corresponding to the face information in the user information according to the recognition result;
    根据所述待推送信息库的用户分类规则获取所述与所述个人信息相匹配的一个用户群作为目标用户群;Acquiring the user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed;
    获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user.
  16. 一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,该计算机程序被处理器执行时实现一种基于人脸识别的信息推送方法,其中,所述基于人脸识别的信息推送方法包括以下步骤:A computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, a method for pushing information based on face recognition is implemented, wherein the The information push method includes the following steps:
    若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,其中,所述用户信息包括多张所述照片,每一所述照片对应一个用户;If the user information input by the administrator is received, a feature vector is extracted from each photo of the user information according to a preset vector extraction model to obtain a feature vector set, wherein the user information includes a plurality of the photos, each One said photo corresponds to one user;
    若到达预置信息推送时间点,获取当前用户的人脸信息;If it reaches the preset information push time point, obtain the current user's face information;
    根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果;Recognizing the face information according to a preset face recognition model and the feature vector set to obtain a recognition result of whether the current user is a certain user in the user information;
    若识别结果为所述当前用户为所述用户信息中某一用户,根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送。If the recognition result is that the current user is a certain user in the user information, the target push information matching the facial information is obtained from the preset to-be-push information database according to the recognition result to send information to the current user Push it.
  17. 根据权利要求16所述的计算机可读存储介质,所述向量提取模型包括向量转换规则及特征向量计算公式,所述若接收到管理员所输入的用户信息,根据预置向量提取模型从所述用户信息的每一照片中提取特征向量以得到特征向量集,包括:The computer-readable storage medium according to claim 16, wherein the vector extraction model includes a vector conversion rule and a feature vector calculation formula, and if the user information input by the administrator is received, the vector extraction model is selected from the The feature vector is extracted from each photo of the user information to obtain a feature vector set, including:
    对所述用户信息中的每一照片进行去色处理以得到照片集;Decolorize each photo in the user information to obtain a photo collection;
    根据所述向量提取模型中的向量转换规则对所述照片集中的照片进行转换以得到向量集合;Transform the photos in the photo collection according to the vector conversion rules in the vector extraction model to obtain a vector collection;
    根据所述向量提取模型中的特征向量计算公式及所述向量集合计算得到每一所述照片对应的特征向量以得到特征向量集。The feature vector corresponding to each photo is calculated according to the feature vector calculation formula in the vector extraction model and the vector set to obtain a feature vector set.
  18. 根据权利要求16所述的计算机可读存储介质,所述人脸识别模型包括 向量提取规则、差别计算公式计算及差别阈值,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果,包括:The computer-readable storage medium according to claim 16, wherein the face recognition model includes a vector extraction rule, a difference calculation formula calculation, and a difference threshold, and the face recognition model and the feature vector set are used to compare the Recognizing face information to obtain the recognition result of whether the current user is a certain user in the user information includes:
    根据所述人脸识别模型中的向量提取规则获取与所述人脸信息相对应的人脸特征向量;Acquiring the face feature vector corresponding to the face information according to the vector extraction rule in the face recognition model;
    根据所述人脸识别模型中的差别计算公式计算得到所述人脸特征向量与特征向量集中每一特征向量的差别值;Calculating the difference value between the face feature vector and each feature vector in the feature vector set according to the difference calculation formula in the face recognition model;
    根据所述人脸识别模型中的差别阈值对每一所述特征向量对应的差别值进行判断以得到所述用户信息中所述当前用户是否为所述用户信息中某一用户的识别结果。The difference value corresponding to each feature vector is judged according to the difference threshold in the face recognition model to obtain the recognition result of whether the current user in the user information is a certain user in the user information.
  19. 根据权利要求16所述的计算机可读存储介质,所述根据预置人脸识别模型及所述特征向量集对所述人脸信息进行识别以得到所述当前用户是否为所述用户信息中某一用户的识别结果之后,还包括:The computer-readable storage medium according to claim 16, wherein the face information is recognized according to a preset face recognition model and the feature vector set to obtain whether the current user is one of the user information After a user’s identification result, it also includes:
    若识别结果为所述当前用户不是所述用户信息中某一用户,向所述当前用户发出再次获取人脸信息的提示信息并再次获取所述当前用户的人脸信息。If the recognition result is that the current user is not a certain user in the user information, a prompt message for obtaining face information again is issued to the current user and the face information of the current user is obtained again.
  20. 根据权利要求16所述的计算机可读存储介质,所述待推送信息库中包含多个信息推送类别及用户分类规则,所述根据所述识别结果从预置待推送信息库中获取与所述人脸信息相匹配的目标推送信息以对所述当前用户进行推送,包括:The computer-readable storage medium according to claim 16, wherein the to-be-pushed information database contains a plurality of information push categories and user classification rules, and the identification result is obtained from a preset to-be-pushed information database and the The target pushing information that matches the facial information to push the current user includes:
    根据所述识别结果获取所述用户信息中与所述人脸信息对应的个人信息;Acquiring personal information corresponding to the face information in the user information according to the recognition result;
    根据所述待推送信息库的用户分类规则获取所述与所述个人信息相匹配的一个用户群作为目标用户群;Acquiring the user group matching the personal information as a target user group according to the user classification rule of the information database to be pushed;
    获取所述待推送信息库中与所述目标用户群对应信息推送类别中所包含的待推送信息作为目标推送信息以对所述当前用户进行推送。Obtain the to-be-push information contained in the information push category corresponding to the target user group in the to-be-push information database as the target push information to push the current user.
PCT/CN2020/087133 2019-07-05 2020-04-27 Information pushing method and apparatus based on face recognition and computer device WO2021004137A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910605454.4A CN110442783A (en) 2019-07-05 2019-07-05 Information-pushing method, device based on recognition of face, computer equipment
CN201910605454.4 2019-07-05

Publications (1)

Publication Number Publication Date
WO2021004137A1 true WO2021004137A1 (en) 2021-01-14

Family

ID=68429223

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/087133 WO2021004137A1 (en) 2019-07-05 2020-04-27 Information pushing method and apparatus based on face recognition and computer device

Country Status (2)

Country Link
CN (1) CN110442783A (en)
WO (1) WO2021004137A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113836418A (en) * 2021-09-27 2021-12-24 百度在线网络技术(北京)有限公司 Data pushing method and device, electronic equipment and storage medium

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110442783A (en) * 2019-07-05 2019-11-12 深圳壹账通智能科技有限公司 Information-pushing method, device based on recognition of face, computer equipment
CN111311355A (en) * 2020-01-20 2020-06-19 深圳市博乐信息技术有限公司 Method and module for pushing by applying identity recognition and AR pushing system
CN111339420A (en) * 2020-02-28 2020-06-26 北京市商汤科技开发有限公司 Image processing method, image processing device, electronic equipment and storage medium
CN114201741B (en) * 2022-02-18 2022-05-06 北京派瑞威行互联技术有限公司 Method, device and machine-readable storage medium for information processing

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103699594A (en) * 2013-12-11 2014-04-02 深圳先进技术研究院 Information push method and information push system
CN108595628A (en) * 2018-04-24 2018-09-28 百度在线网络技术(北京)有限公司 Method and apparatus for pushed information
CN109299709A (en) * 2018-12-04 2019-02-01 中山大学 Data recommendation method, device, server end and client based on recognition of face
CN109523344A (en) * 2018-10-16 2019-03-26 深圳壹账通智能科技有限公司 Product information recommended method, device, computer equipment and storage medium
CN110442783A (en) * 2019-07-05 2019-11-12 深圳壹账通智能科技有限公司 Information-pushing method, device based on recognition of face, computer equipment

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103942705A (en) * 2014-03-25 2014-07-23 惠州Tcl移动通信有限公司 Advertisement classified match pushing method and system based on human face recognition
CN109558535B (en) * 2018-11-05 2020-08-07 重庆中科云从科技有限公司 Personalized article pushing method and system based on face recognition

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103699594A (en) * 2013-12-11 2014-04-02 深圳先进技术研究院 Information push method and information push system
CN108595628A (en) * 2018-04-24 2018-09-28 百度在线网络技术(北京)有限公司 Method and apparatus for pushed information
CN109523344A (en) * 2018-10-16 2019-03-26 深圳壹账通智能科技有限公司 Product information recommended method, device, computer equipment and storage medium
CN109299709A (en) * 2018-12-04 2019-02-01 中山大学 Data recommendation method, device, server end and client based on recognition of face
CN110442783A (en) * 2019-07-05 2019-11-12 深圳壹账通智能科技有限公司 Information-pushing method, device based on recognition of face, computer equipment

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113836418A (en) * 2021-09-27 2021-12-24 百度在线网络技术(北京)有限公司 Data pushing method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN110442783A (en) 2019-11-12

Similar Documents

Publication Publication Date Title
WO2021004137A1 (en) Information pushing method and apparatus based on face recognition and computer device
US10405052B2 (en) Method and apparatus for identifying television channel information
US11074436B1 (en) Method and apparatus for face recognition
US9367756B2 (en) Selection of representative images
CN108446390B (en) Method and device for pushing information
US8750573B2 (en) Hand gesture detection
US8792722B2 (en) Hand gesture detection
WO2019109526A1 (en) Method and device for age recognition of face image, storage medium
US9589205B2 (en) Systems and methods for identifying a user's demographic characteristics based on the user's social media photographs
US9262614B2 (en) Image processing device, image processing method, and storage medium storing image processing program
US8571332B2 (en) Methods, systems, and media for automatically classifying face images
US11455831B2 (en) Method and apparatus for face classification
US20210334604A1 (en) Facial recognition method and apparatus
WO2012173401A2 (en) Image processing method and apparatus
CN109582813B (en) Retrieval method, device, equipment and storage medium for cultural relic exhibit
CN111814655B (en) Target re-identification method, network training method thereof and related device
CN106056083B (en) A kind of information processing method and terminal
WO2020078215A1 (en) Video-based information acquisition method and device
WO2020135756A1 (en) Video segment extraction method, apparatus and device, and computer-readable storage medium
CN109241299B (en) Multimedia resource searching method, device, storage medium and equipment
CN111582027B (en) Identity authentication method, identity authentication device, computer equipment and storage medium
CN111666907A (en) Method and device for identifying object information in video and server
US20110081074A1 (en) Method of Computing Global-to-Local Metrics for Recognition
CN110717401A (en) Age estimation method and device, equipment and storage medium
WO2023123923A1 (en) Human body weight identification method, human body weight identification device, computer device, and medium

Legal Events

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

Ref document number: 20836616

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205 DATED 16/05/2022)

122 Ep: pct application non-entry in european phase

Ref document number: 20836616

Country of ref document: EP

Kind code of ref document: A1