Stain detection method and device for cooking equipment and cooking equipment

By obtaining images at different brightness on the cooking equipment and performing differentiated processing, detecting and reminding users to clean stains on transparent parts, the problems of high accuracy and cost of stain detection in the prior art are solved, and stain detection with high accuracy and low cost are achieved.

CN118657765BActive Publication Date: 2025-03-11GREE ELECTRIC APPLIANCE INC OF ZHUHAI
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411132798.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-19
Publication Date
2025-03-11
Estimated Expiration
2044-08-19

AI Technical Summary

Technical Problem

The prior art cannot effectively and at low cost to detect glass stains on cooking equipment, resulting in reduced image recognition accuracy and reduced intelligent control accuracy.

Method used

By acquiring images captured by the image acquisition component at different brightnesses, differentiated processing is performed to determine the stain information on the transparent parts, and a cleaning reminder is issued to the user when the reminder conditions are met.

Benefits of technology

It improves the accuracy of stain detection in cooking equipment, while reducing detection costs, ensuring the accuracy of image recognition and intelligent control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118657765B_ABST
    Figure CN118657765B_ABST
Patent Text Reader

Abstract

The present application relates to a stain detection method, device and cooking equipment for cooking equipment. The cooking equipment includes an image acquisition component, a transparent part and an inner pot, and the image acquisition component acquires an image of the inner pot through the transparent part. The method includes: acquiring a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness; performing differential processing on the first image and the second image to obtain difference information between the first image and the second image; determining stain information on the transparent part based on imaging changes of images acquired at different brightnesses represented by the difference information; and reminding the user to clean when it is determined that the stain on the transparent part meets the reminder condition according to the stain information. The use of this method can improve the accuracy of stain detection of cooking equipment while reducing detection costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of intelligent control of household appliances, and in particular to a stain detection method and device for cooking equipment, and cooking equipment. Background Art

[0002] With the popularization of smart kitchen appliances and the development of related technologies, intelligently controlled cooking equipment has gradually become an indispensable household appliance in users' kitchens. Taking steam ovens as an example, in order to meet users' strong demand for intelligent control of cooking equipment, some steam ovens on the market are equipped with high-definition cameras installed in the interlayer of the oven door. The cameras can capture images of the ingredients inside the oven through the innermost glass of the oven door to realize image recognition, video recording, real-time live broadcast and other functions.

[0003] However, cooking equipment is a cooking tool used to perform the cooking process. During use, users are prone to leaving stains on the glass of the cooking equipment. Once the stains accumulate on the glass, they will affect the imaging effect of the camera, and then affect the accuracy of subsequent image recognition, reducing the accuracy of intelligent control of the cooking equipment.

[0004] To detect glass stains on steam ovens, the commonly used technical solutions are edge detection algorithms or deep learning technology for identification. However, although the edge detection algorithm is simple to use, it has a low accuracy rate when detecting glass stains on steam ovens. The implementation cost of deep learning technology is high, and it requires a large amount of training data and has high hardware requirements. Therefore, existing stain detection methods cannot achieve the effect of low-cost and high-accuracy stain detection on cooking equipment. Summary of the invention

[0005] Based on this, it is necessary to provide a stain detection method, device, computer equipment, computer-readable storage medium and computer program product for cooking equipment, which can improve the accuracy of stain detection for cooking equipment while reducing the detection cost, in order to address the above technical problems.

[0006] In a first aspect, the present application provides a stain detection method for a cooking device, wherein the cooking device comprises an image acquisition component, a transparent member and an inner pot, wherein the image acquisition component acquires an image of the inner pot through the transparent member, and the method comprises:

[0007] Acquire a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness;

[0008] performing difference processing on the first image and the second image to obtain difference information between the first image and the second image;

[0009] Determining stain information on the transparent element based on imaging changes of images collected at different brightnesses represented by the difference information;

[0010] When it is determined according to the stain information that the stain on the transparent element meets the reminder condition, a cleaning reminder is given to the user.

[0011] In one embodiment, performing difference processing on the first image and the second image to obtain difference information between the first image and the second image includes:

[0012] Performing grayscale conversion on the first image and the second image to obtain a first grayscale image and a second grayscale image;

[0013] Calculate the pixel difference between the first grayscale image and the second grayscale image to obtain difference information between the first image and the second image.

[0014] In one of the embodiments, the difference information includes grayscale difference values ​​of each matching pixel in the first image and the second image;

[0015] The determining of the stain information on the transparent element based on the imaging change between the images collected at different brightnesses represented by the difference information includes:

[0016] Determine the grayscale average value of the first image and the second image based on the grayscale difference value of each matching pixel point of the first image and the second image;

[0017] In the case where there is a grayscale difference value smaller than the grayscale average value, among the matching pixel points, the matching pixel points whose corresponding grayscale difference values ​​are smaller than the grayscale average value are determined as stain pixels;

[0018] Based on each of the stain pixels, stain information on the transparent element is determined.

[0019] In one of the embodiments, the difference information includes a difference image between the first image and the second image;

[0020] The determining of the stain information on the transparent element based on the imaging change between the images collected at different brightnesses represented by the difference information includes:

[0021] Based on the pixel value of each pixel point in the difference image between the first image and the second image, binarize the difference image to obtain an output image;

[0022] The stain information on the transparent element is determined according to the pixel value of each output pixel point on the output image.

[0023] In one embodiment, the binarization of the difference image based on the pixel value of each pixel point in the difference image between the first image and the second image to obtain the output image includes:

[0024] Based on a preset partitioning method, dividing the difference image between the first image and the second image into regions to obtain sub-difference images corresponding to a plurality of image regions;

[0025] For each of the sub-difference images, obtaining a pixel value of each pixel in the sub-difference image;

[0026] Compare each of the pixel values ​​with a regional pixel threshold of the image region to which the sub-difference image belongs, to obtain a pixel value comparison result of each of the pixel points;

[0027] Based on the pixel value comparison results, the sub-difference images are binarized to obtain an output image.

[0028] In one embodiment, the method further comprises:

[0029] Determining a pixel mean of the sub-difference image according to each of the pixel values;

[0030] A regional pixel threshold of an image region to which the difference image belongs is determined based on the pixel mean value and a brightness difference value between the first brightness and the second brightness.

