A method for detecting surface defects of titanium anodes
By combining a variety of image detection technologies and parameter adjustments, the problem of insufficient detection of surface defects of titanium anode is solved, achieving higher detection accuracy and comprehensiveness.
Patent Information
- Application Number
- CN202510578410.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-07
- Publication Date
- 2025-07-18
- Estimated Expiration
- 2045-05-07
AI Technical Summary
Traditional detection methods are difficult to comprehensively and accurately detect defects on the surface of titanium anode, especially due to insufficient detection due to its reflective characteristics.
Combined with a variety of image detection technologies, by obtaining the surface defect conditions and identification scores of titanium anode samples at different preset shooting angles, curve fitting and optimization are performed, and imaging technical parameters are adjusted to improve detection comprehensiveness and accuracy.
It improves the accuracy and comprehensiveness of surface defect detection of titanium anode and provides a more reliable quality analysis basis.
Smart Images

Figure CN120125574B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image detection, and particularly to a method for detecting surface defects of titanium anodes. Background Art
[0002] A titanium anode is an electrode with a titanium substrate coated with noble metal oxides such as ruthenium and iridium. Due to its corrosion resistance, good electrical conductivity, long service life and other characteristics, its applications cover multiple key fields such as chemical industry, environmental protection, and energy. Therefore, ensuring the quality and performance of titanium anodes, especially the timely detection of metal surface defects, is the key to improving the overall equipment efficiency and extending the service life. However, due to the reflective characteristics of titanium anodes, it is difficult to detect all the defects on the surface of titanium anodes. Traditional detection methods often focus on single detection means, resulting in insufficient detection of surface defects of titanium anodes and affecting the comprehensiveness and accuracy of detection results. Summary of the Invention
[0003] In view of the above technical problems, the present invention provides a method for detecting surface defects of titanium anodes, which can combine multiple image detection technologies to improve the comprehensiveness and accuracy of detecting surface defects of titanium anodes.
[0004] According to a first aspect of the present invention, there is provided a method for detecting surface defects of titanium anodes, including the following steps:
[0005] For any titanium anode sample, obtain the surface defect conditions of the titanium anode sample at a plurality of preset shooting angles under a first given imaging technology, and based on the true defect conditions of the titanium anode sample, obtain the first defect recognition score corresponding to the titanium anode sample at each preset shooting angle.
[0006] According to a plurality of preset shooting angles and the first defect recognition scores corresponding to the titanium anode sample at each preset shooting angle, perform curve fitting to obtain an initial angle-score curve graph corresponding to the titanium anode sample; wherein, the initial angle-score curve graph is a normal distribution curve.
[0007] According to the initial angle-score curve graph corresponding to each titanium anode sample, perform fitting optimization processing to obtain a target angle-score curve graph.
[0008] When receiving a captured image of a given titanium anode, obtain the first defect detection result corresponding to the given titanium anode, and based on the target shooting angle corresponding to the given titanium anode, obtain the second defect recognition score corresponding to the given titanium anode from the target angle-score curve graph.
[0009] Obtain the defect types that are not accurately identified corresponding to the second defect recognition score from the captured images of several titanium anode samples, and adjust the parameters of the second given imaging technique according to the defect types that are not accurately identified, so as to obtain the second defect detection result corresponding to the given titanium anode under the second given imaging technique.
[0010] According to the first defect detection result and the second defect detection result, obtain the final surface defect detection result corresponding to the given titanium anode.
[0011] The present invention has at least the following beneficial effects:
[0012] The present invention provides a method for detecting surface defects of titanium anodes. First, obtain the surface defect conditions and corresponding first defect recognition scores of titanium anode samples under a first given imaging technique at several preset shooting angles, which can obtain the recognition degree and recognition ability of the first given imaging technique for different defect types at different shooting angles, and is helpful for providing an analysis basis for the detection accuracy of defect types; then fit the first defect recognition scores corresponding to each preset shooting angle of the titanium anode samples to obtain an initial angle-score curve graph, and then optimize the initial angle-score curve graphs corresponding to several titanium anode samples into a target angle-score curve graph, which can reasonably reflect the reliable corresponding relationship between the shooting angle and the score. When receiving the captured image of a given titanium anode, obtain the second defect recognition score and the corresponding defect types that are not accurately identified corresponding to the given titanium anode, and adjust the parameters of the second given imaging technique to obtain the second defect detection result corresponding to the given titanium anode under the second given imaging technique. Integrate the first defect detection result and the second defect detection result into the final surface defect detection result corresponding to the given titanium anode. Through the reasonable combination of multiple imaging techniques, the accuracy and comprehensiveness of the detection of surface defects of titanium anodes can be effectively improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0014] Figure 1 It is a flowchart of the method for detecting surface defects of titanium anodes provided by the embodiment of the present invention. DETAILED DESCRIPTION OF THE INVENTION
[0015] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative efforts belong to the scope of protection of the present invention.
[0016] An embodiment of the present invention provides a method for detecting surface defects of a titanium anode. As Figure 1 shown, the method includes the following steps:
[0017] S100, for any titanium anode sample, obtain the surface defect conditions of the titanium anode sample at several preset shooting angles under a first given imaging technology, and based on the actual defect conditions of the titanium anode sample, obtain the first defect recognition score corresponding to each preset shooting angle of the titanium anode sample; it can be understood that: the surface defect conditions include defect types such as scratches, pits, protrusions, cracks, oxidation, etc. that can be recognized in the captured images.
[0018] In a specific embodiment, the first given imaging technology is an optical imaging technology or an infrared thermal imaging technology.
[0019] Furthermore, both the upper limit value and the lower limit value corresponding to the range of the preset shooting angles are between 0-180°, and 90° < Δθ < 180°, where Δθ is the difference between the upper limit value and the lower limit value corresponding to the range of the preset shooting angles, so as to enable multi-angle coverage shooting of the titanium anode and improve the defect recognition accuracy and comprehensiveness in cases such as titanium anode reflection.
[0020] In a specific embodiment, the first defect recognition score corresponding to any preset shooting angle of the titanium anode sample is obtained through the following steps:
[0021] S101, for any preset defect type, obtain the similarity between the surface defect conditions and the actual defect conditions of the titanium anode sample at any preset shooting angle, and use the similarity as the initial defect recognition score corresponding to any preset defect type.
[0022] In an embodiment, taking the scratch in the surface defect conditions as an example, step S101 includes the following steps:
[0023] S1011, obtain the shooting length of the target scratch in the surface defect conditions and the actual length of the target scratch in the actual defect conditions; it can be understood that: the shooting length of the target scratch refers to the scratch length corresponding to mapping the captured image to the physical object. For example, the actual length of the target scratch is 1 cm, but since both ends of the scratch are relatively shallow and cannot be fully displayed in the captured image, the shooting length is based on the actual length corresponding to the actual display length of the captured image.
[0024] S1012. Calculate the similarity between the surface defect situation and the actual defect situation of the titanium anode sample under any preset defect type according to the captured length and the actual length of the target scratch.
[0025] Specifically, the similarity F between the surface defect situation and the actual defect situation of the titanium anode sample under any preset defect type meets the following conditions:
[0026] F = 1 - abs(1 - H1 / H2), where H1 is the captured length of the target scratch, H2 is the actual length of the target scratch, and abs() is the absolute value function.
[0027] Furthermore, when the defect type is a pit or a bulge, the area size can be used as the scoring measurement standard. When the defect type is a crack, the length can be used as the scoring measurement standard. When the defect type is oxidation, the pixel value can be used as the scoring measurement standard. This will not be elaborated again.
[0028] S102. Take the average of the several initial defect recognition scores corresponding to several preset defect types as the first defect recognition score of the titanium anode sample under any preset shooting angle. In actual operation, to ensure the unity of the data magnitude, the initial defect recognition scores corresponding to different preset defect types are normalized to the same data range.
[0029] As described above, by obtaining the first defect recognition score corresponding to the titanium anode sample under each preset shooting angle, the recognition degree and recognition ability of the first given imaging technology for different defect types at different shooting angles can be obtained, which helps to provide an analysis basis for the detection accuracy of defect types.
[0030] S200. According to several preset shooting angles and the first defect recognition score corresponding to the titanium anode sample under each preset shooting angle, perform curve fitting to obtain the initial angle-score curve graph of the titanium anode sample.
[0031] Furthermore, the initial angle-score curve graph is a normal distribution curve. For example, draw a curve according to the relationship between the preset shooting angle and the first defect recognition score. When the angle is greater than 90° and less than 90°, it has a symmetric effect and can be fitted into a normal distribution curve.
[0032] S300. According to the initial angle-score curve graph corresponding to each titanium anode sample, perform fitting optimization to obtain the target angle-score curve graph.
[0033] Specifically, step S300 includes the following steps:
[0034] S301. Obtain the value ranges of the angle mean and the angle standard deviation respectively according to the initial angle-score curve graphs corresponding to several titanium anode samples, and construct a target grid based on the value ranges of the angle mean and the angle standard deviation. It can be understood that the angle mean is divided into a first preset number of equal parts, and the angle standard deviation is divided into a second preset number of equal parts to construct the target grid.
[0035] S302. Generate an intermediate angle-score curve graph for the angle mean and the angle standard deviation corresponding to any grid point in the target grid, and calculate the loss value corresponding to the grid point itself based on the intermediate angle-score curve graph. Among them, the loss value L corresponding to the grid point itself meets the following conditions:
[0036] , where f i (ε) is the probability density function of the i-th initial angle-score curve graph, f new (ε) is the probability density function of the intermediate angle-score curve graph corresponding to the grid point itself, m is the number of titanium anode samples, and ε represents the value of the random variable.
[0037] S303. Take the angle mean and the angle standard deviation corresponding to the grid point with the minimum loss value as the optimal solution, and obtain the target angle-score curve graph according to the optimal solution.
[0038] As described above, by constructing the target grid, the angle mean and the angle standard deviation in the curve graph can be subdivided to improve the optimization accuracy. Calculate the loss value of each subdivided grid point respectively, and the reliability of the curve corresponding to each grid point can be known, and the optimal curve graph can be selected to make the optimized curve have a more reliable integration effect.
[0039] S400. When receiving the captured image of a given titanium anode, obtain the first defect detection result corresponding to the given titanium anode, and obtain the second defect recognition score corresponding to the given titanium anode from the target angle-score curve graph based on the target shooting angle corresponding to the given titanium anode. It can be understood that the information of the captured image of the given titanium anode received includes the target shooting angle information.
[0040] S500. Obtain the defect types that are not accurately recognized corresponding to the second defect recognition score from the captured images of several titanium anode samples, and adjust the parameters of the second given imaging technology according to the defect types that are not accurately recognized to obtain the second defect detection result corresponding to the given titanium anode under the second given imaging technology.
[0041] In a specific embodiment, the second given imaging technology is a laser scanning imaging technology or an X-ray imaging technology.
[0042] Further, the parameters of the second given imaging technique include but are not limited to scanning speed, moving step size, and scanning power.
[0043] Specifically, the steps of obtaining the defect types not accurately identified corresponding to the second defect recognition score from the captured images corresponding to a number of titanium anode samples are as follows:
[0044] S501, extend the second defect recognition score upward and downward respectively with a preset step size to obtain a defect recognition score range. Those skilled in the art set the preset step size according to actual needs. For example, the preset step size is 2 points or 0.2 points.
[0045] S502, obtain a number of captured images from the captured images corresponding to a number of titanium anode samples, where the corresponding first defect recognition scores are within the defect recognition score range.
[0046] S503, based on the defect types in the surface defect conditions corresponding to each captured image and the defect types in the true defect conditions corresponding to each captured image, obtain the defect types not accurately identified corresponding to the second defect recognition score.
[0047] Further, the defect types not accurately identified refer to the defect types among the several defect types corresponding to the second defect recognition score, where the corresponding initial defect recognition scores are less than the preset score threshold. Those skilled in the art set the preset score threshold according to actual needs and will not be elaborated here.
[0048] As described above, by obtaining the target shooting angle corresponding to a given titanium anode, the approximate second defect recognition score corresponding to the titanium anode at this shooting angle can be found, that is, the defect recognition degree corresponding to this shooting angle. By analyzing the defect types not identified corresponding to the same defect recognition score in the historical data, the defect types that are not easily identified at this shooting angle can be obtained, so as to use the second given imaging technique to detect and identify again, improving the comprehensiveness, accuracy, and reliability of defect detection.
[0049] In a specific embodiment, the steps of adjusting the parameters of the second given imaging technique according to the defect types not accurately identified are as follows:
[0050] S510, when the defect type not accurately identified is 1, look up the preset parameters of the second given imaging technique corresponding to the defect type not accurately identified from the preset defect type - parameter comparison table, and adjust the current parameters of the second given imaging technique based on the preset parameters; it can be understood that for different defect types, the parameters of the second given imaging technique corresponding to each defect type are preset in advance according to experiments to clearly capture the corresponding defect types.
[0051] S520. When the number of defect types that are not accurately identified is greater than 1, perform weight optimization processing on the preset parameters of the second given imaging technology corresponding to each defect type that is not accurately identified, and calculate the weighted sum to obtain the adjustment parameters of the second given imaging technology, so as to adjust the current parameters of the second given imaging technology.
[0052] Further, step S520 specifically further includes the following steps:
[0053] S521. Based on the historical detection data corresponding to a number of titanium anode samples, perform data standardization processing on the defect degree of each defect type in the historical detection data to obtain standardized defect detection data. It can be understood that the historical detection data includes the defect degree of each defect type. For example, the defect degree can be characterized by the length ratio of scratches, the area size of pits, the number of defects, etc. Through data standardization processing, the dimension can be unified, which is convenient for calculation.
[0054] S522. Calculate the dispersion degree of the j-th defect type according to the proportion of the i-th titanium anode sample under the j-th defect type. Among them, the dispersion degree S of the j-th defect type j meets the following conditions:
[0055] ; where m is the number of titanium anode samples, and K ij is the defect detection data of the j-th defect type corresponding to the i-th titanium anode sample.
[0056] S523. Determine the proportion of the dispersion degree of each defect type as the parameter weight of the second given imaging technology optimized corresponding to the defect type itself, so as to obtain the parameter weights of the second given imaging technology corresponding to each defect type that is not accurately identified.
[0057] S524. Respectively use the parameter weights of the second given imaging technology corresponding to a number of defect types that are not accurately identified as a1 to a n and substitute them into the preset parameter adjustment model to obtain the target parameter adjustment model. Among them, n is the number of types of defect types, and x j represents the preset parameters of the second given imaging technology corresponding to the j-th defect type. It can be understood that x j is the combined vector of multiple preset parameters of the second given imaging technology corresponding to the j-th defect type.
[0058] S525. Substitute the preset parameters of the second given imaging technology corresponding to each defect type that is not accurately identified into the target parameter adjustment model to obtain the adjustment parameters of the second given imaging technology.
[0059] As described above, by obtaining the defect detection data, i.e., the defect degree, the dispersion degree of each defect type can be known. In order to obtain accurate detection results, the corresponding weight should be higher when the dispersion degree is larger. In the case where multiple defect types coexist, the adjusted parameters should tend to the preset parameters corresponding to the defect type with a larger weight, so that the obtained target parameter adjustment model is more reasonable and can achieve a more accurate detection effect.
[0060] S600. According to the first defect detection result and the second defect detection result, obtain the final surface defect detection result corresponding to the given titanium anode.
[0061] As described above, after obtaining the first defect detection result, the surface of the titanium anode is detected again using the second given imaging technique to supplement the defect types in the first defect detection result. By combining the first defect detection result and the second defect detection result, the accuracy and comprehensiveness of the surface defect detection of the titanium anode can be effectively improved, providing a reliable factual basis for the quality analysis of the titanium anode.
[0062] Although some specific embodiments of the present invention have been described in detail by way of examples, those skilled in the art should understand that the above examples are only for illustration and not for limiting the scope of the present invention. Those skilled in the art should also understand that various modifications can be made to the embodiments without departing from the scope and spirit of the present invention. The scope of the present invention is defined by the appended claims.
Claims
1. A method for detecting surface defects of a titanium anode, characterized in that, The method includes the following steps: For any titanium anode sample, obtain the surface defect conditions of the titanium anode sample at a number of preset shooting angles under the first given imaging technique, and based on the true defect conditions of the titanium anode sample, obtain the first defect recognition score corresponding to the titanium anode sample at each preset shooting angle; According to a number of preset shooting angles and the first defect recognition scores corresponding to the titanium anode sample at each preset shooting angle, perform curve fitting to obtain the initial angle-score curve graph corresponding to the titanium anode sample; wherein, the initial angle-score curve graph is a normal distribution curve; According to the initial angle-score curve graph corresponding to each titanium anode sample, perform fitting optimization processing to obtain the target angle-score curve graph; When receiving the shooting image of a given titanium anode, obtain the first defect detection result corresponding to the given titanium anode, and based on the target shooting angle corresponding to the given titanium anode, obtain the second defect recognition score corresponding to the given titanium anode from the target angle-score curve graph; Obtain the defect types that are not accurately recognized corresponding to the second defect recognition score from the shooting images corresponding to a number of titanium anode samples, and adjust the parameters of the second given imaging technique according to the defect types that are not accurately recognized to obtain the second defect detection result corresponding to the given titanium anode under the second given imaging technique; According to the first defect detection result and the second defect detection result, obtain the final surface defect detection result corresponding to the given titanium anode; Among them, the obtaining the defect types that are not accurately recognized corresponding to the second defect recognition score from the shooting images corresponding to a number of titanium anode samples includes the following steps: Extend the second defect recognition score upward and downward respectively with a preset step length to obtain a defect recognition score interval; Obtain a number of shooting images corresponding to the first defect recognition scores within the defect recognition score interval from the shooting images corresponding to a number of titanium anode samples; Based on the defect types in the surface defect conditions corresponding to each obtained shooting image and the defect types in the true defect conditions corresponding to each shooting image, obtain the defect types that are not accurately recognized corresponding to the second defect recognition score.
2. The method for detecting surface defects of a titanium anode according to claim 1, characterized in that, Obtain the first defect recognition score corresponding to the titanium anode sample at any preset shooting angle through the following steps: For any preset defect type, obtain the similarity degree between the surface defect conditions and the true defect conditions of the titanium anode sample at any preset shooting angle, and use the similarity degree as the initial defect recognition score corresponding to any preset defect type; Take the average value of the number of initial defect recognition scores corresponding to a number of preset defect types as the first defect recognition score corresponding to the titanium anode sample at any preset shooting angle.
3. The titanium anode surface defect detection method according to claim 1, characterized in that, The performing fitting optimization processing according to the initial angle-score curve graph corresponding to each titanium anode sample to obtain the target angle-score curve graph includes the following steps: According to the initial angle-score curve graphs corresponding to a number of titanium anode samples, respectively obtain the value ranges of the angle mean and the angle standard deviation, and construct a target grid according to the value ranges of the angle mean and the angle standard deviation; Generate an angle-score intermediate curve graph for the average angle and standard deviation of the angle corresponding to any grid point in the target grid, and calculate the loss value corresponding to the grid point itself based on the angle-score intermediate curve graph; wherein, the loss value L corresponding to the grid point itself satisfies the following conditions: , where f i (ε) is the probability density function of the i-th angle-score initial curve graph, and f new (ε) is the probability density function of the angle-score intermediate curve graph corresponding to the grid point itself, m is the number of titanium anode samples, and ε represents the value of the random variable; Take the average angle and standard deviation of the angle corresponding to the grid point with the smallest loss value as the optimal solution, and obtain the angle-score target curve graph according to the optimal solution.
4. The method for detecting surface defects of a titanium anode according to claim 1, characterized in that, The adjusting the parameters of the second given imaging technique according to the inaccurately identified defect type includes the following steps: When the inaccurately identified defect type is 1, look up the preset parameters of the second given imaging technique corresponding to the inaccurately identified defect type from the preset defect type-parameter look-up table, and adjust the current parameters of the second given imaging technique based on the preset parameters; When the inaccurately identified defect type is greater than 1, perform weight optimization processing on the preset parameters of the second given imaging technique corresponding to each inaccurately identified defect type, and calculate the weighted sum to obtain the adjustment parameters of the second given imaging technique to adjust the current parameters of the second given imaging technique.
5. The method for detecting surface defects of a titanium anode according to claim 4, characterized in that, The performing weight optimization processing on the preset parameters of the second given imaging technique corresponding to each inaccurately identified defect type and calculating the weighted sum to obtain the adjustment parameters of the second given imaging technique includes the following steps; Based on the historical detection data corresponding to a number of titanium anode samples, perform data standardization processing on the degree of defect of each defect type in the historical detection data to obtain standardized defect detection data; Calculate the degree of dispersion of the j-th type of defect based on the proportion of the i-th titanium anode sample under the j-th type of defect; wherein, the degree of dispersion S of the j-th type of defect j Meets the following conditions: ; where m is the number of titanium anode samples, and K ij is the defect detection data of the j-th type of defect corresponding to the i-th titanium anode sample; Determine the proportion of the degree of dispersion of each defect type as the parameter weight optimized for the second given imaging technique corresponding to the defect type itself, so as to obtain the parameter weights of the second given imaging technique corresponding to each inaccurately identified defect type; The parameter weights of the second given imaging techniques corresponding to several defect types that are not accurately identified are respectively used as a1 to a n and substituted into a preset parameter adjustment model to obtain a target parameter adjustment model; where n is the number of types of defect types, and x j represents the preset parameters of the second given imaging technique corresponding to the jth type of defect type; Substitute the preset parameters of the second given imaging technique corresponding to each inaccurately identified defect type into the target parameter adjustment model to obtain the adjustment parameters of the second given imaging technique.
6. The titanium anode surface defect detection method according to claim 2, characterized in that The obtaining the similarity degree between the surface defect condition and the true defect condition of the titanium anode sample at any preset shooting angle includes the following steps: When the defect type targeted is a scratch, obtain the shooting length of the target scratch in the surface defect condition and the actual length of the target scratch in the true defect condition; According to the shooting length of the target scratch and the actual length of the target scratch, calculate the similarity degree between the surface defect condition and the true defect condition of the titanium anode sample under any preset defect type.
7. The method for detecting surface defects of a titanium anode according to claim 1, wherein Both the upper limit value and the lower limit value corresponding to the range of the preset shooting angle are between 0-180°, and 90° < Δθ < 180°, where Δθ is the difference between the upper limit value and the lower limit value corresponding to the range of the preset shooting angle.
Citation Information
Patent Citations
LED chip appearance intelligent rapid detection system and method
CN118961730A
Method and device for detecting surface defects on workpieces or components having a shiny surface
WO2004063732A1