Artificial Intelligence-Based Vehicle Grille Component Damage Detection Method and Related Equipment

By building and training the vehicle components and grille segmentation network, the problem of low accuracy in vehicle grille damage detection is solved, and refined detection and accurate damage identification of vehicle grille component damage is achieved.

CN115239960BActive Publication Date: 2025-06-20PING AN TECH (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210912211.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-28
Publication Date
2025-06-20
Estimated Expiration
2042-07-28

AI Technical Summary

Technical Problem

The existing semantic segmentation network or target segmentation network has low accuracy in vehicle grille damage detection and cannot be refined to specific vehicle components, especially vehicle grille components.

Method used

The first segmentation network of vehicle components and the first segmentation network of grilles are built, and the image information of the vehicle grilles components and grilles subcategory in the vehicle image is extracted respectively through training of the preset loss function and the cross entropy loss function, and the image information of the vehicle grilles components and grilles subcategory in the vehicle image is respectively, and the preset damage detection network is used for damage detection.

Benefits of technology

The accuracy of damage detection of vehicle grille components is improved, and the grille subcategories can be refined and the damage detection results can be obtained.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115239960B_ABST
    Figure CN115239960B_ABST
Patent Text Reader

Abstract

The present application proposes an artificial intelligence-based method, device, electronic device, and storage medium for detecting damage to vehicle grille components. The artificial intelligence-based method for detecting damage to vehicle grille components includes: building a first segmentation network for vehicle components, and training the first segmentation network for vehicle components according to a preset loss function to obtain a second segmentation network for vehicle components; collecting target vehicle images, and obtaining vehicle grille images of the target vehicle images based on the second segmentation network for vehicle components; building a first segmentation network for the grille, and training the first segmentation network for the grille according to the cross-entropy loss function to obtain a second segmentation network for the grille; segmenting the vehicle grille images of the target vehicle images according to the second segmentation network for the grille to obtain vehicle grille sub-images of each grille sub-category; and inputting all the vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle images. The present application can improve the accuracy of detecting damage to vehicle grille components.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of artificial intelligence technology, and particularly relates to a method, device, electronic device and storage medium for detecting damage to vehicle grille components based on artificial intelligence. Background Art

[0002] During the driving process of a vehicle, due to factors such as weather, road conditions or driver skills, it is inevitable for the vehicle to be damaged. Detecting the damaged parts and the degree of damage of the damaged vehicle directly affects the determination of the subsequent vehicle repair plan and the confirmation of the economic compensation amount of the relevant parties in the subsequent accident.

[0003] Currently, existing semantic segmentation networks or object segmentation networks are usually directly used to process the images of damaged vehicles to achieve intelligent loss assessment. However, the feature differences of different vehicle components in the images are large, and this method cannot be refined to specific vehicle components. At the same time, the vehicle grille is a type of vehicle component with a complex structure, resulting in a low accuracy of vehicle grille damage detection. Summary of the Invention

[0004] In view of the above, it is necessary to propose a method and related devices for detecting damage to vehicle grille components based on artificial intelligence to solve the technical problem of how to improve the accuracy of vehicle grille damage detection. Among them, the related devices include a device for detecting damage to vehicle grille components based on artificial intelligence, an electronic device and a storage medium.

[0005] The present application provides a method for detecting damage to vehicle grille components based on artificial intelligence, and the method includes:

[0006] Build a first vehicle component segmentation network, and train the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network;

[0007] Collect an image of a target vehicle, and obtain an image of the vehicle grille of the target vehicle image based on the second vehicle component segmentation network;

[0008] Build a first grille segmentation network, and train the first grille segmentation network according to the cross-entropy loss function to obtain a second grille segmentation network;

[0009] Segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain vehicle grille sub-images of each grille sub-category;

[0010] Input all the vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image.

[0011] In some embodiments, building a first vehicle component segmentation network and training the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network includes:

[0012] Build a first vehicle component segmentation network, where the first vehicle component segmentation network includes an encoder and a decoder;

[0013] Collect a large number of vehicle images and obtain the label data of each vehicle image;

[0014] Store all vehicle images and the label data of all vehicle images as an annotation data set;

[0015] Train the first vehicle component segmentation network based on the annotation data set and the preset loss function to obtain a second vehicle component segmentation network. The input of the second vehicle component segmentation network is a vehicle image, and the output is the component segmentation result of the vehicle image. The component segmentation result includes the class vector of each pixel point in the vehicle image. The class vector of the pixel point includes the probability value of the pixel point belonging to each type of vehicle component. The vehicle components include multiple vehicle components including 2 types of vehicle grille components, and the 2 types of vehicle grille components include a middle grille and a lower grille.

[0016] In some embodiments, the preset loss function satisfies the relationship:

[0017]

[0018] where W×H represents the size of the vehicle image input to the first vehicle component segmentation network, p i,j represents the class vector of the pixel point (i, j) in the component segmentation result output by the first vehicle component segmentation network, represents the mean value of the class vectors of all pixel points within the neighborhood range of the pixel point (i, j) in the component segmentation result output by the first vehicle component segmentation network, represents p i,j and The Euclidean distance of, Loss2 is a cross-entropy loss function constructed based on the label data of the vehicle image, λ is a regulation coefficient, and the value range is [0, 1], Loss l is the preset loss function value.

[0019] In some embodiments, collecting a target vehicle image and obtaining a vehicle grille image of the target vehicle image based on the second vehicle component segmentation network includes:

[0020] Collect the images of the target vehicle, input the target vehicle images into the second vehicle component segmentation network to obtain the component segmentation results of the target vehicle images. The component segmentation results include the class vectors of each pixel point. Select the vehicle component type corresponding to the maximum probability value in the class vector of each pixel point as the vehicle component type of the pixel point;

[0021] Set the pixel values of the pixel points whose vehicle component type in the component segmentation results is the vehicle grille component to 1, and set the pixel values of other areas to 0 to obtain the mask image of the vehicle grille component. The vehicle grille component includes the middle grille and the lower grille;

[0022] Multiply the mask image of the vehicle grille component by the target vehicle image to obtain the vehicle grille image of the target vehicle image.

[0023] In some embodiments, the construction of the first grille segmentation network and the training of the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network include:

[0024] Construct the first grille segmentation network, which includes an encoder and a decoder;

[0025] Collect a large number of vehicle grille images and obtain the label data of each vehicle grille image;

[0026] Train the first grille segmentation network based on the vehicle grille images, the label data of the vehicle grille images and the cross-entropy loss function to obtain the second grille segmentation network. The input of the second grille segmentation network is the vehicle grille image, and the output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-class vectors of each pixel point in the vehicle grille image. The sub-class vector of the pixel point includes the probability values of the pixel point belonging to each grille sub-class. The grille sub-classes include the vehicle logo, the grille frame and the grille bright strip.

[0027] In some embodiments, the segmentation of the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain the vehicle grille sub-images of each grille sub-class includes:

[0028] Input the vehicle grille image of the target vehicle image into the second grille segmentation network to obtain the grille segmentation result. The grille segmentation result includes the sub-class vectors of each pixel point. Select the grille sub-class corresponding to the maximum probability value in the sub-class vector of each pixel point as the grille sub-class of the pixel point;

[0029] Randomly select a grille sub-class as the target grille sub-class;

[0030] Set the pixel values of the pixel points of the target grille subcategory in the grille segmentation result to 1, and set the pixel values of the pixel points in other areas to 0 to obtain the mask image of the target grille subcategory;

[0031] Multiply the mask image of the target grille subcategory by the vehicle grille image of the target vehicle image to obtain the vehicle grille sub-image of the target grille subcategory;

[0032] Traverse all grille subcategories to obtain the vehicle grille sub-image of one grille subcategory.

[0033] In some embodiments, the inputting all vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image includes:

[0034] Stack the vehicle grille sub-images of each grille subcategory together in a fixed order to construct a three-dimensional vehicle grille sub-image;

[0035] Input the three-dimensional vehicle grille sub-image into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image, and the damage detection result includes the damage types and location information of all damages in the vehicle grille component of the target vehicle image.

[0036] The embodiment of the present application also provides an artificial intelligence-based vehicle grille component damage detection device, and the device includes:

[0037] A first training unit, configured to build a first vehicle component segmentation network, and train the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network;

[0038] An acquisition unit, configured to collect a target vehicle image, and obtain the vehicle grille image of the target vehicle image based on the second vehicle component segmentation network;

[0039] A second training unit, configured to build a first grille segmentation network, and train the first grille segmentation network according to a cross-entropy loss function to obtain a second grille segmentation network;

[0040] A segmentation unit, configured to segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain the vehicle grille sub-image of each grille subcategory;

[0041] A damage detection unit, configured to input all vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image.

[0042] The embodiment of the present application also provides an electronic device, and the electronic device includes:

[0043] A memory that stores at least one instruction;

[0044] A processor that executes the instructions stored in the memory to implement the above-mentioned method for detecting damage to vehicle grille components based on artificial intelligence.

[0045] An embodiment of the present application also provides a computer-readable storage medium, in which at least one instruction is stored, and the at least one instruction is executed by a processor in an electronic device to implement the above-mentioned method for detecting damage to vehicle grille components based on artificial intelligence.

[0046] In summary, the present application uses a vehicle component segmentation network to extract image information of vehicle grille components from vehicle images, further makes a refined division of the image information of vehicle grille components to obtain image information of each grille sub-category, and obtains the damage detection result of vehicle grille components from the image information of each grille sub-category, thereby improving the accuracy of damage detection of vehicle grille components. Description of the Drawings

[0047] Figure 1 is a flowchart of a preferred embodiment of the method for detecting damage to vehicle grille components based on artificial intelligence involved in the present application.

[0048] Figure 2 is a schematic diagram of the acquisition process of the damage detection result involved in the present application.

[0049] Figure 3 is a functional module diagram of a preferred embodiment of the device for detecting damage to vehicle grille components based on artificial intelligence involved in the present application.

[0050] Figure 4 is a schematic diagram of the structure of an electronic device of a preferred embodiment of the method for detecting damage to vehicle grille components based on artificial intelligence involved in the present application. Detailed Embodiments

[0051] In order to more clearly understand the purpose, features, and advantages of the present application, the present application will be described in detail below with reference to the drawings and specific embodiments. It should be noted that, without conflict, the embodiments of the present application and the features in the embodiments can be combined with each other. Many specific details are set forth in the following description in order to fully understand the present application. The described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments.

[0052] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of the said features. In the description of this application, "a plurality of" means two or more unless otherwise specifically defined.

[0053] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field to which this application belongs. The terms used in the description of this application herein are for the purpose of describing specific embodiments only and are not intended to limit this application. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.

[0054] An embodiment of this application provides a method for detecting damage to vehicle grille components based on artificial intelligence, which can be applied to one or more electronic devices. An electronic device is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes, but is not limited to, a microprocessor, an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), a digital signal processor (DSP), an embedded device, etc.

