An image recognition system based on big data

By constructing a knowledge graph of light source parameters and a knowledge graph of regional scratch correlation, and combining big data and lightweight convolutional neural networks, the problem of insufficient detection accuracy in traditional detection methods is solved, and efficient and reliable scratch recognition of metal processing parts is achieved.

CN121366342BActive Publication Date: 2026-03-27KECHUANGTONG CHENGDU CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-12-22
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

Traditional local threshold segmentation algorithms are difficult to adapt to the image differences of different parts in the detection of scratches on the surface of metal processing parts, resulting in insufficient detection accuracy and reliability.

Method used

We construct a knowledge graph of light source parameters and a knowledge graph of regional scratch correlation, obtain key surface characteristics and optimal light source parameters of metal processing parts through big data analysis, and combine them with a lightweight convolutional neural network for scratch recognition to achieve full-process automation.

Benefits of technology

It significantly improves the accuracy and reliability of scratch detection for metal processing parts, reduces missed and false detections, shortens the detection cycle, lowers the operating threshold, and helps upgrade production to intelligent levels.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121366342B_ABST
    Figure CN121366342B_ABST
Patent Text Reader

Abstract

The application provides a kind of big data-based image recognition system, it is related to image processing field, including: atlas construction module, for obtaining multiple sample images, establish light source parameter knowledge graph;Characteristic acquisition module, for obtaining the key surface characteristics of current metal processing parts;Parameter determination module, for determining the current light source parameter based on the key surface characteristics of current metal processing parts and light source parameter knowledge graph;Image acquisition module, for obtaining the image of current metal processing parts based on the current light source parameter;Atlas construction module is also used to construct the regional scratch correlation knowledge graph corresponding to current metal processing parts;Scratch identification module, for carrying out the scratch identification of current metal processing parts based on the regional scratch correlation knowledge graph corresponding to current metal processing parts and the image of current metal processing parts, has the advantages of improving the accuracy and reliability of the quality detection of metal processing parts.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of image processing, and in particular to an image recognition system based on big data. BACKGROUND

[0002] Metal processing is a manufacturing process that obtains metal parts with specific shape, size and performance requirements by physically deforming or removing metal raw materials (including plates, strips, pipes, profiles and blocks, etc.) through various process means (such as stamping, forging, casting, cutting, etc.). As the core basic part of industrial manufacturing, metal processing parts are widely used in key fields such as automobiles, aerospace, electronic equipment and mechanical equipment, and their quality directly determines the performance, safety and service life of the whole machine.

[0003] To ensure the quality and performance of metal processing parts, quality detection is an indispensable key link in the production process. As a surface defect, scratches can damage the continuity of metal materials and form stress concentration points. When subjected to load (such as tension, bending, vibration), stress concentration areas are prone to crack propagation, leading to part fracture or fatigue failure. Currently, the mainstream method for detecting surface scratches of metal processing parts is to obtain the surface image of the workpiece to be detected by image acquisition equipment (such as industrial cameras, line scan cameras, etc.), and then identify and extract the scratch area in the image by means of local threshold segmentation algorithm to determine whether there is a scratch defect. However, the traditional local threshold segmentation algorithm has obvious limitations: this algorithm usually sets a uniform local range size for all pixel points for threshold calculation, but when detecting metal processing parts, due to the significant differences in images of different parts (such as material reflectivity, surface texture complexity, light condition changes, etc.), and the distribution and characteristics of scratches (such as length, width, depth, direction, etc.) are different, the fixed local range size is difficult to adapt to the image characteristics of different regions, which seriously affects the accuracy and reliability of quality detection.

[0004] Therefore, it is necessary to provide an image recognition system based on big data to improve the accuracy and reliability of the quality detection of punched metal processing parts. SUMMARY

[0005] The application provides a big data-based image recognition system, comprising: a graph construction module, configured to acquire multiple sample images, and establish a light source parameter knowledge graph, wherein the light source parameter knowledge graph is used to record key surface characteristics of different types of metal processing parts and corresponding optimal light source parameters; a characteristic acquisition module, configured to acquire the key surface characteristics of a current metal processing part; a parameter determination module, configured to determine the current light source parameter based on the key surface characteristics of the current metal processing part and the light source parameter knowledge graph; an image acquisition module, configured to acquire the image of the current metal processing part based on the current light source parameter; and the graph construction module is further configured to construct a regional scratch correlation knowledge graph corresponding to the current metal processing part, wherein the regional scratch correlation knowledge graph is used to record the correlation of scratches of multiple regions of the current metal processing part; and a scratch identification module, configured to perform scratch identification of the current metal processing part based on the regional scratch correlation knowledge graph corresponding to the current metal processing part and the image of the current metal processing part.

[0006] Further, the multiple sample images comprise images of multiple sample metal processing parts acquired under different light source parameters; the graph construction module is configured to determine multiple surface characteristic factors, determine the initial surface characteristics of each sample metal processing part according to the multiple surface characteristic factors, wherein the initial surface characteristics comprise factor values corresponding to each surface characteristic factor, determine the optimal light source parameter corresponding to each sample metal processing part based on the multiple sample images, determine multiple key surface characteristic factors based on the optimal light source parameter corresponding to each sample metal processing part and the initial surface characteristics of each sample metal processing part, and establish the light source parameter knowledge graph based on the initial surface characteristics of each sample metal processing part, the multiple key surface characteristic factors and the optimal light source parameter corresponding to each sample metal processing part.

