Battery pole defect detection method and device, computer equipment and storage medium

By performing scratch area detection and ring area detection on the battery pole image, a pixel matrix is ​​generated to identify penetrating scratches, the problem of low detection efficiency and accuracy in the prior art is solved, and automated detection and resource optimization are realized.

CN119624887APending Publication Date: 2025-03-14SHENZHEN SMARTMORE TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411671942.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-03-14

AI Technical Summary

Technical Problem

The prior art cannot effectively detect the penetrating scratches of the battery pole, resulting in inadequate detection quality and efficiency.

Method used

The trained pole scratch detection model is used to detect the pole column image to be detected, and the corresponding pixel matrix is ​​generated through the connection domain segmentation and ring area detection to determine the area where the penetrating scratch is located.

Benefits of technology

Automatic detection of the through-corner scratches of the battery pole is realized, which improves detection efficiency and accuracy, and reduces resource occupation and time consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119624887A_ABST
    Figure CN119624887A_ABST
Patent Text Reader

Abstract

The invention relates to a battery pole defect detection method and device, computer equipment and a storage medium. The method comprises the following steps: carrying out scratch area detection on an obtained to-be-detected pole image by adopting a trained pole scratch detection model to obtain a scratch area binary image; performing connected domain segmentation on the binary image of the scratch area to generate a scratch area pixel matrix; performing circular ring area detection on a circular ring on the outer side of the pole of the to-be-detected pole image to generate an outer circular ring area pixel matrix; according to the scratch area pixel matrix and the outer circular ring area pixel matrix, determining an overlapping area pixel matrix; and according to pixel values in the overlapped region pixel matrix, determining a region where the penetrability scratch is located in the to-be-detected pole image. According to the invention, the accuracy and efficiency of defect detection of the battery pole can be 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 processing technology, and in particular to a battery pole defect detection method, device, computer equipment and storage medium. Background Art

[0002] With the widespread application of new energy batteries, the quality inspection of new energy batteries is becoming more and more important. Defects on the battery pole (such as scratches or marks) are one of the important evaluation indicators affecting battery quality. However, among all types of pole scratches, only penetrating scratches will affect the conductivity of the battery.

[0003] The existing battery pole scratch detection technology can only detect the location or size of the scratch on the battery pole, but cannot further detect whether the scratch type is a penetrating scratch. Usually, manual follow-up is required to identify or judge the penetrating scratches one by one, resulting in low quality and efficiency of battery pole defect detection. Summary of the invention

[0004] Based on this, it is necessary to provide a battery pole defect detection method, device, computer equipment and storage medium to address the above technical problems, which can improve the accuracy and efficiency of battery pole defect detection.

[0005] In a first aspect, the present application provides a battery pole defect detection method, comprising:

[0006] The trained pole scratch detection model is used to detect the scratch area of ​​the acquired pole image to be detected, and a binary image of the scratch area is obtained;

[0007] Perform connected domain segmentation on the binary image of the scratched area to generate a pixel matrix of the scratched area;

[0008] Performing circular ring area detection on the outer circular ring of the pole of the pole image to be detected, and generating a pixel matrix of the outer circular ring area;

[0009] Determine the pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer ring area;

[0010] According to the pixel values ​​in the pixel matrix of the overlapped area, the area where the penetrating scratch is located in the pole image to be detected is determined.

[0011] In a second aspect, the present application provides a battery pole defect detection device, comprising:

[0012] An image generation module is used to detect the scratched area of ​​the acquired pole image to be detected by using the trained pole scratch detection model to obtain a binary image of the scratched area;

[0013] A region segmentation module is used to perform connected domain segmentation on the binary image of the scratched region to generate a pixel matrix of the scratched region;

[0014] A region detection module is used to perform a circular ring region detection on the outer circular ring of the pole of the pole image to be detected, and generate a pixel matrix of the outer circular ring region;

[0015] A matrix generation module, used for determining a pixel matrix of an overlapped area according to a pixel matrix of a scratched area and a pixel matrix of an outer ring area;

[0016] The scratch detection module is used to determine the area where the penetrating scratches in the pole image to be detected are located according to the pixel values ​​in the pixel matrix of the overlapped area.