[0055] An electronic device can be any electronic product that can interact with a customer, such as a personal computer, a tablet computer, a smart phone, a personal digital assistant (PDA), a game console, an Internet Protocol Television (IPTV), a smart wearable device, etc.

[0056] An electronic device may also include a network device and / or a client device. Among them, the network device includes, but is not limited to, a single network server, a server group composed of multiple network servers, or a cloud composed of a large number of hosts or network servers based on cloud computing.

[0057] The network where the electronic device is located includes, but is not limited to, the Internet, a wide area network, a metropolitan area network, a local area network, a virtual private network (VPN), etc.

[0058] Such as Figure 1As shown, it is a flowchart of a preferred embodiment of the method for detecting damage to vehicle grille components based on artificial intelligence in this application. According to different requirements, the order of steps in this flowchart can be changed, and some steps can be omitted.

[0059] S10. Build the first vehicle component segmentation network, and train the first vehicle component segmentation network according to a preset loss function to obtain the second vehicle component segmentation network.

[0060] In an optional embodiment, the building of the first vehicle component segmentation network and training the first vehicle component segmentation network according to a preset loss function to obtain the second vehicle component segmentation network includes:

[0061] Build the first vehicle component segmentation network, and the first vehicle component segmentation network includes an encoder and a decoder;

[0062] Collect a large number of vehicle images, and obtain the label data of each vehicle image;

[0063] Store all vehicle images and the label data of all vehicle images as an annotation dataset;

[0064] Based on the annotation dataset and a preset loss function, train the first vehicle component segmentation network to obtain the second vehicle component segmentation network. The input of the second vehicle component segmentation network is a vehicle image, and the output is the component segmentation result of the vehicle image. The component segmentation result includes the class vector of each pixel point in the vehicle image. The class vector of the pixel point includes the probability value of the pixel point belonging to each type of vehicle component. The vehicle components include multiple vehicle components including 2 types of vehicle grille components. The 2 types of vehicle grille components include the middle grille and the lower grille.

