An oil level grade analysis method and device based on an oil level paper

By preprocessing and edge detection of the oil-absorbing paper image, combined with tilt correction and noise correction, the problems of subjectivity and insufficient accuracy in oil analysis of oil-absorbing paper are solved, enabling accurate assessment and visualization of oily areas on the face, thus improving the user experience.

CN119671961BActive Publication Date: 2025-12-16GUANGZHOU SHIKA TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411724723.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-28
Publication Date
2025-12-16
Estimated Expiration
2044-11-28

AI Technical Summary

Technical Problem

Existing methods for analyzing the oil-producing area of ​​blotting papers suffer from problems such as strong subjectivity, biased testing, insufficient accuracy, and poor anti-interference ability, making it difficult to accurately assess facial oil production.

Method used

An oil grade analysis method based on oil-measuring paper is adopted, including image preprocessing, edge detection, tilt correction, noise correction and visualization. The oil grade is determined by calculating the area ratio.

Benefits of technology

It improves the objectivity and accuracy of oil production analysis, reduces subjective errors, and can accurately assess the area and level of facial oil production, making it easier for users to understand product usage and enhancing user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119671961B_ABST
    Figure CN119671961B_ABST
Patent Text Reader

Abstract

The application relates to an oil-out grade analysis method based on an oil measurement surface paper, which comprises the following steps: obtaining an image to be analyzed of the oil measurement surface paper; performing a pretreatment operation on the image to be analyzed to obtain a pretreated image; performing edge detection on the pretreated image to obtain an edge image, and performing inclination correction on the edge image to obtain an image to be area-analyzed; determining an oil-out range of the image to be area-analyzed to obtain a preliminary oil-out range; performing noise correction on the preliminary oil-out range based on a preset floating value to obtain an accurate oil-out range; marking the accurate oil-out range in the image to be area-analyzed, and pushing the marked image to be area-analyzed to a user terminal interface after visualizing the marked image. The application can make the finally obtained accurate oil-out range as accurate as possible, and finally visually display the accurate oil-out range to the user, so that the user can understand the product use condition of the user, and the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image processing, and in particular to an oil-out level analysis method and device based on oil absorption paper. BACKGROUND

[0002] Oil absorption paper is a thin paper or tissue with strong oil absorption properties. In existing facial care products, people often use this oil absorption paper to absorb excess oil on the face to prevent facial pimples, and at the same time, to keep the face clean and fresh.

[0003] The oil absorption paper on the market often needs the user to judge the oil-out position according to visual perception after use, and then the corresponding processing is carried out according to the judgment result. This method is not convenient for the user to use, and is greatly affected by subjective factors. If the image analysis method is used to analyze the oil-out area, it may cause many interference items due to the use traces of the oil absorption paper, resulting in inaccurate analysis results.

[0004] In the field of facial care, oil absorption paper is widely used as an effective tool for oil absorption to control facial oil secretion and maintain skin freshness. After using traditional oil absorption paper, users usually rely on visual assessment to judge the position and degree of oil-out. This assessment method has obvious limitations and subjectivity. Users' visual assessment is not only affected by individual perception differences, but also difficult to accurately quantify the oil-out area and oil amount, which limits the in-depth understanding and effective management of oil-out conditions.

[0005] In addition, existing image analysis techniques often use point measurement methods when dealing with oil absorption paper, which can only measure the oil-out conditions of fixed small areas, and cannot accurately and comprehensively evaluate the oil-out conditions and position differences of the face.

[0006] It is difficult to accurately analyze the oil-out area due to complex background and interference caused by use traces. These technologies usually lack fine control of image preprocessing and edge detection, resulting in inaccurate analysis results. Therefore, the existing technology has the following main defects in the analysis of the oil-out area of the oil absorption paper:

[0007] Strong subjectivity: Users' visual assessment is highly dependent on personal experience and perception, lacking objectivity and repeatability.

[0008] Test patch: The test is based on point determination, such as cheek, forehead, etc., lacking a method for evaluating the overall facial oil level.