[0017] In a third aspect, the present application provides a computer device, the computer device comprising a memory and a processor, the memory storing a computer program, and the processor implementing the steps in the above method when executing the computer program.

[0018] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which implements the steps in the above method when executed by a processor.

[0019] In a fifth aspect, the present application provides a computer program product, which includes a computer program, and the computer program implements the steps in the above method when executed by a processor.

[0020] The above-mentioned battery pole defect detection method, device, computer equipment and storage medium perform scratch area detection and outer ring area detection on the pole image to be inspected, and identify the penetrating scratch area based on the scratch area pixel matrix and the outer ring area pixel matrix obtained by detection. Compared with the prior art, the present application realizes the automatic determination of penetrating scratches on the battery pole, and can realize one-time penetrating detection of a large number of scratch defects based on pixel matrix operation, rather than manual detection one by one, which greatly improves the detection efficiency and detection accuracy of penetrating scratches and effectively reduces resource occupation and time consumption. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] Figure 1 An application environment diagram of a battery pole defect detection method provided in an embodiment of the present application;

[0022] Figure 2 A schematic diagram of a flow chart of a battery pole defect detection method provided in an embodiment of the present application;

[0023] Figure 3 A schematic diagram of a pixel matrix of an overlapped area provided in an embodiment of the present application;

[0024] Figure 4A schematic diagram of a flow chart of another battery pole defect detection method provided in an embodiment of the present application;

[0025] Figure 5 A structural block diagram of a battery pole defect detection device provided in an embodiment of the present application;

[0026] Figure 6 An internal structure diagram of a computer device provided in an embodiment of the present application;

[0027] Figure 7 An internal structure diagram of another computer device provided in an embodiment of the present application;

[0028] Figure 8 An internal structure diagram of a computer-readable storage medium provided in an embodiment of the present application. DETAILED DESCRIPTION

[0029] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0030] The battery pole defect detection method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown. Among them, the terminal 102 communicates with the server 104 through a communication network. The data storage system can store the data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network servers. Among them, the terminal 102 can be but is not limited to various personal computers, laptops, smart phones, tablets, Internet of Things devices and portable wearable devices. The Internet of Things devices can be smart speakers, smart TVs, smart air conditioners, smart car-mounted devices, etc. Portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The server 104 can be implemented with an independent server or a server cluster consisting of multiple servers.

[0031] like Figure 2 As shown, the embodiment of the present application provides a battery pole defect detection method, which is applied to Figure 1 The terminal 102 or the server 104 in the example is used for explanation. It is understandable that the computer device may include at least one of the terminal and the server. The method comprises the following steps:

[0032] S202: Use the trained pole scratch detection model to perform scratch area detection on the acquired pole image to be detected, and obtain a binary image of the scratch area.

[0033] S204, performing connected domain segmentation on the binary image of the scratched area to generate a pixel matrix of the scratched area.

[0034] S206 , performing annular region detection on the outer circular ring of the pole of the pole image to be detected, and generating an outer circular ring region pixel matrix.

[0035] S208: Determine the pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer ring area.

[0036] S210: Determine the region where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the pixel matrix of the overlapped region.

[0037] The pole image to be inspected may be a battery pole image with a scratch inspection requirement, which may be obtained directly from the demander, or may be obtained by photographing the battery pole area to be inspected using an image acquisition device according to actual inspection requirements. The specific image acquisition angle, light source, or other acquisition-related data may be preset according to actual requirements, and this embodiment does not limit this.

[0038] Among them, the pole scratch detection model can be pre-built and trained by relevant technical personnel according to actual detection needs; or, a large number of battery pole scratch images can be used to train the existing detection network model.

[0039] In some embodiments, before using the trained pole scratch detection model to perform scratch area detection on the acquired pole image to be detected and obtaining a binary image of the scratch area, the method further includes:

[0040] Obtaining pole scratch image samples of different scratch types, and marking scratch areas of the pole scratch image samples to obtain standard scratch areas of the pole scratch image samples;

[0041] Input the pole scratch image sample into the preset pole scratch detection model for processing, and output the predicted scratch area;

[0042] According to the standard scratch area and the predicted scratch area, the pole scratch detection model is trained until the preset model training end condition is met to obtain the trained pole scratch detection model.

