A safety control method and system of a treatment cabinet based on face recognition
By using near-infrared light sources and mimicry fuzzy repair algorithms to address facial recognition issues caused by medical personnel wearing masks, goggles, or other obstructions, the robustness and adaptability of the recognition system are improved. This ensures rapid and accurate identity verification under high-pressure environments and solves the problem of low recognition accuracy of traditional facial recognition technology when protected by protective devices.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGZHOU BAILI KANGTAI MEDICAL TECH CO LTD
- Filing Date
- 2025-01-17
- Publication Date
- 2026-04-10
AI Technical Summary
Traditional facial recognition technology suffers a significant drop in effectiveness when medical personnel wear protective gear such as masks and goggles, affecting their ability to quickly verify identities in high-pressure environments such as emergency rooms and surgeries, resulting in reduced recognition accuracy and efficiency.
Facial images are acquired using a near-infrared light source. The difference in coverage and brightness is calculated through grayscale conversion and grid division. Facial occlusion analysis and image segmentation are performed. Unoccluded facial features are extracted using a mimicry blur repair algorithm, and a deep learning model is used for recognition.
While sacrificing some safety, it improves the accuracy and adaptability of identification when medical staff wear protective gear, ensuring rapid and accurate identity verification in emergency, surgical, and other environments, reducing cumbersome procedures and improving work efficiency.
Smart Images