[0009] Insufficient precision: Unable to accurately quantify the oil-out area, resulting in inability to analyze and manage oil secretion in detail.

[0010] Poor anti-interference capability: the existing image analysis technology is difficult to accurately identify the facial oil area and level of different people in the face of complex background and interference terms. SUMMARY

[0011] The purpose of the present application is to at least solve one of the deficiencies of the prior art, provide an oil level analysis method and device based on oil measuring paper.

[0012] In order to achieve the above purpose, the present application adopts the following technical scheme:

[0013] Specifically, an oil level analysis method based on oil measuring paper is proposed, which includes the following,

[0014] Obtain the image to be analyzed of the oil measuring paper;

[0015] Pretreatment operation is performed on the image to be analyzed to obtain a pretreated image;

[0016] Edge detection is performed on the pretreated image to obtain an edge image, and tilt correction is performed on the edge image to obtain a to-be-area-analyzed image;

[0017] The to-be-area-analyzed image is subjected to oil range determination to obtain a preliminary oil range;

[0018] Based on the preset floating value, the preliminary oil range is subjected to noise correction to obtain a precise oil range;

[0019] According to the area ratio of the precise oil range in the to-be-area-analyzed image, the oil level analysis result is obtained according to the preset rule;

[0020] The precise oil range in the to-be-area-analyzed image is labeled, and the labeled to-be-area-analyzed image is visualized and pushed to the user terminal interface together with the oil level analysis result.

[0021] Further, specifically, the pretreated image is obtained by pretreating the image to be analyzed, which includes,

[0022] The pretreated image is obtained by adjusting the brightness, contrast and removing noise of the image to be analyzed and then gray scaling.

[0023] Further, specifically, the to-be-area-analyzed image is obtained by tilt correction of the edge image, which includes,

[0024] The straight line in the edge image is found by Hough transform;

[0025] Assuming that there are two points A(x1, y1) and B(x2, y2) in any straight line, the slope slope=(y2-y1) / (x2-x1) is calculated;

[0026] The slope slope is converted to the inclination angle angle of the straight line by angle = np.degrees(np.arctan(slope));

[0027] The inclination angles of all straight lines in the edge image are averaged to obtain average_angle = np.mean(angles);

[0028] np.mean(angles);

[0029] The edge image is rotated based on average_angle to achieve inclination correction;

[0030] The blank area of the edge generated after rotation is cropped to obtain a to-be-area-analyzed image.

[0031] Further, specifically, the to-be-area-analyzed image is subjected to oil outlet range determination to obtain a preliminary oil outlet range, including,

[0032] The to-be-area-analyzed image is binarized to obtain a first image;

[0033] The first image is subjected to connected component detection to obtain a plurality of connected regions;

[0034] The area of each connected region is calculated by cv2.findContours;

[0035] The mean value of the areas of all connected regions at this time is calculated to obtain a first mean value;

[0036] The first mean value is subtracted by a preset floating value to obtain a first discrimination value;

[0037] All connected regions whose areas are lower than the first discrimination value are removed, and the remaining connected regions are the preliminary oil outlet range.

[0038] Further, specifically, the preliminary oil outlet range is subjected to noise correction based on a preset floating value to obtain an accurate oil outlet range, including,

[0039] The proportion P of the number of removed connected regions to the number of all connected regions is calculated;

[0040] It is judged whether the proportion P is lower than a proportion threshold value,

[0041] If it is lower than the proportion threshold value, the area mean value of the preliminary oil outlet range is calculated to obtain a second mean value, and the second mean value is subtracted by a preset floating value to obtain a second discrimination value. The connected regions in the preliminary oil outlet range that are lower than the second discrimination value are removed to obtain the accurate oil outlet range;

[0042] If the ratio threshold is not less than the ratio threshold, the second average is calculated by calculating the area average of the preliminary oil-out range, and the second average is directly taken as the second discrimination value, and the connected region lower than the second discrimination value in the preliminary oil-out range is removed to obtain the accurate oil-out range.

[0043] Further, specifically, the visualization operation comprises,

