Access control method, device, equipment and storage medium based on face recognition
By combining visible light and infrared light image merging processing and emotion recognition algorithms in the access control system, the psychological state of personnel is analyzed, which solves the problem of low psychological warning effect in the existing technology and achieves more accurate early warning and guidance of psychological problems. , improving the mental health monitoring capabilities of the access control system.
Patent Information
- Application Number
- CN202010734141.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-27
- Publication Date
- 2024-09-17
- Estimated Expiration
- 2040-07-27
AI Technical Summary
Existing deep learning based on visible light images to analyze facial expressions is not accurate enough for early warning of psychological problems, and the access control system fails to effectively combine psychological counseling and cannot effectively warn and guide people with psychological problems.
Using an access control method based on face recognition, by merging visible light and infrared light images, combined with preset emotion recognition algorithms, the identity information, emotion type and emotion intensity of the person are analyzed, and the door opening instructions and emotion reports are sent to the access control system. , to achieve more accurate analysis and guidance of psychological states.
It improves the early warning effect and accuracy of psychological problems, can detect and guide people with negative emotions early, and enhances the ability of the access control system to monitor mental health.
Smart Images

Figure CN111881822B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of face recognition, and in particular to a door access control method, device, equipment and storage medium based on face recognition. Background Art
[0002] As artificial intelligence surpasses humans in the field of Go, the field of deep learning of artificial intelligence has attracted widespread attention. People's exploration of deep learning has continuously applied the initial neural network to various fields. In the field of security, face recognition has gradually become a hot direction in the security field. Through face recognition, functions such as online payment, searching for missing children, and verification of access control personnel can be realized, and it is becoming more and more deeply integrated into people's lives.
[0003] However, the ever-growing economy has accelerated the pace of life and study, and people's psychological problems have become increasingly prominent. The occurrence of many events has made people pay more and more attention to people's mental health. Face recognition technology is used to analyze facial expressions to analyze people's mental state, which is used to warn and guide people with psychological problems. However, the existing deep learning analysis of people's mental state based on visible light images is not accurate enough, and the access control system does not combine psychological counseling issues. An access control system with higher accuracy in analyzing psychological states is needed to warn and guide people's psychological problems. Summary of the invention
[0004] The main purpose of the present invention is to solve the technical problem that the warning effect of the existing face recognition warning psychological problems is low.
[0005] A first aspect of the present invention provides an access control method based on face recognition, the access control method based on face recognition comprising:
[0006] Acquire a visible light image and an infrared light image of the door opening verification person, and merge the visible light image and the infrared light image to generate a feature image;
[0007] According to a preset emotion recognition algorithm, the characteristic image is analyzed to obtain the identity information and emotion type of the door opening verification person, and the emotion intensity corresponding to the emotion type;
[0008] Determining whether the identity information is in a preset permitted personnel list;
[0009] If the person is in the preset list of permitted personnel, a door opening command is sent to the preset electronic door lock, and the emotion type and the emotion intensity are written into the preset emotion record table;
[0010] According to the emotion record form, an emotion report of the door opening verification personnel is generated, and the emotion report is sent to the management device.
[0011] Optionally, in a first implementation manner of the first aspect of the present invention, the merging the visible light image and the infrared light image to generate a feature image includes:
[0012] According to a preset decomposition quantity parameter, the visible light image and the infrared light image are equally divided horizontally or vertically to obtain a visible light atlas and an infrared light atlas;
[0013] The visible light atlas and the infrared light atlas are cross-joined to obtain a feature image.
[0014] Optionally, in a second implementation of the first aspect of the present invention, parsing the feature image according to a preset emotion recognition algorithm to obtain the identity information and emotion type of the door opening verification person, and obtaining the emotion intensity corresponding to the emotion type includes:
[0015] Based on a preset emotion recognition algorithm, grayscale processing is performed on the feature image to obtain a grayscale feature image;
[0016] Performing vectorization processing on the grayscale image to obtain a feature vector matrix;
[0017] According to the analysis neural network in the emotion recognition algorithm, the feature vector matrix is convolved to obtain a feature convolution vector;
[0018] Normalizing the feature convolution vector to generate a feature result probability matrix;
[0019] The identity information and emotion type of the door opening verification person are determined based on the characteristic result probability matrix, and the emotion intensity corresponding to the emotion type is obtained.
[0020] Optionally, in a third implementation manner of the first aspect of the present invention, the vectorizing the grayscale image to obtain a feature vector matrix includes:
[0021] Reading the grayscale value data of each pixel in the grayscale image;
[0022] Arranging all the gray value data according to the distribution of each pixel in the grayscale image to obtain a preliminary vector matrix;
[0023] The preliminary vector matrix is fitted to obtain a characteristic vector matrix.
[0024] Optionally, in a fourth implementation manner of the first aspect of the present invention, the normalizing the feature convolution vector to generate a feature result probability matrix includes:
[0025] Obtain a preset weight matrix, and multiply the feature convolution vector by the weight matrix to obtain a weighted feature matrix;
[0026] Use the preset regression function to perform regression calculation on each element in the weighted feature matrix to obtain the regression value corresponding to each element
[0027] Each element in the weighted feature matrix is replaced with a regression value corresponding to the element, and the replaced weighted feature matrix is normalized to obtain a feature result probability matrix.
[0028] Optionally, in a fifth implementation of the first aspect of the present invention, generating an emotion report of the door opening verification personnel according to the emotion record form, and sending the emotion report to the management device includes:
[0029] Reading preset emotion monitoring data, wherein the emotion monitoring data includes: emotion monitoring type and emotion intensity threshold value corresponding to the emotion monitoring type;
[0030] Capture the emotion type and emotion intensity corresponding to the emotion monitoring type in the emotion record table, and generate a monitoring list;
[0031] Determine whether there is an emotion intensity in the monitoring list that is greater than the corresponding emotion intensity threshold;
[0032] If it exists, mark the emotion intensity greater than the corresponding emotion intensity threshold, and mark the emotion type corresponding to the emotion intensity;
[0033] According to the marked emotion type and emotion intensity, an emotion report of the door opening verification personnel is generated, and the emotion report is sent to the management device.
[0034] Optionally, in a sixth implementation of the first aspect of the present invention, after generating an emotion report of the door opening verification personnel according to the emotion record form and sending the emotion report to the management device, the method further includes:
[0035] Acquire the marked person information sent by the management device, wherein the marked person information is recorded in the permitted person list;
[0036] When the identity information corresponding to the marked person information is obtained through parsing, the emotion type corresponding to the marked person information and the emotion intensity corresponding to the emotion type are sent to the management device.
[0037] A second aspect of the present invention provides a door access control device based on face recognition, comprising:
[0038] An acquisition module is used to acquire a visible light image and an infrared light image of a door opening verification person, and to combine the visible light image and the infrared light image to generate a feature image;
[0039] The parsing module is used to parse the feature image according to a preset emotion recognition algorithm, obtain the identity information and emotion type of the door opening verification person, and obtain the emotion intensity corresponding to the emotion type;
[0040] A judging module, used to judge whether the identity information is in a preset permitted personnel list;
[0041] A recording module, for sending a door opening command to a preset electronic door lock if the person is in the preset permitted personnel list, and writing the emotion type and the emotion intensity into a preset emotion recording table;
[0042] The sending module is used to generate an emotion report of the door opening verification personnel according to the emotion record form, and send the emotion report to the management device.
[0043] The third aspect of the present invention provides a face recognition-based access control device, comprising: a memory and at least one processor, the memory storing instructions, the memory and the at least one processor being interconnected through lines; the at least one processor calling the instructions in the memory so that the face recognition-based access control device executes the above-mentioned face recognition-based access control method.
[0044] A fourth aspect of the present invention provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is run on a computer, the computer executes the above-mentioned access control method based on face recognition. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 Schematic diagram of a first embodiment of a door access control method based on face recognition in an embodiment of the present invention;
[0046] Figure 2 Schematic diagram of a second embodiment of the access control method based on face recognition in an embodiment of the present invention;
[0047] Figure 3 Schematic diagram of a third embodiment of a door access control method based on face recognition in an embodiment of the present invention;
[0048] Figure 4 Schematic diagram of an embodiment of a door access control device based on face recognition in an embodiment of the present invention;
[0049] Figure 5 Schematic diagram of another embodiment of a door access control device based on face recognition in an embodiment of the present invention;
[0050] Figure 6 The figure is a schematic diagram of an embodiment of a door access control device based on face recognition in an embodiment of the present invention. DETAILED DESCRIPTION
[0051] The embodiments of the present invention provide a door access control method, device, equipment and storage medium based on face recognition.
[0052] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" or "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0053] For ease of understanding, the specific process of the embodiment of the present invention is described below. Figure 1 The first embodiment of the access control method based on face recognition in the embodiment of the present invention includes:
[0054] 101. Obtaining a visible light image and an infrared light image of the door opening verification person, and merging the visible light image and the infrared light image to generate a feature image;
[0055] In this embodiment, the facial expression of the door opening verification personnel cannot fully reflect their psychological state, so it is necessary to supplement the features of the infrared light image and monitor the temperature of the facial part. The visible light image and infrared light image collected at the same time are merged. In the merging process, the layer overlay method can be used to directly combine them into a feature image, or they can be directly spliced to generate a feature image with the visible light image on the left and the infrared light image on the right. In the merging process, the temperature of the infrared light image can also be directly read to generate a temperature matrix, and then the temperature value is processed by function, and a weighted merging calculation is performed with the optical matrix of the visible light image, and finally a processed merged matrix is obtained, and the matrix is used as the feature image.
[0056] 102. According to a preset emotion recognition algorithm, the feature image is analyzed to obtain the identity information and emotion type of the door opening verification person, and the emotion intensity corresponding to the emotion type;
[0057] In this embodiment, the feature image is vectorized to obtain a matrix corresponding to the feature image. In the process of obtaining the vectorization of the matrix, the image can be first denoised and then vectorized. The obtained matrix is convolutionally calculated, and finally the activation layer is used to finally obtain the identity information and emotion type of the door opening verification personnel, and the emotion intensity can be obtained when the emotion type is obtained. The emotion intensity can be represented by numbers from 1 to 10, and the larger the intensity value, the greater the emotion. For example, the result is: {identity: AAQ, student number (work number): 1520, gender: male, current emotion type: anger, emotion intensity: 5}, and the emotion types can be classified into 25 categories: admiration, worship, appreciation, entertainment, anxiety, awe, embarrassment, boredom, calmness, confusion, desire, disgust, pain, anger, jealousy, excitement, fear, hatred, fun, happiness, nostalgia, sadness, satisfaction, sympathy, satisfaction, etc.
[0058] 103. Determine whether the identity information is in the preset permitted personnel list;
[0059] In this embodiment, the types of personnel in the permitted personnel list are pre-recorded, and the student ID (work ID) can be used to match whether it is in the permitted list. For example: {identity: AAQ, student ID (work ID): 1520, gender: male, current emotion type: angry, emotion intensity: 5}, the personnel information recorded in the permitted personnel list includes student IDs (work IDs) 1-1510, and the identified information is not in the permitted personnel list.
[0060] 104. If the person is in the preset permitted personnel list, a door opening command is sent to the preset electronic door lock, and the emotion type and emotion intensity are written into the preset emotion record table;
[0061] In this embodiment, if the match is successful, after sending the door opening command to the electronic door lock to unlock, the emotions and emotional intensity of the personnel are recorded, and the emotional recording table exists as a basic data table for recording emotions. The time can be recorded at the same time, for example, {student number: 480 emotion type: jealousy emotion intensity: 8 date: 2020.1.15, student number: 480 emotion type: jealousy emotion intensity: 7 date: 2020.1.17, student number: 487 emotion type: sad emotion intensity: 4 date: 2020.1.17}.
[0062] 105. Generate an emotion report of the door opening verification personnel based on the emotion record form, and send the emotion report to the management device.
[0063] In this embodiment, conditions for generating reports are set. For example, negative emotions: pain, disgust, jealousy, anxiety, hatred, sadness, etc., need to be reported if the intensity of the emotion is greater than 5. The analysis shows {identity: AAQ, student number (work number): 1520, gender: male, current emotion type: anger, emotion intensity: 8}, then the information should be reported, indicating the type of negative emotions of the personnel, and the opening time: 2020.7.14. The report generation condition can also be set to negative emotions: pain, disgust, jealousy, anxiety, hatred, sadness are detected more than 5 times within 2 days, then the records exceeding 5 times will be captured, and a record form will be generated, and then the record form and the corresponding record time will be sent to the management device.
[0064] In the embodiment of the present invention, by increasing feature acquisition and performing face recognition on the image, the emotional judgment of the verification person is performed when the access control is unlocked, warnings are given to people with negative emotions, and people with negative emotions are discovered and guided early, thereby improving the warning effect and accuracy of psychological problems.
[0065] See also Figure 2 , a second embodiment of the access control method based on face recognition in the embodiment of the present invention includes:
[0066] 201. Obtaining visible light images and infrared light images of the door opening verification personnel;
[0067] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0068] 202. According to a preset decomposition quantity parameter, the visible light image and the infrared light image are equally divided horizontally or vertically to obtain a visible light atlas and an infrared light atlas;
[0069] In this embodiment, the decomposition quantity parameter is 1000, the visible light image and the infrared light image are divided into 1000 equal parts horizontally, and then the 1000 parts are labeled as 1-1000 according to the sorting order to generate a visible light atlas and an infrared light atlas.
[0070] 203. Cross-join the visible light atlas and the infrared light atlas to obtain a feature image;
[0071] In this embodiment, the visible light atlas element No. 1 is arranged first and then the infrared light atlas element No. 1, and then the visible light atlas element No. 2 is arranged and then the visible light atlas element No. 2 is arranged, and the cross-stitching continues until element No. 1000 to obtain a feature image.
[0072] 204. Based on a preset emotion recognition algorithm, grayscale processing is performed on the feature image to obtain a grayscale feature image;
[0073] In this embodiment, the color values of the three channels R=B=G in the characteristic image are set to be equal, so that a grayscale characteristic image is obtained.
[0074] 205. Read the gray value data of each pixel in the grayscale image;
[0075] In this embodiment, the grayscale value of each pixel is read, for example, grayscale values such as 10, 15, 14, 13, 17, 25, 25, 0, 0. A grayscale correction algorithm can also be used:
[0076]
[0077] Grey is the grayscale value, R is the red channel value, G is the green channel value, and B is the blue channel value.
[0078] 206. Arrange all gray value data according to the distribution of each pixel in the grayscale image to obtain a preliminary vector matrix;
[0079] In this embodiment, the gray values are arranged according to the distribution to generate a matrix, for example:
[0080]
[0081] This vector matrix is used as a preliminary vector matrix.
[0082] 207. Perform fitting processing on the preliminary vector matrix to obtain a characteristic vector matrix;
[0083] In this embodiment, the purpose of fitting is to prevent some features from being too prominent. The fitting formula can be that all elements of the entire matrix are used:
[0084] f(x)=e x -45
[0085] Calculation is performed, f(x) is the element after calculation, and x is the element of the preliminary vector matrix.
[0086] 208. According to the analysis neural network in the emotion recognition algorithm, convolution processing is performed on the feature vector matrix to obtain a feature convolution vector;
[0087] In this embodiment, the feature vector is in the shape of N*M, and the convolution vector is 2*2. In order to extract as many features as possible, the convolution layer is 80-120 layers, and finally a feature convolution vector is obtained.
[0088] 209. Obtain a preset weight matrix, multiply the feature convolution vector by the weight matrix, and obtain a weighted feature matrix;
[0089] In this embodiment, the feature convolution vector is in the shape of A*B, the weight matrix is B*1, and finally a weighted feature matrix of A*1 is obtained.
[0090] 210. Use a preset regression function to perform regression calculation on each element in the weighted feature matrix to obtain a regression value corresponding to each element;
[0091] In this embodiment, the regression calculation formula is: f(x)=e x , where f(x) is the regression value of the element and x is the element value.
[0092] 211. Replace each element in the weighted feature matrix with the regression value corresponding to the element, and perform normalization calculation on the replaced weighted feature matrix to obtain a feature result probability matrix;
[0093] In this embodiment, the normalized calculation formula is:
[0094]
[0095] Among them, F(x) is the normalized formula, f(x) is the regression value, Regression value sum of all elements.
[0096] 212. Determine the identity information and emotion type of the door opening verification person according to the feature result probability matrix, and obtain the emotion intensity corresponding to the emotion type;
[0097] In this embodiment, [0.012, 0.088, 0.105, 0.795, 0, 0, 0, 0, ..., 0, 0] T is the feature result probability, and finally the identity information and emotion type corresponding to the probability of 0.795 are obtained, and the emotion intensity corresponding to the emotion type.
[0098] 213. Determine whether the identity information is in the preset permitted personnel list;
[0099] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0100] 214. If the person is in the preset list of permitted personnel, a door opening command is sent to the preset electronic door lock, and the emotion type and emotion intensity are written into the preset emotion record table;
[0101] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0102] 215. Generate an emotion report of the door opening verification personnel based on the emotion record form, and send the emotion report to the management device.
[0103] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0104] In the embodiment of the present invention, by increasing feature acquisition and performing face recognition on the image, the emotional judgment of the verification person is performed when the access control is unlocked, warnings are given to people with negative emotions, and people with negative emotions are discovered and guided early, thereby improving the warning effect and accuracy of psychological problems.
[0105] See also Figure 3 , a third embodiment of the access control method based on face recognition in the embodiment of the present invention includes:
[0106] 301. Obtaining a visible light image and an infrared light image of the door opening verification person, and merging the visible light image and the infrared light image to generate a feature image;
[0107] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0108] 302. Analyze the feature image according to a preset emotion recognition algorithm to obtain the identity information and emotion type of the door opening verification person, and obtain the emotion intensity corresponding to the emotion type;
[0109] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0110] 303. Determine whether the identity information is in the preset permitted personnel list;
[0111] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0112] 304. If the person is in the preset permitted personnel list, a door opening command is sent to the preset electronic door lock, and the emotion type and emotion intensity are written into the preset emotion record table;
[0113] The method embodiment described in this embodiment is similar to the first embodiment. You can refer to the corresponding process in the aforementioned method embodiment, which will not be described again.
[0114] 305. Read preset emotion monitoring data, wherein the emotion monitoring data includes: emotion monitoring types and emotion intensity thresholds corresponding to the emotion monitoring types;
[0115] In this embodiment, the emotion type can be one or more of: admiration, worship, appreciation, entertainment, anxiety, awe, embarrassment, boredom, calmness, confusion, desire, disgust, pain, anger, jealousy, excitement, fear, hatred, fun, happiness, nostalgia, sadness, satisfaction, sympathy, and contentment. For example, the emotion monitoring data requires monitoring: excitement emotion, the emotion intensity threshold is 2; hatred emotion, the emotion intensity threshold is 5.
[0116] 306. Capture the emotion type and emotion intensity corresponding to the emotion monitoring type in the emotion record table, and generate a monitoring list;
[0117] In this embodiment, in the emotion record table, all people's excitement and hatred emotions and the corresponding emotion intensity are captured to generate a monitoring list.
[0118] 307. Determine whether there is an emotion intensity in the monitoring list that is greater than the corresponding emotion intensity threshold;
[0119] In this embodiment, it is determined whether the emotion intensity in the monitoring list is greater than 2, and it is determined whether the hatred emotion is greater than 5.
[0120] 308. If present, mark the emotion intensity greater than the corresponding emotion intensity threshold, and mark the emotion type corresponding to the emotion intensity;
[0121] In this embodiment, the case where the intensity of the excitement emotion is greater than 2 is marked, and the corresponding excitement emotion is marked, and the case where the intensity of the hatred emotion is greater than 5 is marked, and the corresponding hatred emotion is marked.
[0122] 309. Generate an emotion report of the door opening verification personnel according to the marked emotion type and emotion intensity, and send the emotion report to the management device;
[0123] In this embodiment, the emotional intensities corresponding to the marked hatred emotions and excitement emotions are listed, a report is generated, and the report is sent to a management device, which may be a mobile phone or an email.
[0124] 310 obtaining the marked person information sent by the management device, wherein the marked person information is recorded in the permitted person list;
[0125] In this embodiment, a key person to be monitored is received, for example, {mark monitoring: employee number 1021, name WEQ, gender male}, and the information marked for monitoring is in the permitted personnel list.
[0126] 311. When the identity information corresponding to the marked person information is obtained through parsing, the emotion type corresponding to the marked person information and the emotion intensity corresponding to the emotion type are sent to the management device.
[0127] In this embodiment, when the information {employee number 1021, name WEQ, gender male} is parsed and obtained, the emotion {employee number 1021, name WEQ, gender male, emotion type: happy, emotion intensity: 8} monitored at this time is immediately sent to the set mobile phone, mailbox, and folder to complete real-time monitoring of the psychological state of the monitored personnel.
[0128] In the embodiment of the present invention, by increasing feature acquisition and performing face recognition on the image, the emotional judgment of the verification person is performed when the access control is unlocked, warnings are given to people with negative emotions, and people with negative emotions are discovered and guided early, thereby improving the warning effect and accuracy of psychological problems.
[0129] The above describes the access control method based on face recognition in the embodiment of the present invention. The following describes the access control device based on face recognition in the embodiment of the present invention. Figure 4 In one embodiment of the present invention, an access control device based on face recognition includes:
[0130] The acquisition module 401 is used to acquire the visible light image and the infrared light image of the door opening verification person, and merge the visible light image and the infrared light image to generate a feature image;
[0131] The parsing module 402 is used to parse the feature image according to a preset emotion recognition algorithm, obtain the identity information and emotion type of the door opening verification person, and obtain the emotion intensity corresponding to the emotion type;
[0132] A determination module 403 is used to determine whether the identity information is in a preset permitted personnel list;
[0133] The recording module 404 is used to send a door opening command to a preset electronic door lock if the person is in the preset permitted personnel list, and write the emotion type and the emotion intensity into a preset emotion recording table;
[0134] The sending module 405 is used to generate an emotion report of the door opening verification personnel according to the emotion record form, and send the emotion report to the management device.
[0135] In the embodiment of the present invention, by increasing feature acquisition and performing face recognition on the image, the emotional judgment of the verification person is performed when the access control is unlocked, warnings are given to people with negative emotions, and people with negative emotions are discovered and guided early, thereby improving the warning effect and accuracy of psychological problems.
[0136] See also Figure 5 Another embodiment of the access control device based on face recognition in the embodiment of the present invention includes:
[0137] The acquisition module 401 is used to acquire the visible light image and the infrared light image of the door opening verification person, and merge the visible light image and the infrared light image to generate a feature image;
[0138] The parsing module 402 is used to parse the feature image according to a preset emotion recognition algorithm, obtain the identity information and emotion type of the door opening verification person, and obtain the emotion intensity corresponding to the emotion type;
[0139] A determination module 403 is used to determine whether the identity information is in a preset permitted personnel list;
[0140] The recording module 404 is used to send a door opening command to a preset electronic door lock if the person is in the preset permitted personnel list, and write the emotion type and the emotion intensity into a preset emotion recording table;
[0141] The sending module 405 is used to generate an emotion report of the door opening verification personnel according to the emotion record form, and send the emotion report to the management device.
[0142] The acquisition module 401 is specifically used for:
[0143] According to a preset decomposition quantity parameter, the visible light image and the infrared light image are equally divided horizontally or vertically to obtain a visible light atlas and an infrared light atlas;
[0144] The visible light atlas and the infrared light atlas are cross-joined to obtain a feature image.
[0145] Wherein, the parsing module 402 includes:
[0146] A grayscale unit 4021 is used to perform grayscale processing on the feature image based on a preset emotion recognition algorithm to obtain a grayscale feature image;
[0147] A vectorization unit 4022, used for performing vectorization processing on the grayscale image to obtain a feature vector matrix;
[0148] A convolution unit 4023, configured to perform convolution processing on the feature vector matrix according to the analysis neural network in the emotion recognition algorithm to obtain a feature convolution vector;
[0149] A normalization unit 4024 is used to perform normalization processing on the feature convolution vector to generate a feature result probability matrix;
[0150] The determination unit 4025 is used to determine the identity information and emotion type of the door opening verification person according to the characteristic result probability matrix, and obtain the emotion intensity corresponding to the emotion type.
[0151] The vectorization unit 4022 is specifically used for:
[0152] Reading the grayscale value data of each pixel in the grayscale image;
[0153] Arranging all the gray value data according to the distribution of each pixel in the grayscale image to obtain a preliminary vector matrix;
[0154] The preliminary vector matrix is fitted to obtain a characteristic vector matrix.
[0155] The normalization unit 4024 is specifically used for:
[0156] Obtain a preset weight matrix, and multiply the feature convolution vector by the weight matrix to obtain a weighted feature matrix;
[0157] Use the preset regression function to perform regression calculation on each element in the weighted feature matrix to obtain the regression value corresponding to each element
[0158] Each element in the weighted feature matrix is replaced with a regression value corresponding to the element, and the replaced weighted feature matrix is normalized to obtain a feature result probability matrix.
[0159] The sending module 405 is specifically used for:
[0160] Reading preset emotion monitoring data, wherein the emotion monitoring data includes: emotion monitoring type and emotion intensity threshold value corresponding to the emotion monitoring type;
[0161] Capture the emotion type and emotion intensity corresponding to the emotion monitoring type in the emotion record table, and generate a monitoring list;
[0162] Determine whether there is an emotion intensity in the monitoring list that is greater than the corresponding emotion intensity threshold;
[0163] If it exists, mark the emotion intensity greater than the corresponding emotion intensity threshold, and mark the emotion type corresponding to the emotion intensity;
[0164] According to the marked emotion type and emotion intensity, an emotion report of the door opening verification personnel is generated, and the emotion report is sent to the management device.
[0165] The access control device based on face recognition includes a marking module 406, and the marking module 406 is specifically used for:
[0166] Acquire the marked person information sent by the management device, wherein the marked person information is recorded in the permitted person list;
[0167] When the identity information corresponding to the marked person information is obtained through parsing, the emotion type corresponding to the marked person information and the emotion intensity corresponding to the emotion type are sent to the management device.
[0168] In the embodiment of the present invention, by increasing feature acquisition and performing face recognition on the image, the emotional judgment of the verification person is performed when the access control is unlocked, warnings are given to people with negative emotions, and people with negative emotions are discovered and guided early, thereby improving the warning effect and accuracy of psychological problems.
[0169] above Figure 4 and Figure 5 The access control device based on face recognition in the embodiment of the present invention is described in detail from the perspective of modular functional entities. The access control device based on face recognition in the embodiment of the present invention is described in detail from the perspective of hardware processing.
[0170] Figure 6 6 is a schematic diagram of the structure of a face recognition-based access control device provided by an embodiment of the present invention. The face recognition-based access control device 600 may have relatively large differences due to different configurations or performances, and may include one or more processors (central processing units, CPU) 610 (for example, one or more processors) and a memory 620, and one or more storage media 630 (for example, one or more mass storage devices) storing application programs 633 or data 632. Among them, the memory 620 and the storage medium 630 can be short-term storage or permanent storage. The program stored in the storage medium 630 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the face recognition-based access control device 600. Furthermore, the processor 610 may be configured to communicate with the storage medium 630 to execute a series of instruction operations in the storage medium 630 on the face recognition-based access control device 600.
[0171] The access control device 600 based on face recognition may also include one or more power supplies 640, one or more wired or wireless network interfaces 650, one or more input and output interfaces 660, and / or one or more operating systems 631, such as Windows Serve, Mac OS X, Unix, Linux, FreeBSD, etc. It will be appreciated by those skilled in the art that Figure 6 The structure of the access control device based on face recognition shown does not constitute a limitation on the access control device based on face recognition, and may include more or fewer components than shown in the figure, or a combination of certain components, or a different arrangement of components.
[0172] The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When the instructions are executed on a computer, the computer executes the steps of the access control method based on face recognition.
[0173] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described system, device, or unit can refer to the corresponding process in the aforementioned method embodiment and will not be repeated here.
[0174] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program codes.
[0175] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A door access control method based on face recognition, characterized in that: Includes steps: Acquire a visible light image and an infrared light image of the door opening verification person, and merge the visible light image and the infrared light image to generate a feature image; According to a preset emotion recognition algorithm, the characteristic image is analyzed to obtain the identity information and emotion type of the door opening verification person, and the emotion intensity corresponding to the emotion type; Determining whether the identity information is in a preset permitted personnel list; If the person is in the preset list of permitted personnel, a door opening command is sent to the preset electronic door lock, and the emotion type and the emotion intensity are written into the preset emotion record table; Generate an emotion report of the door opening verification personnel according to the emotion record form, and send the emotion report to the management device; The step of analyzing the characteristic image according to a preset emotion recognition algorithm to obtain the identity information and emotion type of the door opening verification person, and obtaining the emotion intensity corresponding to the emotion type includes: Based on a preset emotion recognition algorithm, grayscale processing is performed on the feature image to obtain a grayscale feature image; Performing vectorization processing on the grayscale feature image to obtain a feature vector matrix; According to the analysis neural network in the emotion recognition algorithm, the feature vector matrix is convolved to obtain a feature convolution vector; Normalizing the feature convolution vector to generate a feature result probability matrix; Determine the identity information and emotion type of the door opening verification person according to the feature result probability matrix, and obtain the emotion intensity corresponding to the emotion type; The step of performing vectorization processing on the grayscale feature image to obtain a feature vector matrix includes: Reading the grayscale value data of each pixel in the grayscale feature image; Arranging all the grayscale value data according to the distribution of each pixel in the grayscale feature image to obtain a preliminary vector matrix; The step of normalizing the feature convolution vector to generate a feature result probability matrix includes: Obtain a preset weight matrix, and multiply the feature convolution vector by the weight matrix to obtain a weighted feature matrix; Using a preset regression function to perform regression calculation on each element in the weighted feature matrix to obtain a regression value corresponding to each element; Each element in the weighted feature matrix is replaced with a regression value corresponding to the element, and the replaced weighted feature matrix is normalized to obtain a feature result probability matrix.
2. The access control method based on face recognition according to claim 1, characterized in that: The merging of the visible light image and the infrared light image to generate a feature image comprises: According to a preset decomposition quantity parameter, the visible light image and the infrared light image are equally divided horizontally or vertically to obtain a visible light atlas and an infrared light atlas; The visible light atlas and the infrared light atlas are cross-joined to obtain a feature image.
3. The access control method based on face recognition according to claim 1, characterized in that: The step of generating an emotion report of the door opening verification personnel according to the emotion record form, and sending the emotion report to the management device comprises: Reading preset emotion monitoring data, wherein the emotion monitoring data includes: emotion monitoring type and emotion intensity threshold value corresponding to the emotion monitoring type; Capture the emotion type and emotion intensity corresponding to the emotion monitoring type in the emotion record table, and generate a monitoring list; Determine whether there is an emotion intensity in the monitoring list that is greater than the corresponding emotion intensity threshold; If it exists, mark the emotion intensity greater than the corresponding emotion intensity threshold, and mark the emotion type corresponding to the emotion intensity; According to the marked emotion type and emotion intensity, an emotion report of the door opening verification personnel is generated, and the emotion report is sent to the management device.
4. The access control method based on face recognition according to any one of claims 1 to 3, characterized in that: After generating an emotion report of the door opening verification personnel according to the emotion record form and sending the emotion report to the management device, the method further includes: Acquire the marked person information sent by the management device, wherein the marked person information is recorded in the permitted person list; When the identity information corresponding to the marked person information is obtained through parsing, the emotion type corresponding to the marked person information and the emotion intensity corresponding to the emotion type are sent to the management device.
5. An access control device based on face recognition, characterized in that: The access control device based on face recognition includes: An acquisition module is used to acquire a visible light image and an infrared light image of a door opening verification person, and to combine the visible light image and the infrared light image to generate a feature image; The parsing module is used to parse the feature image according to a preset emotion recognition algorithm, obtain the identity information and emotion type of the door opening verification person, and obtain the emotion intensity corresponding to the emotion type; The step of analyzing the characteristic image according to a preset emotion recognition algorithm to obtain the identity information and emotion type of the door opening verification person, and obtaining the emotion intensity corresponding to the emotion type includes: Based on a preset emotion recognition algorithm, grayscale processing is performed on the feature image to obtain a grayscale feature image; Performing vectorization processing on the grayscale feature image to obtain a feature vector matrix; According to the analysis neural network in the emotion recognition algorithm, the feature vector matrix is convolved to obtain a feature convolution vector; Normalizing the feature convolution vector to generate a feature result probability matrix; Determine the identity information and emotion type of the door opening verification person according to the feature result probability matrix, and obtain the emotion intensity corresponding to the emotion type; The step of performing vectorization processing on the grayscale feature image to obtain a feature vector matrix includes: Reading the grayscale value data of each pixel in the grayscale feature image; Arranging all the grayscale value data according to the distribution of each pixel in the grayscale feature image to obtain a preliminary vector matrix; The step of normalizing the feature convolution vector to generate a feature result probability matrix includes: Obtain a preset weight matrix, and multiply the feature convolution vector by the weight matrix to obtain a weighted feature matrix; Using a preset regression function to perform regression calculation on each element in the weighted feature matrix to obtain a regression value corresponding to each element; Each element in the weighted feature matrix is replaced with a regression value corresponding to the element, and the replaced weighted feature matrix is normalized to obtain a feature result probability matrix; A judging module, used to judge whether the identity information is in a preset permitted personnel list; A recording module, for sending a door opening command to a preset electronic door lock if the person is in the preset permitted personnel list, and writing the emotion type and the emotion intensity into a preset emotion recording table; The sending module is used to generate an emotion report of the door opening verification personnel according to the emotion record form, and send the emotion report to the management device.
6. An access control device based on face recognition, characterized in that: The access control device based on face recognition includes: a memory and at least one processor, the memory stores instructions, and the memory and the at least one processor are interconnected through a line; The at least one processor calls the instruction in the memory so that the face recognition-based access control device executes the face recognition-based access control method as described in any one of claims 1-4.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the access control method based on face recognition as described in any one of claims 1 to 4 is implemented.
