A Method for Identifying and Repainting Damaged Areas of Rivets on Iron Caps Based on Multi-State Image Difference Reconstruction

By using a multi-state image difference reconstruction method, the problems of inaccurate damage identification and unreasonable recoating in the detection of rivet areas of iron caps were solved, achieving efficient and accurate damage area identification and recoating control, thereby improving production efficiency and coating utilization.

CN123071606APending Publication Date: 2026-11-10NANTONG INST OF TECH +1
View PDF 0 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

In machine vision inspection of existing iron cap rivet areas, the normal surface reflection response and the protective coating damage response are easily confused due to the reflection of the rivet curved surface, the obstruction of the pull ring, and the influence of the fixed structure edge. This results in insufficient accuracy in identifying damaged areas, and it is difficult to balance the complete coverage of damage and the reduction of redundant recoating when fixing the recoating position and range.

Method used

By acquiring multi-state images of the rivet area of ​​the iron cover under multiple different imaging states, a local coordinate domain of the rivet is established. Using a mask formed by the geometric boundary of the rivet and a preset stable structure, normal surface reflection and damage response are distinguished, and the damaged area and recoating parameters are adaptively determined. The recoating position and amount are optimized by combining the preset spraying coverage response.

Benefits of technology

It improves the accuracy of damaged area identification and the reliability of recoating, reduces redundant coating coverage, enhances the consistency and adaptability of recoating control, and reduces the occurrence of misidentification and redundant recoating.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123071606A_ABST
    Figure CN123071606A_ABST
Patent Text Reader

Abstract

This invention discloses a method for identifying and adaptively recoating damaged areas of rivets on iron caps based on multi-state image difference reconstruction. The method includes: acquiring multi-state images of the rivet area under different imaging states; establishing a local coordinate domain for the rivet and performing registration mapping; establishing a normal multi-state reference response based on a reference position in the same or adjacent radial interval as the detection location; constructing a damage response field based on the difference between the actual multi-state response and the normal multi-state reference response; using a structural mask formed by a preset stable structure to suppress interference responses and reconstruct the damaged area; determining the recoating extension distance based on the identification uncertainty of the damage boundary; performing non-equidistant extension of the damaged area to obtain the target recoating area; and determining the recoating position and amount based on the spray coverage response and performing the recoating. This invention can improve the accuracy and adaptability of rivet protective coating damage identification and recoating.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent control technology, and in particular to a method for identifying and repainting damaged areas of rivets on iron covers using multi-state image difference reconstruction. Background Technology

[0002] Metal lids are widely used in the metal packaging of food, beverages, and other products. Some of these lids feature a pull ring structure secured by rivets. During the rivet forming and pull ring assembly process, the rivet area is subjected to stamping, stretching, and localized compression. This can cause scratches, cracks, peeling, or partial detachment of the original protective coating, exposing the metal substrate. To reduce the risk of corrosion in the exposed areas, it is usually necessary to recoat the rivets and surrounding areas where coating damage may exist.

[0003] As the production speed of metal caps increases, machine vision can be used to inspect the rivet area and control the recoating device to perform automatic recoating based on the inspection results. This can reduce the efficiency and consistency problems caused by manual inspection and recoating. However, the rivet area of ​​metal caps is characterized by its small size, significant changes in surface curvature, and high metal reflectivity. Furthermore, there may be fixed structures around the rivets, such as pull ring edges, stamped structure edges, and pre-formed lines. When light shines on the curved surface of the rivets, it easily forms highly directional bright and dark areas. Slight changes in the lighting direction, workpiece posture, or surface condition can alter the position and brightness of these bright areas. Therefore, when damage identification is performed based solely on grayscale, gradient, or edge features under a single imaging state, the image response generated by normal surface reflection, pull ring occlusion, and structural edges can easily be confused with the actual damage response of the protective coating.

[0004] To improve recognition reliability, multiple images of the same rivet area can be acquired under different lighting conditions, and the differences between the images can be used to assist in judging surface anomalies. However, rivets themselves are highly reflective structures with obvious three-dimensional curved surfaces. Even if the surface protective coating is completely normal, the same location may exhibit significant differences in image response under different lighting directions or incident angles. Directly performing grayscale difference, threshold segmentation, or feature fusion on multiple images still makes it difficult to distinguish between cross-state reflection changes caused by the normal geometry of the rivet and abnormal responses caused by coating damage.

[0005] On the other hand, the surface color, coating condition, and overall reflectivity of different batches of iron caps may vary, and the lighting and image acquisition devices may also experience changes in light intensity or imaging state during long-term operation. Using a pre-established fixed standard image or a fixed grayscale threshold as a normal surface reference is easily affected by batch differences and changes in equipment condition. Especially on the curved surface of rivets, different radial positions have different normal reflection patterns due to varying surface inclination angles, making it difficult to accurately describe the normal image response of the entire rivet area using a unified fixed reference value.

[0006] Furthermore, existing automated touch-up processes typically determine the touch-up location based on the nominal position of the rivet or the detected defect location, and spray using a preset range or preset touch-up amount. However, actual coating damage may manifest as localized point-like scratches, elongated scratches, arc-shaped damage, or multiple separated damage areas, and the reliability of boundary identification for different damage areas may also vary. When using a fixed range for touch-up, a large touch-up allowance is often required to ensure complete coverage, which can easily increase ineffective coating coverage and paint consumption; if the touch-up range is set too small, it can easily lead to missed coating when there is some uncertainty in the identification of damage boundaries.

[0007] Therefore, there is a need for a method that can distinguish between normal surface reflection of rivets and damage to protective coatings by utilizing the response relationship between different imaging states, and further adaptively determine the actual recoating area and recoating parameters based on the reliability of the identified damage area and its boundaries. Summary of the Invention

[0008] The purpose of this invention is to provide a method for identifying and recoating damaged areas of rivets on iron caps based on multi-state image difference reconstruction. This method addresses the problems in existing machine vision inspection of rivet areas on iron caps, where the normal surface reflection response and the protective coating damage response are easily confused due to the influence of rivet surface reflection, pull ring occlusion, and fixed structure edges, leading to insufficient accuracy in identifying damaged areas. It also addresses the difficulty in achieving both complete damage coverage and reducing redundant recoating when using fixed recoating positions and ranges.

[0009] To achieve the above objectives, the present invention adopts the following technical solution:

[0010] A method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction includes the following steps:

[0011] S1, acquire multi-state images of the rivet area of ​​the iron cover to be detected under at least two different imaging states; wherein, the relative position of the iron cover to be detected and the image acquisition device remains unchanged under different imaging states, and at least one of the illumination direction, illumination incident angle and polarization state is different between the different imaging states.

[0012] Further, in step S1, the iron cover to be detected is positioned in the image acquisition area, and the relative position between the iron cover to be detected and the image acquisition device remains unchanged; under the condition that the relative position remains unchanged, the illumination device is controlled to switch at least one paraxial illumination state and at least two oblique incidence illumination states with different incident orientations in a preset sequence, and images of the rivet area are acquired in each imaging state; the images acquired in different imaging states are associated according to the imaging state corresponding to the acquisition time to obtain the multi-state image, so that the same rivet surface position has a spatially corresponding image response in different imaging states.

[0013] S2, determine the rivet center and reference direction based on the rivet geometric boundary in the multi-state image described in S1, establish the rivet local coordinate domain, and register and map the multi-state image described in S1 to the rivet local coordinate domain to obtain the corresponding local image responses under different imaging states.

[0014] Further, in step S2, the geometric boundary of the rivet is extracted from at least one image in the multi-state images described in S1. The rivet center O and the feature radius R representing the rivet size are determined based on the rivet geometric boundary, and the reference direction is determined based on the preset stable structure on the iron cover. Taking the rivet center O as the origin of the coordinate system, each position within the rivet area is converted into a local position represented by normalized radial coordinate ρ and circumferential angular coordinate θ. The normalized radial coordinate ρ is determined based on the distance from the corresponding position to the rivet center O and the feature radius R, and the circumferential angular coordinate θ is determined based on the circumferential angle of the corresponding position relative to the reference direction. Based on the rivet center O, the feature radius R, and the reference direction, the multi-state images under different imaging states are normalized and spatially registered to map the multi-state images to a unified rivet local coordinate domain.

[0015] S3, for the position to be detected in the local coordinate domain of the rivet described in S2, a reference position is selected from multiple circumferential positions that are in the same or adjacent radial interval as the position to be detected, and a normal multi-state reference response corresponding to the position to be detected is established based on the local image response of the reference position under different imaging states; wherein, the reference position does not include the occluded position and the position corresponding to the preset stable structure.

[0016] Further, in step S3, for the detection position located at the target radial position in the local coordinate domain of the rivet, multiple candidate reference positions distributed at different circumferential positions are selected within a preset radial interval including the target radial position; based on the pull ring position, rivet structure edge position, and preset engraving line position in the local coordinate domain of the rivet, candidate reference positions located in the pull ring occlusion area and the corresponding area of ​​the preset stable structure are excluded from the candidate reference positions, and outlier positions of multi-state response are excluded based on the local image response of each candidate reference position under different imaging states to obtain effective reference positions; based on the local image response of the effective reference positions under each imaging state, normal response benchmarks for each imaging state corresponding to the target radial position are determined, and the normal response benchmarks for each imaging state are combined according to the corresponding imaging state to obtain the normal multi-state reference response.

[0017] S4, obtain the actual multi-state response of the position to be detected under different imaging states as described in S2, compare the actual multi-state response with the normal multi-state reference response as described in S3, determine the damage response value of the position to be detected based on the difference in state amplitude and the difference in cross-state change relationship between the two, and construct a damage response field based on the damage response values ​​of each position to be detected in the local coordinate domain of the rivet.

[0018] Further, in step S4, the state amplitude anomaly is determined based on the difference between the actual image response of the position to be detected in each imaging state and the normal response benchmark of the corresponding imaging state in the normal multi-state reference response; the cross-state change anomaly is determined based on the difference between the actual response change of the position to be detected in at least two imaging states and the normal response change of the normal multi-state reference response in the corresponding imaging states; the spatial continuity anomaly is determined based on the difference between the actual multi-state response spatial change relationship between the position to be detected and its neighboring positions and the corresponding normal multi-state response spatial change relationship; the state amplitude anomaly, the cross-state change anomaly, and the spatial continuity anomaly are fused to obtain the damage response value of the position to be detected, and a damage response field is constructed based on the damage response values ​​corresponding to each position to be detected in the local coordinate domain of the rivet.

