Quality detection method and device of photovoltaic module junction box cover and computer equipment
By using pre-trained detection models and misjudgment screening mechanisms in the quality detection of photovoltaic module junction boxes, the problems of low detection efficiency and frequent misdetection in the prior art are solved, and high-precision and low-cost quality detection are achieved.
Patent Information
- Application Number
- CN202510321707.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-18
- Publication Date
- 2025-06-20
AI Technical Summary
The prior art is inefficient and costly in the quality detection of photovoltaic module junction boxes, and is prone to missed inspection and missed inspection due to human factors, making it difficult to meet the efficient demand for large-scale production.
The pre-trained detection model is used to detect the box cover image of the photovoltaic module junction box, and the detection reliability is improved through the misjudgment screening mechanism to determine the quality detection results of the photovoltaic module junction box.
It improves detection accuracy and efficiency, reduces the misjudgment rate, ensures the stability of product quality, and reduces the cost of manual intervention.
Smart Images

Figure CN120182235A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of production inspection, and particularly relates to a quality inspection method, device and computer equipment for the cover of a photovoltaic module junction box. Background Art
[0002] The installation quality of the photovoltaic module junction box is crucial for the performance and lifespan of the module. If problems such as reverse installation, detachment, or misalignment occur during production, installation, or circulation of the junction box, it may lead to serious consequences such as electrical short circuits and system failures, seriously threatening the electrical safety of the module.
[0003] Traditional manual inspection methods rely on visual inspection, which is inefficient, costly, and prone to missed and false detections due to human fatigue or lack of experience, making it difficult to detect potential hazards in a timely manner. This method is particularly ineffective in large-scale production and can no longer meet the production requirements of high quality and high efficiency in the photovoltaic industry. Summary of the Invention
[0004] This application aims to solve at least one of the technical problems existing in the related art. For this purpose, this application proposes a quality inspection method, device and computer equipment for the cover of a photovoltaic module junction box to improve the inspection accuracy and efficiency.
[0005] In a first aspect, this application provides a quality inspection method for the cover of a photovoltaic module junction box, the method comprising:
[0006] Obtain the cover image of the photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to a cover image;
[0007] Perform defect detection on the cover image through a pre-trained detection model to obtain one or more detection targets and the local positions of each detection target in the cover image;
[0008] Based on the local positions of each detection target in the cover image, perform misjudgment detection on each detection target respectively to screen out the true detection targets from the one or more detection targets;
[0009] Based on the true detection targets in the cover images corresponding to the one or more junction box covers respectively, determine the quality inspection result of the photovoltaic module junction box.
[0010] In the above technical solution, by obtaining the image of the cover of the photovoltaic module junction box, where the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to an image of the cover, it is applicable to junction boxes with a single cover and multiple covers, and can be applicable to photovoltaic module junction boxes of various models and brands, with good versatility and scalability; by using a pre-trained detection model to perform defect detection on the cover image, one or more detection targets and the local positions of each detection target in the cover image are obtained. The detection model can be fully optimized in the offline stage to ensure that no additional training is required when going online, improving the real-time performance and stability of the production line detection. And by using the deep learning object detection algorithm for detection, it can quickly and accurately detect the defects on the junction box cover, improving the detection efficiency; based on the local positions of each detection target in the cover image, false judgment detection is performed on each detection target respectively to screen out the real detection targets from the one or more detection targets, which can effectively eliminate false alarms caused by factors such as light, reflection, and dust, improve the accuracy of defect recognition, reduce the false judgment rate of the production line, and improve the ability to distinguish defects in complex backgrounds; finally, based on the real detection targets in the cover images corresponding to one or more junction box covers respectively, the quality detection result of the photovoltaic module junction box is determined. By performing quality assessment through the selected real defect targets, it can accurately determine whether the junction box meets the production standards, ensure the stability of product quality, improve production efficiency, and reduce the cost of manual intervention.
[0011] According to an embodiment of the present application, the false judgment detection is respectively performed on each detection target based on the local position of each detection target in the cover image to screen out the real detection targets from the one or more detection targets, and it includes:
[0012] For any detection target, based on the local position of the detection target in the cover image, the target center of the detection target is determined;
[0013] Combining the local position of the detection target in the cover image and the target center, the target area corresponding to the detection target is extracted from the cover image;
[0014] The statistical features of the target area are extracted, and false judgment recognition is performed on the detection target based on the statistical features to determine whether the detection target is an actually existing target;
[0015] If the detection target is an actually existing target, the detection target is used as the real detection target.
[0016] In the above embodiments, by calculating the target center, the core area of the detection target can be accurately located, avoiding errors caused by changes in the size or shape of the detection frame, and improving the accuracy of target extraction; by extracting the target area from the image, the key features of the detection target can be effectively focused, reducing background interference and improving the accuracy of subsequent misjudgment detection; by using statistical feature analysis, such as gray mean, standard deviation, etc., real targets and misdetected targets can be effectively distinguished, avoiding misdetection caused by factors such as noise and light changes in the model, and improving the reliability of detection; by screening out real detection targets, it can be ensured that the subsequent quality evaluation is based on accurate data, thereby improving the overall accuracy of detection and reducing production interference caused by misjudgment.
[0017] In a second aspect, the present application provides a quality detection device for a photovoltaic module junction box cover, the device comprising:
[0018] An acquisition module, configured to acquire a cover image of a photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to a cover image;
[0019] A model detection module, configured to perform defect detection on the cover image through a pre-trained detection model to obtain one or more detection targets and the local positions of each detection target in the cover image;
[0020] A misjudgment detection module, configured to perform misjudgment detection on each detection target respectively based on the local position of each detection target in the cover image, so as to screen out real detection targets from the one or more detection targets;
[0021] A determination module, configured to determine the quality detection result of the photovoltaic module junction box based on the real detection targets in the cover images respectively corresponding to the one or more junction box covers.
[0022] In the above technical solution, by obtaining the image of the cover of the photovoltaic module junction box, where the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to an image of the cover, it is applicable to junction boxes with a single cover and multiple covers, and can be applicable to photovoltaic module junction boxes of various models and brands, with good versatility and scalability; by using a pre-trained detection model to perform defect detection on the cover image, one or more detection targets and the local positions of each detection target in the cover image are obtained. The detection model can be fully optimized in the offline stage to ensure that no additional training is required when going online, improving the real-time performance and stability of the production line detection. And by using the deep learning object detection algorithm for detection, it can quickly and accurately detect the defects on the junction box cover, improving the detection efficiency; based on the local positions of each detection target in the cover image, false judgment detection is performed on each detection target respectively to screen out the real detection targets from one or more detection targets, which can effectively eliminate false alarms caused by factors such as light, reflection, and dust, improve the accuracy of defect recognition, reduce the false judgment rate of the production line, and improve the ability to distinguish defects under complex backgrounds; finally, based on the real detection targets in the cover images corresponding to one or more junction box covers respectively, the quality detection result of the photovoltaic module junction box is determined. By screening out the real defect targets for quality assessment, it can accurately determine whether the junction box meets the production standards, ensure the stability of product quality, and improve production efficiency and reduce the cost of manual intervention.
[0023] In a third aspect, the present application provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the quality detection method for the cover of the photovoltaic module junction box as described in the first aspect above.
[0024] In a fourth aspect, the present application provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the quality detection method for the cover of the photovoltaic module junction box as described in the first aspect above.
[0025] In a fifth aspect, the present application provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the quality detection method for the cover of the photovoltaic module junction box as described in the first aspect above.
[0026] In a sixth aspect, the present application provides a computer program product, including a computer program. When the computer program is executed by a processor, it implements the quality detection method for the cover of the photovoltaic module junction box as described in the first aspect above.
[0027] Additional aspects and advantages of the present application will be given in part in the following description, become apparent in part from the following description, or be learned through the practice of the present application. Description of the Drawings
[0028] The above and / or additional aspects and advantages of the present application will become apparent and be readily understood from the description of the embodiments in conjunction with the following drawings, in which:
[0029] Figure 1 is a schematic diagram of an application scenario of a method for detecting the quality of a photovoltaic module junction box cover provided in some embodiments of the present application;
[0030] Figure 2 is a schematic flowchart of a method for detecting the quality of a photovoltaic module junction box cover provided in some embodiments of the present application;
[0031] Figure 3 is a schematic flowchart of a method for detecting the quality of a photovoltaic module junction box cover provided in some other embodiments of the present application;
[0032] Figure 4 is a schematic diagram of a scenario of quality detection results provided in some embodiments of the present application;
[0033] Figure 5 is a schematic structural diagram of a device for detecting the quality of a photovoltaic module junction box cover provided in some embodiments of the present application;
[0034] Figure 6 is a schematic structural diagram of a computer device provided in some embodiments of the present application. Detailed Embodiments
[0035] The technical solutions in the embodiments of the present application will be clearly described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present application fall within the scope of protection of the present application.
[0036] Unless otherwise defined, all technical and scientific terms used in the present application have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present application belongs; the terms used in the specification of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application; the terms "including" and "having" and any variations thereof in the specification and claims of the present application and the above description of the drawings are intended to cover non-exclusive inclusion. The terms "first", "second", etc. in the specification and claims of the present application or the above drawings are used to distinguish different objects, and are not used to describe a specific order or primary-secondary relationship.
[0037] References to "embodiments" in this application mean that the specific features, structures, or characteristics described in connection with the embodiments can be included in at least one embodiment of this application. The phrase appears in various places in the specification and does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described in this application can be combined with other embodiments.
[0038] In the description of this application, it should be noted that unless otherwise clearly specified and limited, the terms "installed", "connected", "joined", and "attached" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be directly connected, or indirectly connected through an intermediate medium, and it can be the communication inside two elements. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0039] The term "and / or" in this application is merely a description of the association relationship of associated objects, indicating that three relationships can exist. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this application generally represents an "or" relationship between the associated objects before and after.
[0040] The term "a plurality of" appearing in this application refers to two or more (including two). Similarly, "a plurality of groups" refers to two or more groups (including two groups), and "a plurality of pieces" refers to two or more pieces (including two pieces).
[0041] With the advancement of intelligent manufacturing, some automated detection technologies have been gradually applied to the production process of photovoltaic modules, but the current detection accuracy and adaptability are still insufficient, making it difficult to cope with complex and diverse defect problems.
[0042] The relevant photovoltaic junction box detection technology solutions mainly rely on manual inspection and traditional rule algorithms, which have obvious shortcomings and limitations. Manual inspection is inefficient and costly, and is prone to missed inspections and false inspections due to worker fatigue or lack of experience, making it difficult to meet the high-efficiency needs of large-scale production; at the same time, its consistency is poor and standardized quality control cannot be achieved. Although traditional automated inspection has improved efficiency to a certain extent, its detection accuracy is limited. When faced with complex defects such as slight cracks, deformations or positional offsets, misjudgment and missed inspections are still prominent, and its adaptability is poor, requiring frequent adjustments to cope with product process changes. In addition, the relevant technologies are also deficient in real-time and intelligent analysis capabilities, making it difficult to identify hidden problems or potential hidden dangers. At the same time, they lack data-driven production optimization capabilities and cannot conduct in-depth analysis of detection data to improve production processes. Especially in scenes with complex lighting, traditional detection methods have poor adaptability to different light conditions, and are easily affected by factors such as light intensity and angle changes, further exacerbating the problems of false detection and missed inspections.
[0043] In view of this, the embodiments of the present application provide a quality inspection method, device and computer equipment for the junction box cover of a photovoltaic module, which utilize a pre-trained inspection model to perform defect inspection on the cover image of the photovoltaic module junction box, and improve the reliability of inspection through a false positive screening mechanism, and finally output the quality inspection result of the photovoltaic module junction box, aiming to.
[0044] In conjunction with the accompanying drawings, the quality inspection method of the photovoltaic module junction box cover provided in the embodiment of the present application is described in detail through specific embodiments and their application scenarios.
[0045] The quality inspection method for the photovoltaic module junction box cover provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown in the figure. Among them, the global image of the photovoltaic module junction box is collected by an industrial camera on the production line. Depending on the product specifications, a photovoltaic module junction box may contain one or more box covers, so the computer device can segment the global image to obtain one or more box cover images, each of which is stored separately and used for subsequent detection. The computer device can be deployed with an offline or online detection model, and perform target detection on each box cover image by calling the detection model, identify possible defective areas, and output the coordinate positions of these targets in the image. After that, the computer device further screens the detected defective targets, including analyzing the texture, color, shape and other features of the defective area to eliminate misjudgment. For example, by calculating the mean and standard deviation of the defective area or using a morphological algorithm for denoising, it is ensured that only real defective targets are retained. Furthermore, the computer device determines the overall quality of the photovoltaic module junction box based on the defect detection results of each box cover, and outputs the detection results. If there are serious defects, it is marked as unqualified (NG), otherwise it is marked as qualified (OK).
[0046] Exemplarily, on a certain photovoltaic module production line, a high-resolution camera is used to collect images of the junction box, and one or more preprocessings such as grayscale conversion, contrast enhancement, and adaptive histogram equalization are performed on the collected images through a computer device to improve the detection accuracy. The computer device uses a YOLO detection model to identify defect types including scratches, cracks, foreign object contamination, label mixing, etc. For example, if cracks or severe scratches are detected, the computer device determines that the junction box is unqualified (NG); if the Logo of the junction box does not match the standard Logo, the computer device determines it as label mixing and the junction box is unqualified (NG). Finally, the computer device stores the detection results in JSON format, including defect types, defect coordinates, confidence scores, etc., and sends them to the host computer or MES system for traceability management.
[0047] Among them, the computer device can be a terminal device or a server. The terminal device includes, but is not limited to, one or more of various desktop computers, laptop computers, smart phones, tablet computers, vehicle-mounted terminals, Internet of Things devices, or portable wearable devices, etc. The Internet of Things devices can be one or more of smart speakers, smart TVs, smart air conditioners, or smart vehicle-mounted devices, etc. The portable wearable devices can be one or more of smart watches, smart bracelets, or head-mounted devices, etc. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, and big data and artificial intelligence platforms.
[0048] Among them, the quality detection method for the photovoltaic module junction box cover can be applied to the terminal device, and can be specifically executed by the hardware or software in the terminal device.
[0049] The quality detection method for the photovoltaic module junction box cover provided by the embodiments of the present application, the execution subject of the quality detection method for the photovoltaic module junction box cover can be a computer device or a functional module or functional entity in the computer device that can implement the quality detection method for the photovoltaic module junction box cover. Hereinafter, taking the computer device as the execution subject as an example, the quality detection method for the photovoltaic module junction box cover provided by the embodiments of the present application will be described.
[0050] As Figure 2 shown, the quality detection method for the photovoltaic module junction box cover includes: step 210 to step 240.
[0051] Step 210, obtain the lid image of the photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box lids, and each junction box lid corresponds to a lid image.
[0052] Before the detection starts, the computer device needs to obtain the global image of the junction box of the photovoltaic module to be tested. Usually, the junction box of the photovoltaic module contains one or more box covers, so the global image can contain one or more box cover areas.
[0053] To ensure image quality and consistency, industrial cameras are usually used for image acquisition on the production line, and are combined with a fixed light source system (such as a ring LED light, a bar light source, etc.) to reduce the influence brought by the change of ambient light. In addition, the resolution and exposure time of the industrial camera should be adjusted according to the actual situation of the production line to ensure that the collected image is clear and there is no overexposure or underexposure phenomenon. During the image acquisition process, a trigger mechanism (such as a PLC signal trigger) can be used to ensure that when each junction box passes through the detection area, the corresponding global image is automatically captured.
[0054] In some embodiments, after the global image is collected at the front end of the production line, the global image is transmitted to the computer device. The computer device can obtain the box cover image of a single box cover from the global image. For example, the computer device can segment the global image according to the product specifications to obtain multiple box cover images, and store the images in the order of numbers so that different junction box covers can be correctly corresponded during subsequent analysis.
[0055] In other embodiments, after the global image is collected at the front end of the production line, it can perform segmentation processing on the global image by itself and transmit one or more box cover images to the computer device.
[0056] Step 220: Perform defect detection on the box cover image through a pre-trained detection model to obtain one or more detection targets and the local positions of each detection target in the box cover image.
[0057] For each box cover image, the computer device can use a pre-trained detection model to perform defect detection on the box cover image. The detection model can be, for example, a deep learning model. For example, an object detection algorithm such as YOLO (You Only Look Once) or Faster R-CNN can be used to identify various defect targets on the box cover, such as scratches, cracks, contamination, dents, deformations, Logo blurring or Logo missing, etc.
[0058] During the detection process, the computer device first extracts features from the input lid image through the detection model, converts the lid image into a multi-layer feature map, and performs object detection on feature maps of different scales to improve the recognition ability for defects of different sizes. Then, based on the defect features learned during training, the detection model annotates the possible defect areas and outputs the detection results of each object, including the object category, confidence score, and coordinate information of the object in the image. The object category can include defect categories (such as scratches, cracks, contamination, dents, deformations, etc.) and Logo categories.
[0059] In addition, to improve the stability of detection, the computer device can adopt data augmentation techniques, such as brightness adjustment, rotation, contrast enhancement, etc., to enhance the generalization ability of the model under different shooting conditions.
[0060] In some embodiments, the detection model can be pre-trained and deployed offline on the computer device. When the iteration condition is reached, the computer device can re-acquire the sample set and train the model, and deploy the new model to the production line. The iteration conditions include, but are not limited to, one or more of the following: product specification update, online feedback misjudgment rate exceeding the threshold, online feedback missed detection rate exceeding the threshold, etc.
[0061] During the training process, the computer device can perform offset processing on the collected images and annotate various Logos to construct a complete data set. Then, the data set is divided into a training set, a validation set, and a test set according to the ratio of 7:2:1. Finally, the divided data set is input into the detection model for training.
[0062] Step 230: Based on the local positions of the detected objects in the lid image, perform misjudgment detection on each detected object to screen out the true detected objects from one or more detected objects.
[0063] Since the detection model may be affected by factors such as environmental light changes, lid surface reflection, dust, etc. during the detection process, some detected objects may be misjudged. Therefore, it is necessary to further screen the detected objects for misjudgment to eliminate the misjudged objects and retain the true detected objects.
[0064] Specifically, the computer device can perform misjudgment detection through one or more of the following methods: gray-scale statistical feature analysis, morphological filtering, region growing algorithm, feature matching, etc., to screen out the true detected objects from one or more detected objects.
[0065] For example, the computer device calculates the gray-scale mean and standard deviation of the defect area. If the mean is lower than the set threshold, it may be a misjudgment caused by light noise, and the object can be directly eliminated.
[0066] For another example, the computer device uses morphological processing (such as opening operation and closing operation) to screen the defect area, removing small-area isolated noise points to ensure that only significant defect targets are retained.
[0067] For another example, the computer device performs growth analysis on the suspected defect area. If the pixel change in this area is small, it may belong to non-genuine defects, such as pseudo-defects caused by shadows or uneven lighting, which can be filtered out.
[0068] For yet another example, the computer device can use feature matching methods such as template matching or ORB / SIFT to compare the detected Logo with the standard template. If the matching degree is low, it is determined that the Logo is blurred or there is a mixed label.
[0069] Step 240: Based on the true detection targets in the respective lid images corresponding to one or more junction box lids, determine the quality inspection result of the photovoltaic module junction box.
[0070] After screening out the true detection targets, the computer device comprehensively considers the defect conditions of each lid to determine the overall quality inspection result of the photovoltaic module junction box. The quality inspection result includes, but is not limited to, indicating one or more of serious defects, minor defects, and mixed labels of the Logo in the photovoltaic module junction box.
[0071] Exemplarily, if a defect is detected, the computer device directly determines that the junction box is unqualified (NG), and records the defect information to obtain the quality inspection result.
[0072] For another example, if a mixed label of the Logo is detected, the computer device directly determines that the junction box is unqualified (NG), and records the defect information to obtain the quality inspection result.
[0073] For another example, if defects affecting the structural integrity such as cracks, severe scratches, and lid deformation are detected, it is directly determined that the junction box is unqualified (NG), and the defect information is recorded to obtain the quality inspection result.
[0074] For yet another example, if only non-structural defects such as minor stains and blurred Logo are detected, the system can perform a secondary judgment. If the defect area exceeds the set threshold, it is reviewed by an operator, otherwise it can still be determined as qualified (OK).
[0075] In some embodiments, the computer device can set different defect weights and perform a comprehensive determination in combination with a rule engine to ensure the accuracy of quality assessment. For example, using the rule engine for NG judgment includes a mixed label rule. Assuming that the Logo is set as A and the specification is n, the rule is:
[0076] if there are any defects, it is determined as NG;
[0077] else if the number of Logos = n, but there is a Logo other than A among the n Logos, it is determined as NG;
[0078] else it is determined as ok
[0079] After completing the quality assessment, the computer device can output the quality inspection results to the host computer or the production management system for storage and traceability management. The output information usually includes, but is not limited to, one or more of the defect category (such as scratches, cracks, contamination, Logo missing, etc.), defect coordinate information, confidence level (the detection confidence level of the detection model for the defect), junction box number, detection timestamp, etc. Among them, the junction box number is used to uniquely identify each detected junction box. The defect coordinate information includes one or more of the local position of the defect in the lid image of the junction box and the global position in the global image, etc. The detection timestamp is used to record the detection time for production traceability.
[0080] To ensure data standardization, exemplarily, the computer device can use the JSON format or XML format to organize the quality inspection results and upload the data to the MES system or cloud database through the API interface for subsequent analysis and quality traceability.
[0081] The quality inspection method for the photovoltaic module junction box lid provided by the embodiment of the present application, by obtaining the lid image of the photovoltaic module junction box, where the photovoltaic module junction box includes one or more junction box lids, and each junction box lid corresponds to a lid image, is applicable to junction boxes with single lids and multiple lids, can be applicable to photovoltaic module junction boxes of various models and brands, and has good versatility and scalability; by using a pre-trained detection model to perform defect detection on the lid image to obtain one or more detection targets and the local positions of each detection target in the lid image, the detection model can be fully optimized in the offline stage to ensure that no additional training is required when going online, improving the real-time performance and stability of the production line detection, and by performing detection through the deep learning object detection algorithm, it can quickly and accurately detect the defects on the junction box lid, improving the detection efficiency; based on the local positions of each detection target in the lid image, false judgment detection is respectively performed on each detection target to screen out the real detection targets from one or more detection targets, which can effectively eliminate false alarms caused by factors such as light, reflection, and dust, improve the accuracy of defect recognition, reduce the false judgment rate of the production line, and improve the ability to distinguish defects under complex backgrounds; finally, based on the real detection targets in the lid images corresponding to one or more junction box lids, the quality inspection results of the photovoltaic module junction box are determined. By screening out the real defect targets for quality assessment, it can accurately determine whether the junction box meets the production standards, ensure the stability of product quality, and improve production efficiency and reduce the cost of manual intervention.
[0082] During the quality inspection process of a photovoltaic module junction box, due to factors such as light, reflection, stains, or equipment errors, some of the detected targets output by the detection model may be misjudged. Therefore, after the initial targets are detected, it is necessary to further detect the misjudgment of each detected target to ensure that the finally identified targets are real targets. To this end, in some embodiments, based on the local positions of each detected target in the cover image, misjudgment detection is performed on each detected target respectively to screen out real detected targets from one or more detected targets, including: for any detected target, based on the local position of the detected target in the cover image, determine the target center of the detected target; combine the local position of the detected target in the cover image and the target center, and extract the target area corresponding to the detected target from the cover image; extract the statistical features of the target area, and perform misjudgment identification on the detected target based on the statistical features to determine whether the detected target is an actual existing target; if the detected target is an actual existing target, use the detected target as a real detected target.
[0083] During the detection process of the cover image of a photovoltaic module junction box, first use a pre-trained detection model to obtain multiple initial detected targets and determine the local positions of these detected targets in the cover image. Since the initial detected targets may include misdetected targets, further misjudgment detection is performed on each detected target to screen out real detected targets.
[0084] Specifically, for any detected target, the computer device first calculates the center point coordinates of the detected target based on its local position in the cover image. Then, using the local position and the target center of the target, the corresponding target region (ROI) is extracted from the original cover image.
[0085] Next, the computer device calculates statistical features for this target region, such as grayscale mean, standard deviation, edge information, or texture features, etc., and performs misjudgment identification based on these statistical features to determine whether the detected target is an actual existing target. If the statistical features of the detected target meet the preset real target features, the computer device confirms it as a real detected target, otherwise it is regarded as a misdetected target and excluded. After this misjudgment detection step, only the actual existing targets are retained, improving the detection accuracy.
[0086] Exemplarily, the computer device extracting the corresponding target region of the detected target can be expressed as:
[0087]
[0088] where, (x i , y i ) is the target center of the detected target, (w i , hi ) are the width and height of the detection target, that is, the width and height of the detection box, and I is the input lid image.
[0089] In the above embodiments, by calculating the target center, the core area of the detection target can be accurately located, avoiding errors caused by changes in the size or shape of the detection box, and improving the accuracy of target extraction; by extracting the target area from the image, the key features of the detection target can be effectively focused, reducing background interference, and improving the accuracy of subsequent misjudgment detection; by using statistical feature analysis, such as gray mean, standard deviation, etc., real targets and misdetected targets can be effectively distinguished, avoiding misdetection caused by factors such as noise and illumination changes in the model, and improving the reliability of detection; by screening out real detection targets, it can ensure that the subsequent quality evaluation is based on accurate data, thereby improving the overall accuracy of detection and reducing production interference caused by misjudgment.
[0090] In some embodiments, statistical features of the target area are extracted, and misjudgment recognition of the targeted detection target is performed based on the statistical features to determine whether the targeted detection target is an actually existing target, including: performing grayscale processing on the target area to obtain an initial grayscale area; respectively determining the brightness mean and brightness fluctuation value of the initial grayscale area, and based on the brightness mean and brightness fluctuation value, determining the abnormal pixels in the initial grayscale area; based on the abnormal pixels in the initial grayscale area, performing misjudgment recognition on the targeted detection target to determine whether the targeted detection target is an actually existing target.
[0091] Specifically, for each detection target, the computer device extracts the corresponding target area from the lid image and performs grayscale processing on the target area to obtain an initial grayscale area. The purpose of grayscale processing is to reduce the interference of color information on feature extraction and make the subsequent brightness feature analysis more stable and reliable.
[0092] Next, the computer device calculates the brightness mean and brightness fluctuation value of the initial grayscale area, where the brightness mean reflects the overall brightness level of the area, and the brightness fluctuation value represents the degree of brightness change of the pixels in the area. The brightness fluctuation value can be the standard deviation or variance, etc. Then, according to the set abnormal determination criterion, the computer device determines the abnormal pixels in the initial grayscale area. For example, if the brightness values of some pixels are significantly higher or lower than a specific threshold range of the brightness mean, they are marked as abnormal pixels. Another example is that an area with a large brightness fluctuation value may mean the existence of reflection, occlusion, or printing defects, and its pattern needs to be further analyzed.
[0093] Finally, based on the abnormal pixels in the initial grayscale region, the computer device determines whether the current detection target is an actually existing target. For example, if the brightness feature of a Logo region matches the preset standard feature, it is confirmed that the Logo is a real target; if the number of abnormal pixels in a defect region is small or shows a random distribution, it may be a false detection caused by light changes or noise, and the target should be excluded.
[0094] Exemplarily, the computer device converts the extracted ROI region into a grayscale image to obtain the initial grayscale region G = f gray (ROI), and then extracts the statistical features of the initial grayscale region, including the brightness mean μ and the standard deviation σ. The specific calculation formulas are as follows:
[0095]
[0096] where W and H are the width and height of the ROI region respectively, and (x, y) represents the pixels in the initial grayscale region G. After that, the computer device uses the threshold T(x, y) to mark the abnormal pixel points in the image, and the formula is as follows:
[0097]
[0098] where k is a preset constant, usually set according to experience, and is used to control the sensitivity of the threshold. If the grayscale value of a certain pixel is greater than the mean plus a multiple of the standard deviation, the computer device regards it as an abnormal pixel and marks it as 255 (white); otherwise, it is marked as 0 (black). After the abnormal pixels are marked, the computer device can, based on the abnormal pixels, perform misjudgment identification on the detection target being targeted to determine whether the detection target being targeted is an actually existing target.
[0099] In the above embodiments, by performing grayscale processing to remove the interference of color information, the subsequent brightness feature analysis is made more stable, and by using the method of abnormal pixel analysis, false detections caused by uneven illumination or noise can be effectively excluded, the reliability of detection is improved, and it can adapt to different lighting environments, improving the applicability and robustness of the detection system in complex environments.
[0100] To improve the detection accuracy, in some embodiments, based on the abnormal pixels in the initial grayscale region, misjudgment identification is performed on the detection target being targeted to determine whether the detection target being targeted is an actually existing target, including: performing morphological processing on the initial grayscale region based on the abnormal pixels to obtain the target grayscale region; determining the area of the target grayscale region, and when the area exceeds a preset threshold, determining that the detection target being targeted is an actually existing target.
[0101] For the initial grayscale region, the computer device uses a statistical feature analysis method to extract abnormal pixel points and performs further misjudgment identification processing based on these abnormal pixel points. Specifically, the computer device first performs morphological processing on the initial grayscale region based on the abnormal pixel points, such as erosion, dilation, opening operation, or closing operation, to enhance the contour features of the defect and eliminate isolated noise points, and finally obtains the target grayscale region. Subsequently, the computer device calculates the area of the target grayscale region and compares it with a preset threshold. If the area exceeds the threshold, it indicates that the abnormal area of the detection target is large, which may be an actual defect or an abnormal identification. At this time, the computer device determines that the detection target is an actual target. If the area does not exceed the threshold, it may be a detection error or a noise point, and the computer device excludes it to reduce misjudgment.
[0102] Exemplarily, the computer device can perform noise removal and hole filling based on the abnormal pixel. Removing noise points usually uses morphological operations to reduce misjudged noise points. And the computer device can also use Gaussian filtering smoothing operation to process the boundary of the target region to reduce the jaggedness of the boundary. Furthermore, the computer device counts the area of the defect region. If the area of the defect region exceeds a certain threshold, it can be considered an actual defect, otherwise it may be a misjudgment.
[0103] In the above embodiments, noise points are eliminated through morphological processing, and threshold screening is performed based on the area of the region, reducing misjudgment and improving the overall accuracy of the detection model. It can be applied to detection environments with different lighting conditions and identification backgrounds, enabling the algorithm to run stably in various production environments. And, through morphological processing, the data is streamlined, unnecessary calculations are avoided, and the efficiency of real-time detection on the production line is improved; by adopting the area threshold determination strategy, false detection caused by tiny noise points can be effectively avoided, and the reliability of the detection result is enhanced.
[0104] During the production process of photovoltaic module junction boxes, the logo on the junction box cover is an important element to ensure that the product meets brand and quality requirements. However, due to production processes, equipment errors, or human operation mistakes, problems such as missing logos, incorrect quantity, or mixed logos may occur on the junction box cover, affecting the compliance and market acceptance of the product. Therefore, in some embodiments, the true detection targets at least include logo targets; correspondingly, based on the true detection targets in the lid images respectively corresponding to one or more junction box lids, the quality detection result of the photovoltaic module junction box is determined, including: determining the standard quantity of logo targets based on the preset product specifications of the photovoltaic module junction box; when the sum of the quantities of logo targets in the lid images respectively corresponding to one or more junction box lids is inconsistent with the standard quantity, determining that the photovoltaic module junction box is a defective product; when the sum of the quantities of logo targets in the lid images respectively corresponding to one or more junction box lids is consistent with the standard quantity, but there is any logo target that is not the preset logo, determining that the photovoltaic module junction box is a defective product.
[0105] Specifically, after the computer device filters out the true detection targets, based on the category of the true detection targets output by the detection model, it determines whether it belongs to a logo target or other defect targets such as scratches, cracks, contamination, dents, deformations, etc.
[0106] For the logo target, the computer device first determines the standard quantity of the logo target, that is, the quantity of logo targets that should be present based on the product specifications of the junction box. For example, if a certain model of junction box is designed to include two logo targets, then the standard quantity of logo targets that should be detected for the junction box is 2.
[0107] Furthermore, the computer device counts the total quantity of logo targets recognized in all lid images and compares it with the standard quantity. If the recognized quantity of logo targets is inconsistent with the standard quantity (such as missing or excessive), then the junction box is determined to be a defective product (NG). Even if the quantity of logo targets meets the standard, the computer device still needs to further confirm whether all logo targets are the preset logos. For example, if the standard logo target should be "Brand A", but "Brand B" appears among the detected logo targets, it indicates that a mixed logo problem has occurred, and at this time, the junction box should still be determined to be a defective product (NG). If both the quantity and content of the logo targets meet the standard, the junction box is determined to be a qualified product. Finally, the computer device outputs the quality detection result to determine whether the junction box is qualified.
[0108] In some embodiments, the computer device can use optical character recognition (OCR) or a deep learning classification model (such as CNN) to perform content parsing on the logo targets and match them with the standard logos.
[0109] In the above embodiments, through automated detection, it is ensured that the marking targets of all photovoltaic module junction boxes meet the product specifications, reducing human inspection errors and improving quality consistency. Moreover, through computer vision technology, double verification is carried out on the quantity and content of the marking targets, effectively identifying problems such as missing or mixed markings, and preventing unqualified products caused by misjudgment from entering the market.
[0110] On the one hand, quality determination is carried out on the marking targets. On the other hand, the computer device also needs to carry out quality determination on the defect targets. For this reason, in some embodiments, the true detection targets further include defect targets; correspondingly, based on the true detection targets in the lid images respectively corresponding to one or more junction box lids, determining the quality detection result of the photovoltaic module junction box further includes: when any of the lid images includes defect targets, determining that the photovoltaic module junction box is a defective product.
[0111] The computer device detects the defect targets in all the lid images. If any of the lid images contains defect targets, it is determined that the junction box is a defective product.
[0112] The computer device can further analyze based on features such as the type, size, and position of the defects to improve the accuracy of defect detection. For example, if some defects (such as minor stains) do not affect the product function, reasonable thresholds can be set for screening. Finally, the computer device combines the detection results of the marking targets and the defect targets and outputs the quality detection result of the photovoltaic module junction box.
[0113] In the above embodiments, through the quality determination of the defect targets, it is ensured that the appearance quality of the junction box meets the standard, and any junction box containing defect targets is accurately identified and removed, ensuring the reliability of the final product.
[0114] As mentioned above, according to different product specifications, a photovoltaic module junction box may include one or more lids. During this detection process, the lid images of the junction box need to be extracted from the original image of the complete junction box to ensure the accuracy of detection. In addition, after the detection targets are screened, the position information of the true detection targets needs to be mapped back to the original image for global analysis. This solution can improve the detection accuracy and optimize the quality management in the production process. Therefore, in some embodiments, obtaining the lid image of the photovoltaic module junction box includes: obtaining the original image of the photovoltaic module junction box transmitted from the front end of the production line, and cutting the original image based on the preset product specifications of the photovoltaic module junction box to obtain a plurality of lid images. Correspondingly, in some embodiments, the above method further includes: based on the local position of the true detection target in the lid image, determining the global position of the true detection target in the original image of the photovoltaic module junction box.
[0115] The computer device first obtains the original image of the photovoltaic module junction box, identifies the junction box cover area in the original image, and cuts the original image into multiple cover images according to a predetermined cutting rule, with each cover image corresponding to a junction box cover. For example, if the junction box contains three independent covers, the device crops the original image into three cover images according to the standard size and stores them with separate numbers.
[0116] Subsequently, the computer device performs detection based on the cover image. After screening out the true detection targets, it maps their position information back to the original image to ensure the global consistency of the detection results. That is, the computer device calculates the global position of the true detection target in the original image based on the local position of the true detection target in the cover image and the position mapping relationship of the cover image in the original image. Thus, the information of the detection target is not limited to a single cover, but can be traced and analyzed within the entire junction box range, which helps to optimize production quality management.
[0117] Exemplarily, the computer device can splice the junction box image information to obtain the original image, and calculate the global position of the true detection target in the original image according to the offset of the cover image in the original image (such as the coordinates of the upper left corner of the cover). For example, if the coordinates of a certain detection target in the cover image are (x', y'), and the upper left corner coordinates of the cover image in the original image are (x0, y0), then the global coordinates of the target in the original image can be calculated as (x0 + x', y0 + y'). The computer device stores the global position data for subsequent quality analysis or production adjustment.
[0118] In the above embodiments, by cutting the original image based on the product specifications, it ensures that the detection model focuses on each independent junction box cover, improves the accuracy of target recognition, and avoids detection errors caused by background interference or overlapping of multiple junction box covers; moreover, not only can target detection be performed on the cover image, but also the detection results can be mapped back to the original image to provide an overall quality assessment of the junction box, which helps to identify systematic problems in the production process, such as whether there are repetitive defects at specific positions in a certain production batch. Since the detection results can be associated with the original image, production managers can track the positions of defective targets and trace back to the specific production processes for targeted optimization of the manufacturing process. When abnormalities are found, relevant production batches can be directly inspected, reducing the risk of defective products flowing into the market and improving the accuracy of quality management.
[0119] During the quality inspection process of a photovoltaic module junction box, the lighting conditions of the original image may be affected by environmental factors (such as light source intensity, shadow effects) and the exposure settings of the imaging device, resulting in uneven image brightness or insufficient contrast, which in turn affects the accuracy of subsequent object detection. Therefore, before cutting the original image, it is necessary to first perform brightness compensation and local contrast adjustment on the original image to improve the image quality and make subsequent detection more stable and reliable. To this end, in some embodiments, before cutting the original image, the above method further includes: performing brightness compensation on the original image to obtain the original image with adjusted brightness; performing local contrast adjustment on the original image with adjusted brightness to obtain the final original image.
[0120] Among them, brightness compensation is used to adjust the overall lighting intensity to ensure that the average brightness of the image is within a reasonable range; local contrast adjustment can enhance image details, improve the distinguishability of different target regions, and thus improve the accuracy of object detection.
[0121] Specifically, after the computer device obtains the original image of the photovoltaic module junction box, it first performs brightness compensation on the original image to make the overall image brightness reach the expected standard; subsequently, it further performs local contrast adjustment to enhance the local details of the image. The image processed through these two steps is used as the final original image for subsequent cutting of the box cover image and object detection.
[0122] In the above embodiments, through brightness compensation, the image with insufficient lighting or overexposure is restored to an appropriate brightness level, reducing the detection error caused by changes in lighting conditions. And through local contrast adjustment, the image details are enhanced, making the marked objects and defective objects on the junction box cover clearer, improving the accuracy of object detection. Thus, it can adapt to different lighting conditions, enhance the stability of detection, and reduce false positives and missed detections caused by lighting changes.
[0123] In some embodiments, performing brightness compensation on the original image to obtain the original image with adjusted brightness includes: scaling the overall brightness of the original image by a preset brightness factor and increasing or decreasing the overall brightness by a preset brightness offset amount to obtain the original image with adjusted brightness.
[0124] Specifically, the computer device reads the original image and calculates the brightness mean of the entire image to evaluate its current brightness state. The computer device can determine the target brightness range of the image according to the product detection standard of the photovoltaic module junction box, for example, requiring the brightness mean of the image to be within a certain numerical range.
[0125] The computer device first scales the image brightness based on a preset brightness factor to adjust the brightness state of the image. For example, for a darker image, the brightness factor can be set greater than 1 to increase the overall brightness, while for a brighter image, the brightness factor is set less than 1 to reduce the brightness. Then, the computer device further adjusts the brightness of the scaled image based on a preset brightness offset to make the overall brightness balanced.
[0126] Exemplarily, the brightness adjustment by the computer device can be achieved through the following formula:
[0127] I out(x,y) = αI in(x,y) + β (5)
[0128] where I in(x,y) is the pixel value of the input image, and I out(x,y) is the pixel value of the output image. α is the brightness factor, and β is the brightness offset.
[0129] In the above embodiments, through brightness scaling, the overall brightness of the image is within the standard range, thereby reducing the detection error caused by changes in the shooting illumination conditions. Then, through brightness offset adjustment, the performance of the marked target and the defect target in the image becomes clearer, improving the accuracy of target detection. Thus, through the brightness compensation method, the system can adapt to different illumination environments, improve the stability of the detection system, and reduce misjudgment and missed detection caused by illumination changes.
[0130] During the quality inspection process of the photovoltaic module junction box, in addition to the overall brightness adjustment, it is also necessary to further enhance the local contrast of the image. The reason is that even after the overall brightness adjustment, there may still be problems of uneven brightness and low contrast in different regions of the image. For example, due to uneven illumination, some regions may still be too dark or too bright, affecting the discrimination ability of the detection model. Therefore, in some embodiments, the local contrast of the original image after brightness adjustment is adjusted to obtain the final original image, including: dividing the original image after brightness adjustment into multiple local image regions; for any local image region, determining the statistical features of the targeted local image region, and normalizing the targeted local image region based on the statistical features to obtain the final original image.
[0131] The core idea of local contrast adjustment is to normalize a local area based on its statistical features, so that its brightness and contrast meet the expected standards. This method can enhance the detail performance of images, improve the detection accuracy of logo targets and defect targets, and reduce the possibility of false detection and missed detection. Specifically, after the computer device completes brightness compensation, it divides the original image with adjusted brightness into multiple local image regions. For example, it uses a grid division method of M×N, so that each local area contains an appropriate number of pixel points to ensure the statistical analysis effect of local features. During the division process, the area size can be adjusted according to the size of the photovoltaic module junction box and the detection requirements to ensure that the local area can cover sufficient detail information.
[0132] For each local area, the computer device calculates its brightness mean and brightness standard deviation as its statistical features to evaluate the brightness distribution and contrast level of the local area.
[0133] Based on the above statistical features, the computer device normalizes the local image region to ensure that the brightness and contrast of all local image regions are within a reasonable range. Finally, the computer device recombines the normalization results of all local areas to obtain the final original image, which is used for subsequent target detection and quality assessment tasks.
[0134] Exemplarily, the computer device can perform normalization processing through the following formula:
[0135]
[0136] where G OUT (x,y) is the enhanced image pixel value, μ local (x,y) is the brightness mean of the local image region, and σ local (x,y) is the brightness standard deviation of the local image region.
[0137] In the above embodiments, through local normalization processing, areas with lower brightness are enhanced, and areas with lower contrast become clearer, improving the discrimination ability of the detection system. Since the lighting conditions in the production environment may vary, the local contrast adjustment method can dynamically adapt to the brightness changes in different regions, thereby improving the robustness of quality detection. Thus, by combining brightness adjustment and local contrast adjustment, the dynamic changes in local area brightness and contrast are combined, effectively avoiding the situation of over-enhancement and enhancing the detail performance of local image regions.
[0138] In a specific example, such as Figure 3As shown, the computer device first obtains the original image of the photovoltaic module junction box as the image to be detected and inputs relevant detection parameters such as exposure and resolution. Then, the computer divides the original image into multiple small pieces to obtain multiple cover images for subsequent local analysis. Before detection, the computer device can perform image preprocessing such as image normalization and illumination adaptive enhancement, such as brightness adjustment, contrast enhancement, and noise removal, to reduce the impact of different illumination conditions on detection. The preprocessed image can be used as a sample to train a detection model, such as the yolo11 model. The process of model training can be performed offline. The computer device loads the weight parameters from the trained yolo11 model for actual object detection tasks and deploys the trained yolo11 model to the local or cloud for real-time object detection and classification to obtain detection information.
[0139] For any detection information, the computer device analyzes the detection targets in the image one by one to obtain information such as the position, category, and confidence of each target. Based on the confidence of the detection result, the computer device can obtain the detection targets output by the model. Further, to avoid false detection, the computer device can further screen the detection targets to screen out the real detection targets.
[0140] Furthermore, the computer device determines whether the photovoltaic module junction box is qualified based on the type and position of the real detection target. If the real detection target is of the Logo category, that is, the logo information on the junction box is detected, the computer device performs a mixed logo determination: if there is a preset logo, it enters the detection OK result, indicating that the product is qualified; if it is not a preset logo, the detection NG result is output, indicating that the product is unqualified. If the real detection target is of the defect category, it means that there is a defect in the junction box, and it is directly determined as NG.
[0141] After that, the computer device can determine the global position of the real detection target in the original image and encapsulate it with the detection results (such as target category, position, quality determination result, etc.) into a JSON format and return it to the front-end software or database of the production line. Exemplarily, the quality detection result is as Figure 4 shown. Taking a single junction box cover as an example, if there is a problem of Logo mixing on this junction box cover, the computer device can return a string message such as "This logo is incorrect. The actual logo should be xx".
[0142] The quality detection method for the photovoltaic module junction box cover of the present application introduces deep learning and computer vision technologies, which can adapt to the detection requirements of junction boxes in different illumination environments. Whether it is the intensity and angle change of light, or the differences in junction box materials or processes, there is no need to frequently adjust parameters, and stable detection performance can be maintained. This highly generalized ability enables it to be widely applied to different production lines and actual scenarios to meet diverse detection needs.
[0143] Moreover, the quality inspection method for the photovoltaic module junction box cover of the present application provides full-process functions of cutting, logo recognition, offset recognition, and detection of mixed-in other Logos for the scenario of inspecting multiple junction boxes (such as three boxes) at one time, effectively solving the problems of mixed installation of junction boxes or inconsistent logos, and ensuring product consistency and quality compliance.
[0144] Furthermore, the quality inspection method for the photovoltaic module junction box cover of the present application can achieve high-precision detection of logos and offsets. By automatically cutting multi-box pictures and independently analyzing each junction box, it can accurately identify the logo position, offset amount, and whether other Logos are mixed in. Combining optimized model training and detection processes, the false detection and missed detection rates are significantly reduced, meeting the requirements of high-quality production.
[0145] In the embodiment of the present application, the execution subject of the quality inspection method for the photovoltaic module junction box cover can be a quality inspection device for the photovoltaic module junction box cover. In the embodiment of the present application, taking the quality inspection device for the photovoltaic module junction box cover executing the quality inspection method for the photovoltaic module junction box cover as an example, the quality inspection device for the photovoltaic module junction box cover provided by the embodiment of the present application is described.
[0146] The embodiment of the present application also provides a quality inspection device for the photovoltaic module junction box cover, which is applied to a computer device. As Figure 5 shown, the quality inspection device for the photovoltaic module junction box cover includes an acquisition module 501, a model detection module 502, a misjudgment detection module 503, and a determination module 504. Among them:
[0147] The acquisition module 501 is configured to acquire the lid image of the photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box lids, and each junction box lid corresponds to a lid image.
[0148] The model detection module 502 is configured to perform defect detection on the lid image through a pre-trained detection model to obtain one or more detection targets and the local positions of each detection target in the lid image.
[0149] The misjudgment detection module 503 is configured to perform misjudgment detection on each detection target respectively based on the local position of each detection target in the lid image, so as to screen out the true detection targets from one or more detection targets.
[0150] The determination module 504 is configured to determine the quality inspection result of the photovoltaic module junction box based on the true detection targets in the lid images corresponding to one or more junction box lids respectively.
[0151] According to the quality detection device for the photovoltaic module junction box cover provided by the embodiments of the present application, by acquiring the cover image of the photovoltaic module junction box, where the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to a cover image, it is applicable to the junction box with a single cover and multiple covers, and can be applicable to the photovoltaic module junction boxes of various models and brands, with good versatility and scalability; by using a pre-trained detection model to perform defect detection on the cover image, one or more detection targets and the local positions of each detection target in the cover image are obtained. The detection model can be fully optimized in the offline stage to ensure that no additional training is required when going online, improving the real-time performance and stability of the production line detection. And by performing detection through the deep learning object detection algorithm, the defects on the junction box cover can be detected quickly and accurately, improving the detection efficiency; based on the local positions of each detection target in the cover image, misjudgment detection is respectively performed on each detection target to screen out the real detection targets from one or more detection targets, which can effectively eliminate false alarms caused by factors such as light, reflection, and dust, improve the accuracy of defect recognition, reduce the misjudgment rate of the production line, and improve the ability to distinguish defects under complex backgrounds; finally, based on the real detection targets in the cover images corresponding to one or more junction box covers respectively, the quality detection result of the photovoltaic module junction box is determined. By screening out the real defect targets for quality assessment, it can accurately determine whether the junction box meets the production standards, ensure the stability of product quality, improve production efficiency, and reduce the cost of manual intervention.
[0152] In some embodiments, the misjudgment detection module is further configured to, for any detection target, based on the local position of the detection target in the cover image, determine the target center of the detection target; combine the local position of the detection target in the cover image and the target center, and extract the target region corresponding to the detection target from the cover image; extract the statistical features of the target region, and based on the statistical features, perform misjudgment recognition on the detection target to determine whether the detection target is an actually existing target; if the detection target is an actually existing target, use the detection target as a real detection target.
[0153] In some embodiments, the misjudgment detection module is further configured to perform grayscale processing on the target region to obtain an initial grayscale region; respectively determine the brightness mean value and the brightness fluctuation value of the initial grayscale region, and based on the brightness mean value and the brightness fluctuation value, determine the abnormal pixels in the initial grayscale region; based on the abnormal pixels in the initial grayscale region, perform misjudgment recognition on the detection target to determine whether the detection target is an actually existing target.
[0154] In some embodiments, the misjudgment detection module is further configured to perform morphological processing on the initial grayscale region based on abnormal pixels to obtain a target grayscale region; determine the area of the target grayscale region, and determine that the detection target being targeted is an actually existing target when the area exceeds a preset threshold.
[0155] In some embodiments, the actual detection target at least includes a marking target; the determination module is further configured to determine the standard quantity of the marking target based on the preset product specifications of the photovoltaic module junction box; determine that the photovoltaic module junction box is a defective product when the sum of the quantities of the marking targets in the lid images respectively corresponding to one or more junction box lids is inconsistent with the standard quantity; and determine that the photovoltaic module junction box is a defective product when the sum of the quantities of the marking targets in the lid images respectively corresponding to one or more junction box lids is consistent with the standard quantity but there is any marking target that is not a preset marking.
[0156] In some embodiments, the actual detection target further includes a defect target; the determination module is further configured to determine that the photovoltaic module junction box is a defective product when any one of the lid images corresponding to one or more junction box lids includes a defect target.
[0157] In some embodiments, the acquisition module is further configured to acquire the original image of the photovoltaic module junction box transmitted from the front end of the production line, and perform cutting on the original image based on the preset product specifications of the photovoltaic module junction box to obtain a plurality of lid images. Correspondingly, the above device further includes a mapping module, configured to determine the global position of the actual detection target in the original image of the photovoltaic module junction box based on the local position of the actual detection target in the lid image.
[0158] In some embodiments, the above device further includes a preprocessing module, configured to perform brightness compensation on the original image to obtain a brightness-adjusted original image; perform local contrast adjustment on the brightness-adjusted original image to obtain the final original image.
[0159] In some embodiments, the preprocessing module is further configured to scale the overall brightness of the original image by a preset brightness factor, and increase or decrease the overall brightness by a preset brightness offset amount to obtain a brightness-adjusted original image.
[0160] In some embodiments, the preprocessing module is further configured to divide the brightness-adjusted original image into a plurality of local image regions; for any one of the local image regions, determine the statistical features of the targeted local image region, and perform normalization processing on the targeted local image region based on the statistical features to obtain the final original image.
[0161] The quality inspection device for the photovoltaic module junction box cover in the embodiments of the present application can be a computer device or a component in a computer device, such as an integrated circuit or a chip. The computer device can be a terminal device or a server. Exemplarily, the computer device can be a mobile phone, a tablet computer, a laptop computer, a handheld computer, an in-vehicle computer device, a Mobile Internet Device (MID), an Augmented Reality (AR) / Virtual Reality (VR) device, a robot, a wearable device, an Ultra-mobile Personal Computer (UMPC), a netbook, or a Personal Digital Assistant (PDA), etc. It can also be a server, a Network Attached Storage (NAS), a Personal Computer (PC), a Television (TV), a teller machine, or a self-service machine, etc. The embodiments of the present application do not make specific limitations.
[0162] The quality inspection device for the photovoltaic module junction box cover in the embodiments of the present application can be a device with an operating system. The operating system can be the Microsoft (Windows) operating system, the Android operating system, the IOS operating system, or other possible operating systems. The embodiments of the present application do not make specific limitations.
[0163] The quality inspection device for the photovoltaic module junction box cover provided in the embodiments of the present application can implement Figure 2 each process implemented by the method embodiments. To avoid repetition, it will not be elaborated here.
[0164] In some embodiments, as Figure 6 shown, the embodiments of the present application further provide a computer device 600, including a processor 601, a memory 602, and a computer program stored on the memory 602 and executable on the processor 601. When the program is executed by the processor 601, it implements each process of the above method embodiments and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.
[0165] It should be noted that the computer device in the embodiments of the present application includes the above-mentioned mobile computer devices and non-mobile computer devices.
[0166] The embodiments of the present application further provide a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements each process of the embodiment of the quality detection method of the photovoltaic module junction box cover, and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.
[0167] Wherein, the processor is the processor in the computer device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory ROM, random access memory RAM, magnetic disk or optical disc, etc.
[0168] The embodiments of the present application further provide a computer program product, including a computer program. When the computer program is executed by a processor, it implements the quality detection method of the photovoltaic module junction box cover described above.
[0169] Wherein, the processor is the processor in the computer device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory ROM, random access memory RAM, magnetic disk or optical disc, etc.
[0170] The embodiments of the present application further provide a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement each process of the embodiment of the quality detection method of the photovoltaic module junction box cover, and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.
[0171] It should be understood that the chip mentioned in the embodiments of the present application can also be referred to as a system-on-chip, system chip, chip system or system-on-chip, etc.
[0172] It should be noted that in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed, or further includes elements inherent to such process, method, article or device. Without more limitations, the element defined by the statement "including one..." does not exclude the existence of additional identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the methods and devices in the embodiments of the present application are not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in a reverse order according to the functions involved. For example, the described methods may be performed in an order different from that described, and various steps may be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0173] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-described method of the embodiments can be implemented by means of software plus a necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present application, in essence, or the part that contributes to the related art, can be embodied in the form of a computer software product. The computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions for causing a terminal (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of the present application.
[0174] The embodiments of the present application have been described above in conjunction with the accompanying drawings. However, the present application is not limited to the above specific implementation manners. The above specific implementation manners are merely illustrative and not restrictive. Under the inspiration of the present application, those of ordinary skill in the art can also make many forms without departing from the purpose of the present application and the scope protected by the claims, and all of them belong to the protection scope of the present application.
[0175] In the description of this specification, the description with reference to terms such as "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in a suitable manner in any one or more embodiments or examples.
[0176] If there is no special indication, all the embodiments and optional embodiments of the present application can be combined with each other to form a new technical solution.
[0177] If there is no special indication, all the technical features and optional technical features of the present application can be combined with each other to form a new technical solution.
[0178] If there is no special indication, all the steps of the present application can be carried out in sequence or randomly, and preferably in sequence. For example, the method includes steps (a) and (b), which means that the method can include steps (a) and (b) carried out in sequence, or can also include steps (b) and (a) carried out in sequence. For example, it is mentioned that the method may further include step (c), which means that step (c) can be added to the method in any order. For example, the method can include steps (a), (b), and (c), or can also include steps (a), (c), and (b), or can also include steps (c), (a), and (b), etc.
[0179] The above are only the preferred embodiments of the present application and are not intended to limit the present application. For those skilled in the art, various changes and modifications can be made to the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included within the protection scope of the present application.
Claims
1. A quality inspection method for a photovoltaic module junction box cover, characterized in that: The method comprises: Acquire a box cover image of a photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to a box cover image; Perform defect detection on the box cover image by using a pre-trained detection model to obtain one or more detection targets and the local position of each detection target in the box cover image; Based on the local position of each detection target in the box cover image, respectively perform misjudgment detection on each detection target to filter out a true detection target from the one or more detection targets; Based on the real detection targets in the box cover images corresponding to the one or more junction box covers, the quality detection result of the photovoltaic component junction box is determined.
2. The method according to claim 1, characterized in that The method of performing misjudgment detection on each detection target based on the local position of each detection target in the box cover image, so as to filter out a real detection target from the one or more detection targets, includes: For any detection target, determining the target center of the detection target based on the local position of the detection target in the box cover image; Extracting a target area corresponding to the detection target from the box cover image in combination with the local position of the detection target in the box cover image and the target center; Extracting statistical features of the target area, and performing misjudgment identification on the detected target based on the statistical features to determine whether the detected target is an actual target; If the detection target is an actual target, the detection target is regarded as the real detection target.
3. The method according to claim 2, characterized in that The extracting statistical features of the target area and performing misjudgment identification on the detected target based on the statistical features to determine whether the detected target is an actually existing target includes: Performing grayscale processing on the target area to obtain an initial grayscale area; Determine the brightness mean value and the brightness fluctuation value of the initial grayscale area respectively, and determine the abnormal pixels in the initial grayscale area based on the brightness mean value and the brightness fluctuation value; Based on the abnormal pixels in the initial grayscale area, misjudgment identification is performed on the targeted detection target to determine whether the targeted detection target is an actual existing target.
4. The method according to claim 3, characterized in that The step of performing misjudgment identification on the target to be detected based on the abnormal pixels in the initial grayscale area to determine whether the target to be detected is an actual target includes: Based on the abnormal pixels, morphological processing is performed on the initial grayscale area to obtain a target grayscale area; The area of the target grayscale region is determined, and when the area of the region exceeds a preset threshold, the detection target is determined to be an actually existing target.
5. The method according to any one of claims 1 to 4, characterized in that The real detection target at least includes a marker target; the quality detection result of the photovoltaic module junction box is determined based on the real detection target in the box cover image corresponding to each of the one or more junction box covers, including: Determining a standard quantity of a marking target based on a preset product specification of the photovoltaic module junction box; When the sum of the number of marked objects in the box cover images corresponding to the one or more junction box covers is inconsistent with the standard number, determining that the photovoltaic module junction box is a defective product; When the sum of the numbers of the marking targets in the box cover images corresponding to the one or more junction box covers is consistent with the standard number, but any marking target is not a preset mark, the photovoltaic module junction box is determined to be a defective product.
6. The method according to any one of claims 1 to 4, characterized in that The real detection target also includes a defect target; and determining the quality detection result of the photovoltaic module junction box based on the real detection target in the box cover image corresponding to each of the one or more junction box covers, further includes: In the case where any box cover image corresponding to the one or more junction box covers includes a defective object, the photovoltaic module junction box is determined to be a defective product.
7. The method according to claim 1, characterized in that The step of obtaining the image of the box cover of the photovoltaic module junction box comprises: Acquire an original image of a photovoltaic module junction box transmitted from a front end of a production line, and cut the original image based on preset product specifications of the photovoltaic module junction box to obtain a plurality of box cover images; The method further comprises: Based on the local position of the real detection target in the box cover image, the global position of the real detection target in the original image of the photovoltaic component junction box is determined.
8. The method according to claim 7, characterized in that Before cutting the original image, the method further includes: Performing brightness compensation on the original image to obtain an original image after brightness adjustment; The local contrast of the original image after brightness adjustment is adjusted to obtain a final original image.
9. The method according to claim 8, characterized in that The performing brightness compensation on the original image to obtain the original image after brightness adjustment includes: The overall brightness of the original image is scaled by a preset brightness factor, and the overall brightness is increased or decreased by a preset brightness offset, so as to obtain an original image with brightness adjusted.
10. The method according to claim 8 or 9, characterized in that: The locally adjusting the contrast of the original image after brightness adjustment to obtain a final original image includes: Dividing the brightness-adjusted original image into a plurality of local image regions; For any local image region, the statistical features of the local image region are determined, and the local image region is normalized based on the statistical features to obtain a final original image.
11. A quality inspection device for a photovoltaic module junction box cover, characterized in that: The device comprises: An acquisition module is used to acquire a box cover image of a photovoltaic module junction box; the photovoltaic module junction box includes one or more junction box covers, and each junction box cover corresponds to a box cover image; A model detection module, used to perform defect detection on the box cover image by using a pre-trained detection model to obtain one or more detection targets and a local position of each detection target in the box cover image; A false positive detection module, configured to perform false positive detection on each detection target based on a local position of each detection target in the box cover image, so as to screen out a true detection target from the one or more detection targets; The determination module is used to determine the quality detection result of the photovoltaic module junction box based on the real detection target in the box cover image corresponding to each of the one or more junction box covers.
12. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the quality detection method for the photovoltaic module junction box cover according to any one of claims 1 to 10 is implemented.
13. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the quality detection method for the junction box cover of a photovoltaic module according to any one of claims 1 to 10 is implemented.
14. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the quality detection method for a photovoltaic module junction box cover according to any one of claims 1 to 10 is implemented.