Permanent magnet defect detection method, device, equipment and medium

By acquiring the detection image and depth image of the permanent magnet and using machine vision recognition technology to identify the uniformity of the glue layer thickness and the concave-convex condition of the multi-pole annular permanent magnet, the problem of low detection accuracy is solved and efficient and accurate defect detection is achieved.

CN120741479AActive Publication Date: 2025-10-03HIGH MAG TECH (SHENZHEN) CO LTD

Patent Information

Application Number
CN202511135655.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-14
Publication Date
2025-10-03
Estimated Expiration
2045-08-14

AI Technical Summary

Technical Problem

The existing defect detection method for multi-pole annular permanent magnets has low detection accuracy, which affects production efficiency.

Method used

By acquiring the detection image and depth image of the permanent magnet, machine vision recognition technology is used to identify the thickness uniformity and concave-convex conditions of the adhesive layer, a threshold is set to determine the defect type, and defective products are graded and marked.

Benefits of technology

It improves the accuracy and efficiency of defect detection, avoids repeated detection, and ensures the accuracy and efficiency of detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120741479A_ABST
    Figure CN120741479A_ABST
Patent Text Reader

Abstract

The invention discloses a permanent magnet defect detection method, apparatus and device, and a medium. The method comprises the following steps: obtaining a detection image of a target end of a target permanent magnet; wherein the target end is one end of the target permanent magnet with the permanent magnet block; obtaining a first defect feature value according to the detection image; wherein the first defect characteristic value is used for representing the defect degree of the thickness uniformity of the adhesive layer; judging whether the first defect characteristic value is greater than a preset first threshold value or not; if yes, marking the target permanent magnet as a first type of defective product, and if not, acquiring a depth image of a target end of the target permanent magnet; acquiring a second defect feature value according to the depth image; wherein the second defect characteristic value is used for representing the protruding or sinking degree of the adhesive layer; judging whether the second defect characteristic value is greater than a preset second threshold value or not; if yes, the target permanent magnet is marked as a second type of defective product, if not, the target permanent magnet is marked as a qualified product, and the permanent magnet defect detection method and device have the advantage that the permanent magnet defect detection precision is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image data processing technology, and in particular to a method, device, equipment and medium for detecting defects in a permanent magnet. Background Art

[0002] Magnets that can maintain their magnetism for a long time are called permanent magnets (abbreviated as permanent magnets), such as natural magnets (magnetite) and artificial magnets (aluminum-nickel-cobalt alloy). Permanent magnets vary in structure depending on their application. One type of permanent magnet, a multi-pole annular permanent magnet, boasts a high magnetic field strength and superior performance. Its main body comprises a magnetic ring body with an inner core built into the center. Embedded within the ring body are multiple permanent magnets arranged in a circular array around the inner core. The permanent magnets are secured by a glue layer solidified from a glue liquid. However, during the glue solidification and molding process, the glue liquid flow, the glue coating process, and external factors (such as temperature and vibration) can easily cause defects such as glue overflow, glue sinking (i.e., the glue layer becomes concave after molding), and uneven thickness. Therefore, permanent magnets with this structure require defect inspection, and those that fail the inspection must be repaired.

[0003] Currently, defect detection methods for the above-mentioned multi-pole annular permanent magnets mainly rely on manual detection or simple tool detection, which has relatively low detection accuracy and affects detection efficiency, ultimately affecting production efficiency. Summary of the Invention

[0004] The main purpose of this application is to provide a permanent magnet defect detection method, device, equipment and medium, aiming to solve the technical problem of low detection accuracy of existing defect detection methods for multi-pole annular permanent magnets.

[0005] To achieve the above objectives, the present application provides a permanent magnet defect detection method, comprising the following steps: Acquire a detection image of a target end of a target permanent magnet; wherein the target permanent magnet includes a magnetic ring body, an inner core is built into the center of the magnetic ring body, a plurality of grooves are formed on one side of the magnetic ring body and are distributed in an annular array around the inner core, and permanent magnet blocks are fixed in place in the grooves by an adhesive layer, and the target end is the end of the target permanent magnet having the permanent magnet blocks; Obtaining a first defect characteristic value according to the detection image; wherein the first defect characteristic value is used to characterize the degree of uniformity defect in the thickness of the adhesive layer; Determining whether the first defect characteristic value is greater than a preset first threshold; If so, the target permanent magnet is marked as a first-category defective product; if not, a depth image of the target end of the target permanent magnet is acquired; Obtaining a second defect characteristic value according to the depth image; wherein the second defect characteristic value is used to characterize the degree of protrusion or depression of the adhesive layer; Determining whether the second defect characteristic value is greater than a preset second threshold; If so, the target permanent magnet is marked as a second-category defective product; if not, the target permanent magnet is marked as a qualified product.