[0019] S5. Establish a structural mask based on the preset stable structure in the rivet area. Use the structural mask to suppress the damage response caused by the preset stable structure in the damage response field described in S4. Reconstruct the region based on the spatial continuity of the remaining damage response in the local coordinate domain of the rivet to obtain the damage region characterizing the damage location and damage range of the surface protective coating of the rivet area.

[0020] Further, in step S5, the positions of one or more preset stable structures among the rivet outer peripheral structural edge, pull ring structural edge, and pre-made engraving lines on the iron cap are determined according to the local coordinate domain of the rivet, and a structural mask is established according to the positions of the preset stable structures; the structural mask is spatially mapped to the damage response field, and the damage response corresponding to the positions located within the structural mask or at a distance less than a preset distance from the structural mask is suppressed to obtain a damage response field after structural response suppression; connectivity analysis is performed on the adjacency relationship of each position in the radial and circumferential directions in the damage response field after structural response suppression, and the positions whose damage response values ​​meet the preset damage judgment conditions and are spatially continuous are merged to obtain candidate damage regions; discrete abnormal regions are excluded according to one or more of the area, length, width, and continuous length of the candidate damage regions to obtain the damage region.

[0021] S6. Determine the damage boundary based on the spatial distribution characteristics of the damaged area described in S5, and determine the recoating extension distance at the corresponding boundary position based on the identification uncertainty corresponding to the damage boundary. Extend the damaged area described in S5 according to the recoating extension distance to obtain a target recoating area that includes the damaged area and the corresponding protection margin area.

[0022] Further, in step S6, the damage boundary is determined based on the spatial distribution relationship between the damaged area and the non-damaged area. For each boundary position on the damage boundary, the identification uncertainty is determined based on at least two of the following: the difference between the damage response value at the corresponding boundary position and the preset damage judgment condition, the consistency of damage judgment at the corresponding boundary position under different imaging states, and the gradient of damage response change in the neighborhood of the corresponding boundary position. The corresponding recoating extension distance is determined based on the identification uncertainty of each boundary position, and the recoating extension distance increases as the identification uncertainty of the corresponding boundary position increases. Based on the recoating extension distance corresponding to each boundary position, the damaged area is extended non-equidistantly along different boundary positions, and the protection margin area formed by the extension is merged with the damaged area to obtain the target recoating area.

[0023] S7. Based on the target recoating area described in S6 and the preset spray coverage response, determine at least the recoating control parameters including the recoating position and the recoating amount, and control the recoating actuator to recoat the target recoating area according to the recoating control parameters; wherein, the preset spray coverage response is used to characterize the coating spatial coverage distribution formed by the recoating actuator under different spraying positions and different spraying amounts.

[0024] Further, in step S7, at least one candidate recoating location is determined based on the spatial location and spatial range of the target recoating area, and multiple candidate recoating amounts are determined for each candidate recoating location; the corresponding preset spraying coverage response is invoked according to the candidate recoating location and candidate recoating amount to obtain the predicted coating coverage area corresponding to each candidate recoating location and candidate recoating amount; the predicted coating coverage area is compared with the target recoating area to determine the uncovered area within the target recoating area and the redundant coverage area outside the target recoating area; with the uncovered area not exceeding a preset allowable range as a constraint, the actual recoating location and recoating amount are determined from the candidate recoating locations and candidate recoating amounts based on the uncovered area and the redundant coverage area.

[0025] Furthermore, the amount of recoating is controlled by one or more of the following: the spray valve opening time, the spray pressure, and the number of sprays.

[0026] Further, in step S7, the spatial morphology of the damaged area is determined based on one or more of the following: area, aspect ratio, main extension direction, radial span, circumferential span, and number of mutually separated damaged sub-regions. When the damaged area is a concentrated damaged area, candidate single-point repair positions are determined based on the centroid of the target repair area. When the damaged area is a long and narrow damaged area extending along a preset direction, multiple candidate repair positions are determined sequentially based on the main extension direction. When the damaged area is an arc-shaped damaged area distributed along the circumference of the rivet, multiple candidate repair positions are determined along the circumference of the rivet based on the circumferential start and end positions of the damaged area. When the damaged area includes multiple mutually separated damaged sub-regions, the candidate repair positions for each damaged sub-region are determined separately, or the candidate repair positions for multiple damaged sub-regions are combined and repaired, based on the spacing between different damaged sub-regions and the preset spray coverage response.

[0027] Furthermore, after completing step S7, the following steps are also included:

[0028] S8, Obtain the post-coating verification image corresponding to the rivet area after the recoating is completed according to the recoating control parameters described in S7, and identify the actual coating coverage area from the post-coating verification image;

[0029] S9, compare the actual coating coverage area described in S8 with the target recoating area described in S6 to determine the remaining uncovered area in the target recoating area; when the remaining uncovered area exceeds the preset allowable range, use the remaining uncovered area as the new area to be recoated to redetermine the recoating position and amount, and perform a second recoating on the remaining uncovered area according to the redetermined recoating position and amount.

[0030] S10, establish a correspondence between the recoating control parameters described in S7 and the actual coating coverage area obtained in S8, update the preset spraying coverage response described in S7 according to the correspondence, and use the updated spraying coverage response to determine the recoating control parameters of the iron cover to be tested in the future.

[0031] Compared with the prior art, the present invention has at least the following beneficial effects:

[0032] This invention acquires multi-state images of the same rivet area on a metal cap under multiple different imaging states, and maps these images under different imaging states to the local coordinate domain of the rivet. This allows for comparative analysis of the image responses of the same rivet surface position under different imaging states. Furthermore, instead of using a fixed standard image as the sole normal reference, it selects effective reference positions from multiple circumferential positions on the metal cap that are in the same or adjacent radial intervals as the target location, establishing a normal multi-state reference response that matches the current metal cap and the current imaging state. This reduces the impact of differences in curvature at different radial positions of the rivet, product batch differences, and variations in imaging conditions on damage identification.

[0033] This invention further forms a damage response field by comparing the differences in state amplitude, cross-state change relationships, and spatial continuity between the actual multi-state response and the normal multi-state reference response. A structural mask formed by a pre-set stable structure is then used to suppress abnormal responses caused by normal structures such as the outer periphery of the rivet, the edge of the pull ring structure, and the pre-made engravings on the iron cap. The damaged area is then obtained by reconstructing the spatial continuity in the radial and circumferential directions. Therefore, the image response conforming to the normal surface reflection variation of the rivet can be further distinguished from the abnormal response caused by damage to the protective coating, reducing misidentification caused by high metal reflectivity, structural edges, and local occlusion.

[0034] Furthermore, this invention determines the recoating extension distance based on the identification uncertainty corresponding to different damage boundary locations, and uses a non-equidistant extension method to form the target recoating area. This ensures that boundary locations with higher identification uncertainty have a larger protection margin, while boundary locations with higher identification reliability maintain a smaller extension range. It further combines a preset spray coverage response with a comparison of the uncovered and redundant coverage areas formed by different candidate recoating schemes to determine the recoating location and amount, thereby ensuring reliable coverage of the damaged area while reducing unnecessary redundant recoating. Through post-recoating verification and spray coverage response updates, the actual recoating results can also be used to correct the determination of subsequent recoating control parameters, improving the consistency and adaptability of recoating control under continuous production conditions. Attached Figure Description

[0035] Figure 1 This is a schematic diagram of the overall process of the method of the present invention.

[0036] Figure 2 This is a schematic diagram of the multi-state image acquisition and repainting execution structure of the present invention.

[0037] Figure 3 This is a schematic diagram of the local coordinate domain of the rivet of the present invention.

[0038] Figure 4 This is a schematic diagram showing the selection of reference positions for the present invention.

[0039] Figure 5 This is a schematic diagram of the damaged area reconstruction according to the present invention.

[0040] Figure 6 This is a schematic diagram illustrating the non-equidistant expansion of the damaged area in this invention.

[0041] Figure 7 This is a schematic diagram illustrating the recoating scheme of the present invention. Detailed Implementation

[0042] The technical solution of the present invention will be further described in detail below with reference to specific embodiments. It should be noted that the following embodiments are used to illustrate the technical principles and specific implementation process of the present invention, and are not intended to limit the scope of protection of the present invention. Those skilled in the art can implement the present invention by adapting the corresponding parameters according to the specific configuration of the size of the iron cover to be tested, the type of protective coating, the image acquisition device, the lighting device, and the recoating execution mechanism, based on the disclosure of the present invention.

[0043] The metal lid described in this embodiment is a metal lid with rivets and a pull ring. A protective coating is applied to the surface of the metal substrate of the lid and its rivet area. During rivet forming, pull ring installation, and subsequent conveying, the rivet and its adjacent area are subjected to stamping, stretching, and localized compression, which may cause scratches, cracks, peeling, or partial detachment of the protective coating. The damaged area described in this embodiment refers to the area within the rivet region where the protective coating has become abnormal and requires recoating for protection. The rivet used in this application is located in the center of the can, but it can also be located in other positions.

[0044] like Figure 2As shown, the apparatus for implementing the method of the present invention includes an image acquisition device, an illumination device, a metal cover positioning mechanism, a control device, and a recoating execution mechanism. The image acquisition device can employ an industrial camera and an industrial lens connected to it, with the imaging area of ​​the industrial camera at least covering the rivets and adjacent areas of the metal cover to be inspected. The illumination device includes independently controllable paraxial illumination units and multiple oblique incidence illumination units positioned at different locations. Polarizing components can also be arranged in the illumination optical path and / or imaging optical path according to inspection needs to form different polarization states. The polarizing components can include a polarizer in the illumination optical path and an analyzer in the imaging optical path, wherein the analyzer can be a rotatable or electrically switchable polarizing component. The control device can switch the analyzer between at least a first polarization direction and a second polarization direction while keeping the metal cover to be inspected, the image acquisition device, and the illumination direction unchanged, and acquire corresponding rivet area images respectively. For example, the first polarization direction is parallel to the polarization direction of the polarizer, and the second polarization direction is orthogonal to the polarization direction of the polarizer, thereby forming at least two different polarization states.