[0065] In this optional embodiment, build the first vehicle component segmentation network. The input of the first vehicle component segmentation network is a vehicle image, and the expected output is the component segmentation result of the vehicle image. The component segmentation result includes the class vector of each pixel point in the vehicle image. The class vector includes the probability value of the pixel point belonging to each type of vehicle component, and the sum of all probability values in the class vector of the same pixel point is 1; select the type of vehicle component corresponding to the maximum probability value in the class vector as the type of vehicle component corresponding to the pixel point. Among them, the vehicle components include multiple vehicle components including 2 types of vehicle grille components. The 2 types of vehicle grille components include the middle grille and the lower grille.

[0066] In this optional embodiment, the first vehicle component segmentation network is an encoder-decoder structure. The encoder uses convolutional layers to downsample the input vehicle image to obtain a global feature map, and sends the global feature map into the decoder to perform upsampling using transposed convolutional layers to obtain the component segmentation result of the vehicle image. The first vehicle component segmentation network can select existing image segmentation networks with relatively high accuracy, such as DeepLapV3+ and UNet, which are not limited in this application.

[0067] In this optional embodiment, in order to ensure that the output of the first vehicle component segmentation network is the component segmentation result of the input vehicle image, it is necessary to train the first vehicle component segmentation network according to a preset loss function to obtain the second vehicle component segmentation network.

[0068] In this optional embodiment, a large number of vehicle images are collected, and the label data of each vehicle image is obtained. The label data of the vehicle image is an image of the same size as the vehicle image, and the pixel value in the label data represents the preset label of the vehicle component type at each pixel point. The preset label is an integer from 1 to N, where N represents the number of all vehicle component types including 2 types of vehicle grille components. The vehicle component types correspond to the preset labels one by one, and all vehicle images and the label data of all vehicle images are stored as an annotation dataset.

[0069] In this optional embodiment, in a vehicle image, the distribution of vehicle components has a spatial continuity feature. The spatial continuity feature means that a pixel point and other pixel points within the neighborhood range of this pixel point usually belong to the same vehicle component. The neighborhood range of the pixel point includes 8 pixel points adjacent to this pixel point in the vehicle image; at the same time, the label data of a vehicle image can reflect the vehicle component type corresponding to each pixel point in the vehicle image; the spatial continuity feature and the label data are used as supervision information to construct a preset loss function. The preset loss function is used to constrain the first vehicle component segmentation network to learn the features of each vehicle component in the vehicle image and the spatial continuity feature of the vehicle component distribution. The preset loss function satisfies the relational expression:

[0070]

[0071] where, W×H represents the size of the vehicle image input to the first vehicle component segmentation network, p i,j represents the category vector of the pixel point (i, j) in the component segmentation result output by the first vehicle component segmentation network, represents the mean value of the category vectors of all pixel points within the neighborhood range of the pixel point (i, j) in the component segmentation result output by the first vehicle component segmentation network, represents p i,j and The Euclidean distance, Loss2 is the cross-entropy loss function constructed based on the label data of the vehicle images, λ is the adjustment coefficient with a value range of [0, 1], and Loss1 is the preset loss function value. Among them, the adjustment coefficient is used to adjust the supervision intensity of the spatial continuity feature and the label data on the first vehicle component segmentation network, and the value of the adjustment coefficient is 0.8.

[0072] In this optional embodiment, the first vehicle component segmentation network is trained based on the labeled data set and the preset loss function to obtain the second vehicle component segmentation network. Vehicle images are continuously selected from the labeled data set and input into the first vehicle component segmentation network to calculate the value of the preset loss function, and the parameters in the first vehicle component segmentation network are continuously updated using the gradient descent method. When the value of the preset loss function no longer changes, the training is stopped to obtain the second vehicle component segmentation network, and the second vehicle component segmentation network can obtain accurate component segmentation results.

[0073] In this way, the training of the first vehicle component segmentation network is completed to obtain the second vehicle component segmentation network, and the second vehicle component segmentation network can obtain accurate component segmentation results corresponding to the input vehicle images.

[0074] S11, collect a target vehicle image, and obtain the vehicle grille image of the target vehicle image based on the second vehicle component segmentation network.

[0075] In an optional embodiment, the step of collecting a target vehicle image and obtaining the vehicle grille image of the target vehicle image based on the second vehicle component segmentation network includes:

[0076] Collect a target vehicle image, input the target vehicle image into the second vehicle component segmentation network to obtain the component segmentation result of the target vehicle image. The component segmentation result includes the category vector of each pixel point. Select the vehicle component type corresponding to the maximum probability value in the category vector of each pixel point as the vehicle component type of the pixel point;

[0077] Set the pixel value of the pixel points whose vehicle component type in the component segmentation result is the vehicle grille component to 1, and set the pixel values of other regions to 0 to obtain the mask image of the vehicle grille component. The vehicle grille component includes the middle grille and the lower grille;

[0078] Multiply the mask image of the vehicle grille component by the target vehicle image to obtain the vehicle grille image of the target vehicle image.

[0079] In this way, the vehicle grille image in the target vehicle image is obtained by means of the second segmentation network of the vehicle component, so as to realize the positioning of the vehicle grille component and provide a data basis for subsequent vehicle grille damage detection.

[0080] S12. Build a first grille segmentation network, and train the first grille segmentation network according to the cross-entropy loss function to obtain a second grille segmentation network.

[0081] In an optional embodiment, the building of the first grille segmentation network and training the first grille segmentation network according to the cross-entropy loss function to obtain a second grille segmentation network includes:

[0082] Build a first grille segmentation network, and the first grille segmentation network includes an encoder and a decoder;

[0083] Collect a large number of vehicle grille images, and obtain the label data of each vehicle grille image;

[0084] Train the first grille segmentation network based on the vehicle grille images, the label data of the vehicle grille images and the cross-entropy loss function to obtain a second grille segmentation network. The input of the second grille segmentation network is the vehicle grille image, and the output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-category vector of each pixel point in the vehicle grille image. The sub-category vector of the pixel point includes the probability value that the pixel point belongs to each grille sub-category. The grille sub-categories include three types: vehicle logo, grille frame and grille bright strip.

[0085] In this optional embodiment, build a first grille segmentation network. The input of the first grille segmentation network is the vehicle grille image, and the expected output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-category vector of each pixel point in the vehicle grille image. The sub-category vector of the pixel point includes the probability value that the pixel point belongs to each grille sub-category; select the grille sub-category corresponding to the maximum probability value in the sub-category vector as the grille sub-category corresponding to the pixel point. Among them, the grille sub-categories include three types: vehicle logo, grille frame and grille bright strip.

