A method for detecting defects in a thermosetting resin glue
By converting image intensity into normalized reflectance and constructing a multi-scale structural response model, a severity index and a discrimination potential are generated, solving the problem of inaccurate defect identification in thermosetting resin adhesive testing and achieving defect traceability and transparency of test results.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- XIAN TAIHAO FUNCTIONAL POLYMER MATERIALS CO LTD
- Filing Date
- 2025-09-23
- Publication Date
- 2026-06-23
AI Technical Summary
Existing detection technologies struggle to accurately identify bubbles, cracks, and uncured areas in thermosetting resin adhesives, and lack predictive analysis of process parameters and curing processes, resulting in unstable test results and an inability to provide early warnings.
By converting the original image intensity into normalized reflectance, defect candidate responses are generated, and a multi-scale structural response model is constructed to generate a severity index and candidate fusion quantity. Finally, a discriminative potential is generated to achieve accurate detection and traceable labeling of defects.
It enables accurate detection of defects in thermosetting resin adhesives, provides traceable labels to indicate the severity of defects, ensures the transparency and comparability of test results, and supports subsequent verification and cross-batch comparison.
Smart Images

Figure CN121190440B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of resin adhesive technology, and in particular to a defect detection method for thermosetting resin adhesives. Background Technology
[0002] Thermosetting resin adhesives are important materials for structural bonding and insulating encapsulation, and are widely used in aerospace, rail transportation, electronic packaging and high-end equipment manufacturing.
[0003] In actual preparation and curing processes, thermosetting resin adhesives are highly susceptible to defects such as bubbles, voids, microcracks, uncured areas, and delamination. These defects often lead to decreased bond strength, reduced durability, and unstable insulation performance. Existing testing technologies mainly rely on single non-destructive testing methods, such as ultrasonic testing, infrared thermography, or X-ray imaging. While these methods can identify internal defects to some extent, they generally suffer from the following shortcomings: First, traditional methods are easily affected by differences in material thickness, optical transparency, or acoustic impedance, resulting in insufficient stability of test results; second, existing surface imaging methods can only provide two-dimensional defect features, making it difficult to effectively distinguish between real defects and surface artifacts; third, when defects have not yet formed, existing methods lack predictive analysis of process parameters and the curing process, failing to provide early warnings. These shortcomings severely limit the application of thermosetting resin adhesives in high-reliability scenarios. Summary of the Invention
[0004] Therefore, it is necessary to provide a defect detection method for thermosetting resin adhesives that can accurately detect bubbles, cracks, and uncured areas, indicate the severity of defects, and record the statistical parameters and calculation paths corresponding to the label, so as to facilitate subsequent verification and cross-batch comparison and achieve transparency and traceability of test results.
[0005] The technical solution of this invention is as follows:
[0006] A method for detecting defects in thermosetting resin adhesives, the method comprising:
[0007] The original image intensity is converted into normalized reflectance, and defect candidate responses are generated based on the normalized reflectance.
[0008] A severity index is generated based on the defect candidate responses, and a candidate fusion quantity is generated based on the severity index.
[0009] A discrimination potential is generated based on the candidate fusion quantities;
[0010] Based on the discriminative potential energy, a traceable tag is generated.
[0011] Optionally, the original image intensity is converted into normalized reflectance, and a defect candidate response is generated based on the normalized reflectance, including:
[0012] The original image intensity is converted into normalized reflectance based on a reflectance conversion model;
[0013] A multi-scale structural response model is constructed based on the normalized reflectivity, and candidate defect responses are generated.
[0014] Optionally, the original image intensity is converted into normalized reflectance based on a reflectance conversion model; including:
[0015] In response to acquiring the original image intensity, the dark level and the equivalent intensity of the illumination field in the counting domain are acquired;
[0016] Based on the original image intensity, a reflectance conversion model is constructed using the dark level and the equivalent intensity of the illumination field in the counting domain.
[0017] Normalized reflectance is generated based on the reflectance conversion model.
[0018] Optionally, a multi-scale structural response model is constructed based on the normalized reflectivity, and candidate defect responses are generated, including:
[0019] The pixel physical size is obtained based on the normalized reflectance;
[0020] A multi-scale structural response model is constructed based on the normalized reflectivity and pixel physical size;
[0021] Defect candidate responses are generated based on the multi-scale structural response model.
[0022] Optionally, a severity index is generated based on the defect candidate response, and a candidate fusion quantity is generated based on the severity index; including:
[0023] Based on the candidate defect responses, regional aggregation is performed, and a severity index is generated;
[0024] Candidate fusions are performed based on the severity index, and a candidate fusion quantity is generated.
[0025] Optionally, the defect candidate responses are regionalized and aggregated to generate a severity index, including:
[0026] Based on the defect candidate responses, regional aggregation is performed, and the average value of the defect candidate responses in the k-th region is generated;
[0027] A severity index is generated based on the average value of the candidate defect responses in the k-th region, the equivalent diameter of the k-th region, and the shape compactness.
[0028] Optionally, performing candidate fusion and generating candidate fusion quantities based on the severity index includes:
[0029] In response to generating the severity index, the response persistence ratio is obtained;
[0030] Candidate fusion quantities are generated based on the severity index and the response persistence ratio.
[0031] Optionally, generating a discriminative potential based on the candidate fusion amount includes:
[0032] The median is generated based on the candidate fusion values;
[0033] An adaptive threshold is generated based on the median and a preset sensitivity parameter;
[0034] A discriminative potential is generated based on the adaptive threshold and the candidate fusion amount.
[0035] Optionally, the discriminant potential is generated based on the following formula:
[0036]
[0037]
[0038] in, To determine potential energy; The number of candidate fusions; An adaptive threshold; For all the median; For sensitivity parameters; all The absolute deviation of the median.
[0039] Optionally, a defect detection system for thermosetting resin adhesives is also provided, the system comprising:
[0040] A defect candidate generation module is used to convert the original image intensity into normalized reflectance and generate defect candidate responses based on the normalized reflectance.
[0041] The candidate fusion generation module is used to generate a severity index based on the defect candidate response and to generate a candidate fusion quantity based on the severity index.
[0042] A discrimination potential energy generation module is used to generate a discrimination potential energy based on the candidate fusion amount;
[0043] The traceability tag generation module is used to generate traceable tags based on the discrimination potential energy.
[0044] Optionally, the defect candidate generation module is further configured to: convert the original image intensity into normalized reflectance based on the reflectance conversion model; construct a multi-scale structural response model based on the normalized reflectance; and generate defect candidate responses.
[0045] Optionally, the defect candidate generation module is further configured to: in response to obtaining the original image intensity, obtain the equivalent intensity of the dark level and the illumination field in the counting domain; construct a reflectance conversion model based on the original image intensity and the equivalent intensity of the dark level and the illumination field in the counting domain; and generate normalized reflectance based on the reflectance conversion model.
[0046] Optionally, the defect candidate generation module is further configured to: obtain the pixel physical size based on the normalized reflectance; construct a multi-scale structural response model based on the normalized reflectance and the pixel physical size; and generate defect candidate responses based on the multi-scale structural response model.
[0047] Optionally, the candidate fusion generation module is further configured to: perform regional aggregation based on the defect candidate responses and generate a severity index; perform candidate fusion based on the severity index and generate a candidate fusion quantity.
[0048] Optionally, the candidate fusion generation module is further configured to: perform regional aggregation based on the defect candidate responses and generate the average value of the defect candidate responses in the k-th region; and generate a severity index based on the average value of the defect candidate responses in the k-th region, the equivalent diameter of the k-th region, and the shape compactness.
[0049] Optionally, the candidate fusion generation module is further configured to: obtain the response persistence ratio in response to generating the severity index; and generate candidate fusion quantities based on the severity index and the response persistence ratio.
[0050] Optionally, the discrimination potential generation module is further configured to: generate a median based on the candidate fusion amount; generate an adaptive threshold based on the median and a preset sensitivity parameter; and generate a discrimination potential based on the adaptive threshold and the candidate fusion amount.
[0051] Optionally, the discrimination potential energy generation module is further configured to: generate discrimination potential energy based on the following formula:
[0052]
[0053]
[0054] in, To determine potential energy; The number of candidate fusions; An adaptive threshold; For all the median; For sensitivity parameters; all The absolute deviation of the median.
[0055] Optionally, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps described in the above-described method for detecting defects in thermosetting resin adhesives.
[0056] Optionally, a computer-readable storage medium is also provided, on which a computer program is stored, which, when executed by a processor, implements the steps described in the above-described method for detecting defects in thermosetting resin adhesives.
[0057] The technical effects achieved by this invention are as follows:
[0058] 1. The above-mentioned defect detection method for thermosetting resin adhesive converts the original image intensity into normalized reflectivity. Specifically, it constructs a joint compensation of scene lighting field and camera dark level to convert the original image intensity into normalized reflectivity related to the inherent reflective properties of the material. Based on the normalized reflectivity, defect candidate responses are generated, which selectively enhance the tip of fine cracks and the boundary of bubbles based on the defect candidate responses, so as to accurately detect bubbles, cracks and uncured areas, and realize comprehensive defect detection.
[0059] 2. Generate a severity index for engineering handling based on the candidate defect responses, and generate a candidate fusion quantity based on the severity index; generate a discrimination potential based on the candidate fusion quantity, and use the discrimination potential to achieve unified input for subsequent classification;
[0060] 3. Based on the discriminative potential energy, perform engineering-based hierarchical mapping and generate traceable labels. The traceable label refers to the textual or data-based identifier generated for each defect area after hierarchical classification, which includes the level, location, morphological characteristics, and relevant calculation basis. Based on the traceable label, the severity of the defect can be indicated, and the statistical parameters and calculation path corresponding to the label are also recorded, which facilitates subsequent review and cross-batch comparison, and realizes the transparency and traceability of the test results. Attached Figure Description
[0061] Figure 1 This is a flowchart illustrating a defect detection method for thermosetting resin adhesives in one embodiment.
[0062] Figure 2 This is a structural block diagram of a defect detection system for thermosetting resin adhesives in one embodiment;
[0063] Figure 3 This is a structural block diagram of a computer device in one embodiment. Detailed Implementation
[0064] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.
[0065] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0066] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0067] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."
[0068] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0069] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0070] In one embodiment, a terminal is provided, the terminal being configured to: convert the original image intensity into normalized reflectance, and generate a defect candidate response based on the normalized reflectance; generate a severity index based on the defect candidate response, and generate a candidate fusion quantity based on the severity index; generate a discrimination potential based on the candidate fusion quantity; and generate a traceable tag based on the discrimination potential.
[0071] The terminal may be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices.
[0072] In one embodiment, such as Figure 1 As shown, a defect detection method for thermosetting resin adhesives is provided, the method comprising:
[0073] Step S100: Convert the original image intensity into normalized reflectance, and generate defect candidate responses based on the normalized reflectance;
[0074] Step S200: Generate a severity index based on the defect candidate response, and generate a candidate fusion quantity based on the severity index;
[0075] Step S300: Generate a discrimination potential based on the candidate fusion amount;
[0076] Step S400: Generate a traceable tag based on the discriminative potential energy.
[0077] In this embodiment, the original image intensity is converted into normalized reflectivity. Specifically, a joint compensation of scene lighting field and camera dark level is constructed to convert the original image intensity into normalized reflectivity related to the inherent reflectivity of the material. Based on the normalized reflectivity, a defect candidate response is generated, which selectively enhances the tip of fine cracks and the boundary of bubbles based on the defect candidate response, so as to accurately detect bubbles, cracks and uncured areas, and realize comprehensive defect detection.
[0078] A severity index for engineering handling is generated based on the candidate defect responses, and a candidate fusion quantity is generated based on the severity index; a discrimination potential is generated based on the candidate fusion quantity, and a unified input for subsequent classification is achieved based on the discrimination potential.
[0079] Based on the discriminative potential energy, an engineering-graded mapping and traceable label generation are performed. The traceable label refers to a textual or data-based identifier generated for each defect area after grading, which includes the grade, location, morphological characteristics, and relevant calculation basis. Based on the traceable label, the severity of the defect can be indicated, and the statistical parameters and calculation path corresponding to the label are recorded, which facilitates subsequent review and cross-batch comparison, and realizes the transparency and traceability of the test results.
[0080] In one embodiment, step S100: converting the original image intensity into normalized reflectance, and generating a defect candidate response based on the normalized reflectance, includes:
[0081] Step S110: Convert the original image intensity into normalized reflectance based on the reflectance conversion model;
[0082] Step S120: Construct a multi-scale structural response model based on the normalized reflectivity and generate candidate defect responses.
[0083] In this embodiment, the original image intensity is converted into normalized reflectance based on a reflectance conversion model. The normalized reflectance is a dimensionless ratio that represents the relative relationship between the reflected light intensity of a pixel at that location and the reference illumination intensity. This ensures the comparability and consistency of data from different batches, different devices, and different lighting conditions. By constructing a multi-scale structural response model based on the normalized reflectance and generating defect candidate responses, the defect candidate responses not only exhibit high response values at bubble boundaries and fine crack tips, but also significantly suppress false detections caused by uneven illumination and texture differences. This provides clearer and more reliable defect candidate region input for subsequent steps.
[0084] In one embodiment, step S110: converting the original image intensity into normalized reflectance based on a reflectance conversion model; including:
[0085] Step S111: In response to acquiring the original image intensity, acquire the dark level and the equivalent intensity of the illumination field in the counting domain;
[0086] Step S112: Construct a reflectance conversion model based on the original image intensity, the dark level, and the equivalent intensity of the illumination field in the counting domain;
[0087] Step S113: Generate normalized reflectance based on the reflectance conversion model.
[0088] In this embodiment, by constructing a joint compensation between the scene lighting field and the camera dark level, the original image intensity is transformed into a normalized reflectivity map related to the inherent reflectivity characteristics of the material.
[0089] Adaptive illumination calibration is performed using a camera-light source integrated device. A standard reference image is placed within the same field of view and rapid two-point calibration is performed to estimate the spatially non-uniform illumination field.
[0090] Subsequently, short exposures were used to suppress high-brightness reflections, and polarizers were used to reduce the specular component, ultimately yielding a normalized reflectance map for subsequent texture and fine defect characterization.
[0091] The camera-light source integrated device is a mature device in the prior art that includes both a camera and a light source. The specific device can be selected by those skilled in the art, and other image sensors can also be used.
[0092] A standard reference sheet is a benchmark material used in image acquisition and optical inspection for correction of illumination uniformity and reflectivity. Its main characteristics are stable, known, and repeatable surface optical properties. A standard reference sheet acts as an "optical reference sample," helping to correct camera images to a scale consistent with the material's inherent reflective properties.
[0093] Rapid two-point calibration refers to selecting two reference points with known optical reflectance in the image acquisition scene (such as a standard white board and a standard black board, or a high-reflectance and low-reflectance area), and using the correspondence between their response values in the image and the actual reflectance, thus enabling rapid brightness correction and normalization without the need for complex curve fitting.
[0094] Estimating spatially non-uniform illumination fields involves analyzing the brightness differences of pixels at different locations in an image by placing a standard reference image with a uniform surface within the field of view (or acquiring an image in a blank field), thereby estimating the non-uniformity of the light source distribution in space. Specifically, this typically involves smoothing or polynomial fitting the entire reference image to obtain a background field map representing the illumination distribution, which is then used to remove or compensate for the effects of uneven illumination in the sample image.
[0095] During imaging, thermosetting resin surfaces often exhibit high-brightness reflections due to localized gloss or transparency after curing, leading to localized overexposure and loss of defect details. To avoid this problem, the sensor's integrated light intensity can be reduced by shortening the exposure time, keeping highly reflective areas within the dynamic range and thus suppressing saturation. Simultaneously, a linear polarizer is added between the light source and the lens, with its polarization direction intersecting the incident light, effectively weakening specular reflection and retaining only diffuse reflection information. This reduces the interference of highlights on imaging while enhancing the visibility of surface textures and minute defects. Finally, by combining reference image calibration and illumination field estimation, the image is normalized to obtain a normalized reflectivity map reflecting the material's inherent reflectivity characteristics, providing stable input for subsequent defect detection.
[0096] The normalized reflectance map is a two-dimensional distribution map composed of the normalized reflectance values of all pixels in the entire image. It should be understood that the normalized reflectance of each pixel is a dimensionless value; arranging these pixels point by point on a spatial coordinate system forms the complete normalized reflectance map. This resulting map can simultaneously reflect the spatial texture, optical differences, and local defect distribution of the material surface, providing stable input for subsequent gradient calculations, region analysis, and other steps.
[0097] In the normalized reflectance map, the original pixel intensity is set as the count value, the dark level as the count value constant, the spatial illumination field has been converted to the count domain, and the pixel physical size is meters / pixel. A reflectance conversion model is constructed, and the normalized reflectance is generated based on the reflectance conversion model:
[0098]
[0099] in, Normalized reflectance is dimensionless. Normalized reflectance is the raw pixel value acquired by the camera, after removing the influence of external factors such as dark levels and illumination distribution, making the result closer to the inherent reflectivity of the material surface to incident light. In other words, it is a dimensionless ratio representing the relative intensity of light reflected by a pixel at that location to the intensity of a reference illumination, thus ensuring the comparability and consistency of data from different batches, different devices, and different lighting conditions.
[0100] This is the raw image intensity, a count value; it directly reads the raw or de-Bayer linear intensity value from the sensor under given exposure, gain, and lighting conditions (auto gain / auto exposure is recommended to be turned off). The value range is determined by the bit depth, for example: 8-bit: 0-255DN; 10-bit: 0-1023DN; 12-bit: 0-4095DN; 14-bit: 0-16383DN; 16-bit: 0-65535DN; to avoid saturation, it is recommended that the peak value not exceed 80-90% of full-frame.
[0101] This is a count value at a low level; under light-blocking conditions (lens cap or electronic shutter black frame), N≥16 frames are collected with the same exposure / gain as the actual shot to calculate the pixel-level mean or median; a lookup table can be established based on temperature and exposure time to accommodate batch differences. The value range varies with the sensor and gain, commonly 0-300DN (12-16 bit linear cameras can be as low as <50DN at low gain); it may increase under high gain or long exposure, long-term monitoring and periodic recalibration are recommended;
[0102] The equivalent intensity of the illumination field in the counting domain is represented by the count value. Flat-field calibration is employed: a reference board with high reflectivity and uniform texture is placed within the field of view. Several frames are captured at the same exposure / gain as the actual shot, and the intensity of the reference board image after darkening is calculated pixel by pixel as the equivalent intensity. Noise can be suppressed using smoothing or low-order polynomials. The value range should avoid saturation and excessive darkness; in engineering practice, it is recommended to be between 30% and 90% of the camera's full frame; for example, 1200-3600 DN is recommended for a 12-bit system. If the value is below this range locally, the light source brightness / angle needs to be adjusted or the exposure resampled.
[0103] Based on the aforementioned reflectivity conversion model, data were collected once before and once after curing, and calculations were performed separately. , (That is, the process is executed independently once before curing and once after curing to obtain the corresponding normalized reflectance map). , This will be used as input for subsequent steps.
[0104] This step focuses on addressing the detection challenges posed by the complex optical properties of thermosetting resin surfaces. Because these resins typically exhibit high transparency or translucency before curing, and undergo changes in refractive index and increased local gloss after curing, images acquired under traditional fixed lighting conditions often contain overexposed or underexposed areas, failing to accurately reflect surface micro-features. To address this, this embodiment employs an integrated camera and light source configuration, introducing an adaptive control strategy. This allows the light source to automatically adjust its brightness and incident angle based on real-time reflectivity distribution, achieving optimal imaging results in different areas. Simultaneously, two-point calibration using a standard reference film further counteracts the effects of uneven illumination and sensor low-level illumination, ensuring the image signal is normalized to a uniform scale corresponding to the inherent properties of the material.
[0105] In one embodiment, step S120: constructing a multi-scale structural response model based on the normalized reflectivity and generating candidate defect responses, including:
[0106] Step S121: Obtain the pixel physical size based on the normalized reflectivity;
[0107] Step S122: Construct a multi-scale structural response model based on the normalized reflectivity and pixel physical size;
[0108] Step S123: Generate candidate defect responses based on the multi-scale structural response model.
[0109] In this embodiment, a multi-scale structural response model is constructed based on the normalized reflectance output from the normalized reflectance map, and defect candidates are enhanced.
[0110] The normalized reflectance output in step S110 As input to the multi-scale structural response model in this step, from The process involves refining candidate response maps that are sensitive to minute surface discontinuities such as bubbles, fine cracks, and flow marks, and performing dimensionally consistent scale compensation for artifacts caused by illumination and texture anisotropy.
[0111] Based on the pixel scale dependence caused by the natural metric of local changes in gradient and Laplacian operator, the multi-scale structural response model is normalized to the pixel physical size and integrates edge intensity and second-order change information.
[0112] The multi-scale structural response model is shown below:
[0113]
[0114] in,
[0115] The output of this step is a candidate defect response, which is dimensionless.
[0116] For the first-order gradient, For the Laplace operator;
[0117] The physical size of a pixel, in meters per pixel, is used to cancel out the dimensions of the derivative "per pixel" into a dimensionless value.
[0118] These are the weights of the gradient operator, in pixels. The weights of the Laplacian operator, in pixels. 2 It is used to balance the contribution of edge and second-order changes between different materials and curing stages. It is set by experiments or experience. It is used to adjust the relative contribution of first-order gradient and second-order change in defect response. It is usually set to 0.1-2.0 and can be adjusted according to different materials and imaging conditions.
[0119] The normalized reflectance U(x,y) is itself a dimensionless quantity, and after the gradient operator... After the operation, the result has the reciprocal dimension of length, i.e., m. -1 When this result is combined with the pixel physical size p and the weights of the gradient operator... After multiplication, the dimensions cancel each other out, resulting in a dimensionless value. Similarly, the Laplace operator... When acting on a dimensionless quantity, it produces m -2 The dimensions of the quantity, and then with Weights of the Laplace operator After multiplication, the result is also converted into a dimensionless quantity. Therefore, based on the setting of the defect candidate response, the comparability and stability of the results under different resolutions and imaging conditions can be guaranteed.
[0120] In practical applications, estimation is performed on a finite number of scales. and Then, take the weighted sum and substitute it back into the model to obtain... It can selectively enhance the tip of a fine crack and the boundary of a bubble.
[0121] The key point is By constructing responses at the structural level, the subtle defects in the image are fully amplified.
[0122] To achieve this goal, a gradient operator is used to characterize the local first-order variation of intensity, highlighting areas with more prominent boundary transitions; at the same time, the Laplacian operator is used to capture second-order variation features, thus showing sensitivity to high curvature areas such as point-like or crack-tip regions.
[0123] While traditional methods may utilize these operators, they often directly output pixel-level results without considering the impact of the actual physical size of the pixels on the derivative's order of magnitude, leading to discrepancies at different camera resolutions. To address this issue, this step specifically introduces the pixel size parameter into the model. By multiplying it with the gradient and the results of the second-order operators, or by squaring them, the results at different resolutions are normalized to dimensionless quantities, ensuring comparability between the results. The final multi-scale structural response is obtained. It not only exhibits high response values at bubble boundaries and fine crack tips, but also significantly suppresses false detections caused by uneven illumination and texture differences, thus providing clearer and more reliable defect candidate region inputs for subsequent steps.
[0124] In one embodiment, step S200: generating a severity index based on the defect candidate response, and generating a candidate fusion quantity based on the severity index; includes:
[0125] Step S210: Perform regional aggregation based on the defect candidate responses and generate a severity index;
[0126] Step S220: Perform candidate fusion based on the severity index and generate candidate fusion quantity.
[0127] In this embodiment, a severity index is generated by regionalizing and aggregating the candidate defect responses. Based on this severity index, candidate fusion is performed to generate a candidate fusion quantity. The severity index elevates pixel-level fragmented information into an engineering-interpretable indicator, and the candidate fusion quantity is an intermediate result with consistency and traceability. Based on this candidate fusion quantity, the detection process can not only track the evolution trend of defects before and after solidification but also avoid common misjudgment problems in single-stage detection.
[0128] In one embodiment, step S210: performing regional aggregation based on the defect candidate responses and generating a severity index includes:
[0129] Step S211: Perform regional aggregation based on the defect candidate responses and generate the average value of the defect candidate responses in the k-th region;
[0130] Step S212: Generate a severity index based on the average value of the candidate defect responses in the k-th region, the equivalent diameter of the k-th region, and the shape compactness.
[0131] In this embodiment, for Regional aggregation is performed to obtain a severity index for engineering treatment. First, a robust morphological connectivity strategy is used to form connected regions on the candidate response graph. For the k-th connected region, the severity index is calculated:
[0132]
[0133] in,
[0134] This is a severity index, dimensionless;
[0135] For the k-th region The average value;
[0136] Let be the equivalent diameter of the k-th region, in meters. Convert the area of the region to the equivalent circle diameter, for example... ,in The area is the region (obtained by multiplying the number of pixels by the square of the pixel's physical size).
[0137] The reference length related to the process is in meters and is given by the process standard or equipment calibration.
[0138] Shape compactness, dimensionless, is calculated as the ratio of a region's perimeter to its area, for example... ,in For the area, The value represents the perimeter. Regular circular areas are close to 1, while cracked areas have smaller values.
[0139] The aggregate weights are dimensionless and are set through experimental calibration or manual experience. They are used to adjust the relative importance of different features in the severity index. The value range is generally between 0.1 and 5.0, and can be adjusted according to the process requirements for sensitivity and tolerance.
[0140] In this step, firstly, the response... Connectivity analysis is performed by using morphological connection strategies (which involve using mathematical morphology methods such as dilation, erosion, opening and closing operations) to connect high-response pixels that are adjacent to each other or very close together in the response map into a connected region.
[0141] This method groups scattered pixels on the same defect edge together, avoiding the fragmentation of the defect area due to noise or local interruptions. Its advantages include maintaining the overall defect outline while suppressing isolated noise, improving the stability and continuity of region identification. It identifies sets of pixels that may belong to the same defect, forming several candidate defect regions. Within each region, three key statistics are calculated: 1) the region's average response value, characterizing the overall degree of anomaly; 2) the region's equivalent diameter, normalized using the process reference length to eliminate the influence of different equipment imaging resolutions and workpiece size differences; and 3) the region's shape compactness, used to characterize whether the defect is close to a regular circle or has a tendency to develop fine cracks. A severity index is obtained through a weighted combination of these three statistics. This index serves as a comprehensive metric for the region. It's important to emphasize that this index is not a direct judgment of pass or fail, but rather an intermediate-level quantitative description. On the one hand, it elevates pixel-level, fragmented information into an engineering-interpretable indicator; on the other hand, it ensures the smooth transfer and use of data in subsequent steps. This design guarantees the method's hierarchy and logical clarity, while avoiding the noise sensitivity and difficulty in reproducibility issues of traditional pixel-level detection, making the detection results more robust and traceable.
[0142] In one embodiment, step S220: performing candidate fusion based on the severity index and generating candidate fusion quantity includes:
[0143] Step S221: In response to generating the severity index, obtain the response persistence ratio;
[0144] Step S222: Generate candidate fusion quantities based on the severity index and the response persistence ratio.
[0145] In this embodiment, within the connected region obtained by step S210, the average absolute value of the difference in normalized reflectance before and after curing is statistically analyzed to capture the real structural changes caused by curing.
[0146] At the same time, a response persistence ratio is introduced to indicate the degree of overlap of high-response pixels in the region before and after curing, in order to suppress pseudo-changes caused by random noise or occasional reflections.
[0147] The model for the candidate fusion quantity is as follows:
[0148]
[0149] in, The quantity of candidate fusions is dimensionless.
[0150] This represents the average reflectance difference within the region;
[0151] The response persistence ratio is the pixel overlap ratio of the high quantile response set in this region during both the pre- and post-curing stages. The value is between zero and one. High response pixels can be determined by setting a quantile threshold (such as the top 10%), and it is dimensionless.
[0152] The high-quantile response set refers to the set of pixels whose values rank in the top percentage (e.g., top 10% or 20%) in a response map at a certain stage. These pixels represent the areas with the strongest responses and are most likely to correspond to defects. The elements are these selected high-response pixels, each containing its spatial location in the image and its corresponding response value.
[0153] It is a dimensionless fusion coefficient used to balance the three contributions under different material and surface conditions. It is set by experimental or engineering experience and the relative contributions of the three parts can be adjusted according to the detection focus. The value range is generally 0.1-3.0. In common applications, it is set to the sum of the weights after normalization as 1.
[0154] In this step, the main task is to... By integrating data from both the pre- and post-curing stages of the process, a more stable index for changes in the process and environment is obtained. Specifically, the severity index for each region reflects the overall level of anomalies in pixel response within that region, but relying solely on... It is susceptible to random noise or sporadic light spots. Therefore, this step first introduces the regional average difference in normalized reflectance before and after curing. By directly comparing the data before and after curing, it identifies which changes are truly caused by the material curing process, thereby enhancing the accuracy of the judgment. Secondly, it introduces the response duration ratio. This metric measures the overlap of high-response pixels in the region during the two stages before and after curing. This metric effectively eliminates spurious responses that only occasionally appear in a single stage, making the results more robust. Finally, these three types of information are fused into a unified metric using a dimensionless linear combination. This outputs a consistent and traceable intermediate result. In this way, the detection process can not only track the evolution trend of defects before and after curing, but also avoid the misjudgment problems common in single-stage detection.
[0155] In one embodiment, step S300: generating a discriminative potential based on the candidate fusion amount includes:
[0156] Step S310: Generate the median based on the candidate fusion values;
[0157] Step S320: Generate an adaptive threshold based on the median and the preset sensitivity parameter;
[0158] Step S330: Generate a discriminative potential based on the adaptive threshold and the candidate fusion amount.
[0159] In this embodiment, based on robust statistics within the batch, an adaptive threshold is automatically generated, and the relative degree of boundary crossing for each region is expressed as a discriminative potential, so as to achieve a unified input for subsequent classifications:
[0160] For all of the current workpiece or batch The median is taken as the robust center, the absolute deviation of the median is used as the robust scale, and the sensitivity is adjusted with an adjustable coefficient to obtain the adaptive threshold and the discrimination potential of each region is obtained.
[0161] The adaptive threshold and the discriminative potential energy are obtained in the following ways:
[0162]
[0163] in, To determine potential energy, it is dimensionless and used to measure the intensity of crossing the boundary relative to the region's threshold;
[0164] For all The median, dimensionless;
[0165] For all The absolute deviation of the median is dimensionless.
[0166] This is a sensitivity parameter, dimensionless, set manually or tuned experimentally, used to control the sensitivity of the threshold to data dispersion; the value ranges from 1 to 3, the larger the value, the more lenient the threshold, and the smaller the value, the more stringent the threshold.
[0167] This is an adaptive threshold.
[0168] When using it, engineers will determine the appropriate level of technological maturity. Set it to a smaller value (e.g., <1.5) to improve recall, or set it to a larger value (e.g., >2) to improve precision.
[0169] In this step, the detection process enters a crucial intermediate discrimination stage, namely, how to determine the outcome based on the results obtained in the previous step. Generate stable discrimination signals for subsequent grading. Traditional methods often rely on manually preset thresholds, such as setting a fixed value as a judgment boundary; exceeding this value indicates a defect, while falling below it indicates acceptance. However, in the actual testing of thermosetting resin adhesives, the material formulation, optical surface treatment methods, and even the details of the curing process of different batches can all lead to... The overall distribution level shifts. If a fixed threshold is continued to be used, over-detection will occur in one batch, or significant missed detection will occur in another batch, severely affecting the consistency and reliability of the detection.
[0170] Therefore, this step employs a robust statistical strategy: first, for all items in the same workpiece or batch... The median value is taken as the central location indicator, and the absolute deviation of the median is calculated as the scaling measure, combined with a sensitivity parameter. Automatically generate adaptive thresholds for the current batch. Next, for each region... With threshold Compare the values and define the "discriminant potential" using the difference. The magnitude of this potential energy not only reflects the intensity of the region's deviation from the threshold, but also provides continuous and interpretable input for subsequent grading. This processing method can naturally resist the interference of extreme outliers on the threshold setting, ensuring the stability of detection results under different batches and operating conditions.
[0171] In one embodiment, step S400: generating a traceable tag based on the discriminative potential energy, specifically includes:
[0172] After completing adaptive thresholding, it is still necessary to combine the size and shape information of the area to form a grade label that is more in line with the engineering treatment; for example, weak but large-area voids are often more worthy of priority repair than strong but tiny isolated points.
[0173] This step constructs an interpretable level mapping without introducing a complex learner, synthesizes the three elements of "whether it exceeds the boundary", "size ratio" and "shape compactness" into a unified label score, and generates a traceable text label based on this, thus enabling the label to be traced.
[0174] Traceable labels are textual or data-based identifiers generated for each defective area after grading, containing the grade, location, morphological characteristics, and relevant calculation basis. They not only indicate the severity of the defect but also record the corresponding statistical parameters and calculation path, facilitating subsequent verification and cross-batch comparisons, thus achieving transparency and traceability of test results.
[0175] The process of synthesizing a unified label score involves weighting three factors—whether the area exceeds an adaptive threshold, the proportion of the area size relative to the baseline size, and the compactness of the area shape—to obtain a comprehensive score. The so-called interpretable grade mapping divides this score into pre-defined intervals; for example, 0-2 represents "mild," 2-4 represents "moderate," and greater than 4 represents "severe," thus allowing each detection result to intuitively correspond to a clear engineering treatment level.
[0176] When in use, three score levels can be set on-site, mapping the range into which the unified label score falls to "slight", "moderate" and "severe" labels, and writing the corresponding area polygon, source stage and key statistics into the inspection record to achieve cross-batch traceability and verification. Moreover, this grading strategy is easy to connect with subsequent repair processes. For example, when the number or total area of "severe" labels exceeds the process limit, the line stop re-inspection strategy is automatically triggered.
[0177] In one embodiment, such as Figure 2 As shown, a defect detection system for thermosetting resin adhesives is also provided, the system comprising:
[0178] A defect candidate generation module is used to convert the original image intensity into normalized reflectance and generate defect candidate responses based on the normalized reflectance.
[0179] The candidate fusion generation module is used to generate a severity index based on the defect candidate response and to generate a candidate fusion quantity based on the severity index.
[0180] A discrimination potential energy generation module is used to generate a discrimination potential energy based on the candidate fusion amount;
[0181] The traceability tag generation module is used to generate traceable tags based on the discrimination potential energy.
[0182] In one embodiment, the defect candidate generation module is further configured to: convert the original image intensity into normalized reflectance based on a reflectance conversion model; construct a multi-scale structural response model based on the normalized reflectance; and generate defect candidate responses.
[0183] In one embodiment, the defect candidate generation module is further configured to: in response to acquiring the original image intensity, acquire the equivalent intensity of the dark level and the illumination field in the counting domain; construct a reflectance conversion model based on the original image intensity and the equivalent intensity of the dark level and the illumination field in the counting domain; and generate normalized reflectance based on the reflectance conversion model.
[0184] In one embodiment, the defect candidate generation module is further configured to: obtain the pixel physical size based on the normalized reflectance; construct a multi-scale structural response model based on the normalized reflectance and the pixel physical size; and generate defect candidate responses based on the multi-scale structural response model.
[0185] In one embodiment, the candidate fusion generation module is further configured to: perform regional aggregation based on the defect candidate responses and generate a severity index; perform candidate fusion based on the severity index and generate a candidate fusion quantity.
[0186] In one embodiment, the candidate fusion generation module is further configured to: perform regional aggregation based on the defect candidate responses and generate an average value of the defect candidate responses in the k-th region; and generate a severity index based on the average value of the defect candidate responses in the k-th region, the equivalent diameter of the k-th region, and the shape compactness.
[0187] In one embodiment, the candidate fusion generation module is further configured to: obtain the response persistence ratio in response to generating the severity index; and generate candidate fusion quantities based on the severity index and the response persistence ratio.
[0188] In one embodiment, the discrimination potential generation module is further configured to: generate a median based on the candidate fusion amount; generate an adaptive threshold based on the median and a preset sensitivity parameter; and generate a discrimination potential based on the adaptive threshold and the candidate fusion amount.
[0189] In one embodiment, the discrimination potential energy generation module is further configured to: generate discrimination potential energy based on the following formula:
[0190]
[0191]
[0192] in, To determine potential energy; The number of candidate fusions; An adaptive threshold; For all the median; For sensitivity parameters; all The absolute deviation of the median.
[0193] In one embodiment, such as Figure 3 As shown, a computer device is also provided, including a memory and a processor. The memory stores a computer program and an operating system. When the processor executes the computer program, it implements the steps described in the above-described method for detecting defects in thermosetting resin adhesives. The computer device also includes a system bus, internal memory, a network structure, a display screen, and input devices, etc.
[0194] In one embodiment, a computer-readable storage medium is also provided, on which a computer program is stored, which, when executed by a processor, implements the steps described in the above-described method for detecting defects in thermosetting resin adhesives.
[0195] It should be noted that the information interaction and execution process between the above modules are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, which will not be repeated here.
[0196] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0197] This application also provides a network device, which includes: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, wherein the processor executes the computer program to implement the steps in any of the above method embodiments.
[0198] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.
[0199] This application provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the above-described method embodiments.
[0200] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the above-described embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying computer program code to a photographic device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electrical carrier signals or telecommunication signals.
[0201] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0202] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0203] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0204] 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 units can be selected to achieve the purpose of this embodiment according to actual needs.
[0205] The above-described 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, and should all be included within the protection scope of this application.
[0206] One embodiment of this application also provides a computer device, which includes: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, wherein the processor executes the computer program to implement the steps in any of the above-described methods.
[0207] The computer device may include, but is not limited to, a processor and memory. Those skilled in the art will understand that the above description is an example of a computer device and does not constitute a limitation on the computer device. It may include more or fewer components than described above, or a combination of certain components, or different components, such as input / output devices, network access devices, etc.
[0208] The processor can be a Central Processing Unit (CPU), but it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor.
[0209] In some embodiments, the memory may be an internal storage unit of the computer device, such as a hard drive or RAM. In other embodiments, the memory may be an external storage device of the computer device, such as a plug-in hard drive, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card. Furthermore, the memory may include both internal and external storage units of the computer device. The memory is used to store the operating system, applications, bootloader, data, and other programs, such as the program code of the computer program. The memory can also be used to temporarily store data that has been output or will be output.
[0210] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0211] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of the invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method for defect detection in thermosetting resin adhesives, characterized in that, The method includes: The process involves converting the original image intensity into normalized reflectance and generating defect candidate responses based on the normalized reflectance, including: The original image intensity is converted into normalized reflectance based on the reflectance conversion model, including: In response to acquiring the original image intensity, the equivalent intensity of the dark level and the illumination field in the counting domain is obtained; based on the original image intensity, the equivalent intensity of the dark level and the illumination field in the counting domain is used to construct a reflectance conversion model; based on the reflectance conversion model, a normalized reflectance is generated as follows: ,in, For normalized reflectivity, The original image intensity, Dark level, The equivalent intensity of the illumination field in the counting domain; A multi-scale structural response model is constructed based on the normalized reflectivity, and candidate defect responses are generated, including: The pixel physical size is obtained based on the normalized reflectance; a multi-scale structural response model is constructed based on the normalized reflectance and the pixel physical size; candidate defect responses are generated based on the multi-scale structural response model; the multi-scale structural response model is shown below: ,in, This is a candidate response for a defect. For the first-order gradient, For the Laplace operator, The physical size of a pixel. These are the weights of the gradient operator, in pixels. The weights of the Laplacian operator, in pixels. 2 ; The process of generating a severity index based on the candidate defect responses and generating a candidate fusion quantity based on the severity index includes: performing regional aggregation based on the candidate defect responses and generating a severity index; performing candidate fusion based on the severity index and generating a candidate fusion quantity; and performing regional aggregation based on the candidate defect responses and generating a severity index, including: performing regional aggregation based on the candidate defect responses and generating the average value of candidate defect responses in the k-th region; and generating a severity index based on the average value of candidate defect responses in the k-th region, the equivalent diameter of the k-th region, and the shape compactness. ,in, This is a severity index. For the k-th region The average value; Let be the equivalent diameter of the k-th region. For process-related reference lengths, For shape compactness, For aggregate weights; The process of performing candidate fusion and generating candidate fusion quantities based on the severity index includes: obtaining a response persistence ratio in response to generating the severity index; generating candidate fusion quantities based on the severity index and the response persistence ratio; the model for the candidate fusion quantities is as follows: ,in, For candidate fusion quantity, This represents the average reflectance difference within the region. In response to the sustained proportion, The fusion coefficient is dimensionless. Generating a discriminative potential based on the candidate fusion values includes: generating a median based on the candidate fusion values; generating an adaptive threshold based on the median and a preset sensitivity parameter; and generating a discriminative potential based on the adaptive threshold and the candidate fusion values. The adaptive threshold and the discriminative potential are obtained in the following ways: ,in, To determine potential energy; The number of candidate fusions; An adaptive threshold; For all the median; For sensitivity parameters; For all The absolute deviation of the median; Based on the discriminative potential energy, a traceable tag is generated.
2. A system for performing the defect detection method for thermosetting resin adhesive as described in claim 1, characterized in that, The system includes: A defect candidate generation module is used to convert the original image intensity into normalized reflectance and generate defect candidate responses based on the normalized reflectance. The candidate fusion generation module is used to generate a severity index based on the defect candidate response and to generate a candidate fusion quantity based on the severity index. A discrimination potential energy generation module is used to generate a discrimination potential energy based on the candidate fusion amount; The traceability tag generation module is used to generate traceable tags based on the discrimination potential energy.