Polishing visual guidance method, device and system for high-light surface defects
By projecting a line laser beam onto a high-brightness surface and combining it with camera intrinsic parameters and an optical testing system, secondary precise positioning of defects on the high-brightness surface was achieved, solving the problem of low grinding accuracy in existing technologies and improving the success rate and accuracy of grinding.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SPEEDBOT ROBOTICS CO LTD
- Filing Date
- 2024-01-12
- Publication Date
- 2026-05-29
AI Technical Summary
In the existing technology, the coordinates of high-gloss surface defects calculated based on the defect detection device have calibration errors, algorithm errors, and cumulative errors in the coordinate transfer process, resulting in low grinding accuracy.
By obtaining the initial coordinates of the defects in the high-gloss surface, a line laser beam is projected to obtain discrete points. The target coordinates of the defects are calculated based on the type of line laser beam and the discrete points. A secondary fine positioning is performed using a line or cross laser beam combined with camera intrinsic parameters and an optical testing system to improve the grinding accuracy.
It effectively eliminates potential problems during polishing, improves the success rate and accuracy of polishing, and especially enhances the ability to capture defects on high-gloss surfaces under natural light.
Smart Images

Figure CN117697630B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent technology in automobile body manufacturing, and in particular to a visually guided method, apparatus, system, computer-readable storage medium, and computer program product for polishing high-gloss surface defects. Background Technology
[0002] High-gloss surface polishing technology is used to polish and grind high-gloss surfaces to eliminate scratches, pits, and other surface defects, restoring their original luster and appearance. This technology typically mounts a polishing device to the end effector of a robotic arm. Based on data such as the spatial coordinates of the high-gloss surface defect calculated by a defect detection device, the positional relationship between the polishing equipment and the end effector of the robotic arm, and the posture of the robotic arm, the coordinates of the defect in the robotic arm's base coordinate system are calculated. The robotic arm then guides the polishing device to polish and grind the defect points on the high-gloss surface.
[0003] However, the defect coordinates calculated by the defect detection device are subject to calibration errors, algorithm errors, and cumulative errors during the coordinate transfer process. These errors often fail to meet the positioning accuracy requirements for grinding, resulting in low grinding accuracy for high-gloss surface defects. Summary of the Invention
[0004] Therefore, it is necessary to provide a visually guided method, apparatus, system, computer-readable storage medium, and computer program product for polishing high-gloss surface defects that can improve polishing accuracy, in order to address the above-mentioned technical problems.
[0005] Firstly, this application provides a visually guided method for polishing high-gloss surface defects. The method includes:
[0006] Obtain the initial coordinates of the defects in the highlighted surface;
[0007] Based on the initial coordinates, a line laser beam is projected onto the high-brightness surface to obtain discrete points corresponding to the line laser beam;
[0008] Based on the type of the line laser beam and the discrete points corresponding to the line laser beam, the target coordinates of the defect are obtained;
[0009] Based on the target coordinates of the defect, the defect is polished.
[0010] In one embodiment, obtaining the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam includes:
[0011] When the line laser beam includes a single-line laser beam, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point; wherein, the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after the special pattern is projected onto the high-brightness surface.
[0012] The target coordinates of the defect are obtained based on the perpendicular coordinates, the intrinsic parameters of the camera, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
[0013] In one embodiment, obtaining the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam includes:
[0014] When the line laser beam includes a crosshair laser beam, the ray vector corresponding to each point on the target fitting line is obtained based on the target fitting line corresponding to the discrete point and the camera optical center; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center;
[0015] The intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system is determined as the three-dimensional intersection point corresponding to each point on the target fitting line.
[0016] The nominal surface shape is obtained by fitting the three-dimensional intersection points corresponding to each point on the target fitted line;
[0017] The target coordinates of the defect are obtained by iterating the nominal surface shape using a software-configurable optical testing system.
[0018] In one embodiment, the method for obtaining the equation of the line laser beam plane in the camera coordinate system includes:
[0019] At least two sets of calibration images are preprocessed to obtain a preprocessed image corresponding to each set of calibration images; wherein, the at least two sets of calibration images refer to the images captured by the camera and projected onto the calibration plate in at least two poses;
[0020] The gray-scale centroid method is used to process the preprocessed image corresponding to each group of calibration images to obtain the discrete points corresponding to the line laser beam in each group of calibration images;
[0021] Based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images, the scaling factor in the camera projection process corresponding to each set of calibration images is obtained; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images.
[0022] Based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system are obtained.
[0023] Based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, the equation of the line laser beam plane in the camera coordinate system is obtained.
[0024] In one embodiment, the preprocessing of at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images includes:
[0025] Based on the camera's distortion parameters, each set of calibration images is subjected to distortion correction processing, and then grayscale and filtering processing is performed on each set of calibration images after distortion correction processing to obtain the preprocessed image corresponding to each set of calibration images.
[0026] In one embodiment, the method for obtaining the distortion parameters and intrinsic parameters of the camera includes:
[0027] At least two sets of calibration images are obtained based on images captured by a camera and projected onto a calibration plate in at least two poses.
[0028] Based on the at least two sets of calibration images, the distortion parameters and intrinsic parameters of the camera are obtained.
[0029] Secondly, this application also provides a visual guidance device for polishing high-gloss surface defects. The device includes:
[0030] The coordinate acquisition module is used to obtain the initial coordinates of defects in the highlighted surface;
[0031] The first processing module is used to project a line laser beam onto the high-brightness surface based on the initial coordinates and obtain discrete points corresponding to the line laser beam.
[0032] The second processing module is used to obtain the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam;
[0033] The grinding module is used to grind the defect based on the target coordinates of the defect.
[0034] Thirdly, this application also provides a visual guidance system for polishing high-gloss surface defects. The system includes:
[0035] A defect detection device, wherein the defect detection device is used to obtain the initial coordinates of defects in a bright surface;
[0036] A polishing guide device, the polishing guide device including a line laser emitter; the line laser emitter is used to project a line laser beam onto the high-brightness surface based on the initial coordinates;
[0037] The processor is configured to project a line laser beam onto the high-brightness surface based on the initial coordinates of the line laser emitter, obtain discrete points corresponding to the line laser beam, obtain target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam, and perform grinding processing on the defect based on the target coordinates of the defect.
[0038] In one embodiment, the polishing guide device further includes a display screen and a camera;
[0039] The display screen is used to project a special pattern onto the high-brightness surface, and the camera is used to capture a reflected image of the special pattern after it has been reflected by the high-brightness surface.
[0040] The processor is further configured to obtain reference coordinates of the defect based on the reflected image; when the line laser beam includes a line laser beam, obtain the perpendicular coordinates of the reference coordinates on the target fitting line based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point; and obtain the target coordinates of the defect based on the perpendicular coordinates, the intrinsic parameters of the camera, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
[0041] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, performs the following steps:
[0042] Obtain the initial coordinates of the defects in the highlighted surface;
[0043] Based on the initial coordinates, a line laser beam is projected onto the high-brightness surface to obtain discrete points corresponding to the line laser beam;
[0044] Based on the type of the line laser beam and the discrete points corresponding to the line laser beam, the target coordinates of the defect are obtained;
[0045] Based on the target coordinates of the defect, the defect is polished.
[0046] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, performs the following steps:
[0047] Obtain the initial coordinates of the defects in the highlighted surface;
[0048] Based on the initial coordinates, a line laser beam is projected onto the high-brightness surface to obtain discrete points corresponding to the line laser beam;
[0049] Based on the type of the line laser beam and the discrete points corresponding to the line laser beam, the target coordinates of the defect are obtained;
[0050] Based on the target coordinates of the defect, the defect is polished.
[0051] The aforementioned method, apparatus, system, storage medium, and computer program product for guiding the grinding of defects on high-gloss surfaces obtains the initial coordinates of the defects on the high-gloss surface. Based on these initial coordinates, a line laser beam is projected onto the high-gloss surface to obtain discrete points corresponding to the line laser beam. Then, based on the type of line laser beam and the corresponding discrete points, the target coordinates of the defects are obtained. The defects are then ground based on these target coordinates. Therefore, even when the initial coordinates of the defects calculated by the defect detection device contain calibration errors, algorithm errors, and cumulative errors during coordinate transfer, this application can perform secondary precise positioning of the defects based on their initial coordinates, eliminating potential grinding problems and improving the grinding success rate. Attached Figure Description
[0052] Figure 1 This is an application environment diagram of a visually guided method for polishing high-gloss surface defects in one embodiment;
[0053] Figure 2 This is a flowchart illustrating a visually guided method for polishing high-gloss surface defects in one embodiment.
[0054] Figure 3 This is a flowchart illustrating the process of obtaining the target coordinates of a defect based on the type of line laser beam and the discrete points corresponding to the line laser beam in one embodiment.
[0055] Figure 4 This is an application environment diagram of the visual guidance method for polishing high-gloss surface defects in another embodiment;
[0056] Figure 5 This is a three-dimensional structural schematic diagram of the polishing guide device in one embodiment;
[0057] Figure 6 A front view of the grinding guide device in another embodiment;
[0058] Figure 7This is a flowchart illustrating the process of obtaining the target coordinates of a defect based on the type of line laser beam and the discrete points corresponding to the line laser beam in another embodiment.
[0059] Figure 8 This is a schematic diagram illustrating the principle of obtaining the target coordinates of a defect based on the ray vector corresponding to each point on the target fitting line and the equation of the line laser beam plane in the camera coordinate system in one embodiment.
[0060] Figure 9 This is a flowchart illustrating how to obtain the equation of the line laser beam plane in the camera coordinate system in one embodiment;
[0061] Figure 10 This is a flowchart illustrating a visually guided method for polishing high-gloss surface defects in another embodiment.
[0062] Figure 11 This is a structural block diagram of a visual guidance device for polishing high-gloss surface defects in one embodiment. Detailed Implementation
[0063] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0064] The visual guidance method for polishing high-gloss surface defects provided in this application embodiment can be applied to, for example... Figure 1 In the application environment shown, the polishing visual guidance system 100 for high-gloss surface defects includes: a defect detection device 102, a polishing guidance device 104, and a processor 106. The defect detection device 102, the polishing guidance device 104, and the processor 106 communicate via a network.
[0065] The defect detection device 102 is used to obtain the initial coordinates of the defect in the high-gloss surface; the grinding guide device 104 includes a line laser emitter 1041, which is used to project a line laser beam onto the high-gloss surface based on the initial coordinates; the processor 106 is used to obtain the discrete points corresponding to the line laser beam based on the line laser beam projected onto the high-gloss surface by the line laser emitter 1041 based on the initial coordinates, and to obtain the target coordinates of the defect based on the type of line laser beam and the discrete points corresponding to the line laser beam, and to perform grinding processing on the defect based on the target coordinates of the defect.
[0066] In conjunction with the above, in one embodiment, such as Figure 2 As shown, a visually guided method for polishing high-gloss surface defects is provided, which is then applied to... Figure 1 Taking processor 106 as an example, the steps include:
[0067] S202, obtain the initial coordinates of the defects in the highlighted surface.
[0068] In this embodiment, combined with Figure 1 The initial coordinates of the defect are obtained by the defect detection device detecting the highlighted surface. In some embodiments, the defect detection device includes a 3D camera based on the phase deflection principle. Thus, the 3D camera can determine the initial coordinates of the defect by acquiring a high-precision three-dimensional point cloud of the highlighted surface. In some embodiments, the highlighted surface includes the paint surface of an automobile body, etc.
[0069] S204: Based on the initial coordinates, a line laser beam is projected onto the high-brightness surface to obtain the discrete points corresponding to the line laser beam.
[0070] In this embodiment, combined with Figure 1 The processor can send the initial coordinates of the defect to the grinding guide device, thereby controlling the line laser emitter to project a line laser beam within a preset range corresponding to the initial coordinates, so as to ensure that the defect is near the line laser beam.
[0071] In some embodiments, a reflected image of a line laser beam after being reflected by a bright surface is acquired by a camera. The reflected image is then processed based on the gray-scale centroid method to obtain discrete points corresponding to the line laser beam. Specifically, discrete points corresponding to the line laser beam are obtained based on the centroid positions of pixels in each row and each column of the reflected image. The number of discrete points is multiple.
[0072] It should be noted that the grayscale centroid method involved in this application can be replaced by other skeleton extraction algorithms to achieve the same or similar results, such as the Steger algorithm.
[0073] S206, based on the type of line laser beam and the discrete points corresponding to the line laser beam, obtains the target coordinates of the defect.
[0074] In this embodiment, the method of obtaining the target coordinates of the defect based on the discrete points corresponding to the line laser beam varies depending on the type of the line laser beam. The line laser beam can include a linear line laser beam or a crosshair laser beam.
[0075] In some embodiments, when the online laser beam includes a line laser beam, the target coordinates of the defect can be obtained based on the reference coordinates of the defect and the fitted straight line corresponding to the discrete points of the line laser beam. The reference coordinates of the defect are obtained from the reflected image of the special pattern after it has been reflected by the camera onto the bright surface. Specifically, the reference coordinates can be obtained by processing the reflected image using deep learning methods, and the reference coordinates can refer to two-dimensional coordinates.
[0076] In some embodiments, when the online laser beam includes a crosshair laser beam, the target coordinates of the defect can be obtained based on the discrete points corresponding to the online laser beam and the optical center of the camera.
[0077] S208, based on the target coordinates of the defect, performs grinding processing on the defect.
[0078] In some embodiments, combined with Figure 1 The visual guidance system 100 for polishing high-gloss surface defects also includes a polishing device disposed at the end of a robotic arm, thereby enabling the processor 106 to control the polishing head to polish the defect based on the target coordinates of the defect. The polishing device may include a polishing head or other types of devices for performing polishing processes.
[0079] In some embodiments, the robot arm posture is obtained based on the target coordinates of the defect, and then the processor guides the grinding device to perform grinding on the defect based on the robot arm posture. The method for obtaining the robot arm posture based on the target coordinates of the defect can be set according to the actual scenario, and this application does not impose specific limitations.
[0080] In summary, based on Figure 2 The method described herein obtains the initial coordinates of a defect in a high-brightness surface. Then, based on these initial coordinates, a line laser beam is projected onto the high-brightness surface, and a special pattern is projected onto the surface. This allows for the acquisition of discrete points corresponding to the line laser beam. Based on the type of line laser beam and the corresponding discrete points, the target coordinates of the defect are obtained. The defect is then polished based on these target coordinates. Therefore, even when the initial coordinates of the defect calculated by the defect detection device are subject to calibration errors, algorithm errors, and cumulative errors during coordinate transfer, this method can perform secondary precision positioning of the defect based on its initial coordinates, eliminating potential polishing problems and improving the polishing success rate.
[0081] In one embodiment, such as Figure 3 The diagram illustrates a process for obtaining the target coordinates of a defect based on the type of line laser beam and the corresponding discrete points. This method is then applied to… Figure 1 Taking processor 106 as an example, the steps include:
[0082] S302, when the line laser beam includes a single line laser beam, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained based on the reference coordinates of the defect and the target fitting line corresponding to the discrete points.
[0083] In one embodiment, combined Figure 1 ,like Figure 4As shown, the polishing guide device 104 may further include a display screen 402 and a camera 404. The display screen 402 is used to project a special pattern onto the high-gloss surface, and the camera 404 is used to capture a reflection image of the special pattern after it has been reflected by the high-gloss surface. The processor 106 is also used to obtain the reference coordinates of the defect based on the reflection image. Specifically, the processor 106 can process the reflection image using a deep learning method to obtain the reference coordinates, which may refer to two-dimensional coordinates.
[0084] In some embodiments, the visual guidance system 100 for polishing high-gloss surface defects further includes a bracket connector, and the display 402 includes a screen and a screen protective case. For example... Figure 5 As shown, a three-dimensional structural schematic diagram of a grinding guide device 104 is provided. Figure 5 Based on what is shown, as Figure 6 As shown, a front view of a polishing guide device 104 is provided, wherein, in Figure 5 and Figure 6 In the process, the polishing guide device 104 includes a camera 404, a line laser emitter 1041, a screen 502, a screen protective shell 504, and a bracket connector 506. The camera 404 and the line laser emitter 1041 are respectively mounted on their respective adjustment mechanisms, thereby enabling adjustment of the installation posture in six degrees of freedom. The adjustment mechanisms are mounted on the bracket connector 506 on the display screen.
[0085] It should be understood that the installation position and angle of the camera and line laser emitter need to be adjusted to ensure that the line laser can be projected within the imaging range of the camera, and that the camera optical axis and the line laser plane have a good angle.
[0086] In this embodiment, the perpendicular coordinates of the reference coordinates on the target fitted line can be obtained based on the reference coordinates of the defect and the coefficients corresponding to the target fitted line. Specifically, the target fitted line can be obtained by fitting discrete points corresponding to the line laser beam using a fitting algorithm. The fitting algorithm may include algorithms such as RANSAC.
[0087] For example, (u0, v0) represents the reference coordinates of the defect, (u1, v1) represents the perpendicular coordinates, and the target fitted line is expressed as: ax + by + c = 0. The coefficients of the target fitted line include a, b, and c. The reference coordinates, the coefficients of the target fitted line, and the perpendicular coordinates satisfy the following relationship: .
[0088] S304, based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system, obtains the target coordinates of the defect.
[0089] Specifically, the dimension value corresponding to the perpendicular foot coordinate is obtained based on the coefficients of the equation corresponding to the line laser beam plane in the camera coordinate system, and the camera's intrinsic parameters. The target coordinates of the defect are obtained based on the dimension value corresponding to the perpendicular foot coordinate, the camera's intrinsic parameters, and the reference coordinates. The camera's intrinsic parameters are obtained by calibrating the camera using the Zhang Zhengyou calibration method, combined with at least two sets of calibration images.
[0090] For example, (u0, v0) represents the reference coordinates of the defect, (u1, v1) represents the perpendicular coordinates, Z represents the dimension value corresponding to the perpendicular coordinates, and f x f y c x c y This refers to the camera's intrinsic parameters, i.e., f. x and f y c represents focal length. x and c y Indicates the position of the optical center, A, B, C, and D represent the coefficients of the equation corresponding to the line laser beam plane in the camera coordinate system, and P c The target coordinates of the defect are then... , .
[0091] In summary, based on Figure 3 The method shown can obtain the target coordinates of the defect. Based on the target coordinates of the defect, the defect is polished. Thus, even when there are calibration errors, algorithm errors, and cumulative errors in the coordinate transfer process, the initial coordinates of the defect calculated by the defect detection device can be used to perform secondary fine positioning of the defect based on the initial coordinates of the defect, thereby eliminating potential polishing problems and improving the polishing success rate.
[0092] In one embodiment, such as Figure 7 The diagram illustrates a process for obtaining the target coordinates of a defect based on the type of line laser beam and the corresponding discrete points. This method is then applied to… Figure 1 Taking processor 106 as an example, the steps include:
[0093] S702, when the line laser beam includes a crosshair laser beam, based on the target fitting line corresponding to the discrete point and the camera optical center, obtain the ray vector corresponding to each point on the target fitting line; where the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center.
[0094] In this embodiment, a fitting algorithm can be used to fit the discrete points corresponding to the line laser beam to obtain the target fitted line. The fitting algorithm may include the RANSAC algorithm, etc.
[0095] S704, the intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system is determined as the three-dimensional intersection point corresponding to each point on the target fitting line.
[0096] S706, fits the three-dimensional intersection points corresponding to each point on the target fitting line to obtain the nominal surface shape.
[0097] S708 uses a software-configurable optical testing system to iterate the nominal surface shape and obtain the target coordinates of the defect.
[0098] In this embodiment, the plane after the three-dimensional intersection of each point on the fitted target line is the nominal surface shape of monocular deflection. By iterating the nominal surface shape based on the Software Configurable Optical Test System (SCOTS), the target coordinates of the defect and the normal vector corresponding to the target coordinates can be obtained. Here, the target coordinates can refer to three-dimensional coordinates.
[0099] like Figure 8 As shown, a schematic diagram is provided to obtain the target coordinates of the defect based on the ray vector corresponding to each point on the target fitting line and the equation of the line laser beam plane in the camera coordinate system. In this diagram, after each point on the target fitting line 802 is connected to the camera optical center 804 and extended to the plane 806 where the equation of the line laser beam plane in the camera coordinate system is located, the three-dimensional intersection point P corresponding to each point on the target fitting line 802 will be obtained.
[0100] In summary, based on Figure 8 The method shown can obtain the target coordinates of the defect. Based on the target coordinates of the defect, the defect is polished. Thus, even when there are calibration errors, algorithm errors, and cumulative errors in the coordinate transfer process, the initial coordinates of the defect calculated by the defect detection device can be used to perform secondary fine positioning of the defect based on the initial coordinates of the defect, thereby eliminating potential polishing problems and improving the polishing success rate.
[0101] In one embodiment, such as Figure 9 The diagram illustrates a process for obtaining the equation of the line laser beam plane in the camera coordinate system, and how this method can be applied to... Figure 1 Taking processor 106 as an example, the steps include:
[0102] S902, preprocess at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images.
[0103] In this embodiment, at least two sets of calibration images refer to images captured by the camera and projected onto calibration plates in at least two poses. Specifically, each set of calibration images can be dedistorted based on the camera's distortion parameters, and each set of calibration images after distortion can be grayscaled and filtered to obtain a preprocessed image corresponding to each set of calibration images.
[0104] By applying distortion correction to each set of calibration images using the camera's distortion parameters, the complexity of the coordinate mapping calculation process can be reduced. Further grayscale and filtering of the distorted calibration images enhances the contrast of the line laser beam and reduces noise. Therefore, based on the pre-processed images corresponding to each set of calibration images, the accuracy of obtaining the equation of the line laser beam plane in the camera coordinate system can be improved, thereby increasing the accuracy of obtaining the target coordinates of the defect and ultimately improving the grinding accuracy. The camera distortion parameters refer to the distortion parameters of the camera after calibration.
[0105] S904 uses the gray-scale centroid method to process the preprocessed image corresponding to each set of calibration images to obtain the discrete points corresponding to the line laser beam in each set of calibration images.
[0106] In some embodiments, the preprocessed image corresponding to each set of calibration images can be processed based on the gray-scale centroid method to obtain discrete points corresponding to the line laser beam in each set of calibration images. Specifically, the discrete points corresponding to the line laser beam in each set of calibration images are obtained based on the centroid positions of each row of pixels and each column of pixels in the preprocessed image corresponding to each set of calibration images.
[0107] S906, based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images, obtains the scaling factor in the camera projection process corresponding to each set of calibration images; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images.
[0108] In some embodiments, the discrete points corresponding to the line laser beam in each set of calibration images can be fitted based on the RANSAC algorithm to obtain the calibration fitting line corresponding to each set of calibration images.
[0109] In some embodiments, the Zhang Zhengyou calibration method is used to calibrate the camera by combining at least two sets of calibration images, which can obtain the camera's intrinsic parameters and distortion coefficients, as well as the camera's extrinsic parameters corresponding to each set of calibration images.
[0110] For example, (u,v) represents the pixel coordinates of a point on the calibration fitting line, r ijLet r represent the elements in the rotation matrix, i = 1, 2, 3, j = 1, 2, 3. When i = 1, j = 1, r 11 This represents the element in the first row and first column of the rotation matrix. s t1 represents the element in the translation matrix, where s = 1, 2, 3. When s = 1, t1 represents the first element of the translation matrix; f x f y c x c y P is the intrinsic parameter of the camera, λ represents the scaling factor during camera projection, and P is the intrinsic parameter of the camera. s Let represent the three-dimensional coordinates of a point on the calibration fitted line in the camera coordinate system. , where X w and Y w This represents the physical coordinates of a point on the calibration fitted line in the world coordinate system, where the world coordinate system is established on the calibration plate corresponding to each set of calibration images.
[0111] S908 obtains the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system based on the scaling factor during the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters.
[0112] For example, (u,v) represents the pixel coordinates of a point on the calibration fitting line, f x f y c x c y P is the intrinsic parameter of the camera, λ represents the scaling factor during camera projection, and P is the intrinsic parameter of the camera. s Let represent the three-dimensional coordinates of a point on the calibration fitted line in the camera coordinate system. .
[0113] S910, based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, obtains the equation of the line laser beam plane in the camera coordinate system.
[0114] Specifically, a fitting algorithm can be used to fit the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, thereby obtaining the equation of the line laser beam plane in the camera coordinate system. For example, if the equation of the line laser beam plane in the camera coordinate system is expressed as Ax+By+Cz+D=0, then the coefficients of this equation include A, B, C, and D.
[0115] It should be noted that, Figure 9The equation for the line laser beam plane in the camera coordinate system is derived from a calibration image captured when the line laser emitter projects a single line laser beam; there is one equation. When the line laser beam projects a crosshair laser beam, there are two equations.
[0116] In some embodiments, the method of obtaining the camera's distortion parameters and intrinsic parameters includes: obtaining at least two sets of calibration images based on images captured by the camera of a line laser beam projected onto a calibration plate in at least two poses, and obtaining the camera's distortion parameters and intrinsic parameters based on the at least two sets of calibration images.
[0117] The camera and line laser emitter can be fixedly mounted, and the calibration plate pose can be continuously changed (e.g., at least two poses) to ensure that the line laser is projected onto the calibration plate. The camera is then used to capture an image of the line laser beam on the calibration plate to obtain a calibration image.
[0118] Specifically, by using Zhang Zhengyou's calibration method and combining at least two sets of calibration images to calibrate the camera, we can obtain the camera's intrinsic parameters and distortion coefficients, as well as the camera's extrinsic parameters corresponding to each set of calibration images.
[0119] In conjunction with the above, in one embodiment, such as Figure 10 As shown, a visually guided method for polishing high-gloss surface defects is provided, which is then applied to... Figure 1 Taking processor 106 as an example, the steps include:
[0120] S1002, based on the images of the line laser beam projected onto the calibration plate at least two poses captured by the camera, obtain at least two sets of calibration images; using the Zhang Zhengyou calibration method, based on the at least two sets of calibration images, obtain the camera's distortion parameters, intrinsic parameters, and camera extrinsic parameters corresponding to each set of calibration images.
[0121] S1004, based on the camera's distortion parameters, performs distortion correction processing on each set of calibration images, and performs grayscale processing and filtering processing on each set of calibration images after distortion correction processing to obtain the preprocessed image corresponding to each set of calibration images; the grayscale centroid method is used to process the preprocessed image corresponding to each set of calibration images to obtain the discrete points corresponding to the line laser beam in each set of calibration images.
[0122] S1006, based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images, the scaling factor in the camera projection process corresponding to each set of calibration images is obtained; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images.
[0123] S1008: Based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, obtain the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system; based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, obtain the equation of the line laser beam plane in the camera coordinate system.
[0124] S1010: Obtain the initial coordinates of the defects in the bright surface; based on the initial coordinates, project a line laser beam onto the bright surface to obtain the discrete points corresponding to the line laser beam.
[0125] Among them, when the type of online laser beam is different, the way to obtain the target coordinates of the defect based on the discrete points corresponding to the online laser beam is also different, specifically: S1012 or S1014.
[0126] S1012, when the line laser beam includes a single line laser beam, based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained; based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system, the target coordinates of the defect are obtained.
[0127] S1014, when the line laser beam includes a crosshair laser beam, based on the target fitting line corresponding to the discrete points and the camera optical center, obtain the ray vector corresponding to each point on the target fitting line. The ray vector corresponding to each point refers to the vector represented by the line connecting each point to the camera optical center. The intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system is determined as the three-dimensional intersection point corresponding to each point on the target fitting line. Fit the three-dimensional intersection point corresponding to each point on the target fitting line to obtain the nominal surface shape. Based on the software-configurable optical testing system, iterate the nominal surface shape to obtain the target coordinates of the defect.
[0128] S1016, based on the target coordinates of the defect, perform grinding processing on the defect.
[0129] The specific content of S1002-S1016 can be found in the aforementioned description and will not be repeated here.
[0130] It should be understood that the defect coordinates calculated based on the defect detection device often suffer from calibration errors, algorithm errors, and cumulative errors during coordinate transfer, which frequently fail to meet the positioning accuracy requirements for grinding. The method provided in this application can perform secondary fine positioning of defects, eliminating potential grinding risks and improving grinding success rate and accuracy. Furthermore, in natural light environments where cameras struggle to capture defects on bright surfaces, this application uses a display screen as a light source to project a special pattern onto the bright surface, enabling the camera to capture defect information and improving grinding accuracy. The line laser emitter used in this application assists the camera in positioning and can be replaced by other sensors (such as structured light emitters) to achieve the same or similar effects, but the replacement cost will increase. The camera in this application may include a 2D camera as the primary sensor, which can be replaced by other sensors (such as depth cameras, binocular cameras, or structured light cameras) to achieve the same or similar effects, but the replacement cost will increase.
[0131] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.
[0132] Based on the same inventive concept, this application also provides a visual guidance device for polishing high-gloss surface defects to implement the above-mentioned visual guidance method for polishing high-gloss surface defects. The solution provided by this device is similar to the solution described in the above method. Therefore, the specific limitations of one or more embodiments of the visual guidance device for polishing high-gloss surface defects provided below can be found in the limitations of the visual guidance method for polishing high-gloss surface defects described above, and will not be repeated here.
[0133] In one embodiment, such as Figure 11 As shown, a visual guidance device for polishing high-gloss surface defects is provided, comprising: a coordinate acquisition module 1102, a first processing module 1104, a second processing module 1106, and a polishing module 1108, wherein:
[0134] The coordinate acquisition module 1102 is used to obtain the initial coordinates of defects in the highlighted surface.
[0135] The first processing module 1104 is used to project a line laser beam onto a bright surface based on initial coordinates and obtain discrete points corresponding to the line laser beam.
[0136] The second processing module 1106 is used to obtain the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam.
[0137] The grinding module 1108 is used to grind defects based on the target coordinates of the defects.
[0138] In one embodiment, the second processing module 1106 is further configured to: when the line laser beam includes a line laser beam, obtain the perpendicular coordinates of the reference coordinates on the target fitting line based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point; wherein the reference coordinates are obtained based on the reflection image of the special pattern after the special pattern is reflected by the camera after being projected onto the bright surface; and obtain the target coordinates of the defect based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
[0139] In one embodiment, the second processing module 1106 is further configured to: when the line laser beam includes a crosshair laser beam, obtain the ray vector corresponding to each point on the target fitting line based on the target fitting line corresponding to the discrete point and the camera optical center; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center; determine the intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system as the three-dimensional intersection point corresponding to each point on the target fitting line; fit the three-dimensional intersection point corresponding to each point on the target fitting line to obtain the nominal surface shape; and obtain the target coordinates of the defect by iterating the nominal surface shape based on the software configurable optical testing system.
[0140] In one embodiment, the second processing module 1106 is further configured to: preprocess at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images; wherein, the at least two sets of calibration images refer to images captured by a camera and projected onto a calibration board at least two poses; process the preprocessed image corresponding to each set of calibration images using the gray-scale centroid method to obtain discrete points corresponding to the line laser beam in each set of calibration images; and obtain the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images, based on the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images. The scaling factor in the camera projection process corresponding to the calibration image is used; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on the discrete points corresponding to the line laser beam in each set of calibration images; based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system are obtained; based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, the equation of the line laser beam plane in the camera coordinate system is obtained.
[0141] In one embodiment, the second processing module 1106 is further configured to: perform distortion correction processing on each set of calibration images based on the distortion parameters of the camera, and perform grayscale processing and filtering processing on each set of calibration images after distortion correction processing to obtain a preprocessed image corresponding to each set of calibration images.
[0142] In one embodiment, the second processing module 1106 is further configured to: obtain at least two sets of calibration images based on images captured by the camera and projected onto calibration plates in at least two poses; and obtain camera distortion parameters and intrinsic parameters based on the at least two sets of calibration images.
[0143] Each module in the aforementioned visual guidance device for polishing high-gloss surface defects can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of the visual guidance system for polishing high-gloss surface defects in hardware form, or stored in the memory of the system in software form, so that the processor can call and execute the corresponding operations of each module.
[0144] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor:
[0145] Obtain the initial coordinates of the defect in the high-brightness surface; project a line laser beam onto the high-brightness surface based on the initial coordinates to obtain the discrete points corresponding to the line laser beam; obtain the target coordinates of the defect based on the type of line laser beam and the discrete points corresponding to the line laser beam; and perform grinding on the defect based on the target coordinates of the defect.
[0146] In one embodiment, when the computer program is executed by the processor, it further implements the following steps: when the line laser beam includes a line laser beam, based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained; wherein, the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after being projected onto the high-brightness surface; the target coordinates of the defect are obtained based on the perpendicular coordinates, the intrinsic parameters of the camera, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
[0147] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: when the line laser beam includes a crosshair laser beam, based on the target fitting line corresponding to the discrete point and the camera optical center, obtain the ray vector corresponding to each point on the target fitting line; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center; determine the intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system as the three-dimensional intersection point corresponding to each point on the target fitting line; fit the three-dimensional intersection point corresponding to each point on the target fitting line to obtain the nominal surface shape; iterate the nominal surface shape based on the software-configurable optical testing system to obtain the target coordinates of the defect.
[0148] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: preprocessing at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images; wherein, the at least two sets of calibration images refer to images of a line laser beam projected onto a calibration board at at least two poses, captured by a camera; processing the preprocessed image corresponding to each set of calibration images using the gray-scale centroid method to obtain discrete points corresponding to the line laser beam in each set of calibration images; and obtaining each set of calibration images based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters. The scaling factor in the camera projection process corresponding to the calibration images; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images; based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system are obtained; based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, the equation of the line laser beam plane in the camera coordinate system is obtained.
[0149] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: performing distortion correction processing on each set of calibration images based on the distortion parameters of the camera, and performing grayscale processing and filtering processing on each set of calibration images after distortion correction processing to obtain a preprocessed image corresponding to each set of calibration images.
[0150] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: obtaining at least two sets of calibration images based on images of a line laser beam projected onto a calibration plate in at least two poses captured by a camera; and obtaining the camera's distortion parameters and intrinsic parameters based on the at least two sets of calibration images.
[0151] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, performs the following steps:
[0152] Obtain the initial coordinates of the defect in the high-brightness surface; project a line laser beam onto the high-brightness surface based on the initial coordinates to obtain the discrete points corresponding to the line laser beam; obtain the target coordinates of the defect based on the type of line laser beam and the discrete points corresponding to the line laser beam; and perform grinding on the defect based on the target coordinates of the defect.
[0153] In one embodiment, when the computer program is executed by the processor, it further implements the following steps: when the line laser beam includes a line laser beam, based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained; wherein, the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after being projected onto the high-brightness surface; the target coordinates of the defect are obtained based on the perpendicular coordinates, the intrinsic parameters of the camera, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
[0154] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: when the line laser beam includes a crosshair laser beam, based on the target fitting line corresponding to the discrete point and the camera optical center, obtain the ray vector corresponding to each point on the target fitting line; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center; determine the intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system as the three-dimensional intersection point corresponding to each point on the target fitting line; fit the three-dimensional intersection point corresponding to each point on the target fitting line to obtain the nominal surface shape; iterate the nominal surface shape based on the software-configurable optical testing system to obtain the target coordinates of the defect.
[0155] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: preprocessing at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images; wherein, the at least two sets of calibration images refer to images of a line laser beam projected onto a calibration board at at least two poses, captured by a camera; processing the preprocessed image corresponding to each set of calibration images using the gray-scale centroid method to obtain discrete points corresponding to the line laser beam in each set of calibration images; and obtaining each set of calibration images based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters. The scaling factor in the camera projection process corresponding to the calibration images; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images; based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system are obtained; based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, the equation of the line laser beam plane in the camera coordinate system is obtained.
[0156] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: performing distortion correction processing on each set of calibration images based on the distortion parameters of the camera, and performing grayscale processing and filtering processing on each set of calibration images after distortion correction processing to obtain a preprocessed image corresponding to each set of calibration images.
[0157] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: obtaining at least two sets of calibration images based on images of a line laser beam projected onto a calibration plate in at least two poses captured by a camera; and obtaining the camera's distortion parameters and intrinsic parameters based on the at least two sets of calibration images.
[0158] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.
[0159] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0160] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A visually guided method for polishing high-gloss surface defects, characterized in that, The method includes: Obtain the initial coordinates of the defects in the highlighted surface; Based on the initial coordinates, a line laser beam is projected onto the high-brightness surface to obtain discrete points corresponding to the line laser beam; Based on the type of the line laser beam and the discrete points corresponding to the line laser beam, the target coordinates of the defect are obtained; Based on the target coordinates of the defect, the defect is polished. The step of obtaining the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam includes: When the line laser beam includes a single-line laser beam, the perpendicular coordinates of the reference coordinates on the target fitting line are obtained based on the reference coordinates of the defect and the target fitting line corresponding to the discrete point; wherein, the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after the special pattern is projected onto the high-brightness surface. Based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system, the target coordinates of the defect are obtained.
2. The method according to claim 1, characterized in that, The method further includes: When the line laser beam includes a crosshair laser beam, the ray vector corresponding to each point on the target fitting line is obtained based on the target fitting line corresponding to the discrete point and the camera optical center; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center; The intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system is determined as the three-dimensional intersection point corresponding to each point on the target fitting line. The nominal surface shape is obtained by fitting the three-dimensional intersection points corresponding to each point on the target fitted line; The target coordinates of the defect are obtained by iterating the nominal surface shape using a software-configurable optical testing system.
3. The method according to claim 1 or 2, characterized in that, The methods for obtaining the equation of the line laser beam plane in the camera coordinate system include: At least two sets of calibration images are preprocessed to obtain a preprocessed image corresponding to each set of calibration images; wherein, the at least two sets of calibration images refer to the images captured by the camera and projected onto the calibration plate in at least two poses; The gray-scale centroid method is used to process the preprocessed image corresponding to each group of calibration images to obtain the discrete points corresponding to the line laser beam in each group of calibration images; Based on the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, the camera's intrinsic parameters, and the rotation and translation matrices in the camera's extrinsic parameters corresponding to each set of calibration images, the scaling factor in the camera projection process corresponding to each set of calibration images is obtained; wherein, the calibration fitting line corresponding to each set of calibration images is obtained based on fitting the discrete points corresponding to the line laser beam in each set of calibration images. Based on the scaling factor in the camera projection process corresponding to each set of calibration images, the pixel coordinates of each point on the calibration fitting line corresponding to each set of calibration images, and the camera's intrinsic parameters, the three-dimensional coordinates of each point on the calibration fitting line corresponding to each set of calibration images in the camera coordinate system are obtained. Based on the three-dimensional coordinates of each point on the calibration fitting line corresponding to at least two sets of calibration images in the camera coordinate system, the equation of the line laser beam plane in the camera coordinate system is obtained.
4. The method according to claim 3, characterized in that, The step of preprocessing at least two sets of calibration images to obtain a preprocessed image corresponding to each set of calibration images includes: Based on the camera's distortion parameters, each set of calibration images is subjected to distortion correction processing, and then grayscale and filtering processing is performed on each set of calibration images after distortion correction processing to obtain the preprocessed image corresponding to each set of calibration images.
5. The method according to claim 4, characterized in that, The methods for obtaining the distortion parameters and intrinsic parameters of the camera include: At least two sets of calibration images are obtained based on images captured by a camera and projected onto a calibration plate in at least two poses. Based on the at least two sets of calibration images, the distortion parameters and intrinsic parameters of the camera are obtained.
6. A visual guidance device for polishing high-gloss surface defects, characterized in that, The device includes: The coordinate acquisition module is used to obtain the initial coordinates of defects in the highlighted surface; The first processing module is used to project a line laser beam onto the high-brightness surface based on the initial coordinates and obtain discrete points corresponding to the line laser beam. The second processing module is used to obtain the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam; A grinding module is used to grind the defect based on the target coordinates of the defect; The second processing module is further configured to, when the line laser beam includes a linear line laser beam, obtain the perpendicular coordinates of the reference coordinates on the target fitted line based on the reference coordinates of the defect and the target fitted line corresponding to the discrete point; wherein the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after being projected onto the high-brightness surface; and obtain the target coordinates of the defect based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
7. The apparatus according to claim 6, characterized in that, The second processing module is further configured to: When the line laser beam includes a crosshair laser beam, the ray vector corresponding to each point on the target fitting line is obtained based on the target fitting line corresponding to the discrete point and the camera optical center; wherein, the ray vector corresponding to each point refers to the vector represented by the line connecting each point and the camera optical center; The intersection point between the ray vector corresponding to each point on the target fitting line and the plane containing the equation of the line laser beam plane in the camera coordinate system is determined as the three-dimensional intersection point corresponding to each point on the target fitting line. The nominal surface shape is obtained by fitting the three-dimensional intersection points corresponding to each point on the target fitted line; The target coordinates of the defect are obtained by iterating the nominal surface shape using a software-configurable optical testing system.
8. A visual guidance system for polishing high-gloss surface defects, characterized in that, The system includes: A defect detection device, wherein the defect detection device is used to obtain the initial coordinates of defects in a bright surface; A polishing guide device, the polishing guide device including a line laser emitter, the line laser emitter being used to project a line laser beam onto the high-brightness surface based on the initial coordinates; The processor is configured to obtain discrete points corresponding to the line laser beam projected by the line laser emitter onto the high-brightness surface based on the initial coordinates, and to obtain the target coordinates of the defect based on the type of the line laser beam and the discrete points corresponding to the line laser beam, and to perform grinding processing on the defect based on the target coordinates of the defect. The processor is further configured to, when the line laser beam includes a linear line laser beam, obtain the perpendicular coordinates of the reference coordinates on the target fitted line based on the reference coordinates of the defect and the target fitted line corresponding to the discrete point; wherein the reference coordinates are obtained based on the reflection image of the special pattern after it is reflected by the high-brightness surface after being projected onto the high-brightness surface by the camera; and obtain the target coordinates of the defect based on the perpendicular coordinates, the camera's intrinsic parameters, and the coefficients corresponding to the equation of the line laser beam plane in the camera coordinate system.
9. The system according to claim 8, characterized in that, The polishing guide device also includes a display screen and a camera; The display screen is used to project a special pattern onto the high-brightness surface, and the camera is used to capture a reflected image of the special pattern after it has been reflected by the high-brightness surface.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.