[0045] The repainting actuator includes a spray head that can move relative to the metal cover to be inspected and a spray valve for controlling paint output. The control unit is communicatively connected to the image acquisition device, the lighting device, and the repainting actuator, and is used to control multi-state image acquisition, perform image processing and damage area reconstruction, determine repainting control parameters, and control the repainting actuator to perform repainting.

[0046] Before the equipment is put into use, a coordinate transformation relationship can be established between the image coordinate system and the machine coordinate system of the repainting actuator. Specifically, multiple calibration points with known positions can be set within the spraying working plane, and the image coordinates and corresponding machine coordinates of each calibration point can be obtained. Based on this, an affine transformation relationship or a planar projection transformation relationship between the two can be established. Subsequently, after obtaining the image coordinates of the position to be repainted, the machine movement position corresponding to the repainting actuator can be obtained using the aforementioned coordinate transformation relationship.

[0047] like Figure 1 As shown, the method in this embodiment specifically includes the following steps.

[0048] S1, acquire multi-state images of the rivet area of ​​the iron cover to be detected under at least two different imaging states; wherein, the relative position of the iron cover to be detected and the image acquisition device remains unchanged under different imaging states, and at least one of the illumination direction, illumination incident angle and polarization state is different between the different imaging states.

[0049] The rivet area is a metal surface with significant curvature changes, and the surface normal varies at different locations. Therefore, even when the protective coating is in a normal state, the image brightness at different locations will change accordingly when the lighting conditions change. Simultaneously, when the protective coating is scratched, cracked, partially peeled off, or the metal substrate is exposed, the surface material state and reflective properties of the corresponding area change, and its response variation between different imaging states differs from that of the normally coated area. This invention actively sets multiple imaging states, enabling these differences to be extracted in subsequent processing.

[0050] Step S1 specifically includes the following steps.

[0051] S11, Position the iron cover to be detected in the image acquisition area, and keep the relative position of the iron cover to be detected and the image acquisition device unchanged.

[0052] After the metal cover to be inspected reaches the image acquisition area, its planar translation and rotation are restricted by a positioning mechanism. The relative position between the metal cover and the image acquisition device remains unchanged until a set of multi-state images belonging to the same metal cover is acquired.

[0053] Maintaining the relative position means that within the time range required for multi-state image acquisition, the images corresponding to different imaging states can characterize the same rivet surface area, without requiring different iron covers to have exactly the same absolute installation position.

[0054] S12, under the condition that the relative position remains unchanged as described in S11, the lighting device is controlled to switch at least one paraxial lighting state and at least two oblique incident lighting states with different incident orientations in a preset sequence, and images of the rivet area are acquired in each imaging state respectively.

[0055] For example, the first imaging state can be set as a paraxial illumination state, the second imaging state can be set as a first oblique incidence illumination state located on the first side of the rivet, and the third imaging state can be set as a second oblique incidence illumination state located on the second side of the rivet, wherein the incident orientations of the first oblique incidence illumination state and the second oblique incidence illumination state are different.

[0056] Therefore, we can conclude that:

[0057]

[0058] in, Indicates the first Image coordinate position under various imaging conditions The corresponding image response; ; Represents the number of imaging states, and satisfies:

[0059]

[0060] When processing grayscale images It can be the grayscale value of the corresponding position; when using a color image, a predetermined color channel, luminance component, or a representation obtained through color space transformation can be selected as the image response.

[0061] Preferably, the exposure time, gain, focal length, and imaging magnification of the industrial camera are kept constant under different imaging conditions.

[0062] If there are differences in basic light intensity between different illumination units, the brightness of images under different imaging states can be pre-normalized. The normalized image response corresponding to each imaging state can be expressed as:

[0063]

[0064] in, Indicates the first The image response after normalization for various imaging states; Indicates the first The proportional correction coefficient corresponding to each imaging state; Indicates the first The offset correction amount corresponding to each imaging state.

[0065] The proportional correction coefficient and offset correction amount can be obtained by pre-calibrating the non-damaged reference surface under different lighting conditions. When performing the above normalization process, the following steps... Both can be understood as the normalized image response.

[0066] S13, associate the images acquired in S12 under different imaging states according to the corresponding imaging states at the time of acquisition to obtain the multi-state image mentioned in S1, so that the same rivet surface position has a spatially corresponding image response under different imaging states.

[0067] The control device associates each image belonging to the same iron cover to be detected with the corresponding imaging status identifier and forms a set of multi-state image data.

[0068] Therefore, it is possible to compare the actual response of the same rivet surface position under multiple imaging states, thus avoiding treating the brightness differences that exist between different rivet surface positions as cross-state changes.

[0069] S2, as Figure 3As shown, the rivet center and reference direction are determined based on the rivet geometric boundary in the multi-state image described in S1, a local coordinate domain for the rivet is established, and the multi-state image described in S1 is registered and mapped to the local coordinate domain for the rivet to obtain the corresponding local image responses under different imaging states.

[0070] Different metal covers to be inspected may experience translation, rotation, and manufacturing tolerances in rivet dimensions during transport and positioning. If fixed pixel coordinates of an industrial camera are directly used for subsequent calculations, the response positions between different metal covers are difficult to directly correspond. Therefore, this embodiment utilizes the rivet geometry of each metal cover to be inspected to establish a local coordinate domain for the rivets.

[0071] Step S2 specifically includes the following steps.

[0072] S21, extract the rivet geometric boundary from at least one of the multi-state images in S1, determine the rivet center O and the feature radius R representing the rivet size according to the rivet geometric boundary, and determine the reference direction according to the preset stable structure on the iron cover.

[0073] You can prioritize images under paraxial illumination to extract the geometric boundary of the rivet's outer periphery, or you can choose images from other imaging states with higher contrast at the outer periphery of the rivet.

[0074] Edge extraction is performed on the corresponding image to obtain the effective edges of the rivet's outer perimeter. When part of the rivet's outer perimeter is obscured by the pull ring, the outer perimeter contour of the rivet is fitted using the unobscured effective edge segments.

[0075] When the outer perimeter of the rivet is approximately circular, its center and radius can be determined by circle fitting; when the outer perimeter of the rivet is slightly elliptical due to imaging posture or manufacturing error, ellipse fitting can be performed, and the center of the fitted ellipse can be used as the center of the rivet.

[0076] The center of the rivet is indicated as:

[0077]

[0078] When using circle fitting, the radius of the fitted circle is used as the feature radius. When using ellipse fitting, the major semi-axis of the ellipse can be... With short half shaft The arithmetic mean of the features is used as the characteristic radius, that is:

[0079]

[0080] Further determine the reference direction based on the direction of the pull ring spindle, the direction of the pre-made engraved lines on the iron cover, or other structures that have a stable positional relationship with the rivet.

[0081] Let the direction angle of the reference direction relative to the positive direction of the horizontal axis of the image coordinate system be:

[0082]

[0083] S22, taking the rivet center O mentioned in S21 as the origin of the coordinate system, convert each position within the rivet area into a local position represented by the normalized radial coordinate ρ and the circumferential angular coordinate θ; wherein, the normalized radial coordinate ρ is determined based on the distance from the corresponding position to the rivet center O and the feature radius R mentioned in S21, and the circumferential angular coordinate θ is determined based on the circumferential angle of the corresponding position relative to the reference direction mentioned in S21.

[0084] For any image location within the rivet area:

[0085]

[0086] The image distance between position P and the rivet center O is:

[0087]

[0088] The normalized radial coordinates corresponding to position P are:

[0089]

[0090] in, and Using the same image length unit, therefore It is a dimensionless quantity.

[0091] The circumferential angular coordinates of position P relative to the reference direction described in S21 are expressed as follows:

[0092]

[0093] in, Used to obtain the azimuth angle of position P relative to the rivet center O. Used to convert the calculated circumferential angle to an interval:

[0094]

[0095] Therefore, each image position P can be represented as the position of the rivet in the local coordinate domain:

[0096]

[0097] Accordingly, from local coordinates When reversing the process to obtain the coordinates of the original image, the following method can be used:

[0098]

[0099]

[0100] Through the above positive and negative coordinate transformations, the correspondence between the local coordinates of the rivet and the coordinates of the original image can be realized.

[0101] S23, based on the rivet center O, feature radius R and reference direction described in S21, perform coordinate normalization and spatial registration on the multi-state images under different imaging states described in S1, and map the multi-state images to the rivet local coordinate domain described in S2 to obtain the corresponding local image responses under different imaging states.

[0102] Establish a unified A discrete coordinate grid is used, and the original images in each imaging state are mapped to the discrete coordinate grid according to the coordinate transformation relationship described in S22.

[0103] For the result of reverse mapping For cases where the pixel is not at the center of an integer pixel, bilinear interpolation can be used to calculate the corresponding image response.

[0104] Therefore, at any local location All can be obtained as follows:

[0105]

[0106] The above responses correspond to the image responses of the same rivet surface position under different imaging states.

[0107] S3, as Figure 4 As shown, for the position to be detected in the local coordinate domain of the rivet described in S2, a reference position is selected from multiple circumferential positions that are in the same or adjacent radial interval as the position to be detected, and a normal multi-state reference response corresponding to the position to be detected is established based on the local image response of the reference position under different imaging states; wherein, the reference position does not include the occluded position and the position corresponding to the preset stable structure.

[0108] The local tilt of the rivet surface is strongly correlated with its radial position. Therefore, surface positions within the same or adjacent radial intervals can serve as initial candidate reference positions for the location to be detected. It should be noted that when using oblique incidence illumination with a clear incident orientation, normal surface areas within the same radial interval but with different circumferential positions may still have different orientational relationships relative to the current illumination direction, resulting in differences in normal reflection responses. Therefore, under oblique incidence illumination, this embodiment, based on selecting candidate reference positions within the same or adjacent radial intervals, prioritizes candidate reference positions that have the same or similar orientational relationship to the location to be detected relative to the current illumination direction, and then excludes subsequent obstruction positions, positions corresponding to preset stable structures, and outlier positions in multi-state responses. This approach both utilizes radial position to limit rivet curvature differences and reduces the impact of directional illumination on the normal reflection responses at different circumferential positions.

