A whole vehicle part coating line defect closed-loop regulation method and system

CN123010675APending Publication Date: 2026-10-30ZHEJIANG JIUTONG INTELLIGENT EQUIP CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202611332153.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-31
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0012]本发明的目的在于提供一种整车零部件涂装线缺陷闭环调控方法及系统,以解决现有技术中检测结果难以直接转化为喷涂执行动作、复杂曲面缺陷成因被过度线性化处理以及返修控制与主线节拍彼此割裂的技术问题,从而在整车零部件涂装线上实现缺陷发现、缺陷定位、成因判别、补偿执行和效果再验证的闭环调控

Benefits of technology

[0061]第一,实现检测结果到喷涂动作的直接闭环转换。针对现有技术中检测结果停留于图像域、难以直接驱动喷枪补喷的问题,本发明通过引入分区级坐标映射、挂具位姿修正以及分区增强状态向量,将视觉像素缺陷直接转换为局部补喷动作,并进一步输出轨迹偏移补偿、速度补偿、流量补偿和停留时间补偿。由于像素域缺陷位置经过挂具坐标转换、分区归属判定和局部相对坐标定位后进入执行层,因此能够缩短从缺陷发现到生成可执行补喷指令的链路长度,减少检测域与执行域之间的人工解释环节。在保险杠色漆线连续 120件实测 A/B 对照中,检测后至下发补喷寄存器指令的平均时间由对照方案的 2.9±0.5 s降至 1.1±0.2 s,自动闭环覆盖率由 63%±4% 提升至 86%±3%。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123010675A_ABST
    Figure CN123010675A_ABST
Patent Text Reader

Abstract

The application discloses a kind of whole vehicle parts coating line defect closed-loop regulation methods and systems, belong to automobile manufacturing and industrial automation technical field.Visual inspection, conveying displacement, spraying process and beat state data are collected and time alignment is completed;Defect pixel cluster is mapped to surface partition and relative coordinate under hanger coordinate system by hanger pose correction;Based on direct observation state, respectively update insufficient factor and excessive deposition factor, combined with history recurrence, adjacent partition risk, beat allowance and transmission distance to build enhanced state and evaluate comprehensive defect risk;Local supplementary spraying candidate action is generated, and execution action is projected by process spraying constraint, trajectory accessibility and beat constraint, to complete supplementary spraying, reinspection and abnormal degradation switching.The application can realize the direct closed-loop conversion of detection result to spraying action, reduce over-supplying and missing-supplying risk, and improve main line beat stability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of automotive manufacturing and industrial automation technology, specifically relating to a closed-loop control method and system for defects in a vehicle parts painting line. Background Technology

[0002] As automobile manufacturing moves towards greater flexibility, faster production cycles, and higher consistency, the painting lines for vehicle parts have evolved from simple painting execution stages into complex manufacturing processes integrating process control, online inspection, quality tracking, and rework decision-making. For irregularly shaped parts such as bumpers, rearview mirror housings, door handles, and wheel arch trims, the final coating defects are usually not caused by a single abnormal parameter, but rather by the coupling of multiple factors, including spray gun trajectory, workpiece posture, line cycle time, paint mist deposition, voltage and air pressure fluctuations, local masking, edge leveling, and the surface condition before drying.

[0003] Current production typically employs preset spraying trajectories and uniform process parameters. This involves determining the spray gun path, distance, atomization pressure, and output during offline teaching, and then repeating this process at a fixed pace during online production. This approach assumes that the same trajectory and parameters can achieve approximately consistent film thickness and appearance across different component batches, fixture deviations, and environmental disturbances. However, in actual production, surface curvature, edge electric field, local backflow, and occlusion relationships can alter the spatial distribution of paint droplet deposition nuclei, resulting in different deposition outcomes for the same input control parameters. This leads to defects such as orange peel, exposed substrate, runs, particles, pinholes, and localized loss of gloss. Especially when defects occur only in localized areas, traditional full-part repainting or manual touch-up not only disrupts the continuity of the production cycle but also makes it difficult to establish iterative closed-loop corrections at the process level.

[0004] To address the specific problems in the above process, existing technologies have explored several approaches, which can be mainly divided into two categories based on their technical routes: one focuses on improving the accuracy of online detection triggering and quality perception, and the other focuses on adjusting the feedback of spraying execution parameters.

[0005] The first type of method primarily focuses on optimizing detection triggering and quality perception. For example, Chinese patent CN202511714419.8 discloses an encoder-triggered intelligent detection method and system for automotive painting lines. It improves the shooting position accuracy of a line scan camera under speed fluctuations through encoders, photoelectric sensors, Kalman filter prediction, and adaptive correction of the trigger window. This type of technology mainly optimizes the stability of image acquisition time and position, focusing on more stable acquisition of detection images rather than directly converting the detection results into spray gun re-spraying actions. Another example is Chinese patent CN202610500513.1, which discloses a spunlace nonwoven fabric microcapsule uniform spraying system based on machine vision feedback. This system achieves uniform spraying by dividing the image into virtual detection areas, extracting the average grayscale of the areas, and adjusting the flow rate of each spraying unit using an inverse linear compensation model. This type of method is suitable for continuous planar materials or near-single-medium thickness compensation scenarios. It deals with continuous strip-shaped media with relatively regular spatial relationships and does not address deposition differences caused by complex curved surfaces, corners, and occlusion conditions in automotive parts.

[0006] The second type of method mainly focuses on feedback control of spraying parameters. For example, Chinese patent CN202511324072.6 discloses a real-time monitoring and feedback control system for enamel electrostatic powder coating. It constructs a state vector by collecting powder state, deposition error, and environmental interference, dynamically adjusting electrode voltage, powder supply, and spray gun path, and combining optimization algorithms to balance uniformity and efficiency. This type of technology is largely based on the stable control of continuous deposition quality in a single process station, assuming the ability to continuously obtain sufficiently timely and relatively direct deposition error signals. However, it does not adequately address issues such as fixture coordinate drift, workpiece posture changes, and rework insertion under cycle time constraints between defect detection locations and subsequent correctable spraying locations in automotive parts coating lines.

[0007] While the aforementioned existing technologies have solved specific problems in terms of improving detection accuracy, regional coating compensation, and real-time feedback control, they still have the following shortcomings in the scenario of closed-loop control of defects in the whole vehicle parts painting line:

[0008] First, there is a physical disconnect between the defect detection coordinates and the spraying execution coordinates. The output of the first type of detection method mentioned above is essentially correction information for the image acquisition time or position, while the spray gun execution relies on the fixture coordinate system, the local normal of the component, the spray gun posture, and the reachable trajectory parameters. Without a unified mapping from the image defect area to the component surface partition and then to the spray gun action parameters, the detection results can usually only be used for alarms or manual review, making it difficult to form a machine-executable closed-loop control chain. For parts such as bumper corners, door handle grooves, and rearview mirror housing edges, there are also transport displacement, fixture micro-sway, and posture accumulation errors between the visual detection position and the re-spraying position. If the pixel domain coordinates are not converted to the partition local coordinates after fixture posture correction, the re-spraying position is prone to deviating from the actual defect area.

[0009] Secondly, the defect compensation model is insufficient in representing the deposition mechanism of complex curved surfaces. The aforementioned method of regional grayscale inverse compensation is suitable for continuous planes or near-single medium thickness compensation scenarios. However, automotive parts have edge effects, concave-convex curvature variations, local occlusion, and attitude shifts. The same visual grayscale deviation does not necessarily correspond to the same increase or decrease in spray volume. The causes of defects are not limited to uneven material distribution, but may also come from trajectory deviation, changes in gun distance, and insufficient coverage caused by advance of the cycle. Under the assumption of a single linear compensation, defects of different causes will be compressed to similar control values, which can easily lead to over-compensation, under-compensation, or induce sagging in the corner areas. Especially when there is a tendency for bright thin spraying and the risk of edge accumulation in the same area, if insufficient coverage and excessive deposition are not modeled separately, it is difficult to distinguish whether to compensate for coverage by slowing down and increasing flow, or to suppress local accumulation by limiting flow and residence.

[0010] Secondly, existing technologies lack mechanisms for abnormal degradation and rework insertion that are coordinated with production cycle time. While the aforementioned feedback control methods possess some parameter adjustment capabilities, they are insufficient in resolving the contradiction in automotive parts production lines where defect control cannot indefinitely interrupt the main line cycle time. On actual production lines, there are clear cycle time window constraints between local respraying, whole-part respraying, manual re-inspection, and release decisions. If there is only quality feedback without a coordinated decision-making mechanism between defect level, respraying duration, insertion station, and cycle time delay tolerance, the system will either frequently trigger conservative stoppages or allow minor defects to accumulate, making it difficult to establish a stable engineering balance between quality and capacity. Furthermore, local respraying introduces the risk of overspraying in adjacent areas, robot trajectory switching delays, and buffer space occupancy constraints. If these constraints are not evaluated in a unified manner with defect risks, the main line cannot operate stably and continuously.

[0011] Therefore, there is an urgent need in this field for a closed-loop control scheme for defects in the painting line of vehicle parts that can directly convert online visual inspection results into painting execution actions, decompose and model the causes of defects on complex curved surfaces, and complete local repainting decisions and abnormal degradation switching under cycle constraints. Summary of the Invention

[0012] The purpose of this invention is to provide a closed-loop control method and system for defects in the painting line of vehicle parts, in order to solve the technical problems in the prior art where the detection results are difficult to be directly converted into painting execution actions, the causes of defects on complex curved surfaces are overly linearized, and rework control is disconnected from the main line cycle time. This invention enables closed-loop control of defect detection, defect location, cause identification, compensation execution, and effect re-verification on the painting line of vehicle parts.

[0013] To achieve the above objectives, the technical solution provided by the present invention is as follows:

[0014] Establish an event log and collection identifiers, acquire the observation stream, and generate event identifiers based on the collection identifiers and observation streams;

[0015] Collect visual inspection data, conveyor displacement data, spraying process data and cycle time status data from the inspection station of the coating line, and perform time alignment on the collected multi-source data to obtain a unified timestamp data package corresponding to the current part;

[0016] Based on the reference pose of the component's mounting bracket, the conveying displacement correction information, and the mounting bracket posture correction information, the defect pixel clusters in the visual inspection data are mapped to surface points in the mounting bracket coordinate system. The surface points are assigned to pre-divided surface partitions, and the relative coordinates of the defect within the corresponding surface partition are determined.