[0007] Further, the graph construction module is configured to establish and train a scratch identification model, construct a light source evaluation index set, and determine the optimal light source parameter corresponding to each sample metal processing part based on the scratch identification model, the multiple sample images and the light source evaluation index set.

[0008] Further, the graph construction module is configured to calculate the light source difference value of the optimal light source parameters corresponding to any two sample metal processing parts, calculate the factor difference value of any two sample metal processing parts based on the factor values of the surface characteristic factors of the two sample metal processing parts, calculate the light source influence coefficient of each surface characteristic factor based on the factor difference value and the light source difference value of any two sample metal processing parts, and determine the multiple key surface characteristics based on the light source influence coefficient of each surface characteristic factor.

[0009] Further, the atlas constructing module is configured to: for any two sample metal processing parts, calculate a key characteristic similarity of the two sample metal processing parts based on the initial surface characteristics and the plurality of key surface characteristic factors of each sample metal processing part; classify the plurality of sample metal processing parts based on the key characteristic similarity of any two sample metal processing parts, to determine a plurality of part classes; for each part class, calculate a light source difference value of the optimal light source parameters corresponding to any two sample metal processing parts included in the part class, group the sample metal processing parts included in the part class, to determine a part group included in each part class; and establish a light source parameter knowledge graph based on the plurality of part classes, the part group included in each part class, and the optimal light source parameters corresponding to each sample metal processing part.

[0010] Further, the parameter determining module is configured to: determine a part class corresponding to the current metal processing part based on the key surface characteristics of the current metal processing part and the light source parameter knowledge graph; determine a part group corresponding to the current metal processing part from the part groups included in the part class corresponding to the current metal processing part based on the key surface characteristics of the current metal processing part and the light source parameter knowledge graph; determine a similar sample metal processing part from the part group corresponding to the current metal processing part based on the key surface characteristics of the current metal processing part and the light source parameter knowledge graph; and determine the current light source parameter based on the optimal light source parameters corresponding to the similar sample metal processing part.

[0011] Further, the atlas constructing module is configured to: obtain images of a plurality of historical metal processing parts corresponding to the current metal processing part, wherein the images of the historical metal processing parts are obtained based on the current light source parameter; and construct a region mark correlation knowledge graph corresponding to the current metal processing part based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part.

[0012] Further, the atlas constructing module is configured to: calculate a mark similarity of any two image units based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part; determine a plurality of image regions based on the mark similarity of any two image units; calculate a region mark correlation coefficient of any two image regions based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part; and construct a region mark correlation knowledge graph corresponding to the current metal processing part based on the region mark correlation coefficient of any two image regions.

[0013] Further, the scratch identification module is configured to: determine initial scratch identification results of the plurality of image regions based on the current image of the metal processing part; and perform scratch identification of the current metal processing part based on the initial scratch identification results of the plurality of image regions and the region-scratch correlation knowledge graph corresponding to the current metal processing part.

[0014] Further, the scratch identification module is configured to: determine initial scratch identification results of the plurality of image regions based on the current image of the metal processing part; and perform scratch identification of the current metal processing part based on the initial scratch identification results of the plurality of image regions and the region-scratch correlation knowledge graph corresponding to the current metal processing part.

[0015] Compared with the prior art, the image recognition system based on big data provided by the present application has at least the following beneficial effects:

[0016] 1. By constructing a light source parameter knowledge graph, the key surface characteristics (such as material, reflectivity, and surface roughness) of the metal processing part are associated and stored with the optimal light source parameters (such as light intensity, angle, and wavelength). For the current part, the system can quickly match the optimal light source parameters, avoid the problems of image overexposure, shadow, or reflection caused by improper light source configuration, and thus obtain high-contrast and low-noise part images, providing a clear and reliable data basis for subsequent scratch identification and significantly improving detection accuracy.

[0017] 2. The region-scratch correlation knowledge graph is constructed by analyzing the statistical correlation rules (such as the correlation between the scratch density of a certain region and the trend of the adjacent region) of different region scratches in historical data, providing global constraints for scratch identification of the current part. Even if the local image is blocked or has low contrast, the system can infer potential scratch features based on the associated knowledge, reducing missed detection and false detection, and being particularly suitable for defect detection in complex surface or small sample scenarios.

[0018] 3. The full-process automatic module from light source parameter optimization to scratch identification can complete parameter adaptation, image acquisition, and defect analysis without human intervention. This design not only shortens the detection period, but also reduces the operation threshold through standardized processes, helping enterprises to realize efficient and stable quality monitoring, providing data support for process optimization and defect tracing, and promoting the intelligent upgrading of production. BRIEF DESCRIPTION OF DRAWINGS

[0019] The present specification will be further illustrated in the form of exemplary embodiments, which will be described in detail with reference to the accompanying drawings. These embodiments are not limiting, and in these embodiments, the same reference numbers represent the same structures, wherein:

[0020] Figure 1is a module schematic diagram of a big data-based image recognition system according to some embodiments of the present specification;

[0021] Figure 2 is a flow schematic diagram of establishing a light source parameter knowledge graph according to some embodiments of the present specification;