[0006] Optionally, obtaining a first defect characteristic value according to the detection image includes: Obtaining the deviation angle θ of each permanent magnet block from the theoretical position in the detection image; Obtaining a first maximum value and determining whether the first maximum value is greater than a preset deflection angle threshold; wherein the first maximum value is the maximum value among a plurality of deflection angles θ; If so, the first maximum value is output as the first defect characteristic value; If not, obtaining a deviation characteristic evaluation value of all permanent magnets having deviation characteristics; The deviation feature evaluation value is output as the first defect feature value.

[0007] Optionally, obtaining a deviation characteristic evaluation value of all permanent magnets having deviation characteristics includes: Obtaining a deflection angle average value θ' of several deviation angles θ; Obtain the number n1 of permanent magnets having deviation characteristics; According to the average deflection angle θ' and the number n1 of permanent magnets with the deviation characteristic, a deviation characteristic evaluation value Q1 is obtained; wherein Q1=K1·n1·θ', K1 is a first adjustment coefficient.

[0008] Optionally, obtaining a deviation angle θ of each permanent magnet block from a theoretical position in the detection image includes: Identify the groove contour in the inspection image; Constructing a first symmetry line based on the groove profile; wherein the groove profile is symmetrical based on the first symmetry line, and the first symmetry line passes through the center of the circular profile of the magnetic ring body; Identifying the corresponding permanent magnet block profile located within the groove profile; Connect two symmetrical characteristic corner points in the outline of the permanent magnet block to obtain an auxiliary line; Constructing a second symmetry line based on the midpoint of the auxiliary line; wherein the second symmetry line and the auxiliary line are perpendicular to each other, and the outline of the permanent magnet block is symmetrical based on the second symmetry line; The included angle between the second symmetry line and the first symmetry line is output as a deviation angle θ.

[0009] Optionally, obtaining a second defect characteristic value according to the depth image includes: According to the depth image, identify the depth information of each glue layer area; Identify the concave-convex defect areas in each glue layer area based on the depth information; wherein the concave-convex defect areas include glue overflow areas and glue sinking areas; Obtaining a second maximum value and determining whether the second maximum value is greater than a preset concave-convex deviation threshold; wherein the second maximum value is the maximum absolute value of the difference between the limit depth value and the standard depth value of the concave-convex defect area, and the limit depth value is the most convex point depth value of the overflowed glue area or the most concave point depth value of the sunken glue area; If yes, the second maximum value is output as the second defect characteristic value; If not, obtaining the concave-convex feature evaluation value of all adhesive layers with concave-convex defect characteristics; The concavo-convex feature evaluation value is output as a second defect feature value.

[0010] Optionally, obtaining a comprehensive concave-convex feature evaluation value of all adhesive layers having concave-convex defect characteristics includes: Obtain the sum S of the areas of several concave and convex defect regions; Obtain the number n2 of adhesive layers with concave-convex defect characteristics; According to the sum of the areas S and the number of adhesive layers n2, the concave-convex feature evaluation value Q2 is obtained; wherein Q2=K2·n2·S, K2 is the second adjustment coefficient.

[0011] Optionally, before obtaining the concavo-convex feature evaluation value of all adhesive layers having concavo-convex defect features, the method further includes: Obtaining the area values ​​of several concave and convex defect regions respectively to obtain the maximum area value; Determine whether the maximum area value is greater than a preset area threshold; If so, the maximum area value is output as the second defect characteristic value; If not, proceed to the next step.

[0012] To achieve the above objectives, the present application also provides a permanent magnet defect detection device, comprising: a detection image acquisition module, configured to acquire a detection image of a target end of a target permanent magnet; wherein the target permanent magnet comprises a magnetic ring body, wherein an inner core is built into the center of the magnetic ring body, and a plurality of grooves are formed on one side of the magnetic ring body and distributed in an annular array around the inner core, wherein permanent magnet blocks are fixedly disposed in the grooves by an adhesive layer, and the target end is the end of the target permanent magnet having the permanent magnet blocks; A first feature acquisition module is used to acquire a first defect feature value based on the detection image; wherein the first defect feature value is used to characterize the degree of uniformity defect in the thickness of the adhesive layer; A first judgment module is used to judge whether the first defect characteristic value is greater than a preset first threshold; a first data processing module, configured to, if yes, mark the target permanent magnet as a first-category defective product; and, if no, acquire a depth image of a target end of the target permanent magnet; A second feature acquisition module is used to obtain a second defect feature value based on the depth image; wherein the second defect feature value is used to characterize the degree of protrusion or depression of the adhesive layer; A second judgment module is used to judge whether the second defect characteristic value is greater than a preset second threshold; The second data processing module is configured to mark the target permanent magnet as a second-category defective product if yes, and mark the target permanent magnet as a qualified product if no.