[0086] In this optional embodiment, the first grille segmentation network is an encoder-decoder structure. The encoder uses convolutional layers to downsample the input vehicle grille image to obtain a grille feature map, and sends the grille feature map into the decoder to perform upsampling using transposed convolutional layers to obtain the grille segmentation result of the vehicle grille image. The first grille segmentation network can select existing image segmentation networks with higher accuracy such as DeepLapV3+ and UNet, and this application does not make any restrictions.

[0087] In this alternative embodiment, in order to ensure that the output of the first grille segmentation network is the grille segmentation result of the vehicle grille image, it is necessary to train the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network.

[0088] In an alternative embodiment, a large number of vehicle grille images are collected, and the label data of each vehicle grille image is obtained. The pixel value in the label data of the vehicle grille image represents the preset label of the grille sub-category at each pixel point. The preset label is an integer from 1 to 3, corresponding to three grille sub-categories: vehicle logo, grille frame, and grille bright bar respectively. Continuously input the vehicle grille image into the first grille segmentation network to obtain the grille segmentation result, and calculate the value of the cross-entropy loss function based on the grille segmentation result and the label data of the vehicle grille image. Use the gradient descent method to continuously update the parameters in the first grille segmentation network. When the value of the cross-entropy loss function no longer changes, stop the training to obtain the second grille segmentation network. The second grille segmentation network can extract the difference features of different grille sub-categories in terms of brightness, position, etc. in the vehicle grille image, so as to obtain an accurate grille segmentation result.

[0089] In this way, the training of the first grille segmentation network is completed to obtain the second grille segmentation network. Based on the second grille segmentation network, the position information of each grille sub-category in the vehicle grille image can be accurately obtained, ensuring the accuracy of vehicle grille damage detection.

[0090] S13. Segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain vehicle grille sub-images of each grille sub-category.

[0091] In an alternative embodiment, the segmenting the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain vehicle grille sub-images of each grille sub-category includes:

[0092] Input the vehicle grille image of the target vehicle image into the second grille segmentation network to obtain the grille segmentation result. The grille segmentation result includes the sub-category vector of each pixel point. Select the grille sub-category corresponding to the maximum probability value in the sub-category vector of each pixel point as the grille sub-category of the pixel point.

[0093] Randomly select a grille sub-category as the target grille sub-category.

[0094] Set the pixel value of the pixel points of the target grille sub-category in the grille segmentation result to 1, and set the pixel values of the pixel points in other areas to 0 to obtain the mask image of the target grille sub-category.

[0095] Multiply the mask image of the target grille subcategory by the vehicle grille image of the target vehicle image to obtain the vehicle grille subgraph of the target grille subcategory;

[0096] Traverse all grille subcategories to obtain the vehicle grille subgraph of one grille subcategory.

[0097] Among them, the grille subcategories include three types: vehicle logo, grille frame, and grille bright strip, and each grille subcategory corresponds to a vehicle grille subgraph.

[0098] In this way, by means of the grille second segmentation network, the vehicle grille subgraph of each grille subcategory in the vehicle grille image of the target vehicle image is obtained, providing a data basis for realizing vehicle grille damage detection.

[0099] S14, input all vehicle grille subgraphs into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image.

[0100] In an optional embodiment, the inputting all vehicle grille subgraphs into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image includes:

[0101] Stack the vehicle grille subgraphs of each grille subcategory together in a fixed order to construct a three-dimensional vehicle grille subgraph;

[0102] Input the three-dimensional vehicle grille subgraph into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image. The damage detection result includes the damage types and location information of all damages in the vehicle grille components of the target vehicle image.

[0103] Among them, the size of the three-dimensional vehicle grille subgraph is w×h×3, which can reflect the information of the vehicle grille subgraph of each grille subcategory in the target vehicle image. Among them, w×h represents the size information of the vehicle grille subgraph of each grille subcategory, and 3 corresponds to 3 different grille subcategories.

[0104] In this optional embodiment, the damage detection result includes the damage types and location information of all damages in the vehicle grille components of the target vehicle image. The damage types include 11 types: vehicle logo abrasion, vehicle logo fracture, vehicle logo missing, grille frame abrasion, grille frame fracture, grille frame missing, grille frame deformation, grille bright strip abrasion, grille bright strip fracture, grille bright strip missing, grille bright strip deformation. The location information is a rectangular frame containing the damaged area. The schematic diagram of the acquisition process of the damage detection result is as Figure 2 shown.

[0105] In this optional embodiment, the input of the preset damage detection network is a three-dimensional vehicle grille sub-image, and the output is the damage detection result of the three-dimensional vehicle grille sub-image. The preset damage detection network can adopt existing object detection networks such as RetinaNet, YOLOV5, and CenterNet. The obtaining process of the preset damage detection network includes: building an initialized preset damage detection network; collecting a large number of three-dimensional vehicle grille sub-images as sample data, and manually annotating the damage detection results of each sample data to obtain training data; training the initialized preset damage detection network based on the training data to obtain the preset damage detection network.

[0106] In this way, taking the three-dimensional vehicle grille sub-image as the input of the preset damage detection network to obtain the damage detection result of the vehicle grille component in the target vehicle image, the three-dimensional vehicle grille sub-image can directly reflect the vehicle grille sub-image information of each grille sub-category in the target vehicle image, improving the accuracy of the damage detection of the vehicle grille component.

[0107] It can be seen from the above technical solutions that this application uses a vehicle component segmentation network to extract the image information of the vehicle grille component from the vehicle image, further making a refined division of the image information of the vehicle grille component to obtain the image information of each grille sub-category, and obtaining the damage detection result of the vehicle grille component from the image information of each grille sub-category, improving the accuracy of the damage detection of the vehicle grille component.

[0108] Please refer to Figure 3 , Figure 3 which is the functional module diagram of a preferred embodiment of the vehicle grille component damage detection device based on artificial intelligence of this application. The vehicle grille component damage detection device 11 based on artificial intelligence includes a first training unit 110, an acquisition unit 111, a second training unit 112, a segmentation unit 113, and a damage detection unit 114. The module / unit mentioned in this application refers to a series of computer-readable instruction segments that can be executed by a processor 13 and can complete fixed functions, and are stored in a memory 12. In this embodiment, the functions of each module / unit will be described in detail in subsequent embodiments.