[0022] Figure 3 is a schematic diagram of a light source parameter knowledge graph according to some embodiments of the present specification;

[0023] Figure 4 is a schematic diagram of a region scratch correlation knowledge graph according to some embodiments of the present specification. DETAILED DESCRIPTION

[0024] In order to more clearly illustrate the technical solutions of the embodiments of the present specification, the following will briefly introduce the drawings needed to be used in the embodiment description. Obviously, the drawings in the following description are only some examples or embodiments of the present specification, and for those skilled in the art, without paying creative labor, the present specification can also be applied to other similar scenarios according to these drawings. Unless it is obvious from the language environment or otherwise stated, the same reference numbers in the drawings represent the same structure or operation.

[0025] Figure 1 is a module schematic diagram of a big data-based image recognition system according to some embodiments of the present specification, as shown in Figure 1 , a big data-based image recognition system can include a graph construction module, a characteristic acquisition module, a parameter determination module, an image acquisition module and a scratch recognition module.

[0026] The graph construction module is used to acquire a plurality of sample images and establish a light source parameter knowledge graph.

[0027] Among them, the light source parameter knowledge graph is used to record the key surface characteristics of different types of metal processing parts and the corresponding optimal light source parameters.

[0028] The plurality of sample images includes images of a plurality of sample metal processing parts acquired under different light source parameters. Among them, at least one of the light angle, the light point height or the spectral distribution in any two light source parameters is different.

[0029] Figure 2 is a flow schematic diagram of establishing a light source parameter knowledge graph according to some embodiments of the present specification, as shown in Figure 2 , specifically, the graph construction module is used to:

[0030] Multiple surface characteristic factors are identified, which may include at least the material, oxide layer, surface roughness, and metallic color. Highly reflective metals (such as stainless steel and aluminum alloys) have smooth surfaces and high reflectivity, easily forming specular reflections, leading to image overexposure or localized reflection interference. Low-angle ring lighting or diffused lighting (such as dome lighting) should be used to reduce direct reflection, or polarizers should be used to filter reflections. Low-reflective metals (such as cast iron and copper alloys) have rough surfaces and low reflectivity, which may result in low contrast between scratches and the background due to insufficient lighting. High-brightness light sources (such as high-power LEDs) or backlights are needed to enhance overall brightness, or coaxial lighting should be used to highlight surface details. Oxide metals (such as aluminum oxide and copper oxide) form an oxide film on their surface, which may alter light absorption characteristics (e.g., aluminum oxide is white, reflecting light more readily). For samples with low roughness (such as polished or mirror-finished parts), the surface is uneven, and scratches may be obscured by texture or have blurred edges due to excessive shadows. High-angle light sources (such as ring lights) are needed to highlight surface undulations, or structured light (such as laser stripe projection) can be used to detect scratches through deformation analysis. For samples with low roughness (such as polished or mirror-finished parts), the surface is smooth, and scratches are easier to detect but are easily affected by light interference (such as reflections and glare). Low-angle light sources (such as dark-field illumination) are needed to enhance the contrast between scratches and the background, or polarized light can be used to eliminate reflections. Monochromatic light sources (such as blue or green LEDs) can be used to highlight scratches by utilizing the absorption differences of metals at specific wavelengths. Avoid using light sources that are similar to the natural color of the metal (such as yellow light illuminating a gold surface) to prevent low contrast.

[0031] Based on multiple surface feature factors, the initial surface characteristics of each sample metal part are determined. The initial surface characteristics include the factor value corresponding to each surface feature factor. For numerical surface feature factors, the value of the sample metal part corresponding to the surface feature factor can be measured and used as the factor value of the surface feature factor. For non-numerical surface feature factors, the factor value of the surface feature factor can be determined by numerical encoding.

[0032] Based on multiple sample images, the optimal light source parameters for each sample metal processing part are determined;

[0033] Based on the optimal light source parameters corresponding to each sample metal processing part and the initial surface characteristics of each sample metal processing part, several key surface feature factors are determined.

[0034] A knowledge graph of light source parameters is established based on the initial surface characteristics of each sample metal processing part, multiple key surface feature factors, and the optimal light source parameters corresponding to each sample metal processing part.

[0035] In some embodiments, the map building module is used for:

[0036] establish and train a scratch recognition model;

[0037] construct a light source evaluation index set;

[0038] For each sample metal processing part, based on the scratch recognition model, multiple sample images and the light source evaluation index set, determine the corresponding optimal light source parameters of the sample metal processing part.

[0039] Specifically, the scratch recognition model can use a lightweight convolutional neural network (CNN) or an improved target detection architecture (such as YOLO (You Only Look Once)) to balance accuracy and real-time performance. Its core structure includes an input layer (receiving 256x256 or 640x640 resolution RGB images), multiple convolutional modules (such as 3x3 convolution + ReLU (Rectified Linear Unit) activation function, gradually extracting local features such as edges and textures of scratches, and reducing dimensions through pooling layers), feature fusion layers (such as FPN (Feature Pyramid Network) or PANet (Path Aggregation Network), fusing shallow details and deep semantic information to enhance the perception of small scratches), and output layers (classification task uses Sigmoid activation to output scratch probability, positioning task uses anchor box mechanism to output bounding box coordinates and confidence). The scratch recognition model is based on supervised learning, and learns the mapping relationship of "image features → scratch attributes" through a large amount of labeled data (containing scratch position and type label): when the convolution kernel slides across the image, the scratch area will activate specific channels due to features such as contrast mutation and edge continuity. The model optimizes the weights through backpropagation, aligning the high activation area with the true scratch position. In the training phase, data augmentation (such as rotation, scaling, and adding noise) is used to expand the sample diversity and prevent overfitting; the loss function combines Focal Loss (to address the imbalance between positive and negative samples) and CIoU Loss (Complete IoU Loss) (to optimize the regression accuracy of the bounding box), and iteratively updates the parameters through gradient descent until the detection rate (such as >98%) and false detection rate (such as <2%) on the validation set meet the requirements.