[0031] In one embodiment, the cooking device further comprises a lighting component, and the light brightness of the lighting component comprises a first brightness and a second brightness; the step of acquiring a first image acquired by the image acquisition component at the first brightness and a second image acquired at the second brightness comprises:

[0032] In response to a start-up instruction for the cooking device, controlling the illumination component to operate at the first brightness, and acquiring a first image captured by the image acquisition component at the first brightness;

[0033] After the first image is acquired, the illumination component is controlled to operate at the second brightness to obtain a second image acquired by the image acquisition component at the second brightness.

[0034] In one embodiment, the stain information includes the stain area and the number of stains;

[0035] When it is determined according to the stain information that the stain on the transparent element meets the reminder condition, reminding the user to clean the transparent element includes:

[0036] If the area of ​​the stain region is greater than or equal to the preset area, and / or the number of stains is greater than or equal to the preset number, it is determined that the stains on the transparent part meet the reminder conditions, and a cleaning reminder is given to the user.

[0037] In a second aspect, the present application further provides a stain detection device for a cooking device, the cooking device comprising an image acquisition component, a transparent member and an inner pot, the image acquisition component acquires an image of the inner pot through the transparent member, and the device comprises:

[0038] An image acquisition module, used to acquire a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness;

[0039] A difference processing module, used to perform difference processing on the first image and the second image to obtain difference information between the first image and the second image;

[0040] A stain information determination module, configured to determine the stain information on the transparent element based on imaging changes of images acquired at different brightnesses represented by the difference information;

[0041] The reminder module is used to remind the user to clean when it is determined according to the stain information that the stain on the transparent element meets the reminder condition.

[0042] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the above method when executing the computer program.

[0043] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the steps of the above method when executed by a processor.

[0044] In a fifth aspect, the present application also provides a computer program product, including a computer program, which implements the steps of the above method when executed by a processor.

[0045] In a sixth aspect, the present application further provides a cooking device, the cooking device comprising an image acquisition component, a transparent member, an inner pot, a lighting component, and a controller respectively connected to the image acquisition component and the lighting component for communication;

[0046] The image acquisition component acquires an image of the inner container through the transparent member;

[0047] The illumination component is used to provide illumination of a first brightness or a second brightness to the image acquisition area of ​​the image acquisition component;

[0048] The controller implements the operation control method of the cooking equipment purification module as described above.

[0049] In the above-mentioned stain detection method, device, computer equipment, storage medium, computer program product and cooking equipment for cooking equipment, the image acquisition component on the cooking equipment acquires an image of the inner pot through a transparent part. In order to detect stains on the transparent part, the controller can obtain a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness, perform differential processing on the first image and the second image, and obtain difference information between the first image and the second image. Since the first image and the second image are images acquired by the same image acquisition component through the same transparent part at different brightnesses, when there are stains on the transparent part, the obstruction of the stains will cause the imaging changes of the first image and the second image in the stain obstruction area at different brightnesses to be smaller, while the imaging changes of the area not obstructed by the stains to be larger. Therefore, the controller can determine the stain information on the transparent part based on the imaging changes of the images acquired at different brightnesses represented by the difference information, and when it is determined according to the stain information that the stains on the transparent part meet the reminder conditions, the user is reminded to clean. Stains on transparent parts are detected based on the principle that when there are stains, the transmittance of transparent parts is different, that is, the imaging changes of the stained area are small under different brightness. The whole process only needs to provide light of different brightness to the image acquisition component, and there is no need to use a large amount of training data for deep learning. This improves the accuracy of stain detection in cooking equipment while effectively reducing the cost of stain detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 is a structural block diagram of a cooking device in one embodiment;

[0051] Figure 2 is a schematic flow chart of a stain detection method for a cooking device in one embodiment;

[0052] Figure 3 A schematic diagram of a process for determining stain information on a transparent member based on imaging changes between images collected at different brightnesses represented by difference information in one embodiment;

[0053] Figure 4 It is a schematic diagram of a process of performing binarization processing on a difference image between a first image and a second image based on the pixel value of each pixel point in the difference image to obtain an output image in one embodiment;

[0054] Figure 5 is a structural block diagram of a steam oven in one embodiment;

[0055] Figure 6 A schematic diagram of a flow chart of a stain detection method for a cooking device in another embodiment;

[0056] Figure 7 is a schematic diagram of an image processing process in one embodiment;

[0057] Figure 8 is a structural block diagram of a stain detection device for a cooking device in one embodiment;

[0058] Fig. 9 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0059] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0060] In one embodiment, Figure 1 As shown, the existing cooking device 100 includes an image acquisition component 101, a transparent part 102, an inner pot 103 and a controller 104 connected to the image acquisition component 101, wherein the inner pot 103 is used to hold ingredients to be cooked for cooking, and the image acquisition component 101 can capture images of the inner pot 103 through the transparent part 102 to achieve image recognition of the ingredients to be cooked in the inner pot 103, or perform functions such as video recording and real-time live broadcast of the cooking process.

[0061] The transparent member 102 can be any transparent component that can form an insulating interlayer with the door of the cooking device 100 and is made of a high-temperature resistant transparent material, such as glass. The transparent member 102 is generally arranged on the inner side of the interlayer, that is, on the side close to the inner pot 103.

[0062] The image acquisition component 101 can be any component that can capture the image of the inner pot 103 of the cooking device 100, such as a camera. In order to be able to capture the image of the inner pot 103 during cooking, the image acquisition component 101 needs to be set in the insulating interlayer formed by the transparent part 102 and the door body, and the image of the inner pot 103 is captured through the transparent part 102.

[0063] The controller 104 can be any control device with logic processing capabilities, such as an MCU. The controller 104 can execute the corresponding intelligent control method of the cooking device 100. For example, the controller 104 can control the image acquisition component 101 to capture the image of the inner pot 103, and control the cooking device 100 to realize the intelligent cooking process required by the user.

[0064] However, when the existing cooking device 100 is in use, as the user opens and closes the door and the cooking process accumulates, it is easy to leave stains on the transparent part 102, such as oil stains and food residues. Once the stains accumulate on the transparent part 102, they will affect the imaging effect of the image acquisition component 101, and then affect functions such as image recognition, for example, causing inaccurate image recognition results and reducing the recognition rate.