[0109] In an optional embodiment, the first training unit 110 is used to build a first vehicle component segmentation network and train the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network.

[0110] In an optional embodiment, the building of the first vehicle component segmentation network and training the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network includes:

[0111] Build the first vehicle component segmentation network, where the first vehicle component segmentation network includes an encoder and a decoder;

[0112] Collect a large number of vehicle images and obtain the label data for each vehicle image;

[0113] Store all vehicle images and the label data of all vehicle images as an annotated dataset;

[0114] Train the first vehicle component segmentation network based on the annotated dataset and a preset loss function to obtain the second vehicle component segmentation network. The input of the second vehicle component segmentation network is a vehicle image, and the output is the component segmentation result of the vehicle image. The component segmentation result includes the class vector of each pixel point in the vehicle image. The class vector of the pixel point includes the probability value that the pixel point belongs to each type of vehicle component. The vehicle components include multiple vehicle components including 2 types of vehicle grille components. The 2 types of vehicle grille components include the middle grille and the lower grille.

[0115] In this alternative embodiment, build the first vehicle component segmentation network. The input of the first vehicle component segmentation network is a vehicle image, and the expected output is the component segmentation result of the vehicle image. The component segmentation result includes the class vector of each pixel point in the vehicle image. The class vector includes the probability value that the pixel point belongs to each type of vehicle component, and the sum of all probability values in the class vector of the same pixel point is 1; select the type of vehicle component corresponding to the maximum probability value in the class vector as the type of vehicle component corresponding to the pixel point. Among them, the vehicle components include multiple vehicle components including 2 types of vehicle grille components. The 2 types of vehicle grille components include the middle grille and the lower grille.

[0116] In this alternative embodiment, the first vehicle component segmentation network has an encoder-decoder structure. The encoder uses convolutional layers to downsample the input vehicle image to obtain a global feature map, and sends the global feature map into the decoder to use transposed convolutional layers for upsampling to obtain the component segmentation result of the vehicle image. The first vehicle component segmentation network can select existing image segmentation networks with higher accuracy such as DeepLapV3+ and UNet, and this application does not make restrictions.

[0117] In this alternative embodiment, in order to ensure that the output of the first vehicle component segmentation network is the component segmentation result of the input vehicle image, it is necessary to train the first vehicle component segmentation network based on a preset loss function to obtain the second vehicle component segmentation network.

[0118] In this optional embodiment, a large number of vehicle images are collected, and the label data of each vehicle image is obtained. The label data of the vehicle image is an image of the same size as the vehicle image. The pixel value in the label data represents a preset label of the vehicle component type at each pixel point. The preset label is an integer from 1 to N, where N represents the number of all vehicle component types including 2 types of vehicle grille components. The vehicle component types correspond one-to-one with the preset labels. All vehicle images and the label data of all vehicle images are stored as an annotated data set.

[0119] In this optional embodiment, in a vehicle image, the distribution of vehicle components has a spatial continuity feature. The spatial continuity feature means that a pixel point and other pixel points within the neighborhood range of this pixel point generally belong to the same vehicle component. The neighborhood range of the pixel point includes 8 pixel points adjacent to this pixel point in the vehicle image. At the same time, the label data of a vehicle image can reflect the vehicle component type corresponding to each pixel point in the vehicle image. The spatial continuity feature and the label data are used as supervision information to construct a preset loss function. The preset loss function is used to constrain the vehicle component first segmentation network to learn the features of each vehicle component in the vehicle image and the spatial continuity feature of the vehicle component distribution. The preset loss function satisfies the relational expression:

[0120]

[0121] where W×H represents the size of the vehicle image input to the vehicle component first segmentation network, p i,j represents the category vector of the pixel point (i, j) in the component segmentation result output by the vehicle component first segmentation network, represents the mean value of the category vectors of all pixel points within the neighborhood range of the pixel point (i, j) in the component segmentation result output by the vehicle component first segmentation network, represents p i,j and is the Euclidean distance between them. Loss2 is the cross-entropy loss function constructed based on the label data of the vehicle image. λ is a regulation coefficient, and its value range is [0, 1]. Loss1 is the value of the preset loss function. Among them, the regulation coefficient is used to regulate the supervision intensity of the spatial continuity feature and the label data on the vehicle component first segmentation network, and the value of the regulation coefficient is 0.8.

[0122] In this optional embodiment, the first vehicle component segmentation network is trained based on the labeled data set and a preset loss function to obtain the second vehicle component segmentation network. Vehicle images are continuously selected from the labeled data set and input into the first vehicle component segmentation network to calculate the value of the preset loss function, and the parameters in the first vehicle component segmentation network are continuously updated using the gradient descent method. When the value of the preset loss function no longer changes, the training is stopped to obtain the second vehicle component segmentation network, and the second vehicle component segmentation network can obtain accurate component segmentation results.

[0123] In an optional embodiment, the acquisition unit 111 is configured to collect target vehicle images and obtain the vehicle grille images of the target vehicle images based on the second vehicle component segmentation network.

[0124] In an optional embodiment, the collecting the target vehicle images and obtaining the vehicle grille images of the target vehicle images based on the second vehicle component segmentation network includes:

[0125] Collect target vehicle images, input the target vehicle images into the second vehicle component segmentation network to obtain the component segmentation results of the target vehicle images, where the component segmentation results include the class vectors of each pixel point, and select the vehicle component type corresponding to the maximum probability value in the class vectors of each pixel point as the vehicle component type of the pixel point;

[0126] Set the pixel values of the pixel points whose vehicle component type in the component segmentation results is the vehicle grille component to 1, and set the pixel values of other regions to 0 to obtain the mask image of the vehicle grille component, where the vehicle grille component includes the middle grille and the lower grille;

[0127] Multiply the mask image of the vehicle grille component by the target vehicle image to obtain the vehicle grille image of the target vehicle image.

[0128] In an optional embodiment, the second training unit 112 is configured to build the first grille segmentation network and train the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network.

[0129] In an optional embodiment, the building the first grille segmentation network and training the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network includes:

[0130] Build the first grille segmentation network, where the first grille segmentation network includes an encoder and a decoder;

[0131] Collect a large number of vehicle grille images and obtain the label data of each vehicle grille image;