[0043] The different scratch types may include penetrating scratches and non-penetrating scratches of the same or different shapes caused by various reasons during the battery processing, such as mechanical scratches, corrosion scratches, arc scratches, thermal scratches, fatigue scratches or electrostatic scratches.

[0044] The number of samples of pole scratch image samples of different scratch types is balanced to ensure the detection accuracy of different types of scratches. For any pole scratch image sample, the scratch area of ​​the pole scratch image sample is marked. The scratch area can be the area formed by the pixel points where the scratched part is located; the specific marking method can be manual marking method, automatic marking method or semi-automatic marking method, etc., which is not limited in this embodiment.

[0045] Among them, the detection network model can be a U-Net (U-type network, a convolutional neural network for image segmentation) model or a Mask-R-CNN (Mask Region-based Convolutional Neural Network, mask area convolutional neural network) model, etc. Among them, the end condition of model training can be that the number of model iterations reaches a set threshold, or that the model training loss value tends to be stable. Exemplarily, according to the standard scratch area and the predicted scratch area, based on the preset loss function, the loss value under the current number of iterations is determined; if the difference between the current loss value under the current number of iterations and the historical loss value under the previous number of historical iterations is less than the preset threshold, it can be considered that the model training loss value tends to be stable, and the model training is terminated to obtain a trained pole scratch detection model.

[0046] It can be seen that in this embodiment, by using a large number of pole scratch image samples of different scratch types to train the preset pole scratch detection model, a large number of pole scratch features are learned, thereby improving the detection accuracy of the trained pole scratch detection model for pole scratches.

[0047] The predicted scratch image output by the pole scratch detection model is binarized to obtain a binary image of the scratched area. In the binary image of the scratched area, the pixel value of the pixel part of the scratched area is represented by "1", and the pixel value of the pixel part of the non-scratched area is represented by "0".

[0048] The first stage of connected domain segmentation is performed on the binary image of the scratched area to generate a pixel matrix of the scratched area. It should be noted that since the number of scratches in the pole image to be detected may be one or more, the number of connected domains obtained after the connected domain segmentation of the binary image of the scratched area may be one or more. In the process of connected domain segmentation, the pixels in different connected areas are assigned different pixel number values. For example, the pixel number value in the connected area A is 1; the pixel number value in the connected area B is 2; and the pixel number value in the connected area B is 3. Correspondingly, the generated pixel matrix of the scratched area is a pixel matrix with different pixel number values, specifically, the matrix value embodied in the matrix is ​​the corresponding pixel number value, and the matrix value of the non-scratched area is 0; wherein the pixel number value (matrix value) is used to characterize the connected areas of different scratched parts.

[0049] The outer ring of the pole of the pole image to be detected is detected, and a pixel matrix of the outer ring area is generated. Specifically, an edge detection algorithm, such as the Canny operator, can be used to extract edge information in the pole image to be detected; according to the ring characteristics of the outer ring of the battery pole, the inner radius and outer radius range are set, and the Hough circle algorithm is used to search the outer ring area based on the searched edge information and the preset inner and outer radii of the nuclear power, and the area where the outer ring of the pole of the pole image to be detected is located is obtained, and a pixel matrix of the outer ring area is generated. Among them, in the pixel matrix of the outer ring area, the matrix value or pixel value in the pixel area where the outer ring is located is 1, and the other matrix values ​​or pixel values ​​are 0.

[0050] The pixel matrix of the overlapped area is generated based on the pixel matrix of the scratched area and the pixel matrix of the outer ring area. It should be noted that there are three situations where the scratched part of the pole overlaps with the ring: a) there is no overlapped area, which is a non-penetrating scratch; b) one end of the scratched part overlaps with the ring, which is a non-penetrating scratch; c) both ends of the scratched part overlap with the ring, which is a penetrating scratch. Therefore, in order to determine whether the scratched area overlaps with the outer ring area, the overlapped area can be determined based on the product of the pixel values ​​between the two pixel matrices.

[0051] In some embodiments, determining the overlapped area pixel matrix according to the scratched area pixel matrix and the outer ring area pixel matrix includes:

[0052] The two pixel values ​​at the same coordinates in the scratch area pixel matrix and the outer ring area pixel matrix are numerically multiplied to obtain the overlap area pixel matrix.