[0044] After the accurate oil-out range is labeled in the image to be area-analyzed, the accurate oil-out range is color-rendered, and the area of each connected region of the accurate oil-out range is labeled.

[0045] Further, specifically, the edge detection algorithm based on the Canny operator is used to perform edge detection on the preprocessed image to obtain an edge image.

[0046] Further, the method further comprises,

[0047] The APP login information of the user on the mobile terminal is obtained, the data before analysis and the data after analysis are associated and stored with the personal information of the user after each analysis of the image to be analyzed of the oil-out surface paper is completed, and then a user sample library is formed based on all registered users.

[0048] The application also provides an oil-out grade analysis device based on an oil-out surface paper, comprising the following:

[0049] A data acquisition module is configured to acquire an image to be analyzed of an oil-out surface paper.

[0050] A preprocessing module is configured to perform a preprocessing operation on the image to be analyzed to obtain a preprocessed image.

[0051] An edge detection module is configured to perform edge detection on the preprocessed image to obtain an edge image, and perform tilt correction on the edge image to obtain an image to be area-analyzed.

[0052] A first correction module is configured to determine an oil-out range based on the image to be area-analyzed to obtain a preliminary oil-out range.

[0053] A second correction module is configured to perform noise correction on the preliminary oil-out range based on a preset floating value to obtain an accurate oil-out range.

[0054] An oil-out grade analysis module is configured to obtain an oil-out grade analysis result according to the area proportion of the accurate oil-out range in the image to be area-analyzed according to a preset rule.

[0055] A visualization module is configured to label the accurate oil-out range in the image to be area-analyzed, and push the labeled image to be area-analyzed to a user terminal interface after visualizing the labeled image to be area-analyzed.

[0056] The application has the following advantages:

[0057] The application provides an oil-out grade analysis method based on a test oil surface paper. First, a preliminary interference term of a test oil surface paper to be analyzed is preprocessed as much as possible, then an image after edge detection is corrected in tilt to ensure subsequent area analysis, a preliminary oil-out range is obtained by removing part of the interference term when the area analysis is performed, then the strength of the second interference term removal is determined according to the removal of the interference term, and the final accurate oil-out range is as accurate as possible, finally, the accurate oil-out range is visualized and displayed to the user, so that the user can understand the product use condition of the user and improve the user experience. BRIEF DESCRIPTION OF DRAWINGS

[0058] The above and other features of the present disclosure will become more apparent from the following detailed description of the embodiments taken in conjunction with the accompanying drawings, in which like reference characters indicate the same or similar elements throughout the drawings, and in which:

[0059] Figure 1 A flowchart of an oil-out grade analysis method based on a test oil surface paper is shown;

[0060] Figure 2 A management interface schematic diagram when a user sample library is established in the oil-out grade analysis method based on a test oil surface paper is shown;

[0061] Figure 3 An APP interface schematic diagram when a user sample library is established in the oil-out grade analysis method based on a test oil surface paper is shown. DETAILED DESCRIPTION

[0062] The concept, specific structure and generated technical effects of the present application will be described clearly and completely in the following embodiments and drawings, so as to fully understand the purpose, scheme and effect of the present application. It should be noted that the embodiments in the present application and the features in the embodiments can be combined with each other without conflict. The same reference numerals in the drawings indicate the same or similar parts.

[0063] REFERENCE Figure 1 , embodiment 1, the present application provides an oil-out grade analysis method based on a test oil surface paper, including the following,

[0064] Step 110, obtaining a test oil surface paper to be analyzed image;

[0065] Step 120, pre-processing the to-be-analyzed image to obtain a pre-processed image;

[0066] Step 130, edge detection is performed on the pre-processed image to obtain an edge image, and tilt correction is performed on the edge image to obtain a to-be-area-analyzed image;

[0067] Step 140, oil-out range determination is performed on the to-be-area-analyzed image to obtain a preliminary oil-out range;

[0068] Step 150, noise correction is performed on the preliminary oil-out range based on a preset floating value to obtain an accurate oil-out range;