[0013] To achieve the above objectives, the present application also provides a computer device, which includes a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the above method.

[0014] To achieve the above objectives, the present application also provides a computer-readable storage medium, on which a computer program is stored. A processor executes the computer program to implement the above method.

[0015] The beneficial effects that this application can achieve are as follows: This application is based on obtaining a detection image of one end of the target permanent magnet having a permanent magnet block. The detection image also contains contour feature information such as the magnetic ring body, inner core, permanent magnet block and glue layer, so that the uniformity of the glue layer thickness can be identified by machine vision recognition technology, and the degree of the glue layer thickness uniformity defect can be quantified by the first defect characteristic value. At the same time, taking into account a certain allowable error, a first threshold is set here. When the first defect characteristic value is greater than the first threshold, the target permanent magnet can be marked as a first-class defective product, so that the staff can quickly repair it according to the defect type without having to search for the defect type. If the first defect characteristic value is less than or equal to the first threshold, the glue layer is further detected to see if there is glue overflow or glue sinking ( That is, the concave and convex situation), at this time, a depth image of the target end of the target permanent magnet can be obtained, and the depth image can include the distance information from each pixel point in the glue layer area to the camera, so as to characterize the concave and convex situation of the glue layer area, and quantify the degree of protrusion or depression of the glue layer through the second defect characteristic value. Also taking into account the allowable error, a second threshold is set here. When the second defect characteristic value is greater than the second threshold, the target permanent magnet is marked as a second-category defective product, so that the staff can perform targeted repairs according to the defect type. Otherwise, the target permanent magnet is marked as a qualified product, indicating that the target permanent magnet does not have the above two defects. In summary, the present application can effectively and accurately identify defects in the glue layer based on machine vision recognition technology, thereby improving the detection accuracy. At the same time, the present application first detects the uniformity of the glue layer thickness, and then detects the concave and convex condition of the glue layer area. This is because when the uniformity of the glue layer thickness does not meet the standard, the entire permanent magnet block and glue layer need to be removed and re-applied with glue to solidify, so there is no need to detect the concave and convex condition of the glue layer. Only when the uniformity of the glue layer thickness is met, the step of detecting the concave and convex condition of the glue layer is entered. If the concave and convex condition of the glue layer does not meet the standard, it is only necessary to fill the sunken glue or cut off the overflowed glue part, and there is no need to remove the glue layer. Therefore, the present application reasonably plans the defect type detection sequence, while ensuring detection accuracy, it also avoids repeated detection and ensures detection efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] To more clearly illustrate the specific embodiments of this application or the technical solutions in the prior art, the following briefly describes the drawings required for the specific embodiments or the description of the prior art. Similar elements or parts are generally identified by similar reference numerals throughout the drawings. Elements or parts in the drawings are not necessarily drawn to scale.

[0017] Figure 1 Schematic diagram of a flow chart of a permanent magnet defect detection method in an embodiment of the present application; Figure 2 Schematic diagram of the principle of obtaining the deviation angle θ based on the detection image in an embodiment of the present application; Figure 3 This is a schematic structural diagram of the adhesive layer in an embodiment of the present application when there is adhesive overflow; Figure 4 This is a schematic structural diagram of the adhesive layer having a sunken adhesive layer in an embodiment of the present application; Figure 5 This is a schematic diagram of identifying a region with concave-convex defects in an adhesive layer in an embodiment of the present application.

[0018] Reference numerals: 110 - magnetic ring body, 111 - groove, 120 - inner core, 130 - adhesive layer, 140 - permanent magnet block, 150 - first symmetry line, 160 - characteristic corner point, 170 - auxiliary line, 180 - second symmetry line, 190 - concave-convex defect area.

[0019] The realization of the objectives, functional features and advantages of this application will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0020] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments of this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0021] It should be noted that if there are descriptions involving "first", "second", etc. in the embodiments of the present application, the descriptions of "first", "second", etc. are only for descriptive purposes and cannot be understood as indicating or suggesting their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of such features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the fact that they can be implemented by ordinary technicians in this field. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such a combination of technical solutions does not exist and is not within the scope of protection required by this application.