[0053] It can be understood that since the pixel matrix of the scratch area and the pixel matrix of the outer ring area are both generated based on image processing of the pole image to be detected, the matrix sizes of the pixel matrix of the scratch area and the pixel matrix of the outer ring area are the same, both of which are the image size of the pole image to be detected.

[0054] Exemplarily, two pixel values ​​at the same coordinates in the two pixel matrices are numerically multiplied. For example, pixel point A at the coordinates [100, 90] in the scratch area pixel matrix is ​​numerically multiplied with pixel point B at the coordinates [100, 90] in the outer ring area pixel matrix to obtain pixel value C at [100, 90] in the overlap area pixel matrix.

[0055] It can be seen that in this embodiment, by performing a numerical multiplication operation on two pixel values ​​located at the same coordinates in the scratch area pixel matrix and the outer ring area pixel matrix, the pixel points in the area where the scratch area and the outer ring area overlap can be effectively screened out, thereby facilitating the subsequent accurate determination of whether the scratch type is a penetrating scratch.

[0056] According to the pixel values ​​in the pixel matrix of the overlapping area, the area where the penetrating scratch is located in the pole image to be detected is determined. Among them, different pixel values ​​in the pixel matrix of the overlapping area can represent different connected areas to which they belong, and different connected areas are specifically areas where the scratch area and the outer ring area intersect. Therefore, if the scratch type is a penetrating scratch, the transaction area between the area where the penetrating scratch is located and the outer ring area includes at least two areas with the same pixel values. Furthermore, at least two connected areas with the same pixel values ​​can be determined by the pixel values ​​in each connected area in the pixel matrix of the overlapping area, and the positions of the at least two connected areas with the same pixel values ​​in the pole image to be detected are determined as the positions of the areas where the penetrating scratches are located.

[0057] In a specific embodiment, Figure 3 A schematic diagram of a pixel matrix of an overlapped area is shown. Among them, there are connected areas A, connected areas B, connected areas C and connected areas D in the pixel matrix of the overlapped area. Each connected area is an area generated by the intersection of the scratch area part and the outer ring area part. Among them, the pixel values ​​of the connected area C and the connected area D are the same, both of which are 2. Therefore, the scratched parts in the connected area C and the connected area D are penetrating scratches. Further, the scratched areas where the connected areas C and the connected areas D are located in the image to be detected are determined as the areas where the penetrating scratches are located.

[0058] It can be seen that in the embodiment of the present application, by respectively generating a scratch area pixel matrix and an outer ring area pixel matrix, and based on the two pixel matrices, determining the area where the scratch area partially overlaps with the outer ring area, thereby determining the penetrating scratches of the pole image to be detected according to the pixel values ​​of the overlapping area, thereby realizing the automated determination of the penetrating scratches on the battery pole, and enabling one-time penetration detection of a large number of scratch defects based on pixel matrix operation, rather than manual detection one by one, thereby greatly improving the detection efficiency and accuracy of penetrating scratches, and effectively reducing resource occupation and time consumption.

[0059] In order to further improve the accuracy of generating the pixel matrix of the outer ring area, in some embodiments, the ring area detection is performed on the outer ring of the pole of the pole image to be detected to generate the pixel matrix of the outer ring area, including:

[0060] Performing circular ring area detection on the circular ring outside the pole of the pole image to be detected, and generating a first circular ring area pixel matrix;

[0061] Using the trained pole ring detection model to perform ring area detection on the outer ring of the pole of the pole image to be detected, and generating a second ring area pixel matrix;

[0062] An outer circular ring area pixel matrix is ​​generated according to the first circular ring area pixel matrix and / or the second circular ring area pixel matrix.

[0063] Among them, the pole ring detection model can be pre-trained by relevant technical personnel. Specifically, the model training method of the pole ring detection model can be: obtaining battery pole image samples, and marking the outer ring area of ​​the battery pole image samples to obtain the standard outer ring area of ​​the battery pole image samples; inputting the battery pole image samples into a preset detection network model for processing, and outputting the predicted outer ring area; according to the standard outer ring area and the predicted outer ring area, based on the preset loss function, the preset detection network model is trained to obtain a trained pole ring detection model.

[0064] The pole image to be detected is input into the trained pole ring detection model to obtain the pixel matrix of the second ring area predicted by the model.