[0109] Step S3 specifically includes the following steps.

[0110] S31, for the position to be detected in the local coordinate domain of the rivet described in S2, located at the target radial position, select multiple candidate reference positions distributed at different circumferential positions within a preset radial interval that includes the target radial position.

[0111] Let the location to be detected be:

[0112]

[0113] Set the radial search half-width to Then the normalized radial coordinates of the candidate reference position Q satisfy:

[0114]

[0115] Candidate reference positions are selected at different circumferential positions along the radial strip region that meets the above conditions to form an initial set of candidate reference positions:

[0116]

[0117] in, This represents the initial number of candidate reference positions.

[0118] When the current imaging state is oblique incidence illumination, the initial candidate reference positions can be further optimized based on the circumferential azimuth relationship between the detection position P and the current illumination direction. Specifically, the difference between the azimuth angle of each candidate reference position relative to the current illumination direction and the azimuth angle of the detection position P relative to the current illumination direction can be calculated, and candidate reference positions with an azimuth angle difference less than a preset azimuth difference threshold can be preferentially retained. When the number of candidate reference positions that meet the above conditions is insufficient, the preset azimuth difference threshold can be gradually increased. The subsequent exclusion of occlusion positions, preset stable structure corresponding positions, and outlier positions in multi-state response in S32 is based on the above candidate reference positions.

[0119] S32, based on the pull ring position, rivet structure edge position and iron cover preset scribing position in the local coordinate domain of the rivet described in S2, candidate reference positions located in the pull ring occlusion area and the corresponding area of ​​the preset stable structure are excluded from the candidate reference positions described in S31, and multi-state response outliers are excluded based on the local image response of each candidate reference position under different imaging states, so as to obtain the effective reference position.

[0120] First, determine the pull ring blocking area based on the pull ring's outline. Simultaneously, form a stable structural area based on the rivet structure edge and the pre-made engraved lines on the metal cap. Then, determine the position that falls within this area from... By excluding outliers, we obtain a set of candidate reference locations for outlier screening:

[0121]

[0122] Further The candidate reference positions are used to determine outliers in the multi-state response.

[0123] For the For each imaging state, the median of the image response at the candidate reference location is first calculated:

[0124]

[0125] Calculate the corresponding median absolute deviation:

[0126]

[0127] Further define the first Robust discrete scales corresponding to various imaging states:

[0128]

[0129] in, It is a preset positive number to avoid division by zero when the absolute deviation of the median is equal to zero.

[0130] For candidate reference positions Define the outlier degree of a multi-state response:

[0131]

[0132] Set outlier detection threshold ,when:

[0133]

[0134] At that time, the candidate reference position will be... It was excluded as an outlier in the multi-state response.

[0135] The remaining positions form the set of valid reference positions:

[0136]

[0137] This processing method can reduce the probability that coating damage or abnormal reflective spots on the metal cover being inspected will be included in the normal reference set.

[0138] S33, based on the local image response of the effective reference position in each imaging state as described in S32, determine the normal response benchmark for each imaging state corresponding to the radial position of the target.

[0139] For the For each imaging state, the median of the response corresponding to the effective reference position is used as the normal response benchmark:

[0140]

[0141] Furthermore, the robust discrete scale is recalculated based on the effective reference location:

[0142]

[0143] in, This indicates that the position P to be detected is at the th... The normal response benchmark corresponding to a certain imaging state; This represents the robust discrete scale corresponding to the normal response benchmark, and due to the addition of Always satisfy:

[0144]

[0145] S34, combine the normal response benchmarks of each imaging state obtained in S33 according to the corresponding imaging state to obtain the normal multi-state reference response corresponding to the position to be detected in S3.

[0146] The normal multistate reference response corresponding to the location P to be detected is represented as follows:

[0147]

[0148] Therefore, the normal reference does not use a fixed standard iron cover template, but is established separately for different radial positions of the iron cover to be tested, so that the normal reference can adapt to the basic brightness of the iron cover and the radial curvature of the rivets.

[0149] When the number of valid reference positions within the radial range of a certain location to be detected is less than the preset minimum number, the number can be increased step by step. If the expanded radial range still cannot obtain a sufficient number of effective reference positions, then the adjacent radial positions that have already been obtained can be used. and Interpolation is performed to obtain the normal multi-state reference response corresponding to the location to be detected.

[0150] S4, obtain the actual multi-state response of the position to be detected under different imaging states as described in S2, compare the actual multi-state response with the normal multi-state reference response as described in S3, determine the damage response value of the position to be detected based on the difference in state amplitude and the difference in cross-state change relationship between the two, and construct a damage response field based on the damage response values ​​of each position to be detected in the local coordinate domain of the rivet.

[0151] This embodiment uses state amplitude anomalies, cross-state change anomalies, and spatial continuity anomalies to describe the degree to which the actual multi-state response deviates from the normal surface response law.

[0152] Step S4 specifically includes the following steps.

[0153] S41, based on the local image response described in S2, obtain the actual image response of the location to be detected in each imaging state, and compare the actual image response with the normal response benchmark of the corresponding imaging state in the normal multi-state reference response described in S3 to obtain the state amplitude anomaly quantity.

[0154] The actual multi-state response corresponding to the position P to be detected is:

[0155]

[0156] Define state amplitude anomalies:

[0157]

[0158] in, This represents the average standardized deviation of the detection location P from the normal response baseline under all imaging conditions.

[0159] S42, based on the actual image response of the position to be detected in at least two imaging states as described in S41, determine the actual response change between corresponding imaging states, and based on the normal multi-state reference response as described in S3, determine the normal response change between corresponding imaging states, and obtain the cross-state change anomaly amount based on the difference between the actual response change amount and the normal response change amount.

[0160] For any two different imaging states and The actual cross-state response change corresponding to the location P to be detected is:

[0161]

[0162] The corresponding normal cross-state response change is:

[0163]

[0164] Define cross-state change anomalies:

[0165]

[0166] because:

[0167]

[0168] Therefore, the denominator above is always greater than zero.

[0169] It is used to describe the degree to which the response change relationship of the detected location deviates from the normal cross-state change relationship of the surface between different imaging states.

[0170] S43, determine the actual multi-state response spatial change relationship between the detection location and its neighboring locations based on the local image response described in S2, and determine the corresponding normal multi-state response spatial change relationship based on the normal multi-state reference response described in S3, and obtain the spatial continuity anomaly quantity based on the difference between the two.

[0171] Let the set of neighborhood locations corresponding to the location P to be detected be:

[0172]

[0173] For any In the Under what imaging conditions, the actual spatial response change between P and Q is:

[0174]

[0175] The corresponding normal spatial response change is:

[0176]

[0177] Define spatial continuity anomalies:

[0178]

[0179] in, This indicates the number of neighboring locations.

[0180] use As a normalization metric, it can simultaneously consider the dispersion of the normal response corresponding to position P and neighboring positions Q.

[0181] S44, the abnormal state amplitude of S41, the abnormal cross-state change of S42, and the abnormal spatial continuity of S43 are fused to obtain the damage response value of the position to be detected in S4, and the damage response field of S4 is constructed according to the damage response value corresponding to each position to be detected in the local coordinate domain of the rivet.

[0182] The damage response value corresponding to the location P to be detected is expressed as:

[0183]

[0184] in:

[0185]

[0186] and:

[0187]

[0188] in, , and These are the fusion weights corresponding to state amplitude anomalies, cross-state change anomalies, and spatial continuity anomalies, respectively.

[0189] By applying the above processing to all detectable locations within the local coordinate domain of the rivet, the damage response field can be obtained:

[0190]

[0191] The larger the damage response value, the greater the deviation of the actual multi-state response at that location from the normal multi-state response pattern of the current iron cover.

[0192] S5, such as Figure 5As shown, a structural mask is established based on the preset stable structure in the rivet region. The structural mask is used to suppress the damage response caused by the preset stable structure in the damage response field described in S4. The region is reconstructed based on the spatial continuity of the remaining damage response in the local coordinate domain of the rivet, thereby obtaining a damage region that characterizes the damage location and damage range of the surface protective coating of the rivet region.

[0193] The outer periphery of the rivet, the edge of the pull ring, and the pre-made engraving lines on the iron cap are normal structures. However, due to their obvious brightness gradient or changes in reflection state, they may also have a high damage response. Therefore, this embodiment further utilizes a structural mask to suppress the response generated by the above-mentioned fixing structure.

[0194] Step S5 specifically includes the following steps.

[0195] S51, determine the position of one or more preset stable structures among the rivet outer peripheral structure edge, pull ring structure edge and iron cover pre-made engraving line according to the rivet local coordinate domain described in S2, and establish a structural mask according to the position of the preset stable structure.

[0196] The structure mask is represented as:

[0197]

[0198] The preset stable structure influence area can be formed by extending a preset distance from the edge of the corresponding structure to both sides, so as to simultaneously cover the adjacent response area caused by imaging blur, local high reflection, etc.

[0199] S52, spatially correspond the structural mask described in S51 with the damage response field described in S4, and suppress the damage response corresponding to the positions located within the structural mask and at distances less than a preset distance from the structural mask, to obtain the damage response field after structural response suppression.

[0200] The original structural mask obtained in S51 can first be expanded by performing an expansion process according to the preset distance to obtain an expanded structural mask. ,in:

[0201]

[0202] The damage response value after structural response suppression is defined as:

[0203]

[0204] in, The response retention coefficient for the structurally affected region satisfies:

[0205]

[0206] when hour:

[0207]

[0208] when hour:

[0209]

[0210] This allows for the suppression of damage responses occurring at preset stable structural locations. For cases where it is known that actual coating damage could not occur on the corresponding stable structure, a setting can be implemented. When it is desired to preserve some anomalous responses near a stable structure, one can... Set to a value greater than 0 and less than 1.