[0022] Example 1: Reference Figure 1-Figure 5 , this embodiment provides a permanent magnet defect detection method, comprising the following steps: Acquire a detection image of the target end of the target permanent magnet; wherein the target permanent magnet includes a magnetic ring body 110, an inner core 120 is built into the center of the magnetic ring body 110, and a plurality of grooves 111 are formed on one side of the magnetic ring body 110 and distributed in an annular array around the inner core 120. A permanent magnet block 140 is fixedly disposed in the groove 111 by an adhesive layer 130. The target end is the end of the target permanent magnet having the permanent magnet block 140; Obtaining a first defect characteristic value according to the detection image; wherein the first defect characteristic value is used to characterize the degree of thickness uniformity defect of the adhesive layer 130; Determining whether the first defect characteristic value is greater than a preset first threshold; If so, the target permanent magnet is marked as a first-category defective product; if not, a depth image of the target end of the target permanent magnet is acquired; Obtaining a second defect characteristic value according to the depth image; wherein the second defect characteristic value is used to characterize the degree of protrusion or depression of the adhesive layer 130; Determining whether the second defect characteristic value is greater than a preset second threshold; If so, the target permanent magnet is marked as a second-category defective product; if not, the target permanent magnet is marked as a qualified product.

[0023] In this embodiment, a detection image is obtained based on the end of the target permanent magnet having the permanent magnet block 140. The detection image also includes contour feature information of the magnetic ring body 110, the inner core 120, the permanent magnet block 140 and the adhesive layer 130. Therefore, the thickness uniformity of the adhesive layer 130 can be identified by machine vision recognition technology, and the degree of the thickness uniformity defect of the adhesive layer 130 can be quantified by the first defect characteristic value. At the same time, taking into account a certain allowable error, a first threshold is set here. When the first defect characteristic value is greater than the first threshold, the target permanent magnet can be marked as a first-class defective product, so that the staff can quickly repair it according to the defect type without having to look for the defect type. If the first defect characteristic value is less than or equal to the first threshold, the adhesive layer 130 is further detected to see if there is overflow. In this case, a depth image of the target end of the target permanent magnet can be obtained. The depth image can include distance information from each pixel in the adhesive layer 130 area to the camera, thereby characterizing the concave-convex condition of the adhesive layer 130 area and quantifying the degree of protrusion or depression of the adhesive layer 130 using the second defect characteristic value. Also taking into account the allowable error, a second threshold is set here. When the second defect characteristic value is greater than the second threshold, the target permanent magnet is marked as a second-category defective product, so that staff can perform targeted repairs based on the defect type. Otherwise, the target permanent magnet is marked as a qualified product, indicating that the target permanent magnet does not have the above two defects. In summary, this embodiment can effectively and accurately identify defects in the adhesive layer 130 based on machine vision recognition technology, thereby improving detection accuracy. At the same time, the present embodiment first detects the thickness uniformity of the adhesive layer 130, and then detects the concave-convex condition of the adhesive layer 130 area. This is because when the thickness uniformity of the adhesive layer 130 does not meet the standard, the entire permanent magnet block 140 and the adhesive layer 130 need to be removed and re-applied with glue to solidify, so there is no need to further detect the concave-convex condition of the adhesive layer 130. Only when the thickness uniformity of the adhesive layer 130 is met, the step of detecting the concave-convex condition of the adhesive layer 130 is entered. If the concave-convex condition of the adhesive layer 130 does not meet the standard, it is only necessary to fill the sunken adhesive or cut off the overflowed adhesive portion, without removing the adhesive layer 130. Therefore, the present embodiment reasonably plans the defect type detection sequence, while ensuring detection accuracy, avoiding repeated detection and ensuring detection efficiency.

[0024] As an optional implementation manner, obtaining the first defect characteristic value according to the detection image includes: Obtaining a deviation angle θ of each permanent magnet block 140 from a theoretical position in the detection image; Obtaining a first maximum value and determining whether the first maximum value is greater than a preset deflection angle threshold; wherein the first maximum value is the maximum value among a plurality of deflection angles θ; If so, the first maximum value is output as the first defect characteristic value; If not, obtaining a deviation characteristic evaluation value of all permanent magnets having deviation characteristics; The deviation feature evaluation value is output as the first defect feature value.