[0017] For each surface partition, a direct observation state is constructed based on the defect area ratio, grayscale deviation, edge proximity, local curvature category, gun distance deviation, trajectory deviation, spray gun speed deviation, flow rate deviation, and environmental deviation. Based on the direct observation state, the insufficient coverage factor and excessive deposition factor are updated respectively. The partition enhanced state vector and comprehensive defect risk are constructed by combining the partition historical recurrence factor, adjacent partition risk, remaining cycle time, and transmission distance.

[0018] Based on the partition enhancement state vector, local supplementary spraying candidate actions are generated for each surface partition. The local supplementary spraying candidate actions include at least trajectory offset compensation, velocity compensation, flow rate compensation, and dwell time compensation. An executability score is calculated by combining the overspray risk of adjacent partitions and trajectory reachability, and the local supplementary spraying candidate actions are projected into execution actions according to the beat constraint and overspray constraint.

[0019] The execution action is converted into a respraying path segment and spray gun parameter control command for the spraying robot and issued for execution. After respraying, the corresponding surface area is re-inspected. The closed-loop correction result is determined based on the re-inspection result. When there is an abnormality in detection, the trajectory is unreachable, the model output is abnormal, or the cycle time margin is insufficient, the preset degradation strategy is switched.

[0020] Further, the step of mapping defect pixel clusters in the visual inspection data to surface points in the fixture coordinate system and determining the relative coordinates of the defect within the corresponding surface partition includes:

[0021] The surface of the component is divided offline into a preset number of paintable zones, and each paintable zone is bound with a surface segment number, local normal information, and reachable spray gun posture template.

[0022] The defect pixel coordinates are converted into camera normalized rays through camera calibration, and the normalized rays are projected onto the surface template of the part based on the current fixture pose to obtain the surface points in the fixture coordinate system.

[0023] Project the surface point onto the local parameter plane of the candidate surface partition to obtain the relative coordinates within the partition;

[0024] When a surface point satisfies the normal distance condition of the corresponding partition, the candidate surface partition with the smallest normal distance and the smallest local normal angle error is determined as the target surface partition.

[0025] Furthermore, the current position of the hanger is determined by the hanger reference position, the transport displacement correction information, and the hanger attitude correction information.

[0026] Among them, the conveying displacement correction information is obtained from the encoder displacement pulse, and the hanger attitude correction information is obtained from the template matching result of the hanger feature points;

[0027] When the attitude correction information of the hanger exceeds the preset attitude correction range, the current component is marked as an abnormal component and the preset degradation strategy is entered.

[0028] Furthermore, the process of updating the under-coverage factor and the excessive deposition factor based on the directly observed state, and constructing a comprehensive defect risk by combining the partitioned historical recurrence factor and the risk of adjacent partitions, includes:

[0029] The defect area ratio, gray scale deviation, trajectory deviation, gun distance deviation, and spray gun speed deviation of the current cycle are recursively fused with the coverage deficiency factor of the previous cycle to obtain the coverage deficiency factor of the current cycle.

[0030] The excess deposition factor for the current cycle is obtained by recursively fusing the defect area ratio, gray scale deviation, edge proximity, flow rate deviation, and spray gun speed deviation of the current cycle with the excess deposition factor of the previous cycle.

[0031] By performing a bounded mapping of the current period's undercoverage factor, over-deposition factor, historical recurrence factor of the partition, and adjacent partition risk, we obtain the comprehensive defect risk of the current period.

[0032] When there is detection occlusion for a consecutive preset number of decision cycles, only the memory entries of the insufficient coverage factor and the excessive deposition factor are retained, and the upper limit of the subsequent preset action amplitude is reduced.

[0033] Furthermore, the partitioned enhanced state vector includes at least the direct observation state, the insufficient coverage factor, the excessive deposition factor, the comprehensive defect risk, the remaining available time of the current component before the rework insertion station, and the normalized value of the transmission distance from the detection station to the reworkable spraying station.

[0034] The partition history recurrence factor is updated based on the most recent preset number of recurrence defect records of the same type of parts in the corresponding surface partition, and the adjacent partition risk is calculated based on the comprehensive defect risk of the adjacent surface partitions of the target surface partition.

[0035] Further, the step of generating local spraying candidate actions for each surface partition based on the partition enhancement state vector includes:

[0036] Input the enhanced state vector of each surface partition into the action generation model, and output the local spraying candidate actions for the corresponding surface partition;

[0037] The input to the motion generation model is a partitioned enhanced state vector that includes direct observation state, coverage insufficiency factor, excessive deposition factor, comprehensive defect risk, remaining time of cycle time and transmission distance. The output is trajectory offset compensation, velocity compensation, flow compensation and dwell time compensation.

[0038] The training labels for the action generation model are generated by a rule optimizer, which determines the target action based on the joint optimization results corresponding to the remaining risk, the risk of overspraying in adjacent areas, the additional spraying time, and the spraying coverage area.

[0039] Furthermore, the calculation of an executability score by combining the overspray risk of adjacent partitions and trajectory reachability, and the projection of local supplementary spraying candidate actions into executable actions according to the beat constraint and overspray constraint, includes:

[0040] Based on the remaining cycle time of the current component, the risk of overspraying in adjacent zones corresponding to the local respray candidate action, and the reachability score of the robot for the respray trajectory of the target surface zone, the executability score of the target surface zone is calculated.

[0041] When the overall defect risk is not less than the second preset risk threshold and the executability score meets the preset execution conditions, the local respray candidate action is projected into the preset action feasible domain of the target surface partition to obtain the execution action.

[0042] When the overall defect risk is not less than the third preset risk threshold and the executability score does not meet the preset execution conditions, a manual re-inspection instruction is generated.

[0043] When the overall defect risk is not less than the first preset risk threshold and less than the second preset risk threshold, it is recorded as an observation item, and a light trajectory fine-tuning is performed.

[0044] Furthermore, the risk of overspraying in adjacent zones is predicted based on the flow rate compensation, velocity compensation, residence time compensation, boundary distance with adjacent surface zones, local normal angle, current risk of adjacent surface zones, and spray overlap ratio of the target surface zone.

[0045] The trajectory reachability score is determined based on the inverse solution of the spray trajectory, attitude deviation margin, collision safety margin, and joint limit margin.

[0046] When the inverse solution of the spray trajectory fails, the trajectory reachability score is set to a preset lower limit value.

[0047] Further, the process of converting the execution action into a respraying path segment and spray gun parameter control command for the painting robot and issuing it for execution, performing a re-inspection on the corresponding surface area after respraying, and determining the closed-loop correction result based on the re-inspection result includes:

[0048] The reference trajectory segment corresponding to the target surface partition is called, and the execution action is superimposed on the reference trajectory segment to generate a local spraying path;

[0049] When a preset number of surface zones to be sprayed are spatially adjacent and the included angle of the attitude template meets the preset conditions, multiple local spraying paths are merged into a continuous spraying path.

[0050] After the touch-up spraying station, the surface partitions that have undergone touch-up spraying are re-inspected to obtain the risk results after touch-up spraying, and the enhanced state vector of the partition before touch-up spraying, the executed actions, and the risk changes after touch-up spraying are recorded to form a closed-loop sample.

[0051] After accumulating a preset number of valid closed-loop samples, offline incremental training is performed, and the new model is deployed when the new model meets the preset version switching conditions; otherwise, the current stable model version is maintained.

[0052] The present invention also provides a closed-loop control system for defects in the painting line of vehicle parts, including a data acquisition module, a partition mapping module, a risk assessment module, an action generation module, a cycle coordination module, an execution and re-inspection module, and an abnormal degradation module.

[0053] The data acquisition module is used to collect visual inspection data, conveyor displacement data, spraying process data and cycle time status data from the coating line inspection station, and to perform time alignment.

[0054] The partition mapping module is used to map the defect pixel clusters in the visual inspection data into surface points in the hanger coordinate system according to the hanger reference pose, the transmission displacement correction information and the hanger posture correction information, assign the surface points to the pre-divided surface partitions, and determine the relative coordinates of the defect in the corresponding surface partition.

[0055] The risk assessment module is used to construct a direct observation state for each surface partition, update the insufficient coverage factor and excessive deposition factor, and construct a partition enhanced state vector and comprehensive defect risk by combining the partition's historical recurrence factor, adjacent partition risk, remaining time of the cycle, and transmission distance.

[0056] The action generation module is used to generate local spraying candidate actions for each surface partition based on the partition enhancement state vector;

[0057] The beat coordination module is used to calculate the executability score by combining the overspray risk of adjacent partitions and the reachability of the trajectory, and to project local respray candidate actions into execution actions according to the beat constraints and overspray constraints, or to generate cache instructions, observation markers and manual re-inspection instructions;

[0058] The execution and re-inspection module is used to convert the execution action into a re-spraying path segment and spray gun parameter control command for the spraying robot and issue it for execution. After re-spraying, the corresponding surface area is re-inspected and a closed-loop sample is formed.

[0059] The abnormal degradation module is used to switch to a preset degradation strategy when there is visual occlusion, encoder abnormality, unreachable trajectory, abnormal model output, or insufficient cycle margin.

[0060] Compared with the prior art, the present invention has the following beneficial effects:

[0061] First, it achieves a direct closed-loop conversion from detection results to spraying actions. Addressing the problem in existing technologies where detection results remain in the image domain and cannot directly drive the spray gun for respraying, this invention introduces partition-level coordinate mapping, fixture pose correction, and partition-enhanced state vectors to directly convert visual pixel defects into local respraying actions. Furthermore, it outputs trajectory offset compensation, speed compensation, flow rate compensation, and dwell time compensation. Since the pixel domain defect location enters the execution layer after fixture coordinate transformation, partition assignment determination, and local relative coordinate positioning, the link length from defect detection to the generation of executable respraying instructions can be shortened, reducing the manual interpretation steps between the detection and execution domains. In a continuous A / B comparison of 120 bumper paint lines, the average time from detection to issuing the respray register instruction decreased from 2.9±0.5 s in the control scheme to 1.1±0.2 s, and the automatic closed-loop coverage increased from 63%±4% to 86%±3%.