[0211] It should be noted that this embodiment does not automatically assume that the location of the preset stable structure is immune to protective coating damage. For areas where actual coating damage may still occur, such as the outer perimeter of the rivet structure, the edge of the pull ring structure, or near the pre-formed lines of the iron cap, it is preferable not to set the response retention coefficient κ to 0, but to use a response retention coefficient greater than 0 and less than 1 to reduce and suppress it. Furthermore, when the abnormal response located within or near the structural mask is spatially continuous with the high-damage response area outside the structural mask, or when the abnormal response exhibits a significant deviation from the characteristics of the normal multi-state reference response in multiple imaging states, the corresponding abnormal response can be retained to participate in the connectivity analysis described in S53. Thus, the structural mask is mainly used to reduce the normal structural response generated by the preset stable structure itself, while avoiding the deletion of actual protective coating damage near the stable structure.

[0212] S53. Based on the adjacency relationship of each position in the damage response field after the structural response is suppressed as described in S52, a connectivity analysis is performed in the radial and circumferential directions. Positions whose damage response values ​​meet the preset damage judgment conditions and are spatially continuous are merged to obtain candidate damage regions.

[0213] Set damage response judgment threshold This yields the initial set of anomaly locations:

[0214]

[0215] according to Radial and circumferential adjacency relationships in discrete meshes By performing connected component analysis, we obtain:

[0216]

[0217] in, Indicates the first One candidate damage region, This indicates the number of candidate damage regions.

[0218] S54, based on one or more of the area, length, width and continuous length of the candidate damage area described in S53, discrete abnormal areas are excluded to obtain the damage area described in S5, which characterizes the location and extent of damage to the protective coating on the surface of the rivet area.

[0219] Candidate damage regions with an area smaller than the preset minimum damage area and a continuous length smaller than the preset minimum continuous length can be identified as discrete abnormal regions formed by noise or isolated reflection points and excluded.

[0220] The remaining candidate damage areas constitute the final damage area:

[0221]

[0222] The damaged area Spatial information includes the location, area, shape, radial span, circumferential span, and number of mutually separated damaged sub-regions of the corresponding protective coating damage.

[0223] like Figure 6 As shown, in step S6, the damage boundary is determined based on the spatial distribution characteristics of the damaged area described in step S5, and the recoating extension distance at the corresponding boundary position is determined based on the identification uncertainty corresponding to the damage boundary. The damaged area described in step S5 is then extended according to the recoating extension distance to obtain a target recoating area that includes the damaged area and the corresponding protection margin area.

[0224] This embodiment does not apply a uniform fixed distance to the entire damaged area, but instead determines the identification uncertainty of each damaged boundary location. A larger protection margin is set for boundary locations with greater identification uncertainty to reduce the risk of missed coverage.

[0225] To give the extended distance practical physical meaning, we can first transform the local coordinates of the damaged area to the physical coordinate system of the iron cap surface. Let the actual rivet characteristic radius be... Then the local coordinate position The corresponding local physical coordinates of the iron cover can be represented as:

[0226]

[0227]

[0228] in, and The unit can be mm.

[0229] Step S6 specifically includes the following steps.

[0230] S61, determine the damage boundary based on the spatial distribution relationship between the damaged area and the non-damaged area described in S5, and for each boundary position on the damage boundary, determine the identification uncertainty based on at least two of the following: the difference between the damage response value at the corresponding boundary position and the preset damage judgment condition, the consistency of damage judgment at the corresponding boundary position under different imaging states, and the gradient of damage response change in the neighborhood of the corresponding boundary position.

[0231] The boundary of the damaged area is represented as follows:

[0232]

[0233] For any boundary location First, the first uncertainty is determined based on the proximity between the damage response value at the boundary location and the damage response judgment threshold:

[0234]

[0235] in, This is the damage response scale parameter.

[0236] when The closer hour, The closer it is to 1, the more susceptible the boundary position is to changes in the judgment threshold.

[0237] Further, determine whether each imaging state supports the current location being an abnormal location. For the first... Imaging states, defined as follows:

[0238]

[0239] in, For the first The threshold for judging state anomalies corresponding to each imaging state.

[0240] Let the number of imaging states that support anomaly detection be:

[0241]

[0242] The number of imaging states that do not support anomaly detection is:

[0243]

[0244] The consistency of judgments across different imaging states is defined as follows:

[0245]

[0246] Further define the second uncertainty:

[0247]

[0248] When the judgment results of different imaging states are more consistent, The smaller.

[0249] A third uncertainty is further determined based on the variation of the damage response with physical distance within the boundary location's neighborhood. Let the boundary location be... The corresponding set of neighborhood locations is , Indicates the boundary position The local damage response gradient is defined by the actual physical distance between the damage source and its neighboring location Q.

[0250]

[0251] because Therefore, the gradient described above can characterize the magnitude of the damage response change per unit physical distance.

[0252] definition:

[0253]

[0254] in, To preset the gradient scale parameter, its dimensions are the same as... The same applies, thus ensuring that the exponent term is a dimensionless quantity.

[0255] When the damage response changes significantly on both sides of the boundary, It is relatively large, and the boundary location is relatively clear. The corresponding decrease.

[0256] The above uncertainties are combined:

[0257]

[0258] in:

[0259]

[0260] and:

[0261]

[0262] because:

[0263]

[0264] therefore:

[0265]

[0266] S62, determine the corresponding repainting extension distance based on the identification uncertainty of each boundary position obtained in S61, so that the repainting extension distance increases as the identification uncertainty of the corresponding boundary position increases.

[0267] Set minimum recoating extension distance and maximum recoating extension distance ,satisfy:

[0268]

[0269] Boundary position The corresponding recoating extension distance is:

[0270]

[0271] therefore:

[0272]

[0273] Therefore, identifying boundary locations with higher confidence levels corresponds to smaller protection margins, while identifying boundary locations with higher uncertainty levels corresponds to larger protection margins.

[0274] S63, based on the repainting extension distance corresponding to each boundary position obtained in S62, the damaged area described in S5 is extended non-equidistantly along different boundary positions, and the protection margin area formed by the extension is merged with the damaged area described in S5 to obtain the target repainting area described in S6.

[0275] Transform the boundary positions on the damaged boundary to the local physical coordinate plane of the iron cover surface. Let the physical coordinates corresponding to a certain boundary position be:

[0276]

[0277] by Centered on S62 A locally extended region is formed for the radius:

[0278]

[0279] The local expansion areas corresponding to each boundary position are merged with the original damaged area to obtain the target repainting area:

[0280]

[0281] The above and The same physical coordinates are used when performing set operations.

[0282] Due to different boundary positions Unlike other regions, the target repair area does not perform a uniform fixed-distance extension on the original damaged area, but rather forms a non-equidistant protection margin based on the uncertainty of boundary identification.

[0283] like Figure 7 As shown in S7, based on the target recoating area described in S6 and the preset spray coverage response, at least the recoating control parameters including the recoating position and the recoating amount are determined, and the recoating execution mechanism is controlled to recoat the target recoating area according to the recoating control parameters; wherein, the preset spray coverage response is used to characterize the coating spatial coverage distribution formed by the recoating execution mechanism under different spraying positions and different spraying amounts.

[0284] Before the equipment is put into production, the spray coverage response corresponding to different touch-up control parameters can be established through test spraying.

[0285] Specifically, test spraying can be performed on a calibration surface with the same or similar spraying conditions as the iron cover surface, using different spray valve opening times, spraying pressures, and spraying times, and corresponding coating images can be collected.

[0286] A set of spraying parameters is expressed as follows:

[0287]

[0288] in, Indicates the duration of the spray valve opening. Indicates the spraying pressure. Indicates the number of sprays.

[0289] In this embodiment, the spray coverage response is preferably defined as the relative coating deposition response formed by a unit spraying action in the local physical coordinate system with the spraying center as the origin:

[0290]

[0291] in, and This represents the physical coordinate offset relative to the spraying center.

[0292] The The effective coating coverage can be obtained by normalizing the grayscale, color, or other optical characteristics related to the coating deposition amount in the image after recoating. When only determining whether effective coating coverage has been formed, the actual test spray area can be binarized to obtain the corresponding effective coverage area. The threshold for determining effective coating coverage can be pre-determined through coating thickness calibration. Specifically, the actual coating thickness can be measured for test spray areas formed with different spraying parameters, and the image response of the corresponding area under a preset verification lighting condition can be simultaneously acquired, thereby establishing a correspondence between the image response and the actual coating thickness. The minimum effective coating thickness is determined based on the protection requirements of the rivet area on the iron cap, and the image response corresponding to reaching the minimum effective coating thickness is determined as the minimum effective coating deposition threshold. Subsequent predicted coating coverage areas and actual coating coverage areas can both be determined according to the minimum effective coating deposition threshold.

[0293] Step S7 specifically includes the following steps.

[0294] S71, determine at least one candidate repainting location based on the spatial location and spatial range of the target repainting area described in S6, and determine multiple candidate repainting amounts for each candidate repainting location.

[0295] Based on the target repainting area The centroid, main extension direction, and region boundary generate one or more candidate repainting locations:

[0296]

[0297] Different candidate spray valve opening durations, spray pressures, and / or spray counts are set for different candidate recoating locations.

[0298] S72, based on the candidate recoating positions and candidate recoating amounts described in S71, call the corresponding preset spraying coverage response to obtain the predicted coating coverage area corresponding to each candidate recoating position and candidate recoating amount.

[0299] Let the first The physical touch-up location corresponding to the second candidate spraying is:

[0300]

[0301] Spraying parameters are The predicted depositional response formed within the physical coordinate plane of the iron cap is then:

[0302]

[0303] When the candidate recoating scheme includes N sprays, if the spray coverage response K represents the summable relative deposition amount, then the cumulative deposition response is expressed as:

[0304]

[0305] Set the minimum effective coating deposition threshold. The predicted coating coverage area is obtained:

[0306]

[0307] When using a binary spraying coverage model, it is unnecessary to perform the above-mentioned deposition amount summation. Instead, the effective coverage areas corresponding to each candidate spraying action are combined using a union operation to directly obtain the deposition amount. .

[0308] S73, compare the predicted coating coverage area obtained in S72 with the target recoating area described in S6, and determine the uncovered area within the target recoating area and the redundant coverage area outside the target recoating area.

[0309] The area predicted to be effectively uncovered within the target repainting region is represented as follows:

[0310]

[0311] The predicted redundant coverage area located outside the target repainting area is represented as:

[0312]

[0313] The total area of ​​the target repainting area is expressed as:

[0314]

[0315] S74, with the constraint that the uncovered area described in S73 does not exceed a preset allowable range, the repainting position and repainting amount described in S77 are determined from the candidate repainting positions and candidate repainting amounts described in S71 based on the uncovered area and the redundant coverage area; wherein, the repainting amount is controlled by one or more of the following: spray valve opening time, spraying pressure, and number of sprays.

[0316] Let the maximum allowable uncovered percentage be Then the candidate repainting scheme first satisfies:

[0317]

[0318] For candidate repainting schemes that satisfy the above constraints, they can be compared using the following evaluation function:

[0319]

[0320] in, The number of coats required for the current candidate recoating scheme; The maximum number of sprays allowed is preset; , and To correspond to the evaluation weights, and satisfy:

[0321]

[0322] as well as:

[0323]

[0324] From the candidate recoating schemes that meet the uncovered ratio constraint, select the scheme with the smaller evaluation value J, and use its recoating location and recoating amount as the actual recoating control parameters.

[0325] Furthermore, in step S7, determining the candidate repainting location based on the target repainting area described in S6 may also include the following steps.

[0326] S75, determine the spatial morphology of the damaged region based on one or more of the following: area, aspect ratio, main extension direction, radial span, circumferential span, and number of mutually separated damaged sub-regions of the damaged region described in S5.

[0327] For example, principal component analysis can be performed based on the physical coordinates of each location in the damaged area, with the first principal axis direction as the main extension direction of the damaged area; the aspect ratio can be determined based on the span of the damaged area along the first and second principal axes; and simultaneously, based on the damaged area in... and The directional distribution determines the radial span and circumferential span, respectively.

[0328] S76, when S75 determines that the damaged area is a concentrated damaged area, a candidate single-point repair position is determined according to the centroid of the target repair area in S6; when S75 determines that the damaged area is a slender damaged area extending along a preset direction, a plurality of candidate repair positions are determined in sequence according to the main extension direction.

[0329] For concentrated damage areas, the centroid of the target repainting area can be set as the initial candidate repainting location, and several position offset candidate points can be formed in its neighboring area.

[0330] For elongated damage areas, multiple candidate recoating positions can be set along the main extension direction at intervals smaller than the effective diameter of a single spray, thereby avoiding excessive redundant coverage areas caused by simply increasing the amount of a single spray to cover elongated damage.

[0331] S77, when S75 determines that the damaged area is an arc-shaped damaged area distributed along the circumference of the rivet, multiple candidate repair positions arranged along the circumference of the rivet are determined according to the circumferential start position and circumferential end position corresponding to the damaged area.

[0332] The average radial position of the arc-shaped damage area can be determined first. and at the circumferential starting angle of the damaged area and circumferential termination angle Multiple candidate positions are set at preset angle intervals, and the corresponding image positions and physical fill positions are obtained through the reverse coordinate transformation relationship described in S22.

[0333] S78, when S75 determines that the damaged area includes multiple mutually separated damaged sub-regions, based on the spacing between different damaged sub-regions and the preset spraying coverage response described in S72, determine the corresponding candidate repainting position for each damaged sub-region or the corresponding candidate repainting position for multiple damaged sub-regions combined.

[0334] When multiple adjacent damaged sub-regions can be covered by the same spray coating response, and the resulting redundant coverage area still meets the preset requirements, the multiple damaged sub-regions can be regarded as the same recoating object; otherwise, candidate recoating positions are generated for different damaged sub-regions respectively.

[0335] After determining the actual recoating location, the corresponding location is converted into machine coordinates, and the recoating actuator is controlled to perform recoating according to the determined recoating sequence, spray valve opening duration, spraying pressure, and number of sprays.

[0336] S8. Obtain the post-repair verification image corresponding to the rivet area after re-coating according to the re-coating control parameters described in S7, and identify the actual coating coverage area from the post-repair verification image.

[0337] After the recoating is completed, the metal cap can be kept in its original imaging position or transported to an independent verification station. A verification image after recoating is acquired under preset verification lighting conditions.

[0338] When there are identifiable differences in grayscale, color, or reflection between the touch-up coating and the original protective coating, the touch-up area can be directly segmented from the post-touch-up verification image.

[0339] When the visual difference between the two is small, the verification image after recoating can be registered with the image before recoating under the same imaging state in S1, and the actual coating coverage area can be identified based on the difference between the before and after images:

[0340]

[0341] S9, compare the actual coating coverage area described in S8 with the target recoating area described in S6 to determine the remaining uncovered area in the target recoating area; when the remaining uncovered area exceeds the preset allowable range, use the remaining uncovered area as the new area to be recoated to redetermine the recoating position and amount, and perform a second recoating on the remaining uncovered area according to the redetermined recoating position and amount.

[0342] The remaining uncovered areas are represented as follows:

[0343]

[0344] The corresponding remaining uncovered percentage is:

[0345]

[0346] Set the percentage of verification coverage that can be missed. .

[0347] when:

[0348]

[0349] At that time, it was considered that the current touch-up coating of the iron cover met the requirements.

[0350] when:

[0351]

[0352] At that time, As a new area to be recoated, the recoating location and amount are re-determined according to the recoating control parameter determination method described in S7, and a second recoating is performed only on the remaining uncovered areas.

[0353] S10, establish a correspondence between the recoating control parameters described in S7 and the actual coating coverage area obtained in S8, update the preset spraying coverage response described in S7 according to the correspondence, and use the updated spraying coverage response to determine the recoating control parameters of the iron cover to be tested in the future.

[0354] The actual spraying parameters used in this study Establish a correlation with the actual observation results after recoating.

[0355] When a single recoating operation involves only one recoating location, the actual coating coverage response identified by S8 can be directly converted to a local spraying coordinate system with the spraying center as the origin, using that recoating location as the center, to obtain the actual observed spraying response corresponding to that spraying parameter.

[0356] When a single recoating operation involves multiple recoating locations, the predicted coverage area for different spraying actions is first determined based on each recoating location and its corresponding preset spray coverage response. When the coverage areas corresponding to different spraying actions are separated from each other or their overlap is less than a preset overlap threshold, the actual coating coverage response is extracted from the non-overlapping area corresponding to each recoating location and transformed to the local spraying coordinate system corresponding to the respective recoating location to obtain the actual observed spraying response for the corresponding spraying parameters. For overlapping coverage areas formed by two or more spraying actions, since the actual coating response in this area is simultaneously affected by multiple spraying actions, the preset spray coverage response corresponding to a single spraying action is not updated using the overlapping coverage area when the contribution of each spraying action cannot be reliably distinguished. When the non-overlapping effective area corresponding to a certain spraying action is insufficient to form a reliable actual observed spraying response, the recoating result may not be used to update the spray coverage response corresponding to that spraying parameter.

[0357] For cases where the spray coating response is represented by a continuous relative deposition response, the actual observed spray coating response can be obtained from the normalized optical response of the verification image after recoating:

[0358]

[0359] For existing spray coverage responses that are the same as the current spray parameters or located in the vicinity of the preset parameters. Update using the following method:

[0360]

[0361] in, This indicates the response to the previous paint coverage. This indicates the actual observed spraying response; This indicates the updated paint coverage response; To update the coefficients, the following condition must be met:

[0362]

[0363] When using binary spraying to cover the area, the 0 / 1 coverage states of multiple actual spraying results under the same spraying parameters can be statistically analyzed to form the empirical coverage probability of each location, and the corresponding coverage probability field can be updated using the same weighted update method.

[0364] Through the above updates, the spray coverage response can be adaptively adjusted according to changes in nozzle status, paint status, and environmental conditions during actual production, thereby maintaining a good correspondence between the subsequent target recoating area and the actual spraying result.

[0365] The following is a specific operational example to further illustrate the implementation process of the above method and the relationship between the main calculation parameters.

[0366] This example uses an industrial camera to capture images of the rivet area on the metal cover. The object-side resolution of the industrial camera on the metal cover surface is approximately 0.01 mm / pixel. The lighting device includes a paraxial illumination unit and two oblique incidence illumination units located on either side of the optical axis of the industrial camera. The touch-up coating mechanism uses a precision spray head capable of planar position adjustment.

[0367] Once the metal cover to be tested reaches the testing position, it is fixed in place by the positioning mechanism.

[0368] First, execute S1 to acquire multi-state images of the rivet area of ​​the iron cover to be detected under at least two different imaging states; wherein, the relative position of the iron cover to be detected and the image acquisition device remains unchanged under different imaging states, and at least one of the illumination direction, illumination incident angle and polarization state is different between the different imaging states.

[0369] This example uses three imaging states: the first imaging state is paraxial illumination; the second imaging state is oblique incidence illumination with the normal to the surface of the iron cover deflected 30° in the first direction; and the third imaging state is oblique incidence illumination with the normal to the surface of the iron cover deflected 30° in the second direction opposite to the first direction.

[0370] therefore:

[0371]

[0372] Three images of the rivet area are acquired sequentially.

[0373] Then, S2 is executed to determine the rivet center and reference direction based on the rivet geometric boundary in the multi-state image described in S1, establish the rivet local coordinate domain, and register and map the multi-state image described in S1 to the rivet local coordinate domain to obtain the corresponding local image responses under different imaging states.

[0374] Extract the outer peripheral edge of the rivet from the paraxial illumination image, determine the rivet center O, and obtain the actual rivet feature radius:

[0375]

[0376] Using the pull ring's main axis direction as the reference direction, the three images are mapped to a unified plane. Local coordinate domain.

[0377] For one of the locations P to be detected, we get:

[0378]

[0379] Then, S3 is executed. For the position to be detected in the local coordinate domain of the rivet described in S2, a reference position is selected from multiple circumferential positions that are in the same or adjacent radial interval as the position to be detected. A normal multi-state reference response corresponding to the position to be detected is established based on the local image response of the reference position under different imaging states. The reference position does not include the occluded position or the position corresponding to the preset stable structure.

[0380] Set the radial search half-width:

[0381]

[0382] Therefore, from the following:

[0383]

[0384] Multiple circumferential candidate reference positions are selected within the radial range.

[0385] This example can set an initial candidate reference position every 5°, and then exclude the pull ring blocking area, the edge of the rivet outer perimeter structure, and the position corresponding to the pre-made engraving line on the iron cover.

