Deep vision-based defect online detection and process closed-loop compensation system and method

By using a depth vision-based online defect detection and process closed-loop compensation system, images are acquired in real time for multi-scale feature extraction and defect determination. Combined with a dedicated semantic library, quantitative compliance determination is performed, enabling real-time detection and automatic compensation of defects in the laser processing of thin-film solar cell modules. This improves production yield and detection accuracy, and meets real-time requirements.

CN123047463APending Publication Date: 2026-11-06KAICHENG INTELLIGENT TECHNOLOGY (YANGZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611227355.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-13
Publication Date
2026-11-06

AI Technical Summary

Technical Problem

In existing technologies, defect detection and process control in the laser processing of thin-film solar cell modules are disconnected, resulting in delayed defect detection and inability to stop losses in time. Furthermore, the lack of standardized labeling of defect semantics leads to a high rate of false positives and false negatives, and process parameters cannot be adjusted in a timely manner.

Method used

A depth vision-based online defect detection and process closed-loop compensation system is adopted, including imaging acquisition, visual inspection and processing, process closed-loop compensation unit and host computer galvanometer control. The system acquires images in real time through a multi-task depth vision model, performs multi-scale feature extraction, defect localization and category determination, combines a dedicated defect semantic library to perform quantitative compliance determination, and adjusts laser process parameters in real time.

Benefits of technology

It enables real-time detection and automatic compensation of defects in the laser processing of thin-film solar cell modules, reducing the rate of missed and false detections, improving production yield, meeting the requirements of micron-level accuracy and real-time performance, and eliminating the lag of manual intervention.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123047463A_ABST
    Figure CN123047463A_ABST
Patent Text Reader

Abstract

This invention discloses a depth vision-based online defect detection and process closed-loop compensation system and method, belonging to the interdisciplinary field of quality control and process control in thin-film solar cell laser manufacturing. It includes: an imaging acquisition unit; a vision detection processing unit; a process closed-loop compensation unit; and a host computer galvanometer control unit. This invention performs pixel-level segmentation within the detection box constraint range through semantic segmentation branches to obtain the precise contour of the defect, and recalculates the minimum bounding rectangle based on the contour to replace the original detection box. Compared to traditional target detection methods that only output rectangular bounding boxes, this method can closely match the true defect boundary, achieving micron-level precise measurement of geometric parameters such as line width, dead zone width, and crater size.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the interdisciplinary field of quality control and process control in the laser manufacturing of thin-film solar cells, specifically to a system and method for online defect detection and process closed-loop compensation based on depth vision. Background Technology

[0002] Perovskite modules require P1 / P2 / P3 laser scribing to form a series sub-cell structure, followed by P4 laser edge clearing to leave the encapsulation insulation area. Processing quality directly determines module efficiency and yield. Typical quality requirements (from data A / B): scribing line width tolerance ±5μm (@line width 15–200μm), dead zone ≤150μm, P4 edge clearing width tolerance ±20μm.

[0003] Currently, inspection and processing are largely disconnected in the industry. Inspection typically relies on manual visual inspection or offline AOI, meaning defects are often only discovered several wafers or even batches later. By the time defects are detected, a large number of problematic substrates have already been produced, making it impossible to stop losses immediately. Furthermore, laser processing defects have their own specific semantics—broken lines, edge connections, crater height exceeding limits, linewidth exceeding tolerances, residual material after edge cleaning, or over-etching—and general industrial vision models lack corresponding annotation systems and process criteria, resulting in high false positive and false negative rates. Even when defects are detected, the results are not fed back to the galvanometer controller or higher-level process system, leaving processing parameters unchanged, and similar defects repeatedly appearing on subsequent substrates.

[0004] Based on this, the present invention designs a system and method for online defect detection and process closed-loop compensation based on depth vision to solve the above problems. Summary of the Invention

[0005] To address the aforementioned shortcomings of existing technologies, this invention provides a system and method for online defect detection and process closed-loop compensation based on depth vision.

[0006] To achieve the above objectives, the present invention provides the following technical solution: A depth vision-based online defect detection and process closed-loop compensation system includes: Imaging acquisition unit: Deployed downstream of the laser processing station, used to acquire real-time microscopic images of the processing area on a substrate-by-substrate or in segments; Visual inspection and processing unit: acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on a multi-task deep vision model, and completes quantitative compliance determination by combining a dedicated defect semantic library and preset process window thresholds, and outputs structured defect data including defect type, defect center coordinates, geometric dimensions, parameter over-limit values, and target recognition confidence. Process closed-loop compensation unit: used for pre-stored defect-parameter compensation mapping table, and matching the corresponding laser process parameters and galvanometer control parameter adjustment amounts according to the defect type and parameter over-limit value output by the vision inspection processing unit; The host computer galvanometer control unit receives laser process parameters and galvanometer control parameter adjustments via a real-time interface, which take effect immediately in subsequent adjacent processing units or the next substrate processing flow, completing adaptive adjustments to laser power, scanning speed, focus offset, spot diameter, or focal length.

[0007] Furthermore, the imaging acquisition unit is either a coaxial imaging unit or a paraxial imaging unit.

[0008] Furthermore, the dedicated defect semantic library covers the following process defects: broken lines, connected edges, crater height exceeding limits, line width exceeding tolerance, and residual edge cleaning.

[0009] Furthermore, the multi-task deep vision model is composed of a backbone network, a multi-scale feature fusion module, a dual-branch multi-task head, and a quantization and process compliance judgment module connected in series.

[0010] Furthermore, the backbone network structure and step-by-step execution process: The backbone network of the multi-task deep vision model adopts a 50-layer deep residual network (ResNet50). The main body of the network is connected in series with five groups of convolutional modules: Conv1, Conv2_x, Conv3_x, Conv4_x, and Conv5_x. The configuration of each group of modules is fixed: Conv2_x contains 3 consecutive bottleneck residual blocks, Conv3_x contains 4 consecutive bottleneck residual blocks, Conv4_x contains 6 consecutive bottleneck residual blocks, and Conv5_x contains 3 consecutive bottleneck residual blocks. The specific implementation steps for the backbone network are as follows: Image preprocessing: The acquired microscopic images of the perovskite laser-processed area are converted to grayscale and uniformly converted into single-channel grayscale images to remove invalid color information and adapt to the scene of thin film texture and micro-defect feature extraction. Initial convolution and pooling feature extraction: The preprocessed grayscale image is input into the Conv1 module, and then undergoes 7×7 convolution operation, BN batch normalization, ReLU activation function activation in sequence. Finally, max pooling operation is performed to complete the initial extraction of the basic texture and edge contour of the image, and output the initial basic feature map. Multi-layer residual stacking for deep feature extraction: The initial basic feature map is sequentially input into four groups of residual modules: Conv2_x, Conv3_x, Conv4_x, and Conv5_x. Each bottleneck residual block adopts a standard bottleneck structure of "1×1 convolution for dimensionality reduction, 3×3 convolution for core feature extraction, and 1×1 convolution for dimensionality increase". At the same time, a short-circuit residual bypass connection mechanism is introduced to directly map the module input features to the module output, and add and fuse them element by element with the features extracted by the convolution backbone branch, finally outputting multiple groups of backbone original feature maps C2, C3, C4, and C5 at different scales.

[0011] Furthermore, the multi-scale feature fusion module structure and step-by-step execution process are as follows: The multi-scale feature fusion module adopts a feature pyramid network (FPN), taking the original C2, C3, C4, and C5 multi-scale features output by the backbone network as input. Through top-down upsampling combined with horizontal channel alignment fusion, it achieves bidirectional fusion of shallow fine edge features and high-level semantic features, generating fusion features D2, D3, D4, and D5 adapted to the detection of defects of different sizes. The specific integration steps are as follows: Deep feature initialization processing: Perform 1×1 convolution dimensionality reduction on the deepest convolutional feature map C5 of the backbone network, unify the channel dimension, and generate the initial D5 feature; Layer-by-layer upsampling and lateral fusion: The initial D5 feature is upsampled by 2 times and fused element-by-element with the C4 feature which has been channel-aligned by 1×1 convolution. Then, the upsampling aliasing interference is eliminated by 3×3 convolution, and the D4 fused feature is output. The D4 feature is upsampled by 2 times and fused element-by-element with the channel-aligned C3 feature. After smoothing and noise reduction by 3×3 convolution, the D3 fused feature is output.

[0012] Furthermore, a dual-branch, multi-task-head, step-by-step execution process. The dual-branch multi-task head shares the D2, D3, D4, and D5 fusion features. The dual-branch multi-task head consists of an object detection head branch and an instance semantic segmentation head branch. Target detection head branch execution flow: The target detection head is built based on the RetinaHead lightweight detection paradigm, reuses all fused features, adapts to the detection needs of defects of different sizes, performs convolutional regression and classification inference on the features of each layer of D2, D3, D4, and D5 in sequence, generates the defect region of interest (ROI) and the predicted probability of five defect categories one by one, takes the highest predicted probability value as the target recognition confidence, and matches the corresponding defect category with the dedicated defect semantic library to determine the defect type; Example Semantic Segmentation Head Branch Execution Flow: The semantic segmentation branch uses the defect region of interest (ROI) output by the target detection head branch as the constraint range. It abandons the indiscriminate segmentation of the whole image and only performs pixel-level segmentation inference on the local defect region. The semantic segmentation branch uses high-resolution D2 fine features as the core and D3-D5 high-level semantic features as the auxiliary. It performs binary classification pixel prediction in each defect region of interest (ROI) to accurately divide the image pixels into defect pixels and background pixels, and outputs a high-precision defect pixel mask contour.

[0013] Furthermore, the region of interest for a defect is the bounding rectangle of the defect instance. .

[0014] Furthermore, the execution process of the quantitative and process compliance judgment module: Calculate the center coordinates and geometric dimensions of the defect: perform sub-pixel edge fitting on the defect pixel mask contour of the segmented output to restore the real edge shape of the laser scribing and the defect; calculate the center coordinates and geometric dimensions of the defect based on the fitted edge segment by segment, including the actual line width of the laser scribing, the width of the processing dead zone, the diameter of the crater projection, or the area of ​​the residual area after edge clearing. Process threshold compliance determination: Based on the exclusive process constraints corresponding to various defects in the exclusive defect semantic library, the standard threshold of the perovskite laser processing process window preset by the system is retrieved, and the center coordinates and geometric dimensions of the defect are compared with the standard threshold to complete the binary compliance determination and screen out defects that exceed the standard.

[0015] A detection and compensation method, utilizing a depth vision-based online defect detection and process closed-loop compensation system, includes the following steps: Step 1: The imaging acquisition unit acquires microscopic images of the processing area in real time, one substrate at a time or one segment at a time. Step 2: The visual inspection and processing unit acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on the multi-task deep vision model, and completes quantitative compliance determination by combining the exclusive defect semantic library and the preset process window threshold, and outputs structured defect data including defect type, defect center coordinates, geometric size, parameter over-standard amplitude, and target recognition confidence. Step 3: The process closed-loop compensation unit, based on the pre-stored defect-parameter compensation mapping table and according to the defect type and parameter over-limit value output by the visual inspection processing unit, matches and obtains the corresponding laser process parameters and galvanometer control parameter adjustment amounts. Step 4: The host computer galvanometer control unit receives the laser process parameters and galvanometer control parameter adjustment amounts through the real-time interface, and the adjustment takes effect immediately in the subsequent adjacent processing unit or the next substrate processing flow, completing the adaptive adjustment of laser power, scanning speed, focus offset, spot diameter or focal length. Step 5: The host computer galvanometer control unit feeds back the re-inspection data after compensation to the vision inspection processing unit, calculates the residual between the re-inspection defect center coordinates and geometric dimensions and the standard threshold, updates the adjustment weights in the defect-parameter compensation mapping table proportionally based on the residual, iteratively optimizes the standard threshold and defect-parameter compensation mapping table of the multi-task depth vision model, and realizes closed-loop control of laser processing defect detection and process parameter compensation.

[0016] Beneficial Effects: This invention performs pixel-level segmentation within the bounded area of ​​the detection box using a semantic segmentation branch to obtain the precise contour of the defect. Based on this contour, the minimum bounding rectangle is recalculated to replace the original detection box. Compared to traditional object detection methods that only output rectangular bounding boxes, this invention closely matches the true boundary of the defect, achieving micron-level precision measurement of geometric parameters such as line width, dead zone width, and crater size. A multi-task training mechanism jointly optimized by Dice loss and binary cross-entropy loss effectively improves the feature learning ability of small-sized defects such as micro-broken lines and micro-craters, reducing the probability of missed and false detections, addressing the issues of extremely low pixel proportions and imbalanced samples in perovskite micro-defects. By locking the region of interest through the detection branch and constraining the segmentation branch to perform pixel-level inference only within the local defect area, it abandons indiscriminate segmentation of the entire image, significantly reducing computational load. While maintaining micron-level measurement accuracy, it meets the real-time requirements of online production line inspection (single-frame inference time does not exceed the processing cycle time). The defect type output by visual inspection is combined with the over-standard amplitude of geometric parameters calculated based on the precise contour. A defect-parameter compensation mapping table is used to generate process parameter adjustment amounts in real time, which are then fed back to the processing execution unit. Compared to the traditional open-loop model of "detection, manual judgment, and manual parameter adjustment", this system achieves a fully automated closed loop of detection, judgment, and compensation, eliminating the lag of manual intervention. Attached Figure Description

[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are merely some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without any creative effort.

[0018] Figure 1 This is a block diagram of the online defect detection and process closed-loop compensation system based on depth vision according to the present invention. Figure 2 This is a flowchart of the online defect detection and process closed-loop compensation method based on depth vision according to the present invention. Detailed Implementation

[0019] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0020] Example 1: Please refer to the accompanying drawings in the instruction manual. Figure 1 A depth vision-based online defect detection and process closed-loop compensation system includes: Imaging acquisition unit: Deployed downstream of the laser processing station, used to acquire real-time microscopic images of the processing area on a substrate-by-substrate or in segments; The imaging acquisition unit is either a coaxial imaging unit or a paraxial imaging unit; The imaging acquisition unit is paired with a microscope lens; The object space resolution of the imaging acquisition unit is 1-2 μm / pixel, which meets the high-precision measurement requirements of scribing line width tolerance ±5 μm and line width 15-200 μm and micron-level defect contours. The imaging acquisition unit uses a 5-12 megapixel area array CMOS / CCD image sensor, is compatible with imaging lenses of 4x or higher magnification, and has an imaging alignment accuracy of less than ±2μm, making it suitable for micron-level defect detection scenarios in perovskite laser processing.

[0021] Visual inspection and processing unit: Acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on a multi-task deep vision model, and completes quantitative compliance determination by combining a dedicated defect semantic library and preset process window thresholds, and outputs structured defect data including defect type, defect center coordinates, geometric dimensions, parameter over-limit values, and target recognition confidence.

[0022] The dedicated defect semantic library covers the following process defects: broken lines, connected edges, crater height exceeding limits, line width exceeding tolerance, and residual cleaning edges. The multi-task deep vision model is composed of a backbone network, a multi-scale feature fusion module, a dual-branch multi-task head, and a quantization and process compliance judgment module connected in series.

[0023] 1. Backbone network structure and step-by-step execution process: The backbone network of the multi-task deep vision model adopts a 50-layer deep residual network (ResNet50). The main body of the network is connected in series with five groups of convolutional modules: Conv1, Conv2_x, Conv3_x, Conv4_x, and Conv5_x. The configuration of each group of modules is fixed: Conv2_x contains 3 consecutive bottleneck residual blocks, Conv3_x contains 4 consecutive bottleneck residual blocks, Conv4_x contains 6 consecutive bottleneck residual blocks, and Conv5_x contains 3 consecutive bottleneck residual blocks.

[0024] The specific implementation steps for the backbone network are as follows: Image preprocessing: The acquired microscopic images of the perovskite laser-processed area are converted to grayscale and uniformly transformed into single-channel grayscale images to remove invalid color information and adapt to the scene of thin film texture and micro-defect feature extraction.

[0025] Initial convolution and pooling feature extraction: The preprocessed grayscale image is input into the Conv1 module, and then undergoes 7×7 convolution operation, BN batch normalization, ReLU activation function activation, and finally max pooling operation to complete the initial extraction of the image's underlying basic texture and edge contours, and output the initial basic feature map.

[0026] Multi-layer residual stacking for deep feature extraction: The initial basic feature map is sequentially input into four sets of residual modules: Conv2_x, Conv3_x, Conv4_x, and Conv5_x. Each bottleneck residual block adopts a standard bottleneck structure of "1×1 convolution for dimensionality reduction, 3×3 convolution for core feature extraction, and 1×1 convolution for dimensionality increase." Simultaneously, a short-circuit residual bypass connection mechanism is introduced to directly map the module input features to the module output, fusing them element-wise with the features extracted from the convolutional backbone. This structure effectively alleviates the gradient vanishing problem in deep networks, ensuring that shallow features with subtle defects such as broken lines and small craters can be stably propagated to higher layers of the network. Finally, multiple sets of backbone original feature maps C2, C3, C4, and C5 at different scales are output.

[0027] 2. Multi-scale feature fusion module structure and step-by-step execution process: The multi-scale feature fusion module adopts a feature pyramid network (FPN), taking the original C2, C3, C4, and C5 multi-scale features output by the backbone network as input. Through top-down upsampling combined with lateral channel alignment fusion, it achieves bidirectional fusion of shallow fine edge features and high-level semantic features, generating fusion features D2, D3, D4, and D5 adapted to the detection of defects of different sizes.

[0028] The specific integration steps are as follows: Deep feature initialization processing: Perform 1×1 convolution dimensionality reduction on the deepest convolutional feature map C5 of the backbone network, unify the channel dimension, and generate the initial D5 feature.

[0029] Layer-by-layer upsampling and lateral fusion: The initial D5 feature is upsampled by 2 times and fused element-by-element with the C4 feature which has been channel-aligned by 1×1 convolution. Then, the upsampling aliasing interference is eliminated by 3×3 convolution, and the D4 fused feature is output. The D4 feature is upsampled by 2 times and fused element-by-element with the channel-aligned C3 feature. After smoothing and noise reduction by 3×3 convolution, the D3 fused feature is output.

[0030] Highest resolution feature generation: The D3 feature is upsampled by 2 times to pass the high-level defect semantic information upward; at the same time, the shallow high-precision C2 feature output by Conv2_x is aligned by 1×1 convolution channel dimension, and the upsampled D3 high-level semantic feature is fused with the shallow fine C2 feature element by element. Finally, the sampling aliasing effect is suppressed by 3×3 convolution to generate the D2 fused feature with the highest spatial resolution in the entire network.

[0031] Each layer of fused features has a clear division of labor: D2 features retain the ultimate image edges and spatial details, and are mainly used for laser scribing edge extraction, precise line width measurement, and geometric size calculation of micron-level small defects such as micro craters and micro breaks; D3, D4, and D5 features have rich high-level semantic information, which can effectively distinguish various defect morphologies, while suppressing texture noise in perovskite substrate films, and are suitable for identifying large-scale defects such as edge connections and large-area edge clearing residues.

[0032] 3. Dual-branch, multi-task-head, step-by-step execution process: The dual-branch multi-task head shares the D2, D3, D4, and D5 fusion features. The dual-branch multi-task head consists of an object detection head branch and an instance semantic segmentation head branch. It adopts a multi-task architecture with parallel inference for detection and segmentation. Through dual-branch collaborative optimization, it can simultaneously achieve accurate localization and classification of defect instances and pixel-level contour segmentation, balancing detection real-time performance and measurement accuracy.

[0033] Execution flow of the target detection head branch: The target detection head is built on the RetinaHead lightweight detection paradigm, reusing all fused features to adapt to the detection needs of defects of different sizes. Convolutional regression and classification inference are performed on the features of each layer (D2, D3, D4, D5) in sequence to generate the region of interest (ROI) of the defect and the predicted probability of the five defect categories. The highest predicted probability is used as the target recognition confidence, and the corresponding defect category is matched with the dedicated defect semantic library to determine the defect type.

[0034] The region of interest for a defect is the bounding rectangle of the defect instance. ; The target detection head branch quickly filters effective defect regions of interest, filters large areas of defect-free substrate background, and shields invalid noise features, significantly reducing the computational load of subsequent segmentation branches. This ensures real-time inference speed for online detection on the production line and can accurately identify five types of defects: broken lines, connected edges, crater height exceeding limits, line width exceeding tolerance, and residual edge clearing.

[0035] Execution flow of the instance semantic segmentation head branch: The semantic segmentation branch uses the defect region of interest (ROI) output by the target detection head branch as the constraint range, abandons the indiscriminate segmentation of the whole image, and only performs pixel-level segmentation inference on the local defect region. The semantic segmentation branch uses high-resolution D2 fine features as the core and D3-D5 high-level semantic features as the auxiliary. It performs binary classification pixel prediction in each defect region of interest (ROI) to accurately divide the image pixels into defect pixels and background pixels, and outputs high-precision defect pixel mask contours.

[0036] The dual-branch multi-task head linkage optimization logic: On the one hand, the segmentation calculation range is locked by the detection box, which greatly reduces the inference latency and meets the real-time detection requirements of industrial production lines; on the other hand, based on the defect pixel mask contour of the segmentation output, the minimum bounding rectangle of the defect area is recalculated to replace the original rectangular bounding box output by the target detection head, which solves the error problem that the traditional detection box cannot fit the real contour of the defect and significantly improves the defect positioning accuracy and size measurement accuracy.

[0037] 4. Quantitative and Process Compliance Judgment Module Execution Process: After the model completes parallel inference across two branches, the post-processing module accurately converts visual features into process quantification indicators. Combined with a preset process window threshold, compliance determination is then performed. The specific steps are as follows: Calculate the center coordinates and geometric dimensions of the defect: perform sub-pixel edge fitting on the defect pixel mask contour of the segmented output to restore the real edge shape of the laser scribing and the defect; calculate the center coordinates and geometric dimensions of the defect based on the fitted edge segment by segment, including the actual line width of the laser scribing, the width of the processing dead zone, the diameter of the crater projection, or the area of ​​the residual area after edge clearing. Process threshold compliance determination: Based on the exclusive process constraints corresponding to various defects in the exclusive defect semantic library, the system retrieves the standard thresholds of the perovskite laser processing process window, which specifically include: laser scribing line width tolerance ±5μm and line width 15–200μm, dead zone width ≤150μm, P4 edge clearing width tolerance ±20μm. The defect center coordinates and geometric dimensions are compared with the standard thresholds to complete the binary compliance determination and screen out defects that exceed the standard.

[0038] Calculate the parameter overshoot amplitude and integrate the output into structured defect data that includes defect type, defect center coordinates, geometric dimensions, parameter overshoot amplitude, and target recognition confidence.

[0039] The parameter exceeding the standard value is the deviation between the measured defect center coordinates and geometric dimensions and the standard threshold of the corresponding defect-specific process; 5. Multi-task joint training mechanism for the model This multi-task deep vision model employs a multi-task joint training mechanism, with the overall loss function consisting of a weighted average of the object detection loss and the mask segmentation loss. Addressing industry pain points such as the extremely low pixel ratio of perovskite micro-defects and imbalanced samples, the segmentation loss is jointly optimized using Dice loss and binary cross-entropy loss. This effectively improves the training convergence of small-sized defects such as micro-broken lines and micro-craters, reduces the probability of missed and false detections, and ensures the model's detection accuracy and stability in actual production lines.

[0040]

[0041] The overall loss function for the multi-task deep vision model is... For the target detection head branch loss, For instance semantic segmentation head branch loss, The weight balancing coefficient for the segmentation loss is set to a value ranging from 0.4 to 1.0. This coefficient is used to balance the magnitude of the loss between the two branches and is suitable for multi-task collaborative training scenarios.

[0042] Target detection head branch loss It consists of both defect classification loss and detection box regression loss, and is used to constrain the accuracy of defect category recognition and defect location. Instance semantic segmentation head branch loss The formula combines Dice loss and binary cross-entropy loss:

[0043] For binary classification, cross-entropy loss, For the loss of Des; Addressing the industry pain points of extremely low pixel ratio and sample imbalance in perovskite micro-defects, this composite loss combination can effectively improve the problem of insufficient feature learning for small-sized defects. The binary cross-entropy loss is used to supervise pixel-level class differentiation, while the Dessian loss is used to optimize the overlap and segmentation integrity of micro-defect regions. This can significantly improve the training convergence effect of small-sized defects such as micro-broken lines and micro-craters, reduce the probability of missed detection and false detection, and ensure the accuracy and stability of the model in actual production line detection.

[0044] Process closed-loop compensation unit: used for pre-stored defect-parameter compensation mapping table, and matching the corresponding laser process parameters and galvanometer control parameter adjustment amounts according to the defect type and parameter over-limit value output by the vision inspection processing unit; The defect-parameter compensation mapping is represented as follows:

[0045] The host computer galvanometer control unit receives laser process parameters and galvanometer control parameter adjustments through a real-time interface, and takes effect immediately in subsequent adjacent processing units or the next substrate processing flow, completing adaptive adjustments to laser power, scanning speed, focus offset, spot diameter or focal length. Simultaneously, the re-inspection data after compensation processing is fed back to the vision inspection processing unit to calculate the residual between the re-inspection defect center coordinates and geometric dimensions and the standard threshold. Based on the residual, the adjustment weights in the defect-parameter compensation mapping table are updated proportionally. The standard threshold and defect-parameter compensation mapping table of the multi-task depth vision model are iteratively optimized to achieve closed-loop control of laser processing defect detection and process parameter compensation.

[0046] Example 2: Please refer to the accompanying drawings in the instruction manual. Figure 2 A detection and compensation method, utilizing a depth vision-based online defect detection and process closed-loop compensation system, includes the following steps: Step 1: The imaging acquisition unit acquires microscopic images of the processing area in real time, one substrate at a time or one segment at a time. Step 2: The visual inspection and processing unit acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on the multi-task deep vision model, and completes quantitative compliance determination by combining the exclusive defect semantic library and the preset process window threshold, and outputs structured defect data including defect type, defect center coordinates, geometric size, parameter over-standard amplitude, and target recognition confidence. Step 3: The process closed-loop compensation unit, based on the pre-stored defect-parameter compensation mapping table and according to the defect type and parameter over-limit value output by the visual inspection processing unit, matches and obtains the corresponding laser process parameters and galvanometer control parameter adjustment amounts. Step 4: The host computer galvanometer control unit receives the laser process parameters and galvanometer control parameter adjustment amounts through the real-time interface, and the adjustment takes effect immediately in the subsequent adjacent processing unit or the next substrate processing flow, completing the adaptive adjustment of laser power, scanning speed, focus offset, spot diameter or focal length. Step 5: The host computer galvanometer control unit feeds back the re-inspection data after compensation to the vision inspection processing unit, calculates the residual between the re-inspection defect center coordinates and geometric dimensions and the standard threshold, updates the adjustment weights in the defect-parameter compensation mapping table proportionally based on the residual, iteratively optimizes the standard threshold and defect-parameter compensation mapping table of the multi-task depth vision model, and realizes closed-loop control of laser processing defect detection and process parameter compensation.

[0047] By using a semantic segmentation branch to perform pixel-level segmentation within the bounded bounding box, the precise contour of the defect is obtained. The minimum bounding rectangle is then recalculated based on this contour to replace the original bounding box. Compared to traditional object detection methods that only output rectangular bounding boxes, this approach closely matches the true boundary of the defect, achieving micrometer-level precision measurement of geometric parameters such as line width, dead zone width, and crater size. A multi-task training mechanism jointly optimized by Dice loss and binary cross-entropy loss effectively improves the feature learning capability for small-sized defects such as micro-broken lines and micro-craters, addressing the issues of extremely low pixel proportions and imbalanced samples in perovskite micro-defects, thus reducing the probability of missed and false detections.

[0048] By identifying the region of interest through the detection branch and constraining the segmentation branch to perform pixel-level inference only within the local defect area, the computational load is significantly reduced, eliminating the need for indiscriminate segmentation of the entire image. This approach maintains micrometer-level measurement accuracy while meeting the real-time requirements of online production line inspection (single-frame inference time does not exceed the processing cycle time).

[0049] By combining the defect type output by visual inspection with the out-of-range value of geometric parameters based on precise contour calculation, the process parameter adjustment amount is generated in real time through a defect-parameter compensation mapping table and fed back to the processing execution unit. Compared with the traditional open-loop mode of "inspection, manual judgment, and manual parameter adjustment", this achieves a fully automated closed loop of inspection, judgment, and compensation, eliminating the lag of manual intervention.

[0050] By classifying the degree of defects according to the defect type and the range of exceedance values ​​through a mapping table, the corresponding multi-parameter linkage adjustment amount is output (such as adjusting power and speed simultaneously for edge defects), so as to achieve targeted and refined compensation and avoid the "one-size-fits-all" coarse adjustment.

[0051] By implementing real-time detection and immediate compensation, process corrections are made in the early stages of defect occurrence, preventing the recurrence of similar defects on subsequent substrates. According to data from the example, the overall yield is expected to improve by more than 2% (the specific value is subject to actual measurement), while reducing the manpower required for manual inspection.

[0052] By feeding the compensated re-inspection data back into the system, the residuals between the re-inspection geometric parameters and the standard thresholds are calculated. Based on these residuals, the adjustment weights in the mapping table are updated proportionally, enabling online iterative optimization of the mapping table. Simultaneously, the re-inspection data can be used to continuously correct the judgment thresholds of the detection model, giving the system continuous learning and adaptive capabilities.

[0053] Specific Case 1 (FCS10 standalone, Document B): An in-situ imaging unit is added downstream of the off-axis CCD of the FCS10-300-300 scribing and edge cleaning integrated device to perform real-time scribing of P1–P3 and edge cleaning of P4 on a 300×300mm substrate. When a P2 / P3 connection is detected, the laser power of that sub-cell area is reduced by 3–5% and the scanning speed is increased according to the mapping table. The connection rate of the same type on the next substrate decreases, and the scribing linewidth deviation is maintained within a window of ±5μm and dead zone <150μm.

[0054] Specific Case Study 2 (1200×600 Production Line, Data A): Applied to the online inspection station of a fully automated production line, it independently determines the dead zone ≤150μm for each channel of 12 beams processed in parallel. In a certain batch, due to material fluctuations, the crater exceeded the limit. The system automatically compensated for the focus offset, reducing the rate of broken wires and crater defects, and improving the yield by more than 2%.

[0055] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions will not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A depth vision-based online defect detection and process closed-loop compensation system, characterized in that, include: Imaging acquisition unit: Deployed downstream of the laser processing station, used to acquire real-time microscopic images of the processing area on a substrate-by-substrate or in segments; Visual inspection and processing unit: acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on a multi-task deep vision model, and completes quantitative compliance determination by combining a dedicated defect semantic library and preset process window thresholds, and outputs structured defect data including defect type, defect center coordinates, geometric dimensions, parameter over-limit values, and target recognition confidence. Process closed-loop compensation unit: used for pre-stored defect-parameter compensation mapping table, and matching the corresponding laser process parameters and galvanometer control parameter adjustment amounts according to the defect type and parameter over-limit value output by the vision inspection processing unit; The host computer galvanometer control unit receives laser process parameters and galvanometer control parameter adjustments via a real-time interface, which take effect immediately in subsequent adjacent processing units or the next substrate processing flow, completing adaptive adjustments to laser power, scanning speed, focus offset, spot diameter, or focal length.

2. The online defect detection and process closed-loop compensation system based on depth vision according to claim 1, characterized in that, The imaging acquisition unit is either a coaxial imaging unit or a paraxial imaging unit.

3. The online defect detection and process closed-loop compensation system based on depth vision according to claim 2, characterized in that, The dedicated defect semantic library covers the following process defects: broken lines, connected edges, crater height exceeding limits, line width exceeding tolerance, and residual edge cleaning.

4. The online defect detection and process closed-loop compensation system based on depth vision according to any one of claims 1-3, characterized in that, The multi-task deep vision model is composed of a backbone network, a multi-scale feature fusion module, a dual-branch multi-task head, and a quantization and process compliance judgment module connected in series.

5. The online defect detection and process closed-loop compensation system based on depth vision according to claim 4, characterized in that, Backbone network structure and step-by-step execution process: The backbone network of the multi-task deep vision model adopts a 50-layer deep residual network (ResNet50). The main body of the network is connected in series with five groups of convolutional modules: Conv1, Conv2_x, Conv3_x, Conv4_x, and Conv5_x. The configuration of each group of modules is fixed: Conv2_x contains 3 consecutive bottleneck residual blocks, Conv3_x contains 4 consecutive bottleneck residual blocks, Conv4_x contains 6 consecutive bottleneck residual blocks, and Conv5_x contains 3 consecutive bottleneck residual blocks. The specific implementation steps for the backbone network are as follows: Image preprocessing: The acquired microscopic images of the perovskite laser-processed area are converted to grayscale and uniformly converted into single-channel grayscale images to remove invalid color information and adapt to the scene of thin film texture and micro-defect feature extraction. Initial convolution and pooling feature extraction: The preprocessed grayscale image is input into the Conv1 module, and then undergoes 7×7 convolution operation, BN batch normalization, ReLU activation function activation in sequence. Finally, max pooling operation is performed to complete the initial extraction of the basic texture and edge contour of the image, and output the initial basic feature map. Multi-layer residual stacking for deep feature extraction: The initial basic feature map is sequentially input into four groups of residual modules: Conv2_x, Conv3_x, Conv4_x, and Conv5_x. Each bottleneck residual block adopts a standard bottleneck structure of "1×1 convolution for dimensionality reduction, 3×3 convolution for core feature extraction, and 1×1 convolution for dimensionality increase". At the same time, a short-circuit residual bypass connection mechanism is introduced to directly map the module input features to the module output, and add and fuse them element by element with the features extracted by the convolution backbone branch, finally outputting multiple groups of backbone original feature maps C2, C3, C4, and C5 at different scales.

6. The online defect detection and process closed-loop compensation system based on depth vision according to claim 5, characterized in that, Multi-scale feature fusion module structure and step-by-step execution process: The multi-scale feature fusion module adopts a feature pyramid network (FPN), taking the original C2, C3, C4, and C5 multi-scale features output by the backbone network as input. Through top-down upsampling combined with horizontal channel alignment fusion, it achieves bidirectional fusion of shallow fine edge features and high-level semantic features, generating fusion features D2, D3, D4, and D5 adapted to the detection of defects of different sizes. The specific integration steps are as follows: Deep feature initialization processing: Perform 1×1 convolution dimensionality reduction on the deepest convolutional feature map C5 of the backbone network, unify the channel dimension, and generate the initial D5 feature; Layer-by-layer upsampling and lateral fusion: The initial D5 feature is upsampled by 2 times and fused element-by-element with the C4 feature which has been channel-aligned by 1×1 convolution. Then, the upsampling aliasing interference is eliminated by 3×3 convolution, and the D4 fused feature is output. The D4 feature is upsampled by 2 times and fused element-by-element with the channel-aligned C3 feature. After smoothing and noise reduction by 3×3 convolution, the D3 fused feature is output.

7. The online defect detection and process closed-loop compensation system based on depth vision according to claim 6, characterized in that, Dual-branch multi-task-head step-by-step execution process The dual-branch multi-task head shares the D2, D3, D4, and D5 fusion features. The dual-branch multi-task head consists of an object detection head branch and an instance semantic segmentation head branch. Target detection head branch execution flow: The target detection head is built based on the RetinaHead lightweight detection paradigm, reuses all fused features, adapts to the detection needs of defects of different sizes, performs convolutional regression and classification inference on the features of each layer of D2, D3, D4, and D5 in sequence, generates the defect region of interest (ROI) and the predicted probability of five defect categories one by one, takes the highest predicted probability value as the target recognition confidence, and matches the corresponding defect category with the dedicated defect semantic library to determine the defect type; Example Semantic Segmentation Head Branch Execution Flow: The semantic segmentation branch uses the defect region of interest (ROI) output by the target detection head branch as the constraint range. It abandons the indiscriminate segmentation of the whole image and only performs pixel-level segmentation inference on the local defect region. The semantic segmentation branch uses high-resolution D2 fine features as the core and D3-D5 high-level semantic features as the auxiliary. It performs binary classification pixel prediction in each defect region of interest (ROI) to accurately divide the image pixels into defect pixels and background pixels, and outputs a high-precision defect pixel mask contour.

8. The online defect detection and process closed-loop compensation system based on depth vision according to claim 7, characterized in that, The region of interest for a defect is the bounding rectangle of the defect instance. .

9. The online defect detection and process closed-loop compensation system based on depth vision according to claim 7, characterized in that, Execution flow of the quantitative and process compliance judgment module: Calculate the center coordinates and geometric dimensions of the defect: perform sub-pixel edge fitting on the defect pixel mask contour of the segmented output to restore the real edge shape of the laser scribing and the defect; calculate the center coordinates and geometric dimensions of the defect based on the fitted edge segment by segment, including the actual line width of the laser scribing, the width of the processing dead zone, the diameter of the crater projection, or the area of ​​the residual area after edge clearing. Process threshold compliance determination: Based on the exclusive process constraints corresponding to various defects in the exclusive defect semantic library, the standard threshold of the perovskite laser processing process window preset by the system is retrieved, and the center coordinates and geometric dimensions of the defect are compared with the standard threshold to complete the binary compliance determination and screen out defects that exceed the standard.

10. A detection compensation method, utilizing the depth vision-based online defect detection and process closed-loop compensation system as described in any one of claims 1-9, characterized in that, Includes the following steps: Step 1: The imaging acquisition unit acquires microscopic images of the processing area in real time, one substrate at a time or one segment at a time. Step 2: The visual inspection and processing unit acquires microscopic images of the laser processing area, completes multi-scale feature extraction, defect instance localization, and defect category determination based on the multi-task deep vision model, and completes quantitative compliance determination by combining the exclusive defect semantic library and the preset process window threshold, and outputs structured defect data including defect type, defect center coordinates, geometric size, parameter over-standard amplitude, and target recognition confidence. Step 3: The process closed-loop compensation unit, based on the pre-stored defect-parameter compensation mapping table and according to the defect type and parameter over-limit value output by the visual inspection processing unit, matches and obtains the corresponding laser process parameters and galvanometer control parameter adjustment amounts. Step 4: The host computer galvanometer control unit receives the laser process parameters and galvanometer control parameter adjustment amounts through the real-time interface, and the adjustment takes effect immediately in the subsequent adjacent processing unit or the next substrate processing flow, completing the adaptive adjustment of laser power, scanning speed, focus offset, spot diameter or focal length. Step 5: The host computer galvanometer control unit feeds back the re-inspection data after compensation to the vision inspection processing unit, calculates the residual between the re-inspection defect center coordinates and geometric dimensions and the standard threshold, updates the adjustment weights in the defect-parameter compensation mapping table proportionally based on the residual, iteratively optimizes the standard threshold and defect-parameter compensation mapping table of the multi-task depth vision model, and realizes closed-loop control of laser processing defect detection and process parameter compensation.