Methods, devices, computer equipment and media for detecting defects in vehicle paint
By acquiring the relative positional relationship between the defect detection camera and the vehicle body, and the relative positional relationship between the production line and the vehicle body, image fusion and deep learning algorithms are used to detect defects in the vehicle body paint surface. This solves the problem of traditional inspection relying on worker experience and achieves efficient and accurate inspection results.
Patent Information
- Application Number
- CN202411183560.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-27
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2044-08-27
AI Technical Summary
Traditional vehicle paint defect detection relies on worker experience, resulting in low accuracy and efficiency.
By acquiring the relative positional relationship between the defect detection camera and the vehicle body, and the relative positional relationship between the production line and the vehicle body, image fusion and deep learning algorithms are used to detect paint defects. Combined with camera optical models and ray tracing technology, the defect location is mapped from the camera coordinate system to the vehicle body coordinate system and finally onto the vehicle body on the production line.
It achieves efficient and accurate paint defect detection, reduces hardware costs and dependence on environmental factors, and improves detection accuracy and efficiency.
Smart Images

Figure CN119086562B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of defect detection technology, and in particular to a method, apparatus, computer equipment, storage medium and computer program product for detecting defects in vehicle body paint. Background Technology
[0002] The aesthetic appeal of a car's paint finish is a crucial component of automotive quality control and brand marketing. However, various defects are unavoidable during the painting process. Generally, automakers inspect and repair these defects in the painted surface after the painting process, and the effectiveness of these repairs directly impacts the final appearance quality of the vehicle.
[0003] In traditional technology, the inspection of paint defects on most production lines is done by workers. Workers check for surface defects by sight and touch, and then repair them using polishing tools in subsequent operations.
[0004] While the aforementioned traditional methods can detect and repair defects in vehicle paint, the effectiveness of detection and repair depends on the worker's experience and working conditions, resulting in low accuracy and efficiency. Summary of the Invention
[0005] Therefore, it is necessary to provide an efficient and accurate method, device, computer equipment, storage medium, and computer program product for detecting defects in vehicle body paint, addressing the aforementioned technical problems.
[0006] Firstly, this application provides a method for detecting defects in vehicle body paint. The method includes:
[0007] Obtain the digital model of the vehicle body;
[0008] Obtain the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body;
[0009] Paint defects are detected based on the production line vehicle images captured by the defect detection camera, and the location of the paint defects in the camera coordinate system is obtained.
[0010] Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the vehicle body digital model, thus obtaining the position of the paint defect in the vehicle body coordinate system.
[0011] Based on the relative positional relationship between the production line and the vehicle body, the location of paint defects in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection results of the vehicle body on the production line.
[0012] In one embodiment, obtaining the relative positional relationship between the defect detection camera and the vehicle body includes:
[0013] Acquire feature points of the calibration vehicle body captured by the defect detection camera, wherein the location of the feature points on the calibration vehicle body is known;
[0014] The positional relationship between the feature points and the defect detection camera is obtained through camera optical modeling and ray tracing processing.
[0015] Based on the position of the feature point on the calibrated vehicle body and the positional relationship between the feature point and the defect detection camera, the relative positional relationship between the defect detection camera and the vehicle body is obtained.
[0016] In one embodiment, the step of detecting paint defects based on the production line vehicle body image acquired by the defect detection camera to obtain the location of the paint defect in the camera coordinate system includes:
[0017] Acquire the production line vehicle body image captured by the defect detection camera;
[0018] Based on the vehicle body images from the production line, image fusion and deep learning algorithms are used to detect paint defects and obtain the location of paint defects in the camera coordinate system.
[0019] In one embodiment, the step of detecting paint defects using image fusion and deep learning algorithms based on the production line vehicle images to obtain the location of paint defects in the camera coordinate system includes:
[0020] Select the production line vehicle body images acquired at adjacent time intervals;
[0021] The selected vehicle body image is processed using an image fusion algorithm to enhance defects, resulting in a fused image.
[0022] The fused image is input into a trained deep learning model for paint defect detection to obtain the location of the paint defect in the camera coordinate system.
[0023] In one embodiment, obtaining the vehicle body digital model includes:
[0024] Acquire vehicle exterior shape mapping data;
[0025] A digital model of the vehicle body is constructed based on the aforementioned vehicle body exterior morphology mapping data.
[0026] In one embodiment, after mapping the paint defect location in the vehicle body coordinate system to the vehicle body on the production line based on the relative positional relationship between the production line and the vehicle body, and obtaining the paint defect detection result of the vehicle body on the production line, the method further includes:
[0027] The paint defect detection results of the production line vehicle body are sent to the paint defect repair device.
[0028] In one embodiment, the production line body images include multiple 2D production line body images acquired consecutively over time.
[0029] Secondly, this application also provides a vehicle body paint defect detection device. The device includes:
[0030] The digital model acquisition module is used to acquire the digital model of the vehicle body;
[0031] The relative position relationship acquisition module is used to acquire the relative position relationship between the defect detection camera and the vehicle body, as well as the relative position relationship between the production line and the vehicle body;
[0032] The defect detection module is used to detect paint defects based on the production line vehicle images captured by the defect detection camera, and obtain the location of the paint defects in the camera coordinate system.
[0033] The first mapping module is used to locate the position of the paint defect in the camera coordinate system to the digital model of the vehicle body based on the relative position relationship between the defect detection camera and the vehicle body, so as to obtain the position of the paint defect in the vehicle body coordinate system.
[0034] The second mapping module is used to map the position of the paint defect in the vehicle body coordinate system to the vehicle body on the production line according to the relative positional relationship between the production line and the vehicle body, so as to obtain the paint defect detection result of the vehicle body on the production line.
[0035] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to perform the following steps:
[0036] Obtain the digital model of the vehicle body;
[0037] Obtain the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body;
[0038] Paint defects are detected based on the production line vehicle images captured by the defect detection camera, and the location of the paint defects in the camera coordinate system is obtained.
[0039] Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the vehicle body digital model, thus obtaining the position of the paint defect in the vehicle body coordinate system.
[0040] Based on the relative positional relationship between the production line and the vehicle body, the location of paint defects in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection results of the vehicle body on the production line.
[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 digital model of the vehicle body;
[0043] Obtain the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body;
[0044] Paint defects are detected based on the production line vehicle images captured by the defect detection camera, and the location of the paint defects in the camera coordinate system is obtained.
[0045] Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the vehicle body digital model, thus obtaining the position of the paint defect in the vehicle body coordinate system.
[0046] Based on the relative positional relationship between the production line and the vehicle body, the location of paint defects in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection results of the vehicle body on the production line.
[0047] 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:
[0048] Obtain the digital model of the vehicle body;
[0049] Obtain the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body;
[0050] Paint defects are detected based on the production line vehicle images captured by the defect detection camera, and the location of the paint defects in the camera coordinate system is obtained.
[0051] Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the vehicle body digital model, thus obtaining the position of the paint defect in the vehicle body coordinate system.
[0052] Based on the relative positional relationship between the production line and the vehicle body, the location of paint defects in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection results of the vehicle body on the production line.
[0053] The aforementioned method, apparatus, computer equipment, storage medium, and computer program for detecting paint defects on a vehicle body acquire a digital model of the vehicle body; acquire the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body; perform paint defect detection based on the vehicle body images acquired by the defect detection camera on the production line, obtaining the position of the paint defect in the camera coordinate system; based on the relative positional relationship between the defect detection camera and the vehicle body, locate the position of the paint defect in the camera coordinate system onto the digital model of the vehicle body, obtaining the position of the paint defect in the vehicle body coordinate system; based on the relative positional relationship between the production line and the vehicle body, map the position of the paint defect in the vehicle body coordinate system onto the vehicle body on the production line, obtaining the paint defect detection result of the vehicle body on the production line. Throughout this process, the mapping of the paint defect position in the camera coordinate system to the vehicle body on the production line, based on the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body, eliminates the need for complex 3D reconstruction, significantly improving the efficiency of paint defect detection. Therefore, the entire solution can achieve efficient and accurate paint defect detection. Attached Figure Description
[0054] Figure 1 This is a diagram illustrating the application environment of a vehicle body paint defect detection method in one embodiment.
[0055] Figure 2 This is a flowchart illustrating a method for detecting defects in vehicle body paint in one embodiment;
[0056] Figure 3 Images of the car body on the production line captured by a defect detection camera;
[0057] Figure 4 A schematic diagram showing the location of defects in the digital model of the vehicle body;
[0058] Figure 5 This is a flowchart illustrating a method for detecting defects in vehicle body paint in another embodiment;
[0059] Figure 6 This is a structural block diagram of a vehicle body paint defect detection device in one embodiment;
[0060] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0061] 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.
[0062] The vehicle paint defect detection method provided in this application embodiment can be applied to, for example... Figure 1In the application environment shown, the entire vehicle body paint defect detection and repair system includes a detection device 102, a defect detection camera 104, and a paint repair device 106. The defect detection camera 104 captures images of the actual vehicle body on the production line and sends these images to the vehicle body paint defect detection device. The vehicle body paint defect detection device acquires a digital model of the vehicle body; it acquires the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body; it performs paint defect detection based on the vehicle body images captured by the defect detection camera, obtaining the paint defect location in the camera coordinate system; based on the relative positional relationship between the defect detection camera and the vehicle body, it locates the paint defect location in the camera coordinate system onto the digital model of the vehicle body, obtaining the paint defect location in the vehicle body coordinate system; based on the relative positional relationship between the production line and the vehicle body, it maps the paint defect location in the vehicle body coordinate system onto the vehicle body on the production line, obtaining the paint defect detection result of the vehicle body on the production line; furthermore, the detection device 102 sends the paint defect detection result of the vehicle body on the production line to the paint repair device 106, so that the paint repair device 106 can repair the paint on the actual vehicle body on the production line.
[0063] In one embodiment, such as Figure 2 As shown, a method for detecting defects in vehicle body paint is provided, which is then applied to... Figure 1 Taking the detection device 102 as an example, the following steps are included:
[0064] S100: Obtain the digital model of the vehicle body.
[0065] A vehicle body digital model is a three-dimensional digital representation of a car body and its related components, created using computer technology and simulation software. It is the core of vehicle product development and is closely integrated with real-vehicle testing for verification and optimization throughout the entire R&D process. Specifically, a digital model of the vehicle body to be tested can be obtained by acquiring a design model or by measuring and mapping an actual vehicle. Generally, vehicle body digital models are directly taken from the car manufacturer's design CAD model data, or a corresponding one-to-one digital model is obtained by measuring the appearance of the actual vehicle body.
[0066] S200: Acquires the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body.
[0067] The relative positional relationship between the defect detection camera and the vehicle body refers to their relative positional relationship. Specifically, it refers to the relative positional relationship between the defect detection camera and the vehicle body in the time domain when the defect detection camera captures the vehicle body image. The relative positional relationship between the production line and the vehicle body refers to the relative position between the vehicle body and the production line during the actual production process. In essence, the relative positional relationships between the defect detection camera and the vehicle body, and between the production line and the vehicle body, can be understood as the digital environment of the production line and the vehicle body. Here, in order to map the defects detected by the defect detection camera onto the actual vehicle body on the production line, it is necessary to establish the digital environment of the defect detection camera, the vehicle, and the production line in advance.
[0068] S300: Detects paint defects based on the vehicle body images captured by the defect detection camera on the production line, and obtains the location of the paint defects in the camera coordinate system.
[0069] Paint defect detection is performed on production line vehicle body images acquired by a defect detection camera. Specifically, image fusion and deep learning methods can be used to detect paint defects in the production line vehicle body images to obtain the location of the paint defects. The paint defect location obtained here is the paint defect location in the camera coordinate system, that is, the defect location relative to the defect detection camera coordinate system. Specifically, the production line vehicle body images can be multiple 2D production line vehicle body images continuously acquired by the defect detection camera.
[0070] S400: Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the digital model of the vehicle body, thus obtaining the position of the paint defect in the vehicle body coordinate system.
[0071] Based on the relative positional relationship between the defect detection camera and the vehicle body obtained from the S300, the location of paint defects in the camera coordinate system is mapped onto the digital model of the vehicle body. Specifically, as follows... Figure 3 and Figure 4 As shown, Figure 3 The image in the middle is a production line car body image captured by a defect detection camera. Based on this image, defects such as... Figure 3 The defect location within the green rectangle is identified, and then, based on the relative position of the defect detection camera and the vehicle body, the defect location within the green rectangle is mapped into the vehicle body digital model, resulting in the following: Figure 4 The defect location shown is in the digital model of the vehicle body, which is the location of the paint defect in the vehicle body coordinate system.
[0072] S500: Based on the relative positional relationship between the production line and the vehicle body, the location of paint defects in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection results of the vehicle body on the production line.
[0073] Based on the relative position of the production line and the vehicle body, the paint defect location in the vehicle body coordinate system is mapped onto the vehicle body on the production line. In other words, the paint defect location is transformed onto the actual vehicle body on the production line to obtain the paint defect detection result of the vehicle body on the production line. This completes the paint defect detection for the vehicle body on the production line. In subsequent operations, the paint defect detection result of the vehicle body on the production line can be sent to the paint defect repair device, which will then automatically repair the actual vehicle body on the production line.
[0074] In one embodiment, obtaining the relative positional relationship between the defect detection camera and the vehicle body includes:
[0075] The feature points of the calibration vehicle body captured by the defect detection camera are obtained, and the positions of the feature points on the calibration vehicle body are known. The positional relationship between the feature points and the defect detection camera is obtained through camera optical model and ray tracing processing. Based on the position of the feature points on the calibration vehicle body and the positional relationship between the feature points and the defect detection camera, the relative positional relationship between the defect detection camera and the vehicle body is obtained.
[0076] Specifically, the process of obtaining the relative positional relationship between the defect detection camera and the vehicle body can be summarized in the following stages:
[0077] 1) Calibrate vehicle body feature points: First, select a series of feature points on the vehicle body. The locations of these feature points on the vehicle body are known. These feature points can be fixed structural points, marker points, or calibration points of a specific design on the vehicle body.
[0078] 2) Acquire feature point images: Use a defect detection camera to capture images containing these calibrated vehicle body feature points. Ensure that the feature point images captured by the camera are clear and identifiable.
[0079] 3) Camera Optical Model and Ray Tracing Processing: The captured images are processed using a camera optical model (such as a pinhole camera model) and ray tracing technology. By using ray intersection techniques, feature points in the image are connected to the camera's optical center, simulating the emission of rays until they intersect with the external object being measured (i.e., the vehicle body). This intersection point is the actual point on the vehicle body corresponding to the feature point in the image.
[0080] 4) Positional Relationship Calculation: Based on the camera optical model and ray tracing results, the positional relationship (i.e., three-dimensional coordinates) between feature points in the image and the defect detection camera is calculated. Combining the known positions of the feature points on the calibrated vehicle body, the relative positional relationship between the defect detection camera and the vehicle body can be derived.
[0081] like Figure 5 As shown, in one embodiment, S300 includes:
[0082] S320: Acquires images of the production line vehicle body captured by the defect detection camera.
[0083] Use a pre-set defect detection camera to capture images of the car body on the production line. Ensure the camera can capture the entire painted surface of the car body, and that the image clarity and resolution are high enough for accurate defect detection later.
[0084] S340: Based on the production line vehicle body images, image fusion and deep learning algorithms are used to detect paint defects and obtain the location of paint defects in the camera coordinate system.
[0085] Before defect detection, the acquired images can be preprocessed. This includes, but is not limited to, image denoising, contrast enhancement, and color correction to improve image quality and reduce the impact of noise and interference on subsequent detection. Image fusion combines useful information from multiple images to generate an image containing more information. In paint defect detection, image fusion can help inspectors or algorithms observe the paint condition of the vehicle more comprehensively, improving the accuracy and reliability of detection. Pre-trained deep learning algorithms are used to detect paint defects in the preprocessed and / or fused images. Deep learning algorithms, such as convolutional neural networks (CNNs), can learn the features and patterns of paint defects from large amounts of training data and accurately identify and locate these defects in new images. After processing by deep learning algorithms, the location of the paint defects in the camera coordinate system is obtained. This location information is usually given in pixel coordinates or coordinates in the image coordinate system. To transform this location information into a more intuitive and easily understood coordinate system for practical applications (such as the vehicle body coordinate system or the actual ground coordinate system), camera calibration techniques and other spatial transformation algorithms may be required.
[0086] In one embodiment, based on images of the production line vehicle body, image fusion and deep learning algorithms are used to detect paint defects, and the locations of paint defects in the camera coordinate system are obtained as follows:
[0087] Step 1: Select production line vehicle body images acquired at adjacent time points.
[0088] Select vehicle body images acquired at adjacent time points from the defect detection cameras on the production line. These images should include the painted parts of the vehicle body, and there should be some overlap or continuity between images acquired at adjacent time points to facilitate subsequent image fusion.
[0089] Step 2: Perform defect enhancement processing on the selected vehicle body image using an image fusion algorithm to obtain the fused image; input the fused image into the trained deep learning model for paint defect detection to obtain the location of the paint defect in the camera coordinate system.
[0090] Image fusion algorithms can combine useful information from multiple images to enhance the information of defect areas and improve detection accuracy. Commonly used image fusion algorithms include pixel-based weighted averaging and feature-based methods. During the fusion process, appropriate fusion algorithms and parameter settings can be selected based on the characteristics of the images and the needs of defect detection. For example, adjustments can be made based on factors such as lighting conditions and noise levels to achieve better fusion results. After image fusion processing, a fused image is obtained. This image contains useful information from multiple images acquired at adjacent times, and the defect areas are enhanced, making it easier for subsequent deep learning algorithms to detect. The fused image is then input into a trained deep learning model for paint defect detection. This model should be trained specifically for paint defect detection tasks and be able to identify and locate paint defects in images. Specifically, deep learning architectures such as convolutional neural networks (CNNs) can be used, trained with a large amount of labeled data, enabling the model to learn the features and patterns of paint defects. During training, appropriate optimization algorithms and loss functions can be used to improve the model's detection performance and generalization ability. After processing the fused image, the deep learning model outputs the location of the paint defects in the camera coordinate system.
[0091] In one embodiment, obtaining the vehicle body digital model includes:
[0092] Step 1: Obtain vehicle body exterior shape mapping data.
[0093] Before constructing a digital model of the vehicle body, it is first necessary to acquire the exterior shape mapping data of the vehicle body. This is typically achieved through the following methods: 3D scanning: Using a high-precision 3D scanner, the vehicle body is scanned to obtain point cloud data of the vehicle body surface. This point cloud data records the 3D coordinate information of every point on the vehicle body surface. Measurement tools: Using traditional measurement tools, such as calipers and gauges, the key dimensions and features of the vehicle body are measured, and the measurement results are recorded. Photogrammetry: Utilizing a multi-camera system or stereo vision technology, multi-angle photographs of the vehicle body are taken, and combined with image processing algorithms, to acquire the 3D shape data of the vehicle body.
[0094] Step 2: Construct a digital model of the vehicle body based on the vehicle body exterior shape mapping data.
[0095] The construction of a digital vehicle body model includes the following stages: 1) Data preprocessing: Cleaning, denoising, and smoothing the acquired point cloud data or measurement data to improve data accuracy and reliability. 2) Feature extraction: Extracting key features and dimensions of the vehicle body from the processed data, such as edges, curvature, and holes. 3) Model construction: Based on the extracted features and dimensions, using 3D modeling software (such as SolidWorks, CATIA, UG, etc.) or reverse engineering software (such as Geomagic, PolyWorks, etc.) to construct a 3D digital model of the vehicle body. During the construction process, techniques such as curve fitting and surface reconstruction can be used to ensure the accuracy and precision of the model. 4) Model optimization: Optimizing the constructed 3D digital model, such as repairing small defects and smoothing transition surfaces, to improve the model's quality and usability.
[0096] Overall, the aforementioned method for detecting defects in vehicle paint has the following significant technical advantages over existing technologies: Traditional 3D methods require 3D reconstruction after acquiring 2D camera images to determine the location of defect points. However, the accuracy of 3D reconstruction is significantly affected by factors such as 3D camera performance, the surrounding environment, and the material of the object being captured, greatly influencing the deviation in defect point location. Achieving high accuracy requires expensive 3D equipment and a demanding installation and production environment, which is difficult for ordinary production lines and manufacturers to accept. The biggest improvement of this application lies in transforming the complex and sensitive 3D reconstruction process into a digital twin mapping process between the 2D camera and the vehicle body. By pre-establishing the positional relationship between the camera and the vehicle body, the 2D defects are mapped onto the vehicle body using digital ray tracing based on the camera's optical model and the vehicle body's position. This process reduces the complexity of the workflow, is unaffected by reconstruction factors, saves hardware costs, and achieves high-precision conversion requirements.
[0097] It should be understood that although the steps in the flowcharts of the above embodiments 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 above embodiments 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.
[0098] Based on the same inventive concept, this application also provides a vehicle body paint defect detection device for implementing the above-described vehicle body paint defect detection method. The solution provided by this device is similar to the solution described in the above method; therefore, the specific limitations in one or more embodiments of the vehicle body paint defect detection device provided below can be found in the limitations of the vehicle body paint defect detection method described above, and will not be repeated here.
[0099] In one embodiment, such as Figure 6 As shown, a vehicle body paint defect detection device is provided, comprising:
[0100] Digital model acquisition module 100 is used to acquire the vehicle body digital model;
[0101] The relative position relationship acquisition module 200 is used to acquire the relative position relationship between the defect detection camera and the vehicle body, as well as the relative position relationship between the production line and the vehicle body;
[0102] The defect detection module 300 is used to detect paint defects based on the production line body images captured by the defect detection camera and obtain the location of the paint defects in the camera coordinate system.
[0103] The first mapping module 400 is used to locate the position of the paint defect in the camera coordinate system to the digital model of the vehicle body based on the relative positional relationship between the defect detection camera and the vehicle body, so as to obtain the position of the paint defect in the vehicle body coordinate system.
[0104] The second mapping module 500 is used to map the position of paint defects in the vehicle body coordinate system onto the vehicle body on the production line according to the relative positional relationship between the production line and the vehicle body, so as to obtain the paint defect detection results of the vehicle body on the production line.
[0105] In one embodiment, the relative position relationship acquisition module 200 is further used to acquire feature points of the calibration vehicle body captured by the defect detection camera, the position of the feature points on the calibration vehicle body is known; through camera optical model and ray tracing processing, the positional relationship between the feature points and the defect detection camera is obtained; based on the position of the feature points on the calibration vehicle body and the positional relationship between the feature points and the defect detection camera, the relative positional relationship between the defect detection camera and the vehicle body is obtained.
[0106] In one embodiment, the defect detection module 300 is further configured to acquire production line vehicle body images captured by the defect detection camera; based on the production line vehicle body images, image fusion and deep learning algorithms are used to detect paint defects and obtain the location of paint defects in the camera coordinate system.
[0107] In one embodiment, the defect detection module 300 is further configured to select production line vehicle body images acquired at adjacent time intervals; perform defect enhancement processing on the selected vehicle body images through an image fusion algorithm to obtain a fused image; and input the fused image into a trained deep learning model for paint defect detection to obtain the position of the paint defect in the camera coordinate system.
[0108] In one embodiment, the digital model acquisition module 100 is further used to acquire vehicle body exterior shape mapping data; and to construct a vehicle body digital model based on the vehicle body exterior shape mapping data.
[0109] In one embodiment, the above-mentioned vehicle body paint defect detection device further includes: a sending module, used to send the paint defect detection results of the production line vehicle body to the paint defect repair device.
[0110] In one embodiment, the production line vehicle body images include multiple 2D production line vehicle body images acquired sequentially over time.
[0111] Each module in the aforementioned vehicle paint defect detection device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the computer device's memory as software, so that the processor can call and execute the corresponding operations of each module.
[0112] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 7 As shown, the computer device includes a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, NFC (Near Field Communication), or other technologies. When the computer program is executed by the processor, it implements a method for detecting defects in vehicle body paint. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.
[0113] Those skilled in the art will understand that Figure 7The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0114] In one embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the above-described method for detecting defects in vehicle body paint.
[0115] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the above-described method for detecting defects in vehicle body paint.
[0116] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the above-described method for detecting defects in vehicle body paint.
[0117] Those skilled in the art will understand that all or part of the processes in the methods of 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 of the above methods. 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.
[0118] 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.
[0119] 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 method for detecting defects in vehicle body paint, characterized in that, The method includes: Obtain the digital model of the vehicle body; Obtain the relative positional relationship between the defect detection camera and the vehicle body, as well as the relative positional relationship between the production line and the vehicle body; Paint defects are detected based on the production line vehicle images captured by the defect detection camera, and the location of the paint defects in the camera coordinate system is obtained. Based on the relative positional relationship between the defect detection camera and the vehicle body, the position of the paint defect in the camera coordinate system is located to the vehicle body digital model, thus obtaining the position of the paint defect in the vehicle body coordinate system. Based on the relative positional relationship between the production line and the vehicle body, the paint defect location in the vehicle body coordinate system is mapped onto the vehicle body on the production line to obtain the paint defect detection result of the vehicle body on the production line. Obtaining the relative positional relationship between the defect detection camera and the vehicle body includes: acquiring feature points captured by the defect detection camera on the calibration vehicle body, wherein the positions of the feature points on the calibration vehicle body are known; obtaining the positional relationship between the feature points and the defect detection camera through camera optical model and ray tracing processing; and obtaining the relative positional relationship between the defect detection camera and the vehicle body based on the positions of the feature points on the calibration vehicle body and the positional relationship between the feature points and the defect detection camera. The positional relationship between the feature points and the defect detection camera is obtained through camera optical model and ray tracing processing, including: processing the captured image using a pinhole imaging model and ray tracing technology, connecting the feature points in the image to the optical center of the camera using the ray intersection method, simulating the emission of rays until they intersect with the vehicle body, and the resulting intersection point is the actual point on the vehicle body corresponding to the feature point in the image.
2. The method according to claim 1, characterized in that, The step of detecting paint defects based on the production line vehicle body images acquired by the defect detection camera, and obtaining the location of paint defects in the camera coordinate system, includes: Acquire the production line vehicle body image captured by the defect detection camera; Based on the vehicle body images from the production line, image fusion and deep learning algorithms are used to detect paint defects and obtain the location of paint defects in the camera coordinate system.
3. The method according to claim 2, characterized in that, Based on the production line vehicle images, image fusion and deep learning algorithms are used to detect paint defects, and the locations of paint defects in the camera coordinate system are obtained as follows: Select the production line vehicle body images acquired at adjacent time intervals; The selected vehicle body image is processed using an image fusion algorithm to enhance defects, resulting in a fused image. The fused image is input into a trained deep learning model for paint defect detection to obtain the location of the paint defect in the camera coordinate system.
4. The method according to claim 1, characterized in that, The acquisition of the vehicle body digital model includes: Acquire vehicle exterior shape mapping data; A digital model of the vehicle body is constructed based on the aforementioned vehicle body exterior morphology mapping data.
5. The method according to claim 1, characterized in that, After mapping the paint defect location in the vehicle body coordinate system to the vehicle body on the production line based on the relative positional relationship between the production line and the vehicle body, and obtaining the paint defect detection result of the vehicle body on the production line, the method further includes: The paint defect detection results of the production line vehicle body are sent to the paint defect repair device.
6. The method according to claim 1, characterized in that, The production line vehicle body images include multiple 2D production line vehicle body images acquired consecutively over time.
7. A device for detecting defects in vehicle body paint, characterized in that, The device includes: The digital model acquisition module is used to acquire the digital model of the vehicle body; The relative position relationship acquisition module is used to acquire the relative position relationship between the defect detection camera and the vehicle body, as well as the relative position relationship between the production line and the vehicle body; The defect detection module is used to detect paint defects based on the production line vehicle images captured by the defect detection camera, and obtain the location of the paint defects in the camera coordinate system. The first mapping module is used to locate the position of the paint defect in the camera coordinate system to the digital model of the vehicle body based on the relative position relationship between the defect detection camera and the vehicle body, so as to obtain the position of the paint defect in the vehicle body coordinate system. The second mapping module is used to map the paint defect position in the vehicle body coordinate system to the vehicle body on the production line according to the relative positional relationship between the production line and the vehicle body, so as to obtain the paint defect detection result of the vehicle body on the production line. The relative position relationship acquisition module is further used to acquire the relative position relationship between the defect detection camera and the vehicle body, including: acquiring feature points of the calibration vehicle body captured by the defect detection camera, wherein the position of the feature points on the calibration vehicle body is known; obtaining the position relationship between the feature points and the defect detection camera through camera optical model and ray tracing processing; and obtaining the relative position relationship between the defect detection camera and the vehicle body based on the position of the feature points on the calibration vehicle body and the position relationship between the feature points and the defect detection camera. The positional relationship between the feature points and the defect detection camera is obtained through camera optical model and ray tracing processing, including: processing the captured image using a pinhole imaging model and ray tracing technology, connecting the feature points in the image to the optical center of the camera using the ray intersection method, simulating the emission of rays until they intersect with the vehicle body, and the resulting intersection point is the actual point on the vehicle body corresponding to the feature point in the image.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.
9. 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 6.
Citation Information
Patent Citations
Vehicle body paint surface defect video detection method and video detection system
CN116930187A
Image mapping to vehicle surfaces
GB2591445A