[0065] The accumulation of stains on the transparent part 102 is inevitable and needs to be cleaned by the user. However, during use, the user may not be aware of the problem of stains, especially when image recognition is inaccurate. This requires providing a solution that can detect stains on the transparent part 102 of the cooking device 100 and promptly remind the user to clean it.

[0066] Based on this, in one embodiment, Figure 2 As shown, a stain detection method for cooking equipment is provided, and the method is applied to Figure 1 The controller 104 in the embodiment is taken as an example to illustrate, and the following steps are included:

[0067] S202, acquiring a first image acquired by an image acquisition component at a first brightness and a second image acquired at a second brightness.

[0068] Among them, the first brightness and the second brightness are the light intensity of the collection environment when the image collection component is collecting images. The light intensities corresponding to the first brightness and the second brightness are different. For example, the light intensity of the first brightness can be greater than the second brightness, or the light intensity of the second brightness can be greater than the first brightness.

[0069] It can be understood that the realization of the first brightness and the second brightness can be provided by the natural environment. For example, the controller can control the image acquisition component to respectively capture the first image and the second image at different times of the day, such as noon and afternoon, so as to obtain the first image captured at the first brightness and the second image captured at the second brightness. The first brightness and the second brightness can also be provided by an external component. For example, two lighting components can be set on the cooking device, each lighting component has a different lighting intensity. The controller can control the image acquisition component to respectively capture images of the inner pot when different lighting components are running, so as to obtain the first image captured at the first brightness and the second image captured at the second brightness.

[0070] Specifically, the controller controls the image acquisition component to capture the image of the inner tank through the transparent part at a first brightness to obtain a first image, and controls the image acquisition component to capture the image of the inner tank through the transparent part at a second brightness to obtain a second image.

[0071] S204: Perform difference processing on the first image and the second image to obtain difference information between the first image and the second image.

[0072] The differential processing refers to an image processing operation of determining the image difference between the first image and the second image. By performing the differential processing on the first image and the second image, the difference information between the first image and the second image can be obtained.

[0073] Specifically, after obtaining the first image and the second image, the controller may perform differential processing on the first image and the second image based on a preset differential processing method to obtain difference information between the first image and the second image. It is understandable that the difference information may be a pixel difference value or a grayscale difference value of each matching pixel point in the first image and the second image, or a difference image between the first image and the second image.

[0074] In one of the embodiments, a differential processing formula is pre-set in the controller. After obtaining the first image and the second image, differential processing can be performed on the first image and the second image based on the differential processing formula to obtain difference information between the first image and the second image.

[0075] S206: Determine stain information on the transparent element based on imaging changes of images collected at different brightnesses represented by the difference information.

[0076] The stain information is information data used to reflect the condition of stains attached to the transparent part, such as the size of the stain area, the number of stains, the stubbornness of the stains, etc.

[0077] Specifically, since the stains are attached to the transparent part, they will have a blocking effect on the imaging of the image acquisition component. When the brightness of the acquisition environment of the image acquisition component changes, the stains will block the light passing through the transparent part, and the imaging change in the stained area will be smaller than the imaging change in other unobstructed areas. Therefore, after obtaining the difference information, the controller can determine the imaging changes between the images captured by the image acquisition component at different brightness based on the difference information, and determine the stain information on the transparent part.

[0078] For example, if the difference information is the pixel difference value of each matching pixel point in the first image and the second image, then the pixel point in the first image and the second image that is significantly smaller than the other pixel difference values ​​can be determined as a stain pixel point according to the size of the pixel difference value, thereby determining the stain information on the transparent part. If the difference information is a difference image, edge computing can be used to mark the area where the stain exists on the difference image, and the stain area can be obtained by performing edge computing on the difference image. Compared with performing edge computing directly on the collected image, the accuracy of stain detection can be effectively improved.

[0079] S208, when it is determined according to the stain information that the stain on the transparent element meets the reminder condition, a cleaning reminder is given to the user.

[0080] Among them, the reminder condition is a judgment condition for judging whether it is necessary to remind the user to clean the stains. If the stains on the transparent part meet the reminder condition, it means that the stains on the transparent part have affected the imaging effect of the image acquisition component. If it is not cleaned, it is easy to reduce the accuracy of image recognition, thereby reducing the accuracy of intelligent control of cooking equipment. If the stains on the transparent part do not meet the reminder condition, it means that there are no stains or few stains on the transparent part, which has no effect on the imaging effect of the image acquisition component, or has a small effect, and will not reduce the accuracy of image recognition.

[0081] It is understandable that the specific content of the reminder condition can be determined by the designer according to the actual situation. For example, the reminder condition can be that the area of ​​the stain area is larger than the preset area, or the number of stains is larger than the preset number, or the stubbornness of the stain is greater than the preset stubbornness, etc.

[0082] Specifically, after obtaining the stain information, the controller may compare the stain information with the reminder condition. When it is determined according to the stain information that the stain on the transparent part meets the reminder condition, the controller may remind the user to clean.

[0083] In one of the embodiments, when it is determined based on the stain information that the stain on the transparent part meets the reminder condition, the controller can generate and play a prompt voice to remind the user: there are stains on the camera glass. In order for the camera to work properly, please clean and wipe the glass in time.

[0084] In one of the embodiments, when it is determined based on the stain information that the stain on the transparent part meets the reminder condition, the controller can generate a prompt image based on the stain area, and display the prompt image through the display component of the cooking device, showing the location of the stain on the transparent part and prompting the user to clean it.

[0085] In the above-mentioned stain detection method for cooking equipment, the image acquisition component on the cooking equipment acquires an image of the inner pot through a transparent part. In order to detect stains on the transparent part, the controller can obtain a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness, perform differentiation processing on the first image and the second image, and obtain difference information between the first image and the second image. Since the first image and the second image are images acquired by the same image acquisition component through the same transparent part at different brightnesses, when there are stains on the transparent part, the obstruction of the stains will cause the imaging changes of the first image and the second image at different brightnesses to be smaller in the stain obstruction area, while the imaging changes of the area not obstructed by the stains to be larger. Therefore, the controller can determine the stain information on the transparent part based on the imaging changes of the images acquired at different brightnesses represented by the difference information, and remind the user to clean when it is determined according to the stain information that the stains on the transparent part meet the reminder conditions. Stains on transparent parts are detected based on the principle that when there are stains, the transmittance of transparent parts is different, that is, the imaging changes of the stained area are small under different brightness. The whole process only needs to provide light of different brightness to the image acquisition component, and there is no need to use a large amount of training data for deep learning. This improves the accuracy of stain detection in cooking equipment while effectively reducing the cost of stain detection.