[0062] Second, it reduces the risk of over-compensation and under-compensation on complex curved surfaces. Addressing the problem that existing technologies using single grayscale compensation struggle to represent the deposition causes of complex curved surfaces, this invention updates the insufficient coverage factor and excessive deposition factor separately, and introduces over-spray risk constraints and trajectory reachability scores for adjacent areas before execution. Since different defect causes enter different state quantities, the system can distinguish between thin-spray trends and accumulation trends, and adjust speed, flow rate, trajectory offset, and dwell time separately during the action generation phase, rather than applying the same compensation uniformly to different defects. Therefore, over-compensation or under-compensation caused by incorrect compensation direction can be reduced in corners, transitions, and occluded areas. In the bumper digital twin sample and corresponding actual tests, the residual defect rate decreased from 8.1%±1.0% to 3.9%±0.7% after re-inspection, and the over-spray event rate in adjacent areas decreased from 4.8%±0.8% to 1.9%±0.5%.

[0063] Third, while ensuring quality, the main line cycle time remains stable. Addressing the lack of coordination between rework insertion and main line cycle time in existing technologies, this invention sets up an executability score, a minimum executable window, and an allowable delay limit, and makes consistent scheduling decisions between immediate respraying, delayed buffering, and manual re-inspection. Since cycle time margin, overspray safety, and trajectory reachability jointly determine whether an action is executable, the system will not blindly trigger high-risk respraying when the cycle time window is insufficient, nor will it simply transfer all medium- and high-risk parts to full-part respraying. In a continuous test of 180 door handle clear coat parts, the single-part additional processing time decreased from 4.4±0.7 s to 2.1±0.4 s, the main line cycle time over-limit rate decreased from 10.8%±1.2% to 3.8%±0.9%, and the first-time rework success rate increased from 85%±3% to 92%±2%. Attached Figure Description

[0064] Figure 1 is a schematic diagram of the overall process of the closed-loop control method for defects in the painting line of vehicle parts according to the present invention;

[0065] Figure 2 is a flowchart illustrating the data acquisition and partition status construction unit of the present invention;

[0066] Figure 3 is a flowchart illustrating the local spraying action generation and constraint projection unit of the present invention;

[0067] Figure 4 is a flowchart of the re-verification and model update unit after spraying in this invention;

[0068] Figure 5 is a flowchart illustrating the abnormal degradation and rhythm coordination unit of the present invention. Detailed Implementation

[0069] To make the technical means, creative features, and achieved objectives and effects of this invention easier to understand, the invention is further described below with reference to specific embodiments. However, the following embodiments are only preferred embodiments of this invention and not all embodiments. Other embodiments obtained by those skilled in the art based on the embodiments in the implementation details without creative effort are all within the protection scope of this invention.

[0070] Terminology Definition

[0071] 1. Insufficient Coverage Factor: An empirical estimate that characterizes the risk trend of exposed substrate and thin spray within a zone. It is an intermediate state in risk assessment and is not equivalent to the actual film thickness measurement.

[0072] 2. Excess deposition factor: An empirical estimate that characterizes the risk trend of sagging and accumulation within a zone. It is an intermediate state in risk assessment and is not equivalent to the actual film thickness measurement.

[0073] 3. Partition-enhanced state vector: A multi-dimensional state vector composed of direct observation state, deposition risk state, comprehensive risk, clock speed margin and transmission distance, which serves as the standard input for the action generation model.

[0074] 4. First preset risk threshold: The critical value used to determine when a defect risk enters the warning range; if it is below this value, it is considered to be in the normal range.

[0075] 5. Second preset risk threshold: a critical value used to determine the conditions for forced automatic spraying. Automatic spraying is triggered when the threshold is higher than this value and the execution conditions are met.

[0076] 6. Third preset risk threshold: a critical value used to determine when manual re-inspection is required. If the threshold is higher than this value and automatic execution is not possible, a manual re-inspection instruction will be triggered.

[0077] 7. Preset quantity: A fixed value determined through offline calibration, used to limit the scale of sampling window, statistical period, number of partitions, etc.

[0078] 8. Decision cycle: The complete processing cycle of the system completing one data acquisition, status update, action generation and instruction output.

[0079] Example 1: Overall Flowchart of a Closed-Loop Control Method and System for Defects in a Vehicle Parts Painting Line

[0080] As shown in Figures 1 to 5, the closed-loop control method for defects in a vehicle parts painting line provided in this embodiment includes six collaborative stages: multi-source data acquisition and spatiotemporal alignment, partitioned defect state construction and causal decoupling, local touch-up spraying action generation and constraint projection, post-touch-up verification and online updating, abnormal degradation and safe execution, and closed-loop system operation. The system hardware includes an industrial camera, line encoder, photoelectric trigger, environmental sensor, painting robot controller, spray gun parameter actuator, line PLC, industrial processor, and memory, all installed at the painting line inspection station. The industrial processor reads the method program from the memory, receives data from the vision system, encoder, process equipment, and PLC, completes partition mapping, risk assessment, action generation, cycle time coordination, and re-inspection updates, and then sends control commands to the robot controller and line PLC.

[0081] In this embodiment, the number of surface partitions for the component can be M=24, with each partition corresponding to a fixed surface segment; the resolution of a single detection image can be 2448×2048 pixels; the rated gun distance range can be 180 mm to 260 mm, and the reference gun distance can be d0=220 mm, which is determined based on the target paint type operating instructions and the spray gun deposition calibration results; the spray gun moving speed range can be 280 mm / s to 520 mm / s, and the reference speed can be v0=380 mm / s, which is determined based on the standard trajectory coverage stability test; the paint flow rate range can be 110 mL / min to 190 mL / min, and the reference value can be q0=150 mL / min; the atomization pressure range can be 0.10 MPa to 0.22 MPa, and the reference value can be p0=0.16 MPa. The target humidity for the process is denoted as h0, which is preset by the work instructions for different paint types and colors. In this embodiment, the humidity for the color paint can be h0 = 62% RH, a value obtained from the historical stable production window statistics of this color paint line. The encoder sampling period can be 5 ms, the vision result refresh period can be 200 ms, the closed-loop decision period can be 200 ms, and the minimum executable window for local respray insertion can be [missing information]. =1.2 s, the maximum allowable delay for the main storyline can be taken as 1.2 s. =3.5 s. The above time parameters were obtained based on line cycle simulation and offline calibration of PLC buffer capacity.

[0082] The first preset risk threshold can be taken as follows: The second preset risk threshold can be taken as follows: The third preset risk threshold can be taken as follows: The overspray risk threshold for adjacent areas can be taken as follows: The threshold for this type is determined offline based on historical repair results and overspray event statistics.

[0083] Step S1: Multi-source data acquisition and spatiotemporal alignment

[0084] S101. The industrial processor collects visual images, encoder displacement pulses, fixture IDs, robot execution logs, real-time spray gun parameters, ambient temperature and humidity, and line cycle status from the inspection station. The visual images are used to identify defect locations and shapes; the encoder displacement pulses are used to establish the correspondence between image frames and conveyor chain positions; the robot execution log includes the current program segment number, theoretical trajectory point sequence, and real-time joint positions; and the real-time spray gun parameters include the actual flow rate. Atomization pressure Spray gun speed and high voltage electrostatic value Environmental parameters include temperature. and humidity Cycle time status includes the remaining available time at the current workstation. .

[0085] in, The unit is milliliters per minute, which indicates the actual amount of liquid ejected by the spray gun at that moment. The unit is megapascal (MPa), which represents the current atomization pressure. The unit is millimeters per second, which represents the speed at which the spray gun moves relative to the workpiece surface; This indicates the electrostatic high voltage setting value for the spray gun; Indicates the current ambient temperature; Indicates the current ambient relative humidity; This indicates the available cycle time window before the component can be inserted into the repair station.

[0086] S102. The industrial processor preprocesses the multi-source data. For continuous numerical process data, fixed-scale normalization based on training set statistics is used, without online sliding to change the mean and variance, to avoid model input drift. Fixed dictionary encoding is used for fixture IDs, component models, and color categories. Nearest-neighbor registration combined with linear velocity compensation is used for encoder pulses and image timestamps. Spline resampling is used for robot trajectory logs to unify them with the visual refresh cycle of 200ms. For missing single-point sensor values, forward hold is used; if more than three consecutive cycles are missing, an anomaly flag is written. High-brightness reflection points in the image are first subjected to polarization denoising and local median filtering to reduce the interference of specular reflection on the identification of pinholes or particles. To ensure that the execution link latency is manageable, in this embodiment, the average processing latency of edge nodes for defect extraction of a single frame image is controlled within 55 ms, the average latency of coordinate mapping and state update is controlled within 35 ms, the average latency of motion generation and constraint projection is controlled within 30 ms, and the average latency of communication and register refresh between the industrial processor and the robot controller and PLC is controlled within 40 ms. Thus, the overall link latency from visual result refresh to the issuance of the respray command is controlled to be between 160 ms and 185 ms, which is less than a decision cycle of 200 ms.

[0087] S103. A unified mapping from detection coordinates to spraying execution coordinates is established by the industrial processor. During the offline modeling stage, the component is divided into M surface partitions, each bound to a surface segment number, normal direction, and reachable spray gun posture template. Online, the processor determines the reference pose of the current component based on the fixture ID and encoder position, and then reprojects the visual defect pixel clusters to the corresponding partitions. This uses partition-level mapping, not requiring the online recovery of a complete high-precision 3D point cloud, but rather assigning each defect to a specific surface partition and its relative coordinates (ξ, η) within that partition. Here, ξ represents the normalized lateral position of the defect on the local parameter plane of the target partition, ranging from 0 to 1; η represents the normalized longitudinal position of the defect on the local parameter plane of the target partition, also ranging from 0 to 1. Through this processing, the visual inspection results can be directly incorporated into subsequent local respraying control.

[0088] In this step, the humidity deviation is first calculated based on the ambient humidity, which is used for subsequent state vector construction. This humidity deviation is based on an empirical normalization relation, used to map the allowable humidity ranges of different paint types to a unified processing scale. Its calculation is as follows:

[0089] ,

