CN105989594B - A kind of image region detection method and device - Google Patents

A kind of image region detection method and device Download PDF

Info

Publication number
CN105989594B
CN105989594B CN201510075465.8A CN201510075465A CN105989594B CN 105989594 B CN105989594 B CN 105989594B CN 201510075465 A CN201510075465 A CN 201510075465A CN 105989594 B CN105989594 B CN 105989594B
Authority
CN
China
Prior art keywords
pixel
image
cluster
processed
probability
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201510075465.8A
Other languages
Chinese (zh)
Other versions
CN105989594A (en
Inventor
石克阳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201510075465.8A priority Critical patent/CN105989594B/en
Priority to PCT/CN2016/073274 priority patent/WO2016127883A1/en
Publication of CN105989594A publication Critical patent/CN105989594A/en
Application granted granted Critical
Publication of CN105989594B publication Critical patent/CN105989594B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/40Analysis of texture

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)

Abstract

The application provides a kind of image region detection method and device.The method may include: the color characteristic and Gradient Features of image slices vegetarian refreshments to be processed is calculated, constructs the composite character vector of the image to be processed;The composite character vector is clustered, clustering after obtaining cluster;According to pre-defined rule calculate described in the probability that clusters that clusters, and based on the pixels probability of middle pixel of clustering described in probability calculation that clusters;The image to be processed is detected based on the pixels probability, obtains target area.Using embodiment each in the application, the situation of various complexity in real image scene can be successfully managed, realization carries out accurate and effective separation to body region in commodity image, improves and extracts accuracy.

Description