[0132] Train the first grille segmentation network based on the vehicle grille image, the label data of the vehicle grille image, and the cross-entropy loss function to obtain the second grille segmentation network. The input of the second grille segmentation network is the vehicle grille image, and the output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-category vector of each pixel point in the vehicle grille image. The sub-category vector of the pixel point includes the probability value of the pixel point belonging to each grille sub-category. The grille sub-categories include the vehicle logo, the grille frame, and the grille bright strip.

[0133] In this optional embodiment, build the first grille segmentation network. The input of the first grille segmentation network is the vehicle grille image, and the expected output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-category vector of each pixel point in the vehicle grille image. The sub-category vector of the pixel point includes the probability value of the pixel point belonging to each grille sub-category. Select the grille sub-category corresponding to the maximum probability value in the sub-category vector as the grille sub-category corresponding to the pixel point. Among them, the grille sub-categories include the vehicle logo, the grille frame, and the grille bright strip.

[0134] In this optional embodiment, the first grille segmentation network has an encoder-decoder structure. The encoder uses convolutional layers to downsample the input vehicle grille image to obtain a grille feature map, and sends the grille feature map into the decoder to use transposed convolutional layers for upsampling to obtain the grille segmentation result of the vehicle grille image. The first grille segmentation network can select existing image segmentation networks with higher accuracy such as DeepLapV3+ and UNet, and this application does not make any restrictions.

[0135] In this optional embodiment, in order to ensure that the output of the first grille segmentation network is the grille segmentation result of the vehicle grille image, it is necessary to train the first grille segmentation network based on the cross-entropy loss function to obtain the second grille segmentation network.

[0136] In an alternative embodiment, a large number of vehicle grille images are collected, and label data for each vehicle grille image is obtained. The pixel values in the label data of the vehicle grille image represent preset labels for grille sub-categories at each pixel point. The preset labels are integers from 1 to 3, corresponding to three grille sub-categories: vehicle logo, grille frame, and grille bright strip respectively. The vehicle grille images are continuously input into the first grille segmentation network to obtain a grille segmentation result, and the value of the cross-entropy loss function is calculated based on the grille segmentation result and the label data of the vehicle grille image. The parameters in the first grille segmentation network are continuously updated using the gradient descent method. When the value of the cross-entropy loss function no longer changes, the training stops to obtain the second grille segmentation network. The second grille segmentation network can extract the difference features of different grille sub-categories in terms of brightness, position, etc. in the vehicle grille image, so as to obtain an accurate grille segmentation result.

[0137] In an alternative embodiment, the segmentation unit 113 is configured to segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain a vehicle grille sub-image for each grille sub-category.

[0138] In an alternative embodiment, the segmenting the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain a vehicle grille sub-image for each grille sub-category includes:

[0139] Inputting the vehicle grille image of the target vehicle image into the second grille segmentation network to obtain a grille segmentation result. The grille segmentation result includes a sub-category vector for each pixel point. The grille sub-category corresponding to the maximum probability value in the sub-category vector of each pixel point is selected as the grille sub-category of the pixel point;

[0140] Randomly select a grille sub-category as the target grille sub-category;

[0141] Setting the pixel value of the pixel points of the target grille sub-category in the grille segmentation result to 1, and setting the pixel values of the pixel points in other regions to 0 to obtain a mask image of the target grille sub-category;

[0142] Multiplying the mask image of the target grille sub-category by the vehicle grille image of the target vehicle image to obtain a vehicle grille sub-image of the target grille sub-category;

[0143] Traverse all grille sub-categories to obtain a vehicle grille sub-image for one grille sub-category.

[0144] Among them, the grille sub-categories include three types: vehicle logo, grille frame, and grille bright strip, and each grille sub-category corresponds to a vehicle grille sub-image.

[0145] In an alternative embodiment, the damage detection unit 114 is configured to input all vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image.

[0146] In an alternative embodiment, the inputting all vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image includes:

[0147] Stacking the vehicle grille sub-images of each grille sub-category together in a fixed order to construct a three-dimensional vehicle grille sub-image;

[0148] Inputting the three-dimensional vehicle grille sub-image into a preset damage detection network to output the damage detection result of the vehicle grille components in the target vehicle image, where the damage detection result includes the damage types and location information of all damages in the vehicle grille components of the target vehicle image.

[0149] Among them, the size of the three-dimensional vehicle grille sub-image is w×h×3, which can reflect the vehicle grille sub-image information of each grille sub-category in the target vehicle image. Here, w×h represents the size information of the vehicle grille sub-image of each grille sub-category, and 3 corresponds to 3 different grille sub-categories.

[0150] In this alternative embodiment, the damage detection result includes the damage types and location information of all damages in the vehicle grille components of the target vehicle image. The damage types include 11 types: logo abrasion, logo fracture, logo missing, grille frame abrasion, grille frame fracture, grille frame missing, grille frame deformation, grille bright strip abrasion, grille bright strip fracture, grille bright strip missing, and grille bright strip deformation. The location information is a rectangular frame containing the damaged area. The schematic diagram of the acquisition process of the damage detection result is as Figure 2 shown.

[0151] In this alternative embodiment, the input of the preset damage detection network is a three-dimensional vehicle grille sub-image, and the output is the damage detection result of the three-dimensional vehicle grille sub-image. The preset damage detection network can adopt existing object detection networks such as RetinaNet, YOLOV5, and CenterNet. The acquisition process of the preset damage detection network includes: building an initialized preset damage detection network; collecting a large number of three-dimensional vehicle grille sub-images as sample data, and manually annotating the damage detection results of each sample data to obtain training data; training the initialized preset damage detection network based on the training data to obtain the preset damage detection network.

[0152] As can be seen from the above technical solutions, the present application uses a vehicle component segmentation network to extract the image information of the vehicle grille component from the vehicle image, further performs a refined division on the image information of the vehicle grille component to obtain the image information of each grille subcategory, and obtains the damage detection result of the vehicle grille component from the image information of each grille subcategory, thereby improving the accuracy of damage detection of the vehicle grille component.

[0153] Please refer to Figure 4 , which is a schematic structural diagram of an electronic device provided by an embodiment of the present application. The electronic device 1 includes a memory 12 and a processor 13. The memory 12 is used to store computer-readable instructions, and the processor 13 is used to execute the computer-readable instructions stored in the memory to implement the method for detecting damage to a vehicle grille component based on artificial intelligence described in any of the above embodiments.

[0154] In an optional embodiment, the electronic device 1 further includes a bus and a computer program stored in the memory 12 and executable on the processor 13, such as a program for detecting damage to a vehicle grille component based on artificial intelligence.