[0025] In this embodiment, when the thickness uniformity of the adhesive layer 130 is poor, the permanent magnet block 140 will obviously deviate from its theoretical position. Therefore, the thickness uniformity of the adhesive layer 130 can be indirectly characterized by calculating the deviation angle θ of the permanent magnet block 140 from the theoretical position. If the thickness of the adhesive layer 130 is directly calculated, since the adhesive layer 130 needs to wrap the outer periphery of the permanent magnet block 140 and its shape is not linear, it is difficult to accurately calculate the thickness of each area of ​​the adhesive layer 130, and the calculation amount is large and the calculation efficiency is low. Therefore, this embodiment uses the deviation angle θ to indirectly characterize the thickness uniformity of the adhesive layer 130 more accurately and efficiently. After calculating several deviation angles θ, the more representative first maximum value is screened out, and it is determined whether the first maximum value is greater than a preset deflection angle threshold (the deflection angle threshold is the minimum allowable deviation angle). If so, the first maximum value is output as a first defect. The characteristic value is then compared with the first threshold (in this case, the first threshold is the maximum allowable deviation angle). If not, and considering that although the thickness uniformity of the multiple adhesive layers 130 meets the standard, a large number of thickness uniformity defect characteristics exist, which will also affect the overall performance, a comprehensive evaluation of the overall thickness uniformity is also performed here. The deviation characteristic evaluation value is output as the first defect characteristic value to quantitatively assess the overall thickness uniformity of the multiple adhesive layers 130 (in this case, the first threshold is the first evaluation threshold for the deviation characteristic evaluation value, which is used to represent the minimum defect level of the overall thickness uniformity of the multiple adhesive layers 130). By calculating the first defect characteristic value in a graded manner, a comprehensive assessment can be performed from two dimensions: obvious defects in the thickness uniformity of a single adhesive layer 130 and the overall defect distribution of the multiple adhesive layers 130, thereby improving the detection accuracy of the thickness uniformity of the adhesive layers 130.

[0026] It should be noted that the above-mentioned first threshold includes two threshold parameters, namely, the maximum deviation angle and the first evaluation threshold. The corresponding threshold parameters can be adapted and compared according to the attributes of the output first defect characteristic value.

[0027] As an optional implementation, obtaining a deviation characteristic evaluation value of all permanent magnets having deviation characteristics includes: Obtaining a deflection angle average value θ' of several deviation angles θ; Obtain the number n1 of permanent magnets having deviation characteristics; According to the average deflection angle θ' and the number n1 of permanent magnets with the deviation characteristic, a deviation characteristic evaluation value Q1 is obtained; wherein Q1=K1·n1·θ', K1 is a first adjustment coefficient.

[0028] In this embodiment, when quantitatively calculating the deviation characteristic evaluation value, the product of two key parameters, the average deviation angle θ' of several deviation angles θ and the number n1 of permanent magnets with the deviation characteristic, is used for assessment, which is more targeted and representative. At the same time, the first adjustment coefficient K1 is used to adjust the two different attribute parameters, the average deviation angle θ' or the number n1 of permanent magnets, so as to control the final result value (i.e., the deviation characteristic evaluation value Q1) within a reasonable range, facilitating subsequent effective data comparison, thereby achieving an overall evaluation and assessment of the thickness uniformity of the multiple adhesive layers 130.

[0029] As an optional implementation manner, obtaining the deviation angle θ of each permanent magnet block 140 from the theoretical position in the detection image includes: Identify the groove contour in the inspection image; A first symmetry line 150 is constructed based on the groove profile; wherein the groove profile is symmetrical based on the first symmetry line 150, and the first symmetry line 150 passes through the center of the circular profile of the magnetic ring body 110; Identifying the corresponding permanent magnet block profile located within the groove profile; Connect two mutually symmetrical characteristic corner points 160 in the outline of the permanent magnet block to obtain an auxiliary line 170; A second symmetry line 180 is constructed based on the midpoint of the auxiliary line 170 ; wherein the second symmetry line 180 and the auxiliary line 170 are perpendicular to each other, and the profile of the permanent magnet block is symmetrical based on the second symmetry line 180 ; The included angle between the second symmetry line 180 and the first symmetry line 150 is output as a deviation angle θ.

[0030] In this embodiment, when calculating the deviation angle θ, since the shape and position of the groove 111 are fixed, the first symmetry line 150 constructed with the groove outline can be used as a baseline reference line, and then the corresponding permanent magnet block outline located within the groove outline is identified. Since the shape of the permanent magnet block 140 here is also a symmetrical structure and has a distinct characteristic corner point position, the two characteristic corner points 160 are connected here to obtain an auxiliary line 170. Based on the midpoint of the auxiliary line 170, the second symmetry line 180 of the permanent magnet block 140 can be constructed. Finally, the angle between the second symmetry line 180 and the first symmetry line 150 is calculated to be the deviation angle θ. The calculation is accurate and reliable, and can accurately calculate various deviation situations of the permanent magnet block 140 to ensure the reliability of the data.