[0040] The light source evaluation index set is a set of parameters for quantifying the influence of light source characteristics on the scratch detection effect. By evaluating the accuracy, efficiency and robustness of scratch recognition under different light source parameters, the optimal combination is selected. The light source evaluation index set can include scratch contrast (the ratio of the average gray difference between the scratch area and the background area to the standard deviation of the background gray), image signal-to-noise ratio (the ratio of the scratch signal power to the background noise power), edge sharpness (the maximum gray gradient of the scratch edge), texture complexity (the texture similarity between the scratch area and the background area), model confidence average (the average value of the confidence of the scratch recognition model for the detected scratch), inference time (the time (millisecond level) for the scratch recognition model to process a single image), etc.

[0041] For each sample metal processing part, multiple sample images of the sample metal processing part are collected under different combinations of light source parameters, ensuring that the possible variation range of the light source parameters is covered. Then, each sample image is input into the scratch recognition model to obtain the scratch detection result (such as scratch position, confidence, etc.), and the light source evaluation index set (such as scratch contrast, image signal-to-noise ratio, edge sharpness, model confidence average, and inference time, etc.) is calculated synchronously. By analyzing the numerical changes of each index under different light source parameters, the light source parameter combination that makes the scratch contrast higher (such as > 3), the image signal-to-noise ratio up to standard (such as > 20 dB), the edge sharpness clear (such as > 50), the model confidence average high (such as > 0.9), and the inference time meeting the real-time requirement (such as < 50 ms) is selected. Finally, by comprehensively considering the performances of each index, the best light source parameters that make the scratch recognition accuracy and efficiency optimal are determined by using weighted scoring.

[0042] It can be understood that by establishing and training a high-precision and real-time scratch recognition model, and combining a multi-dimensional light source evaluation index set, the best light source parameters are accurately selected for each sample metal processing part. The scratch recognition model uses a lightweight CNN or an improved YOLO architecture, fuses multi-level convolution and feature enhancement technology, effectively extracts the edge, texture and other features of the scratch, and improves the generalization ability through data enhancement and optimization of the loss function, to achieve a detection effect with high detection rate and low false detection rate. The light source evaluation index set covers key parameters such as scratch contrast, image signal-to-noise ratio, and edge sharpness, and comprehensively quantifies the influence of the light source on the detection quality. For each sample, the module collects images under different light source parameters, inputs the model to obtain the detection result and synchronously calculates the evaluation index, selects the light source combination that meets the requirements of high contrast, high signal-to-noise ratio, clear edge, high confidence, and low inference time by analyzing the numerical changes of the index, and finally determines the best parameters by using weighted scoring. This scheme significantly improves the accuracy and efficiency of scratch detection, and reduces the subjectivity and trial-and-error cost of light source parameter selection.

[0043] In some embodiments, the atlas construction module is configured to:

[0044] For any two sample metal processing parts, calculate the light source difference value of the optimal light source parameters corresponding to the two sample metal processing parts;

[0045] For each surface feature factor, based on the factor values corresponding to the surface feature factors of any two sample metal processing parts, calculate the factor difference value of any two sample metal processing parts, and based on the factor difference value and the light source difference value of any two sample metal processing parts, calculate the light source influence coefficient of the surface feature factor.

[0046] Based on the light source influence coefficient of each surface feature factor, determine a plurality of key surface features.

[0047] Specifically, for each sample metal processing part, encode the optimal light source parameters corresponding to the sample metal processing part into a numerical vector. For any two sample metal processing parts, calculate the Euclidean distance of the numerical vectors of the optimal light source parameters corresponding to the two sample metal processing parts as the light source difference value of the optimal light source parameters corresponding to the two sample metal processing parts.

[0048] Generate a light source difference value sequence, wherein the value of an element of the light source difference value sequence is the light source difference value of the optimal light source parameters corresponding to two sample metal processing parts, and the number of elements included in the light source difference value sequence is n(n-1) / 2, where n is the total number of sample metal processing parts.

[0049] Generate a factor difference value sequence, wherein the value of an element of the factor difference value sequence is the factor difference value of two sample metal processing parts, and the number of elements included in the factor difference value sequence is n(n-1) / 2, where n is the total number of sample metal processing parts, and the two sample metal processing parts corresponding to the elements at the same position in the light source difference value sequence and the factor difference value sequence are consistent.