[0155] Figure 4 Only the electronic device 1 with a memory 12 and a processor 13 is shown. Those skilled in the art can understand that Figure 4 the shown structure does not limit the electronic device 1, and it may include fewer or more components than shown, or combine certain components, or have different component arrangements.

[0156] In combination with Figure 1 , the memory 12 in the electronic device 1 stores multiple computer-readable instructions to implement a method for detecting damage to a vehicle grille component based on artificial intelligence, and the processor 13 can execute the multiple instructions to implement:

[0157] Build a first vehicle component segmentation network, and train the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network;

[0158] Collect a target vehicle image, and obtain a vehicle grille image of the target vehicle image based on the second vehicle component segmentation network;

[0159] Build a first grille segmentation network, and train the first grille segmentation network according to the cross-entropy loss function to obtain a second grille segmentation network;

[0160] Segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain vehicle grille subgraphs of each grille subcategory;

[0161] Input all vehicle grille sub - images into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image.

[0162] Specifically, for the specific implementation method of the above - mentioned instructions by the processor 13, reference can be made to Figure 1 the description of the relevant steps in the corresponding embodiment, which will not be elaborated here.

[0163] Those skilled in the art can understand that the schematic diagram is only an example of the electronic device 1, and does not constitute a limitation on the electronic device 1. The electronic device 1 can be of a bus - type structure or a star - type structure. The electronic device 1 can also include more or fewer other hardware or software than shown in the figure, or different component arrangements. For example, the electronic device 1 can also include input - output devices, network access devices, etc.

[0164] It should be noted that the electronic device 1 is only an example. Other existing or future - emerging electronic products that can be adapted to this application should also be included within the protection scope of this application and are hereby incorporated by reference.

[0165] Among them, the memory 12 includes at least one type of readable storage medium. The readable storage medium can be non - volatile or volatile. The readable storage medium includes flash memory, mobile hard disks, multimedia cards, card - type memories (such as SD or DX memories, etc.), magnetic memories, magnetic disks, optical disks, etc. The memory 12 can be an internal storage unit of the electronic device 1 in some embodiments, such as the mobile hard disk of the electronic device 1. The memory 12 can also be an external storage device of the electronic device 1 in other embodiments, such as a plug - in mobile hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a Flash Card, etc. equipped on the electronic device 1. The memory 12 can not only be used to store application software installed in the electronic device 1 and various types of data, such as the code of the vehicle grille component damage detection program based on artificial intelligence, etc., but also be used to temporarily store data that has been output or will be output.

[0166] In some embodiments, the processor 13 may be composed of an integrated circuit. For example, it may be composed of a single packaged integrated circuit, or may be composed of multiple packaged integrated circuits with the same or different functions, including the combination of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips, etc. The processor 13 is the control core (Control Unit) of the electronic device 1, connecting various components of the entire electronic device 1 through various interfaces and circuits. By running or executing programs or modules stored in the memory 12 (such as executing an artificial intelligence-based vehicle grille component damage detection program, etc.), and by calling the data stored in the memory 12, it executes various functions of the electronic device 1 and processes data.

[0167] The processor 13 executes the operating system of the electronic device 1 and various installed application programs. The processor 13 executes the application programs to implement the steps in the above-mentioned embodiments of various artificial intelligence-based vehicle grille component damage detection methods, such as Figure 1 the steps shown.

[0168] Exemplarily, the computer program may be divided into one or more modules / units, and the one or more modules / units are stored in the memory 12 and executed by the processor 13 to complete the present application. The one or more modules / units may be a series of computer-readable instruction segments capable of completing specific functions, and these instruction segments are used to describe the execution process of the computer program in the electronic device 1. For example, the computer program may be divided into a first training unit 110, an acquisition unit 111, a second training unit 112, a segmentation unit 113, and a damage detection unit 114.

[0169] The above-mentioned integrated units implemented in the form of software function modules may be stored in a computer-readable storage medium. The above-mentioned software function modules are stored in a storage medium, including several instructions for causing a computer device (which may be a personal computer, a computer device, or a network device, etc.) or a processor (Processor) to execute parts of the artificial intelligence-based vehicle grille component damage detection methods described in the various embodiments of the present application.

[0170] If the modules / units integrated in the electronic device 1 are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, to implement all or part of the processes in the above-mentioned embodiment methods of the present application, it can also be completed by a computer program instructing relevant hardware devices. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above-mentioned various method embodiments can be implemented.

[0171] Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file or some intermediate form, etc. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disc, computer memory, read-only memory (ROM, Read-Only Memory), random access memory and other memories, etc.

[0172] Furthermore, the computer-readable storage medium mainly includes a storage program area and a storage data area. Among them, the storage program area can store an operating system, application programs required for at least one function, etc.; the storage data area can store data created according to the use of the blockchain node, etc.

[0173] The blockchain referred to in the present application is a new application mode of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, and encryption algorithm. Blockchain, essentially a decentralized database, is a string of data blocks generated by using cryptographic methods. Each data block contains information about a batch of network transactions, which is used to verify the validity (anti-counterfeiting) of the information and generate the next block. The blockchain can include a blockchain underlying platform, a platform product service layer, and an application service layer, etc.

[0174] The bus can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, in Figure 4 only one arrow is used to represent it, but it does not mean that there is only one bus or one type of bus. The bus is set to realize the connection and communication between the memory 12 and at least one processor 13, etc.

[0175] The embodiments of the present application also provide a computer-readable storage medium (not shown in the figure). Computer-readable instructions are stored in the computer-readable storage medium, and the computer-readable instructions are executed by a processor in an electronic device to implement the method for detecting damage to a vehicle grille component based on artificial intelligence described in any of the above embodiments.

[0176] In several embodiments provided by the present application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.

[0177] The modules described as separate components may or may not be physically separated. The components shown as modules may or may not be physical units, that is, they may be located in one place, or they may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0178] In addition, in each embodiment of the present application, the functional modules can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware, or in the form of a combination of hardware and software functional modules.

[0179] In addition, obviously, the word "including" does not exclude other units or steps, and the singular does not exclude the plural. The multiple units or devices described in the specification can also be implemented by one unit or device through software or hardware. Words such as first and second are used to represent names and do not indicate any specific order.

[0180] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application and not to limit them. Although the present application has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present application can be modified or equivalently replaced without departing from the spirit and scope of the technical solutions of the present application.

Claims

