Vision-based bearing ring end face defect detection method
By building an end face defect detection system, the end face images of bearing rings are collected and processed, and the problems of low detection efficiency and high error detection rate in the prior art are solved, real-time and accurate defect detection of the end faces of bearing rings are realized, and it is suitable for a variety of models.
Patent Information
- Application Number
- CN202411758386.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-03
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2044-12-03
AI Technical Summary
The existing visual detection methods have the disadvantages of low detection efficiency, high error detection rate, and single model in the detection of bearing ring end surface defects, making it difficult to achieve real-time and accurate detection.
The vision-based bearing ring end face defect detection method is adopted, and the end face image of the bearing ring is collected by constructing an end face defect detection system, and the area of interest ROI extraction, standard circle matching, polar coordinate conversion, linear interpolation and defect area pre-processing are performed to finally realize defect detection of the end face of the bearing ring.
Real-time and accurate detection of bearing ring defects is achieved, and the error detection rate is reduced. It is suitable for a variety of bearing ring models. It has high detection accuracy and speed, and meets the requirements of real-time inspection on site of the production line.
Smart Images

Figure CN119715537A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a bearing ring defect detection method, and relates to the technical field of visual bearing quality appearance detection, and in particular to a bearing ring end face defect detection method based on vision. Background Art
[0002] Bearings are extremely important components in the industrial field, widely used in various machinery and equipment, and play a key supporting and load-bearing role. The performance and quality of bearings directly affect the stability and safety of mechanical equipment, so it is very important to inspect the appearance quality of bearings during the design and manufacturing process.
[0003] During the manufacturing process, bearing workpieces are easily affected by manufacturing processes and production factors, resulting in various defects such as black blocks, scratches and bumps. Surface defects are mainly caused by equipment failure, material problems, processing errors, poor lubrication and other factors. The requirements for defect detection of bearing end faces are relatively high. The size of some defects is even around 100μm. In addition, there are many types of defects and different sizes generated during the production process. Some fine pits are similar to the bearing texture background. The existing visual inspection methods have the disadvantages of low detection efficiency, high false detection rate, and single model. Therefore, they are insufficient to undertake the task of real-time bearing detection. There are still some difficulties in the process of visual inspection of bearing end faces. The difficulties in bearing end face defect detection are mainly the following: the bearing end face area is narrow, generally around 7mm. In the detection process, the entire end face ring of the bearing needs to be obtained. The general ROI acquisition method will introduce background pixels and lose end face pixels due to inaccurate positioning. The accurate process of contour extraction also affects the accuracy of detection.
[0004] There are too many texture features on the surface of the bearing ring. Therefore, the existence of texture features will have a certain impact on the detection of damage, scratches and black spots during the bearing inspection process, which is prone to false detection problems. It is necessary to eliminate irrelevant texture features. Summary of the invention
[0005] In order to solve the problems existing in the background technology, the present invention provides a bearing ring end face defect detection method based on vision.
[0006] The technical solution adopted by the present invention is:
[0007] The vision-based bearing ring end face defect detection method of the present invention comprises:
[0008] S1: Construct an end face defect detection system for bearing rings, and collect end face images of defect-free bearing rings of different models through the end face defect detection system.
[0009] S2: Use the end face defect detection system to extract the region of interest (ROI) from the end face images of defect-free bearing rings of different models.
[0010] S3: Use the end face defect detection system to collect the end face images of the bearing rings to be inspected on the production line, and use the end face positioning matching based on standard circle matching between the region of interest (ROI) of the end face images of defect-free bearing rings of different models and the end face images of the bearing rings to be inspected. Then, polar coordinate conversion and linear interpolation are performed in sequence, and then defect area preprocessing is performed to locate the defect area, and finally the defect detection of the end face of the bearing ring is realized.
[0011] In step S1, the bearing ring end surface defect detection system includes a 500W area array CCD (Charge Coupled The invention relates to an industrial camera, a white coaxial light source, a semi-transparent reflector, a storage platform, an industrial computer and a cloud platform, wherein the bearing ring is placed horizontally on the storage platform with the end face to be collected facing upward, the area array CCD industrial camera, the semi-transparent reflector and the bearing ring are arranged in sequence from top to bottom, the 16 mm fixed-focus lens of the area array CCD industrial camera is vertically downward facing the semi-transparent reflector, and the coaxial light source is located on one side of the semi-transparent reflector; the industrial computer comprises a programmable controller and a host computer connected in sequence, the controller is electrically connected to the area array CCD industrial camera, and the host computer is wirelessly connected to the cloud platform; the coaxial light source emits a horizontal white light source to the semi-transparent reflector and then reflects to generate vertically downward incident light to the end face of the bearing ring, the reflected light of the end face of the bearing ring is transmitted through the semi-transparent reflector and then is collected by the fixed-focus lens of the area array CCD industrial camera for end face image collection of the bearing ring, and then transmitted to the controller and the host computer of the industrial computer for ROI extraction, matching, polar coordinate conversion and defect area preprocessing for defect detection, and finally uploaded to the cloud platform for storage and monitoring.
[0012] The image acquisition part of the end defect detection system includes an array CCD industrial camera, a coaxial light source, a semi-transparent reflector and a storage platform. The industrial computer includes a controller and a host computer that establish a communication connection with the image acquisition part. After the bearing ring reaches the specified position on the production line, the coaxial light source is illuminated, and the host computer of the industrial computer controls the array CCD industrial camera to acquire images. The controller and the host computer mainly perform real-time monitoring of the bearing ring and store and log abnormal images of the bearing ring, and upload them to the cloud platform; the cloud platform is used to receive the end face images and information of the bearing ring collected by the bearing inspection station. The cloud platform can also receive conventional data such as photos and model size information of abnormal bearing ring workpieces, which can realize cloud-based automated detection of bearing ring workpieces on the production line and can perform maintenance in a timely manner. In normal mode, the host computer of the industrial computer only transmits the information of defective bearing ring workpieces to the cloud platform to reduce traffic and power consumption, or sets automatic upload of abnormal pictures and logs to realize cloud viewing of the inspection station.
[0013] In the step S2, for each type of defect-free bearing ring, the end face image of the defect-free bearing ring is subjected to region of interest ROI extraction. It is necessary to extract the contours of the bearing ring workpieces of different types to achieve accurate positioning of the ROI area, and avoid the introduction or loss of pixels due to inaccurate extraction, thereby causing missed detection and false detection. The details are as follows:
[0014] S2.1: First, the end face image of the bearing ring with a clean surface and no defects under factory imaging conditions is grayed out, and then the end face of the bearing ring in the image is selected using a rectangular frame to obtain an end face framed image. The frame selection operation is used to reduce the impact of the introduction of the background area on contour recognition.
[0015] The collected end face image of the bearing ring is grayed out, and the three-channel image becomes a single channel, making data processing simpler. The graying adopts the weighted average method, and finally the three-channel pixel values of each pixel point of the color image are merged into a single-channel gray value.
[0016] S2.2: Binarize and segment the end face frame image to obtain the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring.
[0017] S2.3: Extract the region of interest (ROI) based on the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring, thereby determining the standard circles of the inner and outer rings of the end face of the defect-free bearing ring and their radius and center coordinates, and finally determine the template circle of the end face of the defect-free bearing ring, completing the extraction of the region of interest (ROI) of the end face image of the defect-free bearing ring under the current model.
[0018] In the step S3, the region of interest ROI of the end face images of defect-free bearing rings of different models and the end face image of the bearing ring to be tested are matched by end face positioning based on standard circle matching. Specifically, the end face image of the bearing ring to be tested is firstly binary segmented to obtain several circumscribed circles of the end face, and then the circumscribed circles of the end face image of the bearing ring to be tested are matched with the radius of the region of interest ROI of the end face image of the defect-free bearing ring of each model by standard circle, so as to determine the maximum circumscribed circle of the end face image of the bearing ring to be tested in each circumscribed circle, and then determine the model of the bearing ring to be tested, so as to match the region of interest ROI of the end face image of the defect-free bearing ring under the corresponding model to the end face image of the bearing ring to be tested according to the center coordinates, and complete the end face positioning matching of the bearing ring to be tested.
[0019] The standard circle matching of each circumscribed circle of the end face image of the bearing ring to be inspected and the radius of the region of interest ROI of the end face image of each model of defect-free bearing ring is specifically for each circumscribed circle of the end face of the bearing ring to be inspected and the region of interest ROI of the end face image of each model of defect-free bearing ring, the radius of the circumscribed circle and the radius of the region of interest ROI are matched and determined according to the following optimal radius condition:
[0020]
[0021] Among them, r new is the radius of the circumscribed circle of the end face of the bearing ring to be tested; r0 is the outer ring radius or inner ring radius of the region of interest ROI; The minimum error of the preset radius.
[0022] When the optimal radius condition is met, the bearing ring to be tested is determined to be the current model; when the optimal radius condition is not met, the optimal radius condition determination of the next model is continued until the model of the bearing ring to be tested is determined and the standard circle matching is completed.
[0023] In the step S3, the end face image of the bearing ring to be inspected after the end face positioning and matching is converted into a rectangular image after polar coordinate conversion and linear interpolation in sequence, and then the defect area is preprocessed. Specifically, an adaptive gamma transform is first performed according to the different surface reflective characteristics of different models, and then a texture removal method based on gradient fusion non-local mean is used to suppress and eliminate the metal texture, and the initial defect area of the suspected defect is extracted. Then, the iterative adaptive threshold segmentation method and the multi-feature discrimination method are used to further segment and screen the initial defect area, and finally the defect area is located, thereby achieving precise positioning and detection of the defect.
[0024] When the rectangular image is subjected to adaptive gamma transformation, the average brightness μ and the brightness standard deviation σ of the rectangular image are first obtained, thereby introducing a dynamic adjustment factor k, k=σ / μ, and adjusting the γ dynamic factor of the adaptive gamma transformation through the dynamic adjustment factor k, thereby performing adaptive gamma transformation on the rectangular image, and realizing dynamic adjustment of the end face image based on brightness. The γ dynamic factor is as follows:
[0025]
[0026] Performs adaptive gamma transformation on rectangular images according to the adjusted gamma dynamic factor.
[0027] The texture removal method based on gradient fusion non-local mean is processed, specifically, first using two 7*7 sobel operators to obtain the horizontal and vertical gradients of the rectangular image after adaptive gamma transformation, and then normalizing it, and then converting the horizontal and vertical gradients of each pixel in the rectangular image into energy gradients through energy gradient conversion, and then taking the area where the pixels with energy gradients higher than the preset energy gradient threshold are located as the high-energy area, and using the seed filling algorithm to fill the high-energy area, so as to fill the internal area of the high-energy area as the reserved area, and taking the remaining texture feature areas without defects as the elimination area, and using the non-local mean filtering denoising algorithm to perform regional inversion smoothing elimination on the elimination area, and finally extracting the initial defect area of the suspected defect.
[0028] The present invention adopts visual image processing algorithm technology to judge the image appearance defects of the bearing ring workpiece, and at the same time builds a machine vision online defect detection system to identify and acquire the workpiece containing defects, thereby realizing non-contact workpiece appearance quality detection, which can be specifically applied to the quality detection of the appearance of the bearing ring end face.
[0029] The beneficial effects of the present invention are:
[0030] The modules of the defect detection system of the present invention are easy to install and adjust, with low cost, and can detect and record defective workpieces of bearing rings in real time. The defect detection system combines machine vision technology to collect the end face image of the bearing ring, and combines the image processing algorithm to detect and screen the bearing rings with defects, and realizes real-time detection and recording of the bearing rings through the host computer. Through remote control and data exchange with the cloud platform, it can realize real-time detection and automatic backup transmission of the bearing rings, reduce the false detection rate, and achieve the purpose of automatic detection. The method of the present invention is universal for various models of bearing rings, and has the characteristics of high detection accuracy and high speed, which meets the requirements of on-site real-time detection of bearing ring production lines, and can be used as a method in the actual production process of bearings. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 This is the overall architecture diagram of the visual bearing ring end face defect detection system of the present invention;
[0032] Figure 2 It is a hardware position diagram of the visual bearing ring end face defect detection system of the present invention;
[0033] Figure 3 Provides an overall flow chart of end face defect detection for the present invention;
[0034] Figure 4 The schematic diagram of obtaining ROI positioning based on standard part circle matching for different types of bearing ring workpieces provided by the present invention, wherein: Figure 4 (a) is a schematic diagram of obtaining ROI positioning of a 53-40-23 model bearing ring workpiece based on standard part circle matching. Figure 4 (b) is a schematic diagram of obtaining ROI positioning of a 37-26-16 model bearing ring workpiece based on standard part circle matching. Figure 4 (c) is a schematic diagram of obtaining ROI positioning of a 43-30-14 model bearing ring workpiece based on standard part circle matching;
[0035] Figure 5 The polar coordinate conversion diagram provided by the present invention, wherein: Figure 5 (a) is the coordinate transformation principle diagram. Figure 5 (b) Actual effect diagram of polar coordinate transformation of bearing ring end face;
[0036] Figure 6 This is a schematic diagram of the polar coordinate conversion of the end face ring area provided by the present invention;
[0037] In the figure: 1. bearing ring, 2. area array CCD industrial camera, 3. fixed-focus lens, 4. coaxial light source, 5. semi-transparent reflector, 6. storage platform, 7. industrial computer, 71. controller, 72. host computer, 8. cloud platform. DETAILED DESCRIPTION
[0038] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings in the embodiments of the present invention.
[0039] like Figure 3 As shown, the bearing ring end face defect detection method based on vision of the present invention is as follows:
[0040] S1: Construct an end face defect detection system for the bearing ring 1, and collect end face images of defect-free bearing rings 1 of different models through the end face defect detection system, such as Figure 1 and Figure 2As shown, the end face defect detection system of the bearing ring 3 includes a 500W area array CCD (Charge Coupled Device) industrial camera 2, a white coaxial light source 4, a semi-transparent reflector 5, a storage platform 6, an industrial computer 7 and a cloud platform 8. The bearing ring 1 is placed horizontally on the storage platform 6 with the end face to be collected facing upward. The area array CCD industrial camera 2, the semi-transparent reflector 5 and the bearing ring 1 are arranged in sequence from top to bottom. The 16mm fixed-focus lens 3 of the area array CCD industrial camera 2 is vertically downward toward the semi-transparent reflector 5, and the coaxial light source 4 is located on one side of the semi-transparent reflector 5; the industrial computer 7 includes a programmable controller 71 and a host computer 72 connected in sequence, and the controller 71 is electrically connected to the area array CCD industrial camera 2. Camera 2 and host computer 72 are wirelessly connected to cloud platform 8; coaxial light source 4 emits horizontal white light source to semi-transparent reflector 5, and then reflects to generate vertically downward incident light to the end face of bearing ring 1. The reflected light of the end face of bearing ring 1 is transmitted through semi-transparent reflector 5 and then captured by fixed focus lens 3 of area array CCD industrial camera 2 for end face image of bearing ring 1, and then transmitted to controller 71 of industrial computer 7 and host computer 72 for region of interest ROI extraction, matching, polar coordinate conversion and defect area preprocessing, and then defect detection processing is performed, and finally uploaded to cloud platform 8 for storage and monitoring.
[0041] The image acquisition part of the end face defect detection system includes an array CCD industrial camera 2, a coaxial light source 4, a semi-transparent reflector 5 and a storage platform 6. The industrial computer 7 includes a controller 71 and a host computer 72 that establish a communication connection with the image acquisition part. After the bearing ring 1 reaches the specified position on the production line, the coaxial light source 4 is illuminated, and the host computer 72 of the industrial computer 7 controls the array CCD industrial camera 2 to acquire images. The controller 71 and the host computer 72 mainly perform real-time monitoring of the bearing ring 1 and store and log abnormal images of the bearing ring 1, and upload them to the cloud platform 8; the cloud platform 8 is used to receive the end face image of the bearing ring 1 collected by the bearing detection station and the information cloud platform 8 can also receive conventional data such as photos and model size information of abnormal bearing ring 1 workpieces, which can realize cloud-based automated detection of the bearing ring 1 workpiece production line and can perform maintenance in a timely manner. In normal mode, the host computer 72 of the industrial computer 7 only transmits the information of the defective bearing ring 1 workpiece to the cloud platform to reduce traffic and power consumption, or sets automatic uploading of abnormal pictures and logs to realize cloud viewing of the inspection station.
[0042] S2: Use the end face defect detection system to extract the region of interest (ROI) of the end face images of defect-free bearing rings 1 of different models. For each type of defect-free bearing ring 1, the end face image of the defect-free bearing ring 1 is subjected to ROI extraction. It is necessary to extract the contours of the workpieces of the bearing rings 1 of different models to achieve accurate positioning of the ROI area, and avoid the introduction or loss of pixels due to inaccurate extraction, thereby causing missed detection and false detection. The details are as follows:
[0043] S2.1: First, the end face image of the bearing ring 1 with a neat surface and no defects under factory imaging conditions is grayed out, and then the end face of the bearing ring 1 in the image is selected using a rectangular frame to obtain an end face framed image. The frame selection operation is used to reduce the influence of the introduction of the background area on contour recognition.
[0044] The collected end face image of the bearing ring 1 is grayed, and the three-channel image is converted into a single channel, making data processing simpler. The graying adopts the weighted average method, and finally the three-channel pixel values of each pixel point of the color image are merged into a single-channel gray value.
[0045] S2.2: Binarize and segment the end face frame image to obtain the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring 1; the Canny contour edge extraction algorithm is used in the specific implementation.
[0046] S2.3: Extract the region of interest (ROI) based on the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring 1, thereby determining the inner and outer standard circles of the end face of the defect-free bearing ring 1 and their radius and center coordinates, and finally determine the template circle of the end face of the defect-free bearing ring 1, and complete the extraction of the region of interest (ROI) of the end face image of the defect-free bearing ring 1 under the current model. Figure 4 (a) Figure 4 (b) and Figure 4 As shown in (c), the ROI positioning results of the bearing ring workpieces of models 53-40-23, 37-26-16 and 43-30-14 are obtained based on the standard part circle matching.
[0047] S3: Use the end face defect detection system to collect the end face image of the bearing ring 1 to be inspected on the production line, and use the end face positioning matching based on standard circle matching between the region of interest (ROI) of the end face image of the defect-free bearing ring 1 of different models and the end face image of the bearing ring 1 to be inspected, and then perform polar coordinate conversion and linear interpolation in sequence, and then perform defect area preprocessing to locate the defect area, and finally realize the defect detection of the end face of the bearing ring.
[0048] The region of interest ROI of the end face image of the defect-free bearing ring 1 of different models and the end face image of the bearing ring 1 to be tested are positioned and matched based on standard circle matching. Specifically, the end face image of the bearing ring 1 to be tested is firstly binarized and segmented to obtain several circumscribed circles of the end face, and then each circumscribed circle of the end face image of the bearing ring 1 to be tested is matched with the radius of the region of interest ROI of the end face image of the defect-free bearing ring 1 of each model by standard circle matching, so as to determine the maximum circumscribed circle of the end face image of the bearing ring 1 to be tested in each circumscribed circle, and then determine the model of the bearing ring 1 to be tested, so as to match the region of interest ROI of the end face image of the defect-free bearing ring 1 under the corresponding model to the end face image of the bearing ring 1 to be tested according to the center coordinates, and complete the end face positioning matching of the bearing ring 1 to be tested.
[0049] Standard circle matching is performed on each circumscribed circle of the end face image of the bearing ring 1 to be tested and the radius of the region of interest ROI of the end face image of each model of defect-free bearing ring 1. Specifically, for each circumscribed circle of the end face of the bearing ring 1 to be tested and the region of interest ROI of the end face image of each model of defect-free bearing ring 1, the radius of the circumscribed circle and the radius of the region of interest ROI are matched and determined according to the following optimal radius conditions:
[0050]
[0051] Among them, r new is the radius of the circumscribed circle of the end face of the bearing ring 1 to be detected; r0 is the outer ring radius or inner ring radius of the region of interest ROI; The minimum error of the preset radius.
[0052] When the optimal radius condition is met, the bearing ring 1 to be tested is determined to be the current model; when the optimal radius condition is not met, the optimal radius condition determination of the next model is continued until the model of the bearing ring 1 to be tested is determined and the standard circle matching is completed.
[0053] The method of the present invention aims at the problem of difficulty in extracting the bearing ROI area during the detection of end face defects of the bearing ring 1, and adopts the ROI extraction and matching method of the standard workpiece circle matching, which solves the problem of introducing or losing pixels in the detection area caused by the different distribution positions of defects and the narrow end face area of the bearing ring 1. The radius condition judgment ensures the precise positioning of the end face area and realizes the regional positioning of the bearing ring 1 workpiece at the detection station. Compared with the traditional contour fitting to obtain the ROI area, the above steps effectively overcome the problems of difficulty in ROI extraction and inaccurate end face pixel fitting caused by the narrow end face area of the bearing ring 1 and the complex background, and can be adapted to different models of bearing ring 1 workpieces.
[0054] The end face image of the bearing ring 1 to be inspected is converted into a rectangular image after polar coordinate conversion and linear interpolation. The result after polar coordinate conversion is as follows: Figure 6 As shown in the figure, the defect area is preprocessed, specifically, an adaptive gamma transform is first performed according to the different surface reflective characteristics of different models, and then a texture removal method based on the gradient fusion non-local mean is used to suppress and eliminate the metal texture, and the initial defect area of the suspected defect is extracted. Then, the iterative adaptive threshold segmentation method and the multi-feature discrimination method are used to further segment and screen the initial defect area, and finally the defect area is located, thereby achieving precise positioning and detection of the defect.
[0055] like Figure 5 (a) and Figure 5 As shown in (b), polar coordinate transformation is performed. First, the entire end face is transformed into a rectangular image through polar coordinate transformation. The outer circumference of the end face is set as the width of the rectangular image after transformation, and the difference between the outer radius and the inner radius is set as the height of the rectangular image after transformation. The specific transformation is as follows:
[0056] θ=uμ θ ,ρ=vμ l +r
[0057] x=ρcosθ+r x , y = ρ sin θ - r y
[0058] Φ′(u,v)=Φ(x,y)
[0059] Among them, θ is the polar angle of the point; ρ is the polar diameter of the point; u and v are the relative distances of the point P on the end surface of the bearing ring 1 to be tested to the center of the circle r x , r y Polar angle and polar diameter; μ θ and μ l are the polar coordinate angle scale factor and the polar diameter conversion scale factor, μ θ =2π / L,μ l =(Rr) / H, L and H are the length and width of the rectangular image, R and r are the outer diameter and inner diameter of the workpiece circle, x and y are the horizontal and vertical distances from point P to the origin O, Φ′(u, v) is the pixel value of the rectangular image, and Φ(x, y) is the adjacent difference in the rectangular coordinate system.
[0060] When the rectangular image is subjected to adaptive gamma transformation, the average brightness μ and brightness standard deviation σ of the rectangular image are first obtained, thereby introducing a dynamic adjustment factor k, k = σ / μ. The γ dynamic factor of the adaptive gamma transformation is adjusted by the dynamic adjustment factor k, thereby performing adaptive gamma transformation on the rectangular image and realizing dynamic adjustment of the end face image based on brightness. The γ dynamic factor is as follows:
[0061]
[0062] Performs adaptive gamma transformation on rectangular images according to the adjusted gamma dynamic factor.
[0063] The dynamic adjustment factor k combines the information of the brightness standard deviation and the average brightness. Log128 is used to normalize the logarithmic value of the average brightness. 1+σ / μ is an amplification factor.
[0064] Adaptive gamma transform ensures dynamic adjustment of the end face brightness under different lighting environments. The brightness of the defective area and the normal area is improved, and the detail changes are more significant, which reduces the influence of some irrelevant features and is more conducive to the subsequent energy gradient analysis irrelevant feature elimination processing.
[0065] Since the collected end face images of the bearing ring 1 have different texture features, considering the reflective characteristics of the end face surface of the bearing ring 1, the process of acquiring the images of the bearing ring 1 workpieces of different batches and models requires the brightness of the light source to be readjusted in order to balance the imaging effect between the defective area and the normal area. Therefore, an adaptive gamma transform method is proposed to realize the dynamic adjustment of the end face based on brightness.
[0066] A texture removal method based on gradient fusion and non-local mean is used for processing. Specifically, two 7*7 sobel operators are first used to obtain the horizontal and vertical gradients of the rectangular image after adaptive gamma transformation, and then normalization is performed. The horizontal and vertical gradients of each pixel in the rectangular image are converted into energy gradients through energy gradient conversion. The area where the pixels with energy gradients higher than the preset energy gradient threshold are located is taken as the high-energy area, and the high-energy area is filled with a seed filling algorithm to fill the internal area of the high-energy area as the retained area, and the remaining texture feature areas without defects are taken as the elimination areas. The elimination areas are subjected to regional inversion and smoothing elimination processing using a non-local mean filtering denoising algorithm, and finally the initial defect area of the suspected defect is extracted.
[0067] The gamma-transformed rectangular image of the bearing end face is subjected to the irrelevant feature elimination algorithm proposed in the present invention. The irrelevant features mainly come from the metal texture area existing in the production and processing of the bearing ring 1. These texture features are relatively complex and will affect the detection of subsequent defects, so the irrelevant features need to be removed. The image gradient refers to the rate of change of the image grayscale value, which reflects the change of the pixel value in the image. Calculating the image gradient can determine the area with significant feature changes on the surface of the bearing ring 1 workpiece, and the defect area shows a more obvious gradient change, and distinguish the suspected defect area from the texture feature.
[0068] By analyzing the texture of the end face of the bearing ring 1, the image similarity can be obtained. By adjusting the filter strength parameter h and the size of the window, the regional similarity can be obtained to analyze the texture and image structure, and the texture can be suppressed and smoothed to select the appropriate scale parameter to obtain the appropriate parameters for eliminating the texture. Using the scale parameter, the non-local mean filter denoising algorithm is used to eliminate the irrelevant feature texture smoothing process for the elimination area with gradient anomaly.
[0069] The bearing end faces with obvious metal texture features are smoothed out to eliminate irrelevant features while avoiding pixel loss in the defective area, thereby eliminating irrelevant features such as texture and retaining details in the defective area.
[0070] Then, the iterative adaptive threshold segmentation method and multi-feature discrimination method are used to further segment and screen the initial defect area. Specifically, the average gray value of the image with the initial defect area extracted is first obtained as the initial threshold, and then the image is divided into foreground and background areas by using the initial threshold. Then, a new gray threshold T is obtained. new , T new =(μ F +μ B ) / 2,μ F is the average grayscale threshold of the foreground area, μ B is the average gray value of the background area. Then, the iterative approximation is continuously performed until |T new -T0|<ε, T0 is the average gray value of the initial threshold, ε is the approximation coefficient, which is generally set to 0.5, to achieve defect segmentation for the suspected area. By locating the segmented defects, the contours are drawn to obtain the segmented area of the suspected defect area. The segmented defect area is feature analyzed, and the defect area is identified by combining the gray range threshold, the maximum circumscribed rectangle area range threshold, and the defect area range threshold.
[0071] Finally, the real-time image and information of the bearing ring 1 workpiece with defects detected are displayed in real time on the host computer software on the host computer 72, and the information log of the bearing ring 1 workpiece with defects is recorded. The host computer software interface collects the defect image and information log, and sends the detection data to the designated cloud platform 8 by wireless means.
[0072] Through the irrelevant feature elimination method, the metal texture of the end face is suppressed, the defect area is initially extracted, and the rest of the area is smoothly eliminated. An image containing only the suspected defect area is obtained. However, when the separated defect area is small, the pixels contained in the area are also small and the edge part is relatively blurred. Directly using a fixed global threshold or contour segmentation method cannot accurately segment these small areas, which will lead to the loss of pixel information in the defect area and thus cause false detection and missed detection.
[0073] The method of iterative threshold adaptive threshold segmentation is performed on the image of the extracted suspected defect area to achieve accurate positioning and segmentation of the defect area, and a multi-feature discrimination method is used to detect and discriminate defects. Finally, the discrimination of defect types and the screening of defective workpieces are achieved, and the positioning and segmentation of the defect location are achieved.
[0074] In view of the problems of difficulty in ROI extraction and large number of irrelevant surface texture features in bearing ring end face detection, the present invention proposes a vision-based bearing ring end face defect detection method, and designs and builds a visual defect detection system for the actual production line of bearing ring workpieces to realize online detection of bearing ring workpiece end face defects, which solves the problems of low degree of automation, strong subjectivity of manual observation and unsatisfactory detection accuracy in the prior art.
[0075] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A method for detecting bearing ring end face defects based on vision, characterized in that: include: S1: constructing an end surface defect detection system for a bearing ring (1), and collecting end surface images of defect-free bearing rings (1) of different models through the end surface defect detection system; S2: using an end face defect detection system to extract a region of interest (ROI) from end face images of defect-free bearing rings (1) of different models; S3: Use the end face defect detection system to collect the end face image of the bearing ring (1) to be inspected on the production line, and use the end face positioning matching based on standard circle matching between the region of interest (ROI) of the end face image of the defect-free bearing ring (1) of different models and the end face image of the bearing ring (1) to be inspected, and then perform polar coordinate conversion and linear interpolation in sequence, and then perform defect area preprocessing to locate the defect area, and finally realize the defect detection of the end face of the bearing ring.
2. The method for detecting bearing ring end face defects based on vision according to claim 1, characterized in that: In the step S1, the end face defect detection system of the bearing ring (3) comprises an array CCD industrial camera (2), a coaxial light source (4), a semi-transparent reflector (5), a storage platform (6), an industrial computer (7) and a cloud platform (8); the bearing ring (1) is horizontally placed on the storage platform (6) with the end face to be collected facing upward; the array CCD industrial camera (2), the semi-transparent reflector (5) and the bearing ring (1) are arranged in sequence from top to bottom; the fixed focus lens (3) of the array CCD industrial camera (2) is vertically downward toward the semi-transparent reflector (5); the coaxial light source (4) is located on one side of the semi-transparent reflector (5); the industrial computer (7) comprises a controller (71) and a host computer (72) connected in sequence; the controller ( 71) is electrically connected to a planar array CCD industrial camera (2), and a host computer (72) is wirelessly connected to a cloud platform (8); a coaxial light source (4) emits a horizontal white light source to a semi-transparent reflector (5), which then reflects to generate vertically downward incident light to the end face of the bearing ring (1); the reflected light from the end face of the bearing ring (1) is transmitted through the semi-transparent reflector (5) and then captured by a fixed-focus lens (3) of the planar array CCD industrial camera (2) to obtain an end face image of the bearing ring (1), which is then transmitted to a controller (71) of an industrial computer (7) and a host computer (72) to extract, match, transform polar coordinates, and pre-process defect areas in a region of interest (ROI), and then perform defect detection processing, and finally upload the image to a cloud platform (8) for storage and monitoring.
3. The method for detecting bearing ring end face defects based on vision according to claim 1, characterized in that: In the step S2, for each type of defect-free bearing ring (1), a region of interest (ROI) is extracted from the end surface image of the defect-free bearing ring (1), specifically as follows: S2.1: firstly, grayscale processing is performed on the end face image of the defect-free bearing ring (1), and then the end face of the bearing ring (1) in the image is selected using a rectangular frame to obtain an end face frame selected image; S2.2: Binarize and segment the end face frame image to obtain the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring (1); S2.3: Extract the region of interest (ROI) based on the maximum circumscribed circle of the standard circle of the end face of the defect-free bearing ring (1), thereby determining the inner and outer ring standard circles of the end face of the defect-free bearing ring (1) and their radius and center coordinates, and complete the region of interest (ROI) extraction of the end face image of the defect-free bearing ring (1) under the current model.
4. The method for detecting bearing ring end face defects based on vision according to claim 1, characterized in that: In the step S3, the regions of interest (ROI) of the end face images of the defect-free bearing rings (1) of different models and the end face images of the bearing rings (1) to be tested are matched by end face positioning based on standard circle matching. Specifically, the end face images of the bearing rings (1) to be tested are firstly subjected to binary segmentation to obtain a plurality of circumscribed circles of the end face, and then the circumscribed circles of the end face images of the bearing rings (1) to be tested are matched with the radii of the regions of interest (ROI) of the end face images of the defect-free bearing rings (1) of various models by standard circle matching, thereby determining the maximum circumscribed circle of the end face image of the bearing rings (1) to be tested in each circumscribed circle, and then determining the model of the bearing rings (1) to be tested, thereby matching the regions of interest (ROI) of the end face images of the defect-free bearing rings (1) of the corresponding model to the end face images of the bearing rings (1) to be tested according to the center coordinates, and completing the end face positioning matching of the bearing rings (1) to be tested.
5. The method for detecting bearing ring end surface defects based on vision according to claim 4 is characterized in that: The method of performing standard circle matching on each circumscribed circle of the end face image of the bearing ring (1) to be inspected and the radius of the region of interest ROI of the end face image of each model of defect-free bearing ring (1) is as follows: for each circumscribed circle of the end face of the bearing ring (1) to be inspected and the region of interest ROI of the end face image of each model of defect-free bearing ring (1), the radius of the circumscribed circle and the radius of the region of interest ROI are matched and determined according to the following optimal radius condition: Among them, r new is the radius of the circumscribed circle of the end face of the bearing ring (1) to be inspected; r0 is the outer ring radius or the inner ring radius of the region of interest ROI; is the minimum error of the preset radius; When the optimal radius condition is met, the bearing ring (1) to be tested is determined to be the current model; when the optimal radius condition is not met, the optimal radius condition determination of the next model is continued until the model of the bearing ring (1) to be tested is determined, and the standard circle matching is completed.
6. The method for detecting bearing ring end surface defects based on vision according to claim 1, characterized in that: In the step S3, the end face image of the bearing ring (1) to be inspected, after the end face positioning and matching is completed, is converted into a rectangular image after polar coordinate conversion and linear interpolation in sequence, and then the defect area is preprocessed, specifically, firstly an adaptive gamma transform is performed, and then a texture removal method based on gradient fusion non-local mean is used to extract the initial defect area, and then an iterative adaptive threshold segmentation method and a multi-feature discrimination method are used to further segment and screen the initial defect area, and finally the defect area is located.
7. The method for detecting bearing ring end surface defects based on vision according to claim 6 is characterized in that: When the rectangular image is subjected to adaptive gamma transformation, the average brightness μ and the brightness standard deviation σ of the rectangular image are first obtained, thereby introducing a dynamic adjustment factor k, k=σ / μ, and adjusting the γ dynamic factor of the adaptive gamma transformation by the dynamic adjustment factor k, thereby performing adaptive gamma transformation on the rectangular image. The γ dynamic factor is as follows: Performs adaptive gamma transformation on rectangular images according to the adjusted gamma dynamic factor.
8. The method for detecting bearing ring end surface defects based on vision according to claim 6, characterized in that: The texture removal method based on gradient fusion non-local mean is processed, specifically, first using two sobel operators to obtain the horizontal and vertical gradients of the rectangular image after adaptive gamma transformation, and then normalizing it, and then converting the horizontal and vertical gradients of each pixel in the rectangular image into energy gradients through energy gradient conversion, and then taking the area where the pixels with energy gradients higher than the preset energy gradient threshold are located as the high-energy area, filling the high-energy area with a seed filling algorithm as the reserved area, and taking the remaining area as the elimination area, and performing regional inversion and smoothing elimination on the elimination area using a non-local mean filtering denoising algorithm, and finally extracting the initial defect area.
Citation Information
Patent Citations
Small bearing quality detection method, device and system based on machine vision
CN110246122A
Bearing quality detection method based on machine vision
CN112308832A
Method and device for detecting smooth abrasion of bearing end face based on stroboscopic light source
CN116051541A
Ferrule endface inspecting device and method for optical communication modules
US20180100811A1
Cited By
Nondestructive testing method and system for internal defects of bearing sealing structure
CN121504922A