A kind of image region detection method and device
Technical field
The application belongs to computer information processing field more particularly to a kind of image region detection method and device.
Background technique
With the development of internet Consumption Age, such as the online commercial articles searching of offers such as one washes in a pan, Taobao and day cat store The image for having underlying commodity would generally be provided largely when merchandise news is shown with the website of online shopping, in order to consumer's progress Intuitive selection.Commodity image is more as carrying in the website of on-line search and shopping, is unusual important information, for commodity Conclusion of the business has strong influence.
In goods information on the network displaying, usual commodity image can preferably embody the intuitive nature of commodity, in commodity Body region (or referred to as foreground area, such as wind coat, casual pants, leather shoes, mobile phone, sofa stool) be usually in commodity image Information content maximum, most important part.For example, when merchandise display, launching advertisement, it usually needs consideration is worked as in piece image In, whether commodity body placed in the middle, whether occupied in the picture that image is shown meet defined ratio, body region relative to Whether background protrudes.And most commodity images are voluntarily shot upload by seller trade company in website displaying in actual application Window, seller trade company often do not have the shooting and picture editting's ability of profession, cannot protrude well and show product features.Cause Business platform service side usually requires to analyze the image that seller trade company provides in this application scenes, obtains commodity master Body adjusts the displaying angles of commodity, background collocation, placement position, main body commodity size etc., makes it have best illustrated effect Image, in order to consumer can more acurrate its interested commodity of acquisition, or by trade company commodity attract.Therefore, commercial The user of platform service side or terminal applies usually require it is accurate and efficiently from commodity image by commodity body region and It separates background area.
Currently used commodity body region and background area isolation technics mainly include using in academia based on color The saliency region detection technology of quantization characteristic.This kind of technology, which is typically due to depend only on color characteristic, to be handled, It is only capable of handling simple commodity image.And the commodity image in the flatbeds electric business website such as Taobao, day cat can be by selling Family uploads, and the quality of image is irregular, and complexity is also very high.Such as under main body and the similar situation of background color, It is easy to mix the two when modeling using color, it is difficult to distinguish, can not effectively extract body region.Equally, exist Background complexity it is higher i.e. non-master body region distribution of color complexity when, using the method based on color characteristic often by background It is modeled as excessive block with prospect, causes also be accurately separated foreground and background.
In currently available technology commodity image main body identification technology face main body and background area color it is close or back Detection, the separation of body region cannot accurately, be effectively carried out when the complicated images such as scene area complexity height.It is outstanding in the prior art It needs a kind of more efficient, accurate detection method when being complicated image region detection.
Summary of the invention
The application is designed to provide a kind of image region detection method and device, can successfully manage in real image scene The situation of various complexity, realization carry out accurate and effective separation to body region in complicated image, improve and extract accuracy.
A kind of image region detection method and device provided by the present application are achieved in that
A kind of image region detection method, which comprises
The color characteristic and Gradient Features of image slices vegetarian refreshments to be processed is calculated, constructs the mixing of the image to be processed Feature vector;
The composite character vector is clustered, clustering after obtaining cluster;
According to pre-defined rule calculate described in the probability that clusters that clusters, and based on the middle picture that clusters described in probability calculation that clusters The pixels probability of vegetarian refreshments;
The image to be processed is detected based on the pixels probability, obtains target area.
A kind of image-region detection device, described device include:
Feature calculation module for the color characteristic and Gradient Features of image slices vegetarian refreshments to be processed to be calculated, and constructs The composite character vector of the image to be processed;
Cluster module, for being clustered to the composite character vector, clustering after obtaining cluster;
Cluster probabilistic module, for according to pre-defined rule calculate described in the probability that clusters that clusters;
Pixels probability module, for based on the pixels probability of middle pixel of clustering described in probability calculation that clusters;
Detection module obtains target area for detecting based on the pixels probability to the image to be processed.
A kind of image-region detection device, described device are configured to, comprising:
Image slices vegetarian refreshments to be processed is calculated for obtaining the image to be processed at users/customers end in first processing units Color characteristic and Gradient Features, construct the composite character vector of the image to be processed;
The second processing unit, for being clustered to the composite character vector, clustering after obtaining cluster;It is also used to root According to pre-defined rule calculate described in the probability that clusters that clusters, and based on the pixel of middle pixel of clustering described in probability calculation that clusters Probability;
Output unit, for carrying out acquisition target area to the image to be processed based on the pixels probability, and by institute It states the target area storage of acquisition or is showed in designated position.
A kind of image region detection method and device provided by the present application, each pixel being adopted as in image construct it Distinctive composite character vector.It further include gradient other than it may include the color characteristic of pixel in the composite character vector Feature considers the information around pixel simultaneously when calculating pixel, can more accurately establish the feature of pixel Value, so that the distance ratio of the composite character vector of two points similar in foreground and background region is only used only when composite character space The distance of color characteristic greatly increases, and can effectively distinguish region similar in foreground and background, improve current region detection Precision.Likewise, composite character vector described herein can be very good color combining feature in complex background image With Gradient Features by the pixel of the pixel of prospect and background be described to two it is different cluster, when Euclidean distance calculates It can be easy to separate the two.Composite character is clustered in the application, clusters after calculating cluster and belongs to body region Cluster probability, based on the probability calculation that clusters cluster in each pixel belong to the pixels probability of body region, with the application institute The significance calculated stated can effectively, accurately detect in image to be processed as the probability for belonging to body region Body region.The application using it is described cluster with other cluster distance and with the ratio of summation as the significance to cluster, be used for table The case where the belonging to the probability of body region, being more in line with commodity body in actual user's perceptual image that cluster is stated, so that processing knot Fruit is more accurate, effective.
Detailed description of the invention
In order to illustrate the technical solutions in the embodiments of the present application or in the prior art more clearly, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this The some embodiments recorded in application, for this neighborhood those of ordinary skill, in the premise of not making the creative labor property Under, it is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of a kind of flow diagram of embodiment of image region detection method of the application;
Fig. 2 is the schematic diagram that herein described image boundary vertex neighborhood window to be processed extracts;
Fig. 3 is to utilize a kind of schematic diagram of image region detection method progress body region extraction described herein;
Fig. 4 is to utilize a kind of schematic diagram of image region detection method progress body region extraction described herein;
Fig. 5 is a kind of modular structure schematic diagram of herein described image-region detection device;
Fig. 6 is a kind of a kind of modular structure schematic diagram of embodiment of herein described feature calculation module;
Fig. 7 is a kind of a kind of modular structure schematic diagram of embodiment of herein described color-feature module;
Fig. 8 is a kind of a kind of herein described modular structure schematic diagram of embodiment of pixels probability computing module.
Specific embodiment
In order to make the personnel of this technology neighborhood more fully understand the technical solution in the application, below in conjunction with the application reality The attached drawing in example is applied, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described implementation Example is merely a part but not all of the embodiments of the present application.Based on the embodiment in the application, this neighborhood is common The application protection all should belong in technical staff's every other embodiment obtained without making creative work Range.
It may include one or more main body in the commodity image that seller trade company uploads, such as in order to save merchandise display Window resource, seller trade company uploads image as certain commodity after can merging multiple images in an image.This Shen Please a kind of image region detection method can be adapted for include one or more commodity body image, in the figure When as including multiple main bodys, image to be processed can be divided into multiple subgraphs, each subgraph may include single main body, then Each subgraph is handled using body region extracting method described herein.Specifically described will include multiple masters The method that the image to be processed of body is divided can use Patent No. CN102567952A, a kind of entitled " image segmentation Method and system " described in image partition method.It, can be by the commodity figure including multiple main bodys after the above method is handled As being divided into multiple subgraphs including single main body.
Below by include the commodity image of single main body or by taking the subgraph after above-mentioned image segmentation as an example to this Shen Image processing method that please be described is described in detail.Fig. 1 is a kind of one reality of herein described image region detection method The method flow diagram of example is applied, as described in Figure 1, the method may include:
S1: being calculated the color characteristic and Gradient Features of image slices vegetarian refreshments to be processed, constructs the image to be processed Composite character vector.
As previously mentioned, image to be processed described in the present embodiment can be the independent commodity figure for including a main body Picture, or the subgraph including single main body after image segmentation comes out.After obtaining the image to be processed, The composite character that image slices vegetarian refreshments to be processed can be constructed based on the characteristic value for including color and gradient, formed composite character to Amount.In actual image information processing, the mode that local feature usually can be used carries out the feature extraction of each pixel, example Such as some pixel P, a neighborhood window W (p) can be chosen, the neighborhood window W (p) can for one with The square area of N*N centered on P point.The value of the N can be according to the precision of Image Information Processing or speed etc. It is required that reasonably selected, such as can be according to picture size or how much values including pixel are the odd numbers such as 3,5,7,9.This N described in embodiment can with value for 5, can in the composite character for calculating pixel every time color characteristic or gradient it is special The square neighborhood window area of the 5*5 centered on P point is taken when sign.
The composite character of the image to be processed of building described in the present embodiment may include the color characteristic and ladder of pixel Feature is spent, the color characteristic and Gradient Features etc. can be carried out with the combination of predetermined format, form high-dimensional composite character Vector.During concrete implementation, the treatment process of the color characteristic that image slices vegetarian refreshments to be processed is calculated be can wrap It includes:
S101: if the image to be processed is not the data of Lab format, the data format of the image to be processed is turned Turn to Lab format;
S102: the pixel of neighborhood window W (p) in the image to be processed is extracted centered on pixel to be processed, by institute Tri- channels L, a, b for stating pixel in neighborhood window W (p) are respectively divided into K grouping, form the color feature vector of 3*K dimension;
S103: the color value by pixel each in the neighborhood window W (p) in tri- channels L, a, b is added to In dimension corresponding to the color feature vector, the color characteristic of pixel to be processed in the neighborhood window is formed.
It usually may include uniformly being quantified as in tri- channels L, a, b respectively in color of image feature extraction to be processed K grouping, guarantees the equal length of each grouping in each channel as far as possible.
The usual image to be processed can be the image information of RGB channel color model, the color mould in the channel Lab Type be often referred to based on people to color feeling establish and with light and device-independent color model, be more in line with the view of people Feel perception.The perception knot of people is thus more in line with using the body region from the image that Lab space detects in the present embodiment Fruit, so that the processing result that body region is extracted is more accurate.
In the present embodiment the channel Lab can be converted from RGB channel by the image to be processed.Usually the RGB is logical Road includes the three-dimensional color vector (R, G, B) of three variables, as follows:
R: red, 0~255 integer, changing value 256;
G: green, 0~255 integer, changing value 256;
B: blue, 0~255 integer, changing value 256.
The channel Lab may include three variables as follows:
L: brightness, 0~100 integer, changing value 100;
A: from green to red, -128~127 integer, changing value 256;
B: from blue to yellow, -128~127 integer, changing value 256.
It is described convert the channel Lab from RGB channel for image to be processed when, can be turned using given algorithm Change, can also be converted using the software tool such as Photoshop, be not discussed in detail herein.It then can be with preparatory The neighborhood window W (p) of setting extracts the pixel in the image to be processed in the channel Lab, will be in the neighborhood window W (p) Tri- channels L, a, b of pixel are uniformly quantified as K bin (grouping) respectively.It further can be by tri- channels L, a, b The value of pixel after quantization, which is stitched together, can form the color feature vector of 3*K dimension, such as the 3*K of the formation The color feature vector of dimension can be expressed as L1, L2 ... LK, a1, a2 ... aK, b1, b2 ... bK.Described in the present embodiment The value of K customized can be arranged, for indicating a description to color of image space to be processed.It is in the application if described The value of K is bigger than normal, then the image to be processed can be divided thinner in color space, color characteristic statement more subject to Really, time increase is calculated accordingly;If opposite K value value is smaller, then to the image to be processed color space entirety Division degree is lower, and color feature vector dimension is smaller, and data processing speed can be improved.By many experiments, the application is provided A kind of value range of K, the value of the specific K can be with are as follows: 6≤K≤16 can guarantee color in above-mentioned value range Feature vector can accurate and effective, suitably state the color characteristic of image to be processed.The value of the K in the present embodiment It can be with value for 6, it can construct the composite character vectors of 18 dimensions of pixel to be processed in the neighborhood window.It finally can be with Color value according to pixel each in the neighborhood window W (p) in tri- channels L, a, b, accumulates it the color characteristic In the corresponding dimension of vector.Such as it is had altogether in 25 pixel neighborhood of a point windows in 5*5, the Lab color of 25 pixels The color feature vector of common one 18 dimension of building of value.Specifically, each pixel can have one group in 25 pixels Lab color value, by taking the channel L as an example, it is assumed that the value in the channel L of the first pixel is 10, and it is total can to map that the channel L In 6 bin (grouping) divided altogether in a corresponding grouping, such as it is divided into L1.The L channel value of second pixel is 98, then it can be divided into L6.And so on, 25 pixels in the neighborhood window W (p) are all traversed one Time, the pixel to be processed in an available neighborhood window W (p) that adds up of the color value in corresponding bin (grouping) is total L, a, b color characteristic distribution vector.
It calculates and completes in current neighborhood window after the color feature vector of pixel to be processed, it can be according to certain orientation one Then one pixel of secondary displacement extracts the pixel of neighborhood window again in the manner described above, calculates in new neighborhood window The color feature vector of pixel to be processed.Successively be calculated the color characteristic of all pixels point in the image to be processed to Amount obtains the color characteristic of the image slices vegetarian refreshments to be processed.
It should be noted that the pixel to be processed in neighborhood window described herein be usually the setting just The central point of Square Neighborhood window.For the non-boundary point pixel in the image to be processed, one can be once being extracted just Rectangular neighborhood window.The pixel that square neighborhood window extracts cannot be met for boundary point or by interior points close to the boundary, then Still according to the pre-set extraction specification of the neighborhood window, it can with the boundary point pixel or by proximal border It is calculated centered on pixel, with the pixel that the neighborhood window actually covers in the image to be processed.Fig. 2 is this Apply for the schematic diagram that the image boundary vertex neighborhood window to be processed extracts.As shown in Figure 2, such as the neighborhood window of setting mentions Taking rule is the square area of 5*5, for the non-angle point of Mr. Yu's boundary point, using the pixel P1 of the boundary point as neighborhood The pixel specification that window center is extracted is 5*3, correspondingly, then extracting for the angle point P2 of the image to be processed The specification of pixel is 3*3.
Composite character described herein may include the Gradient Features of image to be processed.It can be used in the present embodiment HoG feature carries out Gradient Features extraction, forms the Gradient Features of each pixel M dimension in image to be processed.The usually ladder The meaning of degree may include the difference of each pixel and vicinity points in image, can be used for after being configured to Gradient Features Detect the unconspicuous region of color.Grayscale image can be converted from RGB color channel by image to be processed in the present embodiment, in this way Simplify the complexity of Gradient Features.Specifically Gradient Features extraction can be carried out using HoG feature on implementation, obtained pre- The gradient direction and gradient value of pixel in the neighborhood window W (p) being first arranged, then can be by packet in the neighborhood window W (p) The total gradient direction value for including all pixels point gradient direction is divided into M bin (grouping), such as by the total gradient direction of 180 degree 12 bin (grouping) are divided into, then what each bin represented is one 15 degree of range.It finally can be according to the neighborhood window The gradient value of each pixel, is added in corresponding bin (grouping) using the method for linear interpolation in mouth W (p), forms neighborhood The gradient eigenvector of the M dimension of pixel to be processed in window, such as the gradient eigenvectors of 12 dimensions in the present embodiment, Can be expressed as g1, g2 ... g12 }.If such as the gradient direction of certain point is in pixel neighborhood of a point window W (p) to be processed 44 degree, gradient value 10, then it is g3 that the gradient direction, which is bin (grouping) belonging to 44 degree, with aforementioned color characteristic calculating side Formula is similar, can be in grouping g3 belonging to 10 accumulated value of gradient value by 44 degree.Traverse the neighborhood window all pixels point The Gradient Features of the neighborhood window pixel to be processed are calculated in gradient direction and gradient value.Equally calculate a neighborhood A pixel can be shifted after window, continue the Gradient Features for calculating next pixel to be processed.It successively calculates and completes institute The Gradient Features for stating image all pixels point to be processed, are specifically referred to the calculation of above-mentioned color characteristic, herein not It repeats.
After the color characteristic and Gradient Features that the image slices vegetarian refreshments to be processed is calculated, it can construct described wait locate Manage the composite character vector of image.The composite character vector of the specific building image to be processed may include by described wait locate The K dimension color characteristic and M dimension Gradient Features of the reason each pixel of image are spliced and combined, and (K+M) for pixel is formed The composite character vector of dimension.Such as the color characteristic of 18 dimensions and the value of the Gradient Features of 12 dimensions can sequentially be spelled in the present embodiment Connect combination, before 18 dimension datas be color characteristic, behind 12 dimension datas be Gradient Features, can be expressed as L1, L2 ... L6, a1,a2,…a6,b1,b2,…b6,g1,g2,…g12}.Certainly, if the size of the image to be processed is [W, H], wherein W For the width of the image to be processed, H is the height of the image to be processed, and unit is pixel, then passing through above-mentioned side Method can construct the composite character vector of the image W*H to be processed (K+M) dimensions.
Consider to calculate when calculating the color characteristic and Gradient Features of pixel in this application and has arrived each pixel to be processed Point surrounding pixel point information, can more accurately establish the characteristic value of pixel so that when composite character space prospect and The distance of the composite character vector of two points similar in background area is greatly increased than the distance of color characteristic is only used only, can be with It is effective to distinguish region similar in foreground and background, improve the precision of body region detection.
S2: clustering the composite character vector, clustering after obtaining cluster.
Picture size to be processed described in aforementioned is that the commodity image of [W, H] can generate the composite characters of W*H (K+M) dimensions Vector.In order to improve computational efficiency in the application, these feature vectors can be clustered.Gather employed in the present embodiment It can be Kmeans clustering algorithm that class algorithm, which is adopted,.The specific operating process of Kmeans clustering algorithm mainly may include:
S201: L composite character vector is randomly selected in the composite character vector tieed up from the W*H (K+M) as just Beginning cluster centre.In the particular embodiment, the value range of the L can choose suitable value, the usual L through overtesting Value, which will lead to greatly very much, calculates that the time is longer, and L is too small, can not divide feature space relatively fine.
S202: traversing all W*K composite character vectors, calculates separately in each composite character vector and current cluster The distance between heart.It is Euclidean distance that distance described in the present embodiment, which uses, such as two composite character vectors are respectively p And q, wherein q is the current cluster centre randomly selected, then between the composite character vector and the current cluster centre q Euclidean distance D (p, q) can be with are as follows:
D (p, q)=| | (p1-q1)2+(p2-q2)2……+(p(K+M)-q(K+M))2||
S203: it for each composite character vector, calculates at a distance from its L initial cluster center with the selection, institute It states composite character vector and belongs to and cluster with the L initial cluster center apart from the smallest.It can be with after a wheel calculates classification Composite character vector is reasonably divided into the clustering of the nearest L initial cluster center of distance.
S204: the cluster centre each to cluster is updated.Pixel each in image to be processed is divided into corresponding cluster Afterwards, the cluster centre each to cluster can be updated.Specific more new calculation method may include that calculating is described every in the present embodiment It is a cluster in all composite character vectors it is every it is one-dimensional on average value, then by it is described be calculated per one-dimensional average value Cluster new cluster centre as this.
S201~S204 described above is the process once clustered, can cluster calculation is above-mentioned repeatedly is every in the application The step of division of a pixel clusters and update clusters center, until the cluster centre to cluster no longer carries out by a relatively large margin The number of mobile (amplitude threshold of the movement can be configured according to demand) or the cluster calculation reaches preset calculating Until it is required that.Specifically for example in the present embodiment, it is 1000 times that the composite character vector clusters number, which can be set, alternatively, Euclidean distance between the new cluster centre to cluster and the last cluster centre that clusters such as is expressed as one less than 0.5 Secondary cluster centre is Old_C, and new cluster centre is New_C, then the stop condition of cluster calculation can be set to D (Old_C,New_C)<0.5。
Composite character vector is clustered in the present embodiment, L is formed and clusters, it can will be in the image to be processed The composite character calculation amount of a large amount of pixels is contracted to the L calculating to cluster, can be improved subsequent image areas detection into one Computation rate is walked, general image information processing efficiency is improved.
S3: according to pre-defined rule calculate described in the probability that clusters that clusters, and clustered described in probability calculation based on described cluster The pixels probability of middle pixel.
After above-mentioned steps are handled, composite character vector that the image to be processed is tieed up at (K+M) described herein L has been clustered into space to cluster, wherein the L cluster in each cluster in pixel be phase on the feature space Close.The probability that clusters of body region can be belonged in the application for each cluster of unit calculating with each described cluster, then The pixel of the body region is further belonged to based on the middle all pixels point that clusters described in probability calculation of clustering to cluster Probability.It can be described using the significance each to cluster in the entire image to be processed in the present embodiment described each poly- Cluster belongs to the probability of body region.It is specific it is described according to pre-defined rule calculate described in the probability that clusters that clusters may include:
Calculate the L cluster in each cluster Ci with other cluster at a distance from and D (Ci), clustered and D (Ci) with described With all distances to cluster and the ratio of summation cluster as described in the probability that clusters of Ci.
Assume after cluster in the present embodiment the obtained L centers of clustering to cluster be respectively C1, C2 ..., CL, The significance that the present embodiment clusters can be using by indicating with the ratio of other all sum of the distance to cluster and summation.It is so right In arbitrarily clustering for Ci, 1≤i≤L, the present embodiment provides each cluster in clustering described in a kind of calculating with other cluster away from Method from sum, the specific Ci to cluster and other cluster at a distance from and D (Ci) following formula formula (1) can be used to calculate Out:
In above formula, L is the number to cluster, as be arranged in the present embodiment 120, | | ci, cj| | for clustering for the Ci that currently clusters The Euclidean distance of what composite character vector and other at center clustered cluster center composite character vector.In general, described two For composite character vector difference away from bigger, the Euclidean distance between two centers that cluster is bigger between clustering.If some clusters and other The Euclidean distance to cluster is all larger on the whole, and can indicating this to cluster, the difference conspicuousness to cluster with other is higher, then more having can Can be close to the body region of image to be processed, sum of the distance D (Ci) value to cluster with other being calculated accordingly is also bigger. Calculating in this embodiment joined factor Wj in the method for the distance sum, the Wj can currently cluster included by Ci according to Pixel setting weight.In the present embodiment in general, it is described cluster in include pixel number it is more, then its is right Answer the contribution of significant angle value also bigger.Therefore, the Wj can be configured according to pixel included in clustering.Such as it can To be set as the pixel number for clustering included, or currently cluster included pixel number and the image to be processed The ratio etc. of total pixel number, can specifically be configured according to demand.In this way, the distance that clusters described in the calculating and when The weight Wj to cluster described in addition counts pixel number included in described cluster, in application scenes It is more in line with the characteristic of real image body region, the calculated result in extraction master map region can be made in such application scenarios more It is accurate to add.
Obtain it is each cluster after the significance in the image to be processed, can be further according to the significance meter It calculates each to cluster and belongs to the probability that clusters of the body region.It can be gathered with D (Ci) with all with described cluster in the present embodiment The ratio of the summation of the distance sum of the cluster Ci that clusters as described in belongs to the probability that clusters of the body region, specifically can be with It is calculated using following formula (2):
∑ among the above1≤j≤LD(cj) it is the summation of all sums that cluster to cluster being calculated, it can be using currently clustering Distance and as described currently cluster belong to the probability that clusters of the body region with the ratio of the summation.After cluster The middle composite character vector value that clusters be closer to, in a kind of embodiment of the application it is considered that this cluster in pixel category It is equivalent to this in the pixels probability of body region and clusters to belong to the probability that clusters of body region, can be clustered in this way according to described Probability obtains a probability value of each pixel.Therefore, described based on the probability that clusters in a kind of embodiment of the application The pixels probability of middle pixel of clustering described in calculating may include:
S301: the pixels probability of the middle pixel that clusters can be the probability that clusters to cluster belonging to the pixel.
In the application other embodiments, cluster in pixel may be distributed in the image to be processed dispersion its In his region, the application is the compact nature with the body region extracted, and the body region of extraction is more accurate, Ke Yizai The secondary pixels probability for calculating each pixel in each cluster and belonging to body region.Here, the second neighborhood can be set in the application Window W (p) ', the mode for being referred to above-mentioned calculating color characteristic extract the second neighborhood window W centered on pixel P (p) ' pixel, the probability of some pixel q in the second neighborhood window W (p) ' are to cluster belonging to pixel q Cluster probability, is indicated herein with P (q), then described in another embodiment based on clustering described in the probability calculation to cluster in The probability that pixel belongs to the body region may include:
S302: extracting the pixel of the first neighborhood window W (p) ' centered on pixel p to be asked, and calculates institute using following formula State the pixels probability Sal (p) that pixel p to be asked belongs to the body region:
In above formula, P (q) belongs to the poly- of body region to cluster belonging to the pixel q in the first neighborhood window W (p) ' Cluster probability, t are the number for the middle pixel that clusters belonging to pixel p to be asked, and σ is a smoothing parameter of setting, can be indicated The size that the result of the pixel p currently calculated is influenced by surrounding pixel point.If σ value is larger, it can indicate pixel p's Calculated result is easy to be influenced by surrounding pixel point, otherwise is not readily susceptible to the influence of surrounding pixel point.The σ value can be according to warp It tests or estimating for result is rationally arranged, for the image of website product sale, σ can be inclined with value It is small, such as specifically can be with value for 0.17 in the present embodiment.If the image (usually noncommodity image) under natural scene, The value of the σ can be bigger than normal, such as can be with value for 0.25.
The setting of the first neighborhood window W (p) ' can be with the neighborhood that is arranged when aforementioned color feature extracted among the above Window is identical, such as can be set to the square neighborhood window of 5*5.In this way, the pixel in calculating the image to be processed Pixels probability when can be calculated wait the first neighborhood window W (p) ' described centered on seeking pixel such as pixel of 5*5, Traverse all pixels point in the first neighborhood window W (p) ' probability can be calculated the pixel p to be asked belong to it is described The pixels probability of body region.
Belong to body region method for calculating probability by pixel described in above-mentioned S302, can be calculated described wait locate Each pixel belongs to the pixels probability of body region in reason image, and the probability value uses the first neighborhood window W (p) ' the probability value progress smoothing computation of pixel obtains in, and the accuracy of final extraction result can be improved.
S4: detecting the image to be processed based on the pixels probability, obtains target area.
After calculating the completion each pixel of image to be processed and belonging to the pixels probability of the body region, it can carry out The target area obtained in the image to be processed is extracted in the separation of body region and background area.Mesh described herein Marking region can be the body region (foreground area) in the image to be processed, in other examples, the target area Domain may be background area, it can detection obtains the background area of image to be processed, in a kind of embodiment of the application, institute State based on the pixels probability to the image to be processed carry out detection obtain target area specifically may include:
S401: the pixel that the pixels probability value of pixel in the image to be processed meets judgment threshold PV requirement is made For the target area of the image to be processed.
Specifically for example in the implementation process of detection body region, such as the judgement of pixel probability can be preset Then the value of the pixels probability of pixel described in the image to be processed can be greater than 0.85 pixel by threshold value PV such as 0.85 Point extracts, the body region as the image to be processed.Herein described preset judgment threshold value value is too small to be will lead to The pixel of more non-master body region is extracted, value is excessive, the integrality of the body region image extracted can be reduced, this Embodiment provides a kind of value range of judgment threshold, and the value range of the specific preset judgment threshold value PV can be with Are as follows: 0.8≤PV≤0.95.The preferred mode of the pixels probability of pixel described in above-mentioned S401 is to use the first neighborhood window The probability value of pixel carries out the probability value that smoothing computation obtains in mouth W (p) '.
Certainly, in the embodiment of detection background area, the judgment threshold PV for meeting and being judged as background area can be set Value, can be specifically determined according to actual scene application.
The application also provides another preferred embodiment, described to be based on the pixel in another embodiment The pixels probability of point carries out detection acquisition target to the image to be processed
S4021: the probability value that pixel in the image to be processed belongs to body region is greater than to the picture of first threshold PF Vegetarian refreshments is as sub-pixel point;
S4022: the Euclidean distance with pixel in the second neighborhood of surrounding window is calculated centered on the sub-pixel point;
S4023: the Euclidean distance is less than the pixel of second threshold as new sub-pixel point;
S2044: the Euclidean distance of pixel in the second neighborhood window described in all sub-pixel points of traversal and surrounding And judge, using the sub-pixel point being calculated as the target area of the image to be processed.
In the present embodiment, the pixels probability that the pixel belongs to body region preferably can be for belonging to the pixel The probability that clusters to cluster.In addition, the first threshold PF and second threshold and the third neighborhood window can be according to realities Border data processing needs are configured, such as the first valve PF value equally can be set to 0.85 or be chosen for the probability that clusters The higher value of intermediate value, the second threshold can be set to 0.5.Such as above-mentioned preset judgment threshold value, herein described first threshold PF value is too small to will lead to the pixel for extracting more non-master body region, and value is excessive, can reduce the body region extracted The integrality of image, the present embodiment provides the value range of first threshold PF a kind of, the specific first threshold PF's Value range can be with are as follows: 0.8≤PF≤0.95.Third neighborhood window described in the present embodiment is general for sub-pixel point Centered on 3*3 eight adjacent windows, then can according to it is described herein such as 30 dimension feature composite character vector into Row Euclidean distance calculates.If the distance meets second threshold requirement, can be wanted second threshold is met around the seed The pixel asked is as new sub-pixel point, it is believed that the new sub-pixel point for meeting the second threshold requirement is same Belong to body region.Certainly, during processing, the pixel using the third neighborhood window is unsatisfactory for can be set as back Scene area.It should be noted that body region described herein is usually to be connected to, it, can be in other application scenarios Background area is set as by the pixel that second threshold judged is not passed through.It can be biggish according to probability value in the present embodiment Then pixel constantly traverses the neighbor point of surrounding and judges, finally obtain body region as sub-pixel point.
Certainly, after the herein described pixels probability based on the pixel, the mode for obtaining target area may include But it is not limited to embodiment described herein, other other processing based on method described herein without creative work Method carries out body region and background area point still in application range described herein, such as using geodesic curve distance algorithm The body region obtained from extraction.
A kind of image region detection method provided by the present application is constructed including pixel color characteristic and Gradient Features Composite character vector can more accurately establish the characteristic value of pixel, can effectively distinguish similar in foreground and background The precision that body region is extracted is improved in region.Likewise, in complex background image, composite character described herein to Amount can be very good color combining feature and Gradient Features and the pixel of the pixel of prospect and background be described to two differences Cluster, can be easy to separate the two when Euclidean distance calculates.Composite character is clustered in the application, is obtained After clustering using it is described cluster with other cluster distance and with the ratio of summation as the significance to cluster, belong to for stating to cluster The probability of body region, the case where being more in line with commodity body in actual user's perceptual image so that processing result it is more accurate, Effectively.In actual application, the standard in image subject region to be processed is extracted using herein described body region extracting method True rate has reached 89.62%, and recall rate has reached 88.83%, solves master when facing the high image of complexity in the prior art Body region extracts the low problem of accuracy rate.
Fig. 3, Fig. 4 are showing using a kind of image region detection method progress body region extraction described herein respectively It is intended to, Fig. 3, Fig. 4 are from left to right that image, existing algorithm extraction result and the present invention to be processed extract result respectively.Such as Fig. 3 institute Show, selection is the very similar image of a foreground and background field color, and existing algorithm is being handled as can see from Figure 3 Part highlighted among the clothes can not be detected when such image, because color herein is very close to the white of background Color.And the composite character vector of (K+M) dimension of the application can effectively distinguish similar foreground and background region.Fig. 4 What is chosen is the situation of background complexity, and existing algorithm is being difficult to essence on the higher image of complexity as can see from Figure 4 Main body is really extracted, herein described method obtains to cluster using cluster calculates the pixels probability that pixel belongs to body region, can Effectively to solve the problems, such as that not only the very high image subject of complexity is extracted in color simultaneously structure in background, greatly improves detection Precision.
Based on a kind of image region detection method described herein, the application also provides a kind of image-region detection dress It sets.Fig. 5 is a kind of modular structure schematic diagram of herein described image-region detection device, as shown in figure 5, described device can be with Include:
Feature calculation module 101 can be used for being calculated the color characteristic and Gradient Features of image slices vegetarian refreshments to be processed, And construct the composite character vector of the image to be processed;
Cluster module 102 can be used for clustering the composite character vector, clustering after obtaining cluster;
Cluster probabilistic module 103, can be used for according to pre-defined rule calculate described in the probability that clusters that clusters;
Pixels probability module 104 can be used for the pixel based on the middle pixel that clusters described in the probability calculation to cluster Probability;
Detection module 105 can be used for detecting the image to be processed based on the pixels probability, obtain target Region.
In the specific implementation process, the feature calculation module 101 is segmented into multiple submodule and carries out phase respectively Answer the processing of process.Fig. 6 is a kind of a kind of modular structure schematic diagram of embodiment of herein described feature calculation module 101, such as Shown in Fig. 6, the feature calculation module 101 can be configured to include:
Color-feature module 1011 can be used for calculating the color characteristic of the image slices vegetarian refreshments to be processed;
Gradient Features module 1012 can be used for calculating the Gradient Features of the image slices vegetarian refreshments to be processed;
Composite character module 1013 can be used for combining the color characteristic and Gradient Features, form image to be processed Composite character vector.
Fig. 7 is a kind of a kind of modular structure schematic diagram of embodiment of herein described feature calculation module 1011, such as Fig. 7 institute Show, the color-feature module 1011 may include:
Lab conversion module 111 can be used for converting the image to be processed to the data of Lab format;
Color feature vector module 112 can be used for centered on pixel to be processed extracting adjacent in the image to be processed Tri- channels L, a, b of pixel in the neighborhood window are respectively divided into K grouping by the pixel of domain window, form 3*K dimension Color feature vector;
Feature calculation module 113 can be used for each pixel in the neighborhood window in tri- channels described L, a, b Color value be added in dimension corresponding to the color feature vector, form the face of pixel to be processed in the neighborhood window Color characteristic.
By above-mentioned resume module, the color characteristic of available image to be processed.The application provides for the device A kind of value range of K, the value of the specific K can be with are as follows: 6≤K≤16 can guarantee this Shen in above-mentioned value range Please device extract color feature vector it is accurate and effective, suitably state the color characteristic of image to be processed.
The probabilistic module 103 that clusters in device described above calculates described cluster and belongs to the probability of body region, specifically may be used To include:
Distance and computing module, can be used for calculating each cluster in described cluster with other cluster at a distance from and;
Cluster probability evaluation entity, can be used for clustering according to and with all distances to cluster and summation meter The probability that clusters to cluster described in calculation.
In a kind of a kind of preferred embodiment of herein described image-region detection device, the distance calculation module is calculated It is described cluster in each cluster with other cluster at a distance from and specifically may include:
Using following formula calculate described in cluster in each cluster with other cluster at a distance from and D (Ci):
In above formula, L is the number to cluster, | | ci, cj| | for the composite character vector at the center that clusters for the Ci that currently clusters and its The Euclidean distance of what he clustered cluster center composite character vector, Wj is what the pixel according to the Ci that currently clusters included by was arranged Weight.
Fig. 8 is a kind of a kind of modular structure schematic diagram of embodiment of herein described pixels probability module 104, such as Fig. 8 institute Show, the pixels probability module 104 may include at least one of following:
First probabilistic module 1041, the probability that clusters that can be used for cluster belonging to pixel is as the pixel of the pixel Probability;
Second probabilistic module 1042 can be used for extracting the picture of the first neighborhood window W (p) ' centered on pixel p to be asked Vegetarian refreshments calculates the pixels probability Sal (p) of the pixel p to be asked using following formula:
In above formula, P (q) belongs to the general of body region to cluster belonging to the pixel q in the first neighborhood window W (p) ' Rate, t are the number for the middle pixel that clusters belonging to pixel p to be asked, and σ is a smoothing parameter of setting.
The extraction module 105 can take pre-set different extracting mode to extract the body region of image to be processed Domain.Specifically may include at least one of following modules:
First extraction module can be used for the pixels probability value of pixel in the image to be processed meeting judgment threshold Target area of the pixel that PV is required as the image to be processed;
Second extraction module can be used for for the probability value that pixel belongs to body region in the image to be processed being greater than The PF pixel of first threshold is as sub-pixel point;It can be also used for calculating centered on the sub-pixel point and surrounding the The Euclidean distance of pixel in two neighborhood windows;Can be also used for using the Euclidean distance be less than second threshold pixel as New sub-pixel point;It can be also used for traversing pixel in the second neighborhood window described in all sub-pixel points and surrounding Euclidean distance and judge, using the sub-pixel point being calculated as the target area of the image to be processed.
In a kind of image-region detection device described above, the value range of the judgment threshold PV can be with are as follows: 0.8≤ PV≤0.95;
And/or
The value range of the first threshold PF can be with are as follows: 0.8≤PF≤0.95.
The value range of judgment threshold PV or first threshold PF provided in this embodiment, can be effectively ensured body region Correct, the validity extracted improve the accuracy of the higher image-region detection of the especially described complexity of image.
It, can be multiple for separating in flatbed electric business website using a kind of image-region detection device described herein Body region and background area in miscellaneous changeable commodity image, can successfully manage the feelings of various complexity in real image scene Condition, realization carry out accurate and effective separation to body region in complicated image, improve image detection accuracy.
A kind of image-region detection device described herein can be used in multiple terminal equipment, such as user is mobile The stingy figure application of client, either dedicated for image subject or the client or server of background area extraction.In general, Described image detection device is carrying out image detection, can be by the image of the target area of the acquisition after obtaining target area User is saved or is shown to be further processed.The application provides a kind of image-region detection device, can be applicable in In processing user or the image of client, image detection is carried out, obtains target area.Specifically, described device can be set It is set to, comprising:
First processing units can be used for obtaining the image to be processed at users/customers end, image slices to be processed be calculated The color characteristic and Gradient Features of vegetarian refreshments construct the composite character vector of the image to be processed;
The second processing unit can be used for clustering the composite character vector, clustering after obtaining cluster;May be used also With for according to pre-defined rule calculate described in the probability that clusters that clusters, and based on the middle pixel that clusters described in probability calculation that clusters The pixels probability of point;
Output unit can be used for carrying out acquisition target area to the image to be processed based on the pixels probability, and By the target area storage of the acquisition or it is showed in designated position.
Image provided in this embodiment goes detection device, can effectively, accurately extract in client or server Client picture processing user experience or client/server image information can be improved in the target area of picture to be processed The accuracy of processing.
Although mentioning the conversion of different images format, the calculating of clustering method, given formula or the like in teachings herein Description, still, the application be not limited to must be complete standard format conversion, clustering method or provided by the present application solid The case where determining formula.Foregoing description involved in each embodiment is only answering in some embodiments in the application in the application With processing method modified slightly can also carry out each embodiment of above-mentioned the application on the basis of certain standards, method Scheme.Certainly, to meet process method step described in the application the various embodiments described above other without creative change Identical application still may be implemented in shape, and details are not described herein.
The unit or module that above-described embodiment illustrates can specifically realize by computer chip or entity, or by having The product of certain function is realized.For convenience of description, it is divided into various modules when description apparatus above with function to describe respectively. Certainly, the function of each module can be realized in the same or multiple software and or hardware when implementing the application, it can also be with The module for realizing same function is realized by the combination of multiple submodule or subelement.
This neighborhood technique personnel are complete also, it is understood that other than realizing controller in a manner of pure computer readable program code Entirely can by by method and step carry out programming in logic come so that controller with logic gate, switch, specific integrated circuit, programmable Logic controller realizes identical function with the form for being embedded in microcontroller etc..Therefore this controller is considered one kind Hardware component, and the structure that the device for realizing various functions that its inside includes can also be considered as in hardware component.Or Person even, can will be considered as realizing the device of various functions either the software module of implementation method can be hardware again Structure in component.
The application can describe in the general context of computer-executable instructions executed by a computer, such as program Module.Generally, program module includes routines performing specific tasks or implementing specific abstract data types, programs, objects, group Part, data structure, class etc..The application can also be practiced in a distributed computing environment, in these distributed computing environments, By executing task by the connected remote processing devices of communication network.In a distributed computing environment, program module can To be located in the local and remote computer storage media including storage equipment.
As seen through the above description of the embodiments, the technical staff of this neighborhood can be understood that the application can It realizes by means of software and necessary general hardware platform.Based on this understanding, the technical solution essence of the application On in other words the part that contributes to existing technology can be embodied in the form of software products, the computer software product It can store in storage medium, such as ROM/RAM, magnetic disk, CD, including some instructions are used so that a computer equipment (can be personal computer, mobile terminal, server or the network equipment etc.) executes each embodiment of the application or implementation Method described in certain parts of example.
Each embodiment in this specification is described in a progressive manner, the same or similar portion between each embodiment Dividing may refer to each other, and each embodiment focuses on the differences from other embodiments.The application can be used for crowd In mostly general or special purpose computing system environments or configuration.Such as: personal computer, server computer, handheld device or Portable device, laptop device, multicomputer system, microprocessor-based system, programmable electronic equipment, network PC, minicomputer, mainframe computer, distributed computing environment including any of the above system or equipment etc..
Although depicting the application by embodiment, this neighborhood those of ordinary skill knows, the application there are many deformation and Variation is without departing from spirit herein, it is desirable to which the attached claims include these deformations and change without departing from the application's Spirit.