[0050] The factor difference value and the light source difference value of any two sample metal processing parts are taken as two variables, the light source difference value sequence and the factor difference value sequence are substituted into the correlation coefficient (e.g., Pearson correlation coefficient, Spearman rank correlation coefficient, etc.) calculation formula, to obtain the correlation coefficient of the factor difference value and the light source difference value, take the absolute value to obtain the light source influence coefficient of the surface feature factor, and the surface feature factor with a light source influence coefficient greater than a light source influence coefficient threshold (e.g., 0.5) is taken as a key surface feature.

[0051] It can be understood that the correlation between the light source parameters and the surface characteristic factors is quantitatively analyzed to accurately identify the key surface characteristics. First, the optimal light source parameters of the sample parts are encoded into a numerical vector, the Euclidean distance between each two samples is calculated as the light source difference value, and the factor difference value sequence of the corresponding position is generated synchronously; then, the absolute value correlation between the light source difference and the factor difference is calculated by using the Pearson or Spearman correlation coefficient to obtain the light source influence coefficient; finally, the surface characteristic factors with an influence coefficient exceeding a threshold value (such as 0.5) are selected as the key characteristics. This method objectively quantifies the influence degree of the light source on the surface characteristic detection in a data-driven manner, avoiding the deviation of subjective experience judgment; at the same time, through the full combination analysis of each two samples, the data information is fully utilized to improve the stability and reliability of the key characteristic identification.

[0052] In some embodiments, the atlas construction module is configured to:

[0053] For any two sample metal machining parts, based on the initial surface characteristics and the plurality of key surface characteristic factors of each sample metal machining part, a key characteristic similarity of the two sample metal machining parts is calculated;

[0054] Based on the key characteristic similarity of any two sample metal machining parts, the plurality of sample metal machining parts are classified to determine a plurality of part classes;

[0055] For each part class, a light source difference value of the optimal light source parameters corresponding to any two sample metal machining parts included in the part class is calculated, and the sample metal machining parts included in the part class are grouped to determine a part group included in each part class.

[0056] Based on the plurality of part classes, the part group included in each part class, and the optimal light source parameters corresponding to each sample metal machining part, a light source parameter knowledge atlas is established.

[0057] Specifically, for each sample metal machining part, based on the initial surface characteristics and the plurality of key surface characteristic factors of the sample metal machining part, the key surface characteristics of the sample metal machining part are determined, wherein the key surface characteristics include the factor values of each key surface characteristic factor corresponding to the sample metal machining part.

[0058] For any two sample metal machining parts, based on the cosine similarity algorithm, the cosine similarity of the key surface characteristics of the two sample metal machining parts is calculated as the key characteristic similarity of the two sample metal machining parts.

[0059] According to the similarity of the key characteristics between any two samples, a clustering algorithm (such as K-means or hierarchical clustering) is used to automatically classify all samples. By setting a similarity threshold or dynamically determining the number of clusters, samples with high similarity are classified into the same part class, ensuring that parts of the same class have high consistency in surface characteristics.

[0060] For each part class, the mean value of the key surface characteristics of the sample metalworking parts included in the part class is calculated as the average key surface characteristics corresponding to the part class.

[0061] Using a clustering algorithm (such as K-means or hierarchical clustering), the sample metalworking parts included in the part class are grouped based on the light source difference value of the best light source parameters corresponding to any two sample metalworking parts included in the part class, to determine the part group included in each part class, so that sample metalworking parts in the same group have high similarity in the best light source parameters.

[0062] For each part group, the mean value of the key surface characteristics of the sample metalworking parts included in the part group is calculated as the average key surface characteristics corresponding to the part group.

[0063] Figure 3 is a schematic diagram of a light source parameter knowledge graph according to some embodiments of the present specification, as shown in Figure 3 As shown, the light source parameter knowledge graph can include four types of nodes, one type of node representing a part class, one type of node representing a part group, one type of node representing a sample metalworking part, and one type of node representing a best light source parameter.

[0064] The characteristic acquisition module is configured to acquire the key surface characteristics of the current metalworking part.

[0065] Specifically, the key surface characteristics of the current metalworking part can include the factor value of each key surface characteristic factor corresponding to the current metalworking part.

[0066] The parameter determination module is configured to determine the current light source parameter based on the key surface characteristics of the current metalworking part and the light source parameter knowledge graph.

[0067] In some embodiments, the parameter determination module is configured to:

[0068] determine the part class corresponding to the current metalworking part based on the key surface characteristics of the current metalworking part and the light source parameter knowledge graph;

[0069] determine the part group corresponding to the current metalworking part from the part groups included in the part class corresponding to the current metalworking part based on the key surface characteristics of the current metalworking part and the light source parameter knowledge graph;

[0070] determine a similar sample metal processing part from a part group corresponding to the current metal processing part based on a current metal processing part key surface characteristic and a light source parameter knowledge graph;

[0071] determine the current light source parameter based on a similar sample metal processing part corresponding optimal light source parameter.

[0072] Specifically, by calculating the similarity (such as cosine similarity or Euclidean distance) of the key surface characteristics of the current metal processing part and the average key surface characteristics corresponding to each part class, the part class with the highest similarity is selected as the part class corresponding to the current metal processing part.

[0073] After determining the part class, further focus on all part groups under the part class. By calculating the similarity (such as cosine similarity or Euclidean distance) of the key surface characteristics of the current metal processing part and the average key surface characteristics corresponding to each part group included in the part class corresponding to the current metal processing part, the part group with the highest similarity is selected as the part group corresponding to the current metal processing part.

