Square battery appearance defect detection method and apparatus, storage medium, and electronic device
By setting up camera modules at different detection positions of square batteries and performing image fusion technology, the problem of low detection efficiency of square batteries in the prior art is solved, and fast and accurate identification of battery appearance defects is achieved.
Patent Information
- Application Number
- PCT/CN2024/085601
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-06-02
- Filing Date
- 2024-04-02
- Publication Date
- 2024-12-05
AI Technical Summary
The prior art is less efficient in detecting the appearance defects of square batteries, especially for the detection of multi-faceted batteries, making it difficult for manual or machine equipment to quickly and accurately identify defects on each surface.
By setting corresponding camera modules at different detection positions, images of each face of the square battery can be captured, and using image synthesis and recognition technology, shape features are extracted, pixel fusion and defect recognition are performed, and the battery appearance defects can be quickly recognized.
It improves the efficiency and accuracy of battery appearance defect detection, ensures the acquisition integrity of images on each side of the square battery, reduces the use of computing resources, and simplifies the image fusion process.
Smart Images

Figure CN2024085601_05122024_PF_FP_ABST
Abstract
Description
Method, device, storage medium and electronic device for detecting appearance defects of square batteries
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application claims priority to Chinese patent application number 202310644737.6 filed with the State Intellectual Property Office of China on June 2, 2023, entitled “Method, device, storage medium and electronic device for detecting appearance defects of square batteries”, the entire contents of which are incorporated by reference into this application. Technical Field
[0003] The present application relates to the field of computer technology, and in particular to a method, device, storage medium, and electronic device for detecting appearance defects of square batteries. Background Art
[0004] With the rapid development of new energy vehicles, power battery production capacity is increasing, and product quality requirements are becoming increasingly stringent. Battery quality inspection includes appearance defect detection, which requires a wide range of inspection types, such as pits, bumps, wrinkles, battery film damage, scratches, etc. These appearance defects not only affect the product appearance, but also pose a huge safety hazard.
[0005] Most of the appearance defect detection of relevant power batteries is done by manual visual inspection. The quality department trains the inspection staff, formulates corresponding operation instructions, and conducts corresponding skill assessments on the staff. Only after passing the assessment can they go to work, thereby completing the appearance inspection of power batteries.
[0006] With the development of artificial intelligence technology, the use of robotic equipment for automatic defect detection has gradually emerged. However, for square-shaped power batteries, they have multiple surfaces, each of which requires defect detection. The related methods of using robotic equipment for defect detection are relatively inefficient.
[0007] Summary of the Invention
[0008] The purpose of this application is to provide a method, device, storage medium and electronic device for detecting appearance defects of square batteries to solve at least one of the above problems.
[0009] Some embodiments of the present application provide a method for detecting appearance defects of a square battery, the method comprising:
[0010] Move the battery to be inspected to a first position, call a first camera module to photograph a first portion of the battery to be inspected, and form a front image and a back image of the battery to be inspected;
[0011] Moving the battery to be inspected to a second position, calling a second camera module to photograph a second portion of the battery to be inspected, to form a left side image and a right side image of the battery to be inspected;
[0012] Moving the battery to be inspected to a third position, calling a third camera module to photograph a third portion of the battery to be inspected, to form a bottom surface image and a top surface image of the battery to be inspected;
[0013] Appearance defects of the battery to be inspected are identified based on the front image, the back image, the left side image, the right side image, the bottom image, and the top surface image.
[0014] In some optional embodiments, the first camera module may include a first line scan camera module and a first 3D camera module, the front image includes a line scan front image and a 3D front image, and the rear image includes a line scan rear image and a 3D rear image. Calling the first camera module to photograph the first portion of the battery to be inspected to form the front image and the rear image of the battery to be inspected may include:
[0015] Move the first line scan camera module and the first 3D camera module along a first direction to collect front image information of the battery to be inspected to form the line scan front image and the 3D front image;
[0016] The battery to be inspected is rotated at the first position by a preset angle, and the first line scan camera module and the first 3D camera module are moved along the second direction to collect rear image information of the battery to be inspected, thereby forming the line scan rear image and the 3D rear image.
[0017] In some optional embodiments, sensing devices are provided on both the first line scan camera module and the first 3D camera module, and the number of sensing devices on the first line scan camera module and the number of sensing devices on the first 3D camera module are 1 or 2 respectively.
[0018] In some optional embodiments, the second camera module may include a second camera module A and a second camera module B. Moving the battery to be inspected to a second position and invoking the second camera module to photograph a second portion of the battery to be inspected to form a left side image and a right side image of the battery to be inspected may include:
[0019] The battery to be inspected passes through the second camera module during the process of moving to the second position. The second camera module A scans the second part of the battery to be inspected during the process of passing through to form the left side image. The second camera module B scans the second part of the battery to be inspected during the process of passing through to form the right side image.
[0020] In some optional embodiments, the second camera module A includes a second line scan camera module A and a second 3D camera module A, the second camera module B includes a second line scan camera module B and a second 3D camera module B, and sensing devices are provided on the second line scan camera module A, the second 3D camera module A, the second line scan camera module B, and the second 3D camera module B. The number of sensing devices on the second line scan camera module A, the second 3D camera module A, the second line scan camera module B, and the second 3D camera module B is 1 or 2 respectively.
[0021] In some optional embodiments, the battery to be inspected is moved to a fourth position, and a fourth camera module is called to capture a fourth portion of the battery to be inspected to form an image of the terminal and the explosion-proof valve of the battery to be inspected.
[0022] The identifying of appearance defects of the battery to be inspected based on the front image, the rear image, the left side image, the right side image, the bottom image, and the top image may include: identifying appearance defects of the battery to be inspected based on the front image, the rear image, the left side image, the right side image, the bottom image, the top image, the pole image, and the explosion-proof valve image.
[0023] In some optional embodiments, identifying appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top side image may include:
[0024] synthesizing the front image and the rear image to form a first synthesized image;
[0025] synthesizing the left side image and the right side image to form a second synthesized image;
[0026] Appearance defects of the battery to be inspected are identified based on the first composite image, the second composite image, the bottom surface image, and the top surface image.
[0027] In some optional embodiments, the synthesizing the front image and the rear image, or the synthesizing the left side image and the right side image includes:
[0028] Extracting the front image and the back image, or the left side image and the right side image to be synthesized;
[0029] Extracting shape features of the front image, the back image, the left side image, and the right side image;
[0030] According to the extracted shape features, the front image and the back image, or the left side image and the right side image with similar shape features are horizontally spliced or vertically spliced or directly fused.
[0031] In some optional embodiments, the synthesizing the front image and the rear image, or the synthesizing the left side image and the right side image includes:
[0032] Determine the front image and the back image, the left side image and the right side image to be synthesized based on the shape features;
[0033] Establish a coordinate system and extract the pixel position coordinates of the front image and the back image, or the left side image and the right side image to be synthesized;
[0034] Calculate the pixel average value of the front image and the back image, or the left side image and the right side image at the same pixel position coordinate;
[0035] The pixel average is used as the pixel value of the synthesized image.
[0036] In some optional embodiments, the line scan front image is a time-sharing line scan front image. After acquiring the front image information of the battery to be inspected and forming the line scan front image and the 3D front image, the following steps may be performed:
[0037] The line scan front image is decomposed according to the time-sharing line scan image and the corresponding scanning rule to form a plurality of line scan front images.
[0038] In some optional embodiments, the identifying appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top image may include: acquiring multiple images of the same portion of the battery to be inspected, fusing the images of the same portion, and identifying the appearance defects of the battery to be inspected based on the fused images, wherein the images of the same portion include one or more of the front image, the back image, the left side image, the right side image, the bottom image, and the top image;
[0039] When the recognition result of one of the fused images is that there is an appearance defect, the unfused image corresponding to the fused image with the appearance defect is separately inspected for appearance defects, and based on the appearance defect recognition result of each image, it is determined whether the corresponding battery has an appearance defect.
[0040] In some optional embodiments, acquiring multiple images of the same part of the battery to be inspected and fusing the images of the same part includes: identifying one or more reference points from each image to be fused, aligning the images to be fused according to the one or more reference points so that the images to be fused have the same position and direction, fusing the pixels corresponding to the reference points representing the same or corresponding positions in the images to be fused, and fusing other pixels in the images to be fused based on the determined reference points.
[0041] In some optional embodiments, the number of images of the same portion of the multiple batteries to be inspected that are acquired is determined according to the yield rate of the batteries.
[0042] Some embodiments of the present application further provide a device for detecting appearance defects of a square battery, the device comprising:
[0043] a first shooting module configured to move the battery to be inspected to a first position, and call the first camera module to shoot a first portion of the battery to be inspected to form a front image and a back image of the battery to be inspected;
[0044] a second shooting module configured to move the battery to be tested to a second position, and call a second camera module to shoot a second portion of the battery to be tested, thereby forming a left side image and a right side image of the battery to be tested;
[0045] a third shooting module configured to move the battery to be inspected to a third position, and call a third camera module to photograph a third portion of the battery to be inspected, thereby forming a bottom surface image and a top surface image of the battery to be inspected;
[0046] The defect recognition module is configured to identify appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top side image.
[0047] In some optional embodiments, the first camera module is slidably connected to the first transmission device via a sliding device, and the third camera module is slidably connected to the second transmission device via a sliding device. In some optional embodiments, the device further includes: a fourth camera module configured to move the battery to be inspected to a fourth position, and to activate the fourth camera module to capture a fourth portion of the battery to be inspected, thereby forming an image of the battery terminal and explosion-proof valve.
[0048] In some optional embodiments, the first camera module includes a first line scan camera module and a first 3D camera module, and the first line scan camera module includes a first line scan camera, a line coaxial device, and a line light device;
[0049] The second camera module includes a second camera module A and a second camera module B, the second camera module A includes a second line scan camera module A and a second 3D camera module A, the second camera module B includes a second line scan camera module B and a second 3D camera module B, the second line scan camera module A includes a second line scan camera A and a line light device A, and the second line scan camera module B includes a second line scan camera B and a line light device B;
[0050] The third camera module includes a third line scan camera module and a third 3D camera module, and the third line scan camera module includes a third line scan camera, a line coaxial device and a line light device;
[0051] The fourth camera module includes an area array camera A and an area array camera B. A linear coaxial light device and a strip light device are sequentially arranged below the area array camera A, and a strip light device is arranged below the area array camera B.
[0052] In some optional embodiments, the defect recognition module is configured to perform first-type battery appearance defect recognition on 3D images captured by the first 3D camera module, the second 3D camera module A, the second 3D camera module B, and the third 3D camera module, and perform second-type battery appearance defect recognition on line scan images captured by the first line scan camera module, the second line scan camera module A, the second line scan camera module B, and the third line scan camera module;
[0053] Among them, the first type of battery appearance defects includes one or more of the following: dents, convex points, appearance damage, scratches, overlapping width and depth of the battery protective layer; the second type of battery appearance defects includes one or more of the following: bubbles in the battery protective layer, dents, convex points, wrinkles, appearance damage, scratches, overlapping width and height of the battery protective layer, surface foreign matter, surface warping, surface fingerprints, etc.
[0054] Some embodiments of the present application further provide a computer-readable storage medium having executable instructions stored thereon. When the executable instructions are executed by a processor, the processor is enabled to execute the method described in any one of the embodiments of the present application.
[0055] Some embodiments of the present application further provide an electronic device, including:
[0056] one or more processors;
[0057] The memory is used to store one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors execute the method described in any embodiment of the present application.
[0058] The above-mentioned square battery appearance defect detection method, device, storage medium and electronic device, by setting corresponding camera modules at different detection positions, and using them to photograph the corresponding parts of the square battery, and specifically through the first camera module, the second camera module, and the third camera module to respectively photograph the first part, the second part, and the third part of the battery to be inspected, effectively ensure the integrity of the image acquisition of the 6 planes of the square battery, so that images of all surfaces of the battery can be obtained at one time, and then the entire battery appearance defect detection can be directly performed on the images of each surface, thereby improving the efficiency of the overall appearance defect identification of the battery. BRIEF DESCRIPTION OF THE DRAWINGS
[0059] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope of the present application.
[0060] FIG1 is a structural diagram of a first part of a battery appearance inspection device provided in some embodiments of the present application;
[0061] FIG2 is a schematic flow chart of a method for detecting appearance defects of square batteries provided in some embodiments of the present application;
[0062] FIG3 is a structural diagram of the second part of the battery appearance inspection device provided in some embodiments of the present application;
[0063] FIG4 is a structural diagram of the third part of the battery appearance inspection device provided in some embodiments of the present application;
[0064] FIG5 is a structural block diagram of a square battery appearance defect detection device provided in some embodiments of the present application.
[0065] Icons: 101-first transmission device; 102-first 3D camera module; 103-line coaxial device; 104-line light device; 105-first line scan camera; 121-line light device A; 122-second line scan camera A; 123-second line scan camera module A and second 3D camera module A; 124-line light device B; 125-second line scan camera B; 126-second line scan camera module B and second 3D camera module B; 141-area array camera A; 142-line coaxial light device; 143-strip light device; 144-strip light device; 145-area array camera B; 502-first shooting module; 504-second shooting module; 506-third shooting module; 510-fourth shooting module; 508-defect recognition module. DETAILED DESCRIPTION
[0066] In order to make the purpose, technical solutions and advantages of this application more clearly understood, the present application is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0067] All terms (including technical and scientific terms) used in this application have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.
[0068] For example, the terms "first," "second," and the like used herein may be used to describe various elements herein, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first camera module may be referred to as a second camera module, and similarly, a second camera module may be referred to as a first camera module. Both the first camera module and the second camera module are camera modules, but they are not the same camera module.
[0069] For example, the terms "include", "comprising", etc. used in this application indicate the existence of features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.
[0070] In some embodiments of the present application, as shown in FIG2 , a method for inspecting the appearance of a square battery is provided. The method may include:
[0071] Step S202: the battery to be inspected is moved to a first position, and a first camera module is called to photograph a first portion of the battery to be inspected to form a front image and a back image of the battery to be inspected.
[0072] In some embodiments, the battery to be tested may be a prismatic battery having six planes, where the six planes may include a front, back, left side, right side, bottom, and top. The prismatic battery may be coated with a protective layer such as a blue film or an aluminum shell, and the electronic device may detect cosmetic defects on the blue film or aluminum shell. One of the sides of the battery to be tested may include a terminal post and an explosion-proof valve, where the terminal post includes a positive terminal post and a negative terminal post.
[0073] The first part may include the front and rear parts of the battery to be inspected, and the first position may be a position where the first camera module on the battery appearance inspection device is suitable for photographing the first part.
[0074] In some embodiments, a conveyor belt or a manipulator is used to transport the battery to be inspected to a first position. The battery appearance inspection equipment is provided with a plurality of workstations, each of which can be used to inspect a different part of the battery. For example, the first workstation is used to inspect the first part of the battery. The first position is located at the first workstation, which may also include a first transmission device. The first transmission device may be a conveyor belt. The first camera module realizes uniform motion in a first direction or a second direction at a first speed under the transmission of the first transmission device. The first direction and the second direction may be one of a horizontal motion direction and a vertical motion direction, respectively. The first position can be set at any position that the first camera module passes through during the uniform motion. When the first camera module passes through the first position during the motion, if the battery to be inspected has been transported to the first position, the first camera module captures an image of the first part of the battery to be inspected.
[0075] In some optional embodiments, the first speed may be any speed such as 0.2 m / s, 0.5 m / s, or 1 m / s. The first speed may be set based on the number of front and rear images of the battery to be inspected required. For example, when there are a large number of batteries to be inspected, in order to increase the inspection speed of the batteries to be inspected, the first speed may be set to 1 m / s so that the batteries to be inspected pass through the first position quickly.
[0076] In some optional embodiments, the first camera module is a module for capturing the appearance image of the first part of the battery, which may include one or more camera devices. For example, it has two different types of camera devices, namely a first line scan camera module and a first 3D camera module. Accordingly, the front image includes a line scan front image and a 3D front image, and the rear image includes a line scan rear image and a 3D rear image. By using different types of camera devices to capture the first part of the battery to be inspected, corresponding different battery appearance images are formed, and then different battery appearance images can be used to jointly detect battery appearance defects in the subsequent process, thereby improving the detection accuracy of appearance defect detection of the battery to be inspected. The number of the first camera modules may be 1 or 2.
[0077] In some optional embodiments, when the first camera module is two, namely, the first camera module A and the first camera module B, the first camera module A and the first camera module B can be relatively arranged on both sides of the first position, and the first part of the battery to be inspected is photographed by the two first camera modules, thereby increasing the number of front images and rear images of the first part of the battery to be inspected, and improving the accuracy of subsequent appearance defect detection of the battery to be inspected.
[0078] In some optional embodiments, the first camera module is slidably connected to the first transmission device through a sliding device. The sliding device is arranged at the bottom of the first camera module. It can be a slide rail arranged in the center of the bottom of the first camera module, or two slide rails arranged on both sides of the bottom of the first camera module. In order to improve the installation stability of the first camera module, the number of sliding devices can be increased.
[0079] In some optional embodiments, a sensing device is provided on the first camera module. When the first camera module passes through a first position, if the sensing device detects that the battery to be inspected is in the first position, a detection signal is issued to drive the first camera module to capture the first portion of the battery to be inspected. Optionally, the sensing device can be a laser sensor, infrared sensor, ultrasonic sensor, photoelectric sensor, or other device capable of detecting the edge of the battery to be inspected.
[0080] In some optional embodiments, the battery to be tested can stay at the first position for a first dwell time to make the image captured by the first camera module clearer. The first dwell time can be any time such as 3s, 5s, 10s, etc. The first dwell time can be set according to the required number of front images and rear images of the battery to be tested. For example, when the number of batteries to be tested is large, in order to increase the detection speed of the batteries to be tested, the first dwell time can be set to a shorter time, such as 1s.
[0081] Step S204 , moving the battery to be inspected to a second position, calling a second camera module to photograph a second portion of the battery to be inspected, and forming a left side image and a right side image of the battery to be inspected.
[0082] In these embodiments, the second position can be set at the second station of the battery appearance inspection equipment, and the second part can include the left and right sides of the battery to be inspected. The battery to be inspected is moved to the second position by a manipulator or a conveyor belt, and the second camera module is fixed near the second position. The battery to be inspected is driven by the manipulator or the conveyor belt to move longitudinally back and forth at the second position past the second camera module, so that the second camera module captures the second part of the battery to be inspected. The second camera module is a module for capturing the appearance image of the second part of the battery, and it can include one or more camera devices. For example, the number of the camera devices can be one or two.
[0083] In some optional embodiments, the second camera module includes two different types of camera devices: a second line scan camera module and a second 3D camera module. Each camera device can independently capture the second portion, forming an independent image. The left side profile image includes a line scan left side profile image and a 3D left side profile image, and the right side profile image includes a line scan right side profile image and a 3D right side profile image.
[0084] In some optional embodiments, the number of second camera modules can be 2, and the second camera module includes a second camera module A and a second camera module B. The second camera module A and the second camera module B are respectively arranged at the upper and lower parts of the second position, respectively detecting the left side image and the right side image of the battery to be inspected.
[0085] In some optional embodiments, the number of the second camera module can be one, and the second camera module can be set at the upper or lower part of the second position. After the left side image or the right side image of the battery to be inspected is acquired, the battery to be inspected is rotated 180 degrees using a manipulator or a rotation module to acquire the image of the other side of the battery to be inspected.
[0086] In these embodiments, the battery to be inspected can be moved at a second constant speed and pass through a second camera module. A second sensing device is provided on the second camera module. When the battery to be inspected is moved at the second constant speed and passes through the second camera module, the second sensing device emits a detection signal, driving the second camera module to capture a second portion of the battery to be inspected. For example, the second sensing device can be a laser sensor, infrared sensor, ultrasonic sensor, photoelectric sensor, or other device capable of detecting the edge of the battery to be inspected. The second speed can be any speed, such as 0.2 m / s, 0.5 m / s, or 1 m / s. The second speed can be the same as the first speed or a different value. The second speed can be set based on the number of left and right side images of the battery to be inspected required.
[0087] In some optional embodiments, the battery to be inspected can stay at the second position for a second dwell time to make the image captured by the second camera module clearer. The second dwell time can be, for example, any time such as 3s, 5s, 10s, etc. The second dwell time can be set according to the required number of left side images and right side images of the battery to be inspected.
[0088] Step S206 , moving the battery to be inspected to a third position, calling a third camera module to photograph a third portion of the battery to be inspected, and forming a bottom surface image and a top surface image of the battery to be inspected.
[0089] In some embodiments of the present application, a conveyor belt or a manipulator of a battery appearance inspection device is used to transport the battery to be inspected to a third position. The third position can be set at the third station of the battery appearance inspection device, wherein the third part of the battery to be inspected can include the bottom and top surfaces of the battery to be inspected. The third station can also include a second transmission device, which can be a conveyor belt. The third camera module can achieve uniform motion in the first direction or the second direction at a third speed under the transmission of the second transmission device. The third position can be set at any position that the third camera module passes through during the uniform motion. When the third camera module passes through the third position during its motion, if the battery to be inspected has been transported to the third position, the third camera module captures an image of the third part of the battery to be inspected. Specifically, the third speed can be any speed such as 0.2m / s, 0.5m / s, 1m / s, etc. The third speed can be the same value as the first speed and the second speed, or the third speed can be a value different from the first speed and the second speed. The third speed can be set according to the required number of bottom surface images and top surface images of the batteries to be detected. For example, when the number of batteries to be detected is large, in order to increase the detection speed of the batteries to be detected, the third speed can be set to 1m / s so that the batteries to be detected pass through the third position quickly.
[0090] In some optional embodiments, the third camera module may be a module for capturing the appearance of a third portion of the battery to be inspected, and may include one or more camera devices. For example, it may include two different types of camera devices: a third line scan camera module and a third 3D camera module. The bottom surface image includes a line scan bottom surface image and a 3D bottom surface image, and the top surface image includes a line scan top surface image and a 3D top surface image. Capturing the third portion of the battery to be inspected using different types of camera devices improves the inspection accuracy of the battery to be inspected. The number of third camera modules may be one or two.
[0091] In some optional embodiments, when there are two third camera modules, such as a third camera module A and a third camera module B, the third camera module A and the third camera module B can be relatively arranged on both sides of the third position, and the third part of the battery to be inspected is photographed by two third camera modules, thereby increasing the number of bottom surface images and top surface images of the third part of the battery to be inspected, and improving the accuracy of subsequent appearance defect detection of the battery to be inspected.
[0092] In some optional embodiments, the third camera module can be slidably connected to the second transmission device through a sliding device. The sliding device is arranged at the bottom of the third camera module. It can be a slide rail arranged in the center of the bottom of the third camera module, or two slide rails arranged on both sides of the bottom of the third camera module. In order to improve the installation stability of the third camera module, the number of sliding devices can be increased.
[0093] In some optional embodiments, the third camera module may be provided with a sensing device. When the third camera module passes through a third position, if the sensing device detects that the battery to be inspected is in the third position, a detection signal is issued to drive the third camera module to capture a third portion of the battery to be inspected. Specifically, the sensing device may be a laser sensor, infrared sensor, ultrasonic sensor, photoelectric sensor, or other device capable of detecting the edge of the battery to be inspected.
[0094] In some optional embodiments, the battery to be inspected can stay at a third position for a third dwell time to make the image captured by the third camera module clearer. The third dwell time can be any time, such as 3s, 5s, 10s, etc. The third dwell time can be set according to the required number of bottom surface images and top surface images of the battery to be inspected.
[0095] In some optional embodiments, the first dwell time of the battery to be inspected at the first position, the second dwell time at the second position, and the third dwell time at the third position can be the same and can occur at the same time. For example, when there are multiple batteries to be inspected on the battery appearance inspection device and they are moved synchronously for inspection, at a certain moment, battery A to be inspected moves to the first position, battery B to be inspected moves to the second position, and battery C to be inspected moves to the third position. At this time, the first dwell time of battery A to be inspected at the first position, the second dwell time of battery B to be inspected at the second position, and the third dwell time of battery C to be inspected at the third position are the same because the movement of the batteries to be inspected is synchronized. Setting the stay and movement of the battery to be inspected at the three positions to be synchronized can improve the efficiency of the overall appearance defect identification of the battery.
[0096] Step S208 , identifying appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top side image.
[0097] In some embodiments of the present application, a corresponding battery appearance defect recognition model is pre-set, and the battery appearance defect recognition can be performed through this model. The appearance defects of the battery may include one or more defect types such as concave spots, convex spots, appearance damage, scratches, overlapping width of the battery protective layer, protective layer height, surface foreign matter, wrinkles, warping, fingerprints, dirt, etc. Optionally, the battery appearance defect recognition model may be a convolutional neural network model. The system can construct a convolutional neural network model for each or several defect types, use each image as the input of the corresponding model, and use different convolutional neural network models to perform corresponding defect recognition. In this way, it is detected whether there is a corresponding defect.
[0098] In some embodiments of the present application, identifying appearance defects of batteries to be inspected based on a convolutional neural network model includes:
[0099] Acquire images of a battery to be inspected, wherein the images to be inspected include a front image, a back image, a left side image, a right side image, a bottom image, and a top image; input the images to be inspected into a battery appearance defect recognition model for feature extraction, extract low-order features such as edges, line segments, and contours of the images to be inspected based on a convolution module, and integrate the low-order features based on a downsampling convolution module; perform secondary integration of the integrated low-order features based on a fully connected neural network to perform battery appearance defect recognition, and output a recognition result.
[0100] In some optional embodiments, establishing a battery appearance defect recognition model may include: obtaining battery defect images with labeled appearance defects; performing noise reduction processing on the battery defect images to eliminate interference; performing image data enhancement processing on the battery defect images; based on the enhanced battery defect images, dividing the battery defect images into a training set and a test set, extracting defect features of the training set through a convolutional neural network model, and identifying the defect features. Adjusting the network parameters of the convolutional neural network model, calculating the recognition accuracy of the battery appearance defect recognition through the test set, and when the recognition accuracy is lower than a threshold, adjusting the network parameters of the convolutional neural network model again, training the convolutional neural network model through the training set, and calculating the recognition accuracy of the battery appearance defect recognition again through the test set, until the recognition accuracy reaches the threshold.
[0101] In some optional embodiments, image data enhancement processing includes data balancing, color enhancement, and orientation enhancement. Data balancing involves expanding the battery defect images of six planes with different battery appearance defect types; color enhancement involves randomly changing the brightness, contrast, and saturation of the battery defect images, or adding Gaussian noise to the battery defect images; and orientation enhancement involves horizontally, vertically, or randomly flipping the battery defect images. Image data enhancement expands the image data of the battery defect images and improves the recognition accuracy of the convolutional neural network model.
[0102] In the square battery appearance defect detection method provided in some embodiments of the present application, the first, second and third parts of the battery to be inspected are photographed respectively by the first camera module, the second camera module and the third camera module, thereby effectively ensuring the integrity of the image acquisition of the six planes of the square battery, so that images of all surfaces of the battery can be obtained at one time, thereby improving the efficiency of the overall appearance defect identification of the battery.
[0103] In some optional embodiments, the first camera module may include a first line scan camera module and a first 3D camera module, the front image includes a line scan front image and a 3D front image, and the rear image includes a line scan rear image and a 3D rear image. Step S202 includes: moving the first line scan camera module and the first 3D camera module along a first direction to capture front image information of the battery to be inspected, forming a line scan front image and a 3D front image; rotating the inspection battery at a preset angle in the first position, moving the first line scan camera module and the first 3D camera module along a second direction to capture rear image information of the battery to be inspected, forming a line scan rear image and a 3D rear image.
[0104] In some embodiments, the first line scan camera module can be a linear array camera that uses a time-sharing line scan method to capture the front image and the back image of the battery to be tested, and the first 3D camera module can be a 3D camera. The first direction and the second direction can be left and right movement directions, and the preset angle can be a suitable angle determined according to the device structure, such as 90 degrees or 180 degrees. In this embodiment, the detection battery can be rotated by the preset angle in the first position by a robot clamping the battery to be tested and rotating 180 degrees around the center position of the battery to be tested as an axis, or a rotation module can be set at the bottom of the battery to be tested, and the rotation module can be set on a conveyor belt that moves the battery to be tested. The rotation module rotates 180 degrees to drive the battery to be tested to rotate.
[0105] In some embodiments, the first line scan camera module and the first 3D camera module of the first camera module can be respectively disposed at different positions of the first transmission device, and the first line scan camera module and the first 3D camera module sequentially capture the first portion of the battery to be inspected in the order in which they pass by the battery to be inspected. The first direction can be either from left to right or from right to left, and the second direction is a direction of movement opposite to the first direction.
[0106] In some embodiments, the first line scan camera module and the first 3D camera module may both be provided with a sensing device, and the number of sensing devices on the first line scan camera module and the number of sensing devices on the first 3D camera module may be 1 or 2 respectively.
[0107] In some optional embodiments, the first line scan camera module and the first 3D camera module each have one sensing device, which can be set at a side edge position of the first line scan camera module and the first 3D camera module. When the first line scan camera module or the first 3D camera module passes the first position, the sensing device detects the edge of the battery to be detected and sends a detection signal. The detection signal of the sensing device serves as a starting signal for starting shooting. After receiving the detection signal, the first line scan camera module and the first 3D camera module start to shoot continuously until all the batteries to be detected at the first position are shot. Specifically, when the sensing device on the first line scan camera module and the first 3D camera module does not detect the edge of the battery to be detected within a preset time, it indicates that all the batteries to be detected at the first position have been shot, and the first line scan camera module and the first 3D camera module stop shooting. The preset time can be any time such as 2s, 3s, 10s, etc.
[0108] In some optional embodiments, the number of sensing devices on the first line scan camera module and the first 3D camera module may be two respectively, and a sensing device is set on both side edges of the first line scan camera module and the first 3D camera module respectively to sense both side edges of the battery to be detected. For example, when the first line scan camera module passes through the first position, the left side of the first line scan camera module first passes through the edge of the battery to be detected, and the left sensing device of the first line scan camera module senses the edge of the battery to be detected, and sends a detection signal to drive the first line scan camera module to start shooting the first part of the battery to be detected. The right side of the first line scan camera module then passes through the edge of the battery to be detected. When the right sensing device of the first line scan camera module senses the edge of the battery to be detected for the first time, the battery to be detected has not completely passed through the first line scan camera module. When the right sensing device of the first line scan camera module senses the edge of the battery to be detected for the second time, a stop signal is sent, indicating that the first line scan camera module has passed the battery to be detected and enters the shooting of the next battery to be detected.
[0109] In some embodiments, the shooting frequency of the first line scan camera module and the first 3D camera module can be set according to the system memory and the rate at which the server processes images. For example, the shooting frequency of the first line scan camera module is to shoot 10 images in 1s, and the shooting frequency of the first 3D camera module is to shoot 15 images in 1s.
[0110] For example, as shown in Figure 1, the battery appearance inspection equipment includes a first transmission device 101 at the first workstation, a first 3D camera module 102 located on one side of the first transmission device 101, and a first line scan camera module. The first line scan camera module includes a first line scan camera 105, a line coaxial device 103, and a line light device 104. When the battery to be inspected is in the first position, the first transmission device 101 drives the first 3D camera module 102 and the first line scan camera module to move from right to left. The first 3D camera module 102 and the first line scan camera module sequentially scan and capture images of the front surface of the battery to be inspected in the first position, respectively obtaining a line scan front image and a 3D front image.
[0111] After that, the battery to be inspected can be rotated 180° at the first position, and the first transmission device 101 drives the first 3D camera module 102 and the first line scan camera module to move from left to right. The first 3D camera module 102 and the first line scan camera module scan and capture images of the back of the battery to be inspected in the first position in turn, and obtain a line scan back image and a 3D back image, respectively.
[0112] In some optional embodiments, the third camera module has the same configuration as the first camera module, which will not be described in detail here.
[0113] In some optional embodiments, the second camera module includes a second camera module A and a second camera module B. Step S204 includes: when the battery to be inspected passes through the second camera module during the process of moving to the second position, the second camera module A scans the second portion of the battery to be inspected during the process of passing through to form a left side image, and the second camera module B scans the second portion of the battery to be inspected during the process of passing through to form a right side image.
[0114] In some embodiments, the second position is located at the rearmost position of the second station. For example, the second camera module A is located in front of the second camera module B, and the second position is located behind the second camera module B. As the battery to be inspected moves longitudinally backward, it first passes through the second camera module A, then the second camera module B, and finally reaches the second position. The battery to be inspected is positioned with its left side facing up and its right side facing down, or with its right side facing up and its left side facing down. The second camera module A is positioned with its lens facing up or down, and the lens of the second camera module B is oriented in the opposite direction to that of the second camera module A.
[0115] In some optional embodiments, the second camera module A includes a second line scan camera module A and a second 3D camera module A, and the second camera module B includes a second line scan camera module B and a second 3D camera module B. Similar to the first line scan camera module and the first 3D camera module, the second line scan camera module A, the second 3D camera module A, the second line scan camera module B, and the second 3D camera module B are also provided with sensing devices. The number of sensing devices thereon may also be one or two, and the configuration of the sensing devices is consistent with that of the first line scan camera module and the first 3D camera module.
[0116] In some embodiments, the second line scan camera module A and the second 3D camera module A of the second camera module A and the second line scan camera module B and the second 3D camera module B of the second camera module B also have a shooting frequency that can be set according to the system memory and the rate at which the server processes images.
[0117] For example, as shown in FIG3 , the battery appearance inspection device is provided with a second camera module A and a second camera module B at the upper and lower ends of the second workstation. The second camera module A includes a second line scan camera module A and a second 3D camera module A (123); the second camera module B includes a second line scan camera module B and a second 3D camera module B (126). The second line scan camera module A includes a second line scan camera A (122) and a line light device A (121). The second line scan camera module B includes a second line scan camera B (125) and a line light device B (124).
[0118] When the battery to be inspected is in the second position, the battery to be inspected moves longitudinally back and forth, and the second line scan camera module A and the second 3D camera module A scan and take images of one of the left side or right side of the battery to be inspected. Correspondingly, the second line scan camera module B and the second 3D camera module B scan and take images of the other side of the left side or right side of the battery to be inspected, and obtain a line scan left side image, a line scan right side image, a 3D left side image, and a 3D right side image, respectively.
[0119] In some optional embodiments, before step S208, the method further includes moving the battery to be inspected to a fourth position, calling a fourth camera module to photograph a fourth part of the battery to be inspected, and forming an image of the pole and the explosion-proof valve of the battery to be inspected.
[0120] In some embodiments, the battery to be inspected also has a pole and an explosion-proof valve, and the system further inspects the pole and explosion-proof valve. Specifically, the battery appearance inspection equipment is also provided with a fourth camera module for photographing the pole and explosion-proof valve. The battery to be inspected is moved to the fourth position by a conveyor belt or a manipulator, and the fourth camera module includes an area array camera A and an area array camera B. The fourth position includes a fourth position A and a fourth position B. The fourth part of the battery to be inspected includes the pole and explosion-proof valve of the battery to be inspected, and the pole includes a positive pole and a negative pole. The positive pole and the negative pole are symmetrically distributed on both sides of the left side or right side of the battery to be inspected, and the side where the pole and the explosion-proof valve of the battery to be inspected are located faces the camera of the fourth camera module.
[0121] In some optional embodiments, the fourth position A is located directly below the lens of the area array camera A, and the fourth position B is located directly below the lens of the area array camera B.
[0122] In some optional embodiments, the fourth position A is located at any position within the shooting range of the area array camera A, and may not be directly below the lens of the area array camera A. The fourth position B is located at any position within the shooting range of the area array camera B, and may not be directly below the lens of the area array camera B. The shooting ranges of the area array cameras A and B are set according to camera parameters.
[0123] Specifically, area array cameras A and B are equipped with sensing devices. When sensing a battery to be inspected, area array camera A captures an image of the terminal while area array camera B captures an image of the explosion-proof valve. Alternatively, area array camera B captures an image of the terminal while area array camera A captures an image of the explosion-proof valve. The capture frequencies A and B of area array camera A and B can be set based on the server's image processing rate, system memory, and the required number of images of the terminal and explosion-proof valve.
[0124] In some optional embodiments, after the area array camera A or the area array camera B completes capturing the image of one of the positive and negative electrodes, the battery to be inspected is rotated 180 degrees about the battery centerline using a rotation module or manipulator disposed at the bottom of the battery to be inspected, and an image of the other of the positive and negative electrodes is captured.
[0125] In some optional embodiments, the battery to be tested stays at the fourth position A and the fourth position B for a fourth dwell time A and a fourth dwell time B, respectively. The fourth dwell time A and the fourth dwell time B may be the same or different times. The fourth dwell time A and the fourth dwell time B are related to the rate at which the server processes images, the system memory, and the number of required pole images and explosion-proof valve images.
[0126] For example, as shown in FIG4 , the fourth station of the battery appearance inspection equipment includes a fourth camera module, which includes an array camera A (141) and an array camera B (145). A linear coaxial light device (142) and a strip light device (143) are sequentially arranged below the array camera A (141), and a strip light device (144) is arranged below the array camera B (145). The battery to be inspected stays at the fourth position for a fourth stay time, and the array camera A (141) and the array camera B (145) respectively take images of the battery pole and the explosion-proof valve to be inspected, thereby obtaining an image of the pole and an image of the explosion-proof valve of the battery to be inspected, wherein the pole image includes an image of the positive pole and an image of the negative pole.
[0127] In some optional embodiments, step S208 includes: identifying appearance defects of the battery to be inspected based on the front image, back image, left side image, right side image, bottom image, top image, pole image, and explosion-proof valve image.
[0128] In some embodiments, a battery appearance defect recognition model is established based on a convolutional neural network, and the acquired front image, back image, left side image, right side image, bottom image, top image, pole image, and explosion-proof valve image are input into the battery appearance defect recognition model for feature extraction and recognition, and the recognition result is output.
[0129] In some optional embodiments, different types of defect detection are performed on images captured by different types of camera modules. For example, the first type of battery appearance defect recognition is performed on the 3D images captured by the above-mentioned 3D camera modules, and the second type of battery appearance defect recognition is performed on the line scan images captured by the line scan camera modules. The first type of battery appearance defects include one or more of concave spots, convex spots, appearance damage, scratches, and the depth of the overlapping width of the battery protective layer; the second type of battery appearance defects include one or more of battery protective layer bubbles, concave spots, convex spots, wrinkles, appearance damage, scratches, the overlapping width of the battery protective layer, the height of the battery protective layer, surface foreign matter, surface warping, and surface fingerprints. The protective layer can be a blue film.
[0130] Using different types of images to identify different types of defects can improve the comprehensiveness of battery defect identification.
[0131] For example, taking the battery's protective layer as a blue film, for the 3D front image and the 3D back image formed by the first 3D camera module, the first type of battery appearance defects identified include: blue film convex and concave points, blue film damage, blue film scratches, depth measurement of blue film overlap width and other defects; for the line scan front image and the line scan back image formed by the first line scan camera module, the first type of battery appearance defects identified include: blue film bubbles, blue film concave and convex points, blue film wrinkles, blue film damage, blue film scratches, blue film overlap width, blue film height, foreign matter on the film surface, film warping, blue film fingerprints, etc.; for the 3D left side image and the 3D right side image formed by the second 3D camera module A and the second 3D camera module B respectively, the first type of battery appearance defects identified include: blue film concave and convex points, blue film wrinkles, blue film damage, blue film scratches, blue film overlap width, blue film height, foreign matter on the film surface, film warping, blue film fingerprints, etc. Membrane damage, blue film scratches, U-shaped folded ears, pole scratches, pole concave points, pole parallelism, pole flatness, explosion-proof valve damage and other defects; the second line scan camera module A and the second line scan camera module B respectively capture the line scan left side image and the line scan right side image to identify the first category of battery appearance defects including: membrane bubbles, blue film concave and convex points, blue film wrinkles, blue film damage, blue film scratches, foreign matter on the membrane surface, membrane lift, blue film fingerprints, U-shaped folded ears and other defects; the pole image captured by the area array camera A is used to identify the third category of battery appearance defects including: pole scratches, pole dirt, pole welding slag and other defects; and the explosion-proof valve image captured by the area array camera B is used to identify the fourth category of battery appearance defects including: explosion-proof valve damage, explosion-proof valve dirt, explosion-proof valve leakage and other defect detection.
[0132] It can be understood that different types of images can identify the same type of defects. When one of the images identifies the presence of a corresponding defect, it can be directly determined that the corresponding part of the battery has the corresponding defect.
[0133] In some optional embodiments, when different types of images representing the same part produce different recognition results for the same defect, these results can be marked as suspected defects and subsequently manually assisted in the judgment. Furthermore, when this occurs, the specific type of image causing the error can be identified, and the recognition model corresponding to that type of image can be trained and optimized to improve its recognition accuracy.
[0134] For example, when defect recognition is performed on both a 3D front image and a line scan front image, the recognition results may indicate that the 3D front image does not contain a blue film concave-convex defect, while the line scan front image does. This creates a discrepancy between the two. This can be flagged as a suspected blue film concave-convex defect on the front of the battery, requiring manual analysis. If manual analysis indicates the presence of a blue film concave-convex defect, this indicates an incorrect assessment of the blue film concave-convex defect in the 3D front image. The model can then be retrained and optimized to improve the accuracy of this defect assessment.
[0135] In some optional embodiments, images of the same type and with identical or symmetrical parts can be combined to form a composite image, and appearance defects can be identified based on the composite image. For example, if the front and back parts of a square battery are identical, as well as the left and right parts, the front and back images can be combined, and the left and right side images can be combined.
[0136] Before step S208, the method also includes an image synthesis step, including: synthesizing the front image and the back image to form a first synthesized image; synthesizing the left side image and the right side image to form a second synthesized image; and identifying the appearance defects of the battery to be inspected based on the first synthesized image, the second synthesized image, the bottom image, and the top image.
[0137] In some embodiments, the front image and the back image, and the left side image and the right side image are images of the same battery to be inspected.
[0138] In some embodiments, synthesizing the front image and the rear image, or the left side image and the right side image, includes: extracting the front image and the rear image, or the left side image and the right side image to be synthesized; extracting shape features of the front image and the rear image, or the left side image and the right side image; and horizontally, vertically, or directly fusing the front image and the rear image, or the left side image and the right side image, having similar shape features based on the extracted shape features. The shape features include length and width, aspect ratio features, outline features, and area features.
[0139] In some optional embodiments, synthesizing the front image and the rear image, or synthesizing the left side image and the right side image includes: determining the front image and the rear image, or the left side image and the right side image to be synthesized based on shape features; establishing a coordinate system, extracting the pixel position coordinates of the front image and the rear image, or the left side image and the right side image to be synthesized; calculating the pixel average value of the front image and the rear image, or the left side image and the right side image at the same pixel position coordinates; and using the pixel average value as the pixel value of the synthesized image.
[0140] In some embodiments, the coordinate system includes a two-dimensional coordinate system and a spatial coordinate system. In the two-dimensional coordinate system, the pixel position coordinates of the line scan image captured by the line scan camera module are extracted, and in the spatial coordinate system, the pixel position coordinates of the 3D image captured by the 3D camera module are extracted.
[0141] In some optional embodiments, one or more reference points may be identified from each image to be fused, and pixels corresponding to reference points representing the same or corresponding positions in the images to be fused are fused. Based on the determined reference points, other pixels in the images to be fused are fused. For example, the images to be fused include a 3D front image and a 3D rear image, wherein four reference points representing the positions of the four vertices of the front of the battery are determined by identifying the 3D front image. Similarly, four reference points representing the four vertices of the rear of the battery are also identified from the 3D rear image. Then, the reference points that match each other in these four pairs of reference points are fused, and based on this, the remaining pixels in the two images are fused.
[0142] Specifically, by independently photographing the six faces of the square battery, each face is photographed in a fixed position (i.e., the first position, the second position, and the third position), the images of the same face of each battery are consistent. On this basis, the four vertices of each face are used as reference points to ensure the same direction and position, so as to perform image alignment, so that multiple images can be fused without spending a lot of computing resources, and battery surface defect detection can be performed based on the fused image. In some optional embodiments, for multiple images to be fused, the multiple images can be aligned first, and then the pixels at corresponding positions in the multiple images can be merged according to the corresponding weights to form a fused image. Optionally, after the merging, the merged image can also be edge processed and post-processed to finally form a fused image.
[0143] The images can be aligned using the same reference point method as described above, ensuring they share the same position and orientation. Regarding weighting, each image can have the same normalized weight, or the normalized weights assigned to pixels suspected of having defects can be increased based on information such as grayscale, brightness, and color. This improves the accuracy of identifying defects in the fused image.
[0144] In some optional embodiments, the fused image can be a grayscale image. The weight setting can be determined based on the grayscale values of each defect type in the image. This prevents defect recognition failures caused by fusing pixels at the same corresponding location. For example, if there is a bubble defect at a certain location in the front image, and a damage defect at the corresponding location in the back image, the resulting fused pixel will have a normal value after the two are neutralized. Therefore, setting different weights can reduce the probability of this occurring.
[0145] In the above method, by fusing multiple images representing the same or symmetrical parts of the battery into one image, subsequent defect detection can be completed by only recognizing one image, reducing the amount of data that needs to be analyzed, thereby improving the efficiency of battery defect detection.
[0146] In some optional embodiments, when a defect is detected in the fused image, individual defect identification can be performed on the fused image to identify which side of the battery has the defect. If no defect is detected in the fused image, the battery portion represented by the fused image can be directly determined to be free of defects.
[0147] In some optional embodiments, the image synthesis step further includes: acquiring multiple images of the same or corresponding parts of the battery to be inspected, fusing the images of the same or corresponding parts, and identifying appearance defects of the battery to be inspected based on the fused images.
[0148] Specifically, the images of the same part of the multiple batteries to be inspected can be images of the same part of any number of two or more different batteries to be inspected. The images of the same or corresponding parts of the multiple batteries to be inspected are identified and acquired based on the shape features of the images. The images of the same or corresponding parts are fused, including horizontal or vertical splicing based on the shape features, or image fusion based on the average pixel position coordinates of the same pixel position in a coordinate system. The coordinate system includes a two-dimensional coordinate system and a spatial coordinate system. In the two-dimensional coordinate system, the pixel position coordinates of the line scan image captured by the line scan camera module are extracted, and in the spatial coordinate system, the pixel position coordinates of the 3D image captured by the 3D camera module are extracted.
[0149] Corresponding parts refer to two or more parts that are identical or symmetrical in shape. Symmetry refers to the one-to-one correspondence in size, shape, and arrangement between two pairs of parts on a figure or object. For example, the front and back of a square battery are corresponding parts, as are the left and right sides. However, since the top surface has a terminal and explosion-proof valve, while the bottom surface does not, these two parts are not corresponding parts.
[0150] In some optional embodiments, the step of further performing appearance defect detection on the fused images is further included, including: when the recognition result of one of the fused images is that there is an appearance defect, performing appearance defect detection on the unfused image corresponding to the fused image with the appearance defect separately, and determining whether the corresponding battery has an appearance defect based on the appearance defect recognition result of each image.
[0151] In this embodiment, the fused image is an image fusion performed based on the pixel average value. When there is an appearance defect in the fused image, the pixel position coordinates of the image area where the appearance defect is located are obtained, and the pixel sum is calculated based on the pixel average value to determine the unfused image that may have the appearance defect. The unfused image that may have the appearance defect is separately identified for the defect to determine the specific battery with the appearance defect.
[0152] In some optional embodiments, the fused image is a horizontal or vertical splicing of images based on shape features, and the corresponding unfused image is determined based on the image area where the appearance defect is located to determine the specific battery with the appearance defect.
[0153] Specifically, the specific battery having the appearance defect is determined according to the shooting time of the battery to be inspected.
[0154] In some optional embodiments, the number of images selected can be determined based on the battery's yield rate. Specifically, the number of batteries to be fused is determined based on the yield rate, and then the same or corresponding parts of the corresponding number of batteries are selected for fusion. Based on this, the system can determine an appropriate number of images to avoid the frequent need to re-return to determine which image contains the defect, which in turn does not significantly reduce the number of images required for inspection, or even leads to an increase in the number of images required for inspection.
[0155] For example, if the yield rate is 90%, it means there is usually a 10% probability of defects. In this case, the number of batteries represented in the image to be fused can be set to less than 10. For example, images of the same or corresponding parts of four batteries can be fused.
[0156] Generally speaking, since the yield rate of battery defects rarely exceeds 50%, by determining the number of images to be fused based on the yield rate, the total number of images required for defect detection can be less than the number of images required for individual defect detection. While occupying fewer image fusion resources, the overall defect detection efficiency of large quantities of square batteries can be improved.
[0157] In some optional embodiments, similarly, for multiple images of the same or corresponding parts of batteries to be inspected, the multiple images may be aligned first, and then the pixels at corresponding positions in the multiple images may be merged according to corresponding weights to form a fused image.
[0158] In some optional embodiments, step S202 further includes decomposing the line scan front image according to the time-sharing line scan image according to the corresponding scanning rule to form a plurality of line scan front images.
[0159] In this embodiment, the front image of the time-sharing line scan is a composite image of the light source output by the time-sharing line scan. Specifically, the time-sharing line scan is a first line scan camera module with two different light sources, line light and line coaxial light. When the first line scan camera module collects the front image and the back image of the battery to be tested, it switches the type of light source according to the scanning rules, so that the line light and the line coaxial light imaging are arranged in an orderly manner in the image, and outputs a composite image of the light source under two different light sources.
[0160] In some optional embodiments, the scanning rule may be to sequentially switch between the line light and the line-coaxial light within a scanning cycle according to a set scanning frequency. For example, within a scanning cycle of 1 second, the line light and the line-coaxial light are alternately scanned as the first line scan camera module scans each line of the image.
[0161] In some optional embodiments, the scanning rule may be to sequentially switch between the line light and the line coaxial light within a scanning cycle according to a preset timing. For example, a scanning cycle of 3 seconds may be configured with a preset timing of 1 second for the line light scan and 2 seconds for the coaxial light scan, and the scanning may be performed according to the timing.
[0162] By using time-sharing line scan images for image scanning and acquisition, the efficiency of image acquisition can be improved and the number of camera modules can be reduced.
[0163] In the square battery appearance defect detection method provided in some embodiments of the present application, the object to be photographed is a square battery with six faces, and the camera will stay for a corresponding time when photographing the front image, the back image, the bottom image, and the top image, and will photograph the images of the corresponding faces at fixed first positions, second positions, and third positions, so that each of the six faces of the square battery has an independent image, and the images presented by the same face photographed for each battery are consistent. On this basis, combined with the image fusion technology, the four vertices of each face are used as reference points to align the images, and the pixels corresponding to the same position in the image to be fused are fused, so that the defect detection of multiple batteries can be completed at one time. By sacrificing the volume of the detection equipment to make image fusion simpler and more convenient, it avoids the overly complex image fusion process that consumes more computing resources, thereby ultimately improving the defect detection efficiency of square batteries.
[0164] In some embodiments of the present application, as shown in FIG5 , a device for detecting appearance defects of square batteries is provided, and the device may include:
[0165] The first shooting module 502 is configured to move the battery to be inspected to a first position, call the first camera module to shoot a first part of the battery to be inspected, and form a front image and a back image of the battery to be inspected;
[0166] The second shooting module 504 is configured to move the battery to be inspected to a second position, and call the second camera module to shoot a second part of the battery to be inspected to form a left side image and a right side image of the battery to be inspected;
[0167] The third shooting module 506 is configured to move the battery to be inspected to a third position, call the third camera module to photograph a third portion of the battery to be inspected, and form a bottom surface image and a top surface image of the battery to be inspected;
[0168] The defect recognition module 508 is configured to recognize appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top side image.
[0169] In some optional embodiments, the first camera module includes a first line scan camera module and a first 3D camera module, the front image includes a line scan front image and a 3D front image, and the rear image includes a line scan rear image and a 3D rear image. The first shooting module 502 is also configured to move the first line scan camera module and the first 3D camera module along a first direction to collect front image information of the battery to be inspected, forming a line scan front image and a 3D front image; rotate the battery to be inspected at a preset angle in the first position, move the first line scan camera module and the first 3D camera module along a second direction to collect rear image information of the battery to be inspected, forming a line scan rear image and a 3D rear image.
[0170] In some optional embodiments, the second camera module includes a second camera module A and a second camera module B, and the second camera module 504 is also configured to allow the battery to be inspected to pass through the second camera module while moving to the second position. The second camera module A scans the second part of the battery to be inspected while passing through the second position to form a left side image, and the second camera module B scans the second part of the battery to be inspected while passing through the second position to form a right side image.
[0171] In some optional embodiments, the square battery appearance defect detection device also includes a fourth shooting module 510, which is configured to move the battery to be inspected to a fourth position, call the fourth camera module to shoot the fourth part of the battery to be inspected, and form a pole image and an explosion-proof valve image of the battery to be inspected.
[0172] The defect recognition module 508 is further configured to identify appearance defects of the battery to be inspected based on the front image, back image, left side image, right side image, bottom image, top image, pole image, and explosion-proof valve image.
[0173] In some optional embodiments, the defect recognition module 508 is also configured to synthesize the front image and the back image to form a first synthesized image; synthesize the left side image and the right side image to form a second synthesized image; and identify the appearance defects of the battery to be inspected based on the first synthesized image, the second synthesized image, the bottom image, and the top image.
[0174] In some optional embodiments, the defect recognition module 508 is further configured to decompose the line scan front image according to the time-sharing line scan image according to the corresponding scanning rules to form a plurality of line scan front images.
[0175] In some optional embodiments, the defect recognition module 508 is further configured to obtain multiple images of the same part of the battery to be inspected, fuse the images of the same part, and identify the appearance defects of the battery to be inspected based on the fused images, where the images of the same part include one or more of the front image, the back image, the left side image, the right side image, the bottom image, and the top image; when the recognition result of one of the fused images is that there is an appearance defect, the unfused image corresponding to the fused image with the appearance defect is separately detected for appearance defects, and based on the appearance defect recognition result of each image, it is determined whether the corresponding battery has an appearance defect.
[0176] In some embodiments of the present application, a computer-readable storage medium is further provided, on which executable instructions are stored. When the instructions are executed by a processor, the processor executes the steps in the above-mentioned method embodiments.
[0177] In some embodiments of the present application, an electronic device is also provided, comprising one or more processors; a memory, wherein one or more programs are stored in the memory, wherein when the one or more programs are executed by one or more processors, the one or more processors execute the steps in the above-mentioned method embodiments.
[0178] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some or all of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.
[0179] Furthermore, those skilled in the art will appreciate that although some embodiments herein include certain features included in other embodiments but not other features, combinations of features from different embodiments are intended to be within the scope of this application and to form different embodiments. For example, in the claims above, any of the claimed embodiments may be used in any combination. The information disclosed in this background section is intended solely to enhance understanding of the overall background art of this application and should not be construed as an admission or any implication that such information constitutes relevant art already known to those skilled in the art. Industrial Applicability
[0180] The present application provides a method, device, storage medium and electronic device for detecting appearance defects of square batteries. Corresponding camera modules are set at different detection positions and used to photograph the corresponding parts of the square battery. Specifically, the first camera module, the second camera module and the third camera module are used to photograph the first part, the second part and the third part of the battery to be inspected respectively, thereby effectively ensuring the integrity of the image acquisition of the six planes of the square battery, so that images of all surfaces of the battery can be obtained at one time, and then the entire battery appearance defect detection can be directly performed on the images of each surface, thereby improving the efficiency of the overall appearance defect identification of the battery.
[0181] The object of the photograph is a square battery with six faces, and the camera will stay for a corresponding time when photographing the front, back, bottom, and top images, and will photograph the images of the corresponding faces at fixed first, second, and third positions, so that each of the six faces of the square battery has an independent image, and the images of the same face photographed for each battery are consistent. On this basis, combined with image fusion technology, the four vertices of each face are used as reference points to align the images, and the pixels corresponding to the same position in the images to be fused are fused, so that the defect detection of multiple batteries can be completed at one time. By sacrificing the volume of the detection equipment to make image fusion simpler and more convenient, it avoids the overly complex image fusion process that consumes more computing resources, thereby ultimately improving the defect detection efficiency of square batteries.
[0182] Furthermore, it is understood that the present invention's method, apparatus, storage medium, and electronic device for detecting appearance defects in square batteries are reproducible and can be used in a variety of industrial applications. For example, the present invention's method, apparatus, storage medium, and electronic device for detecting appearance defects in square batteries can be used in the field of computer technology.
Claims
1. A method for detecting appearance defects of a square battery, characterized in that: The method comprises: Move the battery to be inspected to a first position, call a first camera module to shoot a first part of the battery to be inspected, and form a front image and a back image of the battery to be inspected; Move the battery to be tested to a second position, call a second camera module to shoot a second part of the battery to be tested, and form a left side image and a right side image of the battery to be tested; Move the battery to be inspected to a third position, call a third camera module to shoot a third part of the battery to be inspected, and form a bottom surface image and a top surface image of the battery to be inspected; The appearance defects of the battery to be inspected are identified based on the front image, the back image, the left side image, the right side image, the bottom image, and the top surface image.
2. The method according to claim 1, characterized in that: The first camera module includes a first line scan camera module and a first 3D camera module, the front image includes a line scan front image and a 3D front image, the rear image includes a line scan rear image and a 3D rear image, and calling the first camera module to shoot the first part of the battery to be detected to form the front image and the rear image of the battery to be detected includes: Move the first line scan camera module and the first 3D camera module along a first direction to collect front image information of the battery to be inspected to form the line scan front image and the 3D front image; The battery to be inspected is rotated at the first position by a preset angle, so that the first line scan camera module and the first 3D camera module move along the second direction to collect rear image information of the battery to be inspected, forming the line scan rear image and the 3D rear image.
3. The method according to claim 2, characterized in that The first line scan camera module and the first 3D camera module are both provided with sensing devices, and the number of the sensing devices on the first line scan camera module and the first 3D camera module is 1 or 2 respectively.
4. The method according to any one of claims 1 to 3, characterized in that The second camera module includes a second camera module A and a second camera module B. The battery to be detected is moved to a second position, and the second camera module is called to shoot a second part of the battery to be detected to form a left side image and a right side image of the battery to be detected, including: The battery to be inspected passes through the second camera module during the process of moving to the second position. The second camera module A scans the second part of the battery to be inspected during the process of passing through to form the left side image. The second camera module B scans the second part of the battery to be inspected during the process of passing through to form the right side image.
5. The method according to claim 4, characterized in that The second camera module A includes a second line scan camera module A and a second 3D camera module A, the second camera module B includes a second line scan camera module B and a second 3D camera module B, and sensing devices are arranged on the second line scan camera module A, the second 3D camera module A, the second line scan camera module B, and the second 3D camera module B, and the number of sensing devices on the second line scan camera module A, the second 3D camera module A, the second line scan camera module B, and the second 3D camera module B is 1 or 2 respectively.
6. The method according to any one of claims 1 to 5, characterized in that The method further includes: moving the battery to be detected to a fourth position, calling a fourth camera module to photograph a fourth part of the battery to be detected, and forming a pole image and an explosion-proof valve image of the battery to be detected; The identifying of appearance defects of the battery to be inspected based on the front image, the rear image, the left side image, the right side image, the bottom image, and the top image includes: identifying the appearance defects of the battery to be inspected based on the front image, the rear image, the left side image, the right side image, the bottom image, the top image, the pole image, and the explosion-proof valve image.
7. The method according to any one of claims 1 to 6, characterized in that The identifying of appearance defects of the battery to be inspected according to the front image, the rear image, the left side image, the right side image, the bottom image, and the top side image comprises: Synthesize the front image and the rear image to form a first synthesized image; Combining the left side image and the right side image to form a second composite image; Appearance defects of the battery to be inspected are identified based on the first synthetic image, the second synthetic image, the bottom surface image, and the top surface image.
8. The method according to claim 7, characterized in that The synthesizing the front image and the rear image, or the synthesizing the left side image and the right side image comprises: Extracting the front image and the back image, or the left side image and the right side image to be synthesized; Extracting shape features of the front image, the back image, the left side image, and the right side image; According to the extracted shape features, the front image and the back image, or the left side image and the right side image with similar shape features are horizontally spliced or vertically spliced or directly fused.
9. The method according to claim 7, characterized in that: Synthesizing the front image and the rear image, or synthesizing the left side image and the right side image includes: Determine the front image and the back image, the left side image and the right side image to be synthesized based on the shape features; Establish a coordinate system and extract pixel position coordinates of the front image and the back image, or the left side image and the right side image to be synthesized; Calculate the pixel average value of the front image and the back image, or the left side image and the right side image at the same pixel position coordinate; The pixel average is used as the pixel value of the synthesized image.
10. The method according to claim 2 or 3, characterized in that: The line scan front image is a time-sharing line scan front image. After collecting the front image information of the battery to be tested and forming the line scan front image and the 3D front image, the method includes: The line scan front image is decomposed according to the time-sharing line scan image according to the corresponding scanning rule to form a plurality of line scan front images.
11. The method according to any one of claims 1 to 10, characterized in that The identifying of appearance defects of the battery to be inspected according to the front image, the rear image, the left side image, the right side image, the bottom image, and the top side image comprises: Acquire multiple images of the same part of the battery to be inspected, fuse the images of the same part, and identify the appearance defects of the battery to be inspected according to the fused images, wherein the images of the same part include one or more of the front image, the back image, the left side image, the right side image, the bottom image, and the top image; When the recognition result of one of the fused images is that there is an appearance defect, the corresponding image of the fused image with the appearance defect is The unfused images are individually inspected for appearance defects, and based on the appearance defect recognition results of each image, it is determined whether the corresponding battery has appearance defects.
12. The method according to claim 11, characterized in that The method of acquiring images of the same part of a plurality of batteries to be inspected and fusing the images of the same part comprises: identifying one or more reference points from each image to be fused, aligning the images to be fused according to the one or more reference points so that the images to be fused have the same position and direction, fusing the pixels corresponding to the reference points representing the same or corresponding positions in the images to be fused, and fusing other pixels in the images to be fused based on the determined reference points.
13. The method according to claim 12, characterized in that The number of images of the same part of the multiple batteries to be inspected that are acquired is determined according to the yield rate of the batteries.
14. A square battery appearance defect detection device, characterized in that: The device comprises: A first shooting module is configured to move the battery to be tested to a first position, and call the first camera module to shoot a first part of the battery to be tested to form a front image and a back image of the battery to be tested; A second shooting module is configured to move the battery to be tested to a second position, and call a second camera module to shoot a second part of the battery to be tested to form a left side image and a right side image of the battery to be tested; A third shooting module is configured to move the battery to be tested to a third position, call a third camera module to shoot a third part of the battery to be tested, and form a bottom surface image and a top surface image of the battery to be tested; The defect recognition module is configured to recognize appearance defects of the battery to be inspected based on the front image, the back image, the left side image, the right side image, the bottom image, and the top side image.
15. The square battery appearance defect detection device according to claim 14, characterized in that: The first camera module is slidably connected to the first transmission device via a sliding device, and the third camera module is slidably connected to the second transmission device via a sliding device.
16. The square battery appearance defect detection device according to claim 14 or 15, characterized in that: The device further includes: a fourth shooting module configured to move the battery to be detected to a fourth position, call a fourth camera module to shoot a fourth part of the battery to be detected, and form a pole image and an explosion-proof valve image of the battery to be detected.
17. The square battery appearance defect detection device according to claim 16, characterized in that: The first camera module includes a first line scan camera module and a first 3D camera module, and the first line scan camera module includes a first line scan camera, a line coaxial device and a line light device; The second camera module includes a second camera module A and a second camera module B, the second camera module A includes a second line scan camera module A and a second 3D camera module A, the second camera module B includes a second line scan camera module B and a second 3D camera module B, the second line scan camera module A includes a second line scan camera A and a line light device A, and the second line scan camera module B includes a second line scan camera B and a line light device B; The third camera module includes a third line scan camera module and a third 3D camera module. Scanning cameras, line coaxial devices and line light devices; The fourth camera module includes an area array camera A and an area array camera B. A linear coaxial light device and a strip light device are sequentially arranged below the area array camera A, and a strip light device is arranged below the area array camera B.
18. The square battery appearance defect detection device according to claim 17, characterized in that: The defect recognition module is configured to perform first-category battery appearance defect recognition on a 3D image captured by the first 3D camera module, the second 3D camera module A, the second 3D camera module B, and the third 3D camera module, and to perform second-category battery appearance defect recognition on a line scan image captured by the first line scan camera module, the second line scan camera module A, the second line scan camera module B, and the third line scan camera module; Among them, the first type of battery appearance defects includes one or more of dents, convex points, appearance damage, scratches, and the depth of the overlapping width of the battery protective layer; the second type of battery appearance defects includes one or more of battery protective layer bubbles, dents, convex points, wrinkles, appearance damage, scratches, the overlapping width of the battery protective layer, the height of the battery protective layer, surface foreign matter, surface warping, and surface fingerprints.
19. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores executable instructions, which, when executed by a processor, enable the processor to perform the method according to any one of claims 1 to 13.
20. An electronic device, characterized in that: include: one or more processors; A memory for storing one or more programs, which, when executed by the one or more processors, causes the one or more processors to perform the method according to any one of claims 1 to 13.
Citation Information
Patent Citations
Appearance detection method after square aluminum shell battery is coated with blue film
CN115494078A
Automatic high-speed detection equipment for battery cover plate
CN115639211A
Optical detection device, detection method and device, electronic equipment and storage medium
CN115656197A
Battery defect identification method, system and platform based on combined lighting shooting
CN115908768A
Square battery appearance defect detection method and device, storage medium and electronic equipment
CN116359233A
Cited By
Automatic plugging test device for battery module connector
CN119511086A
Method and device for automatically detecting appearance of ultra-miniature TEC
CN119757378A
Detection device and detection method
CN119959135A
Battery monomer appearance detection device and detection method
CN120334235A
Non-contact solar cell dual-mode defect detection method
CN121169886A