[0069] Step 160, according to the area proportion of the accurate oil-out range in the to-be-area-analyzed image, an oil-out grade analysis result is obtained according to a preset rule; the mapping relationship between the area proportion value and the oil-out grade in the preset range can be established, and the oil-out grade is obtained by reading the area proportion value and then mapping.

[0070] Step 170, the accurate oil-out range in the to-be-area-analyzed image is marked, and the to-be-area-analyzed image after marking is visualized and pushed to the user terminal interface together with the oil-out grade analysis result.

[0071] In the embodiment 1, first, the to-be-analyzed image of the oil measuring surface paper is pre-processed to reduce as many preliminary interference items as possible, then the image after edge detection is tilt-corrected to ensure subsequent area analysis, when performing area analysis, some interference items are removed to obtain a preliminary oil-out range, then the strength of the second interference item removal is determined according to the removal of the interference items, so as to make the final accurate oil-out range as accurate as possible, finally, the accurate oil-out range is visualized and displayed to the user, so as to facilitate the user to understand the product use condition of the user and improve the user experience.

[0072] As a preferred embodiment of the present application, specifically, the pre-processing operation is performed on the to-be-analyzed image to obtain a pre-processed image, including,

[0073] The brightness, contrast adjustment and noise removal of the to-be-analyzed image are performed and grayed to obtain the pre-processed image.

[0074] In the preferred embodiment, the pre-processing of the to-be-analyzed image is performed by the above-mentioned manner, which can facilitate the subsequent area analysis process.

[0075] As a preferred embodiment of the present application, specifically, the tilt correction is performed on the edge image to obtain a to-be-area-analyzed image, including,

[0076] The straight line in the edge image is found by Hough transform;

[0077] Suppose that there are two points A(x1, y1) and B(x2, y2) in any straight line, the slope thereof is calculated as slope=(y2-y1) / (x2-x1).

[0078] Convert the slope to the angle of inclination of the line by angle = np.degrees(np.arctan(slope));

[0079] Average the angle of inclination of all lines in the edge image to obtain average_angle = np.mean(angles);

[0080] np.mean(angles);

[0081] Rotate the edge image based on average_angle to achieve inclination correction;

[0082] Crop the blank edge area generated after rotation to obtain the area analysis image.

[0083] In the preferred embodiment, the inclination correction process described above can make the edge image as much as possible to avoid inclination, which is convenient for subsequent area analysis process.

[0084] As a preferred embodiment of the present application, specifically, the oil outlet range determination of the area analysis image is obtained, including,

[0085] The area analysis image is binarized to obtain a first image;

[0086] The connected components of the first image are detected to obtain a plurality of connected regions;

[0087] The area of each connected region is calculated by cv2.findContours;

[0088] The mean value of the area of all connected regions at this time is calculated to obtain the first mean value;

[0089] The first mean value is subtracted by a preset floating value to obtain the first discrimination value;

[0090] All connected regions with an area lower than the first discrimination value are removed, and the remaining connected regions are the preliminary oil outlet range.

[0091] In the preferred embodiment, the above method can remove some small interference items to obtain the preliminary oil outlet range, and the following is an actual application code of a preferred embodiment.

[0092] import cv2

[0093] import numpy as np

[0094] # Read the image

[0095] image=cv2.imread('path_to_image',cv2.IMREAD_GRAYSCALE)

[0096] #Binarization Processing

[0097] _,binary_image=cv2.threshold(image,0,255,cv2.THRESH_BINARY+

[0098] cv2.THRESH_OTSU)

[0099] # Use connectedComponents to detect connected components

[0100] num_labels,labels,stats,centroids=

[0101] cv2.connectedComponentsWithStats(binary_image,connectivity=8)

[0102] #Calculate the area of ​​a connected region

[0103] areas=stats[:,cv2.CC_STAT_AREA]

[0104] for i in range(1, num_labels):

[0105] print(f"The area of ​​region {i} is: {areas[i]}")

[0106] # Use findContours to detect connected components

[0107] contours,hierarchy=cv2.findContours(binary_image,cv2.RETR_EXTERNAL,cv2.CHAIN_APPROX_SIMPLE)

[0108] #Calculate the area of ​​a connected region