[0074] By calculating the similarity (such as cosine similarity or Euclidean distance) of the key surface characteristics of the current metal processing part and the key surface characteristics corresponding to each sample metal processing part included in the part group corresponding to the current metal processing part, the sample metal processing part with a similarity greater than a similarity threshold (for example, 70%) is selected as a similar sample metal processing part.

[0075] From the light source parameter knowledge graph, find the optimal light source parameter node associated with the similar sample metal processing part, and extract the optimal light source parameter. If there are multiple similar sample metal processing parts, the optimal parameters (such as taking the average value or weighted voting) of them can be integrated as the light source parameter recommendation of the current part. For example, if three similar samples all use "high-angle ring light + 5000 lux illumination", directly recommend this parameter combination to ensure that the detection effect of the current part is consistent with the historical optimal case, thereby improving the detection accuracy and efficiency.

[0076] An image acquisition module is configured to acquire an image of the current metal processing part based on the current light source parameter.

[0077] The atlas construction module is further configured to construct a region scratch correlation knowledge graph corresponding to the current metal processing part.

[0078] The region scratch correlation knowledge graph is used to record the correlation of the scratches of the multiple regions of the current metal processing part.

[0079] In some embodiments, the atlas construction module is configured to:

[0080] obtain images of a plurality of historical metal processing parts corresponding to the current metal processing part, wherein the images of the historical metal processing parts are obtained based on the current light source parameter, the historical metal processing parts corresponding to the current metal processing part are consistent with the current metal processing part in factor values of a plurality of surface characteristic factors and are consistent with the current metal processing part in processing procedures and structures;

[0081] construct a region scratch correlation knowledge graph corresponding to the current metal processing part based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part.

[0082] In some embodiments, the graph construction module is configured to:

[0083] calculate a scratch similarity between any two image units based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part;

[0084] determine a plurality of image regions based on the scratch similarity between any two image units.

[0085] calculate a region scratch correlation coefficient between any two image regions based on the images of the plurality of historical metal processing parts corresponding to the current metal processing part.

[0086] construct a region scratch correlation knowledge graph corresponding to the current metal processing part based on the region scratch correlation coefficient between any two image regions.

[0087] Specifically, the image can be equally divided into a plurality of image units.

[0088] For each image unit and each historical metal processing part, the scratch features (for example, length and width, direction angle, density, direction consistency, etc.) of the image unit in the image of the historical metal processing part are extracted, the scratch boundary is identified by an edge detection algorithm (such as Canny operator), the longest axis length and the average width are calculated as the length and width, a straight line is fitted based on the scratch center line, the included angle with the image coordinate axis is calculated to quantify the direction angle (such as horizontal, vertical or oblique) of the scratch, the number of scratches in a unit area is counted to calculate the density, and the variance of the direction angles of all scratches in the image unit is calculated to obtain the direction consistency.

[0089] For any two image units, the cosine similarity of the scratch features of the images of each historical metal processing part corresponding to the two image units is calculated, the average value is obtained, and the scratch similarity of the image units is obtained.

[0090] The clustering algorithm (such as K-means or hierarchical clustering) is used to divide the plurality of image units into a plurality of image regions based on the scratch similarity between any two image units.

[0091] For any two image regions and each scratch characteristic factor (for example, length and width, strike angle, density, direction consistency, etc.), the feature values of the scratch characteristic factors of the two image regions corresponding to the image of each historical metal processing part are substituted into the correlation coefficient (for example, Pearson correlation coefficient, Spearman rank correlation coefficient, etc.) calculation formula to obtain the correlation coefficient of the two image regions corresponding to each scratch characteristic factor. The correlation coefficients of the two image regions corresponding to each scratch characteristic factor are averaged to obtain the regional scratch correlation coefficient of the two image regions.

[0092] Figure 4 is a schematic diagram of a regional scratch correlation knowledge graph according to some embodiments of the present specification, as shown in Figure 4 The nodes in the regional scratch correlation knowledge graph represent image regions, and the weight of the edge between two nodes can be the regional scratch correlation coefficient of the two image regions.

[0093] It can be understood that dividing the image into units and calculating the scratch similarity can accurately capture the micro features such as the morphology and strike of local scratches, and avoid feature confusion caused by excessively large region division. Secondly, the image units are aggregated based on the similarity to form regions. Further calculating the scratch correlation coefficient between regions can quantify the statistical dependence relationship of different regional scratches (such as whether the increase of the scratch density of a region will cause the scratch of the adjacent region to become deeper), which provides data support for revealing the scratch propagation rule. Finally, the constructed knowledge graph stores the regional correlation information in a structured form, which can directly display the spatial distribution pattern and potential causal relationship of the scratches.

[0094] The scratch recognition module is configured to perform scratch recognition of the current metal processing part based on the regional scratch correlation knowledge graph corresponding to the current metal processing part and the image of the current metal processing part.

[0095] In some embodiments, the scratch recognition module is configured to:

[0096] Based on the image of the current metal processing part, determine the initial scratch recognition result of the plurality of image regions. Specifically, the initial scratch recognition result of the image region can include the feature value of each scratch characteristic factor, and the initial scratch recognition result of the plurality of image regions can be determined by the scratch recognition model.