Claims (19)

1. a kind of image region detection method, which is characterized in that the described method includes:
The color characteristic and Gradient Features of image slices vegetarian refreshments to be processed is calculated, constructs the composite character of the image to be processed Vector;
The composite character vector is clustered, clustering after obtaining cluster;
According to pre-defined rule calculate described in the probability that clusters that clusters, and based on the middle pixel that clusters described in probability calculation that clusters Pixels probability;
The image to be processed is detected based on the pixels probability, obtains target area.
2. a kind of image region detection method as described in claim 1, which is characterized in that described that image to be processed is calculated The color characteristic of pixel includes:
If the image to be processed is not the data of Lab format, Lab lattice are converted by the data format of the image to be processed Formula;
The pixel that neighborhood window in the image to be processed is extracted centered on pixel to be processed, by picture in the neighborhood window Tri- channels L, a, b of vegetarian refreshments are respectively divided into K grouping, form the color feature vector of 3*K dimension;
Color value by each pixel in the neighborhood window in tri- channels L, a, b be added to the color characteristic to In the corresponding dimension of amount, the color characteristic of pixel to be processed in the neighborhood window is formed.
3. a kind of image region detection method as claimed in claim 2, which is characterized in that the value of the K are as follows: 6≤K≤ 16。
4. a kind of image region detection method as described in claim 1, which is characterized in that described to be calculated according to pre-defined rule The probability that clusters to cluster includes:
Each cluster in clustering described in calculating with other cluster at a distance from and, with it is described cluster and with all distances to cluster What the ratio of the summation of sum clustered as described in cluster probability.
5. a kind of image region detection method as claimed in claim 4, which is characterized in that each in clustering described in the calculating Cluster with other cluster at a distance from and include:
Using following formula calculate described in cluster in each cluster with other cluster at a distance from and D (Ci):
In above formula, L is the number to cluster, | | ci, cj| | the composite character vector for the center that clusters for the Ci that currently clusters is poly- with other The Euclidean distance of the center composite character vector that clusters of cluster, Wj are the power of the setting of the pixel according to included by the Ci that currently clusters Weight.
6. a kind of image region detection method as described in claim 1, which is characterized in that based on the probability that clusters described in The pixels probability of middle pixel of clustering described in calculation includes:
The pixels probability of the middle pixel that clusters is the probability that clusters to cluster belonging to the pixel.
7. a kind of image region detection method as described in claim 1, which is characterized in that based on the probability that clusters described in The pixels probability of middle pixel of clustering described in calculation includes:
The pixel that the first neighborhood window W (p) ' is extracted centered on pixel p to be asked calculates the pixel to be asked using following formula The pixels probability Sal (p) of point p:
In above formula, P (q) is the probability that clusters to cluster belonging to the pixel q in the first neighborhood window W (p) ', and t is pixel to be asked Cluster the number of middle pixel belonging to point p, and σ is the smoothing parameter of setting.
8. a kind of image region detection method as described in claim 1, which is characterized in that described to be based on the pixels probability pair The image to be processed carries out detection acquisition target area
Using the pixels probability value of pixel in the image to be processed meet judgment threshold PV requirement pixel as described in Handle the target area of image;
Alternatively,
Pixel using the probability value of pixel in the image to be processed greater than first threshold PF is as sub-pixel point;
The Euclidean distance with pixel in the second neighborhood of surrounding window is calculated centered on the sub-pixel point;
The Euclidean distance is less than the pixel of second threshold as new sub-pixel point;
It traverses the Euclidean distance of all sub-pixel points and pixel in the second neighborhood window described in surrounding and judges, Using the sub-pixel point being calculated as the target area of the image to be processed.
9. a kind of image region detection method as claimed in claim 8, which is characterized in that the value model of the judgment threshold PV It encloses are as follows: 0.8≤PV≤0.95;
Alternatively,
The value range of the first threshold PF are as follows: 0.8≤PF≤0.95.
10. a kind of image-region detection device, which is characterized in that described device includes:
Feature calculation module, for the color characteristic and Gradient Features of image slices vegetarian refreshments to be processed to be calculated, and described in building The composite character vector of image to be processed;
Cluster module, for being clustered to the composite character vector, clustering after obtaining cluster;
Cluster probabilistic module, for according to pre-defined rule calculate described in the probability that clusters that clusters;
Pixels probability module, for based on the pixels probability of middle pixel of clustering described in probability calculation that clusters;
Detection module obtains target area for detecting based on the pixels probability to the image to be processed.
11. a kind of image-region detection device as claimed in claim 10, which is characterized in that the feature calculation module packet It includes:
Color-feature module, for calculating the color characteristic of the image slices vegetarian refreshments to be processed;
Gradient Features module, for calculating the Gradient Features of the image slices vegetarian refreshments to be processed;
Composite character module, for the color characteristic and Gradient Features to be combined, formed the composite character of image to be processed to Amount.
12. a kind of image-region detection device as claimed in claim 11, which is characterized in that the color-feature module packet It includes:
Lab conversion module, for converting the image to be processed to the data of Lab format;
Color feature vector module, for extracting the pixel of neighborhood window in the image to be processed centered on pixel to be processed Tri- channels L, a, b of pixel in the neighborhood window are respectively divided into K grouping by point, formed the color characteristic of 3*K dimension to Amount;
Feature calculation module is tired out for the color value by each pixel in the neighborhood window in tri- channels L, a, b It is added in dimension corresponding to the color feature vector, forms the color characteristic of pixel to be processed in the neighborhood window.
13. a kind of image-region detection device as claimed in claim 12, which is characterized in that the color feature vector module The value range of middle K are as follows: 6≤K≤16.
14. a kind of image-region detection device as claimed in claim 10, which is characterized in that the probabilistic module packet that clusters It includes:
Distance and computing module, for calculate each cluster in described cluster with other cluster at a distance from and;
Cluster probability evaluation entity, for cluster according to and with all distances to cluster and summation calculate it is described poly- The probability that clusters of cluster.
15. a kind of image-region detection device as claimed in claim 14, which is characterized in that the distance calculation module calculates It is described cluster in each cluster with other cluster at a distance from and include:
Using following formula calculate described in cluster in each cluster with other cluster at a distance from and D (Ci):
In above formula, L is the number to cluster, | | ci, cj| | the composite character vector for the center that clusters for the Ci that currently clusters is poly- with other The Euclidean distance of the center composite character vector that clusters of cluster, Wj are the power of the setting of the pixel according to included by the Ci that currently clusters Weight.
16. a kind of image-region detection device as claimed in claim 10, which is characterized in that the pixels probability module includes It is at least one of following:
First probabilistic module, for using the probability that clusters to cluster belonging to pixel as the pixels probability of the pixel;
Second probabilistic module, for extracting the pixel of the first neighborhood window W (p) ' centered on pixel p to be asked, under Formula calculates the pixels probability Sal (p) of the pixel p to be asked:
In above formula, P (q) belongs to the probability of body region, t to cluster belonging to the pixel q in the first neighborhood window W (p) ' For the number for the middle pixel that clusters belonging to pixel p to be asked, σ is the smoothing parameter of setting.
17. a kind of image-region detection device as claimed in claim 10, which is characterized in that the detection module includes following At least one of module:
First extraction module, for the pixels probability value of pixel in the image to be processed to be met judgment threshold PV requirement Target area of the pixel as the image to be processed;
Second extraction module, the probability value for pixel in the image to be processed to be belonged to body region are greater than first threshold The pixel of PF is as sub-pixel point;It is also used to centered on the sub-pixel point in calculating and the second neighborhood of surrounding window The Euclidean distance of pixel;It is also used to the Euclidean distance being less than the pixel of second threshold as new sub-pixel point; It is also used to traverse the Euclidean distance of all sub-pixel points and pixel in the second neighborhood window described in surrounding and makes and sentence It is disconnected, using the sub-pixel point being calculated as the target area of the image to be processed.
18. a kind of image-region detection device as claimed in claim 17, which is characterized in that the value of the judgment threshold PV Range are as follows: 0.8≤PV≤0.95;
And/or
The value range of the first threshold PF are as follows: 0.8≤PF≤0.95.
19. a kind of image-region detection device, which is characterized in that described device is configured to, comprising:
The face of image slices vegetarian refreshments to be processed is calculated for obtaining the image to be processed at users/customers end in first processing units Color characteristic and Gradient Features construct the composite character vector of the image to be processed;
The second processing unit, for being clustered to the composite character vector, clustering after obtaining cluster;It is also used to according to pre- Set pattern then calculate described in the probability that clusters that clusters, and based on it is described cluster cluster described in probability calculation middle pixel pixel it is general Rate;
Output unit for carrying out acquisition target area to the image to be processed based on the pixels probability, and is obtained described The target area taken stores or is showed in designated position.
CN201510075465.8A 2015-02-12 2015-02-12 A kind of image region detection method and device Active CN105989594B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201510075465.8A CN105989594B (en) 2015-02-12 2015-02-12 A kind of image region detection method and device
PCT/CN2016/073274 WO2016127883A1 (en) 2015-02-12 2016-02-03 Image area detection method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510075465.8A CN105989594B (en) 2015-02-12 2015-02-12 A kind of image region detection method and device

