CN108133204B - Hand body identification method, device, equipment and computer readable storage medium - Google Patents
Hand body identification method, device, equipment and computer readable storage medium Download PDFInfo
- Publication number
- CN108133204B CN108133204B CN201810064021.8A CN201810064021A CN108133204B CN 108133204 B CN108133204 B CN 108133204B CN 201810064021 A CN201810064021 A CN 201810064021A CN 108133204 B CN108133204 B CN 108133204B
- Authority
- CN
- China
- Prior art keywords
- value
- image
- skin color
- rgb image
- color identification
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V40/00—Recognition of biometric, human-related or animal-related patterns in image or video data
- G06V40/10—Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
- G06V40/107—Static hand or arm
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/90—Determination of colour characteristics
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/56—Extraction of image or video features relating to colour
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10024—Color image
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30004—Biomedical image processing
- G06T2207/30088—Skin; Dermal
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Multimedia (AREA)
- Human Computer Interaction (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a hand body identification method, which comprises the following steps: acquiring a background RGB image and a live-action RGB image; calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real-scene RGB image; processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb regions; performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value; selecting a skin color identification image corresponding to a CrCb region where the characteristic value of the Cr value and the characteristic value of the Cb value are located as a hand body identification result; the method can accurately distinguish the hand body from the noise object close to the skin color by using the OTSU algorithm and the characteristic values of the Cr value and the Cb value, and improve the accuracy rate of hand body identification; the invention also discloses a hand recognition device, equipment and a computer readable storage medium, which have the beneficial effects.
Description
Technical Field
The present invention relates to the field of image processing technologies, and in particular, to a method, an apparatus, a device, and a computer-readable storage medium for hand recognition.
Background
The accuracy of hand body recognition is very important for recognizing a scene operated by a user by using hand body gestures or hand body motion tracks. However, the existing hand body recognition method has a great defect that when a noise object close to the skin color of a person exists in the background, the hand body recognition method cannot separate the hand body from the noise object, and finally the recognition result is wrong.
Therefore, how to improve the accuracy of hand body recognition so as to distinguish the hand body from a noise object close to skin color is a technical problem to be solved by those skilled in the art.
Disclosure of Invention
The invention aims to provide a hand body identification method, a device, equipment and a computer readable storage medium, which utilize an OTSU algorithm and a characteristic value of a Cr value and a characteristic value of a Cb value to accurately distinguish a hand body in a skin color identification image and a noise object close to the skin color and improve the accuracy rate of hand body identification.
In order to solve the above technical problem, the present invention provides a hand recognition method, including:
acquiring a background RGB image and a live-action RGB image;
calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real scene RGB image;
processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb areas;
performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result;
calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
and selecting the characteristic value of the Cr value and a skin color identification image corresponding to the CrCb region where the characteristic value of the Cb value is located as a hand body identification result.
Optionally, calculating a skin color recognition image by using a skin color recognition algorithm according to the real RGB image, including:
converting the real scene RGB image into a real scene YCrCb image;
and processing the real-scene YCrCb image by using a skin color identification algorithm to obtain a skin color identification image.
Optionally, performing difference processing on the background RGB image and the live-action RGB image, and extracting a corresponding Cr value and a Cb value of a target coordinate point in a difference result, includes:
performing fuzzy subtraction processing on the background RGB image and the real-scene RGB image to obtain a fuzzy subtraction image;
carrying out binarization processing on the fuzzy difference image to obtain a binarized image, and acquiring a target coordinate point according to the binarized image;
acquiring the RGB numerical value of the real-scene RGB image corresponding to the target coordinate point;
and converting the RGB numerical value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point.
Optionally, calculating the feature value of the Cr value and the feature value of the Cb value includes:
and calculating the average value of the Cr value and the average value of the Cb value.
The present invention also provides a hand recognition apparatus, the apparatus comprising:
the image acquisition module is used for acquiring a background RGB image and a live-action RGB image;
the skin color identification module is used for calculating a skin color identification image by utilizing a skin color identification algorithm according to the real scene RGB image;
the OTSU calculation module is used for processing the skin color identification image by utilizing an OTSU algorithm to obtain skin color identification images corresponding to different CrCb areas;
the target point characteristic color extraction module is used for carrying out difference processing on the background RGB image and the real scene RGB image and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
and the hand body recognition module is used for selecting the characteristic value of the Cr value and the skin color recognition image corresponding to the CrCb region where the characteristic value of the Cb value is located as a hand body recognition result.
Optionally, the skin color identification module includes:
the converting unit is used for converting the real scene RGB image into a real scene YCrCb image;
and the skin color identification unit is used for processing the real-scene YCrCb image by utilizing a skin color identification algorithm to obtain a skin color identification image.
Optionally, the target point feature color extraction module includes:
the difference making unit is used for performing fuzzy difference making processing on the background RGB image and the real-scene RGB image to obtain a fuzzy difference making image;
a target point coordinate obtaining unit, configured to perform binarization processing on the blurred difference image to obtain a binarized image, and obtain a target coordinate point according to the binarized image;
the target point characteristic color extraction unit is used for acquiring the RGB numerical value of the real-scene RGB image corresponding to the target coordinate point; converting the RGB numerical value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point; and calculating the characteristic value of the Cr value and the characteristic value of the Cb value.
Optionally, the target point feature color extracting unit includes:
and the target point characteristic color extraction subunit is used for calculating the average value of the Cr value and the average value of the Cb value.
The present invention also provides a hand recognition apparatus, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the hand recognition method when executing the computer program.
The present invention also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the above-described hand recognition method.
The invention provides a hand body identification method, which comprises the following steps: acquiring a background RGB image and a live-action RGB image; calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real-scene RGB image; processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb regions; performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value; and selecting a skin color identification image corresponding to a CrCb region where the characteristic value of the Cr value and the characteristic value of the Cb value are located as a hand body identification result.
Therefore, after the skin color identification is carried out on the real scene RGB image, the skin color identification image is processed by using the OTSU algorithm to obtain the skin color identification images corresponding to different CrCb regions; selecting a skin color identification image corresponding to a CrCb area where the characteristic value is located from skin color identification images corresponding to different CrCb areas as a hand body identification result by using the characteristic value of the skin color Cr value and the characteristic value of the Cb value which are obtained by calculation and correspond to the real scene RGB image as a screening basis; therefore, the method can accurately distinguish the hand body from the noise object with the skin color similar to the skin color, and improve the accuracy rate of hand body identification; the invention also discloses a hand recognition device, equipment and a computer readable storage medium, which have the beneficial effects.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
FIG. 1 is a flowchart of a hand recognition method according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating an embodiment of converting a live-action RGB image into a Y-domain image of a live-action YCrCb image;
FIG. 3 is a diagram illustrating an embodiment of a conversion of a live-action RGB image into a Cb domain-specific image of a live-action YCrCb image;
FIG. 4 is a diagram illustrating an embodiment of converting a live-action RGB image into an image corresponding to a Cr field in a live-action YCrCb image;
fig. 5 is a diagram illustrating a skin color recognition image calculated by a skin color recognition algorithm according to an embodiment of the present invention;
fig. 6 is a schematic diagram of quadrant division of a CbCr threshold for skin color identification and a CbCr value obtained in an OSTU according to an embodiment of the present invention;
fig. 7 is a skin color identification image corresponding to the area 1 in fig. 6 according to an embodiment of the present invention;
FIG. 8 is a skin color identification image corresponding to the area 2 in FIG. 6 according to an embodiment of the present invention;
FIG. 9 is a skin color identification image corresponding to the area 3 in FIG. 6 according to an embodiment of the present invention;
FIG. 10 is a skin color identification image corresponding to the area 4 in FIG. 6 according to an embodiment of the present invention;
FIG. 11 is a diagram illustrating a blur subtraction process according to an embodiment of the present invention;
FIG. 12 is a schematic diagram of a denoised binarized image according to an embodiment of the present invention;
FIG. 13 is a block diagram of a hand recognition device according to an embodiment of the present invention;
fig. 14 is a block diagram of a hand recognition device according to an embodiment of the present invention.
Detailed Description
The core of the invention is to provide a hand body identification method, which accurately distinguishes a hand body and a noise object similar to skin color in a skin color identification image by using an OTSU algorithm, a characteristic value of a Cr value and a characteristic value of a Cb value; the invention further provides a hand recognition device, equipment and a computer readable storage medium.
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In the prior art, when a noise object close to the skin color of a person exists in a real scene, the skin color cannot separate a hand body from the noise object, and finally, a hand body recognition result is wrong. In the embodiment, the characteristic colors of the hand and the noise object close to the skin color can be distinguished by extracting the background RGB image and the live-action RGB image, so that an identification basis is provided for subsequent hand identification; therefore, the hand body in the skin color identification image and the noise object close to the skin color can be accurately distinguished, and the reliability and the accuracy of hand-held identification are improved. Referring to fig. 1 in detail, fig. 1 is a flowchart of a hand recognition method according to an embodiment of the present invention; the method can comprise the following steps:
s100, acquiring a background RGB image and a live-action RGB image;
specifically, skin color identification is a main method for hand body identification, and is based on color transformation of an RGB color gamut. Therefore, the present embodiment first acquires a live RGB image when performing hand recognition. At present, in the prior art, only a real-scene RGB image needs to be acquired when hand recognition is performed. In this embodiment, a background RGB image needs to be obtained, which is mainly used to distinguish the hand from the noise object feature color similar to the skin color by using the background RGB image, so as to provide an identification basis for subsequent hand identification.
The embodiment does not limit the way of acquiring the background RGB image and the real-scene RGB image, and for example, the images can be directly acquired by a camera; the background RGB image and the real RGB image (such as the background RGB image domain and the real RGB image domain) transmitted by other devices after shooting can also be acquired. Further, the size of the background RGB image and the real RGB image is not limited in this embodiment, and the user can select the image according to actual requirements.
S110, calculating by using a skin color recognition algorithm according to the real-scene RGB image to obtain a skin color recognition image;
specifically, the step is mainly to perform skin color identification on the real-scene RGB image to obtain a skin color identification image, that is, a hand body identification result in the real-scene RGB image. The embodiment does not limit the specific skin color recognition algorithm. For example, using existing skin color recognition algorithms known in the art. Optionally, the calculating the skin color recognition image by using the skin color recognition algorithm according to the live-action RGB image may include:
converting the real-scene RGB image into a real-scene YCrCb image;
and processing the live-action YCrCb image by using a skin color identification algorithm to obtain a skin color identification image.
YCrCb is a color space that is commonly used in video processing for continuous motion pictures or in digital photography systems. Y is the luminance (luma) component of the color and Cb and Cr are the concentration offset components of the blue and red colors. The specific conversion formula may be as follows:
the result of converting the real RGB image into the real YCrCb image can refer to fig. 2-4. Respectively corresponding to Y domain, Cb domain and Cr domain.
The skin color identification algorithm in this embodiment may use a general skin color identification criterion, and the range of skin color points is: cb ═ 77127, Cr ═ 133173. The real-scene YCrCb image is processed by using a skin color recognition algorithm, and the obtained skin color recognition image can refer to fig. 5. Since a packing bag of a little finger in the real-scene RGB image is similar to the skin color of the hand, the packing bag as a noise object cannot be removed through the skin color identification in step S110, and the purpose of the subsequent steps in this embodiment is to remove the noise object similar to the skin color of the hand.
S120, processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb areas;
specifically, the step mainly uses OTSU algorithm (i.e. madzu algorithm) to distinguish noise background from entities. The basic principle of the OSTU is to select a specific value for the values of all points in a given graph, which must be within the range of the values in the graph, and this value divides all values in the graph into two parts, the variance of which to the point is the largest. The OTSU algorithm adopted in this embodiment is an existing algorithm, and is not described in detail again.
Obtaining a CbCr threshold of a Cb _ OSTU and a Cr _ OSTU threshold through an OTSU algorithm, and obtaining a relation between a CbCr threshold of a skin color identification algorithm and a CbCr value obtained from the OSTU according to the Cb _ OSTU threshold, the Cr _ OSTU threshold and a standard range of skin color points in the steps; in particular, it can be seen that a partition is formed which is similar to four quadrants; namely, a skin color identification image corresponding to each quadrant can be obtained. For example, four quadrants, one for each quadrant region (i.e., one CrCb region) of the skin tone identification image. The process is described below by way of example in FIG. 2 above:
the real scene image in fig. 2 is an example of a threshold value obtained by the OSTU algorithm, which is Cb _ OSTU: 98, Cr _ OSTU: 146. the universal skin color identification and discrimination standard comprises the following steps: cb ═ 77127, Cr ═ 133173. Therefore, referring to fig. 6, the relationship between the CbCr threshold for skin color identification and the CbCr values obtained in the OSTU, it can be seen that a partition similar to four quadrants is formed; the plan is divided into 4 quadrants 1, 2, 3, 4. Please refer to fig. 7-10, which are the skin color identification images corresponding to the 1, 2, 3, and 4 regions, respectively.
In the following steps S130 to S140, the image information without the hand is used as the background image information, then the current real-time live-action image information and the background image information are subjected to subtraction processing, a characteristic color capable of distinguishing the hand from a noise object close to the skin color is extracted from the subtraction result, and the skin color identification image with the noise object close to the skin color removed can be selected from the skin color identification images corresponding to different CrCb regions through the characteristic color.
S130, performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result;
specifically, the main purpose of this step is to obtain the Cr value and the Cb value corresponding to each point in the corresponding region of the hand image in the real RGB image. The difference between the background RGB image in this embodiment and the real-scene RGB image is that there is no hand in the background RGB image.
Further, the embodiment does not limit the specific way of performing the difference processing. For example, blur subtraction processing may be performed. The embodiment also does not limit the specific way of extracting the corresponding Cr value and Cb value of the target coordinate point in the subtraction result. For example, a target coordinate point (i.e., a coordinate point corresponding to the hand body region) in the subtraction result may be extracted by a binary method, and a Cr value and a Cb value corresponding to the target coordinate point may be obtained (for example, the RGB value in the real-world RGB image corresponding to the target coordinate point may be obtained first, and the RGB value may be converted into the Cr value and the Cb value). The user can select the response algorithm according to the actual situation. And the process of noise reduction and the like for improving the accuracy can be added according to the actual situation in the calculation process.
Optionally, performing difference processing on the background RGB image and the real-scene RGB image, and extracting corresponding Cr values and Cb values of the target coordinate points in the difference result may include:
carrying out fuzzy subtraction processing on the background RGB image and the real-scene RGB image to obtain a fuzzy subtraction image;
in particular, because there may be camera shake, the matching degree of the real RGB image and the background RGB image is not very high. For example, in the image matrix, the background RGB image is white of the ceiling, the real RGB image is black of the bag, and the white of the ceiling may become a point of the corresponding point toward the adjacent rear in the real RGB image. The specific blur differencing process can refer to fig. 11.
Performing binarization processing on the fuzzy difference image to obtain a binarized image, and acquiring a target coordinate point according to the binarized image;
specifically, a threshold needs to be set when the binarization processing is performed on the blur difference image, and when C (i0, j0) < the threshold, C (i0, j0) is set to 0; and > threshold, C (i0, j0) is set to 1. The present embodiment does not limit the specific threshold value, and may be set according to actual situations. For example, the threshold value is 20.
Further, before the target coordinate point is obtained from the binarized image, denoising the binarized image may be further included. To improve the reliability of the binarized image. The present embodiment does not limit the specific noise reduction processing method. For example, morphological filtering, that is, dilation-erosion operation, may be applied to the binarized image, which is a common denoising method and is not described herein again. The denoised binarized image may be referred to in fig. 12.
And acquiring a target coordinate point according to the binary image, namely acquiring a coordinate point corresponding to the 1 region in the binary image as the target coordinate point. For example, the target coordinate point of black in fig. 12, that is, a point whose value after binarization is 1.
Acquiring RGB values of the real-scene RGB image corresponding to the target coordinate point;
and converting the RGB value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point.
Specifically, the target coordinate point corresponding to the 1 region in the binarized image is extracted at R, G, B values corresponding to the live view RGB image. And then converting the RGB color space into a YCrCb color space according to the conversion formula to obtain a Cr value and a Cb value corresponding to the target coordinate point. Where Y represents luminance and Cb and Cr are referred to as chrominance in the YCbCr color space, which is a space that can be used for skin color detection.
S140, calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
the purpose of this embodiment is to distinguish a hand body in a skin color recognition image from a noise object close to the skin color, where it is necessary to determine a Cr value and a Cb value corresponding to the hand body in the real RGB image according to a Cr value and a Cb value corresponding to a target coordinate point to obtain the skin color recognition image corresponding to the closest Cr Cb region from step S120. Since the Cr value and the Cb value corresponding to the noise object also exist in the Cr value and the Cb value corresponding to the target coordinate point, but the number of noise objects is a small number, the CrCb region to which the hand skin color belongs can be determined more accurately by calculating the feature value of the Cr value and the feature value of the Cb value.
The feature value is not limited in this embodiment, and may be, for example, a median value, an average value, a Cr value mode of the target coordinate point corresponding to the Cr value and the Cb value, and a Cb value mode. In the case of ensuring the calculation accuracy and the calculation efficiency, it is preferable to calculate the average value of the Cr value and the average value of the Cb value. For example, the graph is for FIG. 12, the average calculated Cr values 149.9306, and the average calculated Cb values 102.4683.
S150, selecting a skin color recognition image corresponding to a CrCb area where the characteristic value of the Cr value and the characteristic value of the Cb value are located as a hand body recognition result.
Specifically, in the step, the CrCb region to which the Cr value belongs is determined according to the feature value of the Cr value and the feature value of the Cb value, and then the skin color recognition image corresponding to the CrCb region is selected as the hand recognition result. For example, the average value 149.9306 of the Cr value and the average value 102.4683 of the Cb value indicate that the region belongs to 1 region in fig. 6. And correspondingly selecting a skin color identification image (figure 7) of the 1 area as a hand body identification result. Mean values of the hand points are Cb: 102.4683, respectively; cr: 149.9306, it is clear that the range of 1 in fig. 6 is so that the final hand detection result corresponds to fig. 7, and thus, it can be seen from fig. 7 that it has removed noise objects close to the hand skin color that cannot be removed in the original skin color recognition.
In the present embodiment, step S120 is performed after step S110, and step S140 and step S150 are performed after step S130. However, the present embodiment does not limit the execution order of step S110 and step S130. Of course both may be performed simultaneously. In step S130 and step S140, the feature values of the hand bodies Cr and Cb are obtained by subtracting the live-action image from the background image; the method is different from the hand body recognition of the live-action image based on the skin color recognition threshold value, and separates the hand body and the noise object which cannot be distinguished by the skin color recognition due to the Cr and Cb characteristic values for identifying the hand body.
Based on the technical scheme, the hand body identification method provided by the embodiment of the invention is characterized in that after the skin color identification is carried out on the live-action RGB image, the skin color identification image is processed by using an OTSU algorithm to obtain the skin color identification images corresponding to different CrCb regions; selecting a skin color identification image corresponding to a CrCb area where the characteristic value is located from skin color identification images corresponding to different CrCb areas as a hand body identification result by using the characteristic value of the skin color Cr value and the characteristic value of the Cb value which are obtained by calculation and correspond to the real scene RGB image as a screening basis; therefore, the method can accurately distinguish the hand body from the noise object close to the skin color, and improve the accuracy of hand body identification.
The following describes a hand recognition device, an apparatus, and a computer-readable storage medium according to embodiments of the present invention, and the hand recognition device, the apparatus, and the computer-readable storage medium described below and the hand recognition method described above may be referred to correspondingly.
Referring to fig. 13, fig. 13 is a block diagram of a hand recognition device according to an embodiment of the present invention; the apparatus may include:
an image obtaining module 100, configured to obtain a background RGB image and a live RGB image;
the skin color identification module 200 is used for calculating a skin color identification image by using a skin color identification algorithm according to the real-scene RGB image;
the OTSU calculating module 300 is configured to process the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb regions;
a target point characteristic color extraction module 400, configured to perform difference processing on the background RGB image and the real-scene RGB image, and extract a corresponding Cr value and a Cb value of a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
the hand body recognition module 500 is configured to select a skin color recognition image corresponding to a CrCb region where a feature value of the Cr value and a feature value of the Cb value are located as a hand body recognition result.
Based on the above embodiment, the skin color identification module 200 may include:
the converting unit is used for converting the real scene RGB image into a real scene YCrCb image;
and the skin color identification unit is used for processing the real-scene YCrCb image by utilizing a skin color identification algorithm to obtain a skin color identification image.
Based on any of the above embodiments, the target point feature color extraction module 400 may include:
the difference making unit is used for performing fuzzy difference making processing on the background RGB image and the real-scene RGB image to obtain a fuzzy difference making image;
a target point coordinate obtaining unit, configured to perform binarization processing on the blurred difference image to obtain a binarized image, and obtain a target coordinate point according to the binarized image;
the target point characteristic color extraction unit is used for acquiring RGB values of the real-scene RGB image corresponding to the target coordinate point; converting the RGB value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point; the characteristic value of the Cr value and the characteristic value of the Cb value are calculated.
Based on the above embodiment, the target point feature color extraction unit may include:
and the target point characteristic color extraction subunit is used for calculating the average value of the Cr value and the average value of the Cb value.
It should be noted that, based on any of the above embodiments, the apparatus may be implemented based on a programmable logic device, where the programmable logic device includes an FPGA, a CPLD, a single chip, and the like.
Referring to fig. 14, fig. 14 is a block diagram of a hand recognition device according to an embodiment of the present invention; the hand recognition apparatus may include:
a memory 600 for storing a computer program;
a processor 700, configured to implement acquisition of a background RGB image and a live RGB image when executing the computer program; calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real-scene RGB image; processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb regions; performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value; and selecting a skin color identification image corresponding to a CrCb region where the characteristic value of the Cr value and the characteristic value of the Cb value are located as a hand body identification result.
Further, the hand recognition device may be a mobile terminal, such as a mobile phone or the like.
The invention also provides a computer readable storage medium, on which a computer program is stored, the computer program, when executed by a processor, realizes acquiring a background RGB image and a live-action RGB image; calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real-scene RGB image; processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb regions; performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value; and selecting a skin color identification image corresponding to a CrCb region where the characteristic value of the Cr value and the characteristic value of the Cb value are located as a hand body identification result.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The embodiments are described in a progressive manner in the specification, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above description details a method, an apparatus, a device and a computer readable storage medium for hand recognition provided by the present invention. The principles and embodiments of the present invention are explained herein using specific examples, which are presented only to assist in understanding the method and its core concepts. It should be noted that, for those skilled in the art, it is possible to make various improvements and modifications to the present invention without departing from the principle of the present invention, and those improvements and modifications also fall within the scope of the claims of the present invention.
Claims (10)
1. A hand recognition method, the method comprising:
respectively acquiring a background RGB image and a real scene RGB image;
calculating to obtain a skin color identification image by using a skin color identification algorithm according to the real scene RGB image;
processing the skin color identification image by using an OTSU algorithm to obtain skin color identification images corresponding to different CrCb areas;
performing difference processing on the background RGB image and the real scene RGB image, and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result;
calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
and selecting the characteristic value of the Cr value and a skin color identification image corresponding to the CrCb region where the characteristic value of the Cb value is located as a hand body identification result.
2. The method of claim 1, wherein calculating a skin color identification image from the real world RGB image using a skin color identification algorithm comprises:
converting the real scene RGB image into a real scene YCrCb image;
and processing the real-scene YCrCb image by using a skin color identification algorithm to obtain a skin color identification image.
3. The method as claimed in claim 1 or 2, wherein the difference processing of the background RGB image and the real RGB image and extracting the corresponding Cr value and Cb value of the target coordinate point in the difference result comprises:
performing fuzzy subtraction processing on the background RGB image and the real-scene RGB image to obtain a fuzzy subtraction image;
carrying out binarization processing on the fuzzy difference image to obtain a binarized image, and acquiring a target coordinate point according to the binarized image;
acquiring the RGB numerical value of the real-scene RGB image corresponding to the target coordinate point;
and converting the RGB numerical value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point.
4. The method of claim 3, wherein calculating the Cb value and the Cr value comprises:
and calculating the average value of the Cr value and the average value of the Cb value.
5. A hand recognition device, the device comprising:
the image acquisition module is used for respectively acquiring a background RGB image and a real scene RGB image;
the skin color identification module is used for calculating a skin color identification image by utilizing a skin color identification algorithm according to the real scene RGB image;
the OTSU calculation module is used for processing the skin color identification image by utilizing an OTSU algorithm to obtain skin color identification images corresponding to different CrCb areas;
the target point characteristic color extraction module is used for carrying out difference processing on the background RGB image and the real scene RGB image and extracting a Cr value and a Cb value corresponding to a target coordinate point in a difference result; calculating a characteristic value of the Cr value and a characteristic value of the Cb value;
and the hand body recognition module is used for selecting the characteristic value of the Cr value and the skin color recognition image corresponding to the CrCb region where the characteristic value of the Cb value is located as a hand body recognition result.
6. The apparatus of claim 5, wherein the skin tone identification module comprises:
the converting unit is used for converting the real scene RGB image into a real scene YCrCb image;
and the skin color identification unit is used for processing the real-scene YCrCb image by utilizing a skin color identification algorithm to obtain a skin color identification image.
7. The apparatus of claim 5 or 6, wherein the target point feature color extraction module comprises:
the difference making unit is used for performing fuzzy difference making processing on the background RGB image and the real-scene RGB image to obtain a fuzzy difference making image;
a target point coordinate obtaining unit, configured to perform binarization processing on the blurred difference image to obtain a binarized image, and obtain a target coordinate point according to the binarized image;
the target point characteristic color extraction unit is used for acquiring the RGB numerical value of the real-scene RGB image corresponding to the target coordinate point; converting the RGB numerical value into a YCrCb color space to obtain a Cr value and a Cb value corresponding to the target coordinate point; and calculating the characteristic value of the Cr value and the characteristic value of the Cb value.
8. The apparatus of claim 7, wherein the target point feature color extraction unit comprises:
and the target point characteristic color extraction subunit is used for calculating the average value of the Cr value and the average value of the Cb value.
9. A hand recognition apparatus, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the hand recognition method of any one of claims 1 to 4 when executing the computer program.
10. A computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, which computer program, when being executed by a processor, carries out the steps of the hand recognition method according to any one of claims 1 to 4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810064021.8A CN108133204B (en) | 2018-01-23 | 2018-01-23 | Hand body identification method, device, equipment and computer readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810064021.8A CN108133204B (en) | 2018-01-23 | 2018-01-23 | Hand body identification method, device, equipment and computer readable storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108133204A CN108133204A (en) | 2018-06-08 |
CN108133204B true CN108133204B (en) | 2021-02-02 |
Family
ID=62400103
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810064021.8A Active CN108133204B (en) | 2018-01-23 | 2018-01-23 | Hand body identification method, device, equipment and computer readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108133204B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111815662A (en) * | 2019-04-11 | 2020-10-23 | 上海集森电器有限公司 | Behavior recognition implementation method based on face detection |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104331690A (en) * | 2014-11-17 | 2015-02-04 | 成都品果科技有限公司 | Skin color face detection method and system based on single picture |
US9196219B1 (en) * | 2012-07-18 | 2015-11-24 | Amazon Technologies, Inc. | Custom color spectrum for skin detection |
CN106529432A (en) * | 2016-11-01 | 2017-03-22 | 山东大学 | Hand area segmentation method deeply integrating significance detection and prior knowledge |
CN106778704A (en) * | 2017-01-23 | 2017-05-31 | 安徽理工大学 | A kind of recognition of face matching process and semi-automatic face matching system |
CN106845388A (en) * | 2017-01-18 | 2017-06-13 | 北京交通大学 | The extracting method of the mobile terminal palmmprint area-of-interest based on complex scene |
-
2018
- 2018-01-23 CN CN201810064021.8A patent/CN108133204B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9196219B1 (en) * | 2012-07-18 | 2015-11-24 | Amazon Technologies, Inc. | Custom color spectrum for skin detection |
CN104331690A (en) * | 2014-11-17 | 2015-02-04 | 成都品果科技有限公司 | Skin color face detection method and system based on single picture |
CN106529432A (en) * | 2016-11-01 | 2017-03-22 | 山东大学 | Hand area segmentation method deeply integrating significance detection and prior knowledge |
CN106845388A (en) * | 2017-01-18 | 2017-06-13 | 北京交通大学 | The extracting method of the mobile terminal palmmprint area-of-interest based on complex scene |
CN106778704A (en) * | 2017-01-23 | 2017-05-31 | 安徽理工大学 | A kind of recognition of face matching process and semi-automatic face matching system |
Also Published As
Publication number | Publication date |
---|---|
CN108133204A (en) | 2018-06-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110008954B (en) | Complex background text image extraction method and system based on multi-threshold fusion | |
US10783617B2 (en) | Device for and method of enhancing quality of an image | |
WO2020125631A1 (en) | Video compression method and apparatus, and computer-readable storage medium | |
CN103973977B (en) | Virtualization processing method, device and the electronic equipment of a kind of preview interface | |
EP3644599B1 (en) | Video processing method and apparatus, electronic device, and storage medium | |
JP2018088247A (en) | Image processing apparatus and method for correcting foreground mask for object segmentation | |
CN110390643B (en) | License plate enhancement method and device and electronic equipment | |
CN112887693B (en) | Image purple border elimination method, equipment and storage medium | |
JP6779688B2 (en) | Image processing equipment, image processing method, computer program | |
CN108389215B (en) | Edge detection method and device, computer storage medium and terminal | |
CN110248177B (en) | Image data processing method and device | |
Lee et al. | Color image enhancement using histogram equalization method without changing hue and saturation | |
KR20130000827A (en) | A method for edge enhancement of image | |
KR101875891B1 (en) | apparatus and method for face detection using multi detection | |
CN110599553B (en) | Skin color extraction and detection method based on YCbCr | |
JP5286215B2 (en) | Outline extracting apparatus, outline extracting method, and outline extracting program | |
CN108133204B (en) | Hand body identification method, device, equipment and computer readable storage medium | |
CN111414877B (en) | Table cutting method for removing color frame, image processing apparatus and storage medium | |
CN112052726A (en) | Image processing method and device | |
KR100488014B1 (en) | YCrCb color based human face location detection method | |
CN115829848A (en) | Method, apparatus and computer-readable storage medium for processing graphic symbols | |
CN110942420B (en) | Method and device for eliminating image captions | |
CN109934215B (en) | Identification card identification method | |
CN112699760A (en) | Face target area detection method, device and equipment | |
Powar et al. | Skin detection for forensic investigation |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20210722 Address after: 264300 No. 699, Jiangjun South Road, Rongcheng City, Weihai City, Shandong Province Patentee after: Rongcheng goer Technology Co.,Ltd. Address before: 266100 Room 308, Beizhai Street Investment Service Center, Laoshan District, Qingdao City, Shandong Province Patentee before: GOERTEK TECHNOLOGY Co.,Ltd. |