Intelligent control method and system of egg liquid spraying machine
Through intelligent control methods, the monitoring image of the egg sprayer is processed, dirty areas are divided and cleaning evaluation is calculated, which solves the problem that stained areas cannot be accurately identified and cleaned in the existing technology, and achieves efficient and accurate cleaning effects.
Patent Information
- Application Number
- CN202411636117.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-15
- Publication Date
- 2025-03-11
- Estimated Expiration
- 2044-11-15
AI Technical Summary
The existing egg sprayer cannot accurately identify and clean the stained areas on the tray, resulting in unclear cleaning.
Intelligent control method is adopted to divide dirty areas through monitoring image processing, calculate cleaning evaluation, and control the cleaning device to accurately clean the dirty areas.
Accurate identification and secondary cleaning of residual stain areas is achieved, unnecessary cleaning times are reduced, and cleaning efficiency and quality are improved.
Smart Images

Figure CN119600533A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing, and in particular to an intelligent control method and system for an egg liquid spraying machine. Background Art
[0002] In the food production process, it is sometimes necessary to apply or spray egg liquid on the surface of the food. For example, a layer of egg liquid is provided on the surface of bread so that the bread is baked to have a golden color.
[0003] In the prior art, a Chinese patent with publication number CN108522567A discloses a CNC program-controlled egg spraying machine, which includes: a main frame, a variable speed motor, a recovery box, a transmission roller, a beam, an outer cover, an exhaust motor, a mounting frame, an exhaust pipe and a spray head. Food is placed on a tray and transferred to the bottom of the spray head through the transmission roller. The food is sprayed with egg liquid through the spray head. After completion, the spray head can clean the tray on which the food is placed by spraying clean water or cleaning liquid.
[0004] However, in the process of cleaning the tray, after one cleaning, the tray may not be cleaned thoroughly, and there may still be stained areas with residual egg liquid on the tray. The existing technology cannot accurately identify the stained areas for secondary cleaning. Summary of the invention
[0005] In order to solve the technical problem that the stained area cannot be accurately identified for secondary cleaning, the present application provides an intelligent control method and system for an egg liquid sprayer.
[0006] In the first aspect, the present application provides an intelligent control method for an egg liquid spraying machine, which adopts the following technical solution: An intelligent control method for an egg liquid spraying machine comprises the following steps: dividing a dirty area after processing a monitoring image; calculating a cleaning evaluation of the dirty area; in response to the cleaning evaluation being less than an evaluation threshold, controlling a preset cleaning device to clean the dirty area; the calculation method for the cleaning evaluation comprises the following steps: taking the ratio of the number of pixel points in the same dirty area in adjacent frame monitoring images as a quantity ratio; calculating the gradient value of each pixel point in the dirty area, taking the ratio of the maximum value to the minimum value of the gradient value as a gradient value ratio, and taking the difference of the gradient value ratios in adjacent frame monitoring images as a ratio difference; taking the absolute values of the difference between the quantity ratio and 1 and the ratio difference, respectively, and multiplying them to obtain a product, and taking the sum of the normalized result of the product and a preset bias factor as the dirtiness evaluation.
[0007] The beneficial effects are: through quantitative cleaning evaluation, it is determined whether a secondary cleaning is needed and the location of the cleaning, and the dirty area can be monitored in real time. Through intelligent control, a precise secondary cleaning is performed on the remaining stained area after one cleaning, and secondary cleaning is performed only when necessary, which reduces the number of unnecessary cleaning times, improves cleaning efficiency, ensures that the expected cleaning effect can be achieved, and improves cleaning quality.
[0008] Optionally, the method for dividing the dirty area includes the steps of: calculating the dirtiness coefficient of each pixel point, replacing the pixel value of the pixel point with the dirtiness coefficient corresponding to each pixel point, and obtaining a dirtiness coefficient map; obtaining the maximum value in each row and column of the dirtiness coefficient map, taking the pixel point corresponding to the maximum value as the starting point, and performing continuous gradient descent at a preset angle until the gradient drops to less than or equal to zero, thereby obtaining the boundary point, and the closed interval formed by connecting all the boundary points is the dirty area.
[0009] The beneficial effect is that during the cleaning process, the egg liquid residue will have a tailing area, which is the area left by the egg liquid that has not been completely cleaned. The characteristic is that there is a yellow gradient area, that is, the yellow color gradually changes from dark to light until it disappears completely. In the process of gradient, the gradient decreases continuously from the center point of the dirty area to the surrounding area, so the area with continuous gradient decreases is regarded as the dirty area.
[0010] Optionally, the calculation formula for the dirtiness coefficient is: ,in, For the The dirtiness coefficient of each pixel, For the The color channel vector of pixels, The color channel vector of the egg liquid pixel value.
[0011] Optionally, the method for obtaining the color channel vector of the egg liquid pixel value is: obtaining an egg liquid pool image; calculating the Euclidean distance between the pixel value of the pixel point in the egg liquid pool image and the standard yellow pixel value; and using the pixel values of the three channels of the pixel point with the smallest Euclidean distance as the three elements in the color channel vector of the egg liquid pixel value.
[0012] The beneficial effect is: the Euclidean distance between the color of the egg liquid in the egg liquid pool and the pixel value of the standard yellow is calculated. The standard yellow is not used directly because there will be color differences between different batches of egg liquid. If the standard yellow is used, the accuracy of the subsequent results will be reduced. And the influence of bubbles on the surface of the egg liquid in the egg liquid pool is avoided, so as to accurately collect the color characteristics of the egg liquid in the egg liquid pool, which is convenient for the subsequent analysis of the egg liquid residue by color characteristics.
[0013] Optionally, the method for calculating the gradient value of each pixel in the dirty area is: calculating the ratio of the dirtiness coefficients corresponding to the pixel and the pixels in its eight neighborhoods, and retaining the smallest ratio as the gradient value of the pixel.
[0014] The beneficial effect is that retaining the minimum ratio as the gradient value can enhance the contrast between the dirty area and the clean area in the image, making the dirty area more obvious and easier to observe and process.
[0015] Optional, expression for the bias factor: ,in, is the bias factor, is the set of gradient values of the dirty area in the next frame of the adjacent frame monitoring image, is the maximum value function, is the minimum function, Indicates a preset constant.
[0016] Optionally, the evaluation threshold and the bias factor have the same value.
[0017] In the second aspect, the present application provides an intelligent control system for an egg liquid spraying machine, which adopts the following technical solution: An intelligent control system for an egg liquid spraying machine comprises: a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the intelligent control method for the egg liquid spraying machine is implemented.
[0018] The beneficial effect is that the intelligent control method of the egg liquid spraying machine is generated into a computer program and stored in a memory so as to be loaded and executed by a processor, thereby making a system based on the memory and the processor for easy use.
[0019] This application has the following technical effects: 1. Through quantitative cleaning evaluation, it can determine whether secondary cleaning is needed and the location of cleaning, and can monitor the dirty area in real time. Through intelligent control, a pair of residual stain areas can be accurately cleaned for the second time after one cleaning, and secondary cleaning is only performed when necessary, which reduces the number of unnecessary cleaning times, improves cleaning efficiency, ensures that the expected cleaning effect can be achieved, and improves cleaning quality.
[0020] 2. During the cleaning process, the egg liquid residue will have a tailing area. The tailing area is the area left by the egg liquid that has not been completely cleaned. The characteristic is the presence of a yellow gradient area, that is, the yellow color gradually changes from dark to light until it disappears completely. In the process of gradient, the gradient decreases from the center point of the dirty area to the surrounding area, so the area with a continuous gradient decrease is regarded as the dirty area. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] By reading the detailed description below with reference to the accompanying drawings, the above and other purposes, features and advantages of the exemplary embodiments of the present application will become easily understood. In the accompanying drawings, several embodiments of the present application are shown in an exemplary and non-restrictive manner, and the same or corresponding numbers represent the same or corresponding parts.
[0022] Figure 1 It is a method flow chart of an intelligent control method of an egg liquid spraying machine according to an embodiment of the present application.
[0023] Figure 2 It is a flow chart of a method for dividing dirty areas in an intelligent control method of an egg liquid sprayer in an embodiment of the present application.
[0024] Figure 3 It is a flow chart of a method for calculating cleaning evaluation in an intelligent control method for an egg liquid spraying machine in an embodiment of the present application. DETAILED DESCRIPTION
[0025] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present application.
[0026] It should be understood that when the terms "first", "second", etc. are used in the claims, specification and drawings of the present application, they are only used to distinguish different objects, rather than to describe a specific order. The terms "include" and "comprise" used in the specification and claims of the present application indicate the presence of the described features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or their collections.
[0027] The present application embodiment discloses an intelligent control method for an egg liquid spraying machine, and the application scenario is: after the egg liquid spraying machine cleans the tray once, it identifies the residual egg liquid area on the tray, and adaptively changes the cleaning position and frequency to accurately clean the residual egg liquid area. Figure 1 , including steps S1 to S3, which are specifically as follows: S1: After processing the monitoring image, the dirty area is divided.
[0028] Cameras are set directly above the tray and directly above the egg liquid pool to obtain monitoring images of the tray and the egg liquid pool. The monitoring image is obtained by extracting frames from the monitoring video to obtain multiple frames of monitoring images. The frame extraction frequency can be set according to the actual application scenario. For example, 60 frames are extracted per second.
[0029] The color channel vector of the egg liquid pixel value is obtained according to the egg liquid pool image. The acquisition method is: Calculate the Euclidean distance between the pixel value of the pixel point in the egg liquid pool image and the standard yellow pixel value. For example, set the pixel value of the pixel point in the egg liquid pool image to , represents the pixel value of the red channel, represents the pixel value of the green channel, Represents the pixel value of the blue channel. The standard yellow pixel value is (255,255,0).
[0030] The calculation of the Euclidean distance is a prior art and will not be described in detail here. The pixel values of the three channels of the pixel point with the smallest Euclidean distance are used as the three elements in the color channel vector of the egg liquid pixel value. Exemplarily, the color channel vector can be (255, 255, 0).
[0031] The above steps are to avoid the influence of bubbles on the surface of the egg liquid in the egg liquid pool, so as to accurately collect the color characteristics of the egg liquid in the egg liquid pool, so as to facilitate the subsequent analysis of the egg liquid residue by color characteristics.
[0032] Reference Figure 2 The method for dividing the dirty area includes steps S10 and S11: S10: Calculate the dirtiness coefficient of each pixel point, and replace the pixel value of the pixel point with the dirtiness coefficient corresponding to each pixel point to obtain a dirtiness coefficient map.
[0033] The calculation formula of the dirtiness coefficient is: ,in, For the The dirtiness coefficient of each pixel, For the The color channel vector of pixels, The color channel vector of the egg liquid pixel value. It indicated and The cosine similarity of .
[0034] S11: Obtain the maximum value in each row and column of the dirt coefficient map, take the pixel point corresponding to the maximum value as the starting point, perform continuous gradient descent at a preset angle until the gradient drops to less than or equal to zero, and obtain the boundary point. The closed interval formed by connecting all the boundary points is the dirty area.
[0035] In one embodiment, the preset angle is , , and , the polygonal area formed by the four angle directions is the dirty area.
[0036] S2: Calculate the cleaning rating of the dirty area. Figure 3 , including steps S20 to S22: S20: taking the ratio of the number of pixels in the same dirty area in the monitoring images of adjacent frames as the quantity ratio.
[0037] S21: Calculate the gradient value of each pixel in the dirty area, take the ratio of the maximum value to the minimum value of the gradient value as the gradient value ratio, and take the difference of the gradient value ratios in adjacent frame monitoring images as the ratio difference.
[0038] In one embodiment, the method for calculating the gradient value of each pixel in the dirty area is: calculating the ratio of the dirt coefficients corresponding to the pixel and its eight neighborhoods, and retaining the smallest ratio as the gradient value of the pixel. The eight neighborhoods refer to the neighborhood consisting of eight pixels around a pixel. Specifically, it includes the neighboring pixels above, below, left, right and four diagonal directions of the pixel.
[0039] During the cleaning process, the egg liquid residue will have a tailing area. The tailing area is the area left by the egg liquid that has not been completely cleaned. The characteristic is the presence of a yellow gradient area, that is, the yellow color gradually changes from dark to light until it disappears completely. In the process of gradient change, the gradient decreases from the center point of the dirty area to the surrounding area, and the gradual change of the gradient is calculated as the dirtiness evaluation of the dirty area.
[0040] S22: taking the absolute values of the difference between the quantity ratio and 1 and the ratio difference, respectively, and multiplying them to obtain a product, and taking the sum of the normalized result of the product and the preset bias factor as the dirtiness evaluation.
[0041] In one embodiment, the calculation formula of the bias factor is: ,in, is the bias factor, is the set of gradient values of the dirty area in the next frame of the adjacent frame monitoring image, is the maximum value function, is the minimum function, Indicates a preset constant, for example, Take 0.5. When the ratio of the maximum and minimum gradients in the dirty area is less than 0.95, it means that the dirty area has been cleaned and the bias factor is 0.5. Otherwise, it is determined that it needs to be cleaned again and the bias factor is 0.
[0042] In one embodiment, the expression of dirtiness evaluation is: ,in, is the dirtiness evaluation of any dirty area, is the number of pixels of the dirty area in the previous frame monitoring image, is the number of pixels of the dirty area in the subsequent frame image, is the gradient value set of the dirty area in the previous frame image, is the gradient value set of the dirty area in the subsequent frame image, is the maximum value function, is the minimum function, is the bias factor, is the hyperbolic tangent function.
[0043] S3: In response to the cleaning evaluation being less than the evaluation threshold, controlling a preset cleaning device to clean the dirty area.
[0044] In one embodiment, the evaluation threshold is set to be the same as the value of the bias factor, that is, the dirt evaluation threshold is set to 0.5. When the cleaning evaluation threshold is greater than 0.5, the cleaning device is controlled to clean the dirty area again, otherwise, no cleaning is performed. In one embodiment, the dirty area on the tray to be cleaned can be moved to below the nozzle of the cleaning device by a conveying device for cleaning, or the position of the nozzle of the cleaning device can be adjusted to move it above the dirty area of the tray to be cleaned.
[0045] The embodiment of the present application also discloses an intelligent control system for an egg liquid sprayer, including a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the intelligent control method for the egg liquid sprayer according to the present application is implemented.
[0046] The above system also includes other components well known to those skilled in the art, such as a communication bus and a communication interface, and their configuration and functions are known in the art, so they will not be described in detail here.
[0047] In the present application, the aforementioned memory may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, apparatus, or device. For example, a computer-readable storage medium may be any appropriate magnetic storage medium or magneto-optical storage medium, such as a resistive random access memory RRAM (Resistive Random Access Memory), a dynamic random access memory DRAM (Dynamic Random Access Memory), a static random access memory SRAM (Static Random Access Memory), an enhanced dynamic random access memory EDRAM (Enhanced Dynamic Random Access Memory), a high bandwidth memory HBM (High Bandwidth Memory), a hybrid memory cube HMC (Hybrid Memory Cube), etc., or any other medium that can be used to store the required information and can be accessed by an application, a module, or both. Any such computer storage medium may be part of a device or accessible or connectable to a device.
[0048] Although this specification has shown and described a plurality of embodiments of the present application, it is obvious to those skilled in the art that such embodiments are provided by way of example only. Those skilled in the art will think of many changes, modifications and alternatives without departing from the thought and spirit of the present application. It should be understood that in the process of practicing the present application, various alternatives to the embodiments of the present application described herein may be adopted.
[0049] The above are all preferred embodiments of the present application, and the protection scope of the present application is not limited thereto. Therefore, any equivalent changes made according to the structure, shape, and principle of the present application should be included in the protection scope of the present application.
Claims
1. An intelligent control method for an egg liquid spraying machine, characterized in that: Includes steps: After processing the monitoring image, the dirty area is divided; a cleaning evaluation of the dirty area is calculated; in response to the cleaning evaluation being less than an evaluation threshold, a preset cleaning device is controlled to clean the dirty area; The calculation method of the cleaning evaluation includes the following steps: The ratio of the number of pixels in the same dirty area in adjacent frame monitoring images is used as the quantity ratio; Calculate the gradient value of each pixel in the dirty area, take the ratio of the maximum value to the minimum value of the gradient value as the gradient value ratio, and take the difference of the gradient value ratios in adjacent frame monitoring images as the ratio difference; The absolute values of the difference between the quantity ratio and 1 and the ratio difference are taken respectively and then multiplied to obtain the product, and the sum of the normalized result of the product and the preset bias factor is used as the dirtiness evaluation.
2. The intelligent control method of the egg liquid spraying machine according to claim 1, characterized in that: The method of demarcating the dirty area comprises the steps of: Calculate the dirtiness coefficient of each pixel point, and replace the pixel value of the pixel point with the dirtiness coefficient corresponding to each pixel point to obtain a dirtiness coefficient map; Get the maximum value in each row and column of the dirt coefficient map, take the pixel point corresponding to the maximum value as the starting point, perform continuous gradient descent at a preset angle until the gradient drops to less than or equal to zero, and get the boundary point. The closed interval formed by connecting all the boundary points is the dirty area.
3. The intelligent control method of the egg liquid spraying machine according to claim 2, characterized in that: The calculation formula of the dirtiness coefficient is: ,in, For the The dirtiness coefficient of each pixel, For the The color channel vector of pixels, The color channel vector of the egg liquid pixel value.
4. The intelligent control method of the egg liquid spraying machine according to claim 3, characterized in that: The method for obtaining the color channel vector of the egg liquid pixel value is: Acquire an image of the egg pool; Calculate the Euclidean distance between the pixel value of the pixel point in the egg pool image and the standard yellow pixel value; The pixel values of the three channels of the pixel point with the smallest Euclidean distance are used as the three elements in the color channel vector of the egg liquid pixel value.
5. The intelligent control method of the egg liquid spraying machine according to any one of claims 1 to 4, characterized in that: The method for calculating the gradient value of each pixel in the dirty area is: calculate the ratio of the dirtiness coefficients of the pixel and the pixels in its eight neighborhoods, and retain the smallest ratio as the gradient value of the pixel.
6. The intelligent control method of the egg liquid spraying machine according to any one of claims 1 to 4, characterized in that: The expression of the bias factor is: ,in, is the bias factor, is the set of gradient values of the dirty area in the next frame of the adjacent frame monitoring image, is the maximum value function, is the minimum function, Indicates a preset constant.
7. The intelligent control method of the egg liquid spraying machine according to claim 6, characterized in that: The evaluation threshold has the same value as the bias factor.
8. An intelligent control system for an egg liquid spraying machine, characterized in that: include: A processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the intelligent control method of the egg liquid spraying machine according to any one of claims 1-7 is implemented.
Citation Information
Patent Citations
Numerical control program-controlled egg spraying machine
CN108522567A
Certificate image quality evaluation method and terminal
CN114120343A
Lens dirt identification method and device, computer equipment and storage medium
CN114359414A
Intelligent detection method for smudginess of carbon electrode under vision assistance
CN116758071A
Liquid leakage detection method and system
CN118071735A
Cited By
Stain detection method for fresh egg cleaning
CN120259310A
A stain detection method for fresh egg cleaning
CN120259310B