Publications (2)

Publication Number Publication Date
CN105989594A CN105989594A (en) 2016-10-05
CN105989594B true CN105989594B (en) 2019-02-12

Family

ID=56614213

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510075465.8A Active CN105989594B (en) 2015-02-12 2015-02-12 A kind of image region detection method and device

Country Status (2)

Country Link
CN (1) CN105989594B (en)
WO (1) WO2016127883A1 (en)

Families Citing this family (44)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108961316B (en) * 2017-05-23 2022-05-31 华为技术有限公司 Image processing method and device and server
CN108389205B (en) * 2018-03-19 2022-10-25 北京航空航天大学 Rail foreign matter monitoring method and device based on air-based platform image
CN108520259B (en) * 2018-04-13 2021-05-25 国光电器股份有限公司 Foreground target extraction method, device, equipment and storage medium
CN111178118B (en) * 2018-11-13 2023-07-21 浙江宇视科技有限公司 Image acquisition processing method, device and computer readable storage medium
CN109611916B (en) * 2018-12-06 2020-08-04 绍兴京越智能科技有限公司 Smoking gear automatic adjustment platform
CN109815762B (en) * 2018-12-29 2022-02-11 福建天泉教育科技有限公司 Method and storage medium for remotely identifying two-dimensional code
CN110334936B (en) * 2019-06-28 2023-09-29 创新先进技术有限公司 Method, device and equipment for constructing credit qualification scoring model
CN110610438B (en) * 2019-09-16 2022-02-15 黑龙江八一农垦大学 Crop canopy petiole included angle calculation method and system
CN110689478B (en) * 2019-09-25 2023-12-01 北京字节跳动网络技术有限公司 Image stylization processing method and device, electronic equipment and readable medium
CN113627453A (en) * 2020-05-08 2021-11-09 珠海金山办公软件有限公司 Pure-color background image matting method and device and electronic equipment
CN111726476B (en) * 2020-07-06 2022-05-31 北京字节跳动网络技术有限公司 Image processing method, device, equipment and computer readable medium
CN113920528A (en) * 2020-07-08 2022-01-11 顺丰科技有限公司 Subject object detection method and device, computer equipment and storage medium
CN111862244A (en) * 2020-07-16 2020-10-30 安徽慧视金瞳科技有限公司 Plastic sheet intelligent color sorting method based on image processing
CN111862084B (en) * 2020-07-31 2024-02-02 东软教育科技集团有限公司 Image quality evaluation method, device and storage medium based on complex network
CN113034509A (en) * 2021-02-26 2021-06-25 北京达佳互联信息技术有限公司 Image processing method and device
CN113034454B (en) * 2021-03-16 2023-11-24 上海交通大学 Underwater image quality evaluation method based on human visual sense
CN113052922B (en) * 2021-03-26 2023-03-14 重庆紫光华山智安科技有限公司 Bare soil identification method, system, device and medium
CN113077308B (en) * 2021-03-30 2022-03-22 张雨钊 Intelligent visual commercial transaction platform
CN113298829B (en) * 2021-06-15 2024-01-23 Oppo广东移动通信有限公司 Image processing method, device, electronic equipment and computer readable storage medium
CN114445483B (en) * 2022-01-28 2023-03-24 泗阳三江橡塑有限公司 Injection molding part quality analysis method based on image pyramid
CN114663316B (en) * 2022-05-17 2022-11-04 深圳市普渡科技有限公司 Method for determining edgewise path, mobile device and computer storage medium
CN114827711B (en) * 2022-06-24 2022-09-20 如你所视(北京)科技有限公司 Image information display method and device
CN115115893B (en) * 2022-07-26 2023-01-31 金乡县富通金属回收有限公司 Intelligent sorting method for waste metal recovery
CN115496760B (en) * 2022-11-17 2023-04-07 澳润(山东)药业有限公司 Donkey-hide gelatin quality identification method
CN115526890B (en) * 2022-11-25 2023-03-24 深圳市腾泰博科技有限公司 Method for identifying fault factors of record player head
CN115661669B (en) * 2022-12-13 2023-03-21 山东省土地发展集团有限公司 Method and system for monitoring illegal farmland occupancy based on video monitoring
CN115861301B (en) * 2023-02-16 2023-05-16 山东百成新材料科技股份有限公司 Multi-material uniformity visual evaluation method for modified asphalt production
CN116092013B (en) * 2023-03-06 2023-06-09 广东汇通信息科技股份有限公司 Dangerous road condition identification method for intelligent monitoring
CN116205923B (en) * 2023-05-06 2023-07-14 威海锐鑫丰金属科技有限公司 Nondestructive testing method for internal defects of automobile hub based on X-RAY
CN116309577B (en) * 2023-05-19 2023-08-04 山东晨光胶带有限公司 Intelligent detection method and system for high-strength conveyor belt materials
CN116645354A (en) * 2023-06-02 2023-08-25 江西绿萌科技控股有限公司 Multifunctional sorting system-oriented surface flaw image detection method
CN116385434B (en) * 2023-06-02 2023-08-08 同济检测(济宁)有限公司 Intelligent detection method for precast beam cracks
CN116740809B (en) * 2023-06-05 2024-03-29 嘉兴米兰映像家具有限公司 Intelligent sofa control method based on user gesture
CN116485819B (en) * 2023-06-21 2023-09-01 青岛大学附属医院 Ear-nose-throat examination image segmentation method and system
CN116503404B (en) * 2023-06-27 2023-09-01 梁山县创新工艺品股份有限公司 Plastic toy quality detection method and device, electronic equipment and storage medium
CN116824168B (en) * 2023-08-29 2023-11-21 青岛市中医医院(青岛市海慈医院、青岛市康复医学研究所) Ear CT feature extraction method based on image processing
CN116977329B (en) * 2023-09-21 2023-12-08 江苏惠汕新能源集团有限公司 Photovoltaic grid line detection method based on machine vision
CN117011303B (en) * 2023-10-08 2024-01-09 泰安金冠宏油脂工业有限公司 Oil production quality detection method based on machine vision
CN117115494B (en) * 2023-10-23 2024-02-06 卡松科技股份有限公司 Lubricating oil impurity pollution detection method and device based on artificial intelligence
CN117173164B (en) * 2023-11-02 2023-12-26 江苏君杰新能源有限公司 Grid line detection method of solar cell panel
CN117237384B (en) * 2023-11-16 2024-02-02 潍坊科技学院 Visual detection method and system for intelligent agricultural planted crops
CN117333484B (en) * 2023-11-30 2024-02-20 山东罗斯夫新材料科技有限公司 Method for detecting acrylic emulsion production wastewater based on image processing
CN117520102B (en) * 2024-01-04 2024-04-26 广州大一互联网络科技有限公司 Intelligent energy consumption monitoring method for IDC data center
CN117635507B (en) * 2024-01-26 2024-04-09 深圳市精森源科技有限公司 Plastic particle online visual detection method and system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101447076A (en) * 2008-12-02 2009-06-03 浙江大学 Method for partitioning interested areas in WEB image
CN102842135A (en) * 2012-07-17 2012-12-26 杭州淘淘搜科技有限公司 Method of detecting main body area of product image
CN102867313A (en) * 2012-08-29 2013-01-09 杭州电子科技大学 Visual saliency detection method with fusion of region color and HoG (histogram of oriented gradient) features
CN103824283A (en) * 2014-01-22 2014-05-28 西安电子科技大学 Large-area topographic map segmentation method based on random probability sampling and multi-level fusion
CN104217438A (en) * 2014-09-19 2014-12-17 西安电子科技大学 Image significance detection method based on semi-supervision
CN104268595A (en) * 2014-09-24 2015-01-07 深圳市华尊科技有限公司 General object detecting method and system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7039239B2 (en) * 2002-02-07 2006-05-02 Eastman Kodak Company Method for image region classification using unsupervised and supervised learning
US9025868B2 (en) * 2013-02-27 2015-05-05 Sony Corporation Method and system for image processing to determine a region of interest

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101447076A (en) * 2008-12-02 2009-06-03 浙江大学 Method for partitioning interested areas in WEB image
CN102842135A (en) * 2012-07-17 2012-12-26 杭州淘淘搜科技有限公司 Method of detecting main body area of product image
CN102867313A (en) * 2012-08-29 2013-01-09 杭州电子科技大学 Visual saliency detection method with fusion of region color and HoG (histogram of oriented gradient) features
CN103824283A (en) * 2014-01-22 2014-05-28 西安电子科技大学 Large-area topographic map segmentation method based on random probability sampling and multi-level fusion
CN104217438A (en) * 2014-09-19 2014-12-17 西安电子科技大学 Image significance detection method based on semi-supervision
CN104268595A (en) * 2014-09-24 2015-01-07 深圳市华尊科技有限公司 General object detecting method and system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Salient Region Detection by Modeling Distributions of Color and Orientation;Viswanath Gopalakrishnan 等;《IEEE Transactions on Multimedia》;20091231;第11卷(第5期);全文
融合颜色属性和空间信息的显著性物体检测;徐丹等;《中国图象图形学报》;20140407;第19卷(第4期);全文