[0086] In order to improve the accuracy of stain detection, in one embodiment, S204, performing a difference process on the first image and the second image to obtain difference information between the first image and the second image includes:

[0087] The first image and the second image are gray-scale converted to obtain the first gray-scale image and the second gray-scale image. The pixel difference between the first gray-scale image and the second gray-scale image is calculated to obtain the difference information between the first image and the second image.

[0088] Grayscale conversion refers to the image processing operation of converting the first image and the second image into grayscale images respectively. By grayscale conversion of images, an image originally containing color information can be converted into an image containing only grayscale information, also known as a single-channel image. Unlike color images, grayscale images have only one color channel, in which the grayscale value of each pixel represents the brightness level of the pixel.

[0089] Specifically, after obtaining the first image and the second image, the controller performs grayscale conversion on the first image and the second image respectively to obtain the first grayscale image and the second grayscale image, and then calculates the pixel difference between the first grayscale image and the second grayscale image to obtain difference information between the first image and the second image.

[0090] In one embodiment, the controller may perform grayscale conversion on the first image and the second image respectively based on a preset grayscale conversion tool to obtain a first grayscale image and a second grayscale image.

[0091] In one embodiment, the controller may perform grayscale conversion on the first image and the second image respectively based on a preset grayscale conversion method, such as a weighted average conversion method or a simple average conversion method, to obtain a first grayscale image and a second grayscale image.

[0092] In one embodiment, after obtaining the first grayscale image and the second grayscale image, the controller can respectively calculate the grayscale difference of each matching pixel in the first grayscale image and the second grayscale image, and obtain the difference information of the first image and the second image according to the absolute value of the grayscale difference of each matching pixel. For example, if the first grayscale image contains pixels A1, A2, and A3, and the second grayscale image contains pixels B1, B2, and B3, the difference information of the first image and the second image can be determined according to |A1-B1|, |A2-B2|, and |A3-B3|.

[0093] In the above embodiment, the first image and the second image are firstly grayscale converted to obtain the first grayscale image and the second grayscale image. The grayscale value of each pixel in the first grayscale image and the second grayscale image can represent the brightness level of the pixel. The pixel difference between the first grayscale image and the second grayscale image is subsequently calculated to obtain difference information for characterizing the imaging changes of the images collected at different brightnesses. By performing a difference comparison between the first image and the second image on the grayscale image after the grayscale conversion, the accuracy of determining the difference information can be effectively improved, thereby improving the accuracy of stain detection.

[0094] After obtaining the difference information between the first image and the second image, how to determine the stain information on the transparent part based on the difference information is a key step of the entire stain detection method. The following will illustrate how to determine the stain information on the transparent part through several embodiments.

[0095] In one embodiment, the difference information includes the grayscale difference value of each matching pixel point in the first image and the second image, such as Figure 3 As shown, S206, based on the imaging change between the images collected at different brightness represented by the difference information, determining the stain information on the transparent part includes:

[0096] S302: Determine the average grayscale value of the first image and the second image based on the grayscale difference value of each matching pixel point of the first image and the second image.

[0097] Since the first image and the second image are image data obtained by the image acquisition component at different brightnesses for the same inner liner, there are one-to-one corresponding matching pixels in the first image and the second image. The grayscale difference value of each matching pixel is the absolute value of the grayscale difference obtained by calculating the grayscale difference of each matching pixel in the first grayscale image and the second grayscale image.

[0098] Specifically, after obtaining the grayscale difference value of each matching pixel point of the first image and the second image, the controller may average the grayscale difference value of each matching pixel point of the first image and the second image to obtain the grayscale average value of the first image and the second image.

[0099] S304: When there is a grayscale difference value smaller than the grayscale average value, the matching pixel points whose corresponding grayscale difference values ​​are smaller than the grayscale average value among the matching pixel points are determined as stain pixels.

[0100] Specifically, the grayscale difference value can characterize the imaging changes between images collected under different brightnesses. For example, in the absence of stains, the grayscale value of a first pixel in the first grayscale image is 100, and the grayscale value of a second pixel matching the first pixel in the second grayscale image is 120. At this time, the grayscale difference value of the matching pixels is 20. In the presence of stains, the grayscale value of a first pixel in the first grayscale image is 100. Due to the occlusion of the stains, the grayscale value of the second pixel matching the first pixel in the second grayscale image is 106. At this time, the grayscale difference value of the matching pixels is 6. It can be seen that the smaller the grayscale difference value, the smaller the imaging change of the pixel under different brightness, and the pixel is a stain pixel.

[0101] Therefore, the controller can compare the grayscale difference value of each matching pixel with the grayscale average value. If there is a grayscale difference value less than the grayscale average value, it means that the position corresponding to the matching pixel has a small imaging change under different brightness, and the matching pixel is a stain pixel. The controller can determine the matching pixel whose corresponding grayscale difference value is less than the grayscale average value among the matching pixels as a stain pixel. The position of the stain pixel mapped on the transparent part is the position of the stain, and the area formed by the stain pixel is the stain area on the transparent part.

[0102] S306: Determine stain information on the transparent element based on each stain pixel point.

[0103] Specifically, after determining each stain pixel point, the controller may determine the stain information on the transparent part based on each stain pixel point. For example, when the stain information includes a stain area, the controller may determine the stain area based on the pixel area composed of each stain pixel point. When the stain information includes the number of stains, the controller may determine the number of stains based on the number of pixel areas composed of each stain pixel point. When the stain information includes the stubbornness of the stain, the controller may determine the stubbornness of the stain based on the grayscale average value of the pixel area composed of each stain pixel point. For example, the higher the grayscale average value, the lower the stubbornness of the stain, and the lower the grayscale average value, the higher the stubbornness of the stain.

[0104] In this embodiment, by comparing the grayscale difference value of each matching pixel point between the first image and the second image with the grayscale average value of the first image and the second image, the stain pixel points with smaller imaging changes under different brightness can be quickly determined from each pixel point, thereby effectively improving the detection efficiency of stain information on transparent parts while ensuring the accuracy of stain detection.