Figure CN120014684B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of face recognition, and particularly relates to a safety control method and system of a treatment cabinet based on face recognition. BACKGROUND
[0002] In the medical industry, face recognition technology is often used for medical staff identity verification, patient identity confirmation, and automatic activation of medical equipment. However, traditional face recognition technology such as patent No. CN119131860A entitled "Face recognition system and anesthesia cabinet applying the same" has a significantly decreased recognition effect when medical staff wear masks, goggles, and other protective items. For example, in high-pressure environments such as emergency and surgery, medical staff often need to wear masks, goggles, and other protective equipment, which can severely obstruct facial features, making it difficult for face recognition systems to accurately and quickly verify identity through eye distance alone.
[0003] When facing obstructions, face recognition systems usually compare complete facial images directly collected with information in a database. However, in the case of medical staff wearing protective items, obstructions can cause partial feature information to be missing or severely distorted, resulting in a significant decrease in recognition accuracy. In addition, traditional face recognition methods usually prioritize improving system security, trying to minimize the risk of misidentification, but ignore the need for fast response due to the intense work rhythm of medical staff. In high-pressure environments such as emergency and surgery, any delay in identity verification can directly affect the efficiency of patient treatment or rescue, and may even have serious consequences. SUMMARY
[0004] The present application aims to at least partially solve one of the technical problems in the related art. To this end, the first object of the present application is to propose a safety control method for a treatment cabinet based on face recognition, which can improve adaptability and recognition accuracy when medical staff wear protective items by introducing a quasi-state blur repair algorithm, at the expense of part of the security, effectively improving the working efficiency of face recognition in medical emergency scenes.
[0005] The second object of the present application is to propose a safety control system for a treatment cabinet based on face recognition.
[0006] To achieve the above-mentioned objects, the first aspect of the present application proposes a safety control method for a treatment cabinet based on face recognition, which comprises the following steps:
[0007] S100, irradiating the face to be recognized by a near-infrared light source to obtain a near-infrared light source picture;
[0008] S200, performing grayscale and grid division on the near-infrared light source picture and obtaining grayscale information to obtain a near-infrared light source grayscale picture;
[0009] S300, calculating a coverage inspection range difference according to the gray scale information of the near-infrared light source gray scale picture, and obtaining a face cover area through the coverage inspection range difference;
[0010] S400, performing image segmentation on the near-infrared light source picture according to the face cover area, obtaining a non-coverage face picture area, and performing metamorphic blur repair on the non-coverage face picture area;
[0011] S500, identifying the non-coverage face picture area after the metamorphic blur repair and a corresponding non-coverage face picture area in the stored near-infrared light source picture information of the user, and opening the treatment cabinet if the identification is passed.
[0012] According to the safety control method provided in the embodiments of the present application, the metamorphic blur repair algorithm is introduced, the adaptability and recognition accuracy of the medical staff when wearing protective articles are improved on the premise of sacrificing part of the safety, and the working efficiency of face recognition in a medical emergency scene is effectively improved.
[0013] Further, in step S100, the face to be identified is irradiated by a near-infrared light source to obtain a near-infrared light source picture, which includes:
[0014] The face to be identified is irradiated by a near-infrared light source, wherein the near-infrared light source includes a near-infrared sensor and an image sensor, the near-infrared sensor adopts a CMOS (complementary metal oxide semiconductor) based detector; the image sensor performs real-time imaging on the face, captures the reflected near-infrared light intensity, and forms a near-infrared light source picture.
[0015] Since the treatment cabinet is often placed in a medical monitoring room at night or in insufficient light, and the nurse wears a mask and glasses, the visible light-based face recognition system in this environment often fails to recognize or has low recognition accuracy. Although the face recognition technology based on the near-infrared light source can overcome the problem of insufficient light, when the nurse wears a mask, the area covered by the mask may still affect the accuracy of the face recognition system. When the nurse wears glasses, especially large-framed glasses, a large part of the eye area may be covered. Although the near-infrared light source can penetrate the surface of the eye and capture the deep information below the eye, the reflection or shielding of the glasses may interfere with the reflection of the light, resulting in the recognition system being unable to obtain complete eye information and being unable to find the face features that can be captured.
[0016] To solve the above problems, in step S200, the near-infrared light source picture is gray-scaled and grid-divided to obtain gray scale information, and a near-infrared light source gray scale picture is obtained, which includes:
[0017] The near-infrared light source picture is divided into K grids by a grid division algorithm, and a gray scale processing is performed, wherein the grid size is 1000th of the near-infrared light source picture, K=1000, and a near-infrared light source gray scale picture is obtained.
[0018] In step S300, a covered bright range value is calculated according to the gray scale information of the near-infrared light source gray scale picture, including:
[0019] s(i) represents the gray scale value of the i-th grid of the near-infrared light source gray scale picture, i is [1, K], K is the number of grids after the near-infrared light source gray scale picture is divided, the average value of the gray scale values in each grid of the near-infrared light source gray scale picture is obtained and recorded as ZM, and SL(i) represents the average value of the gray scale values of the adjacent grids of the i-th grid.
[0020] Further, the adjacent grid refers to a grid sharing a boundary with the current grid, wherein the gray scale value of the grid is the average value of the gray scale values of all pixels in the grid, and the average value SL(i) of the gray scale values of the adjacent grids of the i-th grid is the sum of the gray scale values of all adjacent grids of the i-th grid divided by the number of adjacent grids.
[0021] The near-infrared light source gray scale picture is subjected to a face cover analysis.
[0022] S301, a covered bright range difference of the near-infrared light source gray scale picture is calculated.
[0023] The covered bright range difference is calculated: the absolute value of the difference between SL(i) and SL(i+1) is recorded as ZG(j), the absolute value of the difference between s(i) and s(i+1) is recorded as SG(j), j is [1, K-1], all ZG(j) and all SG(j) are added and divided by 2(K-1) to obtain the covered bright range difference HDC.
[0024] The covered bright range difference HDC is used to quantify the change and non-uniformity of the cover area, and is used as a standard to determine whether the current grid is a cover reflection point or a blur point.
[0025] S302, an integer variable k is defined, and the initial value is set to 1, and a blank sequence Z1 is created.
[0026] S303, a face cover analysis is performed, wherein the face cover analysis is: the values of s(k) and ZM are compared, and the values of [ZG(j)+SG(j)] and HDC are compared, and if s(k) is less than ZM and [ZG(k)+SG(k)] is less than HDC, s(k) is added to the sequence Z1.
[0027] S304, judging whether the face cover analysis is completed, and the specific judging method is: if the current variable k is less than K, then k is increased by 1, and the face cover analysis is continued in step S303; if the current variable k is equal to K, it indicates that the face cover analysis has been completed, and the step S305 is turned to;
[0028] S305, recording the grid corresponding to all elements in the sequence Z1 as a face cover grid, and recording the area composed of all face cover grids and adjacent grids of the face cover grid as a face cover area.
[0029] The beneficial effect of the present step is that: through the face cover analysis based on the local change of the image gray value, the gray difference of the adjacent grid, and the highlight range difference (HDC), the cover area in the image is judged, through the face cover analysis, the real face feature area and the interference area caused by the cover, noise or blur can be effectively distinguished, through the effective analysis and identification of the cover area, the system can eliminate these interference parts from the image, and the real face feature is concentrated to avoid the influence of the medical staff or other users wearing masks, glasses, goggles and other coverings on the accuracy of the face recognition system.
[0030] Further, in step S400, the near-infrared light source picture is segmented according to the face cover area to obtain a non-covered face picture area, and the non-covered face picture area is subjected to a morphological blur repair, which includes:
[0031] Further, since the medical staff will wear goggles during work, the eye imaging caused by the near-infrared light source passing through the goggles will cause tearing and noise points, and the edge tearing and local blur caused by separation in the face cover analysis process, so the non-covered face picture area needs to be subjected to a morphological blur repair;
[0032] The process of the morphological blur repair is:
[0033] S401, obtaining the gray value of the grid of the non-covered face picture area and the average value of the gray value of the adjacent grid of the non-covered face picture area grid;
[0034] Specifically, u(y) represents the gray value of the yth grid of the non-covered face picture area, y is [1, G], and G is the number of grids of the non-covered face picture area; the median of the gray value in each grid in the non-covered face picture area is obtained and recorded as PD, and the average value of the gray value in each grid in u(y) is obtained and recorded as PM; SOG(y) represents the average value of the gray value of the adjacent grid of the yth grid of the non-covered face picture area;
[0035] S402, calculating the difference fluctuation gray value KJ(y) of each grid in the uncovered face picture area; wherein KJ(y) is the sum of Du(y) and DS(y); wherein Du(y) is the absolute value of 2u(y) minus the sum of u(y-1) and u(y+1); Ds(y) is the absolute value of 2SOG(y) minus the sum of SOG(y-1) and SOG(y+1), wherein for the boundary grid y=1 or y=G, Ds(1)=Ds(G)=0 is defined, Du(1)=Du(G)=0 is defined;
[0036] S403, calculating the difference fluctuation gray range; wherein the difference fluctuation gray range KFW is the sum of the absolute values of the difference between all KJ(y) and the covered brightness range difference HDC divided by G;
[0037] S404, correcting the gray value of the grid with gray fluctuation anomaly according to the difference fluctuation gray value of each grid and the difference fluctuation gray range;
[0038] Comparing the absolute value of the difference between KJ(y) and HDC with the size of KFW, when the absolute value of the difference between KJ(y) and HDC is greater than KFW, the gray value of u(y) is corrected to the sum of u(y-1), u(y+1), PD, PM, SOG(y), SOG(y-1) and SOG(y+1) divided by 7;
[0039] Wherein, PD represents the median of the current grid gray value, which can effectively reflect the gray distribution of the local area and reduce noise interference; PM represents the average value of the current grid gray value, which can provide the gray center trend of the local area; the difference fluctuation gray value KJ(y) represents the gray change of the current grid and its adjacent area; Du(y) is used to measure the intensity of the gray change of the current grid. Ds(y) is used to measure the gray change of the adjacent area of the current grid. KJ(y) represents the gray fluctuation degree of the current grid and its adjacent grid, reflecting the change degree of the image in the area. The difference fluctuation gray range KFW is the average value of the difference between all grid difference fluctuation gray values KJ(y) and the covered brightness range difference HDC, representing the average level of the fluctuation difference of all grids, which is used to measure the fluctuation range of the whole image.
[0040] Further, the quasi-state blur repair is judged by the gray difference fluctuation and the average gray value of the adjacent grid whether it needs to be repaired. If the difference fluctuation is large and exceeds the normal fluctuation range KFW, it means that the grid may have blur phenomenon, and its gray value needs to be corrected by the gray values of the surrounding adjacent grids.
[0041] The beneficial effect of this step is that by repairing part of the gray scale information, the tearing and noise caused by the eye imaging of the near-infrared light source passing through the goggles worn by the medical staff is solved, which affects the collection of eye features and greatly reduces the success rate and flexibility of the identification process. In the high-pressure environment of emergency, surgery, etc., face recognition cannot be quickly performed to open the medical cabinet in time.
[0042] S500, identify the uncovered face picture area of the user after the mimicry blur repair and the corresponding uncovered face picture area in the stored near-infrared light source picture information of the user, and if the identification is passed, open the treatment cabinet.
[0043] The uncovered face picture area is subjected to feature extraction, and the feature extraction method includes texture-based features, shape features, or key point feature extraction.
[0044] Specifically, the texture feature is obtained by a gray level co-occurrence matrix (GLCM) method, the shape feature is described by the relative position of the face feature point, and the deep learning method extracts higher-level face features through a convolutional neural network (CNN) network.
[0045] Further, the stored user near-infrared light source picture information has been pre-processed and extracted as a template for identification, and these templates also contain texture, shape, and key point information, which are used to match the features of the current face image.
[0046] Further, the uncovered face area features of the current user are compared with the stored templates, and similarity measurement is calculated, and a deep learning model is used for feature extraction, and similarity calculation is performed through the output of the neural network to obtain a matching score. The matching score can measure the similarity between the current face and the stored template.
[0047] Further, in the comparison process, if the similarity between the current face feature and the template exceeds the preset matching score, the identity of the currently identified user is verified, and at this time, the treatment cabinet is opened through the control of the hardware device (such as a relay, a smart socket, etc.). If the matching score is lower than the set matching score, it means that the identification fails, and it is judged that the user face information is not matched due to occlusion, image quality, etc. The user is required to perform face recognition again or give a corresponding error prompt.
[0048] The beneficial effects of the present application are: the present application improves the robustness and adaptability of the face recognition system by mimicry blur repair and separation of the blocked area, especially in the complex environment of medical staff wearing masks, goggles and other shielding materials. The assumption and processing of part of the image information in the image repair process sacrifices safety, but by introducing the mimicry blur repair algorithm, the blur, noise and tearing phenomenon caused by the shielding material can be effectively eliminated, ensuring that even with goggles or masks, sufficient accurate facial features can be extracted. In practical applications, the existence of face shielding materials, especially the wearing of medical protective supplies such as masks and glasses, seriously affects the recognition accuracy and stability of traditional face recognition systems. The safety requirements of traditional face recognition methods usually focus on minimizing the risk of misidentification, while ignoring the fact that medical staff's work rhythm is usually very tense, especially in high-pressure environments such as emergency and surgery, any delay will affect the treatment or rescue efficiency of patients, therefore, the face recognition technology not only needs to have high precision, but also must respond quickly to ensure that identity verification can be completed within a short time and related equipment can be enabled. Through appropriate technical compromise, the present application sacrifices part of the safety to obtain higher recognition success rate and use flexibility, so that the recognition system can still reliably perform identity verification in medical, nursing and other environments, especially in the case of insufficient light and personnel wearing protective materials. In addition, although the gray-scale information is repaired, the repair process of the image is essentially a certain degree of estimation and correction of the original data, but the repair process will strictly follow the overall structural features of the image, maintain the coherence and naturalness of the facial features, and this way ensures that the recognition system has strong fault tolerance and adaptability while ensuring accuracy; therefore, the present application focuses more on improving the application range and recognition effect of the system, especially in the medical and emergency scene, it can quickly and accurately identify the identity, reduce the cumbersome operation in medical work, and improve the work efficiency.
[0049] To achieve the above object, the second aspect of the present application also proposes a safety control system of a treatment cabinet based on face recognition, which comprises a processor, a memory and a computer program stored in the memory and executable on the processor. The processor executes the computer program to realize the steps in the safety control method of the treatment cabinet based on face recognition. The safety control system of the treatment cabinet based on face recognition runs in the computing devices of desktop computers, notebooks, palmtop computers and cloud data centers.
[0050] The face recognition-based safety control method of the treatment cabinet is executed by the face recognition-based safety control system of the treatment cabinet, and the adaptability and recognition accuracy of medical personnel when wearing protective articles are improved under the premise of sacrificing part of the safety by introducing a quasimorphic fuzzy repair algorithm, and the working efficiency of face recognition in a medical emergency scene is effectively improved. BRIEF DESCRIPTION OF DRAWINGS
[0051] Figure 1 A flowchart of a face recognition-based safety control method of a treatment cabinet is shown.
[0052] Figure 2 A structural diagram of a face recognition-based safety control system of a treatment cabinet is shown. DETAILED DESCRIPTION
[0053] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference signs represent the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the accompanying drawings are exemplary and are intended to explain the present application, and cannot be understood as a limitation of the present application.
[0054] Figure 1 A flowchart of a face recognition-based safety control method of a treatment cabinet is shown.
[0055] Referring to Figure 1 The present application proposes a face recognition-based safety control method of a treatment cabinet, which comprises the following steps:
[0056] S100, a face to be recognized is irradiated by a near-infrared light source to obtain a near-infrared light source picture;
[0057] S200, the near-infrared light source picture is grayed and grid-divided to obtain gray-scale information, and a near-infrared light source gray-scale picture is obtained;
[0058] S300, the coverage and brightness range difference is calculated according to the gray-scale information of the near-infrared light source gray-scale picture, and the face covering object area is obtained through the coverage and brightness range difference;
[0059] S400, the near-infrared light source picture is image segmented according to the face covering object area, the uncovered face picture area is obtained, and the uncovered face picture area is quasimorphically fuzzy repaired;
[0060] S500, the uncovered face picture area after quasimorphic fuzzy repair is identified with the corresponding uncovered face picture area in the near-infrared light source picture information of the stored user, and if the identification is passed, the treatment cabinet is opened.
[0061] According to the safety control method provided in the embodiments of the present application, the adaptability and recognition accuracy of the medical staff wearing the protective equipment can be improved under the premise of sacrificing part of the safety by introducing the quasi-state fuzzy repair algorithm, and the working efficiency of the face recognition in the medical emergency scene can be effectively improved.
[0062] Further, in step S100, the face to be recognized is irradiated by a near-infrared light source, and a near-infrared light source image is acquired, including:
[0063] The face to be recognized is irradiated by a near-infrared light source, wherein the near-infrared light source includes a near-infrared sensor and an image sensor, the near-infrared sensor adopts a CMOS (complementary metal oxide semiconductor) based detector; the image sensor performs real-time imaging on the face, captures the reflected near-infrared light intensity, and forms a near-infrared light source image.
[0064] Since the treatment cabinet is often placed in a medical monitoring room at night or in insufficient light, and the nurse wears a mask and glasses, the visible light-based face recognition system in this environment often fails to recognize or has low recognition accuracy. Although the face recognition technology based on the near-infrared light source can overcome the problem of insufficient light, when the nurse wears a mask, the area blocked by the mask may still affect the accuracy of the face recognition system. When the nurse wears glasses, especially large-framed glasses, a large part of the eye area may be blocked. Although the near-infrared light source can penetrate the surface of the eye and capture the deep information below the eye, the reflection or blocking of the glasses may interfere with the reflection of the light, causing the recognition system to fail to obtain complete eye information and to find the face features that can be captured.
[0065] To solve the above problems, in step S200, the near-infrared light source image is grayed and grid divided to obtain gray information, and a near-infrared light source gray image is obtained, including:
[0066] The near-infrared light source image is grid divided and grayed by a grid division algorithm, the grid size is 1 / 1000 of the near-infrared light source image, the near-infrared light source image is divided into K grids, wherein K = 1000, and the near-infrared light source gray image is obtained.
[0067] In step S300, the coverage brightness range value is calculated according to the gray information of the near-infrared light source gray image, including:
[0068] Let s(i) represent the gray value of the i-th grid of the near-infrared light source gray image, i is in the range of [1, K], K is the number of grids after the near-infrared light source gray image is divided; the average value of the gray values in each grid of the near-infrared light source gray image is obtained and denoted as ZM; and SL(i) represents the average value of the gray values of the adjacent grids of the i-th grid.
[0069] Further, the adjacent grid refers to the grid sharing the boundary with the current grid, wherein the gray value of the grid is the average value of the gray values of all pixels in the grid, and the average value of the gray values of the adjacent grids of the ith grid SL(i) is the sum of the gray values of all adjacent grids of the ith grid divided by the number of the adjacent grids;
[0070] Performing face occlusion analysis on the near-infrared light source gray picture:
[0071] S301, calculating the coverage and brightness range difference of the near-infrared light source gray picture;
[0072] Calculating the coverage and brightness range difference: taking the absolute value of the difference between SL(i) and SL(i+1) as ZG(j), and taking the absolute value of the difference between s(i) and s(i+1) as SG(j), j is [1, K-1], and the sum of all ZG(j) and all SG(j) is divided by 2(K-1) to obtain the coverage and brightness range difference HDC;
[0073] The coverage and brightness range difference HDC is used to quantify the change and non-uniformity of the occlusion area, and is used as a standard to determine whether the current grid is an occlusion reflection point or a blur point.
[0074] S302, defining an integer variable k, and setting the initial value as 1, and creating an empty sequence Z1;
[0075] S303, performing face occlusion analysis, wherein the face occlusion analysis is: comparing the values of s(k) and ZM, and comparing the values of [ZG(j)+SG(j)] and HDC, and if s(k) is less than ZM and [ZG(k)+SG(k)] is less than HDC, then s(k) is added to the sequence Z1;
[0076] S304, judging whether the face occlusion analysis is completed, and the specific judging method is: if the current variable k is less than K, then increasing k by 1, and returning to step S303 to continue the face occlusion analysis; if the current variable k is equal to K, it indicates that the face occlusion analysis has been processed, and turning to step S305;
[0077] S305, recording the grid corresponding to all elements in the sequence Z1 as the face occlusion grid, and recording the area composed of all face occlusion grids and the adjacent grids of the face occlusion grid as the face occlusion area.
[0078] The beneficial effect of this step is that by analyzing the face cover based on the local change of the image gray value, combining the gray difference of the adjacent grid and the highlight range difference (HDC), the cover area in the image is judged, and by analyzing and identifying the cover area, the system can eliminate the interference part from the image, and concentrate on identifying the real face feature to avoid the influence of the face recognition system when the medical staff or other users wear masks, glasses, goggles and other coverings.
[0079] Further, in step S400, the near-infrared light source picture is segmented according to the face cover area to obtain a non-covered face picture area, and the non-covered face picture area is repaired by a morphological blur.
[0080] Further, since the medical staff will wear goggles during work, the eye imaging caused by the near-infrared light source passing through the goggles will cause tearing and noise, and the edge tearing and local blur generated in the face cover analysis process, so it is necessary to repair the non-covered face picture area by a morphological blur.
[0081] The process of the morphological blur repair is as follows:
[0082] S401, obtaining the gray value of the grid of the non-covered face picture area and the average value of the gray value of the adjacent grid of the non-covered face picture area grid;
[0083] Specifically, u(y) represents the gray value of the yth grid of the non-covered face picture area, y is [1, G], and G is the number of grids of the non-covered face picture area. The median of the gray value in each grid in the non-covered face picture area is obtained and denoted as PD, and the average value of the gray value in each grid in u(y) is obtained and denoted as PM. SOG(y) represents the average value of the gray value of the adjacent grid of the yth grid of the non-covered face picture area.
[0084] S402, calculating the difference fluctuation gray value KJ(y) of each grid of the non-covered face picture area; wherein KJ(y) is the sum of Du(y) and DS(y); wherein Du(y) is the absolute value of 2u(y) minus the sum of u(y-1) and u(y+1); Ds(y) is the absolute value of 2SOG(y) minus the sum of SOG(y-1) and SOG(y+1), wherein for the boundary grid y=1 or y=G, Ds(1)=Ds(G)=0, Du(1)=Du(G)=0 is defined.
[0085] S403, calculate the difference fluctuation gray range; wherein the difference fluctuation gray range KFW is the sum of the absolute values of the difference between all KJ(y) and the coverage brightness difference range HDC divided by G;
[0086] S404, correct the gray value of the grid with the gray fluctuation anomaly according to the difference fluctuation gray value of each grid and the difference fluctuation gray range;
[0087] Compare the absolute value of the difference between KJ(y) and HDC with the size of KFW, and if the absolute value of the difference between KJ(y) and HDC is greater than KFW, then correct the gray value of u(y) to the sum of u(y-1), u(y+1), PD, PM, SOG(y), SOG(y-1) and SOG(y+1) divided by 7;
[0088] Wherein, PD represents the median of the current grid gray value, which can effectively reflect the local gray distribution and reduce noise interference; PM represents the average value of the current grid gray value, which can provide the local gray center trend; the difference fluctuation gray value KJ(y) represents the gray change of the current grid and its adjacent region; Du(y) is used to measure the intensity of the current grid gray change. Ds(y) is used to measure the gray change of the adjacent region of the current grid. KJ(y) represents the gray fluctuation degree of the current grid and its adjacent grid, reflecting the change degree of the image in the region. The difference fluctuation gray range KFW is the average value of the difference between all grid difference fluctuation gray values KJ(y) and the coverage brightness difference HDC, representing the average level of the fluctuation difference of all grids, and is used to measure the fluctuation range of the whole image.
[0089] Further, the quasi-state blur repair is judged by the gray difference fluctuation and the average gray value of the adjacent grid. If the difference fluctuation is large and exceeds the normal fluctuation range KFW, it means that the grid may have blur phenomenon, and the gray value needs to be corrected by the gray value of the surrounding adjacent grid.
[0090] The beneficial effect of this step is that the tearing and noise caused by the eye imaging of the near-infrared light source passing through the goggles due to the wearing of the goggles or glasses by the medical staff is solved by repairing part of the gray information, which affects the collection of eye features and greatly reduces the success rate of the recognition process and the use flexibility. In the high-pressure environment of emergency, surgery, etc., face recognition cannot be quickly performed to open the medical cabinet, which cannot be operated in time.
[0091] S500, identify the uncovered face picture area in the stored user's near-infrared light source picture information corresponding to the quasi-state blur repaired uncovered face picture area, and if the identification is passed, open the treatment cabinet.
[0092] Feature extraction is performed on the uncovered face picture area, and the feature extraction method includes texture-based features, shape features, or key point feature extraction.
[0093] Specifically, texture features are obtained by methods such as gray level co-occurrence matrix (GLCM), shape features are described by the relative positions of facial feature points, and deep learning methods extract higher-level facial features through convolutional neural networks (CNN) and other networks.
[0094] Further, the stored user near-infrared light source picture information has been pre-processed and the features are extracted for use as recognition templates, which also contain texture, shape, and key point information, for matching with the features of the current face image.
[0095] Further, the features of the uncovered face area of the current user are compared with the stored templates, and similarity measurement is calculated, and deep learning models are used for feature extraction, similarity calculation is performed through the output of the neural network, and a matching score is obtained. The matching score can measure the similarity between the current face and the stored template.
[0096] Further, during the comparison process, if the similarity between the current face features and the template exceeds the preset matching score, the identity of the currently recognized user is verified, and at this time the treatment cabinet is opened through the control of the hardware device (such as a relay, a smart socket, etc.). If the matching score is lower than the set matching score, it means that the recognition fails, and it is determined that the user face information does not match due to occlusion, image quality, etc., and the user is required to re-perform face recognition or given a corresponding error prompt.
[0097] The beneficial effects of the present application are: the present application improves the robustness and adaptability of the face recognition system by mimicry blur repair and separation of the blocked area, especially in the complex environment of medical staff wearing masks, goggles and other shielding objects. The assumption and processing of part of the image information in the image repair process sacrifices safety, but by introducing the mimicry blur repair algorithm, the blur, noise and tearing phenomenon caused by the shielding object can be effectively eliminated, ensuring that even with goggles or masks, accurate facial features can be extracted. In practical applications, the existence of face shielding objects, especially the wearing of medical protective articles such as masks and glasses, seriously affects the recognition accuracy and stability of traditional face recognition systems. The safety requirements of traditional face recognition methods usually focus on minimizing the risk of misidentification, while ignoring the fact that medical staff's work rhythm is usually very tense, especially in high-pressure environments such as emergency and surgery, any delay will affect the treatment or rescue efficiency of patients, therefore, the face recognition technology not only needs to have high precision, but also must respond quickly to ensure that identity verification can be completed within a short time and related equipment can be enabled. Through appropriate technical compromise, the present application sacrifices part of the safety to obtain higher recognition success rate and use flexibility, so that the recognition system can still reliably perform identity verification in medical, nursing and other environments, especially in the case of insufficient light and personnel wearing protective articles. In addition, although the gray-scale information is repaired, the repair and difference adjustment of the image in the repair process is essentially a certain degree of estimation and correction of the original data, but the repair process will strictly follow the overall structural features of the image, maintain the coherence and naturalness of the facial features, and this way ensures that the recognition system has strong fault tolerance and adaptability while ensuring accuracy; therefore, the present application focuses more on improving the application range and recognition effect of the system, especially in the medical and emergency scene, it can quickly and accurately identify the identity, reduce the cumbersome operation in medical work, and improve the work efficiency.
[0098] Figure 2 The safety control system structure diagram of the treatment cabinet based on face recognition is shown.
[0099] Reference Figure 2 The present application also provides a safety control system 20 of a treatment cabinet based on face recognition, which comprises a processor, a memory and a computer program stored in the memory and executable on the processor. The processor executes the computer program to realize the steps in the safety control method of the treatment cabinet based on face recognition. The safety control system 20 of the treatment cabinet based on face recognition runs in the computing devices of desktop computers, notebooks, palmtop computers and cloud data centers.
[0100] The security control system comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor executes the computer program to run in the following units of the security control system:
[0101] The acquisition unit 21 is configured to irradiate a face to be identified by a near-infrared light source and acquire a near-infrared light source image.
[0102] The conversion unit 22 is configured to perform grayscale and grid division on the near-infrared light source image and acquire grayscale information, thereby obtaining a near-infrared light source grayscale image.
[0103] The calculation unit 23 is configured to calculate a coverage and illumination range difference according to the grayscale information of the near-infrared light source grayscale image, and acquire a face cover area through the coverage and illumination range difference.
[0104] The management unit 24 is configured to perform image segmentation on the near-infrared light source image according to the face cover area, acquire a non-coverage face image area, and perform quasi-state blur repair on the non-coverage face image area.
[0105] The identification unit 25 is configured to identify the non-coverage face image area after quasi-state blur repair with a corresponding non-coverage face image area in the near-infrared light source image information of a stored user, and open a treatment cabinet if the identification is passed.
[0106] The security control system of the treatment cabinet based on face recognition can run in a desktop computer, a notebook computer, a palm computer, and a cloud server, and the like. The security control system of the treatment cabinet based on face recognition can comprise, but is not limited to, a processor and a memory. Those skilled in the art can understand that the example is only an example of the security control system 20 of the treatment cabinet based on face recognition, and does not constitute a limitation on the security control system 20 of the treatment cabinet based on face recognition, and can comprise more or fewer components, or combine certain components, or different components, for example, the security control system of the treatment cabinet based on face recognition can also comprise an input and output device, a network access device, a bus, and the like.
[0107] By executing the security control method of the treatment cabinet based on face recognition through the security control system 20 of the treatment cabinet based on face recognition, the adaptability and recognition accuracy of medical personnel wearing protective articles can be improved under the premise of sacrificing part of the security by introducing a quasi-state blur repair algorithm, and the working efficiency of face recognition in a medical emergency scene can be effectively improved.
[0108] It is to be appreciated that the above description and the examples that follow are intended to be illustrative only and that changes can be made to the description and examples without departing from the scope of the application. Note also that the use of particular brand names in the description is solely for illustration and should not be construed as an endorsement of such brands.
[0109] It should be understood that aspects of the application can be implemented in hardware, software, firmware or a combination thereof. In the above embodiments, various steps or methods can be implemented in software or firmware that is stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any of the following technologies, known in the art, can be used: a hybrid of the technologies mentioned above, discrete logic circuitry having logic gates for implementing logic functions upon data signals, application specific integrated circuits having appropriate combinational logic gates, programmable gate arrays (PGA), field programmable gate arrays (FPGA), and so forth.
[0110] In the description of the present application, reference has been made to the use of terms such as "one embodiment", "some embodiments", "an example", "a specific example" or "some examples" means that a particular feature, structure, material or characteristic is included in at least one embodiment or example of the present application. The illustrative examples given are not necessarily to be construed as preferred or advantageous or with the exclusion of other equally valid examples that can be particularly adapted to a given application. Furthermore, since numerous modifications and changes will readily occur to those skilled in the art, it is not desired to limit the application to the exact construction and operation described. Accordingly, all suitable modifications and equivalents should be included within the scope of the present application.
[0111] In the description of the present application, it needs to be understood that the terms "center", "longitudinal", "transverse", "length", "width", "thickness", "upper", "lower", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", "clockwise", "counterclockwise", "axial", "radial", "circumferential" and the like indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, which are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the devices or elements referred to must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as limiting the present application.
[0112] In addition, the terms "first", "second", and the like used in the embodiments of the present application are only for the purpose of description, and cannot be understood as indicating or implying relative importance, or implicitly indicating the number of technical features referred to in the embodiments. Therefore, the features defined with "first", "second" and the like in the embodiments of the present application can be explicitly or implicitly indicated to include at least one of the features. In the description of the present application, the meaning of the word "plurality" is at least two or two or more, such as two, three, four, etc., unless otherwise specifically limited in the embodiments.
[0113] In the present application, unless otherwise specifically provided or limited in the embodiments, the terms "mounting", "connecting", "connecting" and "fixing" and the like appearing in the embodiments should be understood broadly, for example, the connection can be fixed connection, or detachable connection, or integral, which can be understood, or can be mechanical connection, electrical connection, etc. Of course, it can also be directly connected, or indirectly connected through an intermediate medium, or the internal communication of two elements, or the interaction relationship between two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific implementation situation.
[0114] In the present application, unless otherwise specifically provided and limited, the first feature "on" or "under" the second feature can be that the first and second features are in direct contact, or the first and second features are indirectly in contact through an intermediate medium. Moreover, the first feature "above", "above" and "above" the second feature can be that the first feature is directly above or obliquely above the second feature, or only indicates that the horizontal height of the first feature is higher than that of the second feature. The first feature "below", "below" and "below" the second feature can be that the first feature is directly below or obliquely below the second feature, or only indicates that the horizontal height of the first feature is less than that of the second feature.
[0115] Although the embodiments of the present application have been shown and described above, it is understood that the above-described embodiments are exemplary and are not to be construed as limiting the present application, and that variations, modifications, substitutions and changes can be made by those skilled in the art without departing from the scope of the present application.
Claims
1. A security control method for a treatment cabinet based on facial recognition, characterized in that, The method includes the following steps: S100 acquires a near-infrared image by illuminating the face to be identified with a near-infrared light source; S200 performs grayscale conversion and grid division on the near-infrared light source image and obtains grayscale information to obtain a near-infrared light source grayscale image; S300: Calculate the coverage brightness difference based on the grayscale information of the near-infrared light source grayscale image, and obtain the facial occlusion area through the coverage brightness difference; wherein, S300 includes: Let s(i) represent the grayscale value of the i-th grid of the near-infrared light source grayscale image, where i takes the value [1, K], and K is the number of grids after the near-infrared light source grayscale image is divided; obtain the average grayscale value of each grid in the near-infrared light source grayscale image and record it as ZM; let SL(i) represent the average grayscale value of the adjacent grids of the i-th grid; wherein, adjacent grids refer to grids that share a boundary with the current grid, where the grayscale value of the grid is the average grayscale value of all pixels in the grid, and the average grayscale value SL(i) of the adjacent grids of the i-th grid is the sum of the grayscale values of all adjacent grids of the i-th grid divided by the number of adjacent grids; perform facial occlusion analysis on the near-infrared light source grayscale image: wherein the facial occlusion analysis includes the following steps: S301, Calculate the difference in coverage and brightness range of a near-infrared light source grayscale image; Calculate the coverage and brightness difference: Let the absolute value of the difference between SL(i) and SL(i+1) be ZG(j), and the absolute value of the difference between s(i) and s(i+1) be SG(j), where j takes the value [1, K-1]. Add all ZG(j) and all SG(j) together and divide by 2(K-1) to get the coverage and brightness difference HDC. The coverage brightness difference (HDC) is used to quantify the changes and unevenness of the occlusion area, and serves as a standard to determine whether the current grid is a reflection point of an occlusion or a blurry point. S302, Define an integer variable k, initialize it to 1, and create an empty sequence Z1; S303, perform facial occlusion analysis, which involves comparing the values of s(k) and ZM, and comparing the values of [ZG(j)+SG(j)] and HDC. If s(k) is less than ZM and [ZG(k)+SG(k)] is less than HDC, then add s(k) to sequence Z1. S304, determine whether the facial occlusion analysis is complete. The specific determination method is as follows: if the current variable k is less than K, then increase k by 1 and return to step S303 to continue the facial occlusion analysis; if the current variable k is equal to K, it means that the facial occlusion analysis has been completed and proceed to step S305. S305, denote the mesh corresponding to all elements in sequence Z1 as the face occlusion mesh, and denote the region composed of all face occlusion meshes and adjacent meshes of the face occlusion mesh as the face occlusion region; S400, perform image segmentation on the near-infrared light source image based on the facial occlusion area to obtain the uncovered facial image area, and perform mimicry blur repair on the uncovered facial image area; wherein, S400 includes: S401, obtain the gray value of the grid of the uncovered facial image area and the average gray value of the adjacent grids of the uncovered facial image area. Specifically, let u(y) represent the gray value of the y-th grid in the uncovered face image region, where y takes the value [1, G] and G is the number of grids in the uncovered face image region; obtain the median of the gray values in each grid in the uncovered face image region and denote it as PD, and obtain the average gray value in each grid in u(y) and denote it as PM; let SOG(y) represent the average gray value of the adjacent grids of the y-th grid in the uncovered face image region; S402, calculate the difference fluctuation gray value KJ(y) of each grid in the uncovered face image region; where KJ(y) is the sum of Du(y) and DS(y); where Du(y) is the absolute value of 2u(y) minus the sum of u(y-1) and u(y+1); Ds(y) is the absolute value of 2SOG(y) minus the sum of SOG(y−1) and SOG(y+1), where for the boundary grid y=1 or y=G, define Ds(1)=Ds(G)=0, and define Du(1)=Du(G)=0; S403, calculate the difference fluctuation grayscale range; where the difference fluctuation grayscale range KFW is the sum of the absolute values of the differences between all KJ(y) and the coverage brightness difference HDC divided by G; S404, corrects the gray values of grids with abnormal gray value fluctuations based on the difference fluctuation gray value and the difference fluctuation gray value range of each grid; Compare the absolute value of the difference between KJ(y) and HDC with the size of KFW. When the absolute value of the difference between KJ(y) and HDC is greater than KFW, the gray value of u(y) is corrected to the sum of u(y-1), u(y+1), PD, PM, SOG(y), SOG(y−1) and SOG(y+1) divided by 7. The S500 identifies the uncovered facial image area after mimicry blur repair and the corresponding uncovered facial image area in the stored near-infrared light source image information of the user. If the identification is successful, the treatment cabinet is opened.
2. The security control method for a treatment cabinet based on face recognition according to claim 1, characterized in that, In step S100, the face to be identified is illuminated by a near-infrared light source to obtain a near-infrared light image, including: The face to be identified is illuminated by a near-infrared light source, which includes a near-infrared sensor and an image sensor. The near-infrared sensor uses a CMOS-based detector, and the image sensor performs real-time imaging of the face, capturing the intensity of the reflected near-infrared light to form a near-infrared light image.
3. The security control method for a treatment cabinet based on face recognition according to claim 1, characterized in that, In step S200, the near-infrared light source image is converted to grayscale and divided into grids to obtain grayscale information, resulting in a near-infrared light source grayscale image including: The near-infrared light source image is divided into grids and then converted to grayscale using a grid partitioning algorithm. The grid size is 1 / 1000 of the near-infrared light source image. The near-infrared light source image is divided into K grids, where K=1000, to obtain a near-infrared light source grayscale image.
4. A safety control system for a treatment cabinet based on facial recognition, characterized in that, The safety control system for a treatment cabinet based on face recognition includes: a processor, a memory, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, it implements the steps of the safety control method for a treatment cabinet based on face recognition as described in any one of claims 1 to 3.
Citation Information
Patent Citations
Facial recognition system and anesthetic cabinet using same
CN119131860A
Face recognition method and device based on multispectral fusion
CN108090477A
Occlusion tolerant pattern recognition
WO2001022355A1