[0097] Based on the initial scratch recognition result of the plurality of image regions and the regional scratch correlation knowledge graph corresponding to the current metal processing part, perform scratch recognition of the current metal processing part.

[0098] In some embodiments, the scratch recognition module is configured to:

[0099] Determine the associated scratch features of the multiple image regions based on the initial scratch recognition results of the multiple image regions and the region scratch correlation knowledge graph corresponding to the current metal processing part;

[0100] Perform scratch recognition of the current metal processing part based on the initial scratch recognition results of the multiple image regions, the associated scratch features, and the image of the current metal processing part.

[0101] Specifically, the associated scratch features of the image region refer to the potential dependency relationship of the cross-region scratch morphology or distribution mined by analyzing the statistical correlation of the scratches between regions. For example, if historical data shows that the scratch density of image region A has a strong positive correlation with the scratch direction of image region B (e.g., when A density increases, B often appears horizontal scratches), then the "horizontal scratch tendency" of image region B is an associated feature affected by image region A. To determine these features, the scratch recognition module uses a graph neural network model: first, the region scratch correlation knowledge graph is constructed as a graph structure, where the nodes represent image regions and the edge weights are the correlation coefficients between the scratches of the regions; then, the initial scratch recognition results of each region are input as the initial attributes of the nodes to train the graph neural network model; the graph neural network model aggregates the feature information of adjacent nodes and learns their associated patterns through multiple layers of message passing mechanism, and finally outputs the associated scratch feature vector of each region. For example, if image region C and image region D have a negative correlation in the knowledge graph (image region C scratch becomes deeper, image region D scratch becomes shallower), the graph neural network model will generate the "shallow scratch tendency" of image region D as an associated feature. Through graph structure data mining, the features of isolated regions are expanded into cross-region dependency relationships, providing global constraints for subsequent recognition.

[0102] A multi-modal fusion Transformer model is used to complete the final recognition. First, the convolutional neural network branch extracts local features from the current image to generate high-resolution scratch candidate regions; at the same time, the Transformer branch concatenates the initial recognition results (such as "high-density scratch" of image region A) and the associated features (such as "horizontal scratch tendency" of image region B) as sequence input, and learns the dependency relationship between global features (such as the high density of image region A may strengthen the horizontal features of image region B) through self-attention mechanism; then, the local features of the convolutional neural network branch and the global features of the Transformer are aligned across modalities to generate a fusion feature map; finally, the decoder outputs the accurate segmentation mask and type classification of the scratch based on the fusion features. For example, if the associated feature suggests that image region C may have shallow scratches, the model will preferentially search for low-contrast, short-length scratch candidates in the image and suppress false positives of deep scratches. This step significantly improves the robustness of complex surface scratch recognition by combining local visual details and cross-region association knowledge.

[0103] It can be understood that by fusing the dual mechanisms of data driving and knowledge guiding, the precision and robustness of the scratch detection of metal processing parts are significantly improved. First, the scratch recognition model is used to perform initial feature extraction on the image region, which can accurately quantify the numerical representation of each scratch characteristic factor, providing a fine-grained data basis for subsequent analysis. Second, the region scratch correlation knowledge graph is introduced, which mines the statistical correlation rules of different region scratches in historical data (such as whether the increase of the scratch density in a certain region will cause the scratch in a specific direction in the adjacent region), and performs cross-region verification and correction on the initial recognition result, effectively overcoming the problem that single-region independent detection is easily affected by noise interference or local occlusion. Finally, the scratch recognition result generated by combining the initial features and the correlation knowledge not only retains the accuracy of local details, but also reflects the rationality of global correlation, improving the accuracy of scratch recognition.

[0104] Finally, it should be understood that the embodiments described herein are merely intended to illustrate the principles of the embodiments described herein. Other variations can also be within the scope of the present disclosure. Therefore, as an example but not limitation, alternative configurations of the embodiments described herein can be considered consistent with the teachings of the present disclosure. Accordingly, the embodiments of the present disclosure are not limited to the embodiments explicitly introduced and described in the present disclosure.

Claims