[0031] As an optional implementation manner, obtaining a second defect characteristic value according to the depth image includes: Identify depth information of each adhesive layer 130 region according to the depth image; According to the depth information, the concave-convex defect area 190 in each adhesive layer 130 is identified; wherein the concave-convex defect area 190 includes an overflowing adhesive area and a sunken adhesive area; Obtaining a second maximum value and determining whether the second maximum value is greater than a preset concave-convex deviation threshold; wherein the second maximum value is the maximum absolute value of the difference between the limit depth value and the standard depth value of the plurality of concave-convex defect regions 190, and the limit depth value is the most convex point depth value of the overflowing glue region or the most concave point depth value of the sunken glue region; If yes, the second maximum value is output as the second defect characteristic value; If not, obtaining a comprehensive concavo-convex feature evaluation value of all adhesive layers 130 having concavo-convex defect features; The concavo-convex feature evaluation value is output as a second defect feature value.

[0032] In this embodiment, when calculating the second defect feature, the depth information of each adhesive layer 130 region can be identified based on the depth image, thereby identifying the concave-convex defect region 190 in each adhesive layer 130 region, including the adhesive overflow region and the adhesive sunken region. If it is an adhesive overflow region, the absolute value of the difference between the most convex point depth value of the adhesive overflow region and the standard depth value is calculated. If it is a adhesive sunken region, the absolute value of the difference between the most concave point depth value of the adhesive sunken region and the standard depth value is calculated, thereby obtaining multiple sets of calculated values. The most representative second maximum value is screened out and compared with the concave-convex deviation threshold (the threshold is the minimum allowable concave-convex deviation value). If the second maximum value is greater than the concave-convex deviation threshold, the second maximum value is output as the second defect feature value for subsequent comparison with the second threshold (in this case, the second threshold is the maximum allowable concave-convex deviation value). For comparison, if the second maximum value is less than or equal to the concave-convex deviation threshold, the concave-convex depth of the adhesive layer 130 meets the qualification standard. However, considering that the presence of multiple adhesive layers 130 with concave-convex defect characteristics will also have a certain impact on the overall performance of the permanent magnet, a concave-convex feature evaluation value is further calculated to comprehensively evaluate the overall concave-convex condition of the multiple adhesive layers 130, and the concave-convex feature evaluation value is output as a second defect characteristic value (in this case, the second threshold is a second evaluation threshold for the concave-convex feature evaluation value, which is used to represent the minimum defect degree of the overall concave-convex condition of the multiple adhesive layers 130). By calculating the second defect characteristic value in a graded manner, a comprehensive assessment can be performed from two dimensions: obvious concave-convex defects in a single adhesive layer 130 and the overall distribution of concave-convex defects in multiple adhesive layers 130, thereby improving the detection accuracy of concave-convex defects in the adhesive layers 130.

[0033] It should be noted that the aforementioned second threshold value includes two threshold parameters: a maximum concave-convex deviation value and a second evaluation threshold value. Based on the attributes of the output second defect characteristic value, the corresponding threshold parameters are adapted for comparison. If only one adhesive layer 130 has an overflow or subsidence defect, the absolute value of the difference between the calculated limit depth value and the standard depth value of the overflow or subsidence area is the second maximum value.

[0034] As an optional embodiment, obtaining the concave-convex feature evaluation value of all adhesive layers 130 having concave-convex defect features includes: Obtaining the sum S of the areas of the plurality of concave-convex defect regions 190; Obtain the number n2 of adhesive layers with concave-convex defect characteristics; According to the sum of the areas S and the number of adhesive layers n2, the concave-convex feature evaluation value Q2 is obtained; wherein Q2=K2·n2·S, K2 is the second adjustment coefficient.

[0035] In this embodiment, the concavo-convex feature evaluation value is calculated by multiplying the sum S of the areas of the concavo-convex defect regions 190 (i.e., localized regions with overflowed or sunken adhesive in the adhesive layer 130) and the number n2 of adhesive layers exhibiting concavo-convex defect characteristics. This provides a relatively representative and targeted representation of the overall concavo-convex condition. An excessively large sum S or an excessive number n2 of adhesive layers exhibiting concavo-convex defect characteristics will affect overall performance. Simultaneously, a second adjustment coefficient K2 is used to adjust these two key parameters with different properties, thereby keeping the final result (i.e., the concavo-convex feature evaluation value Q2) within a reasonable range. This facilitates subsequent effective data comparison, thereby achieving a comprehensive evaluation of the concavo-convexity of the multiple adhesive layers 130.

[0036] As an optional embodiment, before obtaining the concavo-convex feature evaluation value of all adhesive layers 130 having concavo-convex defect features, the method further includes: Obtaining area values ​​of a plurality of concave-convex defect regions 190 respectively to obtain a maximum area value; Determine whether the maximum area value is greater than a preset area threshold; If so, the maximum area value is output as the second defect characteristic value; If not, proceed to the next step.

