WO2019041967A1 - 手和图像检测方法和系统、手分割方法、存储介质和设备 - Google Patents

手和图像检测方法和系统、手分割方法、存储介质和设备 Download PDF

Info

Publication number
WO2019041967A1
WO2019041967A1 PCT/CN2018/091321 CN2018091321W WO2019041967A1 WO 2019041967 A1 WO2019041967 A1 WO 2019041967A1 CN 2018091321 W CN2018091321 W CN 2018091321W WO 2019041967 A1 WO2019041967 A1 WO 2019041967A1
Authority
WO
WIPO (PCT)
Prior art keywords
connected domain
image
point
starting point
region
Prior art date
Application number
PCT/CN2018/091321
Other languages
English (en)
French (fr)
Inventor
赵骥伯
Original Assignee
京东方科技集团股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 京东方科技集团股份有限公司 filed Critical 京东方科技集团股份有限公司
Priority to US16/342,626 priority Critical patent/US10885321B2/en
Priority to EP18850076.3A priority patent/EP3678046B1/en
Publication of WO2019041967A1 publication Critical patent/WO2019041967A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/011Arrangements for interaction with the human body, e.g. for user immersion in virtual reality
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/017Gesture based interaction, e.g. based on a set of recognized hand gestures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/0304Detection arrangements using opto-electronic means
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/136Segmentation; Edge detection involving thresholding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/187Segmentation; Edge detection involving region growing; involving region merging; involving connected component labelling
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/107Static hand or arm
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/20Movements or behaviour, e.g. gesture recognition
    • G06V40/28Recognition of hand or arm movements, e.g. recognition of deaf sign language
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20068Projection on vertical or horizontal image axis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20112Image segmentation details
    • G06T2207/20132Image cropping
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30196Human being; Person
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/56Extraction of image or video features relating to colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/74Image or video pattern matching; Proximity measures in feature spaces
    • G06V10/75Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
    • G06V10/755Deformable models or variational models, e.g. snakes or active contours
    • G06V10/7553Deformable models or variational models, e.g. snakes or active contours based on shape, e.g. active shape models [ASM]