Also Published As

Publication number Publication date
CN105989594A (en) 2016-10-05
WO2016127883A1 (en) 2016-08-18

Similar Documents

Publication Publication Date Title
CN105989594B (en) A kind of image region detection method and device
US11030782B2 (en) Accurately generating virtual try-on images utilizing a unified neural network framework
US9741137B2 (en) Image-based color palette generation
US9396560B2 (en) Image-based color palette generation
US10831819B2 (en) Hue-based color naming for an image
TWI559242B (en) Visual clothing retrieval
CN101763429B (en) Image retrieval method based on color and shape features
US9633448B1 (en) Hue-based color naming for an image
JP5797789B2 (en) Method and system for quasi-duplicate image retrieval
CN106898026B (en) A kind of the dominant hue extracting method and device of picture
CN105426850A (en) Human face identification based related information pushing device and method
CN108388882A (en) Based on the gesture identification method that the overall situation-part is multi-modal RGB-D
CN110782466B (en) Picture segmentation method, device and system
CN113301409B (en) Video synthesis method and device, electronic equipment and readable storage medium
CN108510013A (en) The steady tensor principal component analytical method of improvement based on low-rank kernel matrix
CN113408590B (en) Scene recognition method, training method, device, electronic equipment and program product
CN103049340A (en) Image super-resolution reconstruction method of visual vocabularies and based on texture context constraint
KR102234614B1 (en) Apparatus and method for recommending color combination based on analysis of space image
Sobieranski et al. Learning a nonlinear distance metric for supervised region-merging image segmentation
US8873833B2 (en) System and method for effectively performing a scene representation procedure
CN111046213A (en) Knowledge base construction method based on image recognition
CN112016548B (en) Cover picture display method and related device
Liu et al. RGB-D action recognition using linear coding
CN107657276B (en) Weak supervision semantic segmentation method based on searching semantic class clusters
CN106340024A (en) Image segmentation method and application and computing device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 1229936

Country of ref document: HK

GR01 Patent grant
GR01 Patent grant