[0090] in, This represents the humidity normalization bias corresponding to the m-th partition in the k-th decision period; This indicates the actual relative humidity measured by environmental sensors at the current moment; This indicates the target relative humidity corresponding to the current paint type; and These represent the upper and lower limits of the allowable humidity for the current paint type, respectively; the denominator... This indicates the allowable humidity range width, used to scale deviations to a uniform order of magnitude. In this embodiment, the paint line can be taken as... RH RH, these upper and lower limits are obtained statistically from historical stable spraying windows under this paint condition. When the calculated result is greater than 1 or less than -1, it is truncated to the corresponding boundary to avoid excessive amplification of the impact of abnormal humidity values ​​on the model input. This humidity deviation will subsequently be used as an environmental deviation in the directly observed state.

[0091] Subsequently, the current fixture pose is determined jointly by the fixture reference pose, the transport displacement correction information, and the fixture attitude correction information. This relationship is a geometric transformation relationship, used to unify the workpiece attitude at the moment of detection to the fixture coordinate system. Its calculation is as follows:

[0092] ,

[0093] in, This represents the pose transformation matrix of the attachment relative to the world coordinate system during the k-th decision cycle. This represents the reference pose matrix of the hanger, which is the initial pose of the hanger in the standard position during offline calibration. This represents the conveyor displacement correction matrix determined by the encoder displacement pulses, where This indicates the cumulative displacement in the conveying direction corresponding to the current cycle; This represents the fixture attitude micro-sway correction matrix obtained by matching the fixture feature point template. The above three matrices are multiplied in sequence, representing the process of first starting from the reference fixture position, then superimposing the transport displacement change, and finally superimposing the fixture micro-sway and attitude disturbance. In this embodiment, the translation correction is limited to ±6 mm, and the attitude correction angle around the conveying direction and the vertical direction is limited to ±2.5°. This range is set offline based on the matching experiment of the fixture installation tolerance and visual stability. When it exceeds this range, it indicates that the current fixture attitude has exceeded the stable spraying execution range, and the system marks the current component as an abnormal component and proceeds to step S5.

[0094] Next, the image pixel coordinates are back-projected onto the surface points in the fixture coordinate system. This relationship belongs to the camera imaging geometry and coordinate transformation relationship, and is used to recover the three-dimensional surface position from the two-dimensional defect position. Its calculation is as follows:

[0095] ,

[0096] in, This represents the three-dimensional coordinates of the defect point in the fixture coordinate system during the k-th decision cycle, in millimeters. , and These represent the position components of the point along the three coordinate axes of the fixture coordinate system; This represents the inverse matrix of the current mount pose matrix, used to convert world coordinates back to the mount coordinate system; This represents the extrinsic transformation matrix from the camera coordinate system to the world coordinate system; Represents the camera intrinsic parameter matrix. Used to back-project pixel coordinates into camera-normalized rays; and These represent the horizontal and vertical pixel coordinates of the defect center in the image, respectively; column vector This represents the homogeneous coordinates of the pixel. This represents the scale factor determined by the intersection conditions between the ray and the surface template of the component. Its physical meaning is the normalized scale length of the ray along its propagation direction. This scale factor is obtained by ray intersection or nearest-point projection from an offline surface fragment library. If a ray intersects with multiple candidate surface fragments, candidate points with smaller normal distances and smaller local normal angle errors are preferentially retained.

[0097] After obtaining the surface points, they are projected onto the local parameter plane of the candidate partition to obtain the relative coordinates within the partition. This relationship belongs to local geometric projection and is used to convert the three-dimensional surface position into a controllable two-dimensional relative position within the partition. Its calculation is as follows:

[0098] ,

[0099] in, Represents the normalized relative coordinates of the horizontal direction of the local parameter plane of the m-th partition; Represents the normalized relative coordinates of the longitudinal direction of the local parameter plane of the m-th partition; This represents the surface point of the aforementioned defect in the fixture coordinate system; Represents the reference origin of the local parameter plane of the m-th partition; vector This represents the spatial displacement of the defect point relative to the origin of the partition; and These represent the local horizontal and vertical unit basis vectors of the m-th partition, respectively; the symbol " " represents the vector dot product, used to calculate the projection length of the displacement in the corresponding local direction; and These represent the local horizontal and vertical calibration lengths of the m-th partition, respectively. If... and If all values ​​are between 0 and 1, and the normal distance from the point to the surface patch of the partition does not exceed a preset threshold, then the defect is determined to belong to partition m. In this embodiment, the normal distance threshold can be 2.5 mm, which is determined based on the statistical analysis of offline surface modeling error and online visual positioning error. If multiple candidate partitions are satisfied simultaneously, the partition with the smallest normal distance and the smallest local normal angle error is selected.

[0100] Step S2: Construction of Partition Defect States and Decoupling of Causes

[0101] S201. The industrial processor extracts the direct observation state for each partition. The direct observation state of the m-th partition in the k-th decision period is denoted as... The system consists of defect area proportion, average grayscale deviation of defects, edge proximity, local curvature category, current gun distance deviation, trajectory lateral deviation, spray gun speed deviation, flow rate deviation, and environmental deviation. The directly observed state variables are used to characterize the directly measurable local defect morphology and process deviation information in the current cycle, and their dimension is 9. If no defect is detected in a certain partition in the current cycle, the defect area proportion and grayscale deviation are set to zero, but the process deviation variables such as trajectory, gun distance, speed, flow rate, and environment are still retained so that the system can identify the state of "currently having no obvious defects but having a potential instability trend". When a partition is occluded and the image becomes unusable, the visual correlation terms are not set to zero, but inherit the estimated value of the previous cycle and add an occlusion flag. The occlusion flag does not enter the enhanced state vector, but participates in the subsequent limiting and degradation logic as an external anomaly control variable.

[0102] In this step, the lateral trajectory offset is obtained based on the difference between the current spray gun projection center and the theoretical coverage center, retrieved from the robot log. This relationship represents a normalized offset along the local partition direction, characterizing the degree of deviation of the spray gun center from the theoretical coverage position. Its calculation is as follows:

[0103] ,

[0104] in, This represents the normalized value of the lateral offset of the trajectory of the m-th partition in the k-th period; This indicates the actual position of the current spray gun projection center in the local lateral direction of the partition, obtained through robot execution log inversion, in millimeters; This indicates the reference position of the theoretical coverage center of the partition in the same local lateral direction, also in millimeters; This represents the local horizontal calibration length of the m-th partition, used for normalization. If... A positive value indicates that the spray gun center has shifted in a positive local lateral direction relative to the theoretical center; a negative value indicates a shift in the opposite direction. This value is subsequently used as one of the update terms for the insufficient coverage factor to characterize the risk of insufficient local coverage caused by trajectory deviation.

[0105] Grayscale deviation is obtained based on the relative difference between the average grayscale of the current defect area and the grayscale of the standard sample. This relationship belongs to the relative grayscale deviation after color category grouping and calibration, and is used to reflect the trend of thin or thick spraying. Its calculation is as follows:

[0106] ,

[0107] in, This represents the grayscale deviation of the m-th partition in the k-th period; This represents the average grayscale value of the defective area in this partition during the current period. This represents the average grayscale value of a standard sample of the same model, color category c, and shooting lighting conditions in partition m; superscript Indicates the color category index, such as light paint, dark paint, or metallic paint; denominator Used to scale grayscale differences to a relative deviation. When When positive, it indicates that the current defect area is brighter than the standard sample, and under the paint segmentation calibration relationship in this embodiment, it tends to be more inclined towards thin spraying; when A negative value indicates a relatively darker tone, leaning towards a thicker or more layered application. To minimize the impact of differences in paint type, color, and lighting, independent reference grayscale libraries are established for light-colored, dark-colored, and metallic paints, and the corresponding library files are called when changing colors on the production line.

[0108] S202. The deposition risk state that cannot be directly observed is estimated by an industrial processor. To avoid simply compressing defects of different origins into a single gray-scale deviation, this invention sets two estimation states and one risk assessment state for each partition, namely, the inadequate coverage factor. Excess deposition factor and comprehensive defect risk Among them, the insufficient coverage factor is used to characterize risk trends such as exposed substrate and thin spraying, and is a risk estimation factor rather than the actual film thickness; the excessive deposition factor is used to characterize risk trends such as sagging and accumulation, and is also a risk estimation factor; the comprehensive defect risk is used for subsequent control decisions and is not directly equivalent to the finished product quality judgment result. The above state quantities are all derived from direct observation characteristics, historical state memory, and offline calibration coefficients; they are obtained through recursive estimation and bounded mapping; their rationality is verified by manual review of defect labels, re-inspection results, and offline parameter scanning samples.

[0109] The insufficient coverage factor is obtained by recursively fusing the previous cycle's memory term with the current defect area, grayscale deviation, trajectory deviation, gun distance deviation, and velocity deviation. This relationship is a state update relationship after empirical calibration, used to reflect the cumulative evolution of thin spraying and insufficient coverage risks. Its calculation is as follows:

[0110] ,

[0111] in, This represents the coverage deficiency factor of the m-th partition in the k-th period; This represents the coverage deficiency factor of the corresponding partition in the previous period; The memory coefficient, representing the coverage deficiency factor, is used to control the degree to which the state of the previous period is retained in the current period. In this embodiment, it can be taken as... This coefficient was obtained by offline fitting based on the continuity of historical periodic defects; This represents the proportion of the current periodic defect area of ​​the m-th partition to the projected area of ​​that partition; Indicates the grayscale deviation for the current period; This represents the normalized value of the lateral offset of the trajectory; This represents the normalized deviation of the actual gun distance from the reference gun distance; This indicates the normalized deviation of the spray gun speed from the reference speed; to The values ​​represent the calibration weights of the above observations on the inadequate coverage factor, which in this embodiment can be 0.30, 0.18, 0.22, 0.14, and 0.16, respectively. These coefficients are obtained through offline calibration using standard part parameter scanning spraying, manual verification of defect category labels, least squares fitting, and monotonicity constraints. This formula shows that increased defect area, brighter grayscale, increased trajectory deviation, increased gun distance, and faster speed all increase the risk of inadequate coverage. If... If unavailable, initialize to zero; if the update result is less than zero, truncate to zero; when there are three consecutive periods of occlusion, only the memory entry is retained. Furthermore, the upper limit of the action amplitude is reduced in the subsequent action generation stage to avoid overcompensation based on incomplete observations.

[0112] The excess deposition factor is obtained by recursively fusing the previous cycle's memory term with the current defect area, grayscale deviation, edge proximity, flow rate deviation, and velocity deviation. This relationship is also an empirically calibrated state update relationship, used to reflect the cumulative evolution of sagging and accumulation risks. Its calculation is as follows:

[0113] ,

[0114] in, This represents the excess deposition factor of the m-th partition in the k-th period; This indicates the excess deposition factor for the corresponding partition in the previous cycle; The memory coefficient representing the excess deposition factor can be taken as follows in this embodiment: ; to The values ​​represent the calibration weights of the defect area ratio, negative grayscale deviation, edge proximity, flow rate deviation, and negative velocity deviation on the over-deposition factor. In this embodiment, these weights can be 0.22, 0.16, 0.20, 0.24, and 0.18, respectively. This represents the normalized proximity of the defect center to the boundary of the partition; a larger value indicates that it is closer to the edge. Indicates the normalized deviation of the flow rate relative to the reference flow rate; symbol This indicates that, under the current grayscale definition, local grayscale values ​​lower than the standard sample tend to indicate a thicker coating or more concentrated pattern; (symbol) This indicates that a lower velocity makes it easier for deposition to increase per unit area. The formula shows that increased defect area, darker regions, proximity to edges, higher flow rates, and slower velocities all increase the risk of excessive deposition. Its initialization, truncation, and occlusion processing logic is the same as the undercapacity factor.

[0115] The comprehensive defect risk is obtained by a bounded mapping of inadequate coverage factor, excessive deposition factor, regional historical recurrence factor, and adjacent regional risk. This relationship belongs to logistic regression risk mapping, used to compress multi-source risk quantities into a unified 0-1 decision space. Its calculation is as follows:

[0116] ,

[0117] in, This represents the overall defect risk of the m-th partition in the k-th period, with a value ranging from 0 to 1. This represents the Sigmoid bounded mapping function, which compresses the result of a linear combination to a bounded interval; This represents the bias term, which can be -1.20 in this embodiment; , , and These represent the weights of the insufficient coverage factor, excessive deposition factor, partition history recurrence factor, and adjacent partition coupling factor, respectively. In this embodiment, these weights can be 1.05, 0.96, 0.52, and 0.41, respectively. This represents the normalized value of the frequency of recurring defects in the most recently preset number of parts of the same model in this partition; This represents the average risk of the adjacent partitions of this partition. (The above...) The coefficients are obtained through logistic regression training with class weights. Positive samples are partitions that need rework, and negative samples are partitions that can be approved. If the absolute value of the sigmoid input exceeds the preset upper limit, it is truncated according to the corresponding boundary. In this embodiment, the upper limit of the absolute value can be 8, which is set offline based on numerical stability testing.

[0118] S203. An enhanced state vector for each partition is constructed using an industrial processor. For the m-th partition, the enhanced state vector consists of 9 directly observed states, 2 estimated physical states, 1 comprehensive risk state, the current remaining available time, and the normalized transmission distance value, resulting in a total dimension of 14. This enhanced state vector defines the input space of the action generation model, allowing local defect states, process deviations, historical recurrence trends, and cycle time constraints to be jointly represented in the same vector. Specifically, the remaining available time field in the enhanced state vector is updated in real-time by the PLC; the normalized transmission distance value is obtained by normalizing the remaining transport distance of the current component from the detection station to the re-spraying station relative to the calibrated total distance from the detection station to the re-spraying station; if the line is temporarily stopped, the remaining available time does not decrease according to the normal cycle time but is refreshed by the PLC in real-time via a message; if a component does not pass through the re-spraying station, this field is set to zero and directly enters the manual re-inspection judgment. Obstruction flags are stored separately as anomalies and are not included in this 14-dimensional vector, only participating in subsequent action limiting and degradation judgments.

[0119] Step S3: Generation and Constraint Projection of Local Spraying Action

[0120] S301. The industrial processor generates local supplementary spraying candidate actions based on the zoned enhancement state. Each zone's candidate actions include four items: trajectory offset compensation, velocity compensation, flow rate compensation, and residence time compensation. These are used to correct the local execution mode of the spray gun in terms of spatial position, spraying time scale, and deposition volume scale, respectively. Trajectory offset compensation is in millimeters, representing the lateral correction of the spray gun relative to the theoretical trajectory; velocity compensation is in millimeters per second, representing the local deceleration or acceleration of the spray gun; flow rate compensation is in milliliters per minute, representing the adjustment of the spray gun's output volume relative to the baseline value; and residence time compensation is in seconds, representing the additional residence time of the spray gun in the target area.

[0121] In this embodiment, the main execution path employs a risk-driven partition compensation network to generate candidate actions. This network is executed by an industrial processor, with a 14-dimensional augmented state vector as input. The hidden layers are two fully connected layers with dimensions of 32 and 16 respectively, using ReLU activation to learn nonlinear compensation relationships while maintaining online inference speed. The output is a 4-dimensional candidate action. The network's technical inputs include the partition's directly observed state, under-coverage factor, over-deposition factor, comprehensive defect risk, remaining cycle time, and transmission distance. The technical output is a quadruple of local respray actions. Training data sources include historical rework records, offline parameter scan samples, and digital twin spraying simulation samples. Training labels are generated by a rule optimizer, which selects actions with the goal of minimizing residual risk, while satisfying the requirements of no-spraying, trajectory reachability, and cycle time executability. Network training uses the sum of mean squared error loss and out-of-bounds penalty terms to make the network output approximate the rule optimizer's labeled actions and suppress out-of-bounds flow and dwell time. If the model parameters are unavailable, the output is abnormal, or the edge computing power is insufficient, the historical weighted average, linear extrapolation, or the median of the most recent prediction results will be used as the alternative output; if the network output is a non-numerical abnormality, the degradation mechanism in step S5 will be triggered directly, and the process will not enter the execution layer.

[0122] S302. The industrial processor projects the candidate actions based on cycle time and overspray constraints. Since a high risk in a certain zone does not necessarily mean that the action can be executed within the current cycle time, this invention sets an action executability score, which uniformly measures cycle time margin, overspray safety, and trajectory reachability. The executability score is used to determine whether the zone requires immediate respraying, delayed buffering, or manual re-inspection. Its calculation can be performed in the following form:

[0123] ,

[0124] in, This represents the executability score of the m-th partition in the k-th period; This represents the normalized time availability based on the remaining time of the current component cycle time; This indicates the risk of overspray in adjacent partitions corresponding to the candidate action of the target partition; This represents the reachability score of the robot for the zoned spraying trajectory on the target surface; , and These represent the weights of time availability, overspray safety, and trajectory reachability in the executability score, respectively. These three factors can be calibrated offline based on historical rework results and cycle time simulation data, and their weights sum to 1. This formula indicates that the more sufficient the cycle time margin, the lower the overspray risk, and the more reachable the trajectory, the higher the executability score.

[0125] The risk of overspraying in adjacent areas is predicted based on the target area candidate action amplitude, the boundary distance between the target area and adjacent areas, the normal angle, the current adjacent area risk, and the spray overlap ratio. This risk is a logistic regression-based neighborhood side effect estimate, used to describe the possibility of excessive deposition in adjacent areas after executing the current supplementary spraying action. If the adjacent areas are empty, the risk is set to zero. The trajectory reachability score is determined based on the inverse solution of the supplementary spraying trajectory, attitude deviation margin, collision safety margin, and joint limit margin. If the inverse solution of the supplementary spraying trajectory fails, the reachability score is directly set to 0. The attitude deviation margin represents the remaining proportion of the allowable deviation angle of the current supplementary spraying attitude relative to the template attitude; the collision safety margin represents the normalized result of the minimum distance from the spray gun envelope to the non-target area of ​​the component and the fixture relative to the safety threshold; and the joint limit margin represents the normalized result of the minimum remaining angle of the soft limit threshold of each joint of the robot. In this embodiment, the collision safety threshold can be taken as... This threshold is set offline based on the spray gun's shape envelope and the fixture's anti-collision verification.

[0126] Regarding the execution determination of candidate actions, in this embodiment, when And when the executability score meets the execution conditions, the candidate action is projected into the action feasible region of the target partition to obtain the execution action; when And if the executability score does not meet the execution conditions, a manual re-inspection instruction is generated; when At that time, it is recorded as an observation and a light trajectory fine-tuning is performed. The feasible region after motion projection is used to limit lateral offset, velocity compensation, flow rate compensation, and residence time compensation to not exceed the process safety boundary of that zone. In this embodiment, Can be limited to , Can be limited to , Can be limited to , It can be limited to These ranges are obtained offline based on the spray gun's performance limits, film thickness safety window, and overspray tolerance of adjacent zones. Furthermore, the change in equivalent gun distance after respraying can be limited to... The deviations of the spray gun's pitch and yaw angles relative to the partition attitude template can not exceed ±6° and ±8°, respectively. If the target partition is a sharply curved edge partition, the upper limit of the dwell time is tightened to 0.55 s, and this tightening value is set offline based on the edge drip sensitivity test. If all actions after projection are zero and the risk is still higher than the manual re-inspection threshold, automatic release is prohibited, and manual re-inspection is directly initiated. If the action projection causes the expected re-spraying time to be lower than the minimum control resolution by 0.05 s, the dwell compensation is treated as zero.

[0127] S303. The industrial processor converts the executed actions into robot respraying path segments and spray gun parameter instructions. Specifically, the processor calls the offline-established partition template library, overlays the executed actions onto the corresponding baseline trajectory segment of the partition, and generates a local respraying path; at the same time, the flow rate, speed, and dwell time compensation are written into the parameter register of the robot controller. If multiple partitions need respraying at the same time, they are clustered and merged according to risk level and spatial proximity, and a continuous respraying path is generated first to reduce frequent start and stop. In this embodiment, if the distance between the boundary centers of two partitions to be resprayed is less than 35 mm and the included angle of the posture templates is not greater than 12°, they can be merged into a continuous path, and a smooth transition segment of 0.08 s to 0.15 s is used at the partition boundary. The duration of this transition segment is determined offline based on robot kinematic smoothness tests.

[0128] In one optional implementation, the painting robot control command frame includes a command number, a controlled robot number, a generation timestamp, a predicted effective timestamp, a target partition number, a trajectory segment number, a desired posture, a desired speed, a control increment, a task safety level, and an integrity check code. The robot controller determines whether the repainting command is within the allowed execution window based on the generation timestamp and the predicted effective timestamp, and determines whether the repainting command has been truncated, tampered with, or out of order during transmission based on the integrity check code. If it is not within the allowed execution window or the integrity check fails, execution is refused and an abnormal status is reported to the industrial processor, which then proceeds to the degradation logic in step S5.

