Adaptive trimming method, system and equipment for urea-formaldehyde products
By introducing machine vision and deep learning technologies into the adaptive edge trimming method, combining fuzzy control and genetic algorithms, dynamically adjusting edge trimming parameters, the problems of poor real-time and insufficient adaptability in the existing technology are solved, and higher edge trimming accuracy and real-time performance are achieved.
Patent Information
- Application Number
- CN202411295576.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-18
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2044-09-18
AI Technical Summary
The existing adaptive edge trimming methods face the problems of poor real-time performance and difficulty in dealing with various interferences in production environments in practice. Especially when dealing with products with complex shapes and different materials, the accuracy and robustness still need to be improved.
Adaptive edge trimming method based on machine vision and deep learning is adopted, and image recognition and analysis of the edge edges of urea formaldehyde products are performed, trimming parameters are dynamically adjusted, and trimming parameters are optimized using fuzzy control algorithms and genetic algorithms to improve trimming accuracy and real-time performance.
Improve the accuracy and real-timeness of the trimming path, enhance the adaptability to different product shapes and materials, reduce the requirements for computing resources, and improve the processing capacity in the production environment.
Smart Images

Figure CN118823296B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing, and in particular to an adaptive trimming method, system and equipment for urea-formaldehyde products. Background Art
[0002] Urea-formaldehyde resin is a common thermosetting resin widely used in the manufacturing process of various industrial and daily necessities. Due to its excellent bonding properties, low cost and good mechanical properties, urea-formaldehyde resin is widely used in the production of plywood, particleboard, fiberboard and some home decoration materials. However, in the manufacturing process of urea-formaldehyde resin products, the trimming process is particularly important. Trimming refers to the process of removing excess material in the process of making products so that the product reaches the predetermined size and shape. Reasonable and effective trimming methods can not only improve the aesthetics of the product, but also enhance its performance. At present, the trimming methods of urea-formaldehyde products mainly include mechanical trimming and laser trimming. Mechanical trimming usually uses a tool or a grinding wheel for cutting and grinding. Its working principle is to remove excess material by mechanical force. However, this method has some problems, such as fast tool wear, low trimming accuracy, and the possibility of generating a large amount of dust and noise, which affects the operating environment and worker health. Laser trimming uses a high-energy laser beam to melt and vaporize excess material, with high precision and cleanliness, but its equipment cost is high, and the heat-affected zone of the material may cause local performance degradation of the product.
[0003] In order to solve the above problems, some studies in recent years have proposed adaptive trimming methods based on image processing and machine learning. These methods automatically adjust the trimming path by image recognition and analysis of the edges of the product to improve the trimming accuracy and efficiency. However, the existing adaptive trimming methods still face some challenges in practice. For example, these methods usually rely on a large amount of high-quality image data for model training, and obtaining sufficient data may require a lot of time and cost. In addition, the accuracy and robustness of existing image processing algorithms when processing products with complex shapes and different materials still need to be improved. In response to these problems, some methods have been tried to solve them. For example, the use of multiple sensor fusion technologies can improve the accuracy and robustness of image recognition; the use of reinforcement learning and transfer learning technologies can train models with higher performance on limited data sets; and the introduction of more advanced image processing algorithms, such as deep convolutional neural networks (CNNs) and generative adversarial networks (GANs), can improve the recognition ability of complex shapes. However, compared with the adaptive trimming methods for urea-formaldehyde products, these methods still have some defects in practical applications, such as high requirements for computing resources, poor real-time performance, and difficulty in handling various interferences in the production environment.
[0004] Therefore, there is an urgent need for a technical solution that can improve the accuracy and real-time performance of the trimming path and improve the adaptability to different product shapes and materials. Summary of the invention
[0005] In order to solve the deficiencies of the prior art, the embodiments of the present application provide an adaptive trimming method, system and device for urea-formaldehyde products. The present application solves the technical problems of the prior art such as poor real-time performance and difficulty in handling various interferences in the production environment.
[0006] An embodiment of the present application provides an adaptive trimming method for urea-formaldehyde products, comprising: acquiring an image of the urea-formaldehyde product based on preset light source parameters and camera parameters to pre-process the image; wherein the pre-processing comprises: decomposing the image into multiple wavelength components to modulate each wavelength component according to a quantum efficiency curve of the camera, and compensating using the spectral power distribution of the light source; weightedly reconstructing the compensated classification using a dynamic weight function to perform mapping processing through a nonlinear function; extracting edge features from the pre-processed image to analyze the edge state; adaptively adjusting the trimming parameters using a fuzzy control algorithm based on the analysis results; and controlling the trimming equipment to perform the trimming operation according to the adaptively adjusted trimming parameters.
[0007] In a possible implementation, the dynamic weight function includes: ,in, represents the wavelength, Indicates the exposure time, Indicates the aperture value, Indicates light sensitivity. represents the maximum sensitive wavelength of the camera sensor, Indicates the maximum aperture value of the camera. Indicates the base ISO value.
[0008] In a possible implementation, edge feature extraction is performed on the preprocessed image to analyze the edge state, including: performing Gaussian filtering on the image to calculate the gradient amplitude and direction using an operator; setting the pixels of non-local maxima to zero and retaining the pixels of local maxima through the gradient amplitude of adjacent pixels in the gradient direction; performing edge connection based on dual threshold detection to detect the edge of the urea-formaldehyde product in the image; using the detected edge to extract edge features including edge length, edge curvature, edge roughness and edge corners; dividing the edge categories based on a machine learning algorithm and the edge features to analyze the edge state; wherein the categories include normal edges, slight burrs, severe burrs, missing corners and cracks.
[0009] In a possible implementation, edge connection is performed based on dual threshold detection to detect the edge of a urea-formaldehyde product in an image, including: setting two thresholds including a high threshold and a low threshold; marking pixels above the high threshold as strong edges, and marking pixels below the low threshold as non-edges; checking pixels between the high threshold and the low threshold, and if the pixels are connected to a strong edge, marking them as edges; eliminating the remaining non-edge pixels to retain edge pixels and strong edge pixels.
[0010] In a possible implementation, edge features including edge length, edge curvature, edge roughness and edge corners are extracted using the detected edge, including: calculating the total number of edge pixels and converting it into actual length based on the image resolution; calculating the edge curvature using a preset algorithm; calculating the average deviation from the edge pixels to the fitting curve as a roughness indicator; and using the Harris corner detection algorithm to identify corners on the edge to calculate the number and distribution of corners.
[0011] In a possible implementation, the preset algorithm includes: ,in, represents the edge curvature, (x1, y1) represents the coordinates of the first point on the curve, (x2, y2) represents the coordinates of the second point on the curve, and (x3, y3) represents the coordinates of the third point on the curve.
[0012] In a possible implementation, a fuzzy control algorithm is used to adaptively adjust the trimming parameters based on the analysis results, including: using a rule library to infer edge features and categories, and obtaining precise trimming parameters through a preset conversion algorithm; constructing a target optimization function to optimize member function parameters and rule weights using a genetic algorithm.
[0013] In a possible implementation, the preset conversion algorithm includes: ,in, Indicates the target exact value, represents the membership degree of the i-th rule, represents the output value corresponding to the i-th rule, Indicates the system running time. represents the weight fluctuation frequency of the i-th rule, represents the phase offset of the i-th rule.
[0014] The embodiment of the present application also provides an adaptive trimming system for urea-formaldehyde products, comprising: an image acquisition unit, an image processing unit and a trimming unit; wherein the image acquisition unit is used to acquire images of urea-formaldehyde products based on preset light source parameters and camera parameters; the image processing unit is used to pre-process the images; wherein the pre-processing comprises: decomposing the image into multiple wavelength components to modulate each wavelength component according to the quantum efficiency curve of the camera, and compensating using the spectral power distribution of the light source; weightedly reconstructing the compensated classification using a dynamic weight function to perform mapping processing through a nonlinear function; extracting edge features from the pre-processed image to analyze the edge state; and adaptively adjusting the trimming parameters using a fuzzy control algorithm based on the analysis results; and the trimming unit is used to control the trimming equipment to perform the trimming operation according to the adaptively adjusted trimming parameters.
[0015] An embodiment of the present application also provides an adaptive trimming device for urea-formaldehyde products, comprising: a processor, a memory, and a system bus; wherein the processor and the memory are connected via the system bus; the memory is used to store one or more programs, and the one or more programs include instructions, which, when executed by the processor, enable the processor to execute the method described in the above embodiment.
[0016] In the adaptive trimming method, system and device for urea-formaldehyde products provided above, the embodiments of the present application can improve the accuracy and real-time performance of the trimming path by using a high-resolution camera and a faster image processing algorithm. Furthermore, in some embodiments, an adaptive algorithm based on artificial intelligence is introduced, and the adaptability to different product shapes and materials can be improved through continuous learning and optimization. The present application introduces exposure time and temperature factors through a dynamic weight function to increase adaptability to environmental changes. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0018] Figure 1 A schematic flow chart of an adaptive trimming method for urea-formaldehyde products provided in an embodiment of the present application;
[0019] Figure 2 A schematic diagram of a flow chart of a method for adaptively adjusting trimming parameters provided in an embodiment of the present application;
[0020] Figure 3A schematic block diagram of an adaptive trimming system for urea-formaldehyde products provided in an embodiment of the present application. DETAILED DESCRIPTION
[0021] Various exemplary embodiments of the present application will now be described in detail with reference to the accompanying drawings. It should be noted that unless otherwise specifically stated, the relative arrangement of components and steps, numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present application.
[0022] Those skilled in the art will appreciate that the terms "first", "second" and the like in the embodiments of the present application are only used to distinguish different steps, devices or modules, etc., and do not represent any specific technical meaning, nor do they represent the necessary logical order between them. It should also be understood that in the embodiments of the present application, "multiple" may refer to two or more, and "at least one" may refer to one, two or more. It should also be understood that for any component, data or structure mentioned in the embodiments of the present application, in the absence of explicit limitation or contrary revelation given in the context, it can generally be understood as one or more. In addition, the term "and / or" in the present application is only a kind of association relationship describing the associated objects, indicating that there can be three kinds of relationships, for example, A and / or B, which can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in the present application generally indicates that the associated objects before and after are an "or" relationship. It should also be understood that the description of each embodiment in the present application emphasizes the differences between the embodiments, and the same or similar parts can refer to each other. For the sake of brevity, they will not be repeated one by one.
[0023] At the same time, it should be understood that, for ease of description, the sizes of the various parts shown in the drawings are not drawn according to the actual proportional relationship. The following description of at least one exemplary embodiment is actually only illustrative and is by no means intended to limit the present application and its application or use. The techniques, methods and devices known to ordinary technicians in the relevant fields may not be discussed in detail, but where appropriate, the techniques, methods and devices should be considered as part of the specification. It should be noted that similar numbers and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further discussed in subsequent drawings.
[0024] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings 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 ordinary technicians in this field without creative work are within the scope of protection of this application.
[0025] Figure 1 A flow chart of an adaptive trimming method for urea-formaldehyde products provided in an embodiment of the present application. It should be understood that urea-formaldehyde products often need to be trimmed during the production process to ensure the dimensional accuracy and appearance quality of the product. Traditional trimming methods often rely on fixed parameter settings, which are difficult to adapt to the differences between different batches of products and easily cause problems such as insufficient or excessive trimming. Therefore, the development of a trimming method that can be adaptively adjusted is of great significance to improving the production efficiency and quality of urea-formaldehyde products. The present application scheme aims to design an adaptive trimming method based on machine vision and deep learning, which dynamically adjusts the trimming parameters by analyzing the edge features of the product in real time to achieve accurate and efficient trimming processing.
[0026] like Figure 1 As shown, at step S101, an image of the urea-formaldehyde product is collected based on preset light source parameters and camera parameters to pre-process the image. Specifically, a high-resolution industrial camera can be used to shoot the urea-formaldehyde product to obtain a clear image of the area to be trimmed. The camera parameters are set as follows: resolution: 4096×3072 pixels, frame rate: 60fps, exposure time: 10ms, aperture: f / 5.6. At the same time, to ensure image quality, an LED ring light source can be used to provide uniform lighting, and the light source parameters are as follows: color temperature: 5500K, brightness: 50000lux, uniformity: >95%.
[0027] The collected raw images are then preprocessed to improve the accuracy and efficiency of subsequent analysis. The image is decomposed into multiple wavelength components to modulate each wavelength component according to the camera's quantum efficiency curve and compensated using the spectral power distribution of the light source; the compensated classification is weighted and reconstructed using a dynamic weight function to perform mapping processing through a nonlinear function. Specifically, the different wavelength components of the image are dynamically modulated using the camera's spectral response curve and the spectral distribution of the light source, thereby enhancing specific features of the image.
[0028] First, perform spectral decomposition to decompose the input image into multiple wavelength components I(λ), where λ is the wavelength. The camera response is modulated, and each wavelength component is modulated according to the camera's quantum efficiency curve Q(λ): I'(λ)=I(λ)*Q(λ). Light source compensation. Use the spectral power distribution S(λ) of the light source for compensation: I''(λ)=I'(λ) / S(λ). Dynamic weight allocation, introduce the dynamic weight function W, and perform weighted reconstruction: Finally, nonlinear mapping is performed and the nonlinear function f is applied for final processing: , where f can be a function similar to sigmoid.
[0029] This preprocessing method takes into account the spectral characteristics of the camera and light source, and can better restore the real scene. The exposure time and temperature factors are introduced through the dynamic weight function to increase the adaptability to environmental changes. Nonlinear mapping can enhance the image details in a specific range.
[0030] It should be noted that the implementation of this preprocessing method requires accurate camera spectral response curves, accurate light source spectral distribution data, and real-time exposure time. Although this method has high computational complexity, it has the potential to provide image quality superior to traditional methods in specific application scenarios (such as precision industrial inspection). Its uniqueness lies in the integration of spectral information, camera characteristics, and environmental factors into a unified preprocessing framework.
[0031] In one embodiment, the dynamic weight function comprises: ,in, represents the wavelength, Indicates the exposure time, Indicates the aperture value, Indicates light sensitivity. represents the maximum sensitive wavelength of the camera sensor, Indicates the maximum aperture value of the camera. Represents the base ISO value. The weighting function takes into account the following factors: wavelength dependence, retaining the original sine function to ensure that different wavelengths have different weights. Exposure time, using log(E + 1) instead of log(E) to avoid problems when E=0. This still reflects the impact of exposure time, but avoids over-emphasizing long exposures. Aperture, introducing When the aperture value A is close to the maximum aperture When the aperture is small, this term is close to 1; when the aperture is small, this term decreases. This reflects the characteristic that large apertures can usually capture more details. ISO sensitivity, add The higher the ISO, the greater the weight, but a square root is used to slow the rate of increase, reflecting the increase in noise at higher ISOs.
[0032] This new weight function better reflects the key parameters in actual photography. It takes into account the influence of the three elements of exposure (aperture, shutter speed, ISO). Consideration of sensitivity to different wavelengths is retained. The ambient temperature factor is removed to make the formula more focused on camera settings and optical characteristics. This weight function can better adapt to different shooting conditions. For example, higher weights will be given in low-light environments (large aperture, long exposure, high ISO). For different spectral ranges, it can be optimized according to the characteristics of the camera sensor. In this way, the pre-processing step of this application can more accurately adjust the image according to the actual shooting parameters.
[0033] At step S102, edge feature extraction is performed on the preprocessed image to analyze the edge state. First, the image is subjected to Gaussian filtering to calculate the gradient amplitude and direction using an operator. The pixels of non-local maxima are set to zero by the gradient amplitude of adjacent pixels in the gradient direction, and the pixels of local maxima are retained. Edge connection is performed based on dual threshold detection to detect the edge of the urea-formaldehyde product in the image. In one embodiment, it includes: setting two thresholds including a high threshold and a low threshold; marking pixels above the high threshold as strong edges, and marking pixels below the low threshold as non-edges; checking pixels between the high threshold and the low threshold, and if the pixels are connected to a strong edge, marking them as edges; eliminating the remaining non-edge pixels to retain edge pixels and strong edge pixels.
[0034] Furthermore, the input image is subjected to Gaussian filtering to reduce the impact of noise on edge detection. Gaussian filtering performs a convolution operation on the image through a Gaussian kernel function to achieve image smoothing. The formula is as follows: ,in, is the standard deviation, which determines the smoothness of the filter. Next, calculate the gradient magnitude and direction of each pixel in the image. The gradient reflects the change in the grayscale value of the image, and the Sobel operator can be used to calculate the gradient: , the calculation formula of gradient amplitude and direction is as follows: .
[0035] In order to obtain refined edges, non-maximum suppression is required. This step checks the gradient magnitude of adjacent pixels in the gradient direction, sets the pixels that are not local maxima to zero, and retains the pixels that are local maxima.
[0036] The last step is double threshold detection and edge connection. Two thresholds are set: high threshold and low threshold. Pixels above the high threshold are marked as strong edges, pixels below the low threshold are marked as non-edges, and pixels between the two are marked as edges if they are connected to strong edges, otherwise they are marked as non-edges.
[0037] The specific steps are as follows: Mark strong edges, pixels above the high threshold. Check the pixels between the high threshold and the low threshold, and if they are connected to a strong edge, mark them as edges. Eliminate the remaining non-edge pixels. By completing the edge detection algorithm through these four steps, accurate edge information in the image can be obtained.
[0038] Next, the detected edge is used to extract edge features including edge length, edge curvature, edge roughness and edge corners. In one embodiment, the total number of edge pixels is calculated and converted to actual length according to the image resolution. The edge curvature is calculated using a preset algorithm, wherein the preset algorithm includes: ,in, Represents the edge curvature, (x1, y1) represents the coordinates of the first point on the curve, (x2, y2) represents the coordinates of the second point on the curve, and (x3, y3) represents the coordinates of the third point on the curve. Numerator: (x2 - x1)(y3 - y1) - (x3- x1)(y2 - y1), this part calculates twice the area of the triangle formed by the three points, which reflects the degree to which the three points deviate from the straight line. Denominator: , which is the cube of the distance from point 1 to point 2, acts as a normalization so that the curvature is independent of the scaling of the curve. The coefficient 2 is to adjust the size of the final result. In summary, this formula gives a measure of the degree of curvature of the curve at that point by comparing the area of the triangle and the distance between the points. Then, the average deviation of the edge pixels to the fitted curve is calculated as a roughness indicator. Finally, the Harris corner detection algorithm is used to identify the corners on the edge to calculate the number and distribution of corners.
[0039] After the analysis is completed, the edge is classified based on the machine learning algorithm and the edge features to analyze the edge status; wherein the categories include normal edge, slight burr, severe burr, chipped corner and crack. In one implementation scenario, the support vector machine (SVM) algorithm can be used to classify the extracted edge features and divide the edge status into the above five categories. The decision function of the SVM classifier is: ,in, is the Lagrange multiplier, is the category label, Kernel function, b is the bias term.
[0040] In step S103, based on the analysis results, the fuzzy control algorithm is used to adaptively adjust the trimming parameters (such as Figure 2 The specific method will be shown in Figure 2 Specifically, the rule base is used to infer edge features and categories, and the precise trimming parameters are obtained through the preset conversion algorithm; the target optimization function is constructed to optimize the member function parameters and rule weights using the genetic algorithm.
[0041] At step S104, the trimming equipment is controlled to perform the trimming operation according to the trimming parameters adjusted adaptively. The trimming equipment includes: high-speed spindle: speed range (6000 - 24000rpm), power (5.5kW); servo feed system: maximum feed speed (30m / min), positioning accuracy (±0.01mm); tool system: tool type (carbide milling cutter), tool diameter (6mm), number of blades (4). During the trimming process, the following parameters are monitored in real time: spindle current, feed force, vibration frequency, and processing temperature.
[0042] In addition, after the trimming is completed, the machine vision system can be used to detect the trimming quality online. Use a laser displacement sensor to scan along the edge and calculate the root mean square deviation (RMSD) of the edge profile: ,in, is the height of the measuring point, is the average height, and n is the number of measurement points. Use a high-precision CCD camera to measure the key dimensions of the product and calculate the deviation from the standard dimension: The roughness parameter Ra of the trimmed surface was measured using a confocal microscope: , where L is the sampling length and Z(x) is the profile height function.
[0043] The quality inspection results can also be fed back to the control system for further optimization of trimming parameters. The recursive least squares (RLS) algorithm is used to identify and update the system model online:
[0044] ;
[0045] ;
[0046] ,
[0047] in, is the parameter estimate, is the gain matrix, is the covariance matrix, and λ is the forgetting factor. Through continuous data collection and model updating, the system can continuously adapt to changes in product characteristics and maintain the best trimming effect.
[0048] Through the scheme of the embodiment of the present application, the trimming parameters can be automatically adjusted according to the characteristics of different batches of products, and the adaptability is strong. Through accurate edge feature analysis and parameter optimization, a high-precision trimming effect can be achieved. The degree of automation is high, manual intervention is reduced, and production efficiency is improved. Closed-loop control and continuous optimization strategies are adopted to ensure long-term stable trimming quality. This method is not only applicable to urea-formaldehyde products, but can also be promoted and applied to other products that require precise trimming.
[0049] Figure 2 A schematic diagram of a flow chart of a method for adaptively adjusting trimming parameters provided in an embodiment of the present application. Figure 2 As shown, at step S201, edge features and categories are inferred using a rule base, and precise trimming parameters are obtained through a preset conversion algorithm.
[0050] Specifically, the input variables are: edge roughness (R), burr degree (B), and chip degree (C).
[0051] Output variables: trimming speed (V), trimming depth (D).
[0052] Fuzzy rule base: Design a series of if-then rules, such as:
[0053] If R is high and B is low and C is low then V is fast and D is shallow;
[0054] If R is low and B is high and C is low then V is slow and D is deep;
[0055] If R is low and B is low and C is high then V is medium and D is medium.
[0056] Fuzzy reasoning: Mamdani fuzzy reasoning method is adopted, and the minimum-maximum synthesis rule is used for reasoning.
[0057] Defuzzification: Convert the fuzzy output to precise trimming parameter values using a preset conversion algorithm.
[0058] In one embodiment, the preset conversion algorithm includes:
[0059] ,
[0060] in, Indicates the target exact value, represents the membership degree of the i-th rule, represents the output value corresponding to the i-th rule, Indicates the system running time. represents the weight fluctuation frequency of the i-th rule, Represents the phase shift of the i-th rule. This formula introduces the time variable t to make the output dynamic. The sine function is used to introduce periodic fluctuations to simulate the natural fluctuations of the system. Each rule has its own frequency and phase, which increases the complexity and adaptability of the system.
[0061] Applied to the specific example, for each fuzzy rule, in addition to the membership and output value In addition, it is also necessary to define the frequency of its weight fluctuation and phase shift .
[0062] For example, for the rule "if R is high and B is low and C is low then V is fast and D is shallow":
[0063] ;
[0064] = Typical value for fast trimming speed;
[0065] = Typical value for shallow trimming depth;
[0066] (lower frequency, slower speed change);
[0067] (higher frequency, faster depth changes);
[0068] ;
[0069] (phase shift, making depth and velocity changes out of sync),
[0070] For the trimming speed V and trimming depth D, the preset formulas are applied respectively:
[0071] ; ,
[0072] As time t changes, the output V and D will fluctuate within a certain range, simulating the dynamic changes in the actual processing process. The advantage of this method is that it takes into account the time factor, making the output more dynamic. By adjusting the frequency and phase, the interaction and interference between different rules can be simulated. A certain degree of randomness is introduced to make the system more sensitive to environmental changes. It can better simulate the fluctuations and uncertainties in the actual processing process.
[0073] In an implementation scenario, there are the following specific situations:
[0074] enter:
[0075] Edge roughness (R) = 7 (out of 10)
[0076] Burr level (B) = 3 (out of 10)
[0077] Degree of notch (C) = 2 (out of 10)
[0078] Step 1: Fuzzification
[0079] First, we need to convert the exact input value into a fuzzy set. Assume that we have the following fuzzy sets:
[0080] R: {low, medium, high}
[0081] B: {Low, Medium, High}
[0082] C: {Low, Medium, High}
[0083] Using the triangular membership function, we get:
[0084] R(7) = {Low: 0, Medium: 0.3, High: 0.7}
[0085] B(3) = {Low: 0.7, Middle: 0.3, High: 0}
[0086] C(2) = {Low: 0.8, Medium: 0.2, High: 0}
[0087] Step 2: Apply fuzzy rules
[0088] Using the three rules defined in the previous example:
[0089] Rule 1: If R is high and B is low and C is low, then V is fast and D is shallow
[0090] Rule 2: If R is low and B is high and C is low, then V is slow and D is deep
[0091] Rule 3: If R is low and B is low and C is high, then V is medium and D is medium
[0092] Calculate the activation strength of each rule:
[0093] Rule 1: Take the minimum value (0.7, 0.7, 0.8) = 0.7
[0094] Rule 2: Take the minimum value (0, 0, 0.8) = 0
[0095] Rule 3: Take the minimum value (0, 0.7, 0) = 0
[0096] Step 3: Fuzzy Reasoning
[0097] Since only Rule 1 is activated, only the output of this rule needs to be considered.
[0098] Assume the following output fuzzy sets:
[0099] V: {slow: 20, medium: 50, fast: 80} (unit: mm / s)
[0100] D: {Light: 0.5, Medium: 1.0, Deep: 1.5} (Unit: mm)
[0101] Step 4: Apply the preset algorithm
[0102] For Rule 1, define:
[0103] v1_V = 80 (fast)
[0104] v1_D = 0.5 (shallow)
[0105] ω1_V = 0.1
[0106] ω1_D = 0.2
[0107] φ1_V = 0
[0108] φ1_D = π / 4
[0109] Assume the current time t = 10s
[0110] Apply the preset algorithm formula:
[0111] ;
[0112] ,
[0113] Step 5: Output Interpretation
[0114] The final precise output is:
[0115] Trimming speed (V) ≈ 80 mm / s
[0116] Depth of trimming (D) ≈ 0.5 mm
[0117] This result shows that the system recommends a faster trimming speed and a shallower trimming depth due to high edge roughness but low burr and chipping. Over time, the output value will fluctuate within a certain range: V will fluctuate around 80mm / s, with a small fluctuation range and a long cycle. D will fluctuate around 0.5mm, with a large fluctuation range and a short cycle. This dynamic output can help the system adapt to small changes in the processing process and improve the stability of processing quality.
[0118] Through this example, we can see how the dynamic weight fluctuation method combines fuzzy logic with time-varying systems to produce output that takes into account both rule strength and temporal dynamics. This method is more flexible than the traditional center of gravity method and can better simulate the dynamic changes in the actual machining process.
[0119] At step S202, a target optimization function is constructed to optimize the member function parameters and rule weights using a genetic algorithm. To further improve the trimming effect, a genetic algorithm can be introduced to optimize the parameters of the fuzzy control system. The optimization target function is: , where Q is the trimming quality score, T is the trimming time, C is the trimming cost, and w1, w2, and w3 are weight coefficients.
[0120] The main steps of the genetic algorithm include: population initialization, fitness evaluation, selection operation, crossover operation, mutation operation and termination condition judgment. Through multiple generations of iteration, the member function parameters and rule weights of the fuzzy control system are continuously optimized to obtain the best trimming effect.
[0121] Figure 3A schematic block diagram of an adaptive trimming system for urea-formaldehyde products provided in an embodiment of the present application. It should be understood that the system shown in the figure is exemplary and not restrictive. This means that the system architecture involved is not limited to a specific form or design, but is presented as an example. In other words, the architecture shown in the figure can be regarded as a way of expression to clearly describe related concepts and relationships, and does not exclude other forms of architecture. Therefore, when interpreting the architecture in the picture, it should be understood that the model is flexible and diverse, and its purpose is to provide an exemplary description rather than a restrictive provision on a specific form.
[0122] Specifically, it includes an image acquisition unit 301, an image processing unit 302 and a trimming unit 303. The image acquisition unit 301 acquires an image of the urea-formaldehyde product based on preset light source parameters and camera parameters. The image processing unit 302 pre-processes the image; wherein the pre-processing includes: decomposing the image into multiple wavelength components to modulate each wavelength component according to the quantum efficiency curve of the camera, and using the spectral power distribution of the light source for compensation; weighted reconstruction of the compensated classification using a dynamic weight function to perform mapping processing through a nonlinear function; edge feature extraction of the pre-processed image to analyze the edge state; and adaptive adjustment of the trimming parameters using a fuzzy control algorithm based on the analysis results. The trimming unit 303 controls the trimming equipment to perform the trimming operation according to the adaptively adjusted trimming parameters.
[0123] Furthermore, an embodiment of the present application also provides an adaptive trimming device for urea-formaldehyde products, comprising: a processor, a memory, and a system bus; the processor and the memory are connected via the system bus; the memory is used to store one or more programs, the one or more programs comprising instructions, which, when executed by the processor, enable the processor to execute any of the above methods.
[0124] Furthermore, an embodiment of the present application also provides a computer program product, which, when executed on a terminal device, enables the terminal device to execute any one of the above-mentioned processing methods.
[0125] It can be known from the description of the above implementation mode that those skilled in the art can clearly understand that all or part of the steps in the above-mentioned embodiment method can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., including several instructions for enabling a computer device (which can be a personal computer, a server, or a network communication device such as a media gateway, etc.) to execute the methods described in the various embodiments of the present application or certain parts of the embodiments.
[0126] It should be noted that the various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the various embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.
[0127] It should also be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0128] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. An adaptive trimming method for urea-formaldehyde products, characterized in that: include: Acquiring an image of the urea-formaldehyde product based on preset light source parameters and camera parameters to pre-process the image; The preprocessing includes: decomposing the image into multiple wavelength components, modulating each wavelength component according to the quantum efficiency curve of the camera, and compensating using the spectral power distribution of the light source; weighting and reconstructing the compensated classification using a dynamic weight function to perform mapping processing through a nonlinear function; the dynamic weight function includes: , in, represents the wavelength, Indicates the exposure time, Indicates the aperture value, Indicates light sensitivity. represents the maximum sensitive wavelength of the camera sensor, Indicates the maximum aperture value of the camera. Indicates the base ISO value; Edge feature extraction is performed on the preprocessed image to analyze the edge status, including: Performing Gaussian filtering on the image to calculate gradient magnitude and direction using an operator; By using the gradient magnitude of adjacent pixels in the gradient direction, the pixels that are not local maxima are set to zero, and the pixels that are local maxima are retained; Edge connection is performed based on double threshold detection to detect the edge of urea-formaldehyde products in the image; Using the detected edge to extract edge features including edge length, edge curvature, edge roughness and edge corners; Classifying the edge based on the machine learning algorithm and the edge features to analyze the edge status; wherein the categories include normal edge, slight burr, severe burr, chipped corner and crack; Based on the analysis results, the fuzzy control algorithm is used to adaptively adjust the trimming parameters, including: The edge features and categories are inferred using the rule base, and precise trimming parameters are obtained through a preset conversion algorithm; wherein the preset conversion algorithm includes: , in, Indicates the target exact value, represents the membership degree of the i-th rule, represents the output value corresponding to the i-th rule, Indicates the system running time. represents the weight fluctuation frequency of the i-th rule, represents the phase shift of the i-th rule; Constructing a target optimization function to optimize membership function parameters and rule weights using genetic algorithms; The trimming device is controlled to perform a trimming operation according to the adaptively adjusted trimming parameters.
2. The adaptive trimming method according to claim 1, characterized in that: in, Edge connection is performed based on dual threshold detection to detect the edge of urea-formaldehyde products in the image, including: Setting two thresholds including a high threshold and a low threshold; Mark pixels above a high threshold as strong edges, and pixels below a low threshold as non-edges; Check pixels between a high threshold and a low threshold, and mark them as edges if they are connected to a strong edge; The remaining non-edge pixels are eliminated to retain edge pixels and strong edge pixels.
3. The adaptive trimming method according to claim 1, characterized in that: in, The detected edges are used to extract edge features including edge length, edge curvature, edge roughness and edge corners, including: Calculate the total number of edge pixels and convert them into actual length according to the image resolution; Calculate edge curvature using a preset algorithm; Calculate the average deviation from the edge pixels to the fitting curve as a roughness index; Harris corner detection algorithm is used to identify corners on the edge to calculate the number and distribution of corners.
4. The adaptive trimming method according to claim 3, characterized in that: The preset algorithms include: , in, represents the edge curvature, (x1, y1) represents the coordinates of the first point on the curve, (x2, y2) represents the coordinates of the second point on the curve, and (x3, y3) represents the coordinates of the third point on the curve.
5. An adaptive trimming system for urea-formaldehyde products, used to implement the adaptive trimming method according to any one of claims 1 to 4, characterized in that: include: An image acquisition unit, an image processing unit and a trimming unit; wherein, The image acquisition unit is used to acquire images of urea-formaldehyde products based on preset light source parameters and camera parameters; The image processing unit is used to preprocess the image; wherein the preprocessing includes: decomposing the image into multiple wavelength components, modulating each wavelength component according to the quantum efficiency curve of the camera, and compensating using the spectral power distribution of the light source; weighting and reconstructing the compensated classification using a dynamic weight function to perform mapping processing through a nonlinear function; extracting edge features from the preprocessed image to analyze the edge state; and adaptively adjusting the trimming parameters using a fuzzy control algorithm based on the analysis results; The trimming unit is used to control the trimming device to perform a trimming operation according to the adaptively adjusted trimming parameters.
6. An adaptive trimming device for urea-formaldehyde products, characterized in that: include: A processor, a memory, and a system bus; wherein the processor and the memory are connected via the system bus; The memory is used to store one or more programs, wherein the one or more programs include instructions, and when the instructions are executed by the processor, the processor executes the method according to any one of claims 1 to 4.
Citation Information
Patent Citations
Machine vision cutting method applied to laser cutting machine
CN108875740A
Insulator fitting trimming method and system based on image processing
CN114638847A