[0109] for i,contour in enumerate(contours):

[0110] area=cv2.contourArea(contour)

[0111] print(f"The area of ​​region {i} is: {area}").

[0112] As a preferred embodiment of the present application, specifically, the preliminary oil-out range is noise-corrected based on the preset floating value to obtain the accurate oil-out range, comprising,

[0113] calculating a proportion P of the number of the removed connected regions to the number of all connected regions;

[0114] judging whether the proportion P is lower than a proportion threshold value,

[0115] if the proportion P is lower than the proportion threshold value, calculating a second mean value of the area of the preliminary oil-out range, and subtracting a preset floating value from the second mean value to obtain a second discrimination value, and removing the connected regions lower than the second discrimination value from the preliminary oil-out range to obtain the accurate oil-out range;

[0116] if the proportion P is not lower than the proportion threshold value, calculating a second mean value of the area of the preliminary oil-out range, and directly taking the second mean value as the second discrimination value, and removing the connected regions lower than the second discrimination value from the preliminary oil-out range to obtain the accurate oil-out range.

[0117] In the present preferred embodiment, through the proportion of the number of the initially proposed connected regions, if the proportion is too large, it is considered that there are too many interference items, and in this case, the second mean value is directly used for screening, if the proportion is not large, it is considered that there are not too many interference items, and in this case, the second mean value is floated downward, that is, a preset floating value is subtracted to obtain the second discrimination value and screening is performed based on the second discrimination value, so that the accurate oil-out range can be obtained more accurately.

[0118] As a preferred embodiment of the present application, specifically, the visual operation comprises,

[0119] after the accurate oil-out range is marked in the image to be area-analyzed, the accurate oil-out range is color-rendered and the area of each connected region of the accurate oil-out range is marked.

[0120] As a preferred embodiment of the present application, specifically, an edge image is obtained by performing edge detection on the preprocessed image based on a Canny operator edge detection algorithm.

[0121] In the preferred embodiment, considering that the Canny operator detects edges through a multi-step process including Gaussian smoothing, gradient calculation, non-maximum suppression, and double threshold linking, this method can effectively reduce the impact of noise while improving the accuracy of edge detection. Preprocessing the image using a Gaussian filter helps to smooth the image before edge detection, reducing the impact of noise on the edge detection result. The Canny operator ensures the accuracy of edge localization through the non-maximum suppression technique, which can find the most significant points on the edge, thereby improving the precision of edge detection. By adjusting the standard deviation of the Gaussian filter, the scale of edge detection can be adjusted, so that the Canny operator can adapt to the detection needs of edge features of different sizes. Therefore, the Canny operator is selected for edge detection.

[0122] As a preferred embodiment of the present application, with reference to Figure 2 and Figure 3 , the method further comprises,

[0123] Obtaining the APP login information of the user on the mobile terminal, after completing the analysis of the image to be analyzed of the oil surface paper each time, the data before analysis and the data after analysis are associated and stored with the personal information of the user, and then a user sample library is formed based on all registered users.

[0124] In the preferred embodiment, the user sample library is established by the above-mentioned method, which has the following advantages,

[0125] 1. A large amount of comparative data of consumers before and after using the product can be collected based on the oil surface paper to establish a consumer sample library (skin intrinsic state research database). There are 200 million users of the brand, so data can be collected simply and conveniently.

[0126] 2. Based on the area analysis of skin sebum, the corresponding relationship between sebum secretion and sebum data is established (CK testing instrument), and a new evaluation method standard is established.

[0127] 3. After establishing the product evaluation and consumer oil data corresponding relationship database, different products and formulations can be correspondingly studied to adjust the skin sebum of consumers.

[0128] 4. In the later stage, corresponding products can be matched to consumers according to the data of the oil surface paper.

[0129] 5. The oil absorption paper can absorb the sebum of consumers, and in the later stage, the sebum composition model can be analyzed by sampling.

[0130] 6. The use of different products by consumers at different times can be collected and evaluated for comparison to obtain oil control data.

[0131] The application further provides an oil-out grade analysis device based on the oil level paper, which comprises the following:

[0132] a data acquisition module, configured to acquire an image to be analyzed of the oil level paper;

[0133] a preprocessing module, configured to perform a preprocessing operation on the image to be analyzed to obtain a preprocessed image;

[0134] an edge detection module, configured to perform edge detection on the preprocessed image to obtain an edge image, and perform tilt correction on the edge image to obtain an area analysis image to be analyzed;

[0135] a first correction module, configured to determine an oil-out range based on the area analysis image to be analyzed to obtain a preliminary oil-out range;

[0136] a second correction module, configured to perform noise correction on the preliminary oil-out range based on a preset floating value to obtain an accurate oil-out range;

[0137] an oil-out grade analysis module, configured to obtain an oil-out grade analysis result according to an area ratio of the accurate oil-out range in the area analysis image to be analyzed according to a preset rule;

[0138] a visualization module, configured to mark the accurate oil-out range in the area analysis image to be analyzed, and push the marked area analysis image to be analyzed to a user terminal interface after visualizing the marked area analysis image to be analyzed.

[0139] The modules described as separate components can or can not be physically separate, and the components displayed as modules can or can not be physical modules, that is, they can be located in one place, or they can be distributed on multiple network modules. According to actual needs, some or all of the modules can be selected to achieve the purpose of the scheme in the embodiment.

[0140] In addition, each functional module in each embodiment of the application can be integrated in one processing module, or each module can exist physically, or two or more modules can be integrated in one module. The integrated module can be realized in the form of hardware or in the form of a software functional module.

[0141] The integrated module, if implemented in the form of a software function module and sold or used as an independent product, can be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the above-mentioned embodiment methods can also be completed by a computer program instructing related hardware, and the computer program can be stored in a computer readable storage medium. When the computer program is executed by a processor, the steps of the above-mentioned various method embodiments can be implemented. The computer program includes computer program code, which can be in the form of source code, object code, executable files or some intermediate forms. The computer readable medium can include any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium, etc.

[0142] Although the description of the present application has been quite detailed and particularly described with respect to several described embodiments, it is not intended to be limited to any of these details or embodiments or any particular embodiment, but should be considered to be a broad interpretation of the claims in view of the prior art, so as to effectively encompass the intended scope of the present application. In addition, the present application is described above in embodiments that the inventors can foresee, and the purpose is to provide a useful description, and those non-essential modifications to the present application that have not yet been foreseen can still represent equivalent modifications of the present application.

[0143] The above is only the preferred embodiment of the present application, and the present application is not limited to the above-mentioned embodiments, as long as the same means achieve the technical effect of the present application, which should belong to the protection scope of the present application. The technical solutions and / or embodiments within the protection scope of the present application can have various modifications and changes.

Claims

1. An oil exudation level analysis method based on an oil exudation surface paper, characterized by, The method comprises the following steps: obtaining an image to be analyzed of an oil surface paper; performing a preprocessing operation on the image to be analyzed to obtain a preprocessed image; performing edge detection on the preprocessed image to obtain an edge image, and performing tilt correction on the edge image to obtain an image to be area analyzed; determining an oil discharge range based on the image to be area analyzed to obtain a preliminary oil discharge range; performing noise correction on the preliminary oil discharge range based on a preset floating value to obtain an accurate oil discharge range; obtaining an oil discharge level analysis result according to the area proportion of the accurate oil discharge range in the image to be area analyzed according to a preset rule; annotating the accurate oil discharge range in the image to be area analyzed, and performing visualization on the annotated image to be area analyzed and pushing the annotated image to be area analyzed and the oil discharge level analysis result to a user terminal interface together.

2. The method of claim 1, wherein the method is based on the analysis of the oil level paper. Specifically, the preprocessing operation on the image to be analyzed to obtain a preprocessed image comprises the following steps: adjusting brightness, contrast and removing noise of the image to be analyzed, and performing gray scale processing to obtain the preprocessed image.