[0105] In addition to the above method, in another embodiment, the difference information includes a difference image between the first image and the second image. S206, based on the imaging change between the images collected at different brightness represented by the difference information, determining the stain information on the transparent part includes:

[0106] Based on the pixel value of each pixel point in the difference image between the first image and the second image, the difference image is binarized to obtain an output image. According to the pixel value of each output pixel point on the output image, the stain information on the transparent part is determined.

[0107] The difference image between the first image and the second image is an image obtained by performing a differential calculation on the first grayscale image and the second grayscale image, that is, the controller can obtain the difference image by calculating the pixel difference between the first grayscale image and the second grayscale image.

[0108] Binarization is an image processing method that sets the grayscale value of pixels greater than a certain critical grayscale value to the grayscale maximum value, and sets the grayscale value of pixels less than the critical grayscale value to the grayscale minimum value. By binarizing the difference image, the edge of the stained area can be enhanced, which has a prominent effect on the stained area.

[0109] Specifically, after obtaining the difference image between the first image and the second image, the controller can determine the critical grayscale value for binarization according to the pixel value of each pixel in the difference image, perform binarization on the difference image, and obtain an output image, in which the pixel value of each output pixel in the output image is 255 or 0, that is, white or black. The controller can highlight and distinguish the stain area according to the pixel value of each output pixel on the output image, and determine the stain information on the transparent part. For example, the controller can record the black pixels connected into a non-independent area as a stain, and the number and size of the stains in the output image can be obtained through a simple image processing algorithm.

[0110] In this embodiment, by binarizing the difference image between the first image and the second image, the edge of the stain area can be enhanced, the stain area can be highlighted, and the accuracy and efficiency of the controller in determining the stain information of the transparent part based on the output image can be improved.

[0111] Further, in one embodiment, if Figure 4 As shown, based on the pixel value of each pixel point in the difference image between the first image and the second image, the difference image is binarized to obtain an output image, including:

[0112] S402, dividing the difference image between the first image and the second image into regions based on a preset partitioning method to obtain sub-difference images corresponding to a plurality of image regions.

[0113] Among them, a partitioning method is pre-set in the controller for dividing the difference image between the first image and the second image into regions to obtain multiple sub-difference images. By dividing the difference image into regions, each sub-difference image is used as the detection subject for subsequent stain detection, which effectively improves the stain detection accuracy. The partitioning method can specify the number and size of the divided regions. It is understandable that the specific content of the partitioning method can be determined by the designer according to the actual situation. For example, the designer determines the partitioning method that can meet both the detection accuracy and the computing power of the controller as the preset partitioning method based on the actual detection accuracy requirements and the computing power of the controller.

[0114] Specifically, after obtaining the difference image between the first image and the second image, the controller can call a preset partitioning method, divide the difference image into regions based on the preset partitioning method, and obtain sub-difference images corresponding to multiple image regions. It can be understood that multiple sub-difference images can be pieced together to obtain a difference image.

[0115] S404: For each sub-difference image, obtain a pixel value of each pixel in the sub-difference image.

[0116] Specifically, after obtaining the multiple sub-difference images, the controller may obtain the pixel value of each pixel in each sub-difference image.

[0117] S406, comparing each pixel value with a regional pixel threshold of the image region to which the sub-difference image belongs, to obtain a pixel value comparison result of each pixel point.

[0118] The regional pixel threshold is a threshold parameter determined according to the pixel value of each pixel point in the image area to which the sub-difference image belongs, that is, the critical grayscale value during binarization processing. The regional pixel threshold can be determined according to the brightness difference between the first brightness and the second brightness.

[0119] Specifically, after obtaining the pixel value of each pixel in the sub-difference image, the controller can first determine the regional pixel threshold of the image area to which the sub-difference image belongs based on the pixel value of each pixel and the brightness difference between the first brightness and the second brightness, and compare the pixel value of each pixel in the sub-difference image with the regional pixel threshold to obtain the pixel value comparison result of each pixel.

[0120] S408 , based on the comparison result of each pixel value, binarize the sub-difference image to obtain an output image.

[0121] Specifically, after obtaining the comparison results of each pixel value, the controller can binarize the sub-difference image based on the comparison results of each pixel value. For example, when the pixel value of a pixel point in the image area is greater than the regional pixel threshold, the pixel value of the pixel point can be set to a white pixel value, i.e., 255. When the pixel value of a pixel point in the image area is less than the regional pixel threshold, the pixel value of the pixel point can be set to a black pixel value, i.e., 0, thereby obtaining a sub-output image of the sub-difference image. By splicing the sub-output images, the final output image can be obtained.

[0122] In this embodiment, by partitioning the difference image, when performing stain detection subsequently, the sub-difference image corresponding to each image area is used as the main body for detection, which can effectively improve the detection precision and accuracy of stain detection.

[0123] In one embodiment, the stain detection method for a cooking device further comprises: determining a pixel mean of the sub-difference image according to each pixel value, and determining a regional pixel threshold of the image region to which the difference image belongs based on the pixel mean and the brightness difference between the first brightness and the second brightness.

[0124] Specifically, after obtaining the pixel value of each pixel point in the sub-difference image, the controller can perform mean calculation based on each pixel value to determine the pixel mean of the sub-difference image, and then determine the regional pixel threshold of the image area to which the sub-difference image belongs based on the pixel mean and the brightness difference between the first brightness and the second brightness.