1. A big data based image recognition system, characterized in that, Comprise: The atlas construction module is used for acquiring multiple sample images, and establishing a light source parameter knowledge graph, wherein the light source parameter knowledge graph is used to record the key surface characteristics of different types of metal processing parts and the corresponding optimal light source parameters; The characteristic acquisition module is used for acquiring the key surface characteristics of the current metal processing part; The parameter determination module is used for determining the current light source parameter based on the key surface characteristics of the current metal processing part and the light source parameter knowledge graph; The image acquisition module is used for acquiring the image of the current metal processing part based on the current light source parameter; The atlas construction module is also used to construct a regional scratch correlation knowledge graph corresponding to the current metal processing part, wherein the regional scratch correlation knowledge graph is used to record the correlation of scratches of multiple regions of the current metal processing part; The scratch identification module is used to perform scratch identification of the current metal processing part based on the regional scratch correlation knowledge graph corresponding to the current metal processing part and the image of the current metal processing part; Wherein, the multiple sample images include images of multiple sample metal processing parts acquired under different light source parameters; The atlas construction module is used for: Determine multiple surface characteristic factors; According to the multiple surface characteristic factors, determine the initial surface characteristics of each sample metal processing part, wherein the initial surface characteristics include the factor value corresponding to each surface characteristic factor; Based on the multiple sample images, determine the optimal light source parameter corresponding to each sample metal processing part; For each sample metal processing part, encode the optimal light source parameter corresponding to the sample metal processing part into a numerical vector; For any two sample metal processing parts, calculate the Euclidean distance of the numerical vectors of the optimal light source parameters corresponding to the two sample metal processing parts as the light source difference value of the optimal light source parameters corresponding to the two sample metal processing parts; Generate a light source difference value sequence, wherein the value of an element of the light source difference value sequence is the light source difference value of the optimal light source parameters corresponding to two sample metal processing parts, and the number of elements included in the light source difference value sequence is n (n-1) / 2, wherein n is the total number of sample metal processing parts; Generate a factor difference value sequence, wherein the value of an element of the factor difference value sequence is the factor difference value of two sample metal processing parts, and the number of elements included in the factor difference value sequence is n (n-1) / 2, wherein n is the total number of sample metal processing parts, and the two sample metal processing parts corresponding to the elements at the same position in the light source difference value sequence and the factor difference value sequence are consistent; The factor difference value and the light source difference value of any two sample metal processing parts are used as two variables, the light source difference value sequence and the factor difference value sequence are substituted into the correlation coefficient calculation formula, the correlation coefficient of the factor difference value and the light source difference value is obtained, the absolute value is taken, the light source influence coefficient of the surface characteristic factor is obtained, and the surface characteristic factor with a light source influence coefficient greater than a light source influence coefficient threshold is taken as a key surface characteristic factor.

2. The image recognition system based on big data according to claim 1, wherein The atlas construction module is used for: The light source parameter knowledge graph is established based on the initial surface characteristics of each sample metal machining part, the plurality of key surface feature factors, and the optimal light source parameters corresponding to each sample metal machining part.

3. The big data based image recognition system of claim 2, wherein, The atlas construction module is configured to: establish and train a scratch identification model; construct a light source evaluation index set; for each sample metal machining part, determine the optimal light source parameter corresponding to the sample metal machining part based on the scratch identification model, the plurality of sample images, and the light source evaluation index set.

4. The big data based image recognition system of claim 2, wherein, The atlas construction module is configured to: for any two sample metal machining parts, calculate the key characteristic similarity of the two sample metal machining parts based on the initial surface characteristics of each sample metal machining part and the plurality of key surface feature factors; based on the key characteristic similarity of any two sample metal machining parts, classify the plurality of sample metal machining parts to determine a plurality of part classes; for each part class, calculate a light source difference value of the optimal light source parameters corresponding to any two sample metal machining parts included in the part class, group the sample metal machining parts included in the part class to determine a part group included in each part class; based on the plurality of part classes, the part group included in each part class, and the optimal light source parameters corresponding to each sample metal machining part, establish a light source parameter knowledge graph.

5. The big data based image recognition system of claim 4, wherein, The parameter determination module is configured to: based on the key surface characteristics of the current metal machining part and the light source parameter knowledge graph, determine the part class corresponding to the current metal machining part; based on the key surface characteristics of the current metal machining part and the light source parameter knowledge graph, determine the part group corresponding to the current metal machining part from the part group included in the part class corresponding to the current metal machining part; based on the key surface characteristics of the current metal machining part and the light source parameter knowledge graph, determine a similar sample metal machining part from the part group corresponding to the current metal machining part; based on the optimal light source parameter corresponding to the similar sample metal machining part, determine the current light source parameter.

6. The big data based image recognition system of any one of claims 1-5, wherein, The atlas construction module is configured to: obtain images of a plurality of historical metal machining parts corresponding to the current metal machining part, wherein the images of the historical metal machining parts are obtained based on the current light source parameter; based on the images of the plurality of historical metal machining parts corresponding to the current metal machining part, construct a region scratch correlation knowledge graph corresponding to the current metal machining part.

7. The big data based image recognition system of claim 6, wherein, The atlas construction module is configured to: based on the images of the plurality of historical metal machining parts corresponding to the current metal machining part, calculate the scratch similarity of any two image units; based on the scratch similarity of any two image units, determine a plurality of image regions; based on the images of the plurality of historical metal machining parts corresponding to the current metal machining part, calculate the region scratch correlation coefficient of any two image regions; based on the region scratch correlation coefficient of any two image regions, construct a region scratch correlation knowledge graph corresponding to the current metal machining part.

8. The big data based image recognition system of claim 7, wherein, The scratch identification module is configured to: based on the image of the current metal machining part, determine initial scratch identification results of a plurality of image regions; The scratch recognition of the current metal processing part is performed based on the initial scratch recognition result of the multiple image regions and the region scratch correlation knowledge graph corresponding to the current metal processing part.

9. The big data based image recognition system of claim 8, wherein, The scratch recognition module is used for: The associated scratch features of the multiple image regions are determined based on the initial scratch recognition result of the multiple image regions and the region scratch correlation knowledge graph corresponding to the current metal processing part. The scratch recognition of the current metal processing part is performed based on the initial scratch recognition result of the multiple image regions, the associated scratch features and the image of the current metal processing part.

Citation Information

Patent Citations

  • Intelligent detection method for apparent quality of synthetic leather

    CN117269193A