[0037] In this embodiment, before calculating the concavo-convex feature evaluation value, it is first verified whether the maximum area value of the corresponding concavo-convex defect regions 190 in the multiple adhesive layers 130 exceeds a preset area threshold (i.e., the minimum allowable concavo-convex defect area value). If so, it indicates that the area value of the concavo-convex defect region 190 in the adhesive layer 130 is large, which may also affect the overall performance of the permanent magnet. In this case, the maximum area value is output as the second defect characteristic value and subsequently compared with the second threshold value (in this case, the second threshold value is the maximum allowable concavo-convex defect area value). Otherwise, the concavo-convex feature evaluation value calculation step is entered, thereby further improving the detection accuracy of the concavo-convex defects in the adhesive layer 130. By rationally planning the order of its detection parameters, hierarchical detection is achieved, thereby ensuring detection accuracy while further improving detection efficiency.

[0038] Example 2: Based on the same inventive concept as the above embodiment, this embodiment further provides a permanent magnet defect detection device, comprising: A detection image acquisition module is used to acquire a detection image of a target end of a target permanent magnet; wherein the target permanent magnet includes a magnetic ring body 110, an inner core 120 is built into the center of the magnetic ring body 110, and a plurality of grooves 111 are formed on one side of the magnetic ring body 110 and distributed in an annular array around the inner core 120. Permanent magnet blocks 140 are fixedly installed in the grooves 111 by an adhesive layer 130. The target end is the end of the target permanent magnet having the permanent magnet blocks 140; A first feature acquisition module is configured to acquire a first defect feature value based on the detection image; wherein the first defect feature value is used to characterize the degree of thickness uniformity defects of the adhesive layer 130; A first judgment module is used to judge whether the first defect characteristic value is greater than a preset first threshold; a first data processing module, configured to, if yes, mark the target permanent magnet as a first-category defective product; and, if no, acquire a depth image of a target end of the target permanent magnet; A second feature acquisition module is used to acquire a second defect feature value based on the depth image; wherein the second defect feature value is used to characterize the degree of protrusion or depression of the adhesive layer 130; A second judgment module is used to judge whether the second defect characteristic value is greater than a preset second threshold; The second data processing module is configured to mark the target permanent magnet as a second-category defective product if yes, and mark the target permanent magnet as a qualified product if no.

[0039] The relevant explanations and examples of each module in the device of this embodiment can refer to the methods of the aforementioned embodiments, and will not be repeated here.

[0040] Example 3: Based on the same inventive concept as the above embodiment, this embodiment provides a computer device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the above method.

[0041] Example 4: Based on the same inventive concept as the above embodiment, this embodiment provides a computer-readable storage medium, on which a computer program is stored. A processor executes the computer program to implement the above method.

[0042] The above are only preferred embodiments of the present application and do not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present application.

Claims

1. A method for detecting defects in a permanent magnet, characterized in that: The following steps are involved: Acquire a detection image of a target end of a target permanent magnet; wherein the target permanent magnet includes a magnetic ring body, an inner core is built into the center of the magnetic ring body, a plurality of grooves are formed on one side of the magnetic ring body and are distributed in an annular array around the inner core, and permanent magnet blocks are fixed in place in the grooves by an adhesive layer, and the target end is the end of the target permanent magnet having the permanent magnet blocks; Obtaining a first defect characteristic value according to the detection image; wherein the first defect characteristic value is used to characterize the degree of uniformity defect in the thickness of the adhesive layer; Determining whether the first defect characteristic value is greater than a preset first threshold; If so, the target permanent magnet is marked as a first-category defective product; if not, a depth image of the target end of the target permanent magnet is acquired; Obtaining a second defect characteristic value according to the depth image; wherein the second defect characteristic value is used to characterize the degree of protrusion or depression of the adhesive layer; Determining whether the second defect characteristic value is greater than a preset second threshold; If so, the target permanent magnet is marked as a second-category defective product; if not, the target permanent magnet is marked as a qualified product.

2. A permanent magnet defect detection method according to claim 1, characterized in that: Obtaining a first defect characteristic value according to the detection image includes: Obtaining the deviation angle θ of each permanent magnet block from the theoretical position in the detection image; Obtaining a first maximum value and determining whether the first maximum value is greater than a preset deflection angle threshold; wherein the first maximum value is the maximum value among a plurality of deflection angles θ; If so, the first maximum value is output as the first defect characteristic value; If not, obtaining a deviation characteristic evaluation value of all permanent magnets having deviation characteristics; The deviation feature evaluation value is output as the first defect feature value.