3. The method of claim 2, wherein the paper is a test oil surface paper. Specifically, the tilt correction on the edge image to obtain an image to be area analyzed comprises the following steps: finding straight lines in the edge image through Hough transform; assuming that there are two points A(x1, y1) and B(x2, y2) in any straight line, calculating the slope slope=(y2-y1) / (x2-x1); converting the slope slope to obtain the tilt angle angle of the straight line through angle=np.degrees(np.arctan(slope)); averaging the tilt angles of all straight lines in the edge image to obtain average_angle=np.mean(angles); rotating the edge image based on average_angle to realize tilt correction; cutting off the blank area generated after rotation to obtain the image to be area analyzed.

4. The method of claim 3, wherein the paper is a test oil surface paper. Specifically, the determination of the oil discharge range based on the image to be area analyzed to obtain a preliminary oil discharge range comprises the following steps: performing binaryzation on the image to be area analyzed to obtain a first image; detecting connected regions through connectedComponents to obtain a plurality of connected regions; calculating the area of each connected region through cv2.findContours; calculating the mean value of the areas of all connected regions to obtain a first mean value; subtracting the preset floating value from the first mean value to obtain a first discrimination value; removing the connected regions with areas lower than the first discrimination value from all connected regions, and the remaining connected regions are the preliminary oil discharge range.

5. The method of claim 4, wherein the method is based on the analysis of the oil level paper. Specifically, the noise correction on the preliminary oil discharge range based on the preset floating value to obtain an accurate oil discharge range comprises the following steps: calculating the proportion P of the number of removed connected regions to the number of all connected regions; judging whether the proportion P is lower than a proportion threshold value, if the proportion P is lower than the proportion threshold value, calculating the mean value of the areas of the preliminary oil discharge range to obtain a second mean value, subtracting the preset floating value from the second mean value to obtain a second discrimination value, and removing the connected regions with areas lower than the second discrimination value from the preliminary oil discharge range to obtain the accurate oil discharge range. If the ratio threshold is not lower than the proportion threshold, a second mean value is calculated by calculating the area mean value of the preliminary oil-out range, and the second mean value is directly taken as a second discrimination value. The connected region lower than the second discrimination value in the preliminary oil-out range is removed to obtain the accurate oil-out range.

6. The method of claim 1, wherein the method is based on the analysis of the oil level paper. Specifically, the visualization operation comprises, After the accurate oil-out range is labeled in the image to be area-analyzed, the accurate oil-out range is color-rendered and each connected region of the accurate oil-out range is labeled with its area.

7. The method of claim 1, wherein the method is based on the analysis of the oil level paper. Specifically, an edge image is obtained by performing edge detection on the preprocessed image based on a Canny operator-based edge detection algorithm.

8. The method of claim 1, wherein the method is based on the analysis of the oil level paper. The method further comprises, The APP login information of the user on the mobile terminal is obtained, the data before analysis and the data after analysis are associated with the personal information of the user and stored after the analysis of the image to be analyzed of the oil surface paper is completed each time, and then a user sample library is formed based on all registered users.

9. An oil level based paper analysis device, characterized by, The method comprises the following steps: A data acquisition module is configured to acquire the image to be analyzed of the oil surface paper. A preprocessing module is configured to perform a preprocessing operation on the image to be analyzed to obtain a preprocessed image. An edge detection module is configured to perform edge detection on the preprocessed image to obtain an edge image, and perform tilt correction on the edge image to obtain an image to be area-analyzed. A first correction module is configured to determine an oil-out range based on the image to be area-analyzed to obtain a preliminary oil-out range. A second correction module is configured to perform noise correction on the preliminary oil-out range based on a preset floating value to obtain an accurate oil-out range. An oil-out grade analysis module is configured to obtain an oil-out grade analysis result according to the area proportion of the accurate oil-out range in the image to be area-analyzed according to a preset rule. A visualization module is configured to label the accurate oil-out range in the image to be area-analyzed, and push the labeled image to be area-analyzed to a user terminal interface after visualizing the labeled image to be area-analyzed.

Citation Information

Patent Citations

  • Local human skin oil detection system

    CN203408032U

  • Oil absorption paper convenient to replace and used for measuring skin oil outlet condition

    CN221083675U