[0129] S304. In this embodiment, the training labels for the action generation model are generated by a rule optimizer. The search variables of the rule optimizer are four items: trajectory offset, speed compensation, flow compensation, and dwell time compensation. The search range is consistent with the action feasible region, and the search step size can be 2 mm, 10 mm / s, 3 mL / min, and 0.04 s, respectively. This step size is determined based on a trade-off between offline exhaustive search efficiency and process adjustment resolution. Only those items that satisfy the condition that the risk of overspray in adjacent areas is not higher than [the specified value] are retained. The action combination with the expected additional time not exceeding the current remaining available time and the trajectory reachability score not lower than the preset value is taken as the feasible solution set. In this embodiment, the lower limit of the reachability score can be 0.6, which is obtained by offline calibration based on the robot's safe execution margin. The action with the smallest joint objective is selected from the feasible solution set as the labeled action.

[0130] Step S4: Re-spray and then verify and update online.

[0131] S401. An industrial processor sets up a re-inspection camera position after the re-spraying station to re-inspect the areas that have already undergone re-spraying, obtaining a new defect area ratio and a new risk value. If the risk after re-inspection is lower than the warning threshold, the area is considered to have successfully completed closed-loop correction; if it is still higher than the mandatory re-spraying threshold, it is written into the rework database and the historical recurrence factor of the corresponding area is increased. In actual production line deployment, the distance between the re-inspection position and the re-spraying position is set according to the leveling stabilization time of the paint type. In this embodiment, under the condition of colored paint, a conveying distance of 2.8 m to 4.2 m is preferred, corresponding to an observation delay of 4 s to 7 s. This distance is calibrated offline based on the leveling stabilization time test to make the re-inspection results closer to the actual stable appearance state.

[0132] S402. Online sample retraining is generated by an industrial processor. For each partition that has undergone supplementary spraying, a triplet is recorded, consisting of the enhancement state before supplementary spraying, the executed action, and the change in risk after supplementary spraying. The change in risk is defined as the risk before supplementary spraying minus the risk after supplementary spraying; a larger value indicates a more effective closed-loop action. If the re-examined image is unavailable, the sample does not participate in model updates and is only used for execution log tracking; if the change in risk is less than zero, indicating that the risk has actually increased after supplementary spraying, the sample is marked as a failed sample, and its weight is increased in subsequent offline retraining.

[0133] S403. The industrial processor performs model version updates. The system triggers offline incremental training every time a preset number of valid closed-loop samples are accumulated. In this embodiment, the preset number can be 3000 valid closed-loop samples, a value determined by a trade-off between the model's stable update frequency and the production line data accumulation speed; the training set, validation set, and rollback baseline set can be divided in an 8:1:1 ratio; the optimizer uses Adam, and the learning rate can be... The batch size can be 128, and the maximum number of rounds can be 60. Training will stop early if the validation set loss does not decrease for 8 consecutive rounds. These training parameters are determined based on offline convergence experiments. The new version will only be deployed to the production line if the average risk reduction on the validation set increases by more than 3% and the over-spraying event rate is not higher than the old version; otherwise, it will automatically roll back to the previous stable version. Digital twin samples are used to supplement boundary conditions that are difficult to collect frequently. The defect type distribution in the simulation output must be calibrated for consistency with the statistical distribution of the real production line in the most recent month. The deviation of the proportion of major defect categories should not exceed ±8%. This deviation threshold is set offline according to the simulation sample reliability audit rules; otherwise, it will not be included in the training set.

[0134] Step S5: Abnormal Degradation and Safe Execution

[0135] S501. The industrial processor determines whether the following anomalies exist: continuous visual occlusion exceeding limits, encoder pulse loss, unreachable robot trajectory, abnormal model output values, and the remaining time of the current cycle being less than the minimum execution window. Continuous visual occlusion exceeding limits is defined as an occlusion flag of 1 for three consecutive decision cycles in the same partition; encoder pulse loss is defined as the difference between the displacement and the motor speed estimate in two adjacent sampling cycles exceeding 12% for more than two cycles, where the 12% criterion is determined offline based on encoder stability testing; abnormal model output values ​​include non-numerical values, anomalies exceeding twice the feasible action domain, or conflicting spray directions in multiple partitions of the same part. If any of these anomalies exist, a degradation strategy is initiated.

[0136] S502, The degradation strategy is executed by the industrial processor. The degradation strategy is divided into three levels. The first level is a rule fine-tuning mode, which only allows preset small-scale speed compensation to be performed on low-risk partitions. In this embodiment, the compensation upper limit can be taken as... The upper limit is set offline based on conservative correction tests for low-risk parts; the second level is a delay buffer mode, where the PLC issues a buffer delay of no more than 1.5 seconds to transfer the parts to the respray buffer position. The upper limit of this time is determined offline based on the buffer position occupancy simulation and downstream accumulation risk; the third level is a manual re-inspection mode, which codes and diverts high-risk and non-executable parts. The specific triggering condition is: when When the anomaly originates from only a short-term occlusion or a single-point sensor loss, it enters the rule fine-tuning mode; when And when it is expected that the execution conditions can be met after increasing the cache time, enter the delayed cache mode; when If the trajectory reachability score is below 0.3, or if the execution conditions cannot be met even after caching, the system enters manual review mode. The lower limit of the score of 0.3 is determined offline based on the robot's safety margin test. This abnormal degradation mechanism ensures that the system will not output aggressive supplementary spraying actions when the observation is incomplete or the cycle is too tight.

[0137] Step S6: Closed-loop system operation

[0138] S601: The industrial processor controls the order in which the system's engines are called. The system includes a data acquisition interface, a partition mapping engine, a defect risk assessment engine, a respraying action generation engine, a cycle time collaborative scheduling engine, a re-verification and online update engine, and an anomaly degradation engine. These engines can be deployed on the same industrial computer or distributed across edge computing nodes at the inspection station and the central control server of the production line, but all are executed by the processor using the same data closed-loop logic.

[0139] The input-output relationships of each engine in S602 are as follows: The input to the data acquisition interface is industrial camera images, encoder messages, robot logs, real-time parameters of the spray gun, and PLC cycle messages; the output is a unified timestamp data packet. The input to the partition mapping engine is a unified timestamp data packet and an offline surface template library; the output is the partition number and relative coordinates. The inputs to the defect risk assessment engine are the observed features and historical recurrence records, and the outputs are the partitioned enhanced state vector, comprehensive defect risk, and adjacency relation quantity. The inputs to the respraying action generation engine are the partitioned enhanced state vector and the rule optimizer verification results, and the outputs are candidate actions. The inputs to the cycle time collaborative scheduling engine are candidate actions, PLC remaining window, adjacent area overspray risk, and trajectory reachability score, and the outputs are execution actions, cache instructions, or manual re-inspection instructions. The inputs to the re-verification and online update engine are re-inspection images and execution logs, and the outputs are risk change samples and model version decisions. The anomaly degradation engine runs through steps S1 to S5, and performs graded handling of occlusion, pulse loss, unreachability, and insufficient time scenarios. The robot controller receives the respraying path segment and speed, flow, and dwell parameter register values, and the PLC receives cache bit scheduling, cycle time delay, and diversion control instructions, thus forming a complete input, output, and call sequence chain.

[0140] Example 2: Closed-loop control of local defects under the paint line of bumper exterior parts

[0141] This embodiment illustrates the specific application of the present invention in the paint coating line for bumper exterior parts. Bumper exterior parts are typical automotive components with large curvature and obvious edge transitions. Production lines typically use fixed trajectory spraying and uniform parameter spraying. When the hanger is slightly misaligned, the spray gun wears, or the ambient humidity fluctuates, exposed substrate, loss of gloss, or localized paint buildup can easily occur in corner areas, opening edges, and ends. Traditional methods rely on manual visual inspection followed by touch-up painting, which disrupts the production cycle and makes it difficult to establish closed-loop data between defects and compensation actions.

[0142] This embodiment is deployed on a bumper paint production line with a cycle time of 42 s / piece. The inspection station uses two area-array industrial cameras, each with a single acquisition resolution of 2448×2048; the encoder sampling period is 5 ms; and the vision refresh and decision-making periods are both 200 ms. The component surface is pre-divided into 24 zones, with zone #7 corresponding to the right corner area. The baseline painting parameters are... , , , .

[0143] In a certain processing cycle, the industrial processor receives the following raw data for partition #7: the percentage of the projected area of ​​the defect pixel cluster in the detected image is... Grayscale deviation is This indicates that the area is brighter than the standard sample, consistent with the thin-spraying trend; edge proximity Local curvature category The actual gun distance was 236 mm, corresponding to the normalized gun distance deviation. ; Trajectory lateral offset normalized value Speed ​​deviation Flow deviation ; Humidity deviation Current remaining available time Normalized value of transmission distance The coverage factor for this partition in the previous period was [value missing]. The excess deposition factor is Historical relapse factors Average risk of adjacent partitions This partition did not trigger an occlusion exception.

[0144] During the coordinate mapping stage, the pixel coordinates of the defect center, after camera calibration and fixture pose correction, are mapped to a point on the fixture coordinate system surface and determined to fall within the surface patch corresponding to partition #7, thus obtaining the relative coordinates within the partition. The distance from this location to the normal projection of the partition boundary is 6.2 mm, which is less than 15% of the local lateral length of the partition, conforming to the characteristics of thin-spraying at a corner boundary. Subsequently, the processor calculates the coverage insufficiency factor for this cycle based on the state update relationship described in Example 1. Excess deposition factor Then, through comprehensive risk mapping, we obtain Since the value is higher than the first preset risk threshold of 0.35 but lower than the second preset risk threshold of 0.60, the system determines that the partition is in the medium-risk observation zone, but still allows for light local compensation.