1. An artificial intelligence-based method for detecting damage to vehicle grille components, characterized in that, The method includes: Construct a first vehicle component segmentation network, and train the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network; Collect a target vehicle image, and obtain a vehicle grille image of the target vehicle image based on the second vehicle component segmentation network; Construct a first grille segmentation network, and train the first grille segmentation network according to a cross-entropy loss function to obtain a second grille segmentation network; Segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain vehicle grille sub-images of each grille sub-category, including: input the vehicle grille image of the target vehicle image into the second grille segmentation network to obtain a grille segmentation result, the grille segmentation result includes a sub-category vector of each pixel point, select the grille sub-category corresponding to the maximum probability value in the sub-category vector of each pixel point as the grille sub-category of the pixel point, randomly select a grille sub-category as the target grille sub-category, set the pixel value of the pixel points of the target grille sub-category in the grille segmentation result to 1, and set the pixel values of the pixel points in other areas to 0 to obtain a mask image of the target grille sub-category, multiply the mask image of the target grille sub-category by the vehicle grille image of the target vehicle image to obtain a vehicle grille sub-image of the target grille sub-category, and traverse all grille sub-categories to obtain a vehicle grille sub-image of a grille sub-category; Input all vehicle grille sub-images into a preset damage detection network to output a damage detection result of the vehicle grille component in the target vehicle image.

2. The artificial intelligence-based method for detecting damage to vehicle grille components according to claim 1, characterized in that, The constructing a first vehicle component segmentation network, and training the first vehicle component segmentation network according to a preset loss function to obtain a second vehicle component segmentation network includes: Construct a first vehicle component segmentation network, the first vehicle component segmentation network includes an encoder and a decoder; Collect a large number of vehicle images, and obtain label data of each vehicle image; Store all vehicle images and the label data of all vehicle images as an annotation data set; Train the first vehicle component segmentation network based on the annotation data set and a preset loss function to obtain a second vehicle component segmentation network. The input of the second vehicle component segmentation network is a vehicle image, and the output is a component segmentation result of the vehicle image. The component segmentation result includes a category vector of each pixel point in the vehicle image. The category vector of the pixel point includes the probability value that the pixel point belongs to each vehicle component. The vehicle components include multiple vehicle components including 2 types of vehicle grille components. The 2 types of vehicle grille components include a middle grille and a lower grille.

3. The artificial intelligence-based method for detecting damage to vehicle grille components according to claim 2, characterized in that, The preset loss function satisfies the relation: where, W×H represents the size of the vehicle image input to the first segmentation network of the vehicle component, represents the category vector of the pixel point (i,j) in the component segmentation result output by the first segmentation network of the vehicle component, represents the mean of the category vectors of all pixel points within the neighborhood range of the pixel point (i,j) in the component segmentation result output by the first segmentation network of the vehicle component, represents and is the Euclidean distance of, is the cross-entropy loss function constructed based on the label data of the vehicle image, is the adjustment coefficient, and its value range is [0,1], is the value of the preset loss function.

4. The artificial intelligence-based method for detecting damage to vehicle grille components according to claim 1, characterized in that, The collecting a target vehicle image, and obtaining a vehicle grille image of the target vehicle image based on the second vehicle component segmentation network includes: Collect the target vehicle image, input the target vehicle image into the second vehicle component segmentation network to obtain the component segmentation result of the target vehicle image. The component segmentation result includes the class vector of each pixel point, and select the vehicle component type corresponding to the maximum probability value in the class vector of each pixel point as the vehicle component type of the pixel point; Set the pixel value of the pixel points with the vehicle component type of the vehicle grille component in the component segmentation result to 1, and set the pixel values of other areas to 0 to obtain the mask image of the vehicle grille component. The vehicle grille component includes a middle grille and a lower grille; Multiply the mask image of the vehicle grille component by the target vehicle image to obtain the vehicle grille image of the target vehicle image.

5. The artificial intelligence-based method for detecting damage to vehicle grille components according to claim 1, characterized in that, The building of the first grille segmentation network and training the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network includes: Build the first grille segmentation network, and the first grille segmentation network includes an encoder and a decoder; Collect a large number of vehicle grille images and obtain the label data of each vehicle grille image; Train the first grille segmentation network based on the vehicle grille image, the label data of the vehicle grille image and the cross-entropy loss function to obtain the second grille segmentation network. The input of the second grille segmentation network is the vehicle grille image, and the output is the grille segmentation result of the vehicle grille image. The grille segmentation result includes the sub-class vector of each pixel point in the vehicle grille image. The sub-class vector of the pixel point includes the probability value that the pixel point belongs to each grille sub-category. The grille sub-categories include a vehicle logo, a grille frame and grille bright strips.

6. The artificial intelligence-based method for detecting damage to vehicle grille components according to claim 1, characterized in that, The inputting all the vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image includes: Stack the vehicle grille sub-images of each grille sub-category together in a fixed order to construct a three-dimensional vehicle grille sub-image; Input the three-dimensional vehicle grille sub-image into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image. The damage detection result includes the damage types and location information of all damages in the vehicle grille component of the target vehicle image.

7. An artificial intelligence-based device for detecting damage to vehicle grille components, the device being used to implement the artificial intelligence-based method for detecting damage to vehicle grille components according to any one of claims 1 to 6, characterized in that, The device includes: The first training unit is used to build the first vehicle component segmentation network and train the first vehicle component segmentation network according to a preset loss function to obtain the second vehicle component segmentation network; The acquisition unit is used to collect the target vehicle image and obtain the vehicle grille image of the target vehicle image based on the second vehicle component segmentation network; The second training unit is used to build the first grille segmentation network and train the first grille segmentation network according to the cross-entropy loss function to obtain the second grille segmentation network; The segmentation unit is used to segment the vehicle grille image of the target vehicle image according to the second grille segmentation network to obtain the vehicle grille sub-images of each grille sub-category; The damage detection unit is used to input all the vehicle grille sub-images into a preset damage detection network to output the damage detection result of the vehicle grille component in the target vehicle image.

8. An electronic device, characterized in that, The electronic device includes: A memory storing computer-readable instructions; and A processor that executes the computer-readable instructions stored in the memory to implement the method for detecting damage to a vehicle grille component based on artificial intelligence according to any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, Computer-readable instructions are stored on the computer-readable storage medium, and when the computer-readable instructions are executed by a processor, the method for detecting damage to a vehicle grille component based on artificial intelligence according to any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Lane sideline detection method and device, storage medium and electronic equipment

    CN114332819A

  • Method for detecting damage to outside of human body on basis of semantic segmentation network, and related device

    WO2021056705A1