Wooden door sanding roughness intelligent detection method and system
By dynamically adjusting the gain and constructing a wood grain reference map, combined with phase compensation analysis and defect trajectory tracking, the problems of wood grain texture confusion and light interference in the sanding inspection of wooden doors were solved, achieving high-precision sanding quality assessment and defect location.
Patent Information
- Application Number
- CN202511447016.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-11
- Publication Date
- 2026-02-06
AI Technical Summary
In the existing technology for inspecting the sanding quality of wooden doors, the confusion between wood grain texture and sanding defect characteristics leads to a high rate of missed detection, the dynamic interference of ambient light causes an increase in the false alarm rate, and the inability to quantify the spatial trajectory of micro-defects leads to a large deviation in roughness scoring.
By acquiring high-resolution image data of the sanded surface of wooden doors, dynamic gain adjustment is performed based on regional brightness distribution to construct a wood grain reference map. A surface gradient map is generated by combining phase compensation analysis. Synthetic samples are generated by using the geometric matching rules between wood grain direction and sanding defects. Texture attribute decoupling and defect trajectory tracking are performed to output roughness score and defect coordinates.
It achieves intelligent and high-precision inspection of the sanding quality of wooden doors, overcomes interference from light and wood grain background, accurately describes the scratch trajectory, and improves the automation and accuracy of the inspection.
Smart Images