[0125] In one embodiment, the controller may first calculate the pixel average Ave of the sub-difference image according to each pixel value in the sub-difference image, and then calculate the pixel average Ave according to the brightness difference L between the first brightness and the second brightness. hight -L low , and sensitivity adjustment parameter C, calculate the regional pixel threshold Y of the image region to which the sub-difference image belongs, where Y=Ave-(C+(L hight -L low ), the sensitivity adjustment parameter C can be used to adjust the sensitivity of the regional pixel threshold Y. It can be understood that the sensitivity adjustment parameter C can be adjusted by the designer after experiments based on the actual application scenarios and image characteristics. For example, an initial value is first selected, and then the value of C is gradually adjusted through experimental observation results until a satisfactory result is obtained. The C value corresponding to the satisfactory result is determined as the sensitivity adjustment parameter.

[0126] In the above embodiment, the regional pixel threshold of the image area to which the difference image belongs is determined by the pixel mean and the brightness difference between the first brightness and the second brightness. When the difference image is subsequently binarized based on the regional pixel threshold, the accuracy of the binarization processing can be improved, thereby improving the accuracy of stain detection on cooking equipment.

[0127] The above embodiment describes in detail how to determine the stain information on the transparent part based on the imaging changes of the captured images at different brightness represented by the difference information. In order to improve the convenience of image acquisition when detecting stains on the cooking device, in one embodiment, the cooking device also includes a lighting component, and the light brightness of the lighting component includes a first brightness and a second brightness. S202, acquiring a first image captured by the image acquisition component at the first brightness and a second image captured at the second brightness, includes: in response to a start-up instruction for the cooking device, controlling the lighting component to operate at the first brightness, and acquiring the first image captured by the image acquisition component at the first brightness. After the first image is acquired, controlling the lighting component to operate at the second brightness, and acquiring the second image captured by the image acquisition component at the second brightness.

[0128] The illumination component may be any light source providing component capable of achieving two illumination intensities, such as an LED lamp capable of achieving illumination with a first brightness and illumination with a second brightness.

[0129] Specifically, the user can trigger a start-up instruction for the cooking device based on the cooking device. In response to the start-up instruction for the cooking device, the controller first controls the lighting component to operate at the first brightness, provides the first brightness of the light intensity for the acquisition environment of the image acquisition device, and then controls the image acquisition component to acquire an image of the inner pot at the first brightness, and obtains a first image at the first brightness. After the first image is acquired, the controller can continue to control the lighting component to operate at the second brightness, provide the second brightness of the light intensity for the acquisition environment of the image acquisition device, and control the image acquisition component to acquire an image of the inner pot at the second brightness, and obtain a second image at the second brightness. By setting a lighting component that can provide the first brightness and the second brightness at the same time in the cooking device, the first image and the second image can be acquired at the shortest time interval, which effectively reduces the probability of an increase in the difference in image acquisition due to a large time interval, and improves the accuracy and convenience of image acquisition.

[0130] In one embodiment, the stain information includes the area of ​​the stain region and / or the number of stains. S208, when it is determined according to the stain information that the stain on the transparent element meets the reminder condition, a cleaning reminder is given to the user, including: if the area of ​​the stain region is greater than or equal to the preset area, and / or the number of stains is greater than or equal to the preset number, when it is determined that the stain on the transparent element meets the reminder condition, a cleaning reminder is given to the user.

[0131] The preset area and the preset number are both thresholds for judging whether the stain on the transparent part meets the reminder condition. The preset area and the preset number can be determined by the designer according to actual needs.

[0132] Specifically, in one embodiment, if the stain information includes the area of ​​the stain region, the controller may compare the area of ​​the stain region with the area of ​​the preset region after obtaining the area of ​​the stain region on the transparent member. If the area of ​​the stain region is greater than or equal to the area of ​​the preset region, it is determined that the stain on the transparent member meets the reminder condition, and a cleaning reminder is given to the user. If the area of ​​the stain region is less than the area of ​​the preset region, it is determined that the stain on the transparent member does not meet the reminder condition, and no reminder is required.

[0133] In one embodiment, if the stain information includes the number of stains, the controller may compare the number of stains with a preset number after obtaining the number of stains on the transparent element. If the number of stains is greater than or equal to the preset number, it is determined that the stains on the transparent element meet the reminder condition, and a cleaning reminder is given to the user. If the number of stains is less than the preset number, it is determined that the stains on the transparent element do not meet the reminder condition, and no reminder is required.

[0134] In one of the embodiments, if the stain information includes the stain area and the number of stains, then after obtaining the stain area and the number of stains on the transparent part, the controller can compare the stain area with the preset area, and compare the number of stains with the preset number. When the stain area is greater than or equal to the preset area, and the number of stains is greater than or equal to the preset number, it is determined that the stains on the transparent part meet the reminder conditions, and the user is reminded to clean.

[0135] In one of the embodiments, if the stain information includes the stain area and the number of stains, then after obtaining the stain area and the number of stains on the transparent part, the controller can compare the stain area with the preset area, and compare the number of stains with the preset number. When the stain area is greater than or equal to the preset area, or the number of stains is greater than or equal to the preset number, it is determined that the stains on the transparent part meet the reminder conditions, and the user is reminded to clean.

[0136] In the above embodiment, by setting a preset area and / or a preset number, it is possible to quickly determine whether the stain on the transparent part meets the reminder condition after obtaining the stain information of the transparent part, thereby effectively improving the judgment efficiency of the reminder condition.

[0137] In one embodiment, a stain detection method for a cooking device is provided, and the method is applied to Figure 5 The steam oven 500 shown is taken as an example for description. In one embodiment, the steam oven 500 includes a high-definition camera 501, laminated glass 502, an LED light 503 and a controller 104. The high-definition camera 501 can capture images of the inner container of the steam oven 500 through the laminated glass 502.

[0138] like Figure 6 As shown, the method specifically comprises the following steps:

[0139] First, the controller 504 responds to the start-up instruction for the steam oven 500 and controls the LED light 503 inside the steam oven 500 to light up. low The brightness is turned on, and then the high-definition camera 501 is controlled to capture an image to obtain a first image. After obtaining the first image, the LED light 503 is controlled to be L light The brightness is turned on, and after the brightness is stable, the high-definition camera 502 is controlled to capture an image to obtain a second image.

[0140] The controller 504 performs grayscale conversion on the first image and the second image to obtain a first grayscale image and a second grayscale image, and calculates a pixel difference between the first grayscale image and the second grayscale image to obtain a difference image diff.

[0141] Since the image of the stain area is less different under different brightness illumination, the grayscale value of the pixel in the stain area is smaller than the grayscale value of other areas in the difference image diff map. Therefore, the difference image diff map can be further processed based on this feature. Specifically, the controller 504 first performs partition processing on the difference image diff map to obtain each sub-difference image. For each sub-difference image, the controller 504 obtains the pixel value of each pixel point in the sub-difference image, calculates the pixel mean Ave of the sub-difference image based on each pixel value, and then calculates the pixel mean Ave, L low and L hight The difference and sensitivity adjustment parameter C are used to calculate the regional pixel threshold Y of the sub-difference image corresponding to the image area, where Y=Ave-(C+(L hight -L low )).

[0142] After obtaining the regional pixel threshold Y, the controller 504 compares each pixel value of the sub-difference image with the regional pixel threshold Y, sets the pixel value greater than the regional pixel threshold Y to white (255), and sets the pixel value less than the regional pixel threshold Y to black (0), to obtain the final output image output. The image processing process is shown in the figure. Figure 7 As shown, Figure 7 The cloud-like pattern in FIG. 5 is used to represent the stain area of ​​the laminated glass 502 .

[0143] After obtaining the output image, the controller 504 can count the number and size of the stain areas according to the output image. Specifically, black pixels that are connected into a piece and not existing alone can be recorded as one stain. According to this principle, the number and size of the stains in the output image can be obtained through a simple image processing algorithm. After obtaining the number and size of the stain areas, it can be determined whether the stains on the laminated glass 502 meet the reminder conditions based on the number and size of the stain areas. If so, the user is reminded to clean. If not, the stain detection is completed.

[0144] In this embodiment, by comparing the difference characteristics of camera imaging under light of different brightness, it is determined whether stains exist and the proportion of stains is statistically calculated, thereby solving the problem of low-cost and high-efficiency detection of glass stains.

[0145] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0146] Based on the same inventive concept, the embodiment of the present application also provides a stain detection device for a cooking device for implementing the stain detection method for a cooking device involved above. The implementation solution provided by the device to solve the problem is similar to the implementation solution recorded in the above method, so the specific limitations in the embodiments of one or more stain detection devices for cooking devices provided below can refer to the limitations of the stain detection method for cooking devices above, and will not be repeated here.