[0145] At this point, the 14-dimensional enhanced state vector is input into the compensation network, and the network outputs the following candidate actions: , , , Combined with the overlap ratio of the spray pattern between this zone and adjacent zones. Normalized value of the included normal angle and the average risk of adjacent areas The neighborhood model predicts that the risk of overspraying in adjacent areas is... The robot's inverse kinematics solution success is marked as 1, the attitude deviation margin is 0.90, the collision safety margin is 0.88, and the joint limit margin is 0.90. Based on this, the robot's reachability score is obtained. Then, the feasibility score is calculated by combining the current remaining time in the cycle. Since the score is higher than the execution condition, the system projects the action as the executed action; and all components are within the allowable range, so no further truncation is required. The industrial processor then calls the baseline trajectory segment of partition #7, generates an additional spray path in the right corner area, and sends parameter instructions to the robot controller: lateral outward movement of 5.6 mm, local deceleration of 34 mm / s, flow rate increase of 11 mL / min, and dwell compensation of 0.18 s.

[0146] After being repaired with paint, the part went to the re-inspection station, where the new defect area percentage was obtained. New comprehensive risks Therefore, the risk reduction was 0.294, indicating that the closed-loop correction was successful. The system will write the 14-dimensional state before the re-spray, the 4-dimensional compensation action, and the risk reduction into the closed-loop sample library for subsequent offline incremental training.

[0147] In this embodiment, the 24 partitions are determined jointly by offline CAD surface segmentation and spray gun accessibility analysis. The principle is that the curvature and normal changes within each partition do not exceed preset thresholds to ensure that a unified respray template can be used for the same partition. Specifically, the maximum change in normal within a partition can be controlled within 18°, and the rate of change in local curvature radius can be controlled within 25%. These thresholds are determined offline based on the stability analysis of the spray gun posture template. The coefficients for insufficient coverage and excessive deposition are obtained by jointly fitting 600 parameter scanning simulation samples and 180 manually reviewed samples. The weights in the executability score are obtained by grid searching of historical production data from the past three months to minimize the weighted sum of the cycle time overrun rate and residual defect rate. The compensation network training samples consist of 24,000 partition samples, of which 70% come from digital twin simulation and 30% come from real production line re-inspection and re-feedback. The training hardware uses an edge server with an industrial GPU, and the training time for a single round is approximately 3.2 minutes.

[0148] To address the relationship between grayscale deviation and defect type, reference grayscale libraries were established for light-colored paint, dark-colored paint, and metallic paint for the bumper paint line. For each category, 30 standard samples were selected, and standard grayscale values ​​were obtained under fixed lighting. Then, a segmented calibration table was established by sampling inspection of film thickness and manual visual verification, which states that "brighter colors correspond to thin spraying tendency, and darker colors correspond to thick spraying tendency." Only the partitions that meet the consistency requirements were included in the risk model of this invention.

[0149] Simulation results show that, in 5000 digital twin samples of bumpers, compared with the control scheme of "uniform parameter spraying + manual visual inspection and touch-up," the residual defect rate decreased from 7.8% to 3.2%, the overspray event rate between adjacent zones decreased from 4.5% to 1.6%, the average additional rework time per piece decreased from 2.7 seconds to 1.4 seconds, and the automatic closed-loop processing coverage reached 88.6%. To supplement the real production line support, 120 consecutive mass-produced bumpers from the same production line were selected for A / B comparison. Group A (60 pieces) used the existing manual inspection and touch-up process, while Group B (60 pieces) used the scheme of this invention. The statistical window covered a continuous 4-hour daytime shift, with environmental humidity fluctuating from 60% RH to 66% RH. The results show that the residual defect rate after re-inspection of the scheme of this invention decreased from... Down to The overspray incident rate was... Down to The average additional time for a single item to be repaired is from Down to Subsequently, the processor continues to execute the follow-up steps described in Example 1, such as re-injection of re-examination samples, updating of historical relapse factors, model version verification, and monitoring of abnormal degradation.

[0150] Example 3: Closed-loop control of rhythmic coordination defects under the door handle trim coating line

[0151] This embodiment illustrates the application of the present invention in a high-cycle, small-sized parts scenario. Door handle trim pieces are small in size, but numerous, with tight cycle times and frequent color changes. Traditional production lines often resort to repainting the entire piece or manual removal for re-inspection when a local defect is discovered, resulting in high additional processing time per piece and easily disrupting the main production line's cycle time window during continuous batch production. Therefore, this embodiment focuses on the application of cycle time coordination and delay buffering strategies in the present invention.

[0152] In this embodiment, the production line cycle time is 18 seconds per piece. The distance between the respraying station and the inspection station is short, making cycle time coordination more critical than simple quality compensation. The system still uses a 24-zone model, but only 12 effective zones are activated for small-sized parts. The parameter reference still uses the unified parameter dictionary from Embodiment 1. In a certain processing cycle, zone #3 detected a localized loss of gloss defect, and its data is as follows: , , , , , , , , Previous cycle , Historical relapse factors Average risk of adjacent partitions The remaining available time is only .

[0153] According to the state update relationship described in Embodiment 1, the processor obtains... , Comprehensive risks This value has exceeded the second preset risk threshold, but due to time constraints, the system continues to calculate executability. Assume there is a risk of overspray in the neighborhood. Robot accessibility score Then an executability score is obtained. The value is below the execution limit of 0.55. At this point, the system will not blindly and immediately re-spray, but will instead enter a cycle-based collaborative decision-making process. Since this risk has not yet exceeded the third preset risk threshold of 0.82, the system triggers a delay buffer mode. The PLC requests a 1.2-second buffer delay to transfer the part to the re-spray buffer position, instead of directly re-spraying the entire part. This 1.2-second delay is selected online based on the current buffer position occupancy, downstream workstation capacity, and PLC scheduling simulation results, and does not exceed the 1.5-second buffer limit given in Example 1.

[0154] After caching and re-evaluation, the new availability time has increased to 2.1 seconds. The candidate actions are output via the network as follows: , , , Recalculated The conditions for execution were met, therefore the robot performed the localized touch-up spraying. The re-inspection results showed... The risk reduction was 0.394, indicating a successful closed loop.

[0155] In this embodiment, because door handle parts have shorter cycle times and the remaining available time is more sensitive to decision-making, the cycle time margin item in the executability score remains consistent with that in Embodiment 1, but the delayed caching mode is activated first during deployment. The maximum allowable caching time for the caching bit is set to 1.5 s, which is derived from the PLC cycle time simulation results. Exceeding this time will significantly increase the risk of downstream accumulation. For small-sized parts, the partition template consists of 12 effective surface segments, but is still mapped to a unified 24-partition numbering system for system software reuse. The effective partitions for door handle trims are mainly the opening edge, the upper surface of the handle, the turning edge, and the end. The allowable attitude deviation of the local template can be tightened to pitch ±4° and yaw ±6° to accommodate the higher overlap sensitivity of small-sized parts. This deviation threshold is set offline based on the attitude tolerance test of the small part clear coat line.

[0156] Simulation results show that, in 8000 digital twin samples of door handle trim pieces, compared to the control scheme of "repainting the entire piece upon discovering a defect," this invention reduces the single-piece additional processing time from 4.6 seconds to 1.9 seconds, the main line cycle time over-limit rate from 11.3% to 3.4%, and the first-time repair success rate from 84.1% to 93.5%. To supplement the support of the real production line, 180 consecutive mass-produced parts of the same type of door handle clear varnish line were selected for comparison, with 90 pieces from this invention scheme and 90 pieces from the control scheme, and the statistical window covering two color switching cycles. The results show that the single-piece additional processing time is reduced from... Down to The main storyline beat rate exceeded the limit. Down to The success rate of a single repair was increased from Upgraded to When the cycle time margin is less than 1.2 s, the delayed buffer mode is more conducive to maintaining the continuity of the main line than the whole part repainting, and the risk reduction trend after re-inspection is consistent with the simulation results. Subsequently, the processor continues to execute the subsequent steps described in Example 1, such as post-buffered action projection, re-inspection closed loop, model sample re-feedback, and abnormal degradation monitoring.

[0157] Example 4: System Implementation

[0158] This embodiment illustrates the functional components of a closed-loop control system for defects in a vehicle parts painting line. The system includes a data acquisition module, a partition mapping module, a risk assessment module, an action generation module, a cycle time coordination module, an execution and re-inspection module, and an anomaly degradation module.

[0159] The data acquisition module is used to collect visual inspection data, conveyor displacement data, spraying process data and cycle time status data from the inspection station of the coating line, and to perform time alignment and output a unified timestamp data packet.

[0160] The partition mapping module is used to map the defect pixel clusters in the visual inspection data into surface points in the fixture coordinate system according to the fixture reference pose, the transmission displacement correction information and the fixture posture correction information, assign the surface points to the pre-divided surface partitions, and determine the relative coordinates of the defect in the corresponding surface partition.

[0161] The risk assessment module is used to construct a direct observation state for each surface partition, update the insufficient coverage factor and excessive deposition factor, and construct a partition enhanced state vector and comprehensive defect risk by combining the partition's historical recurrence factor, adjacent partition risk, remaining time of the cycle, and transmission distance.

[0162] The action generation module is used to generate local spraying candidate actions for each surface partition based on the partition enhancement state vector.

[0163] The beat coordination module is used to calculate the executability score by combining the overspray risk of adjacent partitions and the reachability of the trajectory, and to project local respray candidate actions into execution actions according to the beat constraints and overspray constraints, or to generate cache instructions, observation markers and manual re-inspection instructions.

[0164] The execution and re-inspection module is used to convert the execution action into a re-spraying path segment and spray gun parameter control command for the spraying robot and issue it for execution. After re-spraying, the corresponding surface area is re-inspected and a closed-loop sample is formed.

[0165] The abnormal degradation module is used to switch to a preset degradation strategy when there is visual occlusion, encoder abnormality, unreachable trajectory, abnormal model output, or insufficient cycle margin.

[0166] The modules described above interact with each other via unified timestamp data packets, partitioned state vectors, candidate actions, and re-inspection samples. They can be deployed on the same industrial processor or separately on edge nodes of the inspection station and the central control server, communicating via industrial Ethernet or fieldbus. The functional boundaries of each module correspond to the method steps in Embodiment 1, therefore, those skilled in the art can implement the corresponding system accordingly.

[0167] Core Symbolic Variable Description Table

[0168] The core symbolic variables involved in this invention are described in detail in the table below.

[0169]

[0170]

[0171]

[0172] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications and substitutions should be covered within the scope of the claims of the present invention. Relational terms such as "first" and "second" are only used to distinguish different objects or steps and do not indicate an actual order or primary and secondary relationship; terms such as "comprising" and "including" are open-ended limitations and do not exclude other elements not explicitly listed.