3. A permanent magnet defect detection method according to claim 2, characterized in that: Obtain the deviation characteristic evaluation value of all permanent magnets with deviation characteristics, including: Obtaining a deflection angle average value θ' of several deviation angles θ; Obtain the number n1 of permanent magnets having deviation characteristics; According to the average deflection angle θ' and the number n1 of permanent magnets with the deviation characteristic, a deviation characteristic evaluation value Q1 is obtained; wherein Q1=K1·n1·θ', K1 is a first adjustment coefficient.

4. A permanent magnet defect detection method according to claim 2, characterized in that: Obtaining the deviation angle θ of each permanent magnet block from the theoretical position in the detection image, including: Identify the groove contour in the inspection image; Constructing a first symmetry line based on the groove profile; wherein the groove profile is symmetrical based on the first symmetry line, and the first symmetry line passes through the center of the circular profile of the magnetic ring body; Identifying the corresponding permanent magnet block profile located within the groove profile; Connect two symmetrical characteristic corner points in the outline of the permanent magnet block to obtain an auxiliary line; Constructing a second symmetry line based on the midpoint of the auxiliary line; wherein the second symmetry line and the auxiliary line are perpendicular to each other, and the outline of the permanent magnet block is symmetrical based on the second symmetry line; The included angle between the second symmetry line and the first symmetry line is output as a deviation angle θ.

5. A permanent magnet defect detection method according to any one of claims 1 to 4, characterized in that: Obtaining a second defect feature value according to the depth image includes: According to the depth image, identify the depth information of each glue layer area; Identify the concave-convex defect areas in each glue layer area based on the depth information; wherein the concave-convex defect areas include glue overflow areas and glue sinking areas; Obtaining a second maximum value and determining whether the second maximum value is greater than a preset concave-convex deviation threshold; wherein the second maximum value is the maximum absolute value of the difference between the limit depth value and the standard depth value of the concave-convex defect area, and the limit depth value is the most convex point depth value of the overflowed glue area or the most concave point depth value of the sunken glue area; If yes, the second maximum value is output as the second defect characteristic value; If not, obtaining the concave-convex feature evaluation value of all adhesive layers with concave-convex defect characteristics; The concavo-convex feature evaluation value is output as a second defect feature value.

6. A permanent magnet defect detection method according to claim 5, characterized in that: Obtain the comprehensive concave-convex feature evaluation value of all adhesive layers with concave-convex defect characteristics, including: Obtain the sum S of the areas of several concave and convex defect regions; Obtain the number n2 of adhesive layers with concave-convex defect characteristics; According to the sum of the areas S and the number of adhesive layers n2, the concave-convex feature evaluation value Q2 is obtained; wherein Q2=K2·n2·S, K2 is the second adjustment coefficient.

7. A permanent magnet defect detection method according to claim 5, characterized in that: Before obtaining the comprehensive concave-convex feature evaluation value of all adhesive layers with concave-convex defect characteristics, the following steps are also included: Obtaining the area values ​​of several concave and convex defect regions respectively to obtain the maximum area value; Determine whether the maximum area value is greater than a preset area threshold; If so, the maximum area value is output as the second defect characteristic value; If not, proceed to the next step.

8. A permanent magnet defect detection device, characterized in that: include: a detection image acquisition module, configured to acquire a detection image of a target end of a target permanent magnet; wherein the target permanent magnet comprises a magnetic ring body, wherein an inner core is built into the center of the magnetic ring body, and a plurality of grooves are formed on one side of the magnetic ring body and distributed in an annular array around the inner core, wherein permanent magnet blocks are fixedly disposed in the grooves by an adhesive layer, and the target end is the end of the target permanent magnet having the permanent magnet blocks; A first feature acquisition module is used to acquire a first defect feature value based on the detection image; wherein the first defect feature value is used to characterize the degree of uniformity defect in the thickness of the adhesive layer; A first judgment module is used to judge whether the first defect characteristic value is greater than a preset first threshold; a first data processing module, configured to, if yes, mark the target permanent magnet as a first-category defective product; and, if no, acquire a depth image of a target end of the target permanent magnet; A second feature acquisition module is used to obtain a second defect feature value based on the depth image; wherein the second defect feature value is used to characterize the degree of protrusion or depression of the adhesive layer; A second judgment module is used to judge whether the second defect characteristic value is greater than a preset second threshold; The second data processing module is configured to mark the target permanent magnet as a second-category defective product if yes, and mark the target permanent magnet as a qualified product if no.

9. A computer device, characterized in that: The computer device includes a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and the processor executes the computer program to implement the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method and system for detecting appearance defect of magnet

    CN108776966A

  • Visual inspection equipment and method

    CN120044053A

  • Visual inspection systems and methods

    US20240280499A1

Cited By

  • Defect detection method, system and equipment for special-shaped forgings and medium

    CN121049472A