Definitions

  • Embodiments of the present disclosure relate to a hand detection method, a hand division method, an image detection method, an image detection system, a storage medium, and an apparatus including the image detection system or the storage medium.
  • Hand detection is the basis of gesture recognition technology. Hand detection refers to marking a hand in a motion picture file or a still picture. In hand detection, finger fingertip information can be extracted or hand segmentation can be performed.
  • Embodiments of the present disclosure provide a hand detection method, a hand division method, an image detection method, an image detection system, a storage medium, and an apparatus including the image detection system or storage medium.
  • At least one embodiment of the present disclosure provides an image detecting method including: determining a first starting point in a connected domain in an image to be detected; determining a difference from the first starting point in a connected domain of the image to be detected n extreme points, wherein the Nth far point is the pixel point having the largest geodesic distance from the connected domain to the Nth starting point, and the N+1th starting point is the Nth far point, and n and N are positive An integer, and N ⁇ n; performing region growth with the n extreme points as initial points, respectively, to acquire n regions in the connected domain; and determining a preset for each of the n regions Whether the relationship between the feature and the preset feature of the connected domain satisfies the selection condition to determine an effective region that satisfies the selection condition.
  • the distance between the object point corresponding to the first starting point to the center of gravity of the connected domain in the image to be detected and the corresponding object point in the geometric center of the circumscribed pattern of the connected domain is less than 2 cm.
  • the method further includes: acquiring coordinates of a very far point included in the effective area.
  • the method further includes: determining a data change direction of the connected domain by using a principal component analysis method, and segmenting the connected domain according to the data change direction according to the first reference length to obtain a target image,
  • the first reference length is a product of a size of the effective area and a first predetermined multiple.
  • the data change direction of the connected domain is the main direction of the connected domain.
  • the method is for hand detection.
  • the first preset multiple is 1.5-1.7.
  • the first reference length is a product of a size of an effective region having a maximum length and the first predetermined multiple.
  • the selection condition of the effective area includes at least one or more of A, B, or C, wherein A: the first ratio of the length of each of the areas to the maximum width of the connected domain is not less than 1/ 3 and not more than 1.5; B: a second ratio of a width of each of the regions to a maximum width of the connected domain is not more than 1/5; C: an area of each of the regions and an area of the connected domain The third ratio is no more than 1/5.
  • the method before acquiring the first starting point, further includes: acquiring a second image including an initial connected domain from the first image according to the color range; and processing the initial connected domain of the second image to obtain a connected domain in the image to be detected.
  • the method is for hand detection, and processing the initial connected domain to obtain the connected domain includes: determining a data change direction of the initial connected domain by using a principal component analysis method; and making coordinates of the second image
  • the preset coordinate axis of the system is parallel to the data change direction of the initial connected domain; for each of the plurality of positions of the preset coordinate axis, the pixel corresponding to each of the positions in the initial connected domain is calculated
  • the number of points, the maximum number of pixels is selected as the reference number, and the product of the reference quantity and the second preset multiple is taken as the second reference length; and the data change direction along the initial connected domain and according to the The two reference lengths segment the initial connected domain to obtain a connected domain in the image to be detected.
  • the second preset multiple is greater than or equal to 2.5 and less than or equal to 3.
  • the method of determining the growth end point of the region includes: after the i-th growth of the region, if the pixel is in the i+1th growth of the region The increase in the number exceeds a preset value, then the ith growth is the last growth of the region.
  • the growth end point of the region is determined according to a preset length.
  • the image to be detected does not include depth information of a pixel.
  • At least one embodiment of the present disclosure also provides an image detection system including a processor, a memory, and computer program instructions stored in the memory, wherein the computer program instructions are executed by the processor: at the Determining a first starting point in the connected domain of the detected image; determining n far points different from the first starting point in the connected domain of the image to be detected, wherein the Nth far point is the connected domain
  • the pixel with the largest geodesic distance from the Nth starting point, the N+1 starting point is the Nth far point
  • n and N are both positive integers, and N ⁇ n; respectively, taking the n extreme points as initial points.
  • Region growing to acquire n regions in the connected domain and determining whether a relationship between a preset feature of each of the n regions and a preset feature of the connected domain satisfies a selection condition, A valid area that satisfies the selection condition is determined.
  • the distance between the object point corresponding to the first starting point to the center of gravity of the connected domain in the image to be detected and the corresponding object point in the geometric center of the circumscribed pattern of the connected domain is less than 2 cm.
  • At least one embodiment of the present disclosure also provides an image detecting system including: a point determining device configured to determine a first starting point and a different starting point from the first starting point in a connected domain of the image to be detected n extreme points, the N+1th starting point is the Nth pole far point, and the Nth pole far point is the pixel point having the largest geodesic distance from the connected domain to the Nth starting point, and n and N are both positive integers.
  • region determining means configured to: perform area growing with the n extreme points as initial points, respectively, to acquire n areas in the connected domain; and determining means configured to : determining whether a relationship between a preset feature of each of the n regions and a preset feature of the connected domain satisfies a selection condition to determine an effective region that satisfies the selection condition.
  • the distance between the object point corresponding to the first starting point to the center of gravity of the connected domain in the image to be detected and a corresponding object point in the geometric center of the circumscribed pattern of the connected domain is less than 2 cm.
  • the image detecting system further includes an extracting device configured to: acquire coordinates of a far point including the effective region; or determine a data change direction of the connected domain by using a principal component analysis method, and along The data changes direction and divides the connected domain according to a reference length to obtain a target image, where the reference length is a product of a size of the effective area and a preset multiple.
  • At least one embodiment of the present disclosure also provides a storage medium having stored therein computer program instructions adapted to be loaded and executed by a processor: determining a first starting point in a connected domain of the image to be detected; Determining n far points different from the first starting point in the connected domain of the image to be detected, wherein the Nth far point is a pixel point having the largest geodesic distance from the connected domain to the Nth starting point
  • the N+1th starting point is the Nth pole far point
  • n and N are both positive integers, and N ⁇ n
  • the region growth is performed with the n extreme points as initial points, respectively, to obtain in the connected domain n regions; and determining whether a relationship between a preset feature of each of the n regions and a preset feature of the connected domain satisfies a selection condition to determine an effective region that satisfies the selection condition.
  • the distance between the object point corresponding to the first starting point to the center of gravity of the connected domain in the image to be detected and a corresponding object point in the geometric center of the circumscribed pattern of the connected domain is less than 2 cm.
  • At least one embodiment of the present disclosure also provides an apparatus comprising the image detection system of any of the above or the storage medium described above.
  • At least one embodiment of the present disclosure also provides a hand detection method, including: determining a position of a palm in a connected domain in an image to be detected; determining a position different from the position of the palm with the position of the palm as a first starting point n extreme points, wherein the Nth far point is the pixel point having the largest geodesic distance from the connected domain to the Nth starting point, and the N+1th starting point is the Nth far point, and n and N are positive An integer, and N ⁇ n; performing region growth with the n extreme points as initial points, respectively, to acquire n regions in the connected domain; and determining a preset for each of the n regions Whether the relationship between the feature and the preset feature of the connected domain satisfies the selection condition to determine a valid finger region that satisfies the selection condition.
  • At least one embodiment of the present disclosure further provides a hand segmentation method, including: acquiring a skin color connected domain by skin color detection; acquiring a maximum width of the skin color connected domain and a principal direction based on a principal component analysis method along the main direction And dividing the skin color connected domain according to the preset multiple of the maximum width to obtain a suspected hand connected domain; and the hand detecting method described above determines whether the suspected hand connected domain includes the valid finger region.
  • FIG. 1 is a flowchart of an image detecting method according to an embodiment of the present disclosure
  • FIG. 2 is a flowchart of acquiring an image to be detected by using a first image in an image detecting method according to an embodiment of the present disclosure
  • FIG. 3 is a flowchart of splitting an initial connected domain in an image detecting method according to an embodiment of the present disclosure
  • FIG. 4 is a flowchart of an image detection method according to an embodiment of the present disclosure for hand detection
  • FIG. 5 is a flowchart of skin color detection in an image detecting method according to an embodiment of the present disclosure
  • FIG. 6 is a flowchart of an arm deletion process in an image detecting method according to an embodiment of the present disclosure
  • FIG. 7(A) to 7(D) are diagrams showing the processing effect obtained in each step of the arm deletion processing in the image detecting method according to the embodiment of the present disclosure
  • FIG. 8 is a flowchart of determining a valid finger area in an image detecting method according to an embodiment of the present disclosure
  • FIG. 9 are schematic diagrams of respective extreme points detected in the image detecting method provided by the embodiments of the present disclosure.
  • FIG. 10 is a schematic diagram of performing region growth in an image detecting method according to an embodiment of the present disclosure.
  • FIG. 11 are front and rear comparison views of the connected domain according to the effective finger region in the image detecting method provided by the embodiment of the present disclosure
  • FIG. 12 are hand images obtained by the image detecting method provided by the embodiment of the present disclosure.
  • FIG. 13 is a structural block diagram of an image detection system according to an embodiment of the present disclosure.
  • FIG. 14 is a structural block diagram of another image detection system according to an embodiment of the present disclosure.
  • FIG. 15 is a flowchart of a method for detecting a hand according to an embodiment of the present disclosure
  • FIG. 16 is a flowchart of a method for dividing a hand according to an embodiment of the present disclosure.
  • Embodiments of the present disclosure provide an image detecting method, an image detecting system, a storage medium, a device including the image detecting system or a storage medium, a hand detecting method, and a hand segmentation method.
  • the general idea of an embodiment of the present disclosure is to determine a first starting point for a connected domain (which can also be written as a connected domain) in an image to be detected, and determine at least one extreme far point according to the first starting point, for example, n extremely far a point, wherein the Nth far point is a pixel point having the largest geodesic distance from the connected domain to the Nth starting point, and the N+1th starting point is the Nth far point (where the Nth pole is obtained according to the Nth starting point) Far point, and the obtained Nth far point is taken as the N+1th starting point; and so on), n and N are both positive integers, and N ⁇ n; the region growth is performed with the at least one extreme far point as the initial point And obtaining at least one area (hereinafter referred to as a suspected area); detecting whether the at least one area satisfies the selection condition; if the effective area satisfying the selection condition is obtained, the effective area may be utilized to extract necessary information or perform subsequent analysis.
  • a suspected area
  • the suspected region obtained by performing the region growing with the extreme point as the initial point may be the region where the target object is located, and the suspected region is obtained by using the region growing manner, which can avoid the target object in the image to be detected.
  • the interference of the connected domain but actually corresponds to the region of the interferer; the suspected region is detected according to the preset selection condition to determine the effective region, and the interference region in the image to be detected may be further excluded; since the effective region satisfies the selection condition, It is considered that the effective area is the area where a part of the target object is located.
  • the interference factor of the image detection can be further reduced to improve the accuracy of the image detection result.
  • the image detection technology provided by the embodiments of the present disclosure can effectively reduce interference factors, and thus can realize fast real-time calculation.
  • embodiments of the present disclosure may be used in hand detection for image recognition, i.e., for detecting a hand from an image.
  • embodiments of the present disclosure are used for fingertip detection or hand segmentation in hand detection (ie, extracting a hand image from an image).
  • the actual object corresponding to the connected domain in the image to be detected may include a hand, hereinafter referred to as a suspected hand connected domain;
  • the first starting point may be the palm (also referred to as palm) position;
  • the far point may be a finger
  • the position of the fingertip is hereinafter referred to as the fingertip of the suspected finger;
  • the area obtained by the region growth with the far point as the initial point may be the area where the finger is located (hereinafter referred to as the suspected finger area);
  • the effective area satisfying the selection condition is regarded as The area where the finger is located, hereinafter referred to as the effective finger area;
  • the selection condition is determined according to the morphological characteristics of the hand, such as the relationship between the size (e.g., length, width or area) of the finger and the size of the palm.
  • the far point including the effective area may be used as a fingertip, and the coordinates of the fingertip may be acquired by acquiring the coordinates of the extreme point. .
  • the length of the hand is about 1.5 times the length of the finger. Therefore, in the case of the hand segmentation for image recognition in the embodiment of the present disclosure, the relationship between the length of the hand and the length of the finger can be utilized, and the connected domain is segmented according to the size of the effective region to remove the connected domain. The area where the object other than the hand is located, thereby acquiring the target image (ie, the hand image).
  • the hand detection method, the image detection method, the hand segmentation method, the image detection system, the storage medium, and the device including the image detection system or the storage medium provided by the embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.
  • At least one embodiment of the present disclosure provides an image detecting method, as shown in FIG. 1, the image detecting method includes the following steps S11 to S14.
  • Step S11 The first starting point is determined in the connected domain in the image to be detected.
  • the first starting point is determined based on the center of gravity or the geometric center of the connected domain. For example, the distance between the object point corresponding to the first starting point to the center of gravity of the connected domain in the image to be detected and a corresponding object point in the geometric center of the circumscribed pattern of the connected domain is less than 2 cm.
  • the first starting point is one of a center of gravity of a connected domain in the image to be detected and a geometric center of the circumscribed figure of the connected domain, or a first starting point is a neighboring point of the center of gravity point, or the first point The starting point is the neighborhood point of the geometric center.
  • the first starting point in the connected domain of the image to be detected is used to indicate the position of the palm, and the first starting point can be avoided by determining the first starting point according to the center of gravity or the geometric center of the connected domain. A point that is too close to the pixel point of the fingertip.
  • the connected domain is composed of a plurality of pixels having connectivity. For any pixel in the region, the four pixels of the left, top, right, and bottom are called four neighborhood points, and the eight pixels of the left, upper, right, lower, and upper left, upper right, lower right, and lower left are called For an eight-neighbor point, the pixel is connected to any of its neighbor points.
  • the coordinates of the center of gravity of the connected domain are the average values of the coordinates of all the pixels in the connected domain, that is, the X coordinate of the center of gravity is the arithmetic mean of the X coordinates of all the pixels in the connected domain, and the Y of the center of gravity The coordinates are the arithmetic mean of the Y coordinates of all pixels in the connected domain. Since the center of gravity is not affected by the contour shape of the connected domain, the center of gravity as the first starting point can avoid the influence of the shape of the object corresponding to the connected domain on the detection result.
  • the circumscribed shape of the connected domain can be an circumscribed rectangle or an ellipse, for example, the geometric center can be determined according to the geometry of the circumscribed graph.
  • Step S12 determining n extreme points different from the first starting point, and the Nth far point is the pixel point having the largest Geodesic Distance in the connected domain to the Nth starting point, the N+1th The starting point is the Nth extreme point, and both n and N are positive integers.
  • n can be 1, or n can be greater than or equal to 2.
  • step S12 may include: calculating a geodesic distance from a pixel point in the connected domain to the first starting point, and selecting a pixel point having the largest geodesic distance as the first extreme point; The first extreme point is used as the second starting point, and the geodesic distance from the pixel point in the connected domain to the second starting point is calculated, and the pixel point having the largest geodesic distance is selected as the second pole far point; and so on.
  • Geodesic distance is an important concept in mathematical morphology to measure the distance between two points. Unlike the Euclidean distance, the geodesic distance takes into account the connectivity of the area. At least one line in the connected domain can connect two points A and B. The shortest one of the at least one line is called a geodesic arc between A and B, and the length of the geodesic arc is the geodetic distance. The geodesic distance is the gradient of the graph, and the two points are connected along the maximum direction of the gradient to obtain the geodesic arc.
  • Step S13 performing region growth with n extreme points as initial points, respectively, to acquire n regions in the connected domain.
  • the growth end point of each region can be determined using the shape (eg, contour shape, size) characteristics of the target object. Since the width of the hand changes significantly at the base of the finger, in the case where the object corresponding to the connected domain includes the hand, this morphological feature of the hand can be utilized to determine the end point of the region growth.
  • shape eg, contour shape, size
  • the method of determining the growth end point of the region includes: after a certain growth of the region, for example, after the ith growth (i is greater than or equal to 1), if the region is at the The increase value of the number of pixel points in the i+1 growth exceeds a preset value (which can be set according to actual needs), then the ith time is the last growth of the region, and the ith pixel is grown.
  • the position at which the point is located is the end position of the area.
  • the growth end point of the region may also be determined according to a preset length (which may be set according to actual needs).
  • Step S14 determining whether the relationship between the preset feature of each of the n regions and the preset feature of the connected domain satisfies the selection condition to determine an effective region that satisfies the selection condition.
  • a predetermined feature of each region may be a size feature of the region, such as the length, width, or area of the region.
  • the area of the area can be represented by the number of pixels in the area.
  • the pre-set feature of the connected domain can be a dimension feature of the connected domain, such as the length, width, or area of the connected domain.
  • the area of the connected domain can be represented by the number of pixels in the connected domain.
  • the relationship between the size feature of the finger and the size feature of the hand can be utilized to determine the selection condition of the effective region.
  • the selection condition of the effective area includes at least one or more of (A), (B), or (C).
  • Condition (A) according to the characteristic that the ratio of the length of the finger to the width of the palm is not less than 1/3 and not more than 1.5, the first ratio of the length of each region to the maximum width of the connected domain is not less than 1/3 and not more than 1.5.
  • the length of each region is the number of pixel points in the direction from the initial point of the region (ie, the extreme point included in the region) to the end of the region.
  • the width of each region is the number of pixel points in the width direction of the region at which the growth end point of the region is.
  • Condition (C) according to the feature that the ratio of the area of the finger to the area of the hand is not more than 1/5, the third ratio of the area of each area to the area of the connected domain is not more than 1/5.
  • the area may be represented by the number of pixels, and the ratio of the number of pixels of each area to the number of pixels of the connected field is not more than 1/5.
  • the number of pixels per region can be obtained during the process of growing regions.
  • the number of pixels in the connected domain can be obtained by calculating the geodesic distance to find a very far point.
  • the image detecting method provided by at least one embodiment of the present disclosure may further include step S15A or step S15B.
  • Step S15A Acquire coordinates of a very far point included in the effective area.
  • the coordinates of the extreme point may be used as fingertip coordinates.
  • Step S15B determining a data change direction of the connected domain by using a principal component analysis method, and dividing the connected domain according to the data change direction and according to the first reference length to obtain a target image, where the first reference length is the effective area The product of the size and the first preset multiple.
  • the Principle Component Analysis (PCA) method is a multivariate statistical analysis method that transforms data into a new coordinate system by linear transformation, so that the variance of the data on the first coordinate axis is maximized, in the second
  • the variance of the data on the coordinate axes is the second largest, and so on; wherein the direction of the first coordinate axis is the main direction, that is, the main direction is the direction in which the variance of the data is the largest, and the second direction is the direction in which the variance of the data is the second largest.
  • Both the primary direction and the secondary direction are referred to as the direction of data change.
  • the main direction of the hand is its length direction (extension direction), and the secondary direction of the hand is its width direction. Therefore, in the case of the hand-detection in the embodiment of the present disclosure, for example, the data change direction of the connected domain may be the main direction of the connected domain, and the first reference length may be the product of the length of the effective region and the first preset multiple. . That is, in the case where the embodiment of the present disclosure is used for hand detection, the connected domain is segmented along the main direction of the connected domain and according to the product of the length of the effective region and the first predetermined multiple to remove the connected domain. The area of the object other than the hand, thereby obtaining the hand connected domain.
  • the first reference length is a product of a size of the effective region having the largest length and a first predetermined multiple. Since the thumb extends substantially in the secondary direction of the hand, the remaining fingers extend substantially in the main direction of the hand, and the accuracy of the hand segmentation can be improved by determining the first reference length from the effective region having the largest length.
  • the first preset multiple may be set to 1.5-1.7.
  • the first preset multiple is not less than 1.5, which is beneficial to avoid that the target image includes only a part of the hand but not all of the connected domains.
  • the image to be detected in the embodiment of the present disclosure may not include depth information, and the depth information refers to the distance from the object point corresponding to the pixel point in the image to the camera that captured the image.
  • the depth information refers to the distance from the object point corresponding to the pixel point in the image to the camera that captured the image.
  • the effective region can be judged according to the relationship between the size feature of the suspected region and the size feature of the connected domain, it is not required to be used.
  • Depth information therefore, embodiments of the present disclosure can be used to detect images taken by a normal camera.
  • the camera includes a depth-aware camera, a stereo camera, and a general camera.
  • both the depth camera and the stereo camera can obtain images with depth information, and an ordinary camera can obtain images without depth information.
  • the image to be detected may also include depth information.
  • the selection condition for determining the effective area may be set according to the depth information, or may not involve the depth information.
  • the image captured by the ordinary camera does not include the depth information, in this case, in order to acquire the connected domain in the image to be detected, the image taken by the ordinary camera can be processed according to the color range.
  • the image detecting method provided by at least one embodiment of the present disclosure further includes step S21 and step S22.
  • Step S21 Acquire a second image including an initial connected domain from the first image according to the color range.
  • the first image can be a color image.
  • the first image may be a color image taken with a normal camera, in which case the first image does not have depth information.
  • the color range may be determined according to the skin color, that is, the second image including the initial connected domain may be acquired from the first image according to the skin color, which is hereinafter referred to as
  • the initial connected domain obtained by skin color detection is hereinafter referred to as the skin color connected domain.
  • Step S22 Processing the initial connected domain of the second image to obtain a connected domain in the image to be detected.
  • a part of the interference can be removed, thereby obtaining a connected domain in the image to be detected with less interference.
  • the object corresponding to the initial connected domain acquired through the above step S21 may include a hand and an arm; in this step S22, the processing performed on the initial connected domain is, for example, an image.
  • the segmentation process is performed to delete the arm in the connected domain, which is hereinafter referred to as an arm deletion process.
  • the above step S22 may include steps S31 to S34.
  • Step S31 The principal component analysis method is used to determine the data change direction of the initial connected domain.
  • the direction of data change of the initial connected domain can be its primary direction.
  • Step S32 The preset coordinate axis of the coordinate system of the second image is made parallel to the data change direction of the initial connected domain.
  • the preset coordinate axis is the Y axis.
  • the Y-axis of the coordinate system of the second image is parallel to the main direction of the initial connected domain
  • the X-axis is parallel to the secondary direction of the initial connected domain.
  • Step S33 For each of the plurality of positions of the preset coordinate axis, the number of pixel points corresponding to each position in the initial connected domain is calculated.
  • the distance between adjacent positions on the preset coordinate axis is the unit length of the Y axis.
  • Step S34 Select the maximum number of pixel points as the reference quantity, use the product of the reference quantity and the second preset multiple as the second reference length, and divide the initial connected domain according to the data change direction of the initial connected domain and according to the second reference length. To obtain the connected domain in the image to be detected.
  • the maximum number of pixels can be regarded as the number of pixels corresponding to the width of the palm, that is, the reference number reflects the width of the palm.
  • the length of the hand is about k (k is 2.5-3.0) times the width of the palm
  • the length of the hand can be estimated from k times the number of references reflecting the width of the palm.
  • the second preset multiple is, for example, 2.5-3.0
  • the second reference length is used to indicate the length of the hand
  • the initial connected domain is segmented along the main direction of the initial connected domain and according to the second reference length, and the connected domain may be removed. The area where the arm is located, thereby obtaining a suspected hand connected domain, which can be used as a connected domain in the image to be detected.
  • the image detecting method provided by the embodiment of the present disclosure includes three aspects of skin color detection, arm deletion processing, and effective finger area detection. process.
  • the skin color detection may be performed to acquire an image including a skin color connected domain (one example of the second image described above);
  • the arm deletion process is configured to perform a segmentation process on the skin color connected domain to acquire an image including the suspected hand connected domain (the above-described image to be detected) An example);
  • effective finger area detection also referred to as effective fingertip detection
  • the above three processes may be sequentially performed in order to obtain a valid finger area, fingertip information may be acquired according to the effective finger area, or hand segmentation may be performed and then the result of hand segmentation may be input.
  • the classifier identifies it.
  • the classifier is, for example, a trained neural network, such as a convolutional neural network, etc., for which reference may be made to known classifiers, and details are not described herein.
  • the skin color detecting process includes steps S51 to S54.
  • Step S51 class-like skin color extraction, that is, extracting a skin-like region (referred to as a skin color-like domain) from the input image according to the skin color.
  • the RGB color space can be converted to the YCrCb color space first, because the YCrCb color space is less affected by the brightness, and the skin color will produce a good aggregation; afterwards, for example, for the yellow and white people It can be said that the region where the Cr value is between 133 and 173 and the Cb value is between 77 and 127 can be intercepted as the skin color domain.
  • the RGB color space may also be directly processed, or the RGB color space may be converted to other available color spaces for processing.
  • Step S52 Acquire a pixel number of a pixel point of each gray value in the skin-like color domain by using a histogram, and then perform normalization processing to obtain an appearance probability of the pixel point of each gray value.
  • Step S53 Using the probability obtained in step S52, the maximum inter-class difference method (OTSU method) is used to obtain an optimal threshold for segmenting the skin color domain.
  • OTSU method maximum inter-class difference method
  • the inter-class variance of the foreground (Class A) and background (Class B) of the grayscale image is calculated, and the inter-class variance obtained at the optimal threshold is the largest, that is, the threshold value when the inter-class variance is maximum The optimal threshold for the grayscale image.
  • Step S54 Perform segmentation processing on the skin color-like domain according to the optimal threshold to obtain a skin color connected domain.
  • the next one or more connected domains may remain in the image.
  • the connected domains that are reserved may be faces, human hands, or objects that are similar in color but not related.
  • each of the reserved connected domains can be processed using the arm deletion process to obtain a suspected hand connected domain.
  • the arm deletion processing includes the following steps S61 to S63.
  • Step S61 After acquiring the skin color connected domain, the principal component analysis method is used to obtain the main direction of the skin color connected domain.
  • the main direction is as shown by the white line in FIG. 7(A).
  • Step S62 Rotating the original coordinate system of the image of the skin color communication domain with the main direction as a reference until the Y axis is parallel to the main direction, and the rotated new coordinate system XOY is as shown in FIG. 7(B).
  • step S62 the coordinates of all the points in the image before the rotation coordinate system are given a new coordinate value in the new coordinate system.
  • the vertices of the skin color connected domain may be the point where the Y value (ie, the Y coordinate value) is the largest.
  • Step S63 segmenting the skin color connected domain according to a preset rule along the Y axis of the new coordinate system to obtain a suspected hand connected domain, for example, the suspected hand connected domain is as shown in FIG. 7(C) and FIG. 7(D). ) shown.
  • the pixel points corresponding to all Y values in the connected region of the skin color are calculated.
  • the number, where the pixel point is the most, can be regarded as the palm position, the maximum number of pixels (one example of the above reference number) can be taken as the maximum width W of the hand; the maximum number of k of the pixel points (for example, k is 2.5-3.0) times as the length L of the hand, segmented according to the length L in the main direction and from the apex of the connected domain, and the portions below the split position are all regarded as arms and deleted, thereby obtaining a suspected hand connected domain. image.
  • the value of k is such that the suspected hand connected domain may still have a residual portion of the longer arm (as shown in Figure 7(C)), or it may just include all of the hand and does not include the arm ( Figure 7 ( D) shown).
  • the value of k in the arm removal process may be too large but not too small, because if k is too small, there may be a phenomenon that the hand is cut off a part of the overcut.
  • the width of the skin color connected field is greatest at the position of the palm; in other embodiments, if the color of the clothes is close to the skin color, the arm width may be larger than the palm width. In this case, in this case, since the value of k is 2.5-3.0, the value can still achieve k times the maximum width (for example, the maximum number of pixel points) of the connected region of the skin color as the length L of the hand.
  • effective finger area detection is performed. If at least one valid finger area is detected, the effective finger area can be utilized for subsequent processing; if the valid finger area is not detected, the next skin color connected field is subjected to arm deletion processing and effective finger area detection.
  • the effective finger area detection can be as shown in FIG. 8, which includes steps S81 to S83.
  • Step S81 Calculate the center of gravity of the suspected hand connected domain obtained in step S63 or the geometric center of the circumscribed figure (for example, a rectangle or an ellipse) of the connected domain.
  • Step S82 calculating the geodesic distance from all points on the connected domain to the first starting point by using the center of gravity point or the geometric center obtained in step S81 as the first starting point, and selecting the point with the largest geodesic distance as the first extreme point, that is, The first suspected fingertips; each time a far point is found, the extreme point is taken as the starting point, and the next far point is continued until n extreme points are obtained (for example, n>5, for example, 5 ⁇ n ⁇ 10 ), and these extreme points as suspect fingertips.
  • n extreme points for example, n>5, for example, 5 ⁇ n ⁇ 10
  • the first extreme point can be obtained by the following steps S821 to S823.
  • Step S821 Initialize the distance matrix.
  • the initialization constructs a distance matrix of the same size as the image obtained in step S63, and the elements in the distance matrix correspond one-to-one with the pixels in the image.
  • the starting point (the first starting point is the center of gravity or the geometric center of the suspected hand connected domain obtained in step S81) is set to a distance of 0 in the corresponding point in the distance matrix; the other points in the suspected hand connected domain are The distance values of the corresponding points in the distance matrix are set to a certain maximum value (for example, 100,000 or other values); the distance from the background point in the image (ie, the point outside the suspected hand connected domain) at the corresponding point in the distance matrix The values are set to -1, indicating that the distance values for these points do not need to be calculated.
  • Step S822 Update the distance matrix.
  • FIFO abbreviation of First Input First Output
  • the 8 neighborhood is The distance value of the point is updated and the updated neighborhood point is added to the FIFO queue. After that, the updated neighborhood point is taken out from the FIFO queue, and the new distance value of its 8 neighborhood is calculated with it as the origin.
  • the new distance value of each neighborhood point is the distance value of the origin plus the two-dimensional distance from the origin to the neighborhood point.
  • the new distance value of the 4 neighborhood points of the origin is the origin.
  • the distance value plus one, the new distance value of the diagonal neighborhood point of the origin is the distance value of the origin plus the positive square root of 2 (1.414). Since the same point may be a neighborhood of a plurality of origins, in this case, the smallest distance value among the distance values calculated from the plurality of origins is selected as the new distance value of the point.
  • Step S823 Select a very far point.
  • the distance value greater than 0 in the updated distance matrix is the geodesic distance from each point in the suspected hand connected domain to the starting point, and the point with the largest distance value in the distance matrix is found as the extreme point.
  • Steps S821 to S823 are repeatedly executed until n extreme points are detected. These extreme points are the suspected fingertips, that is, the candidate points of the fingertips.
  • the first extreme point (as indicated by a white dot) is located at the middle fingertip; as shown in (B) of FIG. 9, the second extreme point is located at the ring finger.
  • Tip As shown in (C) of Figure 9, the third pole is located at the tip of the index finger; as shown in (D) of Figure 9, the fourth pole is located at the tip of the little finger; as shown in Figure 9 ( As shown in E), the 5th pole is located at the tip of the thumb.
  • Step S83 Perform effective fingertip judgment on all the fingertips of the suspected finger to obtain an effective finger area.
  • the pixel growth method is used to check whether the region where the extreme point is located is a valid finger region.
  • the growth of the suspected finger region is performed with the far point as the starting point, and each pixel grows only once to the adjacent pixel in each growth (that is, each growing point is the neighbor of the previously grown pixel point).
  • the domain point), the white mark in the figure is the position of the new pixel that is grown multiple times.
  • the area is considered to be the finger area.
  • the last growth position is the critical position, and the distance from the critical position to the initial growth point is suspected.
  • the length of the finger area which satisfies a predetermined proportional relationship with the width, area, and the like of the palm (for example, the selection condition of the effective finger area described above), can be determined as a valid finger area.
  • the so-called preset proportional relationship includes the following three relationships.
  • the length of the suspected finger area is not less than one third of the maximum width W of the suspected hand connected field calculated in step S63 and not more than 1.5 times the maximum width W of the suspected hand connected field.
  • the length of the suspected finger area is the number of pixels in the direction from the initial point of the area to the end of the area, which is known during the growth of the area.
  • the width of the suspected finger area is not more than one-fifth of the maximum width W of the suspected hand connected field.
  • the width of the suspected finger area is the number of pixels in the finger width direction at the end of the growth, which is known during the area growth.
  • the area of the suspected finger area (such as the total number of pixels, which is available during the growth of the area) is not larger than the area of the entire suspected connected area (for example, the total number of pixels, which is available in the process of calculating the geodesic distance) One-fifth.
  • the suspect finger regions are judged one by one, and all valid finger regions can be selected more accurately.
  • the suspected hand connected field is an effective hand connected field, and then the effective hand connected field can be directly sent to the classifier or sent to the classifier after being further divided.
  • Gesture recognition for the non-hand objects mentioned above, such as faces or other disturbing objects, because the shape, size, etc. do not match the proportional relationship between the fingers and the hand, the effective finger area cannot be detected, so it can be judged that it is not effective.
  • Hand connected domain for the non-hand objects mentioned above, such as faces or other disturbing objects, because the shape, size, etc. do not match the proportional relationship between the fingers and the hand, the effective finger area cannot be detected, so it can be judged that it is not effective.
  • the length of the longest effective finger region is selected, according to the length of 1.5-1.7 times and according to the main direction information determined in the previous step, along the Y axis parallel to the main direction, Suspected hand connected domains are segmented.
  • (A) in Fig. 11 is a connected domain before division
  • (B) in Fig. 11 is a connected domain after division.
  • a hand image with good effect can be obtained by the method provided by the embodiment of the present disclosure; and, since the skin color detection is employed in the embodiment of the present disclosure, the obtained hand is obtained.
  • the hand in the image may also include a hand print.
  • the target image may be Perform a skin tone extraction (see the skin color detection process for the method). Since this extraction is performed in a small range of a picture, the range contains less information and most of the pixels are hand information, so the method of enhancing contrast (such as histogram equalization) can be used to improve hand segmentation. Effect. After the second skin color segmentation, the hand segmentation result with good effect can be obtained, and then the result is sent to the classifier for gesture recognition.
  • a skin tone extraction see the skin color detection process for the method. Since this extraction is performed in a small range of a picture, the range contains less information and most of the pixels are hand information, so the method of enhancing contrast (such as histogram equalization) can be used to improve hand segmentation. Effect.
  • the hand segmentation result with good effect can be obtained, and then the result is sent to the classifier for gesture recognition.
  • At least one embodiment of the present disclosure also provides an image detecting system including a point determining device, an area determining device connected to the point determining device, and a determining device connected to the region determining device, as shown in FIG.
  • the point determining means is configured to: determine a first starting point and n far points different from the first starting point, wherein the first starting point is a center of gravity of the connected domain in the image to be detected and a geometric center of the circumscribed figure of the connected domain
  • the N+1th starting point is the Nth pole far point
  • the Nth pole far point is the pixel point having the largest geodesic distance from the connected domain to the Nth starting point
  • both n and N are positive integers.
  • the area determining device is configured to: perform area growing with n extreme points as initial points, respectively, to acquire n areas in the connected domain.
  • the determining device is configured to: determine whether a relationship between the preset feature of each of the n regions and the preset feature of the connected domain satisfies the selection condition to determine an effective region that satisfies the selection condition.
  • the image detecting system further includes extracting means for: acquiring coordinates of a far point included in the effective area; or determining a direction of data change of the connected domain by using a principal component analysis method, and along the direction of the data change and according to the reference length ( That is, the first reference length is divided into the connected domain to obtain the target image, and the reference length is the product of the size of the effective area and the preset multiple (ie, the first preset multiple).
  • the image detection system may further include a camera configured to acquire an image and input the acquired image into the point determining device.
  • the camera can be an ordinary camera, and the captured image is a two-dimensional image, excluding depth information.
  • the specific structures of the point determining means, the area determining means, the determining means and the extracting means in the image detecting system may be implemented by hardware, software or firmware, for example, corresponding to the processor and executable instructions executable by the processor, for example
  • the processor can be a Central Processing Unit (CPU), a Micro Controller Unit (MCU), a Digital Signal Processing (DSP), or a Programmable Logic Controller (PLC).
  • CPU Central Processing Unit
  • MCU Micro Controller Unit
  • DSP Digital Signal Processing
  • PLC Programmable Logic Controller
  • the foregoing devices in the embodiments of the present disclosure may all be implemented in one processor, or respectively implemented by different processors, or any two or more devices may be implemented in one processor; It can be implemented in the form of hardware, and can also be implemented in the form of hardware plus software functional units.
  • At least one embodiment of the present disclosure also provides another image detection system, as shown in FIG. 14, the image detection system includes a processor, a memory, and computer program instructions stored in the memory, wherein the computer program instructions are Executing while the processor is running: determining a first starting point, wherein the first starting point is one of a center of gravity of the connected domain in the image to be detected and a geometric center of the circumscribed graph of the connected domain; determining n different from the first starting point Extremely far, wherein the Nth far point is the pixel point with the largest geodesic distance from the connected domain to the Nth starting point, the N+1th starting point is the Nth far point, and n and N are both positive integers; Performing region growth with n extreme points as initial points to acquire n regions in the connected domain; and judging whether the relationship between the preset features of each of the n regions and the preset features of the connected domains is satisfied A condition is selected to determine the effective area that satisfies the selection criteria.
  • the memory can include at least one of a read only memory and a random access memory and provides instructions and data to the processor.
  • a portion of the memory may also include non-volatile random access memory (NVRAM) including magnetic memory, semiconductor memory, optical memory, and the like.
  • NVRAM non-volatile random access memory
  • the processor can be a general purpose processor (eg, a central processing unit, etc.), a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic device, transistor logic device, discrete Hardware components.
  • a general purpose processor can be a microprocessor or any conventional processor or the like.
  • At least one embodiment of the present disclosure also provides a storage medium having stored therein computer program instructions adapted to be loaded and executed by a processor to determine a first starting point, wherein the first starting point is a communication in an image to be detected The center of gravity of the domain and one of the geometric centers of the circumscribed graph of the connected domain; determining n extreme points different from the first starting point, wherein the Nth far point is the geodesic distance from the connected domain to the Nth starting point The largest pixel point, the N+1th starting point is the Nth pole far point, and n and N are both positive integers; the region growth is performed with n extreme points as initial points, respectively, to obtain n regions in the connected domain; And determining whether a relationship between the preset feature of each of the n regions and the preset feature of the connected domain satisfies the selection condition to determine an effective region that satisfies the selection condition.
  • the storage medium can be a semiconductor memory, a magnetic surface memory, a laser memory, a random access memory, a read only memory, a serial access memory, a non-permanent memory, a permanent memory, or any other form of storage well known in the art. medium.
  • the processor can be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic device, transistor logic device, discrete hardware component.
  • DSP digital signal processor
  • ASIC application specific integrated circuit
  • FPGA field programmable gate array
  • a general purpose processor can be a microprocessor or any conventional processor or the like.
  • At least one embodiment of the present disclosure also provides an apparatus comprising the image detection system or storage medium provided by any of the above embodiments.
  • the device may be a human-computer interaction device such as an AR smart glasses or a display, and the device acquires an image by using an ordinary camera, and performs human-computer interaction by analyzing and processing the image.
  • a human-computer interaction device such as an AR smart glasses or a display
  • the device acquires an image by using an ordinary camera, and performs human-computer interaction by analyzing and processing the image.
  • At least one embodiment of the present disclosure further provides a hand detection method, as shown in FIG. 15, the hand detection method includes: determining a position of a palm in a connected domain in an image to be detected; taking a position of a palm as a first starting point, Determining n extreme points different from the position of the palm, wherein the Nth far point is the pixel point having the largest geodesic distance from the connected domain to the Nth starting point, and the N+1th starting point is the Nth far point, and n And N are both positive integers; respectively, region growth is performed with n extreme points as initial points to acquire n regions in the connected domain; and pre-preset features and connected domains are determined for each of the n regions. Let the relationship between the features satisfy the selection condition to determine the effective finger area that satisfies the selection condition.
  • the palm center position may be the center of gravity of the connected domain of the image to be detected or the geometric center of the circumscribed pattern (eg, rectangular or elliptical).
  • the position of the palm of the hand may also be determined by other means.
  • At least one embodiment of the present disclosure also provides a hand segmentation method. As shown in FIG. 16, the hand segmentation method includes steps S161 to S163.
  • Step S161 Acquire a skin color connected domain by skin color detection.
  • the skin color detection can refer to the above steps S51-S54.
  • Step S162 Acquire a maximum width of the skin color connected domain and a main direction based on the principal component analysis method, and divide the skin color connected domain according to the main direction and according to a preset multiple of the maximum width to obtain the suspected hand connected domain.
  • the step S162 may include the above steps S61-S63, so that interference such as an arm can be deleted.
  • the maximum width of the connected region of the skin color is represented, for example, by the number of pixels at the widest point of the connected region of the skin color; the preset multiple is, for example, k times as described above, that is, 2.5-3.0; based on the principal component analysis method
  • the main direction is the main direction of the connected region of the skin color obtained by the principal component analysis method.
  • Step S163 It is judged according to the hand detection method described above whether or not the suspected hand connected domain (an example of the connected domain in the image to be detected in the hand detecting method) includes the valid finger region.
  • the suspected hand connected domain includes at least one valid finger region, it can be determined that the suspected hand connected domain is an effective hand connected domain.
  • the effective hand connected domain may also be segmented along the main direction and according to the product of the length of the effective finger region (eg, the length of the longest active finger region) and a preset multiple (eg, 1.5-1.7) to further Exclude interference from the arm.
  • Embodiments of the hand detection method, the hand division method, the image detection method, the image detection system, and the apparatus including the same may be referred to each other. Further, the embodiments of the present disclosure and the features of the embodiments may be combined with each other without conflict.
  • the suspected region is obtained by using the region growing manner, and the interference of the region of the image to be detected that is connected to the connected domain of the target object but actually corresponds to the interference object can be avoided; the suspected region is performed according to the preset selection condition. Detecting the effective area can further reduce the interference factor of the image detection; since the selection condition is determined according to the size feature of the suspected area and the size characteristic of the connected domain, the depth information is not needed, and thus the embodiment of the present disclosure can be used to obtain the common camera.
  • the image is processed; the skin color connected domain is acquired by the skin color detection, so that the embodiment of the present disclosure can further remove a part of the interference; the interference factor can be further removed by the arm deletion process. Therefore, the image detection technology provided by the embodiment of the present disclosure can be used to process an image acquired by an ordinary camera, which can effectively reduce interference factors, improve the accuracy of the image detection result, and realize fast real-time calculation.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Multimedia (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Psychiatry (AREA)
  • Social Psychology (AREA)
  • Image Analysis (AREA)

Abstract

一种手部检测方法、手分割方法、图像检测方法和系统、存储介质以及设备。该图像检测方法包括:确定第1起点,其为待检测图像中的连通域的重心点以及连通域的外切图形的几何中心中的一个;确定不同于第1起点的n个极远点,其中,第N极远点为连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,并且n、N都为正整数;分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域;判断n个区域中的每个区域的预设特征与连通域的预设特征之间的关系是否满足选取条件,以确定满足选取条件的有效区域。该方法可以提高图像检测结果。

Description

手和图像检测方法和系统、手分割方法、存储介质和设备
对相关申请的交叉参考
本申请要求于2017年8月31日递交的中国专利申请第201710771527.8号的优先权,在此全文引用上述中国专利申请公开的内容以作为本申请的一部分。
技术领域
本公开的实施例涉及一种手部检测方法、手分割方法、图像检测方法、图像检测系统、存储介质、以及包括所述图像检测系统或存储介质的设备。
背景技术
随着人机交互技术的发展,基于计算机视觉的手势识别技术因具有使人能够以自然的方式进行人机交互的优点而成为人机交互技术中的研究热点之一。
手部检测是手势识别技术的基础,手部检测是指在动态影像文件或静态图片中标出手部。在手部检测中,可以提取手指指尖信息或者进行手分割。
发明内容
本公开的实施例提供一种手部检测方法、手分割方法、图像检测方法、图像检测系统、存储介质、以及包括所述图像检测系统或存储介质的设备。
本公开的至少一个实施例提供一种图像检测方法,其包括:在待检测图像中的连通域中确定第1起点;在所述待检测图像的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
例如,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
例如,所述的方法还包括:获取所述有效区域包括的极远点的坐标。
例如,所述的方法还包括:采用主成分分析方法确定所述连通域的数据变化方向,并且沿着所述数据变化方向并且根据第一参考长度对所述连通域进行分割以获取目标图像,所述第一参考长度为所述有效区域的尺寸与第一预设倍数的乘积。
例如,所述连通域的数据变化方向为所述连通域的主方向。
例如,所述方法用于手部检测。
例如,所述第一预设倍数为1.5-1.7。
例如,在所述n个区域包括多个有效区域的情况下,所述第一参考长度为具有最大长度的有效区域的尺寸与所述第一预设倍数的乘积。
例如,所述有效区域的选取条件包括A、B或C中的至少一个或多个,其中,A:所述每个区域的长度与所述连通域的最大宽度的第一比值不小于1/3且不大于1.5;B:所述每个区域的宽度与所述连通域的最大宽度的第二比值不大于1/5;C:所述每个区域的面积与所述连通域的面积的第三比值不大于1/5。
例如,在获取所述第1起点之前,所述方法还包括:根据颜色范围从第一图像中获取包括初始连通域的第二图像;并且对所述第二图像的初始连通域进行处理以获取所述待检测图像中的连通域。
例如,所述方法用于手部检测,并且对初始连通域进行处理以获取所述连通域包括:采用主成分分析方法确定所述初始连通域的数据变化方向;使所述第二图像的坐标系的预设坐标轴与所述初始连通域的数据变化方向平行;对于所述预设坐标轴的多个位置中的每个位置,计算所述初始连通域中对应所述每个位置的像素点的数量,选取像素点的最大数量作为参考数量,并且将所述参考数量与第二预设倍数的乘积作为第二参考长度;以及沿所述初始连通域的数据变化方向并且根据所述第二参考长度对所述初始连通域进行分割,以获取所述待检测图像中的连通域。
例如,所述第二预设倍数大于或等于2.5且小于或等于3。
例如,对于所述n个区域中的每个区域,所述区域的生长终点的确定方法包括:在所述区域的第i次生长之后,如果所述区域的第i+1次生长中像素点数量的增加值超过预设值,那么所述第i次生长为所述区域的最后一次生长。
例如,对于所述n个区域中的每个区域,根据预设长度确定所述区域的生长终点。
例如,所述待检测图像不包括像素点的深度信息。
本公开的至少一个实施例还提供一种图像检测系统,其包括处理器、存储器以及存储在存储器中的计算机程序指令,其中,在所述计算机程序指令被处理器运行时执行:在所述待检测图像的连通域中确定第1起点;在所述待检测图像的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
例如,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
本公开的至少一个实施例还提供一种图像检测系统,其包括:点确定装置,其被配置为:在所述待检测图像的连通域中确定第1起点以及不同于所述第1起点的n个极远点,第N+1起点为第N极远点,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,n、N都为正整数,并且N≤n;区域确定装置,其被配置为:分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及判断装置,其被配置为:判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
例如,所述的图像检测系统还包括提取装置,其被配置为:获取所述有 效区域包括的极远点的坐标;或者采用主成分分析方法确定所述连通域的数据变化方向,并且沿着所述数据变化方向并且根据参考长度对所述连通域进行分割以获取目标图像,所述参考长度为所述有效区域的尺寸与预设倍数的乘积。
本公开的至少一个实施例还提供一种存储介质,其中存储有计算机程序指令,所述计算机程序指令适于由处理器加载并执行:在所述待检测图像的连通域中确定第1起点;在所述待检测图像的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
本公开的至少一个实施例还提供一种设备,其包括以上任一项所述的图像检测系统或以上所述的存储介质。
本公开的至少一个实施例还提供一种手部检测方法,其包括:在待检测图像中的连通域中确定手心位置;以所述手心位置为第1起点,确定不同于所述手心位置的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效手指区域。
本公开的至少一个实施例还提供一种手分割方法,其包括:通过肤色检测获取肤色连通域;获取所述肤色连通域的最大宽度和基于主成分分析方法的主方向,沿所述主方向并且根据所述最大宽度的预设倍数分割所述肤色连通域,以获取疑似手部连通域;以及以上所述的手部检测方法判断所述疑似手部连通域是否包括所述有效手指区域。
附图说明
为了更清楚地说明本公开实施例的技术方案,下面将对实施例的附图作简单地介绍,显而易见地,下面描述中的附图仅仅涉及本公开的一些实施例,而非对本公开的限制。
图1为本公开实施例提供的图像检测方法的流程图;
图2为本公开实施例提供的图像检测方法中利用第一图像获取待检测图像的流程图;
图3为本公开实施例提供的图像检测方法中对初始连通域进行分割的流程图;
图4为本公开实施例提供的图像检测方法用于手部检测时的流程图;
图5为本公开实施例提供的图像检测方法中的肤色检测的流程图;
图6为本公开实施例提供的图像检测方法中的手臂删除处理的流程图;
图7(A)-图7(D)为本公开实施例提供的图像检测方法中进行手臂删除处理的各步骤中得到的处理效果图;
图8为本公开实施例提供的图像检测方法中的有效手指区域判断的流程图;
图9中的(A)-(E)为本公开实施例提供的图像检测方法中检测到的各极远点的示意图;
图10为本公开实施例提供的图像检测方法中进行区域生长的示意图;
图11中的(A)和(B)为本公开实施例提供的图像检测方法中根据有效手指区域分割连通域的前后对比图;
图12中的(A)和(B)为采用本公开实施例提供的图像检测方法获得的手部图像;
图13为本公开实施例提供的一种图像检测系统的结构框图;
图14为本公开实施例提供的另一种图像检测系统的结构框图;
图15为本公开实施例提供的手部检测方法的流程图;
图16为本公开实施例提供的手分割方法的流程图。
具体实施方式
为使本公开实施例的目的、技术方案和优点更加清楚,下面将结合本公 开实施例的附图,对本公开实施例的技术方案进行清楚、完整地描述。显然,所描述的实施例是本公开的一部分实施例,而不是全部的实施例。基于所描述的本公开的实施例,本领域普通技术人员在无需创造性劳动的前提下所获得的所有其他实施例,都属于本公开保护的范围。
除非另外定义,本公开使用的技术术语或者科学术语应当为本公开所属领域内具有一般技能的人士所理解的通常意义。本公开中使用的“第一”、“第二”以及类似的词语并不表示任何顺序、数量或者重要性,而只是用来区分不同的组成部分。“包括”或者“包含”等类似的词语意指出现该词前面的元件或者物件涵盖出现在该词后面列举的元件或者物件及其等同,而不排除其他元件或者物件。“连接”或者“相连”等类似的词语并非限定于物理的或者机械的连接,而是可以包括电性的连接,不管是直接的还是间接的。“上”、“下”、“左”、“右”等仅用于表示相对位置关系,当被描述对象的绝对位置改变后,则该相对位置关系也可能相应地改变。
本公开实施例提供一种图像检测方法、图像检测系统、存储介质、包括所述图像检测系统或存储介质的设备、手部检测方法以及手分割方法。
本公开实施例的总体构思为:针对待检测图像中的连通域(也可写为联通域),确定出第1起点并且根据该第1起点确定出至少一个极远点,例如n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点(其中,根据第N起点得到第N极远点,并且将得到的第N极远点作为第N+1起点;以此类推),n、N都为正整数,并且N≤n;以该至少一个极远点为初始点进行区域生长,以得到至少一个区域(下文称为疑似区域);检测该至少一个区域是否满足选取条件;若是得到满足选取条件的有效区域,则可以利用该有效区域提取需要的信息或进行后续分析。
在本公开实施例中,将极远点作为初始点进行区域生长得到的疑似区域可能是目标物体的一部分所在的区域,采用区域生长的方式得到疑似区域,可以避免待检测图像中与目标物体的连通域连通但实际上对应干扰物的区域的干扰;根据预设的选取条件对疑似区域进行检测以确定有效区域,可以进一步排除待检测图像中的干扰区域;由于有效区域满足选取条件,则可以认为该有效区域是目标物体的一部分所在的区域,通过设置选取条件,可以进 一步减少图像检测的干扰因素,以提高图像检测结果的准确性。本公开实施例提供的图像检测技术可以有效减少干扰因素,因此可以实现快速实时计算。
例如,本公开实施例可以用于图像识别的手部检测中,即用于从图像中检测出手部。例如,本公开实施例用于手部检测中的指尖检测或者手分割(即从图像中提取手部图像)。在这种情况下,待检测图像中的连通域对应的实际物体可能包括手,下文称为疑似手部连通域;第1起点可能是手心(也称为掌心)位置;极远点可能是手指的指尖所在位置,下文称为疑似手指指尖;以极远点为初始点进行区域生长得到的区域可能是手指所在区域(下文称为疑似手指区域);满足选取条件的有效区域被视为手指所在区域,下文称为有效手指区域;选取条件根据手的形态特征确定,该形态特征例如为手指的尺寸(例如长、宽或面积))与手掌的尺寸之间的关系。
鉴于有效区域被视为手指所在区域,在本公开实施例用于指尖检测的情况下,可以将有效区域包括的极远点作为指尖,通过获取该极远点的坐标获取指尖的坐标。
根据经验可知,手的长度约为手指长度的1.5倍左右。因此,在本公开实施例用于图像识别的手分割的情况下,可以利用手的长度与手指长度之间的这一关系,根据有效区域的尺寸对连通域进行分割,以去掉连通域中除手之外的物体所在区域,从而获取目标图像(即,手部图像)。
下面结合附图,对本公开实施例提供的手部检测方法、图像检测方法、手分割方法、图像检测系统、存储介质、以及包括所述图像检测系统或存储介质的设备进行详细说明。
本公开的至少一个实施例提供一种图像检测方法,如图1所示,该图像检测方法包括以下步骤S11-步骤S14。
步骤S11:在待检测图像中的连通域中确定第1起点。
例如,根据连通域的重心点或者几何中心来确定第1起点。例如,第1起点对应的物点到待检测图像中的连通域的重心点以及连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。例如,所述第1起点为待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个,或者第1起点为该重心点的邻域点,或者第1起点为该几何中心的邻域点。
以本申请用于手部检测为例,待检测图像的连通域中的第1起点用于表示手心位置,通过根据连通域的重心点或者几何中心来确定第1起点,可以避免第1起点为距离对应指尖的像素点过近的点。
连通域是由具有连通性的多个像素点构成的。对于区域内部任一像素点,其左、上、右、下这4个像素点称为四邻域点,其左、上、右、下以及左上、右上、右下、左下这8个像素点称为八邻域点,该像素点与其任一邻域点之间是连通的。
这里,连通域的重心点的坐标为连通域中所有像素点的坐标的平均值,也就是说,重心点的X坐标为连通域中所有像素点的X坐标的算术平均值,重心点的Y坐标为连通域中所有像素点的Y坐标的算术平均值。由于重心点不受连通域的轮廓形状影响,因此以重心点为第1起点可以避免连通域对应的物体的形状对检测结果造成影响。
例如,连通域的外切图形可以为外切矩形或椭圆形,例如,根据外切图形的几何形状可以确定其几何中心。
步骤S12:确定不同于所述第1起点的n个极远点,第N极远点为所述连通域中到第N起点的测地距离(Geodesic Distance)最大的像素点,第N+1起点为第N极远点,并且n、N都为正整数。
例如,n可以为1,或者n可以大于或等于2。
例如,在n大于或等于2的情况下,n个极远点是按照先后顺序确定的。例如,在n大于或等于2的情况下,步骤S12可以包括:计算连通域中的像素点到第1起点的测地距离,并且选取测地距离最大的像素点作为第1极远点;将第1极远点作为第2起点,计算连通域中的像素点到第2起点的测地距离,并且选取测地距离最大的像素点作为第2极远点;以此类推。
测地距离是数学形态学中的一个重要概念,用来测量两点之间的距离。和欧氏距离不同的是,测地距离考虑到了区域的连通性。在连通域中存在至少一条线路可以连接A、B两点,该至少一条线路中最短的一条称为A、B之间的测地弧,而测地弧的长度则为测地距离。测地距离利用的是图形的梯度,沿梯度最大方向将两点连接则得到测地弧。
步骤S13:分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域。
例如,可以利用目标物体的形态(例如轮廓形状、尺寸)特征确定每个区域的生长终点。由于手的宽度在手指的指根处发生明显变化,因此,在连通域对应的物体包括手的情况下,可以利用手的这一形态特征确定区域生长的终点。例如,对于所述n个区域中的每个区域,区域的生长终点的确定方法包括:在该区域的某次生长之后,例如第i次生长之后(i大于等于1),如果该区域在第i+1次生长中像素点数量的增加值超过预设值(其可以根据实际需要进行设置),那么该第i次次生长为该区域的最后一次生长,并且所述第i次生长的像素点所处的位置为所述区域的终点位置。
例如,对于所述n个区域中的每个区域,也可以根据预设长度(其可以根据实际需要进行设置)确定该区域的生长终点。
步骤S14:判断n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足该选取条件的有效区域。
例如,每个区域的预设特征可以为该区域的尺寸特征,例如,该区域的长度、宽度或面积。例如,该区域的面积可以用该区域中像素点的数量表示。
类似地,连通域的预设特征可以为连通域的尺寸特征,例如,连通域的长度、宽度或面积。例如,连通域的面积可以用连通域中像素点的数量表示。
例如,在本公开实施例用于手部检测的情况下,可以利用手指的尺寸特征与手的尺寸特征之间的关系确定有效区域的选取条件。例如,有效区域的选取条件包括(A)、(B)或(C)中的至少一个或多个。
条件(A)、根据手指长度与手掌宽度之比不小于1/3且不大于1.5的特点,每个区域的长度与连通域的最大宽度的第一比值不小于1/3且不大于1.5。
例如,每个区域的长度为在从该区域的初始点(即该区域包括的极远点)到该区域的终点的方向上的像素点的数量。
条件(B)、根据手指宽度与手掌宽度之比不大于1/5的特点,每个区域的宽度与连通域的最大宽度的第二比值不大于1/5。
例如,每个区域的宽度为该区域的生长终点处在该区域的宽度方向上的像素点的数量。
条件(C)、根据手指的面积与手的面积之比不大于1/5的特点,每个区域的面积与连通域的面积的第三比值不大于1/5。
例如,可以用像素点的数量表示面积,则每个区域的像素点的数量与连 通域的像素点的数量的比值不大于1/5。例如,每个区域的像素点的数量在进行区域生长的过程中可以得到。例如,连通域的像素点的数量在通过计算测地距离以寻找极远点的过程中可以得到。
例如,如图1所示,本公开的至少一个实施例提供的图像检测方法还可以包括步骤S15A或者步骤S15B。
步骤S15A:获取有效区域包括的极远点的坐标。例如,在本公开实施例用于手部检测的情况下,该极远点的坐标可以作为指尖坐标。
步骤S15B:采用主成分分析方法确定所述连通域的数据变化方向,并且沿着该数据变化方向并且根据第一参考长度对该连通域进行分割以获取目标图像,第一参考长度为该有效区域的尺寸与第一预设倍数的乘积。
主成分分析(Principle Component Analysis,PCA)方法是一种多元统计分析方法,通过线性变换将数据变换到一个新的坐标系中,使在第一个坐标轴上数据的方差达到最大,在第二个坐标轴上数据的方差次大,以此类推;其中,第一坐标轴的方向为主方向,也就是说,主方向为数据的方差最大的方向,次方向为数据的方差次大的方向。主方向和次方向都被称为数据变化方向。
对于手而言,手的主方向为其长度方向(延伸方向),手的次方向为其宽度方向。因此,在本公开实施例用于手部检测的情况下,例如,连通域的数据变化方向可以为连通域的主方向,第一参考长度可以为有效区域的长度与第一预设倍数的乘积。也就是说,在本公开实施例用于手部检测的情况下,沿连通域的主方向并且根据有效区域的长度与第一预设倍数的乘积对连通域进行分割,以去除连通域的除手之外的物体的区域,从而获取手部连通域。
例如,在所述n个区域包括多个有效区域的情况下,第一参考长度为具有最大长度的有效区域的尺寸与第一预设倍数的乘积。由于大拇指大致沿手的次方向延伸,其余手指大致沿手的主方向延伸,通过根据具有最大长度的有效区域确定第一参考长度,可以提高手分割的准确性。
根据手的长度为手指长度的1.5倍左右这一特点,例如,第一预设倍数可以为设为1.5-1.7。第一预设倍数不小于1.5,有利于避免因连通域被过切割而导致目标图像只包括手的一部分而非全部。
例如,本公开实施例中的待检测图像可以不包括深度信息,深度信息是 指图像中的像素点对应的物点到拍摄该图像的摄像机的距离。在本公开实施例中,由于疑似区域的生长终点可以通过像素点数量是否明显增加来判断,并且有效区域可以根据疑似区域的尺寸特征与连通域的尺寸特征之间的关系进行判断,不需要使用深度信息,因此,本公开实施例可以用于对普通摄像机拍摄的图像进行检测。摄像机包括深度感知摄像机、立体摄像机和普通摄像机,利用深度摄像机和立体摄像机都可以获得具有深度信息的图像,利用普通摄像机可以获得不具有深度信息的图像。在本公开的其它实施例中,待检测图像也可以包括深度信息,在这种情况下,用于判断有效区域的选取条件可以根据深度信息进行设置,或者也可以不涉及深度信息。
由于普通摄像机拍摄的图像不包括深度信息,在这种情况下,为了获取待检测图像中的连通域,可以根据颜色范围对普通摄像机拍摄的图像进行处理。例如,如图2所示,本公开的至少一个实施例提供的图像检测方法还包括步骤S21和步骤S22。
步骤S21:根据颜色范围从第一图像中获取包括初始连通域的第二图像。
例如,第一图像可以为彩色图像。例如,第一图像可以为利用普通摄像机拍摄的彩色图像,在这种情况下,该第一图像不具有深度信息。
例如,在本公开实施例用于手部检测的情况下,颜色范围可以根据肤色确定,也就是说,可以根据肤色从第一图像中获取包括初始连通域的第二图像,这在下文被称为肤色检测,通过肤色检测获取的初始连通域在下文被称为肤色连通域。
步骤S22:对第二图像的初始连通域进行处理以获取待检测图像中的连通域。
通过对初始连通域进行处理可以去除一部分干扰,从而得到干扰较少的待检测图像中的连通域。
例如,在本公开实施例用于手部检测的情况下,通过以上步骤S21获取的初始连通域对应的物体可能包括手以及手臂;在该步骤S22中,对初始连通域进行的处理例如是图像分割处理,以将连通域中的手臂删除,这在下文被称为手臂删除处理。
例如,以本公开实施例用于手部检测为例,如图3所示,上述步骤S22可以包括步骤S31至步骤S34。
步骤S31:采用主成分分析方法确定初始连通域的数据变化方向。
例如,对于手而言,初始连通域的数据变化方向可以为其主方向。
步骤S32:使第二图像的坐标系的预设坐标轴与初始连通域的数据变化方向平行。
例如,预设坐标轴为Y轴。例如,第二图像的坐标系的Y轴与初始连通域的主方向平行,并且X轴与初始连通域的次方向平行。
步骤S33:对于预设坐标轴的多个位置中的每个位置,计算初始连通域中对应每个位置的像素点的数量。
例如,在预设坐标轴为Y轴的情况下,该预设坐标轴上的相邻位置之间的距离为Y轴的单位长度。
例如,从连通域的顶点(其Y坐标例如为K0)开始,计算位置Y=K0-1的像素点的数量A1、位置Y=K0-2的像素点的数量A2、位置Y=K0-3的像素点的数量A3,以此类推,直到计算出连通域中所有Y值对应的像素点的数量。
步骤S34:选取像素点的最大数量作为参考数量,将参考数量与第二预设倍数的乘积作为第二参考长度,沿初始连通域的数据变化方向并且根据第二参考长度对初始连通域进行分割,以获取待检测图像中的连通域。
像素点的最大数量可以看作是手掌宽度对应的像素点的数量,也就是说,参考数量反映手掌宽度。
由于手的长度约为手掌宽度的k(k为2.5-3.0)倍,因此可以根据反映手掌宽度的参考数量的k倍估算手的长度。鉴于此,上述第二预设倍数例如为2.5-3.0,第二参考长度用于表示手的长度,沿初始连通域的主方向并且根据第二参考长度对初始连通域进行分割,可以去除连通域中的手臂所在区域,从而得到疑似手部连通域,该疑似手部连通域可以作为上述待检测图像中的连通域。
综上所述,如图4所示,在本公开实施例用于手部检测的情况下,本公开实施例提供的图像检测方法依次包括肤色检测、手臂删除处理和有效手指区域检测这三个过程。通过肤色检测可以以获取包括肤色连通域的图像(上述第二图像的一个示例);手臂删除处理用于对肤色连通域进行分割处理以获取包括疑似手部连通域的图像(上述待检测图像的一个示例);有效手指 区域检测(也可以称为有效指尖检测),即在疑似手部连通域中检测是否有满足手指选取条件的有效手指区域。对于每一帧摄像机输入的图像,可以是以上三个过程按顺序依次执行,以获得有效手指区域,根据该有效手指区域可以获取指尖信息,或者进行手分割并且之后可以将手分割的结果输入分类器进行识别。
该分类器例如是经过训练后的神经网络,该神经网络例如为卷积神经网络等,对此可以参考已知分类器,在此不再赘述。
下面以本公开实施例用于手分割为例,对图像检测方法的一个示例进行详细说明。
例如,如图5所示,肤色检测过程包括步骤S51至步骤S54。
步骤S51:类肤色域提取,即:根据肤色从输入图像中提取类似于肤色的区域(简称为类肤色域)。
对于输入图像,例如,可以先将RGB颜色空间转换到YCrCb颜色空间,这是因为YCrCb颜色空间受亮度影响小,肤色会产生很好的类聚;之后,例如,对于黄种人和白种人来说,可以截取Cr值在133~173以及Cb值在77~127之间的区域作为类肤色域。在本公开的其他示例中,也可以直接采用RGB颜色空间进行处理,或者将RGB颜色空间转换到其他可用的颜色空间进行处理。
步骤S52:利用直方图获取类肤色域中每个灰度值的像素点的像素数,之后进行归一化处理以得到每个灰度值的像素点的出现概率。
例如,从经过步骤S51处理的图像中提取Cr图,以获得一个灰度范围在0-40的新单通道图像;将该新单通道图像转换为灰度图,进行直方图计算并归一化处理,得到灰度范围0-40之间每个灰度值的像素点在灰度图中出现的概率,该概率可以这样表示:假设在灰度图中共有m个同一灰度值的像素点,并且灰度图中像素点总数为M个,则这个该灰度值的像素的出现概率为Pi=m/M。
步骤S53:利用步骤S52中得到的概率,采用最大类间差法(OTSU方法)获取用于分割类肤色域的最佳阈值。
在该步骤中,计算灰度图的前景(A类)和背景(B类)的类间方差,在最佳阈值处得到的类间方差最大,也就是说,类间方差最大时的阈值为灰 度图的最佳阈值。
步骤S54:根据最佳阈值,对上述类肤色域进行分割处理,以获取肤色连通域。
经过肤色检测后,图像中可能保留下一个或多个连通域。保留下的连通域可能是人脸、人手或者是颜色相近但不相关的物体。接下来,可以利用手臂删除处理对每个保留下的连通域进行处理以得到疑似手部连通域。
例如,如图6所示,手臂删除处理包括以下步骤S61至步骤S63。
步骤S61:获取肤色连通域后,使用主成份分析方法获取肤色连通域的主方向,例如,主方向如图7(A)中的白色直线所示。
步骤S62:以该主方向为基准旋转肤色连通域所在图像的原坐标系直到Y轴与该主方向平行,旋转后的新坐标系XOY如图7(B)所示。
通过步骤S62,旋转坐标系前的图像中的所有点的坐标在新坐标系下都被赋予一个新的坐标值。
例如,可以使肤色连通域的顶点(如圆圈标注的点所示)为Y值(即Y坐标值)最大的点。
步骤S63:沿新坐标系的Y轴,按照预设规则对肤色连通域进行分割处理,以获取疑似手部连通域,例如,该疑似手部连通域如图7(C)和图7(D)所示。
例如,在该步骤中,以新坐标系为准,从Y值最大的点开始,沿Y值减小的方向(如箭头方向所示),计算肤色连通域中所有Y值对应的像素点的个数,其中像素点最多的位置可看作是手掌位置,像素点的最大数量(上述参考数量的一个示例)可以作为手的最大宽度W;以像素点的该最大数量的k(例如k为2.5-3.0)倍作为手的长度L,沿主方向并且从连通域的顶点开始根据长度L进行分割,分割位置以下的部分全部被视为手臂并且被删除,从而得到包括疑似手部连通域的图像。
k的取值使获得的疑似手部连通域可能仍然带有较长的手臂的残余部分(如图7(C)所示),也可能刚好包括手的全部且不包括手臂(如图7(D)所示)。虽然如此,手臂删除处理中k的取值可偏大但不宜过小,因为k过小则可能出现手被切割掉一部分的过切割的现象。
在图7(A)-图7(C)中,肤色连通域的宽度在手掌的位置处最大;在 另一些实施例中,如果衣服的颜色与肤色接近,则可能出现手臂宽度比手掌宽度大的情况,在这种情况下,由于k的取值为2.5-3.0,该值仍然可以实现用肤色连通域的最大宽度(例如像素点的最大数量)的k倍作为手的长度L。
在获取疑似手部连通域之后,进行有效手指区域检测。如果检测到至少一个有效手指区域,则可利用该有效手指区域进行后续处理;如果未检测出有效手指区域,则继续对下一个肤色连通域进行手臂删除处理以及有效手指区域检测。
有效手指区域检测可以如图8所示,其包括步骤S81至步骤S83。
步骤S81:计算步骤S63中得到的疑似手部连通域的重心点或者该连通域的外切图形(例如矩形或椭圆形)的几何中心。
步骤S82:以步骤S81中得到的重心点或几何中心为第1起点,计算连通域上所有点到第1起点的测地距离,并且选取测地距离最大的点作为第1极远点,即第1疑似手指指尖;每找到一个极远点,都以该极远点为起点,继续寻找下一个极远点,直到得到n个极远点(例如n>5,例如5<n≤10),并且将这些极远点作为疑似手指指尖。
例如,第1极远点可以通过如下步骤S821-步骤S823获得。
步骤S821:初始化距离矩阵。
初始化构造一个与步骤S63中获得的图像同样大小的距离矩阵,距离矩阵中的元素与图像中的像素一一对应。例如,将起点(第1起点为步骤S81中得到的疑似手部连通域的重心点或几何中心)在距离矩阵中对应点的距离值设置为0;将疑似手部连通域中的其它点在距离矩阵中对应点的距离值都设置为某个最大值(例如100,000或其它数值);将图像中的背景点(即疑似手部连通域之外的点)在距离矩阵中的对应点的距离值都设置为-1,表示这些点的距离值不需要计算。
步骤S822:更新距离矩阵。
从起点出发逐渐更新距离矩阵,先将起点放到一个FIFO(First Input First Output的缩写)队列中。每次从FIFO队列中取一个点,以该点为原点,检查其8邻域点对应的距离值是否需要更新,如果8邻域点的新距离值小于原距离值,则对该8邻域点的距离值进行更新,并将被更新的邻域点添加到FIFO队列中。之后,从FIFO队列中取出被更新后的邻域点,并且以其为原 点计算其8邻域的新距离值。对于每个原点的8邻域点,每个邻域点的新距离值为原点的距离值加上原点到邻域点的二维距离,例如,原点的4邻域点的新距离值为原点的距离值加上1,原点的对角邻域点的新距离值为原点的距离值加上2的正平方根(1.414)。由于同一个点可能是多个原点的邻域,在这种情况下,选取根据该多个原点计算得到的距离值中的最小距离值作为该点的新距离值。当FIFO队列中的全部点都处理完成后,即完成了距离矩阵更新。
步骤S823:选择极远点。
更新后的距离矩阵中的大于0的距离值即为疑似手部连通域中各点到起点的测地距离,找到距离矩阵中距离值最大的点作为极远点。
反复执行步骤S821-步骤S823,直到检测到n个极远点。这些极远点即为疑似手指指尖,即手指指尖的候选点。
例如,如图9中的(A)所示,第1极远点(如白色圆点所示)位于中指指尖;如图9中的(B)所示,第2极远点位于无名指指尖;如图9中的(C)所示,第3极远点位于食指指尖;如图9中的(D)所示,第4极远点位于小拇指指尖;如图9中的(E)所示,第5极远点位于大拇指指尖。
步骤S83:对所有疑似手指指尖进行有效指尖判断,以得到有效手指区域。
例如,以每个极远点为起点,采用像素生长的方法检验该极远点所在区域是否是有效手指区域。
如图10所示,以极远点为起点进行疑似手指区域的生长,每次生长中每个像素只向相邻像素生长一次(即,每一次生长的点为前一次生长的像素点的邻域点),图中的白色标记分别为多次生长出的新像素的位置。当某区域中生长的像素的总个数符合手指与手掌像素数应有的比例时,即可认为该区域是手指区域。例如,如图10中的最后一次生长所示,如果继续生长则像素数会出现激增,此时停止生长,该最后一次生长所在位置为临界位置,此临界位置到生长初始点的距离即是疑似手指区域的长度,该长度满足与手掌宽度、面积等预设的比例关系(例如上述有效手指区域的选取条件)时,疑似手指区域才能被判定为一个有效手指区域。
例如,所谓预设的比例关系包括以下三种关系。
1、疑似手指区域的长度不小于步骤S63中算出的疑似手部连通域的最大宽度W的三分之一且不大于疑似手部连通域的最大宽度W的1.5倍。
例如,疑似手指区域的长度为在从区域初始点到区域终点的方向上的像素点数量,其在区域生长过程中可获知。
2、疑似手指区域的宽度不大于疑似手部连通域的最大宽度W的五分之一。
例如,疑似手指区域的宽度为生长终点处的在手指宽度方向上的像素点数量,其在区域生长过程中可获知。
3、疑似手指区域的面积(例如像素点总数,其在区域生长过程中可得到)不大于整个疑似手部连通域的面积(例如像素点总数,其在计算测地距离的过程中可得到)的五分之一。
例如,可以按照以上3个判断条件至少一个或组合,在同时采用3个判断条件时,对疑似手指区域进行逐个判断,可以更准确地选出所有的有效手指区域。在找到至少一个有效手指区域的情况下,疑似手部连通域为有效手部连通域,之后该有效手部连通域可以直接被送入分类器中或者在被进一步分割之后被送入分类器中进行手势识别;对于前文提到的非手部物体,如人脸或其它干扰物,因其形状、尺寸等不符合手指与手的比例关系,无法检测到有效手指区域,因此可以判断出不是有效手部连通域。
在检测出所有的有效手指区域后,选取最长的有效手指区域的长度,根据该长度的1.5-1.7倍并且根据之前步骤中确定的主方向信息,沿着平行于主方向的Y轴,对疑似手部连通域进行分割。参见图11中的(A)和(B),其中,图11中的(A)为分割之前的连通域,图11中的(B)为分割之后的连通域。
例如,如图12中的(A)和(B)所示,采用本公开实施例提供的方法可以获得效果好的手部图像;并且,由于本公开实施例采用肤色检测,因此得到的手部图像中的手部也可以包括手纹。
由于肤色检测的结果可能受到曝光、物体颜色接近等因素的影响,为了获取更准确的手部连通域,在根据有效手指区域对有效手部连通域进行分割得到目标图像之后,可以对目标图像再进行一次肤色提取(其方法参见肤色检测处理)。由于本次提取是在一张图片的一个小范围内进行的,该范围包 含信息少且绝大部分像素是手部信息,因此可以使用增强对比度的方法(例如直方图均衡化)来提高手分割的效果。经过二次肤色分割后,即可获得效果良好的手分割结果,然后将该结果送入分类器进行手势识别。
本公开的至少一个实施例还提供一种图像检测系统,如图13所示,该图像检测系统包括点确定装置、与点确定装置连接的区域确定装置以及与区域确定装置连接的判断装置。
点确定装置用于:确定第1起点以及不同于第1起点的n个极远点,其中,第1起点为待检测图像中的连通域的重心点以及连通域的外切图形的几何中心中的一个,第N+1起点为第N极远点,第N极远点为连通域中到第N起点的测地距离最大的像素点,并且n、N都为正整数。
区域确定装置用于:分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域。
判断装置用于:判断n个区域中的每个区域的预设特征与连通域的预设特征之间的关系是否满足选取条件,以确定满足选取条件的有效区域。
例如,图像检测系统还包括提取装置,其用于:获取有效区域包括的极远点的坐标;或者采用主成分分析方法确定连通域的数据变化方向,并且沿着数据变化方向并且根据参考长度(即上述第一参考长度)对连通域进行分割以获取目标图像,参考长度为有效区域的尺寸与预设倍数(即上述第一预设倍数)的乘积。
例如,该图像检测系统还可以包括摄像机,其被配置为获取图像,并且将获取的图像输入点确定装置中。该摄像机可以为普通摄像机,所拍摄的图像为二维图像,不包括深度信息。
本公开实施例的图像检测系统中各器件的功能,可参照前述图像检测方法的实施例中的相关描述。
例如,图像检测系统中的点确定装置、区域确定装置、判断装置和提取装置的具体结构均可采用硬件、软件或固件实现,例如对应于处理器以及可由该处理器执行的可执行指令,例如,该处理器可以为中央处理器(CPU,Central Processing Unit)、微处理器(MCU,Micro Controller Unit)、数字信号处理器(DSP,Digital Signal Processing)或可编程逻辑器件(PLC,Programmable Logic Controller)等具有处理功能的电子元器件或电子元器件 的集合。
另外,在本公开实施例中的上述装置可以全部在一个处理器中,或者分别通过不同的处理器实现,或者任意两个或两个以上的装置在一个处理器中实现;上述各装置既可以采用硬件的形式实现,也可以采用硬件加软件功能单元的形式实现。
本公开的至少一个实施例还提供另一种图像检测系统,如图14所示,该图像检测系统,包括处理器、存储器、以及存储在存储器中的计算机程序指令,其中,在计算机程序指令被处理器运行时执行:确定第1起点,其中,第1起点为待检测图像中的连通域的重心点以及连通域的外切图形的几何中心中的一个;确定不同于第1起点的n个极远点,其中,第N极远点为连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,并且n、N都为正整数;分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域;以及判断n个区域中的每个区域的预设特征与连通域的预设特征之间的关系是否满足选取条件,以确定满足选取条件的有效区域。
存储器可以包括只读存储器和随机存取存储器中的至少一个,并向处理器提供指令和数据。存储器的一部分还可以包括非易失性随机存取存储器(NVRAM),包括磁存储器、半导体存储器、光存储器等。
处理器可以是通用处理器(例如中央处理器等)、数字信号处理器(DSP)、专用集成电路(ASIC)、现场可编程门阵列(FPGA)或者其他可编程逻辑器件、晶体管逻辑器件、分立硬件组件。通用处理器可以是微处理器或者任何常规的处理器等。
本公开的至少一个实施例还提供一种存储介质,其中存储有计算机程序指令,计算机程序指令适于由处理器加载并执行:确定第1起点,其中,第1起点为待检测图像中的连通域的重心点以及连通域的外切图形的几何中心中的一个;确定不同于第1起点的n个极远点,其中,第N极远点为连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,并且n、N都为正整数;分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域;以及判断n个区域中的每个区域的预设特征与连通域的预设特征之间的关系是否满足选取条件,以确定满足选取条件的有效区域。
例如,该存储介质可以是半导体存储器、磁表面存储器、激光存储器、 随机存储器、只读存储器、串行访问存储器、非永久记忆的存储器、永久性记忆的存储器或者本领域熟知的任何其它形式的存储介质。
例如,处理器可以是通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现场可编程门阵列(FPGA)或者其他可编程逻辑器件、晶体管逻辑器件、分立硬件组件。通用处理器可以是微处理器或者任何常规的处理器等。
本公开的至少一个实施例还提供一种设备,其包括以上任一实施例提供的图像检测系统或存储介质。
例如,该设备可以为AR智能眼镜、显示器等人机交互设备,该设备利用普通摄像机获取图像,并且通过对该图像进行分析处理,实现人机交互。
本公开的至少一个实施例还提供一种手部检测方法,如图15所示,该手部检测方法包括:在待检测图像中的连通域中确定手心位置;以手心位置为第1起点,确定不同于手心位置的n个极远点,其中,第N极远点为连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,并且n、N都为正整数;分别以n个极远点为初始点进行区域生长,以在连通域中获取n个区域;以及判断n个区域中的每个区域的预设特征与连通域的预设特征之间的关系是否满足选取条件,以确定满足选取条件的有效手指区域。
例如,手心位置可以为待检测图像的连通域的重心点或者外切图形(例如矩形或椭圆形)的几何中心。在本公开的其它实施例中,手心位置也可以为通过其它方式确定。
本公开的至少一个实施例还提供一种手分割方法,如图16所示,该手分割方法包括步骤S161至步骤S163。
步骤S161:通过肤色检测获取肤色连通域。
例如,肤色检测可参考上述步骤S51-S54。
步骤S162:获取肤色连通域的最大宽度和基于主成分分析方法的主方向,沿主方向并且根据最大宽度的预设倍数分割肤色连通域,以获取疑似手部连通域。
例如,该步骤S162可以包括上述步骤S61-S63,这样可以删除手臂等干扰。在这种情况下,肤色连通域的最大宽度例如用该肤色连通域的最宽处的像素点的数量来表示;预设倍数例如为上述的k倍,即2.5-3.0;基于主成分 分析方法的主方向即利用主成分分析方法获取的该肤色连通域的主方向。
步骤S163:根据以上所述的手部检测方法判断疑似手部连通域(手部检测方法中的待检测图像中的连通域的一个示例)是否包括有效手指区域。
在该步骤S163中,若判断出疑似手部连通域包括至少一个有效手指区域,则可判断出该疑似手部连通域为有效手部连通域。例如,还可以沿着主方向并且根据有效手指区域的长度(例如最长的有效手指区域的长度)与预设倍数(例如1.5-1.7)的乘积对该有效手部连通域进行分割,以进一步排除手臂的干扰。
上述手部检测方法、手分割方法、图像检测方法、图像检测系统及包括其的设备的实施例可以互相参照。此外,在不冲突的情况下,本公开的实施例及实施例中的特征可以相互组合。
在本公开实施例中,采用区域生长的方式得到疑似区域,可以避免待检测图像中与目标物体的连通域连通但实际上对应干扰物的区域的干扰;根据预设的选取条件对疑似区域进行检测以确定有效区域,可以进一步减少图像检测的干扰因素;由于选取条件根据疑似区域的尺寸特征和连通域的尺寸特征确定,不需要使用深度信息,因而本公开实施例可以用于对普通摄像机获取的图像进行处理;通过肤色检测获取肤色连通域,使得本公开实施例可以进一步去除一部分干扰物;通过手臂删除处理,可以进一步去除干扰因素。因此,本公开实施例提供的图像检测技术可以用于对普通摄像机获取的图像进行处理,可以有效减少干扰因素,以提高图像检测结果的准确性并且实现快速实时计算。
以上所述仅是本公开的示范性实施方式,而非用于限制本公开的保护范围,本公开的保护范围由所附的权利要求确定。

Claims (25)

  1. 一种图像检测方法,包括:
    在待检测图像中的连通域中确定第1起点;
    在待检测图像中的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;
    分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及
    判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
  2. 根据权利要求1所述的方法,其中,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
  3. 根据权利要求1或2所述的方法,还包括:获取所述有效区域包括的极远点的坐标。
  4. 根据权利要求1-3中任一项所述的方法,还包括:采用主成分分析方法确定所述连通域的数据变化方向,并且沿着所述数据变化方向并且根据第一参考长度对所述连通域进行分割以获取目标图像,所述第一参考长度为所述有效区域的尺寸与第一预设倍数的乘积。
  5. 根据权利要求4所述的方法,其中,所述连通域的数据变化方向为所述连通域的主方向。
  6. 根据权利要求4或5所述的方法,其中,所述方法用于手部检测。
  7. 根据权利要求6所述的方法,其中,所述第一预设倍数为1.5-1.7。
  8. 根据权利要求6或7所述的方法,其中,在所述n个区域包括多个有效区域的情况下,所述第一参考长度为具有最大长度的有效区域的尺寸与所述第一预设倍数的乘积。
  9. 根据权利要求6-8中任一项所述的方法,其中,所述有效区域的选取条件包括A、B或C中的至少一个或多个:
    A:所述每个区域的长度与所述连通域的最大宽度的第一比值不小于1/3 且不大于1.5;
    B:所述每个区域的宽度与所述连通域的最大宽度的第二比值不大于1/5;
    C:所述每个区域的面积与所述连通域的面积的第三比值不大于1/5。
  10. 根据权利要求1或2所述的方法,在获取所述第1起点之前,还包括:
    根据颜色范围从第一图像中获取包括初始连通域的第二图像;并且
    对所述第二图像的初始连通域进行处理以获取所述待检测图像中的连通域。
  11. 根据权利要求10所述的方法,其中,所述方法用于手部检测,并且对所述初始连通域进行处理以获取所述连通域包括:
    采用主成分分析方法确定所述初始连通域的数据变化方向;
    使所述第二图像的坐标系的预设坐标轴与所述初始连通域的数据变化方向平行;
    对于所述预设坐标轴的多个位置中的每个位置,计算所述初始连通域中对应所述每个位置的像素点的数量,选取像素点的最大数量作为参考数量,并且将所述参考数量与第二预设倍数的乘积作为第二参考长度;以及
    沿所述初始连通域的数据变化方向并且根据所述第二参考长度对所述初始连通域进行分割,以获取所述待检测图像中的连通域。
  12. 根据权利要求11所述的方法,其中,所述第二预设倍数大于或等于2.5且小于或等于3。
  13. 根据权利要求1-12中任一项所述的方法,其中,对于所述n个区域中的每个区域,所述区域的生长终点的确定方法包括:在所述区域的第i次生长之后,如果所述区域的第i+1次生长中像素点数量的增加值超过预设值,那么所述第i次生长为所述区域的最后一次生长。
  14. 根据权利要求1-12中任一项所述的方法,其中,对于所述n个区域中的每个区域,根据预设长度确定所述区域的生长终点。
  15. 根据权利要求1-14中任一项所述的方法,其中,所述待检测图像为不包括像素点的深度信息的图像。
  16. 一种图像检测系统,包括处理器、存储器以及存储在存储器中的计 算机程序指令,其中,在所述计算机程序指令被处理器运行时执行:
    在待检测图像中的连通域中确定第1起点;
    在待检测图像中的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;
    分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及
    判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
  17. 根据权利要求16所述的图像检测系统,其中,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
  18. 一种图像检测系统,包括:
    点确定装置,其被配置为:在待检测图像中的连通域中确定第1起点以及不同于所述第1起点的n个极远点,其中,第N+1起点为第N极远点,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,n、N都为正整数,并且N≤n;
    区域确定装置,其被配置为:分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及
    判断装置,其被配置为:判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
  19. 根据权利要求18所述的图像检测系统,其中,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
  20. 根据权利要求18或19所述的图像检测系统,还包括提取装置,其被配置为:
    获取所述有效区域包括的极远点的坐标;或者
    采用主成分分析方法确定所述连通域的数据变化方向,并且沿着所述数据变化方向并且根据参考长度对所述连通域进行分割以获取目标图像,所述 参考长度为所述有效区域的尺寸与预设倍数的乘积。
  21. 一种存储介质,其中存储有计算机程序指令,所述计算机程序指令适于由处理器加载并执行:
    在待检测图像中的连通域中确定第1起点;
    在待检测图像中的连通域中确定不同于所述第1起点的n个极远点,其中,第N极远点为所述连通域中到第N起点的测地距离最大的像素点,第N+1起点为第N极远点,n、N都为正整数,并且N≤n;
    分别以所述n个极远点为初始点进行区域生长,以在所述连通域中获取n个区域;以及
    判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效区域。
  22. 根据权利要求21所述的存储介质,其中,所述第1起点对应的物点到待检测图像中的连通域的重心点以及所述连通域的外切图形的几何中心中的一个对应的物点之间的距离小于2厘米。
  23. 一种设备,包括根据权利要求16或17所述的图像检测系统或权利要求18-20中任一项所述的图像检测系统或权利要求21或22所述的存储介质。
  24. 一种采用权利要求1-15中任一项所述图像检测方法的手部检测方法,其中,
    在所述待检测图像中的所述连通域中确定手心位置,并且以所述手心位置为所述第1起点;
    判断所述n个区域中的每个区域的预设特征与所述连通域的预设特征之间的关系是否满足选取条件,以确定满足所述选取条件的有效手指区域。
  25. 一种手分割方法,包括:
    通过肤色检测获取肤色连通域;
    获取所述肤色连通域的最大宽度和基于主成分分析方法的主方向,沿所述主方向并且根据所述最大宽度的预设倍数分割所述肤色连通域,以获取疑似手部连通域;以及
    根据权利要求24所述的方法判断所述疑似手部连通域是否包括所述有效手指区域。
PCT/CN2018/091321 2017-08-31 2018-06-14 手和图像检测方法和系统、手分割方法、存储介质和设备 WO2019041967A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
US16/342,626 US10885321B2 (en) 2017-08-31 2018-06-14 Hand detection method and system, image detection method and system, hand segmentation method, storage medium, and device
EP18850076.3A EP3678046B1 (en) 2017-08-31 2018-06-14 Hand detection method and system, image detection method and system, hand segmentation method, storage medium, and device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710771527.8A CN109426789B (zh) 2017-08-31 2017-08-31 手和图像检测方法和系统、手分割方法、存储介质和设备
CN201710771527.8 2017-08-31

Publications (1)

Publication Number Publication Date
WO2019041967A1 true WO2019041967A1 (zh) 2019-03-07

Family

ID=65504739

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/091321 WO2019041967A1 (zh) 2017-08-31 2018-06-14 手和图像检测方法和系统、手分割方法、存储介质和设备

Country Status (4)

Country Link
US (1) US10885321B2 (zh)
EP (1) EP3678046B1 (zh)
CN (1) CN109426789B (zh)
WO (1) WO2019041967A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114299406A (zh) * 2022-03-07 2022-04-08 山东鹰联光电科技股份有限公司 基于无人机航拍的光纤电缆线路巡检方法

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109426789B (zh) * 2017-08-31 2022-02-01 京东方科技集团股份有限公司 手和图像检测方法和系统、手分割方法、存储介质和设备
CN110503705B (zh) * 2019-08-29 2023-10-17 上海鹰瞳医疗科技有限公司 图像标注方法和设备
CN111080668A (zh) * 2019-12-13 2020-04-28 武汉华目信息技术有限责任公司 一种闸片磨损故障检测的方法及系统
CN114007085A (zh) * 2020-07-15 2022-02-01 程海涛 一种基于地理位置的用户信息匹配,关联点播直播方法和系统(穿越直播)
CN115761602B (zh) * 2023-01-07 2023-04-18 深圳市蓝鲸智联科技有限公司 用于车窗控制系统的视频智能识别方法
CN116824466B (zh) * 2023-06-21 2024-05-17 前海蜂鸟谷教育科技(深圳)有限公司 辅助少儿智能编程的方法、装置和计算机存储介质
CN117808801B (zh) * 2024-02-29 2024-05-17 泰安大陆医疗器械有限公司 一种钢针排针植入视觉检测方法及系统

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160092726A1 (en) * 2014-09-30 2016-03-31 Xerox Corporation Using gestures to train hand detection in ego-centric video
CN105975906A (zh) * 2016-04-27 2016-09-28 济南大学 一种基于面积特征的pca静态手势识别方法
CN106097354A (zh) * 2016-06-16 2016-11-09 南昌航空大学 一种结合自适应高斯肤色检测和区域生长的手部图像分割方法

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE19612949C1 (de) * 1996-04-01 1997-08-14 Siemens Ag Verfahren zur Erkennung mindestens eines fingerförmigen Objekts in einem ersten, handförmigen Objekt durch einen Rechner
US6088512A (en) * 1997-07-09 2000-07-11 Seiko Epson Corporation Void-and-cluster dither-matrix generation for better half-tone uniformity
US8611670B2 (en) * 2010-02-25 2013-12-17 The Board Of Trustees Of The Leland Stanford Junior University Intelligent part identification for use with scene characterization or motion capture
CN102750690B (zh) * 2012-05-29 2014-10-01 武汉大学 一种基于边缘约束的分形网络演化影像分割方法
AU2013245477A1 (en) * 2013-10-16 2015-04-30 Canon Kabushiki Kaisha Method, system and apparatus for determining a contour segment for an object in an image captured by a camera
US9436872B2 (en) * 2014-02-24 2016-09-06 Hong Kong Applied Science and Technology Research Institute Company Limited System and method for detecting and tracking multiple parts of an object
CN105096259B (zh) * 2014-05-09 2018-01-09 株式会社理光 深度图像的深度值恢复方法和系统
CN107818290B (zh) * 2016-09-14 2021-03-16 京东方科技集团股份有限公司 基于深度图的启发式手指检测方法
CN107958458B (zh) * 2016-10-17 2021-01-22 京东方科技集团股份有限公司 图像分割方法、图像分割系统及包括其的设备
CN109426789B (zh) * 2017-08-31 2022-02-01 京东方科技集团股份有限公司 手和图像检测方法和系统、手分割方法、存储介质和设备

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160092726A1 (en) * 2014-09-30 2016-03-31 Xerox Corporation Using gestures to train hand detection in ego-centric video
CN105975906A (zh) * 2016-04-27 2016-09-28 济南大学 一种基于面积特征的pca静态手势识别方法
CN106097354A (zh) * 2016-06-16 2016-11-09 南昌航空大学 一种结合自适应高斯肤色检测和区域生长的手部图像分割方法

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3678046A4 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114299406A (zh) * 2022-03-07 2022-04-08 山东鹰联光电科技股份有限公司 基于无人机航拍的光纤电缆线路巡检方法
CN114299406B (zh) * 2022-03-07 2022-06-07 山东鹰联光电科技股份有限公司 基于无人机航拍的光纤电缆线路巡检方法

Also Published As

Publication number Publication date
EP3678046A4 (en) 2021-08-18
EP3678046B1 (en) 2023-12-13
CN109426789A (zh) 2019-03-05
EP3678046A1 (en) 2020-07-08
CN109426789B (zh) 2022-02-01
US20190236345A1 (en) 2019-08-01
US10885321B2 (en) 2021-01-05

Similar Documents

Publication Publication Date Title
WO2019041967A1 (zh) 手和图像检测方法和系统、手分割方法、存储介质和设备
US10679146B2 (en) Touch classification
WO2020199468A1 (zh) 图像分类方法、装置及计算机可读存储介质
WO2019232866A1 (zh) 人眼模型训练方法、人眼识别方法、装置、设备及介质
WO2019232862A1 (zh) 嘴巴模型训练方法、嘴巴识别方法、装置、设备及介质
WO2021012484A1 (zh) 基于深度学习的目标跟踪方法、装置及计算机可读存储介质
US8582836B2 (en) Face recognition in digital images by applying a selected set of coefficients from a decorrelated local binary pattern matrix
EP3537375B1 (en) Image segmentation methods, image segmentation system and device comprising same, and storage medium
TWI395145B (zh) 手勢辨識系統及其方法
WO2019114036A1 (zh) 人脸检测方法及装置、计算机装置和计算机可读存储介质
CN105210115B (zh) 使用2d图像数据来执行手势识别
CN107818290B (zh) 基于深度图的启发式手指检测方法
WO2020114320A1 (zh) 点云聚类方法、图像处理设备及具有存储功能的装置
WO2019174276A1 (zh) 用于定位目标物体区域中心的图像处理方法、装置、设备和介质
WO2022028031A1 (zh) 一种轮廓形状识别方法
WO2020119144A1 (zh) 一种图像相似度计算方法、装置、存储介质
EP2980755B1 (en) Method for partitioning area, and inspection device
US10438083B1 (en) Method and system for processing candidate strings generated by an optical character recognition process
WO2019232849A1 (zh) 汉字模型训练方法、手写字识别方法、装置、设备及介质
WO2020034743A1 (zh) 三维模型处理方法、装置、电子设备及可读存储介质
WO2020248848A1 (zh) 智能化异常细胞判断方法、装置及计算机可读存储介质
JP6997369B2 (ja) プログラム、測距方法、及び測距装置
WO2020151299A1 (zh) 黄色禁停线识别方法、装置、计算机设备及存储介质
WO2019232870A1 (zh) 手写字训练样本获取方法、装置、计算机设备及存储介质
WO2019095998A1 (zh) 图像识别方法及装置、计算机装置和计算机可读存储介质

Legal Events

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

Ref document number: 18850076

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2018850076

Country of ref document: EP

Effective date: 20200331