[0386] Set an outlier detection threshold:

[0387]

[0388] After performing the multi-state response outlier analysis described in S32 on the remaining candidate reference positions, the effective reference positions are obtained.

[0389] For the location P to be detected, the actual image responses under the three imaging states are as follows:

[0390]

[0391] The normal response baseline is calculated based on the valid reference location:

[0392]

[0393] The corresponding robust discrete scales are as follows:

[0394]

[0395] Then, S4 is executed to obtain the actual multi-state response of the position to be detected under different imaging states as described in S2. The actual multi-state response is compared with the normal multi-state reference response described in S3. The damage response value of the position to be detected is determined based on the difference in state amplitude and the difference in cross-state change relationship between the two. A damage response field is constructed based on the damage response values ​​of each position to be detected in the local coordinate domain of the rivet.

[0396] Calculated according to S41:

[0397]

[0398] Right now:

[0399]

[0400] For the first and second imaging states:

[0401]

[0402]

[0403] Therefore, the corresponding standardized cross-state difference is:

[0404]

[0405] For the first and third imaging states:

[0406]

[0407]

[0408] therefore:

[0409]

[0410] For the second and third imaging states:

[0411]

[0412]

[0413] therefore:

[0414]

[0415] Because in this example There are 3 pairs of states, therefore:

[0416]

[0417] The image response of P and its neighborhood is calculated according to S43:

[0418]

[0419] set up:

[0420]

[0421] but:

[0422]

[0423] Substituting the unrounded calculation results above, we get:

[0424]

[0425] Set the damage response judgment threshold:

[0426]

[0427] because:

[0428]

[0429] Therefore, location P is included in the initial set of abnormal locations.

[0430] Perform the same calculation on other locations in the local coordinate domain of the rivet to obtain the complete damage response field.

[0431] Then, S5 is executed, a structural mask is established based on the preset stable structure in the rivet area, the structural mask is used to suppress the damage response caused by the preset stable structure in the damage response field described in S4, and the region is reconstructed based on the spatial continuity of the remaining damage response in the local coordinate domain of the rivet, so as to obtain the damage area characterizing the damage location and damage range of the surface protective coating of the rivet area.

[0432] After structural masking suppression, thresholding, and connected component analysis, a damage region extending circumferentially along the rivet was obtained. Converted to actual physical dimensions based on camera calibration, the area of ​​this damage region is approximately:

[0433]

[0434] The maximum extension length is approximately:

[0435]

[0436] The maximum radial width is approximately:

[0437]

[0438] Based on the fact that its circumferential span is significantly larger than its radial span, it is identified as an arc-shaped damage area.

[0439] Then, S6 is executed, the damage boundary is determined according to the spatial distribution characteristics of the damaged area described in S5, and the recoating extension distance at the corresponding boundary position is determined according to the identification uncertainty corresponding to the damage boundary. The damaged area described in S5 is extended according to the recoating extension distance to obtain a target recoating area that includes the damaged area and the corresponding protection margin area.

[0440] Select a boundary location on the damage boundary. The damage response value after structural response suppression is:

[0441]

[0442] set up:

[0443]

[0444] The first uncertainty is:

[0445]

[0446] Two out of the three imaging states give the same judgment, therefore:

[0447]

[0448] corresponding:

[0449]

[0450] Based on the change in damage response relative to physical distance within the boundary location neighborhood, and combined with preset gradient scale parameters According to S61 The calculation formula yields:

[0451]

[0452] set up:

[0453]

[0454] but:

[0455]

[0456] Set the minimum recoating extension distance:

[0457]

[0458] Maximum recoating extension distance:

[0459]

[0460] but:

[0461]

[0462] The same method is used to calculate the repainting extension distance corresponding to other boundary positions of the damaged area, and non-equidistant protection margins are formed according to the different extension distances corresponding to each position to obtain the target repainting area.

[0463] Then, S7 is executed, and based on the target recoating area described in S6 and the preset spray coverage response, at least the recoating control parameters including the recoating position and the recoating amount are determined, and the recoating execution mechanism is controlled to recoat the target recoating area according to the recoating control parameters; wherein, the preset spray coverage response is used to characterize the coating spatial coverage distribution formed by the recoating execution mechanism under different spray positions and different spray amounts.

[0464] This example pre-sets the spraying pressure as follows:

[0465]

[0466] Test spraying and calibration were carried out under the following conditions.

[0467] By setting the spray valve opening time to 12 ms, 16 ms, and 20 ms respectively, the equivalent radius of the corresponding effective coating coverage area is approximately:

[0468]

[0469] The final target area for repainting obtained in this example is:

[0470]

[0471] Set the maximum allowed uncovered percentage:

[0472]

[0473] When using a 20 ms spray valve opening time for single-point recoating, the predicted uncovered area in the target recoating region is:

[0474]

[0475] The corresponding uncovered percentage is:

[0476]

[0477] Since 8.74% is greater than 5%, this option will not be adopted.

[0478] Two candidate recoating positions with a spacing of 0.80 mm were further set along the main extension direction of the arc-shaped damage area, and each recoating position adopted a spray valve opening time of 16 ms.

[0479] Based on the preset spraying coverage response, the corresponding uncovered area for this scheme is calculated as follows:

[0480]

[0481] The percentage of areas not covered is:

[0482]

[0483] satisfy:

[0484]

[0485] The calculated redundant coverage area corresponding to this candidate scheme is approximately:

[0486]

[0487] By comparing with other candidate solutions that meet the undercover ratio constraint, the solution with the above two recoating positions, each using a spraying pressure of 0.25 MPa and a spray valve opening time of 16 ms, was determined as the actual recoating solution.

[0488] The control device converts the two recoating positions into machine coordinates corresponding to the recoating actuator, and controls the spray head to move to the corresponding positions in sequence to complete the recoating.

[0489] After the touch-up coating is completed, execute S8 to obtain the post-touch-up verification image corresponding to the rivet area after the touch-up coating is completed according to the touch-up coating control parameters described in S7, and identify the actual coating coverage area from the post-touch-up verification image.

[0490] The actual coating coverage area was obtained from the verification image after recoating. .

[0491] Then, S9 is executed, and the actual coating coverage area described in S8 is spatially compared with the target recoating area described in S6 to determine the remaining uncovered area in the target recoating area; when the remaining uncovered area exceeds the preset allowable range, the remaining uncovered area is used as the new area to be recoated to redetermine the recoating position and amount, and the remaining uncovered area is recoated a second time according to the redetermined recoating position and amount.

[0492] For example, setting the percentage of verification that allows coverage:

[0493]

[0494] Calculate the actual remaining uncovered percentage based on the actual coating coverage area. When the actual remaining uncovered percentage does not exceed 3%, the current iron cap recoating is terminated; when the actual remaining uncovered percentage is greater than 3%, the remaining uncovered area is treated as a new area to be recoated, and the local recoating location and amount are re-determined according to S7, without re-coating the areas that have already met the coverage requirements.

[0495] Finally, S10 is executed to establish a correspondence between the recoating control parameters described in S7 and the actual coating coverage area obtained in S8. The preset spraying coverage response described in S7 is updated according to the correspondence, and the updated spraying coverage response is used to determine the recoating control parameters of the iron cover to be tested.

[0496] This example includes two recoating locations. Therefore, when updating the spray coverage response, the non-overlapping portions of the actual coverage areas corresponding to the two recoating locations are extracted respectively. The overlapping coverage area formed by the two recoating locations is not included in the update of a single spray coverage response. If the effective non-overlapping area of ​​any recoating location is smaller than the preset minimum update area, the recoating result will not be used to update the spray coverage response corresponding to that spraying parameter.

[0497] For example, the actual spraying response obtained with a spraying pressure of 0.25 MPa and a spray valve opening time of 16 ms is transformed into a local spraying coordinate system with the corresponding spraying center as the origin, forming... Set update coefficients:

[0498]

[0499] The existing spray coating response will then be updated:

[0500]

[0501] The updated paint coverage response is used for coverage prediction of subsequent candidate recoating schemes for the iron cap.

[0502] Through the above specific implementation process, this invention starts with the image response formed by the same iron cover rivet area under multiple imaging states. First, it normalizes the local coordinates of the rivet to make the surface positions in different imaging states correspond to each other. Then, it establishes a normal multi-state reference response using the effective circumferential area of ​​the same or adjacent radial position of the current iron cover itself. On this basis, it constructs a damage response field according to the differences in state amplitude, the differences in cross-state change relationship, and the differences in spatial continuity, and further eliminates the interference generated by stable structures such as pull ring edges, rivet structure edges, and pre-made engravings to reconstruct the actual protective coating damage area. Subsequently, it forms a non-equidistant recoating protection margin according to the recognition uncertainty of different damage boundary positions, and determines the recoating position and recoating amount in combination with the actual spraying coverage response, so that the machine vision inspection results can be directly converted into recoating actions adapted to the actual damage position, range, shape, and recognition reliability.

Claims

1. A method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction, characterized in that, Includes the following steps: S1, acquire multi-state images of the rivet area of ​​the iron cover to be detected under at least two different imaging states; wherein, the relative position of the iron cover to be detected and the image acquisition device remains unchanged under different imaging states, and at least one of the illumination direction, illumination incident angle and polarization state is different between the different imaging states. S2, determine the rivet center and reference direction based on the rivet geometric boundary in the multi-state image described in S1, establish the rivet local coordinate domain, and register and map the multi-state image described in S1 to the rivet local coordinate domain to obtain the local image response corresponding to each other under different imaging states. S3, for the position to be detected in the local coordinate domain of the rivet described in S2, a reference position is selected from multiple circumferential positions that are in the same or adjacent radial interval as the position to be detected, and a normal multi-state reference response corresponding to the position to be detected is established based on the local image response of the reference position under different imaging states; wherein, the reference position does not include the occluded position and the position corresponding to the preset stable structure. S4, obtain the actual multi-state response of the position to be detected under different imaging states as described in S2, compare the actual multi-state response with the normal multi-state reference response as described in S3, determine the damage response value of the position to be detected based on the difference in state amplitude and the difference in cross-state change relationship between the two, and construct a damage response field based on the damage response values ​​of each position to be detected in the local coordinate domain of the rivet. S5. Establish a structural mask based on the preset stable structure in the rivet area, use the structural mask to suppress the damage response caused by the preset stable structure in the damage response field in S4, and reconstruct the region based on the spatial continuity of the remaining damage response in the local coordinate domain of the rivet to obtain the damage area characterizing the damage location and damage range of the surface protective coating of the rivet area. S6. Determine the damage boundary based on the spatial distribution characteristics of the damaged area described in S5, and determine the recoating extension distance at the corresponding boundary position based on the identification uncertainty corresponding to the damage boundary. Extend the damaged area described in S5 according to the recoating extension distance to obtain a target recoating area that includes the damaged area and the corresponding protection margin area. S7. Based on the target recoating area described in S6 and the preset spray coverage response, determine at least the recoating control parameters including the recoating position and the recoating amount, and control the recoating execution mechanism to recoat the target recoating area according to the recoating control parameters; wherein, the preset spray coverage response is used to characterize the coating spatial coverage distribution formed by the recoating execution mechanism under different spray positions and different spray amounts.

2. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S1, acquiring multi-state images of the rivet area of ​​the metal cover to be detected under at least two different imaging states includes the following steps: S11, Position the iron cover to be detected in the image acquisition area, and keep the relative position of the iron cover to be detected and the image acquisition device unchanged; S12, under the condition that the relative position remains unchanged as described in S11, the lighting device is controlled to switch at least one paraxial lighting state and at least two oblique incident lighting states with different incident orientations in a preset sequence, and images of the rivet area are acquired in each imaging state respectively. S13, associate the images acquired in S12 under different imaging states according to the corresponding imaging states at the time of acquisition to obtain the multi-state image mentioned in S1, so that the same rivet surface position has a spatially corresponding image response under different imaging states.

3. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S2, determining the rivet center and reference direction based on the rivet geometric boundary in the multi-state image described in S1, establishing the rivet local coordinate domain, and registering and mapping the multi-state image described in S1 to the rivet local coordinate domain includes the following steps: S21, extract the rivet geometric boundary from at least one of the multi-state images in S1, determine the rivet center O and the feature radius R representing the rivet size according to the rivet geometric boundary, and determine the reference direction according to the preset stable structure on the iron cover; S22, taking the rivet center O mentioned in S21 as the origin of the coordinate system, convert each position within the rivet area into a local position represented by the normalized radial coordinate ρ and the circumferential angular coordinate θ; wherein, the normalized radial coordinate ρ is determined based on the distance from the corresponding position to the rivet center O and the feature radius R mentioned in S21, and the circumferential angular coordinate θ is determined based on the circumferential angle of the corresponding position relative to the reference direction mentioned in S21. S23, based on the rivet center O, feature radius R and reference direction described in S21, perform coordinate normalization and spatial registration on the multi-state images under different imaging states described in S1, and map the multi-state images to the rivet local coordinate domain described in S2 to obtain the corresponding local image responses under different imaging states.

4. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S3, establishing the normal multi-state reference response corresponding to the location to be detected based on the local image response described in S2 includes the following steps: S31, for the position to be detected in the local coordinate domain of the rivet described in S2, located at the target radial position, select multiple candidate reference positions distributed at different circumferential positions within a preset radial interval that includes the target radial position; S32, based on the pull ring position, rivet structure edge position and iron cover preset scribing position in the local coordinate domain of the rivet described in S2, candidate reference positions located in the pull ring occlusion area and the corresponding area of ​​the preset stable structure are excluded from the candidate reference positions described in S31, and multi-state response outliers are excluded based on the local image response of each candidate reference position under different imaging states, so as to obtain the effective reference position. S33, based on the local image response of the effective reference position in each imaging state as described in S32, determine the normal response benchmark for each imaging state corresponding to the radial position of the target; S34, combine the normal response benchmarks of each imaging state obtained in S33 according to the corresponding imaging state to obtain the normal multi-state reference response corresponding to the position to be detected in S3.

5. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 4, characterized in that, In step S4, determining the damage response value at the location to be detected based on the actual multi-state response and the normal multi-state reference response described in S3 includes the following steps: S41, based on the local image response described in S2, obtain the actual image response of the position to be detected in each imaging state, and compare the actual image response with the normal response benchmark of the corresponding imaging state in the normal multi-state reference response described in S3 to obtain the state amplitude abnormality quantity. S42, based on the actual image response of the position to be detected in at least two imaging states as described in S41, determine the actual response change between corresponding imaging states, and based on the normal multi-state reference response as described in S3, determine the normal response change between corresponding imaging states, and obtain the cross-state change anomaly amount based on the difference between the actual response change amount and the normal response change amount. S43, determine the actual multi-state response spatial change relationship between the location to be detected and its neighborhood location based on the local image response described in S2, and determine the corresponding normal multi-state response spatial change relationship based on the normal multi-state reference response described in S3, and obtain the spatial continuity anomaly quantity based on the difference between the two. S44, the abnormal state amplitude of S41, the abnormal cross-state change of S42, and the abnormal spatial continuity of S43 are fused to obtain the damage response value of the position to be detected in S4, and the damage response field of S4 is constructed according to the damage response value corresponding to each position to be detected in the local coordinate domain of the rivet.

6. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S5, processing and reconstructing the damage response field described in S4 using a structural mask to obtain the damage region includes the following steps: S51, determine the position of one or more preset stable structures among the rivet outer peripheral structure edge, pull ring structure edge and iron cover pre-made engraving line according to the rivet local coordinate domain described in S2, and establish a structural mask according to the position of the preset stable structure; S52, Spatially correspond the structural mask described in S51 with the damage response field described in S4, and suppress the damage response corresponding to the positions located within the structural mask and at distances less than a preset distance from the structural mask, to obtain the damage response field after structural response suppression. S53, based on the adjacency relationship of each position in the damage response field after the structural response is suppressed as described in S52, perform connectivity analysis, merge the positions whose damage response values ​​meet the preset damage judgment conditions and are continuously distributed in space, and obtain candidate damage regions. S54, based on one or more of the area, length, width and continuous length of the candidate damage area described in S53, discrete abnormal areas are excluded to obtain the damage area described in S5, which characterizes the location and extent of damage to the protective coating on the surface of the rivet area.

7. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S6, determining the target repainting area based on the spatial distribution characteristics of the damaged area and the uncertainty in identifying the damaged boundary as described in S5 includes the following steps: S61, determine the damage boundary based on the spatial distribution relationship between the damaged area and the non-damaged area as described in S5, and for each boundary position on the damage boundary, determine the identification uncertainty based on at least two of the following: the difference between the damage response value at the corresponding boundary position and the preset damage judgment condition, the consistency of damage judgment at the corresponding boundary position under different imaging states, and the damage response change gradient in the neighborhood of the corresponding boundary position. S62, determine the corresponding repainting extension distance based on the identification uncertainty of each boundary position obtained in S61, so that the repainting extension distance increases as the identification uncertainty of the corresponding boundary position increases; S63, based on the repainting extension distance corresponding to each boundary position obtained in S62, the damaged area described in S5 is extended non-equidistantly along different boundary positions, and the protection margin area formed by the extension is merged with the damaged area described in S5 to obtain the target repainting area described in S6.

8. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, In step S7, determining the recoating control parameters based on the target recoating area described in S6 and the preset spraying coverage response includes the following steps: S71, determine at least one candidate repainting location based on the spatial location and spatial range of the target repainting area described in S6, and determine multiple candidate repainting amounts for each candidate repainting location; S72, according to the candidate recoating position and candidate recoating amount described in S71, call the corresponding preset spraying coverage response to obtain the predicted coating coverage area corresponding to each candidate recoating position and candidate recoating amount; S73, compare the predicted coating coverage area obtained in S72 with the target recoating area described in S6, and determine the uncovered area within the target recoating area and the redundant coverage area outside the target recoating area; S74, with the constraint that the uncovered area described in S73 does not exceed a preset allowable range, the repainting position and repainting amount described in S77 are determined from the candidate repainting positions and candidate repainting amounts described in S71 based on the uncovered area and the redundant coverage area; wherein, the repainting amount is controlled by one or more of the following: spray valve opening time, spraying pressure, and number of sprays.

9. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 8, characterized in that, In step S7, determining the candidate repainting location based on the target repainting area described in S6 includes the following steps: S75, determine the spatial morphology of the damaged region based on one or more of the following: area, aspect ratio, main extension direction, radial span, circumferential span, and number of mutually separated damaged sub-regions. S76, when S75 determines that the damaged area is a concentrated damaged area, a candidate single-point repair position is determined according to the centroid of the target repair area in S6; when S75 determines that the damaged area is a slender damaged area extending along a preset direction, a plurality of candidate repair positions are determined according to the main extension direction. S77, when S75 determines that the damaged area is an arc-shaped damaged area distributed along the circumference of the rivet, multiple candidate repair positions arranged along the circumference of the rivet are determined according to the circumferential start position and circumferential end position corresponding to the damaged area. S78, when S75 determines that the damaged area includes multiple mutually separated damaged sub-regions, based on the spacing between different damaged sub-regions and the preset spraying coverage response described in S72, determine the corresponding candidate repainting position for each damaged sub-region or the corresponding candidate repainting position for multiple damaged sub-regions combined.

10. The method for identifying and repainting damaged areas of rivets on iron caps based on multi-state image difference reconstruction according to claim 1, characterized in that, The following steps are included after step S7: S8. Obtain the post-coating verification image corresponding to the rivet area after the recoating is completed according to the recoating control parameters described in S7, and identify the actual coating coverage area from the post-coating verification image. S9, compare the actual coating coverage area described in S8 with the target recoating area described in S6 in space to determine the remaining uncovered area in the target recoating area; When the remaining uncovered area exceeds the preset allowable range, the remaining uncovered area is used as the new area to be recoated, the recoating position and amount are re-determined, and the remaining uncovered area is recoated a second time according to the re-determined recoating position and amount. S10, establish a correspondence between the recoating control parameters described in S7 and the actual coating coverage area obtained in S8, update the preset spraying coverage response described in S7 according to the correspondence, and use the updated spraying coverage response to determine the recoating control parameters of the iron cover to be tested in the future.