Claims

1. A closed-loop control method for defects in a vehicle parts painting line, applied to online defect detection and rework control in an automotive parts painting production line, comprising the steps of collecting multi-source production data from the painting line, performing defect location assessment, and executing rework, characterized in that... Includes the following steps: Collect visual inspection data, conveyor displacement data, spraying process data and cycle time status data from the inspection station of the coating line, and perform time alignment on the collected multi-source data to obtain a unified timestamp data package corresponding to the current part; Based on the reference pose of the component's mounting bracket, the conveying displacement correction information, and the mounting bracket posture correction information, the defect pixel clusters in the visual inspection data are mapped to surface points in the mounting bracket coordinate system. The surface points are assigned to pre-divided surface partitions, and the relative coordinates of the defect within the corresponding surface partition are determined. For each surface partition, a direct observation state is constructed based on the defect area ratio, grayscale deviation, edge proximity, local curvature category, gun distance deviation, trajectory deviation, spray gun speed deviation, flow rate deviation, and environmental deviation. Based on the direct observation state, the insufficient coverage factor and excessive deposition factor are updated respectively. The partition enhanced state vector and comprehensive defect risk are constructed by combining the partition historical recurrence factor, adjacent partition risk, remaining cycle time, and transmission distance. Based on the partitioned enhanced state vector, local spraying candidate actions are generated for each surface partition. The local spraying candidate actions include at least trajectory offset compensation, velocity compensation, flow rate compensation, and dwell time compensation. The feasibility score is calculated by combining the overspray risk of adjacent zones and the reachability of the trajectory, and the local supplementary spraying candidate actions are projected into execution actions according to the beat constraint and overspray constraint; The execution action is converted into a respraying path segment and spray gun parameter control command for the spraying robot and issued for execution. After respraying, the corresponding surface area is re-inspected. The closed-loop correction result is determined based on the re-inspection result. When there is an abnormality in detection, the trajectory is unreachable, the model output is abnormal, or the cycle time margin is insufficient, the preset degradation strategy is switched.

2. The closed-loop control method for defects in the painting line of vehicle parts according to claim 1, characterized in that, The step of mapping defect pixel clusters in visual inspection data to surface points in the fixture coordinate system and determining the relative coordinates of the defect within the corresponding surface partition includes: The surface of the component is divided offline into a preset number of paintable zones, and each paintable zone is bound with a surface segment number, local normal information, and reachable spray gun posture template. The defect pixel coordinates are converted into camera normalized rays through camera calibration, and the normalized rays are projected onto the surface template of the part based on the current fixture pose to obtain the surface points in the fixture coordinate system. Project the surface point onto the local parameter plane of the candidate surface partition to obtain the relative coordinates within the partition; When a surface point satisfies the normal distance condition of the corresponding partition, the candidate surface partition with the smallest normal distance and the smallest local normal angle error is determined as the target surface partition.

3. The closed-loop control method for defects in the painting line of vehicle parts according to claim 2, characterized in that, The current position of the mounting device is determined by the mounting device reference position, the transmission displacement correction information, and the mounting device attitude correction information. Among them, the conveying displacement correction information is obtained from the encoder displacement pulse, and the hanger attitude correction information is obtained from the template matching result of the hanger feature points; When the attitude correction information of the hanger exceeds the preset attitude correction range, the current component is marked as an abnormal component and the preset degradation strategy is entered.

4. The closed-loop control method for defects in the painting line of vehicle parts according to claim 1, characterized in that, The process involves updating the under-coverage factor and the excessive deposition factor based on the directly observed state, and constructing a comprehensive defect risk by combining the partition's historical recurrence factor and the risk of adjacent partitions, including: The defect area ratio, gray scale deviation, trajectory deviation, gun distance deviation, and spray gun speed deviation of the current cycle are recursively fused with the coverage deficiency factor of the previous cycle to obtain the coverage deficiency factor of the current cycle. The excess deposition factor for the current cycle is obtained by recursively fusing the defect area ratio, gray scale deviation, edge proximity, flow rate deviation, and spray gun speed deviation of the current cycle with the excess deposition factor of the previous cycle. By performing a bounded mapping of the current period's undercoverage factor, over-deposition factor, historical recurrence factor of the partition, and adjacent partition risk, we obtain the comprehensive defect risk of the current period. When there is detection occlusion for a consecutive preset number of decision cycles, only the memory entries of the insufficient coverage factor and the excessive deposition factor are retained, and the upper limit of the subsequent preset action amplitude is reduced.

5. The closed-loop control method for defects in the painting line of vehicle parts according to claim 4, characterized in that, The partitioned enhanced state vector includes at least the direct observation state, the insufficient coverage factor, the excessive deposition factor, the comprehensive defect risk, the remaining available time of the current component before the rework insertion station, and the normalized value of the transmission distance from the detection station to the reworkable spraying station. The partition history recurrence factor is updated based on the most recent preset number of recurrence defect records of the same type of parts in the corresponding surface partition, and the adjacent partition risk is calculated based on the comprehensive defect risk of the adjacent surface partitions of the target surface partition.

6. The closed-loop control method for defects in the painting line of vehicle parts according to claim 1, characterized in that, The step of generating local spraying candidate actions for each surface partition based on the partition enhancement state vector includes: Input the enhanced state vector of each surface partition into the action generation model, and output the local spraying candidate actions for the corresponding surface partition; The input to the motion generation model is a partitioned enhanced state vector that includes direct observation state, coverage insufficiency factor, excessive deposition factor, comprehensive defect risk, remaining time of cycle time and transmission distance. The output is trajectory offset compensation, velocity compensation, flow compensation and dwell time compensation. The training labels for the action generation model are generated by a rule optimizer, which determines the target action based on the joint optimization results corresponding to the remaining risk, the risk of overspraying in adjacent areas, the additional spraying time, and the spraying coverage area.

7. The closed-loop control method for defects in the painting line of vehicle parts according to claim 1, characterized in that, The calculation of an executability score by combining the overspray risk of adjacent zones and trajectory reachability, and the projection of local supplementary spraying candidate actions into executable actions according to the beat constraint and overspray constraint, includes: Based on the remaining cycle time of the current component, the risk of overspraying in adjacent zones corresponding to the local respray candidate action, and the reachability score of the robot for the respray trajectory of the target surface zone, the executability score of the target surface zone is calculated. When the overall defect risk is not less than the second preset risk threshold and the executability score meets the preset execution conditions, the local respray candidate action is projected into the preset action feasible domain of the target surface partition to obtain the execution action. When the overall defect risk is not less than the third preset risk threshold and the executability score does not meet the preset execution conditions, a manual re-inspection instruction is generated. When the overall defect risk is not less than the first preset risk threshold and less than the second preset risk threshold, it is recorded as an observation item, and a light trajectory fine-tuning is performed.

8. The closed-loop control method for defects in the painting line of vehicle parts according to claim 7, characterized in that, The risk of overspraying in adjacent zones is predicted based on the flow rate compensation, velocity compensation, residence time compensation, boundary distance with adjacent surface zones, local normal angle, current risk of adjacent surface zones, and spray overlap ratio of the target surface zone. The trajectory reachability score is determined based on the inverse solution of the spray trajectory, attitude deviation margin, collision safety margin, and joint limit margin. When the inverse solution of the spray trajectory fails, the trajectory reachability score is set to a preset lower limit value.

9. The closed-loop control method for defects in the painting line of vehicle parts according to claim 1, characterized in that, The process involves converting the execution action into a respraying path segment and spray gun parameter control commands for the spraying robot and issuing them for execution. After respraying, a re-inspection is performed on the corresponding surface area, and the closed-loop correction result is determined based on the re-inspection results, including: The reference trajectory segment corresponding to the target surface partition is called, and the execution action is superimposed on the reference trajectory segment to generate a local spraying path; When a preset number of surface zones to be sprayed are spatially adjacent and the included angle of the attitude template meets the preset conditions, multiple local spraying paths are merged into a continuous spraying path. After the touch-up spraying station, the surface partitions that have undergone touch-up spraying are re-inspected to obtain the risk results after touch-up spraying, and the enhanced state vector of the partition before touch-up spraying, the executed actions, and the risk changes after touch-up spraying are recorded to form a closed-loop sample. After accumulating a preset number of valid closed-loop samples, offline incremental training is performed, and the new model is deployed when the new model meets the preset version switching conditions; otherwise, the current stable model version is maintained.

10. A closed-loop control system for defects in a vehicle parts painting line, applied to online defect detection and rework control in an automotive parts painting production line, comprising a data acquisition unit, a defect processing unit, and an execution control unit, characterized in that, include: The data acquisition module is used to collect visual inspection data, conveyor displacement data, spraying process data, and cycle time status data from the inspection station of the coating line, and to perform time alignment. The partition mapping module is used to map the defect pixel clusters in the visual inspection data into surface points in the fixture coordinate system according to the fixture reference pose, the transport displacement correction information and the fixture posture correction information, assign the surface points to the pre-divided surface partitions, and determine the relative coordinates of the defect in the corresponding surface partition. The risk assessment module is used to construct the direct observation state for each surface partition, update the insufficient coverage factor and excessive deposition factor, and construct the partition enhanced state vector and comprehensive defect risk by combining the partition's historical recurrence factor, adjacent partition risk, remaining time of the cycle, and transmission distance. An action generation module is used to generate local spraying candidate actions for each surface partition based on the partition enhancement state vector; The beat coordination module is used to calculate the executability score by combining the overspray risk of adjacent zones and the reachability of the trajectory, and to project local respray candidate actions into execution actions according to the beat constraints and overspray constraints, or generate cache instructions, observation tags and manual re-inspection instructions; The execution and re-inspection module is used to convert the execution action into a re-spraying path segment and spray gun parameter control command for the spraying robot and issue it for execution. After re-spraying, the corresponding surface area is re-inspected and a closed-loop sample is formed. The abnormal degradation module is used to switch to a preset degradation strategy when there is visual occlusion, encoder abnormality, unreachable trajectory, abnormal model output, or insufficient cycle margin.

Citation Information

Patent Citations

  • A real-time monitoring and feedback control system for electrostatic powder coating

    CN120821230B

  • Encoder trigger intelligent detection method and system for automobile painting line

    CN121164299B

  • Spunlace non-woven fabric microcapsule uniform spraying system based on machine vision feedback

    CN122032784A