CA3153067A1 - Picture-detecting method and apparatus - Google Patents
Picture-detecting method and apparatus Download PDFInfo
- Publication number
- CA3153067A1 CA3153067A1 CA3153067A CA3153067A CA3153067A1 CA 3153067 A1 CA3153067 A1 CA 3153067A1 CA 3153067 A CA3153067 A CA 3153067A CA 3153067 A CA3153067 A CA 3153067A CA 3153067 A1 CA3153067 A1 CA 3153067A1
- Authority
- CA
- Canada
- Prior art keywords
- region image
- picture
- background
- binarization
- pixel
- 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.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 71
- 238000006243 chemical reaction Methods 0.000 claims abstract description 22
- 230000011218 segmentation Effects 0.000 claims abstract description 22
- 230000010339 dilation Effects 0.000 claims description 18
- 230000001629 suppression Effects 0.000 claims description 12
- 238000001914 filtration Methods 0.000 claims description 10
- 238000004590 computer program Methods 0.000 claims description 6
- 238000010998 test method Methods 0.000 abstract 1
- 238000001514 detection method Methods 0.000 description 6
- 230000009286 beneficial effect Effects 0.000 description 5
- 238000005516 engineering process Methods 0.000 description 2
- 230000004927 fusion Effects 0.000 description 2
- 230000000007 visual effect Effects 0.000 description 2
- 230000004456 color vision Effects 0.000 description 1
- 238000013527 convolutional neural network Methods 0.000 description 1
- 230000003203 everyday effect Effects 0.000 description 1
- 238000002513 implantation Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/70—Denoising; Smoothing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/20—Image enhancement or restoration using local operators
- G06T5/30—Erosion or dilatation, e.g. thinning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/136—Segmentation; Edge detection involving thresholding
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/194—Segmentation; Edge detection involving foreground-background segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/90—Determination of colour characteristics
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Quality & Reliability (AREA)
- Image Analysis (AREA)
Abstract
The present invention relates to the technical field of picture recognition. Disclosed are a picture test method and device, which improves the quality of an uploaded picture by adding compliance test items, i.e. a picture background purity and a main body position. Said method comprises: acquiring a denoised picture to be tested, performing pixel-level semantic segmentation processing on same, and then recognizing a main body area image and a background area image; performing color space conversion on said picture, and outputting hue space data and lightness space data of the images; expanding the main body area image and then fusing same with the hue space data, and extracting background purity values corresponding to pixels in the background area image, so as to determine whether the background purity of said picture is compliant; processing the lightness space data by means of a plurality of binarization methods, and outputting a plurality of binarization results; and fusing the main body area image with the plurality of binarization results, respectively, extracting coordinate values and a corresponding background purity value of each pixel in the fused main body area image, so as to determine whether the main body position of said picture is compliant.
Description
PICTURE-DETECTING METHOD AND APPARATUS
BACKGROUND OF THE INVENTION
Technical Field [0001] The present invention relates to the technical field of picture recognition, and more particularly to a picture-detecting method and a picture-detecting apparatus.
Description of Related Art
BACKGROUND OF THE INVENTION
Technical Field [0001] The present invention relates to the technical field of picture recognition, and more particularly to a picture-detecting method and a picture-detecting apparatus.
Description of Related Art
[0002] With the popularization of the Internet, more and more web-based platforms allow users to upload pictures. Particularly, in leading e-commerce platforms, hundreds of millions of pictures are uploaded by vendors and users every day, among which there are always some non-compliant or even illegal pictures. For preventing such improper uploading, examination of pictures is conventionally conducted as a combination of machine works and human works.
[0003] The existing examination technologies solely for a single type of illegal picture contents such as violent, terrorism, or porn are not satisfying to the modern e-commerce platforms.
For improving quality of uploaded pictures, it is desirable that a picture examination technology has the ability to determine compliance of pictures in addition to the ability to detect contents related to violent, terrorism, and porn, so as to filter out upload pictures that contain inaesthetic layouts such as non-centered subjects, busy backgrounds, and too much blank.
SUMMARY OF THE INVENTION
For improving quality of uploaded pictures, it is desirable that a picture examination technology has the ability to determine compliance of pictures in addition to the ability to detect contents related to violent, terrorism, and porn, so as to filter out upload pictures that contain inaesthetic layouts such as non-centered subjects, busy backgrounds, and too much blank.
SUMMARY OF THE INVENTION
[0004] The objective of the present invention is to provide a picture-detecting method and a picture-detecting apparatus, which ensure quality of uploaded pictures by adding detection items about picture background purity and subject location compliance.
[0005] To achieve the foregoing objective, in a first aspect the present invention provides a picture-detecting method. The picture-detecting method comprises:
Date Recue/Date Received 2022-03-02
Date Recue/Date Received 2022-03-02
[0006] acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
[0007] performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
[0008] fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
[0009] processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and
[0010] fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
[0011] Preferably, the step of acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image comprises:
[0012] denoising the to-be-detected picture by means of a nonlinear filtering method; and
[0013] performing pixel-level semantic segmentation on the denoised to-be-detected picture through a multi-channel deep residual fully convolutional network model, so as to recognize the subject region image and the background region image.
[0014] Preferably, the step of performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture comprises:
[0015] using HSV hue space conversion method to convert the to-be-detected picture and output the hue space data of the picture, in which the hue space data include a hue space component H; and
[0016] using LUV hue space conversion method to convert the to-be-detected picture and output the brightness space data of the picture, in which the brightness space data include a brightness space channel L.
Date Recue/Date Received 2022-03-02
Date Recue/Date Received 2022-03-02
[0017] More preferably, the step of fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant comprises:
[0018] filtering edge pixels of the subject region image by means of a filter kernel, so as to dilate the subject region image;
[0019] updating the part other than the dilated subject region image in the to-be-detected picture as the background region image;
[0020] fusing the updated background region image with data of the hue space component H, and determining whether the background purity value corresponding to every pixel in the updated background region image is compliant to a first threshold, and if yes, determining that the background purity of the to-be-detected picture is compliant, or if not, determining that the background purity of the to-be-detected picture is non-compliant;
and
and
[0021] wherein the first threshold includes a first background purity threshold.
[0022] More preferably, the step of processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly comprises:
[0023] processing data of the brightness space channel L by means of a fixed-threshold binarization method, so as to obtain a first binarization result; and
[0024] processing the data of the brightness space channel L by means of a Gaussian-window binarization method, so as to obtain a second binarization result.
[0025] Further, after the step of so as to output plural binarization results correspondingly, the method further comprises:
[0026] performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
[0027] Further, the step of fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region Date Recue/Date Received 2022-03-02 image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant comprises:
[0028] fusing the subject region image recognized through pixel-level semantic segmentation with the first binarization result and the second binarization result, respectively;
[0029] extracting coordinate values of the pixels belonging to the subject region image and the first binarization result from fusing results and their corresponding background purity values, and extracting coordinate values of the pixels belonging to the subject region image and the second binarization result from fusing results and their corresponding background purity values;
[0030] summarizing and extracting the coordinate values of the pixels and their corresponding background purity values, and determining whether both the coordinate value of each pixel and its corresponding background purity value are compliant to a second threshold, and if yes, determining that the location of the subject in the to-be-detected picture is compliant, or if not, determining that the location of the subject in the to-be-detected picture is non-compliant; and
[0031] wherein the second threshold includes a second background purity threshold and a location coordinate interval threshold.
[0032] As compared to the prior art, the picture-detecting method of the present invention has the following beneficial effects:
[0033] The picture-detecting method provided by the present invention first identifies a subject region image and a background region image in a denoised to-be-detected picture through pixel-level semantic segmentation, and then performs hue space conversion on the picture, so as to output hue space data and brightness space data of the picture.
During detection of background purity, since pixel-level semantic segmentation processes edge pixels of the subject region image and of the background region image in a relatively rough manner, the present invention dilates the subject region image to dilate the range of edge pixels of the subject region image in order to ensure complete coverage over the subject region image. Afterward, the dilated subject region image is fused with hue space data.
Afterward, background purity values corresponding to individual pixels in the Date Recue/Date Received 2022-03-02 background region image as the final result of said fusing are fused, and whether the background purity of the to-be-detected picture is compliant can be determined. To detect the location of the subject in the picture, the brightness space data are first processed by means of plural binarization methods so as to generate plural corresponding binarization results. The subject region image identified through pixel-level semantic segmentation is then fused with the plural binarization result, respectively. At last, based on the coordinate value of every pixel in the fused subject region image and its corresponding background purity value, whether the location of the subject in the to-be-detected picture is compliant can be determined.
During detection of background purity, since pixel-level semantic segmentation processes edge pixels of the subject region image and of the background region image in a relatively rough manner, the present invention dilates the subject region image to dilate the range of edge pixels of the subject region image in order to ensure complete coverage over the subject region image. Afterward, the dilated subject region image is fused with hue space data.
Afterward, background purity values corresponding to individual pixels in the Date Recue/Date Received 2022-03-02 background region image as the final result of said fusing are fused, and whether the background purity of the to-be-detected picture is compliant can be determined. To detect the location of the subject in the picture, the brightness space data are first processed by means of plural binarization methods so as to generate plural corresponding binarization results. The subject region image identified through pixel-level semantic segmentation is then fused with the plural binarization result, respectively. At last, based on the coordinate value of every pixel in the fused subject region image and its corresponding background purity value, whether the location of the subject in the to-be-detected picture is compliant can be determined.
[0034] It is thus clear that the present invention detects background purity of an uploaded picture and determines the location of the subject with significantly improved efficiency as compared to the conventional human examination.
[0035] In another aspect, the present invention provides a picture-detecting apparatus, which is applied to the method for picture-detecting method as recited in the foregoing technical scheme. The apparatus comprises:
[0036] a pixel-processing unit, for acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
[0037] a hue-space-converting unit, for performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
[0038] a first determining unit, for fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
[0039] a binarization-processing unit, for processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and
[0040] a second determining unit, for fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a Date Recue/Date Received 2022-03-02 location of a subject in the to-be-detected picture is compliant.
[0041] Preferably, between the binarization-processing unit and the second determining unit, the apparatus further comprises:
[0042] performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
[0043] As compared to the prior art, the disclosed picture-detecting apparatus provides beneficial effects that are similar to those provided by the disclosed picture-detecting method as enumerated above, and thus no repetitions are made herein.
[0044] In a third aspect the present invention provides a computer readable storage medium, storing thereon a computer program. When the computer program is executed by a processor, it implements the steps of the picture-detecting method as described previously.
[0045] As compared to the prior art, the disclosed computer-readable storage medium provides beneficial effects that are similar to those provided by the disclosed picture-detecting method as enumerated above, and thus no repetitions are made herein.
BRIEF DESCRIPTION OF THE DRAWINGS
BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The accompanying drawings are provided herein for better understanding of the present invention and form a part of this disclosure. The illustrative embodiments and their descriptions are for explaining the present invention and by no means form any improper limitation to the present invention, wherein:
[0047] FIG. 1 is a flowchart of the picture-detecting method according to one embodiment of the present invention; and
[0048] FIG. 2 is another flowchart of the picture-detecting method according to the embodiment of the present invention.
DETAILED DESCRIPTION OF THE INVENTION
DETAILED DESCRIPTION OF THE INVENTION
[0049] To make the foregoing objectives, features, and advantages of the present invention Date Recue/Date Received 2022-03-02 clearer and more understandable, the following description will be directed to some embodiments as depicted in the accompanying drawings to detail the technical schemes disclosed in these embodiments. It is, however, to be understood that the embodiments referred herein are only a part of all possible embodiments and thus not exhaustive. Based on the embodiments of the present invention, all the other embodiments can be conceived without creative labor by people of ordinary skill in the art, and all these and other embodiments shall be embraced in the scope of the present invention.
Embodiment 1
Embodiment 1
[0050] Referring to FIG. 1 and FIG. 2, the present embodiment provides a picture-detecting method, comprises:
[0051] acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture; fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture; fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
[0052] The picture-detecting method provided by the present embodiment first identifies a subject region image and a background region image in a denoised to-be-detected picture through pixel-level semantic segmentation, and then performs hue space conversion on the picture, so as to output hue space data and brightness space data of the picture. During detection of background purity, since pixel-level semantic segmentation processes edge pixels of the subject region image and of the background region image in a relatively Date Recue/Date Received 2022-03-02 rough manner, the present invention dilates the subject region image to dilate the range of edge pixels of the subject region image in order to ensure complete coverage over the subject region image. Afterward, the dilated subject region image is fused with hue space data. Afterward, background purity values corresponding to individual pixels in the background region image as the final result of said fusing are fused, and whether the background purity of the to-be-detected picture is compliant can be determined. To detect the location of the subject in the picture, the brightness space data are first processed by means of plural binarization methods so as to generate plural corresponding binarization results. The subject region image identified through pixel-level semantic segmentation is then fused with the plural binarization result, respectively. At last, based on the coordinate value of every pixel in the fused subject region image and its corresponding background purity value, whether the location of the subject in the to-be-detected picture is compliant can be determined.
[0053] It is thus clear that the present embodiment detects background purity of an uploaded picture and determines the location of the subject with significantly improved efficiency as compared to the conventional human examination.
[0054] In the foregoing embodiment, the step of acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image comprises:
[0055] denoising the to-be-detected picture by means of a nonlinear filtering method; performing pixel-level semantic segmentation on the denoised to-be-detected picture through a multi-channel deep residual fully convolutional network model, so as to recognize the subject region image and the background region image. Exemplarily, the nonlinear filtering is a median filtering denoising algorithm.
[0056] Specifically, in the foregoing embodiment, the step of performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture comprises:
[0057] using HSV hue space conversion method to convert the to-be-detected picture and so as to output the hue space data of the picture, hue space data comprises hue space component Date Recue/Date Received 2022-03-02 H; using LUV hue space conversion method to convert the to-be-detected picture and output the brightness space data of the picture, in which the brightness space data include a brightness space channel L.
[0058] For conversion of the hue space data, since the commonly used RGB color space method is based on computer hardware and its color space is not suitable for characterizing color purity, in particular implementations, the present employs the HSV hue space conversion method to convert the to-be-detected picture in the RGB color space into the HSV color space that is closer to human visual perceptual characteristics, so as to better characterize color purity and in turn improve detection precision of the background purity.
The conversion equation is as below:
-r,'.= max(R,G,B) S max(R,G,B)¨ min (R,O,B) ¨ ____________________________ max(R,G,B) (0¨B) 60x _____________________ S# Amax R,G,B)=R
S x V
60x 2+ __________________ SO_Emax(R,G,B)=0 r (R-0)\
60x 4+ __________________ S#0Amax(R,O,B)=B
Sxr,' , 1/-=I-1+360 If <0
The conversion equation is as below:
-r,'.= max(R,G,B) S max(R,G,B)¨ min (R,O,B) ¨ ____________________________ max(R,G,B) (0¨B) 60x _____________________ S# Amax R,G,B)=R
S x V
60x 2+ __________________ SO_Emax(R,G,B)=0 r (R-0)\
60x 4+ __________________ S#0Amax(R,O,B)=B
Sxr,' , 1/-=I-1+360 If <0
[0059] Features of brightness space data include extensive color gamut coverage, high visual consistency, and good capability of expressing color perception. Therefore, the present implantation coverts brightness space data of the picture to be examined through: first converting the to-be-detected picture from RGB space data into CIE XYZ space data, and then converting the CIE XYZ space data into LUV brightness space data using the following conversion equation:
X 0.412453 0.357580 0.180423 R
Y = 0.212671 0.715160 0.072169 G
Z 0.019334 0.119193 0.950227 B
Date Recue/Date Received 2022-03-02 Y Y r 6 116x ¨ ¨16 Y L Yn ,29;
=.
29' Y r 6 n Yn 29) /./ = 13 xL 4/1-12õ1 =13xL x(vi¨vni) where kin and vn are light source constants, and " is a preset fixed value;
kir= X +15Y + 3Z
v, =
X+15Y+ 3Z
X 0.412453 0.357580 0.180423 R
Y = 0.212671 0.715160 0.072169 G
Z 0.019334 0.119193 0.950227 B
Date Recue/Date Received 2022-03-02 Y Y r 6 116x ¨ ¨16 Y L Yn ,29;
=.
29' Y r 6 n Yn 29) /./ = 13 xL 4/1-12õ1 =13xL x(vi¨vni) where kin and vn are light source constants, and " is a preset fixed value;
kir= X +15Y + 3Z
v, =
X+15Y+ 3Z
[0060] Specifically, in the foregoing embodiment, the step of fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant comprises:
[0061] filtering edge pixels of the subject region image by means of a filter kernel, so as to dilate the subject region image; updating the part other than the dilated subject region image in the to-be-detected picture as the background region image; fusing the updated background region image with data of the hue space component H, and determining whether the background purity value corresponding to every pixel in the updated background region image is compliant to a first threshold, and if yes, determining that the background purity of the to-be-detected picture is compliant, or if not, determining that the background purity of the to-be-detected picture is non-compliant; and wherein the first threshold includes a first background purity threshold.
[0062] In particular implementations, a round filter kernel k is used for filtering pixels of the subject region image. Taking a round filter kernel having a diameter of 4 for example:
Date Recue/Date Received 2022-03-02 k= 1 1 1 1 x 1 1 1 1
Date Recue/Date Received 2022-03-02 k= 1 1 1 1 x 1 1 1 1
[0063] The filtering equation is:
= P ED K i1) z 1 (k np j) cP
-
= P ED K i1) z 1 (k np j) cP
-
[0064] In the above equation, (i, j) represents the pixel coordinates, P
represents the subject region image, Zu represents the background purity value corresponding to the pixel, (k) represents the punctured neighborhood region corresponding to each pixel obtained using the round filter kernel k as the mask, B represents the dilates subject region image, wherein the background region image is updated when the subject region image is dilated, and D represents the updated background region image. Then the updated background region image is fused with data of the hue space component H so as to generate a result C, wherein the fusion equation is as below:
ic(i,j) = H(i,j), (i,j) E
C = ic(i,j)1 C(i,j) = 0, (i,j) e D
where (0) represents pixel coordinates, H(i,j) represents the background purity value corresponding to the pixel in the hue space component H. When a pixel located at coordinates (i,j) belongs to the dilated background region imageD, the background purity of the pixel in the hue space component H is valuated. When the pixel located at coordinates (i, j) does not belong to the dilated background region image D, the background purity value of the pixel in the hue space component H is valuated as zero.
The coordinates of the pixels and their corresponding background purity values are gathered to form an array C, which is the array composed of the location coordinates of the pixels in the background region image D and the correspondingly converted background purity values. Then the predetermined first threshold is compared to the array Date Recue/Date Received 2022-03-02 C. If all the background purity values corresponding to the induvial pixels in the background region image D are smaller than the first background purity threshold, it is determined that the background purity of the to-be-detected picture is compliant.
represents the subject region image, Zu represents the background purity value corresponding to the pixel, (k) represents the punctured neighborhood region corresponding to each pixel obtained using the round filter kernel k as the mask, B represents the dilates subject region image, wherein the background region image is updated when the subject region image is dilated, and D represents the updated background region image. Then the updated background region image is fused with data of the hue space component H so as to generate a result C, wherein the fusion equation is as below:
ic(i,j) = H(i,j), (i,j) E
C = ic(i,j)1 C(i,j) = 0, (i,j) e D
where (0) represents pixel coordinates, H(i,j) represents the background purity value corresponding to the pixel in the hue space component H. When a pixel located at coordinates (i,j) belongs to the dilated background region imageD, the background purity of the pixel in the hue space component H is valuated. When the pixel located at coordinates (i, j) does not belong to the dilated background region image D, the background purity value of the pixel in the hue space component H is valuated as zero.
The coordinates of the pixels and their corresponding background purity values are gathered to form an array C, which is the array composed of the location coordinates of the pixels in the background region image D and the correspondingly converted background purity values. Then the predetermined first threshold is compared to the array Date Recue/Date Received 2022-03-02 C. If all the background purity values corresponding to the induvial pixels in the background region image D are smaller than the first background purity threshold, it is determined that the background purity of the to-be-detected picture is compliant.
[0065] Preferably, in the foregoing embodiment, the step of processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly comprises:
[0066] processing data of the brightness space channel L by means of a fixed-threshold binarization method, so as to obtain a first binarization result T; processing the data of the brightness space channel L by means of a Gaussian-window binarization method, so as to obtain a second binarization result G. Then non-coherence region suppression is performed on the first binarization result T and the second binarization result G, respectively by means of the non-maximum suppression method, so as to nullify the impact of non-coherence regions caused by complicated a background on the detection results, thereby further improving detection precision.
[0067] In the foregoing embodiment, the step of fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant comprises:
[0068] fusing the subject region image recognized through pixel-level semantic segmentation with the first binarization result and the second binarization result, respectively;
extracting coordinate values of the pixels belonging to the subject region image and the first binarization result from fusing results and their corresponding background purity values; and/or extracting coordinate values of the pixels belonging to the subject region image and the second binarization result from fusing results and their corresponding background purity values; summarizing and extracting the coordinate values of the pixels and their corresponding background purity values, and determining whether both the coordinate value of each pixel and its corresponding background purity value are compliant to a second threshold, and if yes, determining that the location of the subject in the to-be-detected picture is compliant, or if not, determining that the location of the Date Recue/Date Received 2022-03-02 subject in the to-be-detected picture is non-compliant; and wherein the second threshold includes a second background purity threshold and a location coordinate interval threshold.
extracting coordinate values of the pixels belonging to the subject region image and the first binarization result from fusing results and their corresponding background purity values; and/or extracting coordinate values of the pixels belonging to the subject region image and the second binarization result from fusing results and their corresponding background purity values; summarizing and extracting the coordinate values of the pixels and their corresponding background purity values, and determining whether both the coordinate value of each pixel and its corresponding background purity value are compliant to a second threshold, and if yes, determining that the location of the subject in the to-be-detected picture is compliant, or if not, determining that the location of the Date Recue/Date Received 2022-03-02 subject in the to-be-detected picture is non-compliant; and wherein the second threshold includes a second background purity threshold and a location coordinate interval threshold.
[0069] In particular implementations, the fusing process is well known in the art, and is described herein by example. The fusion equation is F = ff (i, DI f , and I f (mi, ni), (mi, ni) # 0 f f(ui, vj) eTnP
. When the background purity value of the pixel (i,j) is in the (f (mi, ni)eGnP
intersection between the first binarization result T and the subject region image, the coordinates of the pixel and its corresponding background purity value are taken.
Alternatively, when the background purity value of the pixel (i,j) is in the intersection between the second binarization result G and the subject region image, the coordinates of the pixel and its corresponding background purity value are taken. At last, the pixel coordinates and their corresponding background purity values are assembled to form an array F, which is an array composed of location coordinates of the pixels after assembling of T n P and G n P and their corresponding background purity values. A preset second threshold array is then used to compare with the array F. If the pixel coordinates are all within the location coordinate interval threshold, and the background purity values are all within the second background purity threshold, it is determined that the location of the subject in the to-be-detected picture is compliant.
Embodiment 2
. When the background purity value of the pixel (i,j) is in the (f (mi, ni)eGnP
intersection between the first binarization result T and the subject region image, the coordinates of the pixel and its corresponding background purity value are taken.
Alternatively, when the background purity value of the pixel (i,j) is in the intersection between the second binarization result G and the subject region image, the coordinates of the pixel and its corresponding background purity value are taken. At last, the pixel coordinates and their corresponding background purity values are assembled to form an array F, which is an array composed of location coordinates of the pixels after assembling of T n P and G n P and their corresponding background purity values. A preset second threshold array is then used to compare with the array F. If the pixel coordinates are all within the location coordinate interval threshold, and the background purity values are all within the second background purity threshold, it is determined that the location of the subject in the to-be-detected picture is compliant.
Embodiment 2
[0070] The present embodiment provides a picture-detecting apparatus, which comprises:
[0071] a pixel-processing unit, for acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
[0072] a hue-space-converting unit, for performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
[0073] a first determining unit, for fusing the subject region image after dilation processing with Date Recue/Date Received 2022-03-02 the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
[0074] a binarization-processing unit, for processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and
[0075] a second determining unit, for fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
[0076] Preferably, between the binarization-processing unit and the second determining unit, the apparatus further comprises:
[0077] performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
[0078] As compared to the prior art, the picture-detecting apparatus of the present embodiment provides beneficial effects that are similar to those provided by the based on the picture-detecting method of a convolutional neural network as enumerated in the previous embodiment, and thus no repetitions are made herein.
Embodiment 3
Embodiment 3
[0079] The present embodiment provides a computer-readable storage medium, storing thereon a computer program. When the computer program is executed by a processor, it implements the steps of the picture-detecting method as described previously.
[0080] As compared to the prior art, the computer-readable storage medium of the present embodiment provides beneficial effects that are similar to those provided by the picture-detecting method as enumerated in the previous embodiment, and thus no repetitions are made herein.
[0081] As will be appreciated by people of ordinary skill in the art, implementation of all or a part of the steps of the method of the present invention as described previously may be Date Recue/Date Received 2022-03-02 realized by having a program instruct related hardware components. The program may be stored in a computer-readable storage medium, and the program is about performing the individual steps of the methods described in the foregoing embodiments.
The storage medium may be a ROM/RAM, a hard drive, an optical disk, a memory card or the like.
The storage medium may be a ROM/RAM, a hard drive, an optical disk, a memory card or the like.
[0082] The present invention has been described with reference to the preferred embodiments and it is understood that the embodiments are not intended to limit the scope of the present invention. Moreover, as the contents disclosed herein should be readily understood and can be implemented by a person skilled in the art, all equivalent changes or modifications which do not depart from the concept of the present invention should be encompassed by the appended claims. Hence, the scope of the present invention shall only be defined by the appended claims.
Date Recue/Date Received 2022-03-02
Date Recue/Date Received 2022-03-02
Claims (10)
1. A picture-detecting method, comprising:
acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
2. The method of claim 1, wherein the step of acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image comprises:
denoising the to-be-detected picture by means of a nonlinear filtering method;
and performing pixel-level semantic segmentation on the denoised to-be-detected picture through a multi-channel deep residual fully convolutional network model, so as to recognize the subject region image and the background region image.
denoising the to-be-detected picture by means of a nonlinear filtering method;
and performing pixel-level semantic segmentation on the denoised to-be-detected picture through a multi-channel deep residual fully convolutional network model, so as to recognize the subject region image and the background region image.
3. The method of claim 1, wherein the step of performing hue space conversion on the to-be-Date Recue/Date Received 2022-03-02 detected picture, so as to output hue space data and brightness space data of the picture comprises:
using HSV hue space conversion method to convert the to-be-detected picture and output the hue space data of the picture, in which the hue space data include a hue space component H; and using LUV hue space conversion method to convert the to-be-detected picture and output the brightness space data of the picture, in which the brightness space data include a brightness space channel L.
using HSV hue space conversion method to convert the to-be-detected picture and output the hue space data of the picture, in which the hue space data include a hue space component H; and using LUV hue space conversion method to convert the to-be-detected picture and output the brightness space data of the picture, in which the brightness space data include a brightness space channel L.
4. The method of claim 3, wherein the step of fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant comprises:
filtering edge pixels of the subject region image by means of a filter kernel, so as to dilate the subject region image;
updating the part other than the dilated subject region image in the to-be-detected picture as the background region image;
fusing the updated background region image with data of the hue space component H, and determining whether the background purity value corresponding to every pixel in the updated background region image is compliant to a first threshold, and if yes, determining that the background purity of the to-be-detected picture is compliant, or if not, determining that the background purity of the to-be-detected picture is non-compliant; and wherein the first threshold includes a first background purity threshold.
filtering edge pixels of the subject region image by means of a filter kernel, so as to dilate the subject region image;
updating the part other than the dilated subject region image in the to-be-detected picture as the background region image;
fusing the updated background region image with data of the hue space component H, and determining whether the background purity value corresponding to every pixel in the updated background region image is compliant to a first threshold, and if yes, determining that the background purity of the to-be-detected picture is compliant, or if not, determining that the background purity of the to-be-detected picture is non-compliant; and wherein the first threshold includes a first background purity threshold.
5. The method of claim 3, wherein the step of processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly comprises:
processing data of the brightness space channel L by means of a fixed-threshold binarization method, so as to obtain a first binarization result; and processing the data of the brightness space channel L by means of a Gaussian-window binarization method, so as to obtain a second binarization result.
Date Recue/Date Received 2022-03-02
processing data of the brightness space channel L by means of a fixed-threshold binarization method, so as to obtain a first binarization result; and processing the data of the brightness space channel L by means of a Gaussian-window binarization method, so as to obtain a second binarization result.
Date Recue/Date Received 2022-03-02
6. The method of claim 5, wherein after the step of so as to output plural binarization results correspondingly, the method further comprises:
performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
7. The method of claim 5 or 6, wherein the step of fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant comprises:
fusing the subject region image recognized through pixel-level semantic segmentation with the first binarization result and the second binarization result, respectively;
extracting coordinate values of the pixels belonging to the subject region image and the first binarization result from fusing results and their corresponding background purity values, and extracting coordinate values of the pixels belonging to the subject region image and the second binarization result from fusing results and their corresponding background purity values;
summarizing and extracting the coordinate values of the pixels and their corresponding background purity values, and determining whether both the coordinate value of each pixel and its corresponding background purity value are compliant to a second threshold, and if yes, determining that the location of the subject in the to-be-detected picture is compliant, or if not, determining that the location of the subject in the to-be-detected picture is non-compliant; and wherein the second threshold includes a second background purity threshold and a location coordinate interval threshold.
fusing the subject region image recognized through pixel-level semantic segmentation with the first binarization result and the second binarization result, respectively;
extracting coordinate values of the pixels belonging to the subject region image and the first binarization result from fusing results and their corresponding background purity values, and extracting coordinate values of the pixels belonging to the subject region image and the second binarization result from fusing results and their corresponding background purity values;
summarizing and extracting the coordinate values of the pixels and their corresponding background purity values, and determining whether both the coordinate value of each pixel and its corresponding background purity value are compliant to a second threshold, and if yes, determining that the location of the subject in the to-be-detected picture is compliant, or if not, determining that the location of the subject in the to-be-detected picture is non-compliant; and wherein the second threshold includes a second background purity threshold and a location coordinate interval threshold.
8. A picture-detecting apparatus, comprising:
a pixel-processing unit, for acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
a hue-space-converting unit, for performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
Date Recue/Date Received 2022-03-02 a first determining unit, for fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
a binarization-processing unit, for processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and a second determining unit, for fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
a pixel-processing unit, for acquiring a to-be-detected picture that has been denoised, and after pixel-level semantic segmentation, recognizing a subject region image and a background region image;
a hue-space-converting unit, for performing hue space conversion on the to-be-detected picture, so as to output hue space data and brightness space data of the picture;
Date Recue/Date Received 2022-03-02 a first determining unit, for fusing the subject region image after dilation processing with the hue space data, extracting a background purity value corresponding to every pixel in the background region image formed after dilation processing, and determining whether background purity of the to-be-detected picture is compliant;
a binarization-processing unit, for processing the brightness space data by means of plural binarization methods, so as to output plural binarization results correspondingly; and a second determining unit, for fusing the subject region image with the plural binarization results, respectively, extracting a coordinate value of every pixel in the fused subject region image and its corresponding background purity value, and determining whether a location of a subject in the to-be-detected picture is compliant.
9. The apparatus of claim 8, wherein between the binarization-processing unit and the second determining unit, the apparatus further comprises:
performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
performing non-coherence region suppression on the first binarization result and the second binarization result, respectively, by means of a non-maximum suppression method.
10. A computer-readable storage medium, storing therein a computer program, wherein the computer program when executed by a processor performs the steps of the method described in any of claims 1 through 7.
Date Recue/Date Received 2022-03-02
Date Recue/Date Received 2022-03-02
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910826006.7 | 2019-09-02 | ||
CN201910826006.7A CN110717865B (en) | 2019-09-02 | 2019-09-02 | Picture detection method and device |
PCT/CN2020/097857 WO2021042823A1 (en) | 2019-09-02 | 2020-06-24 | Picture test method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CA3153067A1 true CA3153067A1 (en) | 2021-03-11 |
CA3153067C CA3153067C (en) | 2024-03-19 |
Family
ID=69210275
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CA3153067A Active CA3153067C (en) | 2019-09-02 | 2020-06-24 | Picture-detecting method and apparatus |
Country Status (3)
Country | Link |
---|---|
CN (1) | CN110717865B (en) |
CA (1) | CA3153067C (en) |
WO (1) | WO2021042823A1 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115126267A (en) * | 2022-07-25 | 2022-09-30 | 中建八局第三建设有限公司 | Optical positioning control system and method applied to concrete member embedded joint bar alignment |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110717865B (en) * | 2019-09-02 | 2022-07-29 | 苏宁云计算有限公司 | Picture detection method and device |
CN112991470B (en) * | 2021-02-08 | 2023-12-26 | 上海通办信息服务有限公司 | Certificate photo background color checking method and system under complex background |
CN114862897B (en) * | 2022-04-24 | 2024-08-09 | 北京百度网讯科技有限公司 | Image background processing method and device and electronic equipment |
CN114996488B (en) * | 2022-08-08 | 2022-10-25 | 北京道达天际科技股份有限公司 | Skynet big data decision-level fusion method |
Family Cites Families (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101686338B (en) * | 2008-09-26 | 2013-12-25 | 索尼株式会社 | System and method for partitioning foreground and background in video |
CN103578098B (en) * | 2012-08-07 | 2017-05-10 | 阿里巴巴集团控股有限公司 | Method and device for extracting commodity body in commodity picture |
CN102982335A (en) * | 2012-12-21 | 2013-03-20 | 北京邮电大学 | Intelligent safe multi-license-plate positioning identification method based on cellular neural network |
WO2014205231A1 (en) * | 2013-06-19 | 2014-12-24 | The Regents Of The University Of Michigan | Deep learning framework for generic object detection |
CN104268537A (en) * | 2014-10-14 | 2015-01-07 | 杭州淘淘搜科技有限公司 | Main body detection method based on complex commodity images |
CN105631455B (en) * | 2014-10-27 | 2019-07-05 | 阿里巴巴集团控股有限公司 | A kind of image subject extracting method and system |
CN105139383B (en) * | 2015-08-11 | 2018-08-10 | 北京理工大学 | Medical image cutting method based on definition circle hsv color space |
CN106611431A (en) * | 2015-10-22 | 2017-05-03 | 阿里巴巴集团控股有限公司 | An image detection method and apparatus |
CN106407983A (en) * | 2016-09-12 | 2017-02-15 | 南京理工大学 | Image body identification, correction and registration method |
KR101995523B1 (en) * | 2017-12-14 | 2019-10-01 | 동국대학교 산학협력단 | Apparatus and method for object detection with shadow removed |
CN108447064B (en) * | 2018-02-28 | 2022-12-13 | 苏宁易购集团股份有限公司 | Picture processing method and device |
CN113163133A (en) * | 2018-10-15 | 2021-07-23 | 华为技术有限公司 | Image processing method, device and equipment |
CN109214367A (en) * | 2018-10-25 | 2019-01-15 | 东北大学 | A kind of method for detecting human face of view-based access control model attention mechanism |
CN109544583B (en) * | 2018-11-23 | 2023-04-18 | 广东工业大学 | Method, device and equipment for extracting interested area of leather image |
CN110717865B (en) * | 2019-09-02 | 2022-07-29 | 苏宁云计算有限公司 | Picture detection method and device |
-
2019
- 2019-09-02 CN CN201910826006.7A patent/CN110717865B/en active Active
-
2020
- 2020-06-24 CA CA3153067A patent/CA3153067C/en active Active
- 2020-06-24 WO PCT/CN2020/097857 patent/WO2021042823A1/en active Application Filing
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115126267A (en) * | 2022-07-25 | 2022-09-30 | 中建八局第三建设有限公司 | Optical positioning control system and method applied to concrete member embedded joint bar alignment |
CN115126267B (en) * | 2022-07-25 | 2024-05-31 | 中建八局第三建设有限公司 | Optical positioning control system and method applied to pre-buried dowel bar alignment of concrete member |
Also Published As
Publication number | Publication date |
---|---|
CA3153067C (en) | 2024-03-19 |
WO2021042823A1 (en) | 2021-03-11 |
CN110717865B (en) | 2022-07-29 |
CN110717865A (en) | 2020-01-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CA3153067C (en) | Picture-detecting method and apparatus | |
KR101715486B1 (en) | Image processing apparatus and image processing method | |
JP4627557B2 (en) | Method and apparatus for correcting hybrid flash artifacts in digital images | |
JP4856086B2 (en) | Method and apparatus for detecting red eye in an acquired digital image | |
US8135184B2 (en) | Method and apparatus for detection and correction of multiple image defects within digital images using preview or other reference images | |
US7747071B2 (en) | Detecting and correcting peteye | |
JP4375322B2 (en) | Image processing apparatus, image processing method, program thereof, and computer-readable recording medium recording the program | |
US20060093238A1 (en) | Method and apparatus for red-eye detection in an acquired digital image using face recognition | |
JP2020160616A (en) | Generation device and computer program and generation method | |
EP3644599B1 (en) | Video processing method and apparatus, electronic device, and storage medium | |
JP2004326805A (en) | Method of detecting and correcting red-eye in digital image | |
JP2007504719A (en) | System and method for detecting and correcting red eyes in an image suitable for embedded applications | |
JP2005228342A (en) | Method and system for segmenting scanned document | |
CN110674759A (en) | Monocular face in-vivo detection method, device and equipment based on depth map | |
KR101631012B1 (en) | Image processing apparatus and image processing method | |
Ghamsarian et al. | Deblurring cataract surgery videos using a multi-scale deconvolutional neural network | |
JP2009038737A (en) | Image processing apparatus | |
JP5286215B2 (en) | Outline extracting apparatus, outline extracting method, and outline extracting program | |
CN113781330B (en) | Image processing method, device and electronic system | |
JP2003209704A (en) | Image processing method, image processor, image forming device, image processing program, and recording medium | |
JP2023546307A (en) | Methods, devices, equipment and storage medium for facial pigment detection model training | |
WO2021102928A1 (en) | Image processing method and apparatus | |
KR101915039B1 (en) | Method and apparatus for of correcting color automatically for color blindness | |
US20230306720A1 (en) | Method for recognizing arteries and veins on a fundus image using hyperspectral imaging technique | |
KR20130000537A (en) | Apparatus and method of correcting purple fringing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |
|
EEER | Examination request |
Effective date: 20220916 |