Figure CN121481931A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent surface quality detection technology in the wood products manufacturing industry, and in particular to an intelligent detection method and system for sanding roughness of wooden doors. Background Technology
[0002] The sanding quality inspection of wooden doors needs to achieve precise control in a dynamic industrial environment: the light intensity of the production line fluctuates from 100 to 1000 lux, and the natural wood grain direction (randomly distributed from 0° to 180°) can easily cover sanding scratches with a width of ≤0.3mm. At the same time, it is necessary to output the roughness quantitative score (0-100 level) and the coordinates of the defect location in real time to meet the real-time requirements of the intelligent manufacturing system for closed-loop feedback of process parameters.
[0003] The current industry uses hyperspectral imaging fusion 3D point cloud analysis technology, which is implemented as follows: spectral images in the 400-1000nm band are acquired by a hyperspectral camera, and a millimeter-level precision point cloud is generated by combining structured light projection; the spatial correlation between spectral absorption features and point cloud height abrupt change regions is extracted; a random forest model is used to fuse multimodal data, a defect classifier is trained based on historical samples, and a roughness estimate is output.
[0004] The solution faces three technical bottlenecks: First, the absorption peak shift in the spectral image is caused by interference from the ambient light in the workshop, which makes the wood grain texture and sanding scratches confused in the feature layer, resulting in a high false alarm rate. Second, point cloud reconstruction is sensitive to sudden changes in illumination, and local height jump artifacts increase the false alarm rate. Third, the lack of geometric correlation modeling between the wood grain structure and the real defects makes it impossible to quantify the offset trajectory of the scratches relative to the wood grain, resulting in a large average deviation in roughness scores and a very small defect location error. Summary of the Invention
[0005] This application provides an intelligent detection method and system for the sanding roughness of wooden doors, which solves the problems in the prior art, such as high false negative rate caused by confusion between wood grain texture and sanding defect characteristics, increased false alarm rate caused by dynamic interference from ambient light, and large roughness scoring deviation caused by the inability to quantify the spatial trajectory of micro-defects.
[0006] Firstly, this application provides an intelligent detection method for the sanding roughness of wooden doors, including: High-resolution image data of the sanded surface of wooden doors are acquired. Under varying lighting conditions, dynamic gain is dynamically adjusted based on the regional brightness distribution of the sanded surface and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. Simultaneously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on multi-angle interference images to generate a surface gradient map of quantified micro-undulations. Based on the graded adjusted image data and the surface gradient map, a cross-modal data pair is constructed, and a synthetic sample simulating sanding defects is generated using physical constraints containing the geometric matching rules of wood grain direction and sanding defects. Spatial decoupling of texture attributes is performed on the synthetic sample to separate gloss reflection features and deformation structure features. Combined with the wood grain reference map, the decoupled deformation structure features are used to achieve wood grain-guided defect trajectory tracking, generating the offset path of sanding scratches relative to the wood grain direction. Based on the offset path, cross-integration classification is performed, and the roughness score and defect coordinates of the sanded wooden door are output. At the same time, a gain compensation factor is generated according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; thus realizing intelligent and high-precision detection of the sanded quality of the wooden door.
[0007] Optionally, obtain the wood grain direction reference data of the sanded surface of the wooden door after strengthening the sanding of scratches and uneven features to construct a wood grain reference map, including: From the graded adjusted image data, the image is divided into multiple wood grain sampling units; Within the wood grain sampling unit, the principal angle value of the texture direction is calculated, and the principal angle value represents the dominant extension direction of the wood grain within the unit; By analyzing the rate of change of direction between adjacent wood grain sampling units, the continuity of wood grain is confirmed, and regions with abrupt changes in direction are smoothly connected. The principal angle values and corresponding position coordinates of all wood grain sampling units are summarized to construct a dot matrix orientation dataset; The directional dataset is encoded into a graph structure as a wood grain reference graph, where each point in the graph corresponds to the principal angle value of a wood grain sampling unit.
[0008] Optionally, phase compensation analysis is performed on the multi-angle interferometric image in conjunction with the wood grain reference pattern to generate a surface gradient map that quantifies micro-undulations, including: Acquire images of the sanded surface of a wooden door from multiple light source angles to form a multi-angle interference image set; In the aforementioned wood grain reference map, the wood grain direction angle is selected as the reference line; For each pixel in the multi-angle interference image, the brightness change amplitude of the corresponding pixel under different light source angles is calculated, and based on the brightness change amplitude, the original phase difference representing the deformation caused by surface micro-undulations is calculated. Referring to the wood grain direction angle of the reference line, a phase offset correction coefficient is applied to adjust the original phase difference, resulting in an adjusted phase difference value. The phase difference value is converted into the surface height change rate, i.e., the vertical displacement per unit distance. At the same time, the height change rates of all pixels are summarized to form a point grid structure, which is stored as a surface gradient map.
[0009] Optionally, based on the graded adjusted image data and the surface gradient map, a cross-modal data pair is constructed, and a synthetic sample simulating sanding defects is generated using physical constraints containing rules for geometric matching of wood grain direction and sanding defects, including: The pixels in the graded adjusted image data are mapped one-to-one with the corresponding points in the surface gradient map to form cross-modal data pairs. Define a geometric matching rule that the angle between the direction of sanding scratches and the direction of wood grain must be within a preset range, and the ratio of scratch length to wood grain width must be fixed. In the cross-modal data pair, the location regions that satisfy the geometric matching rules are identified, and the pixel values of the image data are modified within the location regions, and a point set simulating the scratch shape is added; Adjust the height change rate in the surface gradient map to simulate surface abrupt changes caused by scratches, and output a synthetic sample containing simulated sanding defect areas.
[0010] Optionally, spatial decoupling of texture attributes is performed on the synthesized sample to separate gloss reflection features from deformation structure features, and the decoupled deformation structure features are combined with the wood grain reference map to achieve wood grain-guided defect trajectory tracking, generating the offset path of sanding scratches relative to the wood grain direction, including: The image texture in the synthesized sample is decomposed into gloss component and deformation component, whereby the gloss component corresponds to the brightness and darkness of the pixel and the deformation component corresponds to the surface height change. The deformation component is extracted as the dominant feature, and the reference wood grain direction angle in the wood grain reference map is used to mark the reference wood grain line in the deformation component; The starting and ending points of the simulated sanding defect region are identified in the deformation component to generate an initial trajectory; Calculate the angle deviation and distance deviation between the initial trajectory and the reference wood grain line at each point, and record the sequence of the angle deviation and distance deviation to form the offset path of the sanding scratches relative to the wood grain direction.
[0011] Optionally, cross-integration classification is performed based on the offset path to output the roughness score and defect coordinates of the sanded wooden door. Simultaneously, a gain compensation factor is generated based on changes in ambient lighting to optimize the graded adjustment of the regional gain coefficient, including: The trajectory feature set is extracted from the offset path, and the trajectory feature set is input into a cross-integration mechanism that combines multiple pre-trained feature combiners. The trajectory features are compared with a threshold range in the feature combiner to determine the type and level of sanding defects. A comprehensive roughness score is calculated based on the type and grade. Extract the coordinates of the starting and ending points of the defects in the offset path, and simultaneously monitor the sensor data of ambient light intensity in real time to calculate the light fluctuation coefficient. A gain compensation factor is generated based on the illumination fluctuation coefficient, and the gain compensation factor is used to adjust the specular reflection threshold and scratch enhancement threshold in the regional gain coefficient. The gain compensation factor is applied to update the grading adjustment step, and the roughness score and defect coordinate position are output.
[0012] Optionally, under varying lighting conditions, dynamic gain is dynamically adjusted in stages based on the regional brightness distribution of the sanded surface of the wooden door and the regional differential gain to suppress specular reflection interference, while simultaneously enhancing sanding scratches and uneven features, including: High-resolution image data is divided into multiple local grid regions, and the statistical mean of brightness in each local grid region is measured as a brightness baseline value. Two gain adjustment modes are applied based on the brightness reference value: when the brightness reference value is greater than the specular reflection threshold, the pixel intensity value is reduced proportionally; when the brightness reference value is less than the scratch enhancement threshold, the pixel intensity value is increased proportionally. The mirror reflection threshold and scratch enhancement threshold of the wooden door are dynamically calculated and updated based on ambient light sensor data. The gain adjustment mode is performed separately in the local grid area, and then combined with the specular reflection threshold and scratch enhancement threshold to reassemble the entire image, outputting the graded adjusted image data.
[0013] Secondly, this application provides an intelligent detection system for the sanding roughness of wooden doors, including: The adjustment module is used to acquire high-resolution image data of the sanded surface of the wooden door. Under varying lighting conditions, it achieves dynamic gain adjustment based on the regional brightness distribution of the sanded surface of the wooden door and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. The module is used to simultaneously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on the multi-angle interference image to generate a surface gradient map of quantified micro-undulations. The generation module is used to construct cross-modal data pairs based on the graded adjusted image data and the surface gradient map, and generate synthetic samples simulating sanding defects using physical constraints containing the geometric matching rules of wood grain direction and sanding defects. The separation module is used to perform spatial decoupling of texture attributes on the synthetic sample to separate gloss reflection features and deformation structure features, and to combine the wood grain reference map to realize wood grain-guided defect trajectory tracking of the decoupled deformation structure features, and generate the offset path of sanding scratches relative to the wood grain direction. The detection module is used to perform cross-integration classification based on the offset path, output the roughness score and defect coordinate position of the sanded wooden door, and generate a gain compensation factor according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; thus realizing intelligent and high-precision detection of the sanded quality of the wooden door.
[0014] Thirdly, this application provides a computing device, including a processing component and a storage component; the storage component stores one or more computer instructions; the one or more computer instructions are invoked and executed by the processing component to realize the intelligent detection method for sanding roughness of wooden doors as described in the first aspect above.
[0015] Fourthly, this application provides a computer storage medium storing a computer program, which, when executed by a computer, implements an intelligent detection method for sanding roughness of wooden doors as described in the first aspect.
[0016] This application provides an end-to-end, adaptive, and high-precision method for inspecting the surface quality of sanded wooden doors. Its core value lies in overcoming key challenges such as industrial lighting interference, insufficient real defect data, severe wood grain background interference, and weak defect features through innovative multimodal fusion, strong physical constraint synthetic data generation, accurate application of wood grain reference maps, environmentally adaptive dynamic gain adjustment, and refined feature decoupling and trajectory tracking. Ultimately, it achieves intelligent and high-precision roughness scoring and defect localization, particularly accurate description of scratch trajectories, improving the automation and accuracy of the inspection. Furthermore, the core dependent claims further refine the key steps, such as gain adjustment, map construction, constraint conditions, feature separation, and trajectory tracking classification, strengthening the technical effectiveness of the proposed solution and making the overall solution more concrete, implementable, and superior.
[0017] These or other aspects of this application will become more apparent in the following description of the embodiments. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 A flowchart of an intelligent detection method for sanding roughness of wooden doors provided in this application is shown; Figure 2 A schematic diagram of a scenario illustrating an intelligent detection method for sanding roughness of wooden doors provided in this application is shown. Figure 3 This invention provides a schematic diagram of the structure of an intelligent detection system for sanding roughness of wooden doors. Figure 4 A schematic diagram of the structure of a computing device provided in this application is shown. Detailed Implementation
[0020] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
[0021] In some of the processes described in the specification, claims, and accompanying drawings of this application, multiple operations appearing in a specific order are included. However, it should be clearly understood that these operations may not be executed in the order they appear herein, or may be executed in parallel. The operation numbers, such as 101, 102, etc., are merely used to distinguish different operations and do not themselves represent any execution order. Furthermore, these processes may include more or fewer operations, and these operations may be executed sequentially or in parallel. It should be noted that the descriptions such as "first," "second," etc., in this document are used to distinguish different messages, devices, modules, etc., and do not represent a chronological order, nor do they limit "first" and "second" to different types.
[0022] Currently, inspecting the smoothness of sanded wooden doors in factories often encounters problems. There are three main difficulties: First, uneven workshop lighting or strong glare makes it difficult to see crucial sanding scratches and small bumps in photographs of the wooden door surface. Second, the natural wood grain pattern of the door itself acts as a "disturbing background," making it difficult for machines to accurately distinguish between genuine sanding defects and ordinary wood grain lines, leading to misjudgments. Third, this method heavily relies on the experience of skilled workers and repeated inspections, resulting in low efficiency and difficulty in ensuring consistent accuracy. The core of these problems lies in the fact that existing methods cannot effectively handle changing lighting conditions, cannot effectively eliminate the interference of wood grain, and are heavily reliant on manual labor, lacking intelligence and stability.
[0023] To overcome these challenges, this application proposes a novel intelligent detection method. Its core idea is as follows: First, regarding lighting issues, when photographing a wooden door, the system automatically adjusts the contrast of the image based on the brightness of different areas, much like the human eye adjusts itself. Specifically, it focuses on areas prone to reflection and shine, suppressing glare while enhancing the clarity of genuine polishing defects, ensuring clear and discernible images even under varying lighting conditions. Second, to completely solve the long-standing problem of wood grain interference, this solution creatively establishes a standard wood grain reference map. This template acts like a benchmark. When analyzing detailed images of the wooden door surface, the system uses this "ruler" to automatically distinguish which undulations are normal wood grain patterns and which are genuine polishing defects, thus significantly reducing misjudgments. Finally, this system can not only accurately locate the position and shape of polishing defects, such as the specific path of scratches deviating from the wood grain direction, but also automatically assess the smoothness of the entire surface to obtain a roughness score. Furthermore, it can adjust the photographing strategy, i.e., the gain compensation factor, in real time according to changes in ambient light, ensuring the stability of the detection. In summary, this method is the first to truly achieve automated, high-precision, and interference-resistant testing of the sanding quality of wooden doors. It solves three major problems: reliance on manual labor, susceptibility to changes in light, and inability to distinguish wood grain from defects. This makes the test results more reliable and efficient, eliminating the need for excessive reliance on worker experience.
[0024] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0025] Figure 1 This application provides a flowchart of an intelligent detection method for the sanding roughness of wooden doors, as shown in the embodiments. Figure 1 As shown, the method includes: 101. Collect high-resolution image data of the sanded surface of the wooden door, and under varying lighting conditions, achieve dynamic gain adjustment based on the regional brightness distribution of the sanded surface of the wooden door and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. Optionally, step 101 may specifically include the following steps: 1011. Divide the high-resolution image data into multiple local grid regions, and simultaneously measure the statistical mean of the brightness of each local grid region as the brightness reference value; 1012. Two gain adjustment modes are applied based on the brightness reference value: when the brightness reference value is greater than the specular reflection threshold, the pixel intensity value is reduced proportionally; when the brightness reference value is less than the scratch enhancement threshold, the pixel intensity value is increased proportionally. 1013. Dynamically calculate and update the specular reflection threshold and scratch enhancement threshold of wooden doors based on ambient light sensor data; 1014. Perform gain adjustment mode separately in the local grid area, and combine it with the specular reflection threshold and scratch enhancement threshold to recombine them into the whole image, and output the graded adjusted image data.
[0026] In the above scheme, the specular reflection threshold refers to the critical brightness value of the wooden door surface due to strong reflection caused by smooth metal abrasive. Exceeding this value will cause local overexposure and loss of details in the image. For example, the brightness upper limit of 200 is usually required for areas directly illuminated by light. The scratch enhancement threshold refers to the critical brightness value of dark areas where the features of sanding scratches need to be enhanced. For example, the shadow at the wood grain joint needs to be set to a lower limit of 50. The brightness reference value refers to the statistical average brightness of all pixels in each grid after the high-resolution image is divided into multiple local grid areas, which is used to quantify the brightness state of the area. Regional differential gain refers to applying different adjustment coefficients independently according to the brightness reference value of the grid. For example, the gain coefficient is reduced to 0.7 to suppress reflection in overly bright areas, and the gain coefficient is increased to 1.3 to enhance features in overly dark areas. Dynamic gain graded adjustment refers to updating the processing parameters in combination with real-time changes in ambient light to achieve stable and reliable feature enhancement.
[0027] In this embodiment, firstly, step 1011 divides the high-resolution image into a 40×40 pixel grid region, obtains the pixel intensity value corresponding to each grid region, and calculates the average brightness value of all pixels in each local grid region as the brightness reference value for the region; secondly, step 1012 determines the intensity based on preset specular reflection threshold and scratch enhancement threshold. When the reference value of a grid is greater than the specular reflection threshold, a proportional coefficient of 0.7 is applied to all pixels in the grid to reduce the intensity; when the reference value is less than the scratch enhancement threshold, a coefficient of 1.3 is applied to increase the intensity; then, step 1013 uses ambient light sensor data... Calculate the specular reflection threshold and scratch enhancement threshold of the wooden door. and scratch enhancement threshold ,in and It is a preset illumination adaptation function that dynamically updates the two threshold parameters calculated. For example, when the illumination weakens, the specular reflection threshold is automatically reduced to avoid misjudgment. Finally, in step 1014, all the grids that have been independently adjusted are recombined by bilinear interpolation. After eliminating the jagged edges at the boundaries, the entire image data after hierarchical adjustment is output. For example, in the detection of type A oak doors, the reflection of metal handles is successfully suppressed while the sanding scratches at the wood grain joints are enhanced.
[0028] In a practical application, Company A's inspection system B acquires sanded images of wooden doors in a workshop environment. The system divides the images into a 100×100 pixel grid and measures the average brightness of a certain edge grid. At this time, the ambient light sensor reading... The system calculates the specular reflection threshold T_s = 200. Since 220 is greater than 200, the intensity of all pixels in this grid is multiplied by a scaling factor of 0.8. Meanwhile, a central grid... Scratch enhancement threshold Since 40 is less than 50, the pixel intensity multiplied by the scaling factor equals 1.5. When the ambient light decreases to... At that time, the system pressed renew renew After all grids have been processed, the output image is reconstructed.
[0029] This solution effectively overcomes the impact of industrial lighting fluctuations on inspection. Through local brightness analysis, it precisely suppresses specular reflection areas, significantly improving the visibility of sanding scratches and surface irregularities. A dynamic threshold mechanism ensures that processing parameters adapt to environmental changes in real time, providing high-quality enhanced images for subsequent defect analysis and comprehensively improving the environmental robustness of the inspection system.
[0030] 102. Simultaneously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on the multi-angle interference image to generate a surface gradient map of quantified micro-undulations.
[0031] Optionally, step 102 may specifically include the following steps: 1021. Divide the image into multiple wood grain sampling units from the graded and adjusted image data; 1022. Within the wood grain sampling unit, calculate the principal angle value of the texture direction, whereby the principal angle value represents the dominant extension direction of the wood grain within the unit; 1023. By analyzing the rate of change of direction between adjacent wood grain sampling units, the continuity of wood grain is confirmed, and regions with abrupt changes in direction are smoothly connected. 1024. Summarize the principal angle values and corresponding position coordinates of all wood grain sampling units to construct a dot matrix orientation dataset; 1025. Encode the direction dataset into a graph structure as a wood grain reference graph, wherein each point in the graph corresponds to the principal angle value of a wood grain sampling unit.
[0032] 1026. Acquire images of the sanded surface of a wooden door from multiple light source angles to form a multi-angle interference image set; 1027. In the aforementioned wood grain reference map, the wood grain direction angle is selected as the reference reference line; 1028. For each pixel in the multi-angle interference image, calculate the brightness change amplitude of the corresponding pixel under different light source angles, and based on the brightness change amplitude, calculate the original phase difference representing the deformation caused by surface micro-undulations. 1029. Referring to the wood grain direction angle of the reference line, apply a phase offset correction coefficient to adjust the original phase difference to obtain the adjusted phase difference value; 10210. Convert the phase difference value into the surface height change rate, i.e., the vertical displacement per unit distance, and summarize the height change rates of all pixels to form a point grid structure, which is then stored as a surface gradient map.
[0033] In the above scheme, the enhanced sanded surface of the wooden door after sanding scratches and uneven features refers to the surface state of the wooden door presented by the image data after dynamic gain grading adjustment in step 101, where scratches and uneven features are enhanced. Wood grain direction reference data refers to the angular information describing the dominant extension direction of the wood grain on the wooden door surface. The wood grain reference map refers to the map structure formed by encoding a dot matrix direction dataset, where each point represents the principal angle value of a wood grain sampling unit. The multi-angle interference image set refers to the collection of images of the sanded surface of the wooden door acquired by shooting from different light source angles. Phase compensation analysis refers to the process of adjusting the phase difference with reference to the wood grain direction to compensate for wood grain interference. The surface gradient map refers to the dot grid structure that quantifies the micro-undulations of the surface, where each point stores the height change rate, i.e., the vertical displacement per unit distance. A wood grain sampling unit refers to dividing the image into smaller, regular regions for wood grain analysis. The principal angle value refers to the angle value obtained by calculating the texture direction, representing the dominant extension direction of the wood grain within the unit. The direction change rate refers to the rate of change of the principal angle value between adjacent wood grain sampling units. The orientation dataset refers to a collection of data summarizing the principal angle values and corresponding position coordinates of all wood grain sampling units. The atlas structure refers to an atlas format that organizes data in a dot matrix manner. The baseline reference line refers to a specific wood grain orientation angle selected in the wood grain baseline atlas as a reference baseline. Brightness variation amplitude refers to the difference in brightness value of the same pixel under different light source angles. The original phase difference refers to the initial phase deformation caused by surface micro-undulations calculated based on the brightness variation amplitude. The phase offset correction coefficient refers to the correction parameter used to adjust the original phase difference. The height change rate refers to the displacement change per unit horizontal distance in the vertical direction of the surface. The dot grid structure refers to the topological structure that stores data in a grid format.
[0034] In this embodiment, firstly, step 1021 divides the graded adjusted image data into multiple wood grain sampling units, for example, each unit is a 50x50 pixel square. Secondly, step 1022 calculates the principal angle value of the texture direction within each wood grain sampling unit using a directional filter, with the following formula: ; in: (Rotated coordinates) , This represents the direction angle of the k-th filter, such as 0°, 30°, 60°... for a total of 6 directions. Control the filter bandwidth, The spatial frequency is typically set to 1 / texture period. For example, a Gabor filter is applied to extract the wood grain direction within a unit and output the dominant angle. Next, step 1023 analyzes the rate of change of direction between adjacent wood grain sampling units, for example, calculating the ratio of the angle difference to the distance between adjacent units to confirm the continuity of the wood grain, and using spline interpolation to smooth the connection of regions with abrupt changes in direction. Then, step 1024 summarizes the dominant angle values and position coordinates of all wood grain sampling units, for example, storing the dominant angle values and coordinates as an array to construct a matrix-style direction dataset. Then, step 1025 encodes the direction dataset into a map structure as a wood grain reference map, for example, using matrix encoding for each point corresponding to the unit's dominant angle value. Subsequently, step 1026 acquires images of the sanded surface of the wooden door under multiple light source angles, for example, taking pictures at 30°, 45°, and 60° light source angles to form a multi-angle interference image set. Finally, step 1027 selects the wood grain direction angle in the wood grain reference map as a reference line, for example, selecting the most common angle such as 15° as the reference line. Next, in step 1028, the brightness variation amplitude of each pixel in the multi-angle interference image under different light source angles is calculated. For example, the standard deviation of the brightness values at three angles is taken as the amplitude, and the original phase difference is calculated based on the brightness variation amplitude using a phase unwrapping algorithm. The formula is as follows: ; It represents the amplitude of brightness change, where k is the phase sensitivity constant, calculated using the following formula: .
[0035] Then, by applying a phase offset correction coefficient to the wood grain direction angle of the reference line in step 1029, the original phase difference is adjusted, where the formula is as follows: ,in This is the adjusted phase difference value. The phase shift correction coefficient is obtained based on the wood grain angle difference. Finally, step 10210 converts the phase difference value into the surface height change rate, using the following formula: ,in is the rate of change of height, and m is the conversion coefficient.
[0036] Simultaneously, the height change rates of all pixels are summarized to form a point grid structure and stored as a surface gradient map.
[0037] In practical applications, within Company A's inspection system B, for the sanded wooden door image processed in step 101, the system first executes step 1021 to divide the image into 50x50 pixel wood grain sampling units. For example, if a unit is located in the center of the door panel, the system executes step 1022 to apply a Gabor filter to analyze the texture direction of that unit, calculating the principal angle value to be 30 degrees. Next, step 1023 analyzes the rate of change of direction between this unit and adjacent units, finding that the adjacent unit angle is 25 degrees, a relatively small rate of change, confirming it as continuous wood grain; in another region, the unit angle abruptly changes from 30 degrees to 60 degrees, and the system uses spline interpolation to smooth it to 45 degrees. Then, step 1024 summarizes the principal angle values and position coordinates of all units, for example, 500 units, to construct a direction dataset. Step 1025 encodes this dataset into a 100x100 dot matrix as a wood grain reference map. Finally, step 1026 captures images of the wooden door surface at three light source angles of 30 degrees, 45 degrees, and 60 degrees, forming a multi-angle interference image set. Step 1027 selects the most common wood grain angle of 30 degrees from the map as the baseline reference line. For a single pixel coordinate, step 1028 calculates its brightness values at three light source angles: 150, 160, and 170, representing the brightness variation range. Taking a standard deviation of 8.16 and assuming k=0.5, the original phase difference is... Step 1029: Referring to the reference line at 30 degrees, the wood grain angle difference of this pixel is 5 degrees. Calculate the phase shift correction coefficient. Then the adjusted phase difference value Finally, execute step 10210. Assuming m = 0.1, then... height change rate ;
[0038] The height change rates of all pixels are summarized to form a surface gradient map and stored as grid data.
[0039] This solution uses intelligent analysis of wood grain direction and compensation for phase interference to accurately quantify the microscopic undulation features of the wooden door surface, effectively separate the wood grain background from sanding defects, improve the accuracy of the surface gradient map, provide a reliable three-dimensional deformation data basis for subsequent defect detection, and enhance the system's adaptability to complex textured surfaces.
[0040] 103. Construct cross-modal data pairs based on the graded adjusted image data and the surface gradient map, and generate synthetic samples simulating sanding defects using physical constraints containing the geometric matching rules of wood grain direction and sanding defects; Optionally, step 103 may specifically include the following steps: 1031. Map the pixels in the graded adjusted image data one-to-one with the corresponding points in the surface gradient map to form cross-modal data pairs; 1032. Define a geometric matching rule that the angle between the direction of sanding scratches and the direction of wood grain must be within a preset range, and the ratio of scratch length to wood grain width must be fixed. 1033. In the cross-modal data pair, identify the location region that satisfies the geometric matching rule, modify the pixel value of the image data within the location region, and add a point set simulating the scratch shape; 1034. Adjust the height change rate in the surface gradient map to simulate surface abrupt changes caused by scratches, and output a synthetic sample containing simulated sanding defect areas.
[0041] In the above scheme, the graded adjusted image data refers to the wooden door surface image after dynamic gain processing in step 101. The surface gradient map refers to the point grid data of quantified surface undulation height generated in step 102. Cross-modal data pairs refer to the associated dataset formed by pairing image pixels with corresponding gradient map data points. Wood grain direction refers to the dominant extension direction angle data of the wooden door surface texture. Sanding defect geometric matching rules refer to artificially set defect generation constraints, including the limitation of the scratch direction and the wood grain angle, as well as the proportional relationship between scratch length and wood grain width. Synthetic samples simulating sanding defects refer to training data containing artificial defects generated by the algorithm. One-to-one mapping refers to establishing a precise positional correspondence between image pixel coordinates and gradient map grid points. Preset range refers to a pre-defined allowable angle range, such as 30 degrees to 60 degrees. Point set refers to the discrete coordinate set used to simulate scratch shape. Surface abrupt change refers to a sharp change in the local height change rate in the gradient map.
[0042] In this embodiment, firstly, step 1031 establishes a coordinate mapping relationship between pixels in the graded adjusted image data and corresponding points in the surface gradient map. For example, the image pixel coordinates are aligned to the surface gradient map grid coordinates through an affine transformation matrix to form cross-modal data pairs. Secondly, step 1032 defines geometric matching rules, including that the angle between the direction of sanding scratches and the direction of wood grain must satisfy the formula. in It is the direction angle of the scratch. It is a preset range, such as 35 degrees to 55 degrees, and the scratch length is also set. With wood grain width Proportional constraints must be met Where k is a fixed scaling factor. Then, in step 1033, the image pixel values are modified using a linear subtraction algorithm in areas that satisfy the geometric matching rules, such as areas with a wood grain width of 5 mm and a direction angle of 40 degrees. in This is the scratch depth coefficient, and a set of points simulating the scratch is generated along a set direction, for example, a discrete point sequence with a length of 5 km is generated in a 40-degree direction. Finally, in step 1034, the height change rate is adjusted in the corresponding surface gradient map region, and an abrupt change is set at the scratch centerline position. ; in It is the mutation intensity coefficient It is a synthetic sample output by simulating the surface deformation caused by scratches using the Dirac function.
[0043] In practical applications, step 103 is executed in Company A's inspection system for a wooden door sample. First, step 1031 establishes a coordinate mapping between the 1024×768 pixel image output from step 101 and the gradient map of the same size generated in step 102. Then, step 1032 sets the geometric rules, ensuring the angle between the scratch and the wood grain is within 40 degrees ± 10 degrees, and that the scratch length L_s is equal to the wood grain width. Three times that in wood grain width. millimeter orientation angle Step 1033 of the process in the region of degree calculates the allowable scratch direction. Selected Length of scratch Millimeter generates a point set along a 40-degree direction on the image of this region, with each pixel value multiplied by a coefficient of 0.7 to simulate a dark scratch. Step 1034 sets the center line position of a height abrupt change along the scratch path in the corresponding surface gradient map region, abruptly changing from a normal value of 0.2 to 1.5 with a Gaussian decay transition at the edges. The final output is a synthetic sample containing simulated scratches for subsequent model training.
[0044] This scheme effectively expands the diversity of training samples through a defect generation mechanism based on physical constraints. The generated synthetic defects conform to the geometric characteristics of real sanding damage, significantly improving the generalization ability and recognition accuracy of subsequent defect detection models. At the same time, it maintains the physical rationality of the wood grain background and defects, providing a high-quality data foundation for intelligent detection.
[0045] 104. Perform spatial decoupling of texture attributes on the synthetic sample to separate gloss reflection features and deformation structure features, and combine the wood grain reference map to realize wood grain-guided defect trajectory tracking of the decoupled deformation structure features, and generate the offset path of sanding scratches relative to the wood grain direction. Optionally, step 104 may specifically include the following steps: 1041. The image texture in the synthesized sample is decomposed into a gloss component and a deformation component, wherein the gloss component corresponds to the brightness change of the pixel and the deformation component corresponds to the surface height change. 1042. Extract the deformation component as the dominant feature, and mark the reference wood grain line in the deformation component with reference to the wood grain direction angle in the wood grain reference map; 1043. Identify the start and end points of the simulated sanding defect region in the deformation component to generate an initial trajectory; 1044. Calculate the angle deviation and distance deviation between the initial trajectory and the reference wood grain line at each point, and record the sequence of the angle deviation and distance deviation to form the offset path of the sanding scratch relative to the wood grain direction.
[0046] In the above scheme, the synthetic sample refers to the image and gradient map data containing simulated sanding defects generated in step 103. Spatial decoupling of texture attributes refers to decomposing the image texture into components with different physical meanings. Gloss reflection features describe the brightness variations formed by direct reflection of light. Deformation structure features describe the height variations caused by surface unevenness. Grain-guided defect trajectory tracking refers to a method of tracing the defect path along the grain direction. Offset path refers to the sequence of angle and distance deviations of sanding scratches relative to the grain direction. Gloss component refers to the brightness component in the image formed only by light reflection. Deformation component refers to the structural component in the image formed only by surface undulations. Reference grain line refers to the standard grain direction reference line determined according to the wood grain reference map. Initial trajectory refers to the straight-line connection path from the start point to the end point of the defect area. Angle deviation value refers to the angle difference between the tangent direction of the defect trajectory point and the direction of the reference grain line. Distance deviation value refers to the vertical distance from the defect trajectory point to the nearest reference grain line.
[0047] In this embodiment of the application, step 1041 is first used... Image decomposition algorithms separate the image texture in synthetic samples into gloss components. and deformation components ,in The intensity of reflected light meets the requirements ; in It is the reflectivity component. The corresponding gradient plot height change rate satisfies Next, the deformation component is extracted through step 1042. As a dominant feature, based on the wood grain reference map, in position... Obtain the direction and angle of the wood grain. And draw the baseline wood grain line that runs through the image from this angle. Next, through step 1043, the deformation component... Mid-positioning simulation of sanding defect areas to identify defect starting points and the end point Generate initial straight line trajectory Finally, through step 1044 along Sample N points at equal intervals for each point Calculate the tangent angle of its trajectory. Angle with reference wood grain line The difference Simultaneous calculation arrive vertical distance Forming an offset path .
[0048] In practical applications, step 104 is performed in Company A's inspection system for synthetic samples containing simulated scratches. First, step 1041 applies multi-scale... The algorithm decomposes the image into gloss components to display bright spots in the reflective areas of the door panel, and deformation components to clearly display scratches and wood grain textures. Step 1042 selects the deformation component and references the wood grain pattern, obtaining a 45-degree wood grain angle at coordinates (100, 200) to draw a baseline wood grain line in the 45-degree direction. Step 1043 identifies the simulated scratch origin in the deformation component. end Generate an initial trajectory straight line. Execute step 1044 to take 5 sampling points along the trajectory, for example, point [point name missing]. Calculate the direction angle of the trajectory at this point. Then the angle deviation Distance from this point to the baseline wood grain line Pixels. The final output offset path sequence is as follows: .
[0049] This solution accurately separates surface deformation features through texture decomposition and combines them with wood grain benchmarks to achieve physical rationality tracking of defect trajectories. The generated offset path quantitatively characterizes the spatial relationship between scratches and wood grain, providing interpretable quantitative basis for sanding process evaluation and significantly improving the accuracy and traceability of defect analysis.
[0050] 105. Perform cross-integration classification based on the offset path, output the roughness score and defect coordinate position of the sanded wooden door, and at the same time generate a gain compensation factor according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; realize intelligent and high-precision detection of the sanded quality of the wooden door.
[0051] Optionally, step 105 may specifically include the following steps: 1051. Extract the trajectory feature set from the offset path, input the trajectory feature set into a cross-integration mechanism that combines multiple pre-trained feature combiners, and compare the trajectory features with the threshold range in the feature combiner to determine the type and level of sanding defects; 1052. Calculate the overall roughness score based on the aforementioned type and grade; 1053. Extract the coordinates of the starting point and ending point of the defect in the offset path, and at the same time monitor the sensor data of the ambient light intensity in real time to calculate the light fluctuation coefficient. 1054. A gain compensation factor is generated based on the illumination fluctuation coefficient, wherein the gain compensation factor is used to adjust the specular reflection threshold and scratch enhancement threshold in the regional gain coefficient; 1055. Apply the gain compensation factor to update the grading adjustment step, and output the roughness score and defect coordinate position.
[0052] In the above scheme, the offset path refers to the sequence of angle and distance deviations of the sanding scratches relative to the wood grain direction generated in step 104. The trajectory feature set refers to the set of statistical features extracted from the offset path, including mean, variance, and extreme values. The cross-integration mechanism refers to a fusion decision system that combines multiple pre-trained classification models. The feature combiner refers to a processing unit that combines and transforms the input features. The threshold range refers to a preset feature value judgment interval used for defect classification. The type and grade of sanding defects refer to the types and severity of defects classified according to process standards. The roughness comprehensive score refers to a quantitative score that comprehensively evaluates surface quality. The defect start point coordinates and end point coordinates refer to the start and end points of the scratches on the image. The ambient light intensity sensor data refers to the ambient illuminance values collected in real time by a light sensor. The light fluctuation coefficient refers to a numerical index that quantifies the degree of light change. The gain compensation factor refers to a correction coefficient used to dynamically adjust the gain parameters. The region gain coefficient refers to the specular reflection threshold and scratch enhancement threshold used for image grading adjustment in step 101.
[0053] In this embodiment of the application, the trajectory feature set, including the mean angle deviation, is first extracted from the offset path in step 1051. Distance Deviation Standard Deviation The isostatistic input feature set contains a cross-ensemble mechanism with three pre-trained feature combiners. Each combiner compares feature values with a threshold range, for example, when... and If the defect is identified as a severe scratch at a certain pixel level, then step 1052 involves querying the scoring mapping table based on the defect type and level. Calculate the overall roughness score. Then, extract the defect starting point in the offset path through step 1053. and end point Simultaneously acquire ambient light sensor data sequence Calculate the light fluctuation coefficient ;
[0054] Then, based on step 1054... Generate gain compensation factor Where k is the sensitivity coefficient. Adjusting the region gain coefficient and the new specular reflection threshold New scratch enhancement threshold Finally, step 1055 applies the updated gain coefficient to optimize the grading adjustment process of step 101, while simultaneously outputting the roughness score and defect coordinate location.
[0055] In practical applications, wooden door samples are processed in Company A's inspection system B. Step 1051 is executed to extract the mean value of the offset path feature angle deviation. Distance Deviation Range The pixel input cross-integration mechanism determines all three feature combiners. threshold and The pixel threshold is comprehensively determined to be a depth scratch level 3. Step 1052 is executed, deducting 30 points according to the preset scoring rules for level 3, resulting in a base score of 100 and an output roughness score of 70. Step 1053 is executed, obtaining the defect start point (120, 180) and end point (180, 220). Simultaneously, the light sensor monitors the illuminance values [1000, 980, 1020, 900, 950 lux] within 10 seconds and calculates the average illuminance. Volatility coefficient ; Execute step 1054 settings calculate Original Updated to Original Updated to Step 1055 applies the new threshold to subsequent inspections and outputs a score of 70 and defect coordinates (120, 180) to (180, 220).
[0056] This solution achieves accurate quantitative evaluation of sanding quality through intelligent feature analysis and dynamic parameter optimization, outputting objective roughness scores and defect location information. At the same time, it adjusts image processing parameters in real time according to changes in ambient light to ensure the stability and reliability of the detection system under different lighting conditions, ultimately realizing fully automatic high-precision detection of sanding quality for wooden doors.
[0057] Figure 2 This application provides a scenario diagram illustrating an intelligent detection method for the sanding roughness of wooden doors, as shown in the embodiments of this application. Figure 2 As shown, a complete embodiment of steps 101-105 includes: In the wooden door quality inspection workshop of Company A, testing equipment B performs a full-process inspection on a sanded oak door panel: First, a high-resolution industrial camera captures an image of the door panel surface. Under fluctuating lighting conditions in the workshop, the image is divided into a 10×10 pixel grid. The average brightness of a certain edge grid is measured to be 220 (specular reflection threshold 200). Its pixel intensity is multiplied by a coefficient of 0.8 to suppress reflection. At the same time, the pixel intensity of the grid with an average brightness of 40 in the central area (scratch enhancement threshold 50) is multiplied by 1.5 to enhance scratch visibility. Next, a wood grain baseline map is constructed based on the optimized image. A Gabor filter is applied within a 50×50 pixel unit to measure the main wood grain angle of 45 degrees. Multi-angle images are captured under 30 / 45 / 60 degree light sources, and a surface gradient map is generated through phase compensation. Then, the image and the gradient map are compared. A cross-modal data pair was constructed. In a region with a wood grain width of 0.5 mm and an orientation of 45 degrees, a simulated scratch with a length of 1.5 mm was generated along a 40-degree direction, and the gradient map height change rate was modified simultaneously. Then, the texture was decomposed using the Retinex algorithm, and the simulated scratch was tracked along the 45-degree baseline wood grain line in the deformation component. The average angle deviation of the trajectory points was measured to be 8.2 degrees, and the range of distance deviation was 5.3 pixels. Finally, the cross-integration classifier was used to determine that it was a deep scratch (level 3), and the roughness score was 70 points and the defect coordinates were (120, 180) to (180, 220). At the same time, a gain compensation factor of 1.229 was generated based on the 45.8 lux fluctuation value monitored by the light sensor, and the specular reflection threshold was dynamically updated to 245.8 and the scratch enhancement threshold was updated to 61.45, realizing fully automatic high-precision quality assessment.
[0058] This solution achieves an intelligent closed-loop inspection of the sanding quality of wooden doors. It effectively suppresses light fluctuation interference through dynamic gain grading adjustment and quantifies surface undulations by combining wood grain reference maps. It utilizes cross-modal data to generate synthetic defects with physical constraints, and accurately extracts offset features through texture decoupling and trajectory tracking. Finally, it outputs quantifiable scores (and defect location) through cross-integration classification, while feeding back the ambient light fluctuation coefficient to the preprocessing module to optimize parameters in real time, forming a closed-loop system of inspection-evaluation-optimization, which significantly improves inspection accuracy and process adaptability.
[0059] This plan Figure 3 This application provides a schematic diagram of the structure of an intelligent detection system for the sanding roughness of wooden doors, as shown in the embodiment of the present application. Figure 3 As shown, the system includes: The adjustment module 31 is used to acquire high-resolution image data of the sanded surface of the wooden door. Under varying lighting conditions, it achieves dynamic gain adjustment based on the regional brightness distribution of the sanded surface of the wooden door and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. The construction module 32 is used to synchronously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on the multi-angle interference image to generate a surface gradient map of quantified micro-undulations. The generation module 33 is used to construct cross-modal data pairs based on the graded adjusted image data and the surface gradient map, and generate synthetic samples simulating sanding defects using physical constraints containing the geometric matching rules of wood grain direction and sanding defects. The separation module 34 is used to perform spatial decoupling of texture attributes on the synthetic sample to separate gloss reflection features and deformation structure features, and to combine the wood grain reference map to realize wood grain-guided defect trajectory tracking of the decoupled deformation structure features, and generate the offset path of sanding scratches relative to the wood grain direction. The detection module 35 is used to perform cross-integration classification based on the offset path, output the roughness score and defect coordinate position of the sanding of the wooden door, and generate a gain compensation factor according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; thus realizing intelligent and high-precision detection of the sanding quality of the wooden door.
[0060] Figure 3 The aforementioned intelligent detection system for sanding roughness of wooden doors can perform... Figure 1 The implementation principle and technical effects of the intelligent detection method for sanded roughness of wooden doors described in the illustrated embodiment will not be repeated here. The specific operation methods of each module and unit in the intelligent detection system for sanded roughness of wooden doors described in the above embodiments have been described in detail in the embodiments related to this method, and will not be elaborated upon here.
[0061] In one possible design, Figure 3 The intelligent detection system for sanding roughness of wooden doors shown in the embodiment can be implemented as a computing device, such as... Figure 4 As shown, the computing device may include a storage component 41 and a processing component 42; The storage component 41 stores one or more computer instructions, wherein the one or more computer instructions are invoked and executed by the processing component 42.
[0062] The processing component 42 is used for the above Figure 1 The embodiment describes an intelligent detection method for the sanding roughness of wooden doors.
[0063] The processing component 42 may include one or more processors to execute computer instructions to complete all or part of the steps in the above-described method. Alternatively, the processing component may be implemented as one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above-described method.
[0064] Storage component 41 is configured to store various types of data to support operations at the terminal. The storage component can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0065] Of course, computing devices may also include other components, such as input / output interfaces, display components, communication components, etc.
[0066] Input / output interfaces provide interfaces between processing components and peripheral interface modules, which can be output devices, input devices, etc.
[0067] The communication components are configured to facilitate wired or wireless communication between computing devices and other devices.
[0068] The computing device can be a physical device or an elastic computing host provided by a cloud computing platform. In this case, the computing device can refer to a cloud server, and the aforementioned processing components, storage components, etc., can be basic server resources rented or purchased from the cloud computing platform.
[0069] This application also provides a computer storage medium storing a computer program, which, when executed by a computer, can perform the above-described functions. Figure 1 The embodiment shown is an intelligent detection method for the sanding roughness of wooden doors.
[0070] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0071] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0072] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0073] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.
Claims
1. A method for intelligent detection of sanding roughness of wooden doors, characterized in that, include: High-resolution image data of the sanded surface of wooden doors are acquired. Under varying lighting conditions, dynamic gain is dynamically adjusted based on the regional brightness distribution of the sanded surface and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. Simultaneously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on multi-angle interference images to generate a surface gradient map of quantified micro-undulations. Based on the graded adjusted image data and the surface gradient map, a cross-modal data pair is constructed, and a synthetic sample simulating sanding defects is generated using physical constraints containing the geometric matching rules of wood grain direction and sanding defects. Spatial decoupling of texture attributes is performed on the synthetic sample to separate gloss reflection features and deformation structure features. Combined with the wood grain reference map, the decoupled deformation structure features are used to achieve wood grain-guided defect trajectory tracking, generating the offset path of sanding scratches relative to the wood grain direction. Based on the offset path, cross-integration classification is performed, and the roughness score and defect coordinates of the sanded wooden door are output. At the same time, a gain compensation factor is generated according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; thus realizing intelligent and high-precision detection of the sanded quality of the wooden door.
2. The method according to claim 1, characterized in that, To construct a wood grain reference map, baseline data of the wood grain direction on the sanded surface of the wooden door after sanding and reinforcing the sanding of scratches and uneven features are obtained, including: From the graded adjusted image data, the image is divided into multiple wood grain sampling units; Within the wood grain sampling unit, the principal angle value of the texture direction is calculated, and the principal angle value represents the dominant extension direction of the wood grain within the unit; By analyzing the rate of change of direction between adjacent wood grain sampling units, the continuity of wood grain is confirmed, and regions with abrupt changes in direction are smoothly connected. The principal angle values and corresponding position coordinates of all wood grain sampling units are summarized to construct a dot matrix orientation dataset; The directional dataset is encoded into a graph structure as a wood grain reference graph, where each point in the graph corresponds to the principal angle value of a wood grain sampling unit.
3. The method according to claim 1, characterized in that, Phase compensation analysis is performed on the multi-angle interferometric images based on the aforementioned wood grain reference pattern to generate a surface gradient map that quantifies microscopic undulations, including: Acquire images of the sanded surface of a wooden door from multiple light source angles to form a multi-angle interference image set; In the aforementioned wood grain reference map, the wood grain direction angle is selected as the reference line; For each pixel in the multi-angle interference image, the brightness change amplitude of the corresponding pixel under different light source angles is calculated, and based on the brightness change amplitude, the original phase difference representing the deformation caused by surface micro-undulations is calculated. Referring to the wood grain direction angle of the reference line, a phase offset correction coefficient is applied to adjust the original phase difference, resulting in an adjusted phase difference value. The phase difference value is converted into the surface height change rate, i.e., the vertical displacement per unit distance. At the same time, the height change rates of all pixels are summarized to form a point grid structure, which is stored as a surface gradient map.
4. The method according to claim 1, characterized in that, Based on the graded adjusted image data and the surface gradient map, cross-modal data pairs are constructed. Synthetic samples simulating sanding defects are generated using physical constraints containing rules for matching wood grain direction and sanding defects geometrically, including: The pixels in the graded adjusted image data are mapped one-to-one with the corresponding points in the surface gradient map to form cross-modal data pairs. Define a geometric matching rule that the angle between the direction of sanding scratches and the direction of wood grain must be within a preset range, and the ratio of scratch length to wood grain width must be fixed. In the cross-modal data pair, the location regions that satisfy the geometric matching rules are identified, and the pixel values of the image data are modified within the location regions, and a point set simulating the scratch shape is added; Adjust the height change rate in the surface gradient map to simulate surface abrupt changes caused by scratches, and output a synthetic sample containing simulated sanding defect areas.
5. The method according to claim 1, characterized in that, The synthetic sample undergoes spatial decoupling of texture attributes to separate gloss reflection features from deformation structure features. Combined with the wood grain reference map, the decoupled deformation structure features are used to achieve wood grain-guided defect trajectory tracking, generating the offset path of sanding scratches relative to the wood grain direction, including: The image texture in the synthesized sample is decomposed into gloss component and deformation component, whereby the gloss component corresponds to the brightness and darkness of the pixel and the deformation component corresponds to the surface height change. The deformation component is extracted as the dominant feature, and the reference wood grain direction angle in the wood grain reference map is used to mark the reference wood grain line in the deformation component; The starting and ending points of the simulated sanding defect region are identified in the deformation component to generate an initial trajectory; Calculate the angle deviation and distance deviation between the initial trajectory and the reference wood grain line at each point, and record the sequence of the angle deviation and distance deviation to form the offset path of the sanding scratches relative to the wood grain direction.
6. The method according to claim 1, characterized in that, Based on the offset path, cross-integration classification is performed, outputting the roughness score and defect coordinates of the sanded wooden door. Simultaneously, a gain compensation factor is generated based on changes in ambient lighting to optimize the graded adjustment of the regional gain coefficients, including: The trajectory feature set is extracted from the offset path, and the trajectory feature set is input into a cross-integration mechanism that combines multiple pre-trained feature combiners. The trajectory features are compared with a threshold range in the feature combiner to determine the type and level of sanding defects. A comprehensive roughness score is calculated based on the type and grade. Extract the coordinates of the starting and ending points of the defects in the offset path, and simultaneously monitor the sensor data of ambient light intensity in real time to calculate the light fluctuation coefficient. A gain compensation factor is generated based on the illumination fluctuation coefficient, and the gain compensation factor is used to adjust the specular reflection threshold and scratch enhancement threshold in the regional gain coefficient. The gain compensation factor is applied to update the grading adjustment step, and the roughness score and defect coordinate position are output.
7. The method according to claim 1, characterized in that, Under varying lighting conditions, based on the regional brightness distribution of the sanded surface of the wooden door and the regional differential gain suppression of specular reflection interference, dynamic gain is dynamically adjusted in stages, while simultaneously enhancing sanding scratches and uneven features, including: High-resolution image data is divided into multiple local grid regions, and the statistical mean of brightness in each local grid region is measured as a brightness baseline value. Two gain adjustment modes are applied based on the brightness reference value: when the brightness reference value is greater than the specular reflection threshold, the pixel intensity value is reduced proportionally; when the brightness reference value is less than the scratch enhancement threshold, the pixel intensity value is increased proportionally. The mirror reflection threshold and scratch enhancement threshold of the wooden door are dynamically calculated and updated based on ambient light sensor data. The gain adjustment mode is performed separately in the local grid area, and then combined with the specular reflection threshold and scratch enhancement threshold to reassemble the entire image, outputting the graded adjusted image data.
8. A method and system for intelligent detection of sanding roughness of wooden doors, characterized in that, include: High-resolution image data of the sanded surface of wooden doors are acquired. Under varying lighting conditions, dynamic gain is dynamically adjusted based on the regional brightness distribution of the sanded surface and the regional differential gain to suppress specular reflection interference, while enhancing the sanding scratches and uneven features. Simultaneously acquire the wood grain direction reference data of the sanded surface of the wooden door after strengthening sanding scratches and uneven features to construct a wood grain reference map, and combine the wood grain reference map to perform phase compensation analysis on multi-angle interference images to generate a surface gradient map of quantified micro-undulations. Based on the graded adjusted image data and the surface gradient map, a cross-modal data pair is constructed, and a synthetic sample simulating sanding defects is generated using physical constraints containing the geometric matching rules of wood grain direction and sanding defects. Spatial decoupling of texture attributes is performed on the synthetic sample to separate gloss reflection features and deformation structure features. Combined with the wood grain reference map, the decoupled deformation structure features are used to achieve wood grain-guided defect trajectory tracking, generating the offset path of sanding scratches relative to the wood grain direction. Based on the offset path, cross-integration classification is performed, and the roughness score and defect coordinates of the sanded wooden door are output. At the same time, a gain compensation factor is generated according to the change of ambient light to optimize the regional gain coefficient of the graded adjustment; thus realizing intelligent and high-precision detection of the sanded quality of the wooden door.
9. A computing device, characterized in that, It includes a processing component and a storage component; the storage component stores one or more computer instructions; the one or more computer instructions are invoked and executed by the processing component to implement the intelligent detection method for sanding roughness of wooden doors as described in any one of claims 1 to 7.
10. A computer storage medium, characterized in that, The device contains a computer program that, when executed by a computer, implements an intelligent detection method for sanding roughness of wooden doors as described in any one of claims 1 to 7.