Visual inspection method and system for production quality of titanium alloy bar
By dividing the cooling stage during the titanium alloy bar production process and combining characteristics such as grayscale distribution and curvature, the problem of low crack positioning accuracy in the end detection mode was solved, and higher-precision quality inspection was achieved.
Patent Information
- Application Number
- CN202510836590.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-21
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2045-06-21
AI Technical Summary
The end detection mode of titanium alloy bars in the existing technology increases the difficulty of detection, resulting in low crack positioning accuracy, high risk of missed detection, and poor quality detection accuracy.
By periodically acquiring grayscale images of the bar to be inspected during the cooling process, the images are divided into the high-temperature sensitive stage, the high-temperature cooling stage, and the low-temperature stage. Abnormal bars are screened by combining the grayscale distribution, curvature, and length characteristics. The crack areas are analyzed at different stages to ultimately determine the true crack area.
It achieves more accurate and high-precision crack positioning in the production process of titanium alloy bars, improves the accuracy of quality inspection, and reduces the risk of missed inspection.
Smart Images

Figure CN120725992A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of visual inspection, and in particular to a method and system for visual inspection of production quality of titanium alloy bars. Background Art
[0002] Titanium alloy rods, with their excellent strength-to-weight ratio and corrosion resistance, have become a core raw material in aerospace, high-end equipment manufacturing, and other fields. Their quality directly impacts the reliability of end products. Throughout the entire titanium alloy rod production process, quality inspection is a critical step in ensuring product quality, and vision-based inspection technology is a key supporter of this process.
[0003] In the production process of titanium alloy bars, most quality inspection stages in the industry are concentrated in the latter part of the production process, such as after finishing rolling is completed or the finished product is annealed. This "end detection" mode may cause surface microcracks generated during the rough rolling process to be partially covered up due to high-temperature plastic deformation, oxide layer coverage or work hardening when entering the finishing rolling process, resulting in weakening or even disappearance of crack characteristics, increasing the difficulty of detection and increasing the risk of missed detection, resulting in low crack positioning accuracy and poor accuracy of titanium alloy bar quality inspection. Summary of the Invention
[0004] In order to solve the technical problem in the related art that the "end detection" mode increases the detection difficulty and increases the risk of missed detection, resulting in low crack positioning accuracy and poor accuracy of titanium alloy bar quality detection, the present invention provides a titanium alloy bar production quality visual inspection method and system, the technical solutions adopted are as follows:
[0005] The present invention proposes a method for visually inspecting the production quality of titanium alloy bars, the method comprising:
[0006] Grayscale images of the bar to be inspected are periodically acquired during the cooling process, and the bar to be inspected is divided into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value;
[0007] Determine the standard degree of the bar to be inspected in the grayscale image based on the grayscale distribution, curvature and length of the bar to be inspected in the high-temperature sensitive stage; and screen out abnormal bars with cracks based on the standard degree of the bar to be inspected in each grayscale image.
[0008] During the high-temperature cooling stage, the oxidation effect is analyzed based on the grayscale changes of the abnormal bars at different sampling times, and the initial crack area of the abnormal bars during the high-temperature cooling stage is determined. During the low-temperature stage, crack detection is performed on the abnormal bars in the grayscale image, and the actual crack area is determined based on the similarity between the detected crack area and the initial crack area.
[0009] The production quality of the bar is determined based on the actual crack area.
[0010] Furthermore, the method of dividing the bar to be inspected into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value includes:
[0011] The dividing temperature between the high-temperature sensitive stage and the high-temperature cooling stage is determined to be 800 degrees Celsius, and the dividing temperature between the high-temperature cooling stage and the low-temperature stage is determined to be 500 degrees Celsius;
[0012] Determine the grayscale values of the standard rod with a surface temperature of 800 degrees Celsius and 500 degrees Celsius in the grayscale image as a first grayscale threshold and a second grayscale threshold respectively;
[0013] When the grayscale mean value of the bar to be detected is greater than the first grayscale threshold, it is determined to be in the high temperature sensitive stage;
[0014] When the grayscale value is less than or equal to the first grayscale threshold and greater than the second grayscale threshold, it is determined to be in the high-temperature cooling stage;
[0015] When the grayscale value is less than or equal to the second grayscale threshold, it is determined to be in the low temperature stage.
[0016] Furthermore, the determining of the standard degree of the bar to be inspected in the grayscale image according to the grayscale distribution, curvature and length of the bar to be inspected in the high temperature sensitive stage includes:
[0017] Calculate the gray value variance of all pixels in the bar area to be detected as the first standard indicator;
[0018] Determine the second standard index of bending influence according to the bending degree of the bar to be tested;
[0019] The absolute value of the difference between the length of the bar to be tested and the standard length is used as the third standard indicator;
[0020] The standard degree of the bar to be tested is determined by combining the first standard index, the second standard index and the third standard index, wherein the first standard index, the second standard index and the third standard index are all negatively correlated with the standard degree, and the value of the standard degree is a normalized value.
[0021] Furthermore, the second standard index is determined according to the degree of bending of the bar to be tested, including:
[0022] Perform morphological corrosion treatment on the bar area to be tested to determine the skeleton line;
[0023] Perform straight line fitting on the skeleton line to obtain a fitting straight line;
[0024] Determine the distance between each pixel point on the skeleton line and the fitting line, and use the sum of the distances between all pixels and the fitting line as the second standard indicator.
[0025] Furthermore, the screening of abnormal bars with cracks according to the standard degree of the bars to be inspected in each grayscale image includes:
[0026] The bar to be detected whose standard degree is less than the preset standard threshold is regarded as an abnormal bar.
[0027] Furthermore, the analysis of the oxidation effect based on the grayscale changes of the abnormal bar at different sampling moments and the determination of the initial crack area of the abnormal bar during the high-temperature cooling stage include:
[0028] Determine the grayscale values of the same pixel at different sampling times and arrange them in time sequence to obtain a grayscale sequence; perform first-order difference processing on the grayscale sequence to obtain a difference sequence;
[0029] The elements in the differential sequence whose values are greater than a preset differential threshold are regarded as oxidation-affecting elements;
[0030] Determine the duration corresponding to the oxidation-affecting element in the grayscale sequence as the oxidation time;
[0031] The sum of all oxidation-affecting elements and the ratio of oxidation time are normalized and used as the oxidation effect index;
[0032] Pixels whose oxidation effect index is greater than a preset effect threshold are regarded as crack pixels, and the area formed by the crack pixels is regarded as the initial crack area.
[0033] Furthermore, crack detection is performed on the abnormal bar in the grayscale image, and the real crack area is determined based on the similarity between the detected crack area and the initial crack area, including:
[0034] Perform edge detection on abnormal bars in the grayscale image and determine the edge texture of non-bar contours as the gap area;
[0035] Determining an initial crack region matching each gap region based on a morphological center distance between the gap region and the initial crack region;
[0036] The real crack region is determined based on the difference in extension direction and the region overlap between the gap region and the matching initial crack region.
[0037] Furthermore, determining an initial crack region matching each gap region based on the morphological center distance between the gap region and the initial crack region includes:
[0038] The morphological center points of each gap region and the initial crack region are determined, and the Euclidean distance between the morphological center points of the gap region and the crack region is used as the analysis distance; the crack region with the smallest analysis distance to the gap region is used as the initial crack region matching the corresponding gap region.
[0039] Furthermore, determining the real crack region according to the difference in extension direction between the gap region and the matching initial crack region includes:
[0040] Perform straight line fitting on the gap area and the matching initial crack area to obtain a fitting straight line. The angle between the fitting straight line of the gap area and the fitting straight line of the crack area and the ratio of the angle to 180 degrees are used as direction analysis indicators.
[0041] In the gap area and the matching initial crack area, the ratio of the number of identical pixels to the union of all pixels in the two areas is determined as the area overlap;
[0042] Calculate the difference between the regional overlap and the direction analysis index, normalize it, and use it as the crack judgment index;
[0043] The crack area where the crack judgment index is greater than the preset judgment threshold is regarded as the real crack area.
[0044] On the other hand, a visual inspection system for the production quality of titanium alloy bars is also provided. The system includes a memory, a processor, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, the steps of any of the methods described above are implemented.
[0045] The present invention has the following beneficial effects:
[0046] The present invention periodically obtains the grayscale image of the bar to be inspected during the cooling process, and divides the bar to be inspected into a high-temperature sensitive stage, a high-temperature cooling stage and a low-temperature stage according to the grayscale value. First, by performing quality inspection on the cooling process, compared with the quality inspection of the finished product in the related art, the quality inspection link is moved forward to the transition stage between rough rolling and finishing rolling, which can effectively capture the surface change differences of the bar, accurately identify the surface texture, and complete precise positioning when the cracks have not yet been complicated by the deformation of finishing rolling; in the high-temperature sensitive stage, the three characteristics of grayscale distribution, curvature and length are combined to determine the abnormal bar with cracks; in the high-temperature cooling stage, the oxidation effect is analyzed according to the grayscale change to determine the initial crack area; in the low-temperature stage, gap detection is performed, and the real crack area is determined by combining the similarity; thus, combined with the characteristic performance of the bar at different stages in the cooling process, crack analysis in different dimensions is performed to achieve more accurate and higher-precision crack positioning, effectively improving the accuracy of quality inspection of titanium alloy bars. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] In order to more clearly illustrate the technical solutions and advantages of the embodiments of the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the prior art descriptions. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0048] Figure 1 A flow chart of a method for visually inspecting the production quality of titanium alloy bars provided by one embodiment of the present invention;
[0049] Figure 2 A schematic diagram of a walking beam conveyor provided in one embodiment of the present invention;
[0050] Figure 3 A schematic diagram of image acquisition provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0051] To further illustrate the technical means and effectiveness of the present invention in achieving its intended purpose, the following, in conjunction with the accompanying drawings and preferred embodiments, describes in detail a method and system for visually inspecting the production quality of titanium alloy bars, including its specific implementation, structure, features, and effectiveness. In the following description, references to different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. Furthermore, specific features, structures, or characteristics of one or more embodiments may be combined in any suitable manner.
[0052] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
[0053] The specific scheme of the method for visual inspection of production quality of titanium alloy bars provided by the present invention is described in detail below with reference to the accompanying drawings.
[0054] See also Figure 1 , which shows a flow chart of a method for visually inspecting the production quality of titanium alloy bars provided by one embodiment of the present invention, the method comprising:
[0055] S101: periodically acquiring grayscale images of the bar to be inspected during the cooling process, and dividing the bar to be inspected into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value.
[0056] In the titanium alloy bar production process, most quality inspections are conducted at the end of the production process, such as after finishing rolling or annealing. This "end-of-line inspection" approach can partially mask surface microcracks generated during rough rolling due to high-temperature plastic deformation, oxide layer coverage, or work hardening during finishing. This weakens or even eliminates crack characteristics, increasing the difficulty of detection and the risk of missed detection. Therefore, the present invention moves the quality inspection step forward to the transition stage between roughing and finishing rolling, enabling crack detection in bars.
[0057] In the embodiment of the present invention, the titanium alloy bars after rough rolling are placed in the V-shaped groove of the walking beam conveyor and transported backward in sequence with the stepping action of the conveyor. During the static interval of the conveyor, the bars are in a static state and naturally cool down. The natural cooling process is the cooling process. Figure 2 and Figure 3 , Figure 2 A schematic diagram of a walking beam conveyor provided in accordance with an embodiment of the present invention is shown. Figure 3 A schematic diagram of image acquisition provided for an embodiment of the present invention; a high frame rate camera can be configured directly above the walking beam conveyor to capture the original image of the bar to be inspected, and then the original image is subjected to mean grayscale processing to obtain a grayscale image, which is well known to those skilled in the art and will not be described in detail.
[0058] When the bar is just out of the furnace, the brightness of the bar is high due to the high temperature. However, as it cools naturally, the surface oxidizes and the grayscale value gradually decreases. Therefore, in order to accurately distinguish, in the embodiment of the present invention, the cooling process of the bar to be tested is divided into three stages: high-temperature sensitive stage, high-temperature cooling stage and low-temperature stage.
[0059] Furthermore, in some embodiments of the present invention, the rod to be inspected is divided into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value, including: determining the dividing temperature between the high-temperature sensitive stage and the high-temperature cooling stage to be 800 degrees Celsius, and the dividing temperature between the high-temperature cooling stage and the low-temperature stage to be 500 degrees Celsius; determining the grayscale values of the standard rod with surface temperatures of 800 degrees Celsius and 500 degrees Celsius in the grayscale image as the first grayscale threshold and the second grayscale threshold, respectively; when the grayscale mean value of the rod to be inspected is greater than the first grayscale threshold, it is determined to be in the high-temperature sensitive stage; when it is less than or equal to the first grayscale threshold and greater than the second grayscale threshold, it is determined to be in the high-temperature cooling stage; when it is less than or equal to the second grayscale threshold, it is determined to be in the low-temperature stage.
[0060] That is to say, the actual stage division is performed by temperature, and the grayscale value corresponding to the temperature is used as the threshold to realize the grayscale stage division on the image, and all grayscale images of the bar to be inspected are divided into high-temperature sensitive stage, high-temperature cooling stage and low-temperature stage.
[0061] It should be noted that different stages have different manifestations. When the bar is in the high-temperature sensitive stage, the bar has just completed rough rolling and the surface temperature is extremely high. The cracks generated during the rolling process have not yet completely closed due to high-temperature plastic deformation, so they are easy to find; in the high-temperature cooling stage, the bar is in the middle cooling stage, and the gradually formed oxide film enhances the characteristic performance of the crack defect area; in the low-temperature stage, the surface state of the bar tends to be stable, and the defect morphology no longer changes with temperature, which facilitates the final confirmation and analysis of the defect.
[0062] Based on the above logic, a multi-stage coordinated crack quality detection process is implemented.
[0063] S102: Determine the standard degree of the bar to be inspected in the grayscale image according to the grayscale distribution, curvature and length of the bar to be inspected in the high-temperature sensitive stage; and screen abnormal bars with cracks according to the standard degree of the bar to be inspected in each grayscale image.
[0064] During the high-temperature sensitive stage, the normal rod will have a higher grayscale value due to the high temperature. However, the cracked area will have a more obvious grayscale difference from the normal high-temperature rod due to the corresponding uneven heat dissipation. The rod will also show length inconsistency and bending during this stage. At this stage, the rod is still relatively plastic due to its fresh shape, and the cracks will cause uneven stress, resulting in more obvious bending.
[0065] In the embodiment of the present invention, the grayscale distribution, curvature and length are combined to screen abnormal bars with cracks.
[0066] Furthermore, in some embodiments of the present invention, the standardization degree of the rod to be detected in the grayscale image is determined based on the grayscale distribution, curvature and length of the rod to be detected in the high-temperature sensitive stage, including: calculating the grayscale value variance of all pixels in the rod area to be detected as a first standard indicator; determining a second standard indicator of the influence of bending based on the degree of curvature in the morphology of the rod to be detected; taking the absolute value of the difference between the length of the rod to be detected and the standard length as a third standard indicator; and determining the standardization degree of the rod to be detected by combining the first standard indicator, the second standard indicator and the third standard indicator, wherein the first standard indicator, the second standard indicator and the third standard indicator are all negatively correlated with the standardization degree, and the value of the standardization degree is a normalized value.
[0067] Among them, the first standard indicator, the second standard indicator and the third standard indicator are all indicator information under the corresponding characteristics.
[0068] The first standard indicator characterizes the discrete characteristics of the grayscale value. Since the crack area will have a more obvious grayscale difference under the influence of the crack, the larger the variance of the grayscale value, the more obvious the crack influence.
[0069] The second standard index represents the bending characteristics. The degree of bending can be determined by fitting a straight line and analyzing the difference between the fitted straight lines, or by directly determining the curvature of the bar through image recognition to analyze the degree of bending.
[0070] Furthermore, in some embodiments of the present invention, a second standard indicator is determined based on the degree of bending in the morphology of the rod to be inspected, including: performing morphological corrosion processing on the rod area to be inspected to determine the skeleton line; performing straight line fitting on the skeleton line to obtain a fitted straight line; determining the distance between each pixel point on the skeleton line and the fitted straight line, and using the distance and value of all pixel points and the fitted straight line as the second standard indicator.
[0071] Among them, morphological corrosion treatment is a technology well known in the art. The second standard index is determined by the difference between the skeleton line and the fitting straight line. That is, the larger the value of the second standard index, the higher the degree of bending of the corresponding bar to be tested and the more obvious the impact of the crack.
[0072] The third standard indicator represents the length difference characteristic. Length consistency is also an important influencing factor in bar quality detection. The absolute value of the difference between the length of the bar to be tested and the standard length is used as the third standard indicator. The larger the value of the third standard indicator, the greater the difference between the length and the standard, and the worse the bar quality.
[0073] Based on the above analysis of the first, second, and third standard indicators, the degree of standardization can be calculated. It should be noted that a positive correlation indicates that the independent variable and the dependent variable have a same-direction change relationship, where the larger the independent variable, the larger the dependent variable; a negative correlation indicates that the independent variable and the dependent variable have an inverse change relationship, where the smaller the independent variable, the larger the dependent variable. The specific manifestations of positive and negative correlations are determined by actual applications and are not specifically limited in this application.
[0074] At the same time, to facilitate calculations, all indicator data involved in the calculations in the embodiments of the present invention are pre-processed to eliminate dimension effects. Specific means of eliminating dimension effects are well known to those skilled in the art and are not limited here.
[0075] Therefore, in the embodiment of the present invention, the product value of the first standard index, the second standard index and the third standard index can be directly calculated, and the opposite of the product value can be normalized to the maximum and minimum values to be used as the standard degree.
[0076] In the embodiment of the present invention, the standard degree represents the standard coefficient of the rod to be tested in the three dimensions of grayscale distribution, curvature, and length. The larger the value of the standard degree, the more normal the corresponding rod to be tested performs in the high-temperature sensitive stage. Therefore, in the embodiment of the present invention, the rod to be tested with a standard degree less than the preset standard threshold is regarded as an abnormal rod.
[0077] The preset standard threshold is a threshold value of the standard degree, specifically, it can be 0.6, that is, the bars to be detected with a standard degree less than 0.6 are regarded as abnormal bars.
[0078] S103: During the high-temperature cooling stage, the oxidation effect is analyzed based on the grayscale changes of the abnormal rod at different sampling times to determine the initial crack area of the abnormal rod during the high-temperature cooling stage; during the low-temperature stage, crack detection is performed on the abnormal rod in the grayscale image, and the actual crack area is determined based on the similarity between the detected crack area and the initial crack area.
[0079] When the bar enters the high-temperature cooling stage, cracks disrupt the surface continuity of the bar, exposing the internal metal matrix and forming a large number of highly active oxidation reaction sites. These sites are the first to react with oxygen within the temperature range of the high-temperature cooling stage. At the same time, the cracked area exposes more surface area and the hot air trapped inside further accelerates the formation of an oxide film. The formation of an oxide film can cause grayscale changes. Therefore, oxidation analysis can be directly performed based on grayscale changes to determine the initial crack area.
[0080] Furthermore, in some embodiments of the present invention, the oxidation effect is analyzed according to the grayscale changes of the abnormal rod at different sampling moments, and the initial crack area of the abnormal rod in the high-temperature cooling stage is determined, including: determining the grayscale value of the same pixel at different sampling moments, and arranging it in time sequence to obtain a grayscale sequence; performing first-order difference processing on the grayscale sequence to obtain a differential sequence; taking the elements in the differential sequence whose values are greater than a preset differential threshold as oxidation-influencing elements; determining the duration corresponding to the oxidation-influencing elements in the grayscale sequence as the oxidation time; normalizing the ratio of the sum of all oxidation-influencing elements to the oxidation time as an oxidation effect index; taking the pixel points whose oxidation effect index is greater than the preset effect threshold as crack pixel points, and the area composed of crack pixel points as the initial crack area.
[0081] The oxidation reaction will cause the grayscale of the rod surface to decrease rapidly. Therefore, in the embodiment of the present invention, for the same pixel point, its grayscale sequence is determined and its differential sequence is analyzed. The grayscale changes in the differential sequence are partly due to the grayscale changes caused by normal temperature drop, and partly due to the grayscale changes caused by surface oxidation. The grayscale changes caused by surface oxidation are more drastic, making the grayscale reduction effect more obvious. Therefore, in the embodiment of the present invention, a preset differential threshold is set to achieve the acquisition of oxidation-affecting elements.
[0082] The preset differential threshold is the threshold value of the element in the differential sequence. Specifically, it can be 2, for example. That is, at two adjacent sampling moments (which can be specifically high-frame shooting of 10 to 30 frames per second, with each frame as a sampling moment), the grayscale value changes by 2 values, which is manifested as a grayscale change caused by the oxidation effect, and it is regarded as an oxidation-influencing element.
[0083] The oxidation-affecting elements represent the oxidation behavior at two adjacent sampling moments. Therefore, the corresponding time interval can be used as the time interval corresponding to the oxidation phenomenon. By traversing the differential sequence corresponding to a pixel point, the duration corresponding to all oxidation-affecting elements in the grayscale sequence can be obtained as the overall oxidation time.
[0084] The sum of all oxidation-affecting elements is calculated. The larger the value, the more intense the oxidation reaction. The ratio of the sum to the oxidation time is normalized and used as the oxidation effect index. The oxidation effect index indicates the obvious degree of the oxidation effect. The larger the value of the oxidation effect index, the more intense the oxidation reaction, and the shorter the time, the more likely it is to manifest as an oxidation effect caused by cracks. The pixels whose oxidation effect index is greater than the preset effect threshold are regarded as crack pixels, and the area composed of crack pixels is regarded as the initial crack area.
[0085] The preset effect threshold is a threshold value of the oxidation effect index, which can be specifically 0.8 in the embodiment of the present invention, and is adjusted according to the actual oxidation characteristics of the bar, and is not limited thereto.
[0086] If the oxide film formed during the high-temperature cooling stage is partially damaged due to transportation on a walking beam conveyor, it may expose new metal surfaces to oxygen for a short period of time, temporarily accelerating oxidation and forming "pseudo-crack signals." Therefore, after completing the dynamic oxidation behavior screening during the high-temperature cooling stage, further evaluation is required during the low-temperature stage when the effect is stable.
[0087] Furthermore, in some embodiments of the present invention, crack detection is performed on abnormal rods in grayscale images, and the real crack area is determined based on the similarity between the detected gap area and the initial crack area, including: edge detection is performed on the abnormal rods in the grayscale image, and the edge texture of the non-rod contour is determined to be the crack area; based on the morphological center distance between the crack area and the initial crack area, the initial crack area matching each crack area is determined; based on the difference in extension direction and area overlap between the crack area and the matching initial crack area, the real crack area is determined.
[0088] As the temperature of the titanium alloy bar decreases and enters the low-temperature stage, the oxide film growth tends to stabilize, and the detection signal that initially relied on the dynamic oxidation rate may become flat. At this time, the static geometric characteristics of the oxide film cracking need to be used to define the nature of the defect. Because the oxide film at the actual crack is structurally fragile due to the defect, it is easy to further expand along the original crack when moving on the conveyor. The resulting crack has a clear position inheritance and directional consistency. That is, the crack position is highly consistent with the crack position detected in the low-temperature stage, and the direction is a continuous straight line. However, the oxide film fracture caused by mechanical stress during transportation often manifests as irregular network or point cracks with random distribution direction and no correlation with the initial crack area detected in the previous sequence.
[0089] Therefore, firstly, edge detection is performed on the abnormal rod in the grayscale image to determine the edge texture of the non-rod contour as the gap area, and matching analysis is performed based on morphological features to determine the initial crack area that matches the gap area.
[0090] Furthermore, in some embodiments of the present invention, the initial crack region matching each gap region is determined based on the morphological center distance between the gap region and the initial crack region, including: determining the morphological center point of each gap region and the initial crack region, and using the Euclidean distance between the morphological center points of the gap region and the crack region as the analysis distance; and using the crack region with the smallest analysis distance from the gap region as the initial crack region matching the corresponding gap region.
[0091] Among them, the method of obtaining the morphological center point is well known to relevant technical personnel in this field and will not be elaborated on here. The analysis distance represents the objective position distance between the two areas. The smaller the value, the higher the matching degree. Therefore, the minimum analysis distance is used as a condition for judgment to determine the initial crack area that matches the corresponding gap area.
[0092] When determining the matching initial crack area hysteresis, it is necessary to exclude the influence of pseudo-cracks caused by local damage. Since pseudo-cracks usually spread irregularly, they can be screened according to the extension direction.
[0093] Furthermore, in some embodiments of the present invention, the real crack area is determined based on the difference in extension direction between the gap area and the matching initial crack area, including: performing straight line fitting on the gap area and the matching initial crack area respectively to obtain a fitting straight line, and taking the angle between the fitting straight line of the gap area and the fitting straight line of the crack area, and the ratio of the angle to 180 degrees as a direction analysis index; in the gap area and the matching initial crack area, determining the ratio of the same number of pixels to the union of all pixels in the two areas as the area overlap; calculating the difference between the area overlap and the direction analysis index, normalizing it, and using it as a crack judgment index; and taking the crack area whose crack judgment index is greater than a preset judgment threshold as the real crack area.
[0094] The angle value obtained by linear fitting is used to determine the consistency of the extension direction. The smaller the value of the direction analysis index, the more consistent the extension direction. The regional overlap further analyzes the overlap of the matching gap area and the initial crack area. The larger the regional overlap value, the higher the overlap between the gap area and the matching initial crack area, which means that it is more likely to be a real crack that has always existed. Therefore, in this embodiment of the present invention, the difference between the regional overlap and the direction analysis index is calculated and normalized as the crack judgment index. The larger the value of the crack judgment index, the more consistent it is with the characteristics of a real crack.
[0095] The preset judgment threshold is a threshold value of a crack judgment indicator. In the embodiment of the present invention, it can be specifically 0.5, for example, so as to screen out a real crack area.
[0096] S104: Determine the production quality of the bar according to the actual crack area.
[0097] The real crack area indicates the area where cracks occur. Therefore, the larger the real crack area is, the worse the production quality of the bar is. The real crack area can be directly combined with other characteristics such as its shape and position as the production quality inspection result.
[0098] The present invention periodically obtains the grayscale image of the bar to be inspected during the cooling process, and divides the bar to be inspected into a high-temperature sensitive stage, a high-temperature cooling stage and a low-temperature stage according to the grayscale value. First, by performing quality inspection on the cooling process, compared with the quality inspection of the finished product in the related art, the quality inspection link is moved forward to the transition stage between rough rolling and finishing rolling, which can effectively capture the surface change differences of the bar, accurately identify the surface texture, and complete precise positioning when the cracks have not yet been complicated by the deformation of finishing rolling; in the high-temperature sensitive stage, the three characteristics of grayscale distribution, curvature and length are combined to determine the abnormal bar with cracks; in the high-temperature cooling stage, the oxidation effect is analyzed according to the grayscale change to determine the initial crack area; in the low-temperature stage, gap detection is performed, and the real crack area is determined by combining the similarity; thus, combined with the characteristic performance of the bar at different stages in the cooling process, crack analysis in different dimensions is performed to achieve more accurate and higher-precision crack positioning, effectively improving the accuracy of quality inspection of titanium alloy bars.
[0099] On the other hand, a visual inspection system for the production quality of titanium alloy bars is also provided, which includes a memory, a processor, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, the steps of any of the methods described above are implemented.
[0100] It should be noted that the order in which the embodiments of the present invention are described above is for illustrative purposes only and does not necessarily represent the superiority or inferiority of the embodiments. The processes depicted in the accompanying drawings do not necessarily require the specific order or sequential order shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0101] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on the differences from other embodiments.
Claims
1. A method for visual inspection of titanium alloy bar production quality, characterized in that: The method comprises: Grayscale images of the bar to be inspected are periodically acquired during the cooling process, and the bar to be inspected is divided into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value; Determine the standard degree of the bar to be inspected in the grayscale image based on the grayscale distribution, curvature and length of the bar to be inspected in the high-temperature sensitive stage; and screen out abnormal bars with cracks based on the standard degree of the bar to be inspected in each grayscale image. During the high-temperature cooling stage, the oxidation effect is analyzed based on the grayscale changes of the abnormal bars at different sampling times, and the initial crack area of the abnormal bars during the high-temperature cooling stage is determined. During the low-temperature stage, crack detection is performed on the abnormal bars in the grayscale image, and the actual crack area is determined based on the similarity between the detected crack area and the initial crack area. The production quality of the bar is determined based on the actual crack area.
2. A method for visual inspection of production quality of titanium alloy bars according to claim 1, characterized in that: The method of dividing the bar to be inspected into a high-temperature sensitive stage, a high-temperature cooling stage, and a low-temperature stage according to the surface grayscale value includes: The dividing temperature between the high-temperature sensitive stage and the high-temperature cooling stage is determined to be 800 degrees Celsius, and the dividing temperature between the high-temperature cooling stage and the low-temperature stage is determined to be 500 degrees Celsius; Determine the grayscale values of the standard rod with a surface temperature of 800 degrees Celsius and 500 degrees Celsius in the grayscale image as a first grayscale threshold and a second grayscale threshold respectively; When the grayscale mean value of the bar to be detected is greater than the first grayscale threshold, it is determined to be in the high temperature sensitive stage; When the grayscale value is less than or equal to the first grayscale threshold and greater than the second grayscale threshold, it is determined to be in the high-temperature cooling stage; When the grayscale value is less than or equal to the second grayscale threshold, it is determined to be in the low temperature stage.
3. The method for visual inspection of titanium alloy bar production quality according to claim 1, characterized in that: The step of determining the standard degree of the bar to be inspected in the grayscale image according to the grayscale distribution, curvature, and length of the bar to be inspected in the high-temperature sensitive stage includes: Calculate the gray value variance of all pixels in the bar area to be detected as the first standard indicator; Determine the second standard index of bending influence according to the bending degree of the bar to be tested; The absolute value of the difference between the length of the bar to be tested and the standard length is used as the third standard indicator; The standard degree of the bar to be tested is determined by combining the first standard index, the second standard index and the third standard index, wherein the first standard index, the second standard index and the third standard index are all negatively correlated with the standard degree, and the value of the standard degree is a normalized value.
4. A method for visually inspecting the production quality of titanium alloy bars according to claim 3, characterized in that: The second standard index is determined according to the bending degree of the bar to be tested, including: Perform morphological corrosion treatment on the bar area to be tested to determine the skeleton line; Perform straight line fitting on the skeleton line to obtain a fitting straight line; Determine the distance between each pixel point on the skeleton line and the fitting line, and use the sum of the distances between all pixels and the fitting line as the second standard indicator.
5. The method for visual inspection of production quality of titanium alloy bars according to claim 1, characterized in that: The method of screening abnormal bars with cracks according to the standard degree of the bars to be inspected in each grayscale image includes: The bar to be detected whose standard degree is less than the preset standard threshold is regarded as an abnormal bar.
6. The method for visual inspection of production quality of titanium alloy bars according to claim 1, characterized in that: The analysis of the oxidation effect based on the grayscale changes of the abnormal bar at different sampling moments and the determination of the initial crack area of the abnormal bar during the high-temperature cooling stage include: Determine the grayscale values of the same pixel at different sampling times and arrange them in time sequence to obtain a grayscale sequence; perform first-order difference processing on the grayscale sequence to obtain a difference sequence; The elements in the differential sequence whose values are greater than a preset differential threshold are regarded as oxidation-affecting elements; Determine the duration corresponding to the oxidation-affecting element in the grayscale sequence as the oxidation time; The ratio of the sum of all oxidation-affecting elements to the oxidation time is normalized and used as an indicator of oxidation effect. Pixels whose oxidation effect index is greater than a preset effect threshold are regarded as crack pixels, and the area formed by the crack pixels is regarded as the initial crack area.
7. The method for visual inspection of titanium alloy bar production quality according to claim 1, characterized in that: Perform crack detection on abnormal bars in grayscale images and determine the true crack area based on the similarity between the detected crack area and the initial crack area, including: Perform edge detection on abnormal bars in the grayscale image and determine the edge texture that is not the bar outline as the gap area; Determining an initial crack region matching each gap region based on a morphological center distance between the gap region and the initial crack region; The real crack region is determined based on the difference in extension direction and the region overlap between the gap region and the matching initial crack region.
8. A method for visually inspecting the production quality of titanium alloy bars according to claim 7, characterized in that: Determining an initial crack region matching each gap region based on the morphological center distance between the gap region and the initial crack region includes: The morphological center points of each gap region and the initial crack region are determined, and the Euclidean distance between the morphological center points of the gap region and the crack region is used as the analysis distance; the crack region with the smallest analysis distance to the gap region is used as the initial crack region matching the corresponding gap region.
9. A method for visually inspecting the production quality of titanium alloy bars according to claim 7, characterized in that: Determining the true crack region based on the difference in extension direction between the gap region and the matching initial crack region includes: Perform straight line fitting on the gap area and the matching initial crack area to obtain a fitting straight line. The angle between the fitting straight line of the gap area and the fitting straight line of the crack area and the ratio of the angle to 180 degrees are used as direction analysis indicators. In the gap area and the matching initial crack area, the ratio of the number of identical pixels to the union of all pixels in the two areas is determined as the area overlap; Calculate the difference between the regional overlap and the direction analysis index, normalize it, and use it as the crack judgment index; The crack area where the crack judgment index is greater than the preset judgment threshold is regarded as the real crack area.
10. A titanium alloy bar production quality visual inspection system, the system comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 9 are implemented.
Citation Information
Patent Citations
Method for adaptively extracting infrared thermal image defects based on phase characteristics
CN114219765A
Welding beading defect detection method
CN116664569A
Artificial intelligence visual inspection method, system and device based on workpiece production
CN119205646A
System for generating thermographic images using thermographic signal reconstruction
WO2002089042A1