[0065] Exemplarily, the first circular ring area pixel matrix predicted by the Hough circle algorithm can be used as the outer circular ring area pixel matrix, or the second circular ring area pixel matrix can be used as the outer circular ring area pixel matrix; to more accurately determine the outer circular ring area pixel matrix, the first circular ring area pixel matrix and the second circular ring area pixel matrix can be merged for the pixels of the outer circular ring area, and the merged result can be used as the outer circular ring area pixel matrix.

[0066] It can be seen that this embodiment improves the prediction accuracy of the pixel matrix of the outer ring area of ​​the polar image to be detected by adopting the Hough circle algorithm and / or the polar ring detection model, thereby further improving the subsequent generation accuracy of the pixel matrix of the overlapping area, and further improving the detection accuracy of penetrating scratches on the polar image to be detected.

[0067] Figure 4 A schematic diagram of another method for detecting penetrating scratches on a battery pole provided in an embodiment of the present application. This embodiment is further optimized on the basis of the above embodiment. Figure 4 As shown, the method includes:

[0068] S402: Use the trained pole scratch detection model to perform scratch area detection on the acquired pole image to be detected, and obtain a binary image of the scratch area.

[0069] S404, performing connected domain segmentation on the binary image of the scratched area to generate a pixel matrix of the scratched area.

[0070] S406, performing annular region detection on the outer circular ring of the pole of the pole image to be detected, and generating an outer circular ring region pixel matrix.

[0071] S408: Determine the pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer ring area.

[0072] S410 , binarizing the overlapped region pixel matrix to obtain an overlapped region binarization matrix.

[0073] S412, performing connected domain segmentation on the binary matrix of the overlapping area to generate a secondary detection area pixel matrix.

[0074] S414, determining a target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix.

[0075] S416: Determine the region where the penetrating scratches are located in the pole image to be detected according to the pixel values ​​in the target region matrix.

[0076] The binarization processing of the overlapped region pixel matrix may specifically be to update the non-zero pixel values ​​in the overlapped region pixel matrix to "1", and not to update the zero-value pixel values, thereby obtaining an overlapped region binarization matrix containing only pixel values ​​"0" or "1". It should be noted that the purpose of generating the overlapped region binarization matrix is ​​to provide a basis for subsequent secondary connected domain segmentation, so as to facilitate the secondary connected domain numbering during the subsequent secondary connected domain segmentation, that is, the secondary assignment of pixel values.

[0077] The second stage connected domain segmentation is performed on the binary matrix of the overlapped area to generate a secondary detection area pixel matrix. The secondary detection area pixel matrix may contain one or more connected areas, and the pixel values ​​in each connected area are different.

[0078] The target region matrix is ​​generated based on the secondary detection region pixel matrix and the scratch region pixel matrix. The purpose of generating the target region matrix is ​​to determine whether there are identically coded pixel values ​​in the scratch region pixel matrix generated in the first stage and the secondary detection region pixel matrix generated in the second stage.

[0079] In some embodiments, determining the target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix includes:

[0080] A first preset integer value is used to perform a numerical multiplication operation with each pixel value in the scratch area pixel matrix to obtain an intermediate area pixel matrix;

[0081] The target area matrix is ​​obtained by numerically adding two pixel values ​​at the same coordinates in the intermediate area pixel matrix and the secondary detection area pixel matrix.

[0082] The first preset integer value may be preset by relevant technical personnel according to actual needs. For example, under the objective condition of ensuring that the number of scratches in the pole image to be detected is less than 100, the first preset integer value may be set to 100.

[0083] Each pixel value in the scratch area pixel matrix is ​​multiplied by the first preset integer value to obtain the intermediate area pixel matrix. Two pixel values ​​at the same coordinates in the intermediate area pixel matrix and the secondary detection area pixel matrix are numerically added to obtain the target area matrix. For example, if the first preset integer value is 100, the scratch area pixel matrix is ​​set to the B matrix, and the secondary detection area pixel matrix is ​​set to the E matrix, then the target area matrix F is calculated as follows:

[0084] F = 100 - B + E;

[0085] It can be seen that in this embodiment, by performing matrix multiplication operations based on pre-set preset integer values ​​and performing summation operations based on the multiplied matrices to obtain the target area matrix, the subsequent comparison process of pixel values ​​with the same number in a large number of connected areas is avoided, thereby greatly improving the connected area detection efficiency when the number of scratches is large.