[0147] In one embodiment, Figure 8 As shown, a stain detection device 800 for cooking equipment is provided, comprising: an image acquisition module 801, a differentiation processing module 802, a stain information determination module 803 and a reminder module 804, wherein:

[0148] The image acquisition module 801 is used to acquire a first image acquired by an image acquisition component at a first brightness and a second image acquired at a second brightness.

[0149] The difference processing module 802 is used to perform difference processing on the first image and the second image to obtain difference information between the first image and the second image.

[0150] The stain information determination module 803 is used to determine the stain information on the transparent element based on the imaging changes of the images collected at different brightnesses represented by the difference information.

[0151] The reminder module 804 is used to remind the user to clean the transparent part when it is determined according to the stain information that the stain on the transparent part meets the reminder condition.

[0152] In the above-mentioned stain detection device for cooking equipment, the image acquisition component on the cooking equipment acquires an image of the inner pot through a transparent part. In order to detect stains on the transparent part, the controller can obtain a first image acquired by the image acquisition component at a first brightness and a second image acquired at a second brightness, perform differentiation processing on the first image and the second image, and obtain difference information between the first image and the second image. Since the first image and the second image are images acquired by the same image acquisition component through the same transparent part at different brightnesses, when there are stains on the transparent part, the obstruction of the stains will cause the imaging changes of the first image and the second image at different brightnesses to be smaller in the stain obstruction area, while the imaging changes of the area not obstructed by the stains to be larger. Therefore, the controller can determine the stain information on the transparent part based on the imaging changes of the images acquired at different brightnesses represented by the difference information, and remind the user to clean when it is determined according to the stain information that the stains on the transparent part meet the reminder conditions. Stains on transparent parts are detected based on the principle that when there are stains, the transmittance of transparent parts is different, that is, the imaging changes of the stained area are small under different brightness. The whole process only needs to provide light of different brightness to the image acquisition component, and there is no need to use a large amount of training data for deep learning. This improves the accuracy of stain detection in cooking equipment while effectively reducing the cost of stain detection.

[0153] In one embodiment, the difference processing module is used to: perform grayscale conversion on the first image and the second image to obtain the first grayscale image and the second grayscale image; calculate the pixel difference between the first grayscale image and the second grayscale image to obtain difference information between the first image and the second image.

[0154] In one embodiment, the difference information includes the grayscale difference value of each matching pixel point in the first image and the second image. The stain information determination module is used to: determine the grayscale average value of the first image and the second image based on the grayscale difference value of each matching pixel point in the first image and the second image; in the case where there is a grayscale difference value less than the grayscale average value, determine the matching pixel points whose corresponding grayscale difference values ​​are less than the grayscale average value in each matching pixel point as stain pixels; and determine the stain information on the transparent part based on each stain pixel point.

[0155] In one embodiment, the difference information includes a difference image between the first image and the second image. The stain information determination module is used to: perform binarization processing on the difference image based on the pixel value of each pixel point in the difference image between the first image and the second image to obtain an output image; and determine the stain information on the transparent part according to the pixel value of each output pixel point on the output image.

[0156] In one embodiment, the stain information determination module is further used to: divide the difference image between the first image and the second image into regions based on a preset partitioning method to obtain sub-difference images corresponding to multiple image regions; for each sub-difference image, obtain the pixel value of each pixel in the sub-difference image; compare each pixel value with the regional pixel threshold of the image region to which the sub-difference image belongs to obtain a pixel value comparison result of each pixel; based on the comparison results of each pixel value, binarize the sub-difference image to obtain an output image.

[0157] In one embodiment, the stain detection device of the cooking device further comprises:

[0158] The pixel mean value determination module is used to determine the pixel mean value of the sub-difference image according to each pixel value.

[0159] The regional pixel threshold determination module is used to determine the regional pixel threshold of the image area to which the difference image belongs based on the pixel mean value and the brightness difference between the first brightness and the second brightness.

[0160] In one embodiment, the cooking device further comprises a lighting component, and the light brightness of the lighting component comprises a first brightness and a second brightness. The image acquisition module is used to: in response to a start-up instruction for the cooking device, control the lighting component to operate at the first brightness, and acquire a first image acquired by the image acquisition component at the first brightness; after the first image acquisition is completed, control the lighting component to operate at the second brightness, and acquire a second image acquired by the image acquisition component at the second brightness.

[0161] In one embodiment, the stain information includes the area of ​​the stain region and the number of stains. The reminder module is used to: if the area of ​​the stain region is greater than or equal to the preset area, and / or the number of stains is greater than or equal to the preset number, it is determined that the stain on the transparent part meets the reminder condition, and then remind the user to clean.