[0086] According to the pixel values ​​in the target area matrix, the area where the repeated pixel values ​​are located is selected as the area where the penetrating scratches of the pole image to be detected are located.

[0087] In order to further improve the efficiency of determining the area where the penetrating scratch is located and reduce the workload of processing pixel matrix data, in some embodiments, the area where the penetrating scratch is located in the pole image to be detected is determined according to the pixel values ​​in the target area matrix, including:

[0088] Performing numerical extraction on non-zero pixel values ​​in the target area matrix to obtain at least one reference pixel value;

[0089] Determine, according to the second preset integer value, the target pixel values ​​corresponding to the respective reference pixel values;

[0090] Determining repeated pixel values ​​in each target pixel value;

[0091] The connected area where the pixel value in the scratch area pixel matrix is ​​the same as the repeated pixel value is determined as the area where the penetrating scratch in the pole image to be detected is located.

[0092] Specifically, a unique operation can be performed on the non-zero pixel values ​​in the target area matrix, specifically, the non-zero pixel values ​​in the matrix can be extracted, and the extracted non-zero pixel values ​​can be written into a pre-constructed blank array to obtain at least one reference pixel value contained in the array. According to the second preset integer value, each reference pixel value is updated to obtain a target pixel value. Specifically, each reference pixel value can be divided by the second preset integer value to obtain an integer quotient value, and the integer quotient value is determined as the target pixel value, and the second preset integer value is set the same as the above-mentioned first preset integer value.

[0093] Determine the repeated pixel values ​​in each target pixel value, specifically, the target pixel value that appears at least twice, and determine it as the repeated pixel value. Determine the connected area where the pixel value in the scratch area pixel matrix is ​​the same as the repeated pixel value as the area where the penetrating scratch is located in the pole image to be detected.

[0094] It can be understood that if the pixel value of the scratch area pixel matrix at the same pixel position a is 2, the pixel value of the secondary detection area pixel matrix is ​​3, and the second preset integer value is set to 100, then the pixel value of the target area matrix at the same pixel position a is 203. After performing the non-zero value pixel extraction operation, the reference pixel value 203 is divided by 100 to obtain a target pixel value of 2. If the number of occurrences of the pixel value 2 includes at least two times in all the target pixel values, the connected area where the pixel value 2 of the scratch area pixel matrix is ​​located is determined as the area where the penetrating scratch in the pole image to be detected is located.

[0095] It can be seen that the technical solution of this embodiment determines the overlapping areas with the same pixel values ​​in the connected areas of the two stages by adopting matrix calculation, thereby improving the efficiency of determining the areas where the penetrating scratches are located when the number of scratch areas is large, and reducing the processing workload of pixel-by-pixel comparison of a large amount of pixel matrix data.

[0096] The technical solution of this embodiment performs secondary connected domain segmentation on the generated overlapped area pixel matrix to generate a secondary detection area pixel matrix, and performs penetrating scratch detection on the pole image to be detected according to the pixel values ​​corresponding to the secondary detection area pixel matrix and the scratch area pixel matrix, thereby further improving the detection efficiency of penetrating scratches and reducing the computing resources and time-consuming costs for a large number of intensive scratches. In addition, for a large number of interlaced scratch defects, the overfitting detection of scratches is effectively avoided, thereby further improving the detection accuracy of penetrating scratches.

[0097] It should be understood that, although the steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indications of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear description in this article, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0098] Based on the same inventive concept, the embodiment of the present application also provides a battery pole defect detection device. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more embodiments of the battery pole defect detection device provided below can refer to the limitations of the battery pole defect detection method above, and will not be repeated here.

[0099] like Figure 5 As shown, the embodiment of the present application provides a battery pole defect detection device 400, comprising:

[0100] An image generation module 502 is used to use a trained pole scratch detection model to perform scratch area detection on the acquired pole image to be detected, and obtain a binary image of the scratch area;

[0101] The region segmentation module 504 is used to perform connected domain segmentation on the binary image of the scratched region to generate a pixel matrix of the scratched region;

[0102] The region detection module 506 is used to perform a circular ring region detection on the outer circular ring of the pole of the pole image to be detected, and generate a pixel matrix of the outer circular ring region;