[0162] Each module in the stain detection device of the cooking device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each module.

[0163] In one embodiment, a computer device is provided. The computer device may be a controller, and its internal structure diagram may be as follows: Fig. 9As shown. The computer device includes a processor, a memory and a network interface connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data such as the first image, the second image, difference information, stain information, and reminder conditions. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a stain detection method for a cooking device is implemented.

[0164] Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0165] In one embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor implements the specific implementation steps of the stain detection method for cooking equipment when executing the computer program.

[0166] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the specific implementation steps of the stain detection method for cooking equipment are realized.

[0167] In one embodiment, a computer program product is provided, including a computer program, which, when executed by a processor, implements the specific implementation steps of the stain detection method for cooking equipment.

[0168] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties. In addition, the acquisition, storage, processing, and transmission of data are in compliance with relevant laws and regulations.

[0169] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0170] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0171] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A stain detection method for a cooking device, the cooking device comprising an image acquisition component, a transparent member, a lighting component and an inner pot, the image acquisition component performs image acquisition on the inner pot through the transparent member, the light brightness of the lighting component comprises a first brightness and a second brightness, characterized in that: The method comprises: In response to a start-up instruction for the cooking device, controlling the illumination component to operate at the first brightness, and acquiring a first image captured by the image acquisition component at the first brightness; After the first image is acquired, controlling the illumination component to operate at the second brightness, and acquiring a second image acquired by the image acquisition component at the second brightness; performing difference processing on the first image and the second image to obtain difference information between the first image and the second image; Based on the imaging changes of the images collected at different brightnesses represented by the difference information, the stain information on the transparent member is determined; when there is stain on the transparent member, the light transmittance of the transparent member is different, and the imaging changes of the stained area at different brightnesses are smaller than the imaging changes of other unobstructed areas at different brightnesses; When it is determined according to the stain information that the stain on the transparent element meets the reminder condition, a cleaning reminder is given to the user.

2. The method according to claim 1, characterized in that: The performing difference processing on the first image and the second image to obtain difference information between the first image and the second image includes: Performing grayscale conversion on the first image and the second image to obtain a first grayscale image and a second grayscale image; Calculate the pixel difference between the first grayscale image and the second grayscale image to obtain difference information between the first image and the second image.

3. The method according to claim 2, characterized in that The difference information includes a grayscale difference value of each matching pixel point in the first image and the second image; The determining of the stain information on the transparent element based on the imaging change of the images collected at different brightnesses represented by the difference information includes: Determine the grayscale average value of the first image and the second image based on the grayscale difference value of each matching pixel point of the first image and the second image; In the case where there is a grayscale difference value smaller than the grayscale average value, among the matching pixel points, the matching pixel points whose corresponding grayscale difference values ​​are smaller than the grayscale average value are determined as stain pixels; Based on each of the stain pixels, stain information on the transparent element is determined.

4. The method according to claim 2, characterized in that: The difference information includes a difference image between the first image and the second image; The determining of the stain information on the transparent element based on the imaging change of the image collected at different brightness represented by the difference information includes: Based on the pixel value of each pixel point in the difference image between the first image and the second image, binarize the difference image to obtain an output image; The stain information on the transparent element is determined according to the pixel value of each output pixel point on the output image.

5. The method according to claim 4, characterized in that The step of binarizing the difference image based on the pixel value of each pixel point in the difference image between the first image and the second image to obtain an output image comprises: Based on a preset partitioning method, dividing the difference image between the first image and the second image into regions to obtain sub-difference images corresponding to a plurality of image regions; For each of the sub-difference images, obtaining a pixel value of each pixel in the sub-difference image; Compare each of the pixel values ​​with a regional pixel threshold of the image region to which the sub-difference image belongs, to obtain a pixel value comparison result of each of the pixel points; Based on the pixel value comparison results, the sub-difference images are binarized to obtain an output image.

6. The method according to claim 5, characterized in that The method further comprises: Determining a pixel mean of the sub-difference image according to each of the pixel values; A regional pixel threshold of an image region to which the difference image belongs is determined based on the pixel mean value and a brightness difference value between the first brightness and the second brightness.

7. The method according to any one of claims 1 to 6, characterized in that: The stain information includes the stain area and the stain quantity; When it is determined according to the stain information that the stain on the transparent element meets the reminder condition, reminding the user to clean the transparent element includes: If the area of ​​the stain region is greater than or equal to the preset area, and / or the number of stains is greater than or equal to the preset number, it is determined that the stains on the transparent part meet the reminder conditions, and a cleaning reminder is given to the user.

8. A stain detection device for a cooking device, the cooking device comprising an image acquisition component, a transparent member, a lighting component and an inner pot, the image acquisition component performs image acquisition on the inner pot through the transparent member, the light brightness of the lighting component comprises a first brightness and a second brightness, characterized in that: The device comprises: an image acquisition module, configured to, in response to a start-up instruction for the cooking device, control the illumination component to operate at the first brightness, and acquire a first image acquired by the image acquisition component at the first brightness; after the acquisition of the first image is completed, control the illumination component to operate at the second brightness, and acquire a second image acquired by the image acquisition component at the second brightness; A difference processing module, used to perform difference processing on the first image and the second image to obtain difference information between the first image and the second image; A stain information determination module is used to determine the stain information on the transparent member based on the imaging changes of the images collected at different brightnesses represented by the difference information; when there is stain on the transparent member, the light transmittance of the transparent member is different, and the imaging changes of the stained area at different brightnesses are smaller than the imaging changes of other unobstructed areas at different brightnesses; The reminder module is used to remind the user to clean when it is determined according to the stain information that the stain on the transparent element meets the reminder condition.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

11. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

12. A cooking device, characterized in that: The cooking device comprises an image acquisition component, a transparent member, an inner pot, a lighting component, and a controller respectively connected to the image acquisition component and the lighting component for communication; The image acquisition component acquires an image of the inner container through the transparent member; The illumination component is used to provide illumination of a first brightness or a second brightness to the image acquisition area of ​​the image acquisition component; The controller implements the stain detection method for a cooking device as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method for determining clean or dirty captured images, system and computer readable storage medium

    CN109840911A

  • Remnant detection method, related equipment and storage medium

    CN113673454A