[0103] A matrix generation module 508, used to determine a pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer ring area;

[0104] The scratch detection module 510 is used to determine the area where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the pixel matrix of the overlapped area.

[0105] In some embodiments, in determining the pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer annular area, the matrix generation module 508 is specifically used to:

[0106] The two pixel values ​​at the same coordinates in the scratch area pixel matrix and the outer ring area pixel matrix are numerically multiplied to obtain the overlap area pixel matrix.

[0107] In some embodiments, in determining the region where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the pixel matrix of the overlapped region, the scratch detection module 510 is specifically used to:

[0108] Binarization is performed on the pixel matrix of the overlapped area to obtain a binary matrix of the overlapped area;

[0109] Perform connected domain segmentation on the binary matrix of the overlapping area to generate a pixel matrix of the secondary detection area;

[0110] Determine the target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix;

[0111] According to the pixel values ​​in the target area matrix, the area where the penetrating scratches are located in the pole image to be detected is determined.

[0112] In some embodiments, in determining the target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix, the scratch detection module 510 is specifically used to:

[0113] A first preset integer value is used to perform a numerical multiplication operation with each pixel value in the scratch area pixel matrix to obtain an intermediate area pixel matrix;

[0114] The target area matrix is ​​obtained by numerically adding two pixel values ​​at the same coordinates in the intermediate area pixel matrix and the secondary detection area pixel matrix.

[0115] In some embodiments, in determining the region where the penetrating scratches in the pole image to be detected are located according to the pixel values ​​in the target region matrix, the scratch detection module 510 is specifically used to:

[0116] Performing numerical extraction on non-zero pixel values ​​in the target area matrix to obtain at least one reference pixel value;

[0117] Determine, according to the second preset integer value, the target pixel values ​​corresponding to the respective reference pixel values;

[0118] Determining repeated pixel values ​​in each target pixel value;

[0119] The connected area where the pixel value in the scratch area pixel matrix is ​​the same as the repeated pixel value is determined as the area where the penetrating scratch in the pole image to be detected is located.

[0120] In some embodiments, in terms of performing annular region detection on the outer annular region of the pole of the pole image to be detected and generating an outer annular region pixel matrix, the region detection module 506 is specifically used to:

[0121] Performing circular ring area detection on the circular ring outside the pole of the pole image to be detected, and generating a first circular ring area pixel matrix;

[0122] Using the trained pole ring detection model to perform ring area detection on the outer ring of the pole of the pole image to be detected, and generating a second ring area pixel matrix;

[0123] An outer circular ring area pixel matrix is ​​generated according to the first circular ring area pixel matrix and / or the second circular ring area pixel matrix.

[0124] In some embodiments, the battery pole defect detection device 400 further includes a model training module, which is used to:

[0125] Obtaining pole scratch image samples of different scratch types, and marking scratch areas of the pole scratch image samples to obtain standard scratch areas of the pole scratch image samples;

[0126] Input the pole scratch image sample into the preset pole scratch detection model for processing, and output the predicted scratch area;

[0127] According to the standard scratch area and the predicted scratch area, the pole scratch detection model is trained until the preset model training end condition is met to obtain the trained pole scratch detection model.

[0128] Each module in the above-mentioned battery pole defect detection device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.

[0129] In some embodiments, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 6As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data related to battery pole defect detection. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, the steps in the above-mentioned battery pole defect detection method are implemented.

[0130] In some embodiments, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 7 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, the steps in the above-mentioned battery pole defect detection method are implemented. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen; the input device of the computer device can be a touch layer covering the display screen, or a key, trackball or touchpad provided on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0131] Those skilled in the art will understand that Figure 6 or Figure 7The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0132] In some embodiments, a computer device is provided. The computer device includes a memory and a processor. The memory stores a computer program. When the processor executes the computer program, the steps in the above method embodiments are implemented.

[0133] In some embodiments, Figure 8 The figure shows an internal structure diagram of a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0134] In some embodiments, a computer program product is provided. The computer program product includes a computer program. When the computer program is executed by a processor, the steps in the above method embodiments are implemented.

[0135] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0136] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0137] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0138] The above embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A battery pole defect detection method, characterized in that: include: The trained pole scratch detection model is used to detect the scratch area of ​​the acquired pole image to be detected, and a binary image of the scratch area is obtained; Performing connected domain segmentation on the binary image of the scratched area to generate a pixel matrix of the scratched area; Performing ring area detection on the outer ring of the pole of the pole image to be detected to generate a pixel matrix of the outer ring area; Determine a pixel matrix of an overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer annular area; The region where the penetrating scratch in the pole image to be detected is located is determined according to the pixel values ​​in the pixel matrix of the overlapped region.

2. The method according to claim 1, characterized in that The step of determining the pixel matrix of the overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer annular area includes: The two pixel values ​​at the same coordinates in the scratch area pixel matrix and the outer ring area pixel matrix are numerically multiplied to obtain the overlap area pixel matrix.

3. The method according to claim 1, characterized in that The step of determining the region where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the pixel matrix of the overlapped region includes: Binarizing the pixel matrix of the overlapped area to obtain a binary matrix of the overlapped area; Performing connected domain segmentation on the binary matrix of the overlapping area to generate a secondary detection area pixel matrix; Determining a target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix; The region where the penetrating scratches are located in the pole image to be detected is determined according to the pixel values ​​in the target region matrix.

4. The method according to claim 3, characterized in that The step of determining a target area matrix according to the secondary detection area pixel matrix and the scratch area pixel matrix comprises: A first preset integer value is used to perform a numerical multiplication operation with each pixel value in the scratch area pixel matrix to obtain an intermediate area pixel matrix; The target area matrix is ​​obtained by performing a numerical addition operation on two pixel values ​​located at the same coordinates in the intermediate area pixel matrix and the secondary detection area pixel matrix.

5. The method according to claim 4, characterized in that The step of determining the region where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the target region matrix includes: Performing numerical extraction on non-zero pixel values ​​in the target area matrix to obtain at least one reference pixel value; Determine, according to a second preset integer value, target pixel values ​​corresponding to the reference pixel values ​​respectively; Determining repeated pixel values ​​among the target pixel values; The connected area in the scratch area pixel matrix where the pixel value is the same as the repeated pixel value is determined as the area where the penetrating scratch in the pole image to be detected is located.

6. The method according to claim 1, characterized in that The step of performing ring area detection on the outer ring of the pole of the pole image to be detected to generate a pixel matrix of the outer ring area includes: Performing circular ring area detection on the circular ring outside the pole of the pole image to be detected to generate a first circular ring area pixel matrix; Using a trained pole ring detection model to perform ring area detection on the outer ring of the pole of the pole image to be detected, and generating a second ring area pixel matrix; An outer circular area pixel matrix is ​​generated according to the first circular area pixel matrix and / or the second circular area pixel matrix.

7. The method according to claim 1, characterized in that Before the trained pole scratch detection model is used to detect the scratched area of ​​the acquired pole image to be detected and a binary image of the scratched area is obtained, the method further comprises: Acquire pole scratch image samples of different scratch types, and mark scratch areas of the pole scratch image samples to obtain standard scratch areas of the pole scratch image samples; Inputting the pole scratch image sample into a preset pole scratch detection model for processing, and outputting a predicted scratch area; The pole scratch detection model is trained according to the standard scratch area and the predicted scratch area until a preset model training end condition is met, thereby obtaining the trained pole scratch detection model.

8. A battery pole defect detection device, characterized in that: include: An image generation module is used to detect the scratched area of ​​the acquired pole image to be detected by using the trained pole scratch detection model to obtain a binary image of the scratched area; A region segmentation module is used to perform connected domain segmentation on the binary image of the scratched region to generate a pixel matrix of the scratched region; A region detection module, used for performing a circular ring region detection on the outer circular ring of the pole of the pole image to be detected, and generating a pixel matrix of the outer circular ring region; A matrix generation module, used for determining a pixel matrix of an overlapped area according to the pixel matrix of the scratched area and the pixel matrix of the outer annular area; The scratch detection module is used to determine the area where the penetrating scratch in the pole image to be detected is located according to the pixel values ​​in the pixel matrix of the overlapped area.

9. A computer device, comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Ultrasonic detection and discrimination method for defects of battery cathode column

    CN121190469A

  • Battery negative pole post defect ultrasonic detection and discrimination method

    CN121190469B