WO2020140371A1 - 基于深度学习的识别车辆损伤的方法和相关装置 - Google Patents

基于深度学习的识别车辆损伤的方法和相关装置 Download PDF

Info

Publication number
WO2020140371A1
WO2020140371A1 PCT/CN2019/088801 CN2019088801W WO2020140371A1 WO 2020140371 A1 WO2020140371 A1 WO 2020140371A1 CN 2019088801 W CN2019088801 W CN 2019088801W WO 2020140371 A1 WO2020140371 A1 WO 2020140371A1
Authority
WO
WIPO (PCT)
Prior art keywords
picture
area
convolution
feature
residual
Prior art date
Application number
PCT/CN2019/088801
Other languages
English (en)
French (fr)
Inventor
石磊
马进
王健宗
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2020140371A1 publication Critical patent/WO2020140371A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/08Insurance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features

Definitions

  • the present application relates to the field of computer technology, and in particular to a method and related device for identifying vehicle damage based on deep learning.
  • Motor vehicle insurance refers to a type of commercial insurance that is liable for compensation for personal injury or property damage caused by natural disasters or accidents. In the process of claiming compensation for motor vehicle insurance, insurance companies need to determine and identify whether the motor vehicle is damaged and the type of vehicle damage, etc., in order to carry out liability identification and claim settlement.
  • the embodiments of the present application provide a method and a related device for identifying a vehicle damage based on deep learning, to solve the problem of not being able to identify a part with a relatively light vehicle loss.
  • a method for identifying vehicle damage based on deep learning including:
  • the resolution of the second picture is higher than the resolution of the first picture
  • the second image is detected by a damage detection model based on a single-shot multibox detector (SSD) algorithm to obtain first information, the first information includes the damage location in the second Position coordinates in the picture;
  • SSD single-shot multibox detector
  • a device for identifying vehicle damage based on deep learning including:
  • the picture acquisition module is used to obtain a first picture corresponding to a target vehicle, the target vehicle is a damaged vehicle to be identified, and the first picture is a picture including a damaged part of the target vehicle;
  • a picture processing module configured to process the first picture through a dense residual network to obtain a second picture, the resolution of the second picture is higher than the resolution of the first picture;
  • a picture detection module configured to detect the second picture through a damage detection model based on a single-point multi-box detector algorithm to obtain first information, the first information including the damaged part in the second picture Position coordinates;
  • the marking module is used to mark the area where the damaged part is located in the second picture according to the position coordinates.
  • another device for identifying vehicle damage based on deep learning including a processor, a memory, and an input-output interface, where the processor, memory, and input-output interface are connected to each other, wherein the input-output interface is used to To transmit or receive data, the memory is used to store an application code of an image recognition-based policy entry device to perform the above method, and the processor is configured to perform the above method of the first aspect.
  • a computer non-volatile readable storage medium stores a computer program, and the computer program includes program instructions, which are executed by a processor When the processor executes the method of the first aspect.
  • the parts with smaller damage types can be identified and located, and the accuracy of the identification and positioning is improved.
  • FIG. 1 is a schematic flowchart of a method for identifying vehicle damage based on deep learning according to an embodiment of the present application
  • FIG. 2 is a schematic diagram of a picture including a damaged part of a vehicle provided by an embodiment of the present application
  • FIG. 3 is a schematic diagram of a network architecture of a residual-dense network provided by an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a residual dense block provided by an embodiment of the present application.
  • FIG. 5 is a schematic diagram of a convolution network structure in a damage detection model provided by an embodiment of the present application.
  • FIG. 6 is a schematic diagram of the relationship between a convolution feature map and a convolution feature sub-map provided by an embodiment of the present application
  • FIG. 7 is a schematic diagram of the mapping relationship between the convolution feature map and the original picture provided by an embodiment of the present application.
  • FIG. 8 is a schematic flowchart of determining the position coordinates of the damaged part of the target vehicle in the second picture according to the position coordinates corresponding to the second area provided by an embodiment of the present application;
  • FIG. 9 is a schematic diagram of marking a picture provided by an embodiment of the present application.
  • FIG. 10 is a schematic flowchart of another method for identifying vehicle damage based on deep learning provided by an embodiment of the present application.
  • FIG. 11 is a schematic diagram of marking a picture provided by an embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a device for identifying vehicle damage based on deep learning provided by an embodiment of the present application.
  • FIG. 13 is a schematic structural diagram of another device for identifying vehicle damage based on deep learning provided by an embodiment of the present application.
  • the solution of the embodiment of the present application is applicable to the scenario of vehicle fixed damage.
  • vehicle damage when a vehicle has a traffic accident (such as a rear-end collision, etc.), the insurer can use a picture collection device (such as a mobile phone, video camera, SLR camera, etc.) to deal with the accident vehicle (refer to the vehicle that has a traffic accident ) Take pictures of each damaged part to obtain one or more pictures containing the damaged parts of the vehicle, and then upload the pictures containing the damaged parts of the vehicle to the fixed-vehicle damage-determining device that determines the damage of the vehicle through the picture collection device (such as servers, cloud platforms, etc.).
  • a picture collection device such as a mobile phone, video camera, SLR camera, etc.
  • Target detection models include residual-dense networks and damage detection models.
  • the residual-dense network performs shallow feature extraction, hierarchical feature extraction, global fusion, and upsampling on the picture in sequence, and extracts and restores the details of the picture to improve the resolution of the picture.
  • the damage detection model performs target recognition detection on the improved resolution picture, identifies and locates the vehicle damage part in the picture, and then marks the improved resolution picture to obtain the marked picture.
  • the vehicle damage determination device sends the marked picture to the picture collection device, and the marked picture can be displayed on the picture collection device.
  • the vehicle damage determination device can also identify and detect the damage type of the vehicle damage part after locating the vehicle damage part, and then mark the picture after the improved resolution to obtain the marked picture, and then Send the marked pictures to the picture collection device.
  • the vehicle damage determination device may be the same device as the picture collection device.
  • the picture collection device ie, the vehicle damage determination device
  • the vehicle damage determination device may directly input the collected pictures to the target detection
  • the damaged parts of the vehicle are identified and located.
  • the vehicle damage determination device uses a dense residual network to improve the resolution of the picture containing the damaged part of the vehicle, so that the details of the picture are clearer, so that the damage detection model can detect A more subtle damage location has been created, which improves the accuracy of the vehicle's fixed damage in the scene of the vehicle's fixed damage.
  • FIG. 1 is a schematic flowchart of a method for identifying a vehicle damage based on deep learning provided by an embodiment of the present application. This method can be implemented on the aforementioned vehicle damage determination device. As shown in the figure, the method includes the following steps:
  • the target vehicle is a damaged vehicle to be identified, and the first picture is a picture including a damaged part of the target vehicle.
  • the first picture can be obtained from a local or a network.
  • the first picture can be obtained from the network; for another example, the device that collects the first picture and the device that determines the loss of the vehicle are The same device can get the first picture from the local; another example, the device that collects the first picture and the device that determines the damage of the vehicle are not the same device, the user of the fixed loss (refers to the person responsible for the loss of the vehicle) Copy the first picture collected by the device that collects the first picture to the device that fixes the vehicle by means of SD card copying, and then the first picture can be obtained locally.
  • the fixed loss refers the person responsible for the loss of the vehicle
  • the picture including the damaged part of the target vehicle refers to the picture of the damaged part of the vehicle in the picture content, where the damaged part of the vehicle refers to the paint falling, dent, chipping, falling caused by the vehicle scratching, collision, etc. Waiting for the situation.
  • the picture including the damaged part of the target vehicle may be as shown in FIG. 2.
  • the damaged part of the target vehicle included in the picture is located at the lower right of the picture, and the damaged part is the vehicle tail light Next to the shell.
  • S102 Process the first picture through a dense residual network to obtain a second picture.
  • the resolution of the second picture is higher than the resolution of the first picture.
  • the residual dense network is a network structure that combines the characteristics of the residual network and the densely connected network to utilize all layered features of the original low-resolution image to construct a high-resolution image.
  • the schematic diagram of the network architecture of the residual-dense network can be shown in Figure 3.
  • the network architecture includes four parts: 1) Shallow feature extraction network (SFENet).
  • the shallow feature extraction network consists of two convolutional layers for extracting pictures Shallow features; 2) residual-dense network, which consists of multiple residual-dense blocks (RDB), used to extract the hierarchical features of the picture; 3) dense feature fusion network (DFF), dense feature fusion network It is used to perform global feature fusion and global residual learning on the hierarchical features extracted through the residual dense network to obtain the global features of the picture; 4) Upsampling network (UPNet), the upsampling network is used to upload the global features of the picture Sampling and convolution operation to get the picture after increasing the resolution.
  • RDB residual-dense blocks
  • DFF dense feature fusion network
  • the following specifically describes the process of processing the first picture through the residual-dense network to obtain the second picture.
  • the shallow feature extraction network based on the dense residual network performs convolution processing to obtain the shallow feature map corresponding to the first picture.
  • the shallow feature extraction network may include two convolutional layers as shown in FIG. 3, and the shallow feature extraction network based on the residual dense network performs convolution processing to obtain the shallow feature map corresponding to the second picture as : Convolve the first picture with the first convolution kernel to obtain the first convolution feature map; convolve the second picture with the second convolution kernel to obtain the second convolution feature map and convolve the second convolution feature map
  • the feature map is determined as the shallow feature map corresponding to the first picture.
  • the first convolution kernel and the second convolution kernel are convolution kernels of two convolutional layers, respectively, and the physical meaning of the convolution kernel is an a*a (such as 1*1, 3*3, etc.) matrix.
  • the first picture can be quantized to obtain a pixel matrix corresponding to the first picture.
  • the pixel matrix is an m*n matrix, m*n is equal to the pixels of the first picture, and the value in the pixel matrix is the A quantized value obtained by comprehensively quantizing the brightness, chroma, etc. in a picture. For example, if the pixels of the first picture are 1920*2040 pictures, the pixel matrix corresponding to the first picture is a 1920*2040 matrix, and the value in the matrix is the quantized value of the pixel corresponding to the value.
  • the residual-dense network based on the residual-dense network performs convolution and linear correction processing on the shallow feature convolution map to obtain multiple residual-dense feature maps corresponding to the first picture.
  • the residual dense network may include multiple residual dense blocks as shown in FIG. 3, and a schematic structural diagram of the residual dense blocks is shown in FIG. 4, wherein a residual dense block includes multiple convolutional layers, each The convolutional layer is used to perform convolution calculation on the results of the previous convolutional layers. Each convolutional layer is connected to a linear correction layer to linearly correct the output of the convolutional layer connected to the linear correction layer.
  • the following residual dense network includes D residual dense blocks, and each residual dense block includes (C+1) convolutional layers.
  • the residual dense network based on the residual network convolves the shallow feature convolution map And linear correction processing, the process of obtaining the residual-dense feature map corresponding to the first picture is introduced.
  • the convolutional layer in the first residual dense block performs convolution and linear correction on the shallow feature map corresponding to the first picture to obtain the first residual dense feature map corresponding to the first residual dense block; through the second The convolutional layer in the residual dense block performs convolution and linear correction on the first residual dense feature map to obtain the second residual dense feature map corresponding to the second residual dense block; ...; through the D residual The convolutional layer in the dense block performs convolution and linear correction on the (D-1) residual dense feature map to obtain the D-th residual dense feature map corresponding to the D-th residual dense block.
  • the first residual-dense feature map, the second residual-dense feature map, ..., the D-th residual-dense feature map are determined as a plurality of residual-dense feature maps.
  • the convolutional layer in the d-th residual dense block performs convolution and linear correction on the (d-1)-dense residual feature map to obtain the d-th residual corresponding to the d-th residual dense block
  • Difference-dense feature map d is each positive integer from 1 to D
  • the 0th residual-dense feature map in the (d-1) residual-dense feature map is the shallow feature map corresponding to the first picture
  • d Residual dense feature maps are determined as multiple residual dense feature maps corresponding to the first picture.
  • the convolutional layer in the d-th residual dense block performs convolution and linear correction on the (d-1)-th residual dense feature map to obtain the d-th residual dense feature map corresponding to the d-th residual dense block
  • the specific process is: convolution processing of the (d-1) residual dense feature map through the first convolution kernel (convolution kernel of the first layer convolution layer) in the d residual dense block
  • the convolution feature map corresponding to the first convolution kernel linear correction processing is performed on the convolution feature map corresponding to the first convolution kernel through the linear correction layer corresponding to the first convolution kernel to obtain the d1 convolution feature map
  • the second convolution kernel in the d-th residual dense block (the convolution kernel of the second convolution layer) performs convolution processing on the d2 convolution feature map to obtain the convolution feature map corresponding to the second convolution kernel
  • the d2 convolution feature map includes the (d-1) convolution feature map and the d1 convolution feature map, and the convolution feature map corresponding to the
  • the d4 convolution feature map includes the (d-1) residual dense feature map, the d1 convolution feature map, and the d3 convolution feature map.
  • the linear correction layer corresponding to the 3 convolution kernel performs linear correction processing on the convolution feature map corresponding to the third convolution kernel to obtain the d5 convolution feature map; ...; through the C convolution in the d residual dense block
  • the kernel (convolution kernel of the convolution layer of layer C) performs convolution processing on the d(2C-2) convolution feature map to obtain the convolution feature map corresponding to the C convolution kernel, and the d(2C-2) )
  • Convolutional feature map includes (d-1) residual dense feature map, d1 convolution feature map, ..., d(2C-3) convolution feature map, through the convolution corresponding to the Cth convolution kernel
  • the feature map is linearly corrected to obtain the d(2C-1) convolution feature map; the (2+1) convolution kernel (1*1 convolution kernel) in the d
  • the d2C convolution feature map includes the (d-1) residual dense feature map, the d1 convolution feature map,... , The d(2C-3) convolution feature map, the d2C convolution feature map; fusing the d(2C+1) convolution feature map and the (d-1) residual dense feature map to obtain the The d-th residual dense feature map corresponding to the d-residue dense block.
  • a dense feature fusion network based on a dense residual network performs dense feature fusion on multiple local feature maps to obtain a global feature map corresponding to the first picture.
  • the multiple local feature maps include shallow feature maps and multiple residual dense features Figure.
  • the dense feature fusion network may include a global feature fusion layer and a global residual learning layer as shown in FIG. 3.
  • the dense feature fusion network based on the dense residual network performs dense feature fusion on multiple local feature maps to obtain the global feature map corresponding to the first picture.
  • the multiple global feature maps are fused to obtain the first global convolution feature Figure;
  • the first convolution kernel (1*1 convolution kernel) in the dense fusion network the first global convolution feature map is convolved to obtain the second global convolution feature map; the corresponding to the first picture
  • the shallow convolution feature map and the second global convolution feature map perform residual learning to obtain a global feature map corresponding to the first picture.
  • the up-sampling network based on the residual-dense network performs up-sampling and convolution on the global feature map to obtain the second image.
  • the upsampling network may include an upsampling layer and a convolution layer as shown in FIG. 3, and in specific implementation, subpixel convolutional nerves may be combined with interpolation methods such as neighbor interpolation, bilinear interpolation, mean interpolation, and median interpolation.
  • the network upsamples the global feature map corresponding to the first picture to obtain an upsampled feature map, and then uses the convolution kernel corresponding to the last convolution layer to convolve the upsampled feature map to obtain the pixel matrix corresponding to the second picture To obtain the second picture according to the pixel matrix corresponding to the second picture.
  • step four extract the local features of the picture through steps one and two, and then fuse the local features of the picture through step three to obtain the global features, and then learn the local features through residual learning.
  • the details are restored, and finally the picture is restored in step four to obtain a picture with the size of the original picture. Since the feature extraction and learning of the previous steps restore the details of the picture, the restored picture with the original size Compared with the original picture, the resolution is improved, that is, the resolution of the second picture is higher than that of the first picture.
  • S103 Detect the second picture through the damage detection model based on the single-point multi-box detection algorithm to obtain the first information, where the first information includes the position coordinates of the damaged part of the target vehicle in the second picture.
  • SSD is a depth-based one-stage target learning algorithm, which predicts the category and offset corresponding to the position frame through a convolution kernel on the feature map (the position frame corresponds to the figure Which position).
  • a schematic diagram of the damage detection model based on the SSD algorithm can be shown in FIG. 5, the damage detection model includes several convolutional layers, different convolutional layers correspond to convolution kernels of different sizes, and the pictures are convoluted by convolution kernels of different sizes Convolution processing, you can get convolution feature maps of different sizes. Convolution kernels of different sizes correspond to different multiple prior frames. By using the prior frame corresponding to the convolution kernel, the convolution map corresponding to the convolution kernel is predicted. After processing, multiple prediction frames can be obtained, and the position of the object in the prediction frame and the category of the object can be determined according to the category and confidence of the prediction frame.
  • Convolution processing is performed on the second picture based on the convolution layer in the damage detection model to obtain multiple convolution feature maps with different sizes, and each convolution feature map includes multiple convolution feature sub-maps.
  • the structure of the convolutional network in the damage detection model can be as shown in FIG. 5, the role of the convolutional layer can be divided according to function, and the convolutional layer can be divided into a general convolutional layer and a convolutional feature layer.
  • the convolution layer is only used to convolve the input image in the convolutional network of the damage detection model, as shown in Figure 5 except for the convolution layers labeled f1, f2, f3, f4, f5, and f6
  • the convolutional feature layer is a convolutional layer used to generate a convolutional feature map for identification and detection, such as the convolutional layers labeled f1, f2, f3, f4, f5, and f6 in FIG.
  • the multiple convolution feature maps with different sizes specifically refer to: the convolution maps corresponding to the results respectively output by the convolution feature layers in the damage detection model, and the results are quantified by the convolution map. Is the result of that output.
  • Each convolution feature layer corresponds to multiple convolution feature maps of the same size. The smaller the size of the convolution feature layer, the greater the number of convolution feature maps corresponding to the convolution feature layer.
  • the convolutional layer in the damage detection model is shown in FIG. 5, then the convolution maps corresponding to the results of the output of the convolutional layers labeled f1, f2, f3, f4, f5, and f6 in FIG. 5 are used as multiple Convolution feature maps of different sizes, then the size of the convolution feature map corresponding to the convolution layer labeled f1 is 38*38, and the convolution layer labeled f1 corresponds to multiple convolution feature maps of size 38*38 ,
  • the size of the convolutional feature map corresponding to the convolutional layer labeled f2 is 19*19, the size of the convolutional feature map corresponding to the convolutional layer labeled f3 is 10*10, and the size of the convolutional layer labeled f4 corresponds to
  • the size of the convolutional feature map is 5*5, the size of the convolutional feature map corresponding to the convolutional layer labeled f5 is 3*3, and the size of the convolutional feature map
  • the size of the second picture can be adjusted to the size of the input picture corresponding to the damage detection model (the size can be 300*300 or 512*512) to obtain the third picture
  • the size of the third picture is The size of the input picture corresponding to the damage detection model. Then input the third picture into the convolutional network of the damage detection model, use the third picture as the input of the first convolutional layer in the convolutional network, and use the convolutional checklist corresponding to the convolutional layer in the convolutional network in turn
  • the result output by the previous convolutional layer is subjected to convolution processing, and then the convolution map corresponding to the result output by the convolution feature layer in the convolution network is determined as a plurality of convolution feature maps with different sizes.
  • using the convolution kernel corresponding to the convolution layer to perform convolution processing on the result output by the previous convolution layer specifically refers to using the matrix corresponding to the convolution kernel to multiply the result output by the previous convolution layer, and using the convolution layer
  • the corresponding convolution kernel performs a convolution process on the output result of the previous convolution layer to obtain a matrix with a size corresponding to the size of the convolution layer, and the image corresponding to the matrix is the convolution map corresponding to the convolution layer.
  • the linear correction layer can also be used to correct the output of the convolutional layer, and then The correction processing result is used as the input of the next convolutional layer, and then the output of the linear correction layer connected after the convolutional feature layer is used as multiple convolutional feature maps with different sizes.
  • the convolutional network of the damage detection model includes 7 convolutional layers, where convolutional layer 1 is the first convolutional layer of the convolutional network, and convolutional layer 7 is the convolutional network The last convolutional layer.
  • convolutional layer 3 convolutional layer 4
  • convolutional layer 6 convolutional layer 7 are convolutional feature layers.
  • the third picture is convoluted using the convolution kernel corresponding to the convolution layer 1 to obtain the first convolution map; the first convolution diagram corresponding to the convolution layer 2 is used to check the first Process the convolution map to obtain the second convolution map; ...; use the convolution layer 7 to process the sixth convolution map to obtain the seventh convolution feature map; then the third convolution map and the fourth convolution map
  • the graph, the sixth convolution map, and the seventh convolution map are determined as convolution feature maps. It should be noted that the examples here are only used to illustrate the process of convolving the third picture with a convolution network, and do not limit the embodiments of the present application.
  • the convolution network may include more Convolutional layers and more convolutional feature layers.
  • the convolutional feature submap refers to the feature unit contained in each convolutional feature map.
  • the convolutional feature map may be as shown in FIG. Contains 16 feature units, and each feature unit is a cell in the convolutional feature map, numbered 1 to 16, respectively, that is, the convolutional feature map contains 16 feature subgraphs.
  • the target convolution feature information includes convolution feature information corresponding to each convolution feature submap in the multiple convolution feature submaps.
  • the convolution feature information corresponding to each convolution feature submap refers to the content corresponding to the convolution feature submap in the convolution feature map using the a priori frame corresponding to the convolution feature map as the prediction frame.
  • the size of the a priori frame corresponding to different convolution feature maps and the number of a priori frames are different, and one convolution feature map may correspond to multiple a priori frames with different sizes.
  • the convolution feature map is shown in FIG. 6, then for the convolution feature sub-picture 11 in the convolution feature map, the convolution feature information corresponding to the convolution feature sub-picture 11 is three different sizes in FIG. 6 Information of the convolutional feature map corresponding to the dotted frame of.
  • the prior frame corresponding to each convolution feature map can be used as the prediction frame to determine the information in the prediction frame corresponding to each convolution feature sub-picture in each convolution feature map, and then the The information is determined as the convolution feature information of the convolution feature submap corresponding to the prediction frame, thereby determining the target convolution feature information corresponding to each convolution feature map.
  • the target convolutional feature information corresponding to the convolutional feature map can be determined as: the priori corresponding to the convolutional feature of size 4*4
  • the frame is used as the prediction frame, and the prediction frame is centered on the feature unit 1 to determine the information corresponding to the prediction frame, and the information corresponding to the prediction frame is determined as the convolution feature information corresponding to the feature unit 1;
  • the prediction frame is based on the feature unit 2 Center, determine the information corresponding to the prediction frame, and determine the information corresponding to the frame as the convolution feature information corresponding to the feature unit 1; ...; center the prediction frame on the feature unit 16 to determine the information corresponding to the prediction frame,
  • the information corresponding to the prediction frame is determined as the convolution feature information corresponding to the feature unit 16; finally, the convolution feature information corresponding to the feature unit 1 to the feature unit 16 is determined as the target convolution feature information corresponding to the convolution feature map.
  • the position coordinates corresponding to the convolution feature information refer to the position coordinates corresponding to when the prediction frame corresponding to the convolution feature information is mapped back to the second picture
  • one convolution feature information corresponds to four position coordinates, which are respectively Corresponding to the four vertices of the prediction frame, the coordinates of the four points obtained by mapping the four vertices of the prediction frame back to the original image are the position coordinates corresponding to the convolution feature information.
  • each point in the convolutional feature map has a corresponding relationship with the point or area in the second picture, according to the corresponding relationship Determine the position coordinates of the four points corresponding to the prediction frame in the second picture, and then determine the position coordinates of the fourth point corresponding to the prediction frame in the second picture as the position coordinates corresponding to the convolution feature information corresponding to the prediction frame , Determine the area formed by the point corresponding to the position coordinate as the first area corresponding to the convolution feature information.
  • the prediction frame corresponding to the convolution feature information is shown in FIG. 7, and the four vertices of the prediction frame are a1, a2, a3, and a4, respectively.
  • b1, b2, b3 and b4, b1's position coordinates in the second picture are (b11, b12), b2's position coordinates in the second picture are (b21, b22), b3's position coordinates in the second picture are (b31, b34), b4's position coordinates in the second picture are (b41, b44), then b1's position coordinates (b11, b12), b2's position coordinates (b21, b22), b3's position coordinates (b31 , B32) and b4 position coordinates (b41, b42) are determined as the position coordinates corresponding to the convolution feature information, and the area formed in the second picture where the points b1, b2, b3 and b4 are located is determined
  • the position coordinates corresponding to each convolution feature information may be determined according to the mapping relationship between the convolution feature map corresponding to the convolution feature information and the second picture.
  • determining the confidence of the first region corresponding to each convolution feature information and the attribute category corresponding to the first region are specifically: determining the matching probability between each convolution feature information and the two attribute categories in the damage detection model, The two attribute categories in the damage detection model are background and damage respectively; the maximum matching probability is determined from the matching probabilities between each convolution feature information and the two attribute categories in the damage detection model, and the maximum matching probability is determined as each The confidence of the first region corresponding to the convolution feature information, and the attribute category corresponding to the maximum matching probability is determined as the attribute category corresponding to the first region.
  • the matching degree between the information in the prediction frame and the feature information of the image of the background category, and the information and damage of the prediction frame can be calculated separately.
  • the matching degree of the image feature information of one category, the matching degree corresponding to the two categories is obtained, assuming that the matching degree of the information in the prediction frame and the feature information of the image of the background category is 0.3, and the information of the prediction frame and the damage category
  • the matching degree of the image feature information of is 0.5, then it can be determined that the matching probability between the convolution feature information and the two attribute categories in the damage detection model is 0.3 and 0.5, respectively.
  • the matching probability between the convolutional feature information and the two attribute categories in the damage detection model determines the maximum matching probability. Since 0.5 is greater than 0.3, the maximum matching probability is determined to be 0.5. Finally, the maximum matching probability is determined as the confidence of the first region corresponding to each convolution feature information, and the attribute category corresponding to the maximum matching probability is determined as the attribute category corresponding to the first region, that is, 0.5 is determined as the corresponding convolution feature information. For the confidence of the first area, the category corresponding to 0.5 is damage, and the damage is determined as the attribute category corresponding to the first area.
  • the matching probability between each convolution feature information and the two attribute categories in the damage detection model can be calculated based on the classifier in the damage detection model.
  • the degree of matching between each convolution feature information and the feature information of the image in the category of the background in the classifier and the feature information of the image in the category of damage can be calculated by the classifier in the damage detection model, according to the The matching degree determines the probability that the image corresponding to each convolution feature information is the background and the image corresponding to each convolution feature information is the damage. This probability is determined as the difference between each convolution sign information and the two attribute categories in the damage detection model. Matching probability.
  • the confidence threshold is a preset value close to 1, where a larger confidence threshold indicates that the content in the second area is more likely to be damaged.
  • the confidence threshold can be set It is equivalent to 95%, 98%.
  • the position coordinates of the damaged part of the target vehicle in the second picture are determined according to the position coordinates corresponding to the second area in the following two cases:
  • the number of the second area is one.
  • the position coordinates corresponding to the second area are determined as the position coordinates of the damaged part in the second picture.
  • the number of the second area is multiple.
  • the process of determining the position coordinates of the damaged part of the target vehicle in the second picture according to the position coordinates corresponding to the second area is shown in FIG. 8 and includes the following steps:
  • S201 Determine a second area with the highest confidence in the second area, and determine the second area with the highest confidence as the third area.
  • the second region with a confidence of 0.999 is determined as the third region.
  • S202 Calculate the degree of intersection between the fourth area and the third area.
  • the degree of area intersection is used to indicate the degree of overlap between the fourth area and the third area in the second picture.
  • the fourth area excludes the third area in the second area After the second area.
  • the fourth area refers to the area remaining after removing the third area among the plurality of second areas. For example, there are five second areas, namely second area 1, second area 2, second area 3, second area 4, and second area 5, where second area 3 is the third area, then the The second area 1, the second area 2, the second area 4 and the second area 5 are determined as the fourth area.
  • the area intersection degree may also be referred to as a cross-combination ratio, and calculating the area intersection degree of the fourth area and the third area specifically refers to calculating the degree of coincidence of the fourth area and the third area.
  • intersection ratio of the fourth area and the third area may be calculated according to the position coordinates of the fourth area and the position coordinates of the third area.
  • the IoU threshold is a critical point for evaluating the degree of coincidence between two regions, and the IoU threshold may specifically be 90%, 95%, and so on.
  • the IoU threshold When the IoU of the two regions is greater than the IoU threshold, it means that the two regions have a high degree of coincidence.
  • step S204 When the fifth area is found, step S204 is performed; when the fifth area is not found, step S205 is performed.
  • S204 Determine the third area as the target area, and exclude the third area and the fifth area from the second area.
  • step S201 When the number of the second areas is plural, step S201 is executed; when the number of the second areas is one, the second area is determined as the target area, and step S207 is executed.
  • S207 Determine the position coordinates corresponding to the target area as the position coordinates of the damaged part of the target vehicle in the second picture.
  • the regions with a high degree of coincidence in the determined second regions can be removed, so that the second region most likely to be the region where the damaged part is located can be retained.
  • S104 Mark, in the second picture, the area where the damaged part of the target vehicle is located according to the position coordinates of the damaged part of the target vehicle in the second picture.
  • the area formed by the point corresponding to the position coordinate may be marked in the second picture according to the position coordinates of the damaged location of the target vehicle in the second picture, that is, the second area is marked in the second picture.
  • the probability that the area where the damaged part of the target vehicle is located in the second picture is the damaged part may also be marked, that is, the confidence level of the second region marked in the second picture.
  • the second picture is a picture obtained by processing the picture shown in FIG. 3 through a residual-dense network, and the picture obtained after marking the second picture may be as shown in FIG. 10.
  • the picture is first processed through a dense residual network, and the partial and overall details of the picture are restored using the dense residual network to improve the picture Resolution, and then use the SSD-based damage detection model to identify the pictures with improved resolution. Since the resolution of the picture is improved, the accuracy of the recognition can be improved, and then the location with a smaller damage type can be identified and located , Improve the accuracy of identification and positioning.
  • a large number of pictures can also be used as training samples to train the initial damage detection model to obtain the Damage detection model.
  • FIG. 10 is a schematic flowchart of another method for identifying a vehicle damage based on deep learning according to an embodiment of the present application. The method may be implemented on the aforementioned vehicle damage determination device. As shown in the figure, the method includes the following steps:
  • the target vehicle is a damaged vehicle to be identified, and the first picture is a picture including a damaged part of the target vehicle.
  • S302. Process the first picture through a dense residual network to obtain a second picture.
  • the resolution of the second picture is higher than the resolution of the first picture.
  • S303 Detect the second picture through the damage detection model based on the single-point multi-box detection algorithm to obtain the first information, where the first information includes the position coordinates of the damaged part of the target vehicle in the second picture.
  • S304 Extract a third picture including the damaged part of the target vehicle from the second picture according to the position coordinates of the damaged part of the target vehicle in the second picture, and the size of the third picture is smaller than the second picture.
  • the area formed by the point corresponding to the position coordinate can be cut out from the second picture according to the position coordinate of the damaged location of the target vehicle in the second picture, and the area formed by the point corresponding to the position coordinate is The third picture.
  • S305 Recognize the third picture through the damage type recognition model obtained in advance, and obtain the damage type of the damaged part of the target vehicle.
  • the damage type identification model refers to a classification algorithm obtained by training the sample data, and can perform relevant data processing according to the input picture containing the damaged part, and then output the classification model of the damage type of the damaged part in the picture .
  • the injury type may refer to the degree of injury at the injury site.
  • the injury type may include minor injury, moderate injury, severe injury, and so on.
  • the damage type may also refer to the name and damage situation of the damaged part, for example, the damage type may include the depression of the vehicle shell, the cracking of the vehicle tail light, the paint of the vehicle shell, etc.
  • the damage type recognition model can be a damage type recognition model based on the K-nearest neighbor algorithm, a damage type recognition model based on the Naive Bayes algorithm, a damage type recognition model based on the decision tree algorithm, a damage type recognition model based on the logistic regression algorithm,
  • the damage type recognition model of the support vector machine algorithm, etc. is not limited to the description here.
  • feature extraction can be performed on the third picture to obtain feature data corresponding to the third picture, wherein depth feature extraction can be performed on the third picture through the convolution layer in the convolutional neural network to obtain the third picture correspondence Characteristic data.
  • the feature data corresponding to the third picture is sent to the damage type recognition model as an input of the damage type recognition model, and the damage type recognition model outputs the damage type corresponding to the third picture after being processed by the classification algorithm.
  • the classification algorithm used by the damage type identification model is different, and the logic corresponding to the processing performed by the damage type identification model is different.
  • the similarity distance may be an Euclidean distance, a Manhattan distance, or the like used to calculate the similarity distance between two feature data.
  • Determine the similarity value of the two pictures according to the similarity distance of the feature data determine the similarity value of the two pictures according to the similarity distance between the respective feature data corresponding to the two pictures and the preset feature data weighting formula, and the feature data weighting formula Is the similarity distance of feature data 1*weighting coefficient 1+similarity distance of feature data 2*weighting coefficient 2+...+similarity distance of feature data M*weighting coefficient M
  • M is the data dimension of the feature data of the third picture, That is, the number of feature data.
  • the weighting coefficient of each feature data in the feature data weighting formula is 1, and the multiple corresponding to the damage type recognition model contains damage. If there are 300 pictures of the part and K is 100, the process of determining the damage type corresponding to the third picture is:
  • step 2) Calculate the third picture and the damaged part respectively according to step 1) Picture 2, picture 3 containing the damaged part, ..., the similarity value of the picture 300 containing the damaged part. 3) According to the calculation results of 1) and 2), it is determined that 100 pictures containing the damaged part have a larger similarity value among the 300 pictures containing the damaged part. 4) Count the damage types corresponding to 100 pictures containing damaged parts. Assume that the damage types corresponding to 100 pictures containing damaged parts are damage type 1 (15), damage type 2 (20), and damage type 3. (30), damage type 4 (45). 5) The damage type with the highest frequency among the damage types, that is, damage type 4 is determined as the damage type corresponding to the third picture.
  • the damage type recognition model also The damage type corresponding to the third picture may be determined according to the feature data according to the processing logic of other classification algorithms.
  • S306 Mark the area where the damaged location of the target vehicle is located in the second picture according to the position coordinates of the damaged location of the target vehicle in the second picture, and mark the damage type of the damaged portion of the target vehicle in the second picture.
  • the second picture is a picture obtained by processing the picture shown in FIG. 3 through a residual-dense network, and the damage type of the second picture identified by step S305 is slight damage, which is obtained after marking the second picture
  • the picture can be shown in Figure 11.
  • the damage part is automatically completed.
  • the determination of the type of damage can help the loss-determining personnel to determine the cost of claims.
  • FIG. 12 is a schematic structural diagram of a device for identifying a vehicle damage based on deep learning provided by an embodiment of the present application.
  • the device may be the aforementioned vehicle damage-determining device or a part of the vehicle damage-determining device
  • the device 50 includes:
  • the picture obtaining module 501 is used to obtain a first picture corresponding to a target vehicle, the target vehicle is a damaged vehicle to be identified, and the first picture is a picture including a damaged part of the target vehicle;
  • a picture processing module 502 configured to process the first picture through a dense residual network to obtain a second picture, the resolution of the second picture is higher than the resolution of the first picture;
  • the image detection module 503 is configured to detect the second picture through a damage detection model based on a single-point multi-box detector algorithm to obtain first information, where the first information includes the damaged part in the second picture Position coordinates in
  • the marking module 504 is configured to mark the area where the damaged part is located in the second picture according to the position coordinates.
  • the picture processing module 502 is specifically used to:
  • the network includes multiple residual dense blocks, and the multiple residual dense feature maps are the residual dense feature maps corresponding to the respective residual dense blocks in the multiple residual dense blocks, respectively;
  • the dense feature fusion network based on the residual dense network performs dense feature fusion on multiple local feature maps to obtain a global feature map corresponding to the first picture, and the multiple local feature maps include the shallow feature map and The multiple residual dense feature maps;
  • the up-sampling network based on the residual-dense network performs up-sampling and convolution processing on the global feature map to obtain a second picture.
  • the picture processing module 502 is specifically used to:
  • D is each positive integer from 1 to D, D is the number of the plurality of residual dense blocks, and the 0th residual dense feature map in the (d-1) residual dense feature map is The shallow feature convolution map;
  • the picture detection module 503 is specifically used to:
  • target convolution feature information includes convolution feature information corresponding to each convolution feature submap in the multiple convolution feature submaps
  • the position coordinates of the damaged part in the second picture are determined according to the position coordinates corresponding to the second area.
  • the picture detection module 503 is specifically used to:
  • the maximum matching probability is determined among the matching probabilities between the respective convolutional feature information and the two attribute categories in the damage detection model, and the maximum matching probability is determined as the first corresponding to the respective convolutional feature information
  • the picture detection module 503 is specifically used to:
  • the fourth area is the second area after the third area is excluded from the second area.
  • the IoU is used to indicate the fourth area and The degree of coincidence of the third area in the second picture;
  • the third area is determined as the target area, and after the third area and the fifth area are excluded from the second area, if the second If the number of regions is still multiple, the step of determining the second region with the highest confidence in the second region and determining the region with the highest confidence as the third region is performed;
  • the third area is determined as the target area, and after the third area is excluded from the second area, if the number of the second area is still multiple , Then perform the step of determining the second region with the highest confidence in the second region, and determining the region with the highest confidence as the third region; until all target regions are determined in the second region ;
  • the second area is determined as the target area
  • the position coordinates corresponding to the target area are determined as the position coordinates of the damaged part in the second picture.
  • the device further includes:
  • the picture interception module 505 intercepts a third picture including the damaged part from the second picture according to the position coordinates of the damaged part in the second picture, and the size of the third picture is smaller than the second picture.
  • the damage type recognition module 506 is configured to recognize the third picture through a pre-trained damage type recognition model to obtain the damage type of the damaged part.
  • the marking module 504 is also used to mark the damage type of the damaged part in the second picture.
  • the device for identifying vehicle damage based on deep learning obtains a picture containing the damaged part of the vehicle, the picture is first processed through the residual dense network, and the local details and The overall details have been restored, and the resolution of the picture has been improved.
  • the SSD-based damage detection model is used to recognize the picture after the resolution has been improved. Since the resolution of the picture is increased, the accuracy of the recognition can be improved, and then the recognition can be recognized. And locate the location with less damage type, improve the accuracy of identification and positioning.
  • FIG. 13 is a schematic structural diagram of another device for identifying vehicle damage based on deep learning provided by an embodiment of the present application.
  • the device may be the aforementioned vehicle damage-determining device or a part of the vehicle damage-determining device
  • the device 60 includes a processor 601, a memory 602, and an input-output interface 603.
  • the processor 601 is connected to the memory 602 and the input-output interface 603, for example, the processor 601 may be connected to the memory 602 and the input-output interface 603 through a bus.
  • the processor 601 is configured to support the apparatus for identifying vehicle damage based on deep learning to perform corresponding functions in the method for identifying vehicle damage based on deep learning described in FIGS. 1-7.
  • the processor 601 can be a central processing unit (central processdng, CPU), a network processor (NP), a hardware chip, or any combination thereof.
  • the above-mentioned hardware chip may be an application specific integrated circuit (appldcatdon specdfdc dntegrated cdrcudt, ASDC), a programmable logic device (programmable logdc devdce, PLD), or a combination thereof.
  • the PLD may be a complex programmable logic device (complex programmable logdc devdce, CPLD), a field programmable logic gate array (fdeld-programmable gate array (FPGA), a general array logic (generdc arrayloglog, GAL), or any combination thereof.
  • complex programmable logdc devdce CPLD
  • field programmable logic gate array FPGA
  • general array logic gene arrayloglog, GAL
  • the memory 602 memory is used to store program codes and the like.
  • the memory 602 may include volatile memory (volatdle memory, VM), such as random access memory (random access memory, RAM); the memory 602 may also include non-volatile memory (non-volatdle memory, NVM), such as read-only Memory (read-only memory, ROM), flash memory (flash memory), hard disk (hard drive ddsk, HDD) or solid state drive (soldd-state drdve, SSD); memory 602 may also include a combination of the above types of memory.
  • the memory 602 is used for a residual-dense network, a damage detection model based on an SSD algorithm, a sample picture, and the like.
  • the input/output interface 603 is used to input or output data.
  • the processor 601 may call the program code to perform the following operations:
  • the resolution of the second picture is higher than the resolution of the first picture
  • each operation can also correspond to the corresponding description of the method embodiment shown in FIGS. 1 to 11; the processor 601 can also cooperate with the input and output interface 603 to perform other operations in the above method embodiment .
  • Embodiments of the present application also provide a computer non-volatile readable storage medium, the computer non-volatile readable storage medium stores a computer program, the computer program includes program instructions, and the program instructions are executed by a computer
  • the computer may be a part of the aforementioned device for identifying vehicle damage based on deep learning.
  • the processor 601 described above the processor 601 described above.
  • the storage medium may be a magnetic disk, an optical disk, ROM, RAM, or the like.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • Molecular Biology (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Multimedia (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Image Analysis (AREA)

Abstract

本申请提供基于深度学习的识别车辆损伤的方法和相关装置,其中,所述方法包括:获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。该技术方案可以识别车辆的微小损伤,提高车辆损伤识别的精度。

Description

基于深度学习的识别车辆损伤的方法和相关装置
本申请要求于2019年1月4日提交中国专利局、申请号为2019100153781、申请名称为“基于深度学习的识别车辆损伤的方法和相关装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及计算机技术领域,尤其涉及基于深度学习的识别车辆损伤的方法和相关装置。
背景技术
机动车辆保险,是指对机动车辆由于自然灾害或意外事故所造成的人身伤亡或财产损失负赔偿责任的一种商业保险。在对机动车辆保险进行理赔的过程中,保险公司需要对机动车辆是否存在损伤和车辆损伤类型等进行判定和识别,以进行责任认定和理赔。
在车辆发生交通事故后,车辆的某些部位会留下破损、刮伤等损伤的痕迹。目前,保险公司一般是识别车主或业务人员拍摄的经过交通事故后的车辆的图片,对图片中车辆的损伤部位的损伤类型来对车辆存在的损伤和损伤类型进行识别判定。由于在不同的交通事故中,车辆所产生的损伤类型不同。对于损伤类型较轻的部位,其在图片中不明显,导致无法识别,这样容易影响责任认定和后续的理赔。
申请内容
本申请实施例提供基于深度学习的识别车辆损伤的方法和相关装置,解决无法识别车辆损失程度较轻的部位的问题。
第一方面,提供一种基于深度学习的识别车辆损伤的方法,包括:
获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
通过残差密集网络(residual dense network,RDN)对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
通过基于单点多盒检测器(single shot multibox detector,SSD)算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
第二方面,提供一种基于深度学习的识别车辆损伤的装置,包括:
图片获取模块,用于获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
图片处理模块,用于通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
图片检测模块,用于通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
标记模块,用于根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
第三方面,提供另一种基于深度学习的识别车辆损伤的装置,包括处理器、存储器以及输入输出接口,所述处理器、存储器和输入输出接口相互连接,其中,所述输入输出接口用于发送或接收数据,所述存储器用于存储基于图像识别的保单录入装置执行上述方法的应用程序代码,所述处理器被配置用于执行上述第一方面的方法。
第四方面,提供一种计算机非易失性可读存储介质,所述计算机非易失性可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使 所述处理器执行上述第一方面的方法。
本申请实施例中,通过提高图片的分辨率后再对其包含的车辆损伤部位进行识别和定位,可以识别和定位出损伤类型较小的部位,提高识别和定位的精度。
附图说明
图1是本申请实施例提供的一种基于深度学习的识别车辆损伤的方法的流程示意图;
图2是本申请实施例提供的一种包含车辆的损伤部位的图片的示意图;
图3是本申请实施例提供的一种残差密集网络的网络架构示意图;
图4是本申请实施例提供的残差密集块的示意图;
图5是本申请实施例提供的损伤检测模型中的卷积网络结构的示意图;
图6是本申请实施例提供的卷积特征图与卷积特征子图之间的关系示意图;
图7是本申请实施例提供的卷积特征图与原图片之间的映射关系的示意图;
图8是本申请实施例提供的根据第二区域对应的位置坐标确定目标车辆的损伤部位在第二图片中的位置坐标的流程示意图;
图9是本申请实施例提供的对图片进行标记后的示意图;
图10是本申请实施例提供的另一种基于深度学习的识别车辆损伤的方法的流程示意图;
图11是本申请实施例提供的对图片进行标记后的示意图;
图12是本申请实施例提供的一种基于深度学习的识别车辆损伤的装置的组成结构示意图;
图13是本申请实施例提供的另一种基于深度学习的识别车辆损伤的装置的组成结构示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例提供的一种基于深度学习的识别车辆损伤的方法及相关装置进行说明。
本申请实施例的方案适用于车辆定损的场景。在车辆定损的场景中,当车辆发生交通事故(如发生追尾等)后,保险人员可以通过图片采集设备(如手机、摄像机、单反相机,等等)对事故车辆(指发生交通事故的车辆)的各个损伤部位进行拍照采集,得到一张或多张包含有车辆损伤部位的图片,然后通过图片采集设备将包含有车辆的损伤部位的图片上传至对车辆进行定损的车辆定损装置(如服务器、云平台等)中。车辆定损装置接收到该包含有车辆的损伤部位的图片后,将图片输入至目标检测模型中。目标检测模型包括残差密集网络和损伤检测模型。残差密集网络对图片依次进行浅层特征提取、层级特征提取、全局融合、上采样等处理,对图片的细节进行特征提取和恢复,提高图片的分辨率。损伤检测模型对提高分辨率后的图片进行目标识别检测,识别并定位出图片中的车辆损伤部位,然后在提高分辨率后的图片中进行标记,得到标记后的图片。得到标记后的图片后,车辆定损装置将标记后的图片发送给图片采集设备,标记后的图片可以显示在图片采集设备上。可选地,车辆定损装置还可以在定位出车辆损伤部位后,对车辆损伤部位的损伤类型进行识别和检测,然后将在提高分辨率后的图片中进行标记,得到标记后的图片,然后将标记后的图片发送给图片采集设备。
在另一种可能的情况中,车辆定损装置可以与图片采集装置为同一个装置,在此种场景下,图片采集装置(即车辆定损装置)可以将采集到的图片直接输入至目标检测模型中,对车辆损伤部位进行识别和定位。
由上述场景描述可知,在发生交通事故后,车辆定损装置通过利用残差密集网络对包含有车辆损伤部位的图片的分辨率进行提高,使得图片的细节更加清晰,从而使得损伤检测模型可以检测出更加细微的损伤部位,提高了车辆定损的场景中车辆定损的精度。
参见图1,图1是本申请实施例提供的一种基于深度学习的识别车辆损伤的方法的流 程示意图,该方法可以实现在前述提到的车辆定损装置上。如图所示,该方法包括如下步骤:
S101,获取目标车辆对应的第一图片,目标车辆为待识别损伤的车辆,第一图片为包含目标车辆的损伤部位的图片。
具体地,可以从本地或网络中获取第一图片。例如,采集第一图片的装置和对车辆进行定损的装置不为同一个装置,则可以从网络中获取第一图片;又如,采集第一图片的装置和对车辆进行定损的装置为同一个装置,则可以从本地获取第一图片;又如,采集第一图片的装置和对车辆进行定损的装置不为同一个装置,定损用户(指负责对车辆进行定损的人员)将采集第一图片的装置采集到的第一图片通过SD卡拷贝的方式拷贝至对车辆进行定损的装置,则可以从本地获取第一图片。
这里,包含目标车辆的损伤部位的图片指图片内容中存在车辆的损伤部位的图片,其中,车辆的损伤部位是指因车辆发生剐蹭、碰撞等事件而造成其掉漆、凹陷、碎裂、掉落等情况的部位。示例性地,包含目标车辆的损伤部位的图片可以如图2所示,在图2所示的图片中,图片所包含的目标车辆的损伤部位位于图片的右下方位置,该损伤部位为车辆尾灯旁边的外壳。
S102,通过残差密集网络对第一图片进行处理,得到第二图片,第二图片的分辨率高于第一图片的分辨率。
本申请实施例中,残差密集网络为一种结合残差网络和密集连接网络的特性去利用原始的低分辨率的图像的所有分层特征以构建高分辨率的图像的网络结构。残差密集网络的网络架构示意图可以如图3所示,该网络架构包括四部分:1)浅层特征提取网络(SFENet),浅层特征提取网络由两个卷积层组成,用于提取图片的浅层特征;2)残差密集网络,残差密集网络由多个残差密集块(RDB)组成,用于提取图片的层级特征;3)密集特征融合网络(DFF),密集特征融合网络用于对通过残差密集网络提取得到的层级特征进行全局特征融合和全局残差学习,得到图片的全局特征;4)上采样网络(UPNet),上采样网络用于对图片的全局特征进行上采样和卷积操作,得到提高分辨率之后的图片。
以下具体介绍通过残差密集网络对第一图片进行处理,得到第二图片的过程。
一、基于残差密集网络的浅层特征提取网络进行卷积处理,得到第一图片对应的浅层特征图。
这里,浅层特征提取网络可以如图3所示,包括两个卷积层,基于残差密集网络的浅层特征提取网络进行卷积处理,得到第二图片对应的浅层特征图的方式为:通过第一卷积核对第一图片进行卷积处理,得到第一卷积特征图;通过第二卷积核对第二图片进行卷积处理,得到第二卷积特征图,将第二卷积特征图确定为第一图片对应的浅层特征图。其中,第一卷积核和第二卷积核分别为两个卷积层的卷积核,卷积核的物理意义为一个a*a(如1*1、3*3等)的矩阵。
具体实现中,可以将第一图片量化,得到第一图片对应的像素矩阵,该像素矩阵为一个m*n的矩阵,m*n等于第一图片的像素,该像素矩阵中的值为该第一图片中的亮度、色度等进行综合量化得到的量化值。例如,第一图片的像素为1920*2040的图片,则第一图片对应的像素矩阵为一个1920*2040的矩阵,矩阵中的值为该值所对应的像素的量化值。然后将第一图片的像素矩阵与第一卷积核对应的矩阵相乘,则得到第一卷积特征图对应的像素矩阵,再将第一卷积特征图对应的像素矩阵与第二卷积核对应的矩阵相乘,则得到第二卷积特征图对应的像素矩阵。
二、基于残差密集网络的残差密集网络对浅层特征卷积图进行卷积和线性修正处理,得到第一图片对应的多个残差密集特征图。
这里,残差密集网络可以如图3所示,包括多个残差密集块,残差密集块的结构示意图如图4所示,其中,一个残差密集块包括多个卷积层,每个卷积层用于对前几个卷积层输出的结果进行卷积计算,每个卷积层连接一个线性修正层,用于对与线性修正层连接的 卷积层输出的结果进行线性修正。
以下以残差密集网络包括D个残差密集块,每个残差密集块包括(C+1)个卷积层对基于残差网络的残差密集网络对浅层特征卷积图进行卷积和线性修正处理,得到第一图片对应的残差密集特征图的过程进行介绍。
通过第1残差密集块内的卷积层对第一图片对应的浅层特征图进行卷积和线性修正处理,得到第1残差密集块对应的第1残差密集特征图;通过第2残差密集块内的卷积层对第1残差密集特征图进行卷积和线性修正处理,得到第2残差密集块对应的第2残差密集特征图;……;通过第D残差密集块内的卷积层对第(D-1)残差密集特征图进行卷积和线性修正处理,得到第D残差密集块对应的第D残差密集特征图。将第1残差密集特征图、第2残差密集特征图、……、第D残差密集特征图确定为多个残差密集特征图。上述过程可以概括为:通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到第d残差密集块对应的第d残差密集特征图,d为1至D中的每一个正整数,第(d-1)残差密集特征图中的第0残差密集特征图为第一图片对应的浅层特征图;将第d残差密集特征图确定为第一图片对应的多个残差密集特征图。
其中,通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到第d残差密集块对应的第d残差密集特征图的具体过程为:通过第d残差密集块内的第1卷积核(第一层的卷积层的卷积核)对第(d-1)残差密集特征图进行卷积处理,得到第1卷积核对应的卷积特征图,通过与第1卷积核对应的线性修正层对第1卷积核对应的卷积特征图进行线性修正处理,得到第d1卷积特征图;通过第d残差密集块内的第2卷积核(第二层的卷积层的卷积核)对第d2卷积特征图进行卷积处理,得到第2卷积核对应的卷积特征图,第d2卷积特征图包括第(d-1)卷积特征图和第d1卷积特征图,通过第2卷积核对应的线性修正层对第2卷积核对应的卷积特征图进行线性修正处理,得到第d3卷积特征图;通过第d残差密集块内的第3卷积核(第三层的卷积层的卷积核)对第d4卷积特征图进行卷积处理,得到第3卷积核对应的卷积特征图,第d4卷积特征图包括第(d-1)残差密集特征图、第d1卷积特征图和第d3卷积特征图,通过与第3卷积核对应的线性修正层对第3卷积核对应的卷积特征图进行线性修正处理,得到第d5卷积特征图;……;通过第d残差密集块内的第C卷积核(第C层的卷积层的卷积核)对第d(2C-2)卷积特征图进行卷积处理,得到第C卷积核对应的卷积特征图,第d(2C-2)卷积特征图包括第(d-1)残差密集特征图、第d1卷积特征图、……、第d(2C-3)卷积特征图,通过第C卷积核对应的卷积特征图进行线性修正处理,得到第d(2C-1)卷积特征图;通过第d残差密集块内的第(C+1)卷积核(1*1的卷积核)对第d2C卷积特征图进行卷积处理,得到第d(2C+1)卷积特征图,第d2C卷积特征图包括第(d-1)残差密集特征图、第d1卷积特征图、……、第d(2C-3)卷积特征图、第d2C卷积特征图;将第d(2C+1)卷积特征图与第(d-1)残差密集特征图进行融合处理,得到第d残差密集块对应的第d残差密集特征图。上述过程用公式可以表示为:F d=H RDB,d(F d-1)=H RDB,d(H RDB,d-1(…(H RDB,1(F 0))…)),其中,F d为第d个残差密集块的输出,F0为第二卷积特征图对应的像素矩阵,H RDB,d为第d个RDB的运算。
三、基于残差密集网络的密集特征融合网络对多个局部特征图进行密集特征融合,得到第一图片对应的全局特征图,多个局部特征图包括浅层特征图和多个残差密集特征图。
这里,密集特征融合网络可以如图3所示,包括全局特征融合层和全局残差学习层。基于残差密集网络的密集特征融合网络对多个局部特征图进行密集特征融合,得到第一图片对应的全局特征图具体为:对多个局部特征图进行融合处理,得到第一全局卷积特征图;通过密集融合网络中的第1卷积核(1*1的卷积核)对第一全局卷积特征图进行卷积处理,得到第二全局卷积特征图;对第一图片对应的浅层卷积特征图和第二全局卷积特征图进行残差学习,得到第一图片对应的全局特征图。
四、基于残差密集网络的上采样网络对全局特征图进行上采样和卷积处理,得到第二 图片。
这里,上采样网络可以如图3所示,包括上采样层和卷积层,具体实现中,可以通过邻插值、双线性插值、均值插值、中值插值等插值方式结合亚像素卷积神经网络对第一图片对应的全局特征图进行上采样,得到上采样特征图,然后利用最后一层卷积层对应的卷积核对上采样特征图进行卷积处理,得到第二图片对应的像素矩阵,根据第二图片对应的像素矩阵得到第二图片。
在上述四个步骤中,通过步骤一和步骤二提取得到图片的局部特征,再通过步骤三对图片的局部特征进行融合,得到全局特征,再通过残差学习,学习局部的特征,可以对图片的细节进行恢复,最后通过步骤四对图片进行恢复,得到尺寸为原图尺寸的图,由于通过前面步骤的特征提取和学习,恢复了图片的细节,因而恢复得到的尺寸为原尺寸的图相较于原图分辨率提高,即,第二图片的分辨率高于第一图片的分辨率。
S103,通过基于单点多盒检测算法的损伤检测模型对第二图片进行检测,得到第一信息,第一信息包括目标车辆的损伤部位在第二图片中的位置坐标。
本申请实施例中,SSD是一种基于深度的one-stage框架下的目标学习算法,其通过在特征图上通过卷积核来预测位置框对应的类别和偏移量(位置框对应图中的哪一个位置)。基于SSD算法的损伤检测模型的示意图可以如图5所示,该损伤检测模型包括若干个卷积层,不同的卷积层对应不同尺寸的卷积核,通过不同尺寸的卷积核对图片进行卷积处理,可以得到不同尺寸的卷积特征图,不同尺寸的卷积核对应不同的多个先验框,通过利用卷积核对应的先验框对与卷积核对应的卷积图进行预测处理,可以得到多个预测框,根据该预测框对应的类别和置信度可以确定该预测框中的对象的位置和该对象的类别。
下面具体介绍通过基于SSD算法的损伤检测模型对第二图片进行检测,得到第一信息的过程。
一、基于损伤检测模型中的卷积层对第二图片进行卷积处理,得到多个尺寸不同的卷积特征图,每个卷积特征图包括多个卷积特征子图。
这里,损伤检测模型中的卷积网络结构可以如图5所示,将卷积层的作用按功能进行划分,可以将卷积层划分为一般卷积层和卷积特征层,其中,一般卷积层仅用于在损伤检测模型的卷积网络中对输入的图片进行卷积处理,如图5中除了标号为f1、f2、f3、f4、f5以及f6的卷积层之外的卷积层,卷积特征层为用于生成进行识别检测的卷积特征图的卷积层,如图5中标号为f1、f2、f3、f4、f5以及f6的卷积层。
本申请实施例中,多个尺寸不同的卷积特征图具体是指:通过损伤检测模型中的卷积特征层分别输出的结果所对应的卷积图,对该卷积图进行量化得到结果即为该输出的结果。其中,每个卷积特征层对应多个尺寸相同的卷积特征图,卷积特征层对应的尺寸越小,则卷积特征层对应的卷积特征图的数量越多。
例如,损伤检测模型中的卷积层如图5所示,则将图5中标号为f1、f2、f3、f4、f5以及f6的卷积层输出的结果所对应的卷积图作为多个尺寸不同的卷积特征图,那么,标号为f1的卷积层对应的卷积特征图的尺寸为38*38,标号为f1的卷积层对应多个尺寸为38*38的卷积特征图,标号为f2的卷积层对应的卷积特征图的尺寸为19*19,标号为f3的卷积层对应的卷积特征图的尺寸为10*10,标号为f4的卷积层对应的卷积特征图的尺寸为5*5,标号为f5的卷积层对应的卷积特征图的尺寸为3*3,标号为f6的卷积层对应的卷积特征图的尺寸为1*1;其中,尺寸为38*38的卷积特征图的数量少于尺寸为19*19的卷积特征图的数量,尺寸为19*19的卷积特征图的数量少于尺寸为10*10的卷积特征图的数量,尺寸为10*10的卷积特征图的数量少于尺寸为5*5的卷积特征图的数量……
具体实现中,可以将第二图片的尺寸调整为损伤检测模型对应的输入图片的尺寸(该尺寸可以是300*300,也可以是512*512),得到第三图片,第三图片的尺寸为损伤检测模型对应的输入图片的尺寸。然后将第三图片输入损伤检测模型的卷积网络中,将第三图片作为卷积网络中的第一个卷积层的输入,依次利用该卷积网络中的卷积层对应的卷积核对 上一个卷积层输出的结果进行卷积处理,然后将该卷积网络中的卷积特征层输出的结果所对应的卷积图确定为多个尺寸不同的卷积特征图。其中,利用卷积层对应的卷积核对上一个卷积层输出的结果进行卷积处理具体是指利用该卷积核对应的矩阵与上一个卷积层输出的结果相乘,利用卷积层对应的卷积核对上一个卷积层输出的结果进行卷积处理得到的结果为尺寸为该卷积层对应的尺寸的矩阵,该矩阵对应的图像即为该卷积层对应的卷积图。可选地,如果该卷积网络中的卷积层之后还连接有线性修正层,则在卷积层输出结果之后,还可以利用该线性修正层对卷积层输出的结果进行修正处理,然后将修正处理得到结果作为下一个卷积层的输入,然后将卷积特征层后连接的线性修正层输出的结果作为多个尺寸不同的卷积特征图。
下面通过举例来进行说明,例如,损伤检测模型的卷积网络包括7个卷积层,其中,卷积层1为卷积网络的第一个卷积层,卷积层7为卷积网络的最后一个卷积层。在7个卷积层中,卷积层3、卷积层4、卷积层6和卷积层7为卷积特征层。则在将第三图片输入卷积网络中后,利用卷积层1对应的卷积核对第三图片进行卷积处理,得到第一卷积图;利用卷积层2对应的卷积核对第一卷积图进行处理,得到第二卷积图;……;利用卷积层7对第六卷积图进行处理,得到第七卷积特征图;然后将第三卷积图、第四卷积图、第六卷积图以及第七卷积图确定为卷积特征图。需说明的是,这里的举例仅用于说明利用卷积网络对第三图片进行卷积处理的过程,不对本申请实施例进行限制,在可选实施例中,卷积网络还可以包括更多的卷积层和更多的卷积特征层。
这里,卷积特征子图是指每个卷积特征图包含的特征单元,例如,卷积特征图的尺寸为4*4,则卷积特征图可以如图6所示,卷积特征图一共包含16个特征单元,每个特征单元为卷积特征图中的一个单元格,编号分别为1~16,即卷积特征图包含16个特征子图。
二、分别确定每个卷积特征图对应的目标卷积特征信息,目标卷积特征信息包括多个卷积特征子图中各个卷积特征子图对应的卷积特征信息。
这里,各个卷积特征子图对应的卷积特征信息是指:以卷积特征图对应的先验框作为预测框在该卷积特征图中以卷积特征子图为中心对应的内容。其中,不同的卷积特征图对应的先验框的尺寸和先验框的数量不同,一个卷积特征图可以对应多个尺寸不同的先验框。例如,卷积特征图如图6所示,则对于该卷积特征图中的卷积特征子图11,该卷积特征子图11对应的卷积特征信息为图6中的三个尺寸不同的虚线框所对应的该卷积特征图的信息。
具体实现中,可以分别以各个卷积特征图对应的先验框作为预测框,分别确定各个卷积特征图中的各个卷积特征子图对应的预测框内的信息,将该预测框内的信息确定为该预测框对应的卷积特征子图的卷积特征信息,从而确定每个卷积特征图对应的目标卷积特征信息。
以一个卷积特征图为例,假设卷积特征图如图6所示,则确定卷积特征图对应的目标卷积特征信息可以为:以尺寸为4*4的卷积特征对应的先验框作为预测框,将预测框以特征单元1为中心,确定该预测框对应的信息,将该预测框对应的信息确定为特征单元1对应的卷积特征信息;将预测框以特征单元2为中心,确定该预测框对应的信息,将该框对应的信息确定为特征单元1对应的卷积特征信息;……;将预测框以特征单元16为中心,确定该预测框对应的信息,将该预测框对应的信息确定为特征单元16对应的卷积特征信息;最后将特征单元1~特征单元16对应的卷积特征信息确定为卷积特征图对应的目标卷积特征信息。
三、分别确定目标卷积特征信息中的各个卷积特征信息对应的位置坐标,将在第二图片中与各个卷积特征信息对应的位置坐标对应的区域确定为各个卷积特征信息对应的第一区域。
这里,卷积特征信息对应的位置坐标是指将卷积特征信息对应的预测框映射回第二图片时所对应的位置坐标,一个卷积特征信息对应四个位置坐标,这四个位置坐标分别对应 预测框的四个顶点,将预测框的四个顶点映射回原图所得到的四个点的坐标即为卷积特征信息对应的位置坐标。由于每一个卷积特征图均是由第二图片经过尺寸调整以及卷积处理而来,卷积特征图中的每个点与第二图片中的点或区域存在对应关系,根据该对应关系可确定预测框在第二图片中对应四个点的位置坐标,进而将该预测框在第二图片中对应的第四个点的位置坐标确定为该预测框对应的卷积特征信息对应的位置坐标,将该位置坐标对应的点所形成的区域确定为卷积特征信息对应的第一区域。
举例来进行说明,例如,卷积特征信息对应的预测框如图7所示,预测框的四个顶点分别为a1、a2、a3以及a4,该四个顶点映射回第二图片时分别对应点b1、b2、b3以及b4,b1在第二图片中的位置坐标为(b11,b12),b2在第二图片中的位置坐标为(b21,b22),b3在第二图片中的位置坐标为(b31,b34),b4在第二图片中的位置坐标为(b41,b44),则将b1的位置坐标(b11,b12)、b2的位置坐标(b21,b22)、b3的位置坐标(b31,b32)以及b4的位置坐标(b41,b42)确定为卷积特征信息对应的位置坐标,将点b1、b2、b3以及b4所在第二图片中形成的区域确定为卷积特征信息对应的第一区域。
具体实现中,可以根据该卷积特征信息对应的卷积特征图与第二图片之间的映射关系确定各个卷积特征信息对应的位置坐标。
四、确定各个卷积特征信息对应的第一区域的置信度和第一区域对应的属性类别,并将置信度大于置信度阈值并且属性类别为损伤的第一区域确定为第二区域。
这里,确定各个卷积特征信息对应的第一区域的置信度和第一区域对应的属性类别具体为:分别确定各个卷积特征信息与损伤检测模型中的两种属性类别之间的匹配概率,损伤检测模型中的两种属性类别分别为背景和损伤;在各个卷积特征信息与损伤检测模型中的两种属性类别之间的匹配概率中确定最大匹配概率,并将最大匹配概率确定为各个卷积特征信息对应的第一区域的置信度,并将最大匹配概率对应的属性类别确定为第一区域对应的属性类别。
以一个卷积特征信息(即一个预测框内的信息)为例,可以分别计算该预测框内的信息与背景这一类别的图像的特征信息的匹配度,以及该预测框的信息与损伤这一类别的图像特征信息的匹配度,得到两个类别对应的匹配度,假设预测框内的信息与背景这一类别的图像的特征信息的匹配度为0.3,预测框的信息与损伤这一类别的图像特征信息的匹配度为0.5,那么可确定该卷积特征信息与损伤检测模型中的两种属性类别之间的匹配概率分别为0.3和0.5。然后在卷积特征信息与损伤检测模型中的两种属性类别之间的匹配概率确定最大匹配概率,由于0.5大于0.3,则确定最大匹配概率为0.5。最后将最大匹配概率确定为各个卷积特征信息对应的第一区域的置信度,并将最大匹配概率对应的属性类别确定为第一区域对应的属性类别,即将0.5确定为卷积特征信息对应的第一区域的置信度,0.5对应的类别为损伤,则将损伤确定为第一区域对应的属性类别。
具体实现中,可以基于损伤检测模型中的分类器对各个卷积特征信息与损伤检测模型中的两种属性类别之间的匹配概率进行计算。其中,可以通过损伤检测模型中的分类器计算各个卷积特征信息与分类器中的背景这一类别的图像的特征信息以及与损伤这一类别的图像的特征信息之间的匹配度,根据该匹配度确定各个卷积特征信息对应的图像为背景和各个卷积特征信息对应的图像为损伤的概率,将该概率确定为各个卷积征信息与损伤检测模型中的两种属性类别之间的匹配概率。
这里,置信度阈值为一个预设的接近于1的值,其中,置信度阈值越大,说明该第二区域中的内容为损伤的可能性越大,具体实现中,可以将置信度阈值设置为95%、98%等值。
五、根据第二区域对应的位置坐标确定目标车辆的损伤部位在第二图片中的位置坐标。
这里,根据第二区域对应的位置坐标确定目标车辆的损伤部位在第二图片中的位置坐标有以下两种情况:
1、第二区域的数量为一个。在第二区域的数量为一个的情况下,将第二区域对应的位 置坐标确定为损伤部位在第二图片中的位置坐标。
2、第二区域的数量为多个。在第二区域的数量为多个的情况下,根据第二区域对应的位置坐标确定目标车辆的损伤部位在第二图片中的位置坐标的流程如图8所示,包括如下步骤:
S201,在第二区域中确定置信度最大的第二区域,将置信度最大的第二区域确定为第三区域。
例如,存在5个第二区域,5个第二区域的置信度分别为0.99、0.98、0.995、0.997以及0.999,则将置信度为0.999的第二区域确定为第三区域。
S202,计算第四区域与第三区域的区域交叉度,区域交叉度用于指示第四区域与第三区域在第二图片中的重合程度,第四区域为在第二区域中排除第三区域之后的第二区域。
这里,第四区域是指多个第二区域中去除第三区域之后所剩下的区域。例如,有5个第二区域,分别为第二区域1,第二区域2,第二区域3,第二区域4以及第二区域5,其中,第二区域3为第三区域,则将第二区域1、第二区域2、第二区域4以及第二区域5确定为第四区域。
本申请实施例中,区域交叉度又可以称之为交并比,计算第四区域与第三区域的区域交叉度具体是指计算第四区域与第三区域的重合程度。第四区域和第三区域的区域交叉度等于第四区域与第三区域的交集除以第四区域与第三区域的并集,用公式表达为:IoU=[area(C)∩area(D)]/[area(C)∪area(D)],area(C)为第三区域,area(D)为第四区域。
具体实现中,可以根据第四区域的位置坐标和第三区域的位置坐标计算第四区域与第三区域的交并比。
S203,在第四区域中查找第五区域,第五区域与第三区域的IoU大于IoU阈值。
这里,IoU阈值为一个评估两个区域之间的重合程度的临界点,IoU阈值具体可以为90%、95%,等等。当两个区域的IoU大于IoU阈值时,说明两个区域的重合程度较高。
在查找到第五区域的情况下,执行步骤S204;在未查找到第五区域的情况下,执行步骤S205。
S204,将第三区域确定为目标区域,并在第二区域中排除第三区域和第五区域。
S205,将第三区域确定为目标区域,并在第二区域中排除第三区域。
S206,判断第二区域的数量是否为多个。
在第二区域的数量为多个的情况下,执行步骤S201;在第二区域的数量为一个的情况下,将第二区域确定为目标区域,执行步骤S207。
S207,将目标区域对应的位置坐标确定为目标车辆的损伤部位在第二图片中的位置坐标。
通过上述步骤S201~S207,可以将确定的第二区域中重合度较高的区域去除掉,从而可以保留下最可能为损伤部位所在的区域的第二区域。
S104,根据目标车辆的损伤部位在第二图片中的位置坐标在第二图片中标记出目标车辆的损伤部位所在的区域。
具体实现中,可以根据目标车辆的损伤部位在第二图片中的位置坐标在第二图片中将该位置坐标对应的点所形成的区域标记出来,即在第二图片中标记出第二区域。可选地,还可以在第二图片中标记出目标车辆的损伤部位所在的区域为损伤部位的概率,即在第二图片中标记出第二区域的置信度。
例如,第二图片为通过残差密集网络对图3所示的图片进行处理得到的图片,则在对第二图片标记后得到的图片可以如图10所示。
本申请实施例中,在获取到包含有车辆的损伤部位的图片后,首先通过残差密集网络对图片进行处理,利用残差密集网络对图片的局部细节和整体细节进行了恢复,提高了图片的分辨率,再通过基于SSD的损伤检测模型对提高分辨率后的图片进行识别,由于提高 了图片的分辨率,因而可以提高识别的准确度,进而可以识别和定位出损伤类型较小的部位,提高了识别和定位的精度。
可选地,在利用上述损伤检测模型对图片进行检测,以确定损伤部位在图片中的位置坐标和区域之前,还可以将大量的图片作为训练样本对初始的损伤检测模型进行训练,以得到该损伤检测模型。其中,在训练基于SSD算法的损伤检测模型时,可以获取多个包含损伤部位的样本图片,然后利用样本图片对应的属性类别(指损伤和背景两种类别)和位置信息对各个样本数据进行数据标注,得到样本图片对应的标注图像,接着利用标注图像对单点多盒检测器算法的初始模型进行训练,待模型收敛并达到一定精度(指模型中的损失函数值小于损失阈值且精度大于精度阈值)时保存模型,该保存下来的模型就是基于SSD算法的目标检测检测模型。
进一步地,在确定了损伤部位在图片中所在的位置坐标之后,还可以对损伤部位的损伤类型进行识别。参见图10,图10是本申请实施例提供的另一种基于深度学习的识别车辆损伤的方法的流程示意图,该方法可以实现在前述提到的车辆定损装置上。如图所示,该方法包括如下步骤:
S301,获取目标车辆对应的第一图片,目标车辆为待识别损伤的车辆,第一图片为包含目标车辆的损伤部位的图片。
S302,通过残差密集网络对第一图片进行处理,得到第二图片,第二图片的分辨率高于第一图片的分辨率。
S303,通过基于单点多盒检测算法的损伤检测模型对第二图片进行检测,得到第一信息,第一信息包括目标车辆的损伤部位在第二图片中的位置坐标。
本申请实施例中,步骤S301~S303的具体实现方式可参考步骤S101~S103的描述,此处不再赘述。
S304,根据目标车辆的损伤部位在第二图片中的位置坐标从第二图片中截取包含目标车辆的损伤部位的第三图片,第三图片的尺寸小于第二图片。
具体实现中,可以根据目标车辆的损伤部位在第二图片中的位置坐标将该位置坐标对应的点所形成的区域从第二图片中截取出来,该位置坐标对应的点所形成的区域即为第三图片。
S305,通过预先训练得到的损伤类型识别模型对第三图片进行识别,得到目标车辆的损伤部位的损伤类型。
本申请实施例中,损伤类型识别模型是指利用分类算法对样本数据进行训练得到的,可以根据输入的包含损伤部位的图片进行相关数据处理然后输出该图片中的损伤部位的损伤类型的分类模型。其中,损伤类型可以是指该损伤部位的损伤程度,例如损伤类型可以包括轻微损伤、中度损伤,严重损伤,等等。损伤类型也可以是指损伤部位的名称和损伤情况,例如损伤类型可以包括车辆外壳凹陷、车辆尾灯碎裂、车辆外壳掉漆,等等。
该损伤类型识别模型可以为基于K近邻算法的损伤类型识别模型、基于朴素贝叶斯算法的损伤类型识别模型、基于决策树算法的损伤类型识别模型、基于逻辑回归算法的损伤类型识别模型、基于支持向量机算法的损伤类型识别模型,等等,不限于这里的描述。
具体实现中,可以对第三图片进行特征提取,得到第三图片对应的特征数据,其中,可以通过卷积神经网络中的卷积层对第三图片进行深度的特征提取,得到第三图片对应的特征数据。然后将第三图片对应的特征数据作为该损伤类型识别模型的输入送入该损伤类型识别模型中,该损伤类型识别模型经过该分类算法对应的处理之后,输出该第三图片对应的损伤类型。损伤类型识别模型采用的分类算法不同,则损伤类型识别模型进行的处理所对应的逻辑不同。
本申请实施例以该损伤类型识别模型为基于K邻近算法的损伤类型识别模型为例具体介绍该损伤类型识别模型根据第三图片的特征数据确定目标车辆的损伤部位的损伤类型的具体处理过程:
首先,分别确定第三图片对应的各个特征数据与该损伤类型识别模型中的多个包含有损伤部位的图片的对应的各个特征数据之间的相似距离;然后,分别根据多个包含有损伤部位的图片的各个特征数据对应的相似距离分别确定该多个包含有损伤部位的图片的各个包含有损伤部位的图片与该第三图片的相似值;根据该相似值从该多个包含有损伤部位的图片中选择K个包含有损伤部位的图片,这K个包含有损伤部位的图片与第三图片的相似值大于该多个包含有损伤部位的图片中的其他图片;将K个包含有损伤部位的图片对应的损伤类型出现频率最高的损伤类型确定为该第三图片对应的损伤类型。
其中,相似距离可以为欧式距离、曼哈顿距离等用于计算两个特征数据之间的相似度的距离。根据特征数据的相似距离确定两个图片的相似值为:根据两个图片对应的各个特征数据之间的相似距离以及预设的特征数据加权公式确定两个图片的相似值,该特征数据加权公式为特征数据1的相似距离*加权系数1+特征数据2的相似距离*加权系数2+...+特征数据M的相似距离*加权系数M,M为第三图片的特征数据的数据维度,也即特征数据的个数。
举例来进行说明,假设第三图片的特征数据有10个,分别为特征数据1~10,特征数据加权公式中各个特征数据的加权系数均为1,损伤类型识别模型对应的多个包含有损伤部位的图片为300个,K为100,则确定第三图片对应的损伤类型的过程为:
1)计算第三图片与包含有损伤部位的图片1的相似值,计算第三图片的特征数据1与包含有损伤部位的图片1的特征数据1的相似距离1,计算第三图片的特征数据2与包含有损伤部位的图片1的特征数据2的相似距离2,…,计算第三图片的特征数据10与包含有损伤部位的图片1的特征数据10的相似距离10,根据特征数据加权公式计算第三图片与包含有损伤部位的图片1对应的相似值为:相似距离1+相似距离2+…+相似距离10。2)按照步骤1)的方式分别计算第三图片与包含有损伤部位的图片2,第包含有损伤部位的图片3,……,包含有损伤部位的图片300的相似值。3)根据1)和2)的计算结果确定300个包含有损伤部位的图片中相似值较大的100个包含有损伤部位的图片。4)统计100个包含有损伤部位的图片对应的损伤类型,假设100个包含有损伤部位的图片对应的损伤类型分别为损伤类型1(15个),损伤类型2(20个),损伤类型3(30个),损伤类型4(45个)。5)将损伤类型中出现频率最高的损伤类型,即损伤类型4确定为第三图片对应的损伤类型。
应理解的是,上述过程仅用于对损伤类型识别模型根据第三图片的特征数据进行相关的处理进行解释,不对本申请实施例进行限制,在可选的实施方式中,损伤类型识别模型也可以按照其他的分类算法的处理逻辑根据特征数据确定第三图片对应的损伤类型。
S306,根据目标车辆的损伤部位在第二图片中的位置坐标在第二图片中标记出目标车辆的损伤部位所在的区域,并在第二图片中标记出目标车辆的损伤部位的损伤类型。
例如,第二图片为通过残差密集网络对图3所示的图片进行处理得到的图片,通过步骤S305识别得到的第二图片的损伤类型为轻微损伤,则在对第二图片标记后得到的图片可以如图11所示。
本申请实施例中,在识别定位到图片中的车辆的损伤部位后,通过进一步对该损伤部位所在的区域对应的图片进行识别,识别除了该损伤部位的损伤类型,自动完成了对该损伤部位的损伤类型的认定,可以帮助定损人员确定理赔费用。
参见图12,图12是本申请实施例提供的一种基于深度学习的识别车辆损伤的装置的组成结构示意图,该装置可以为上述前述提到的车辆定损装置或该车辆定损装置的一部分,该装置50包括:
图片获取模块501,用于获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
图片处理模块502,用于通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
图片检测模块503,用于通过基于单点多盒检测器算法的损伤检测模型对所述第二图 片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
标记模块504,用于根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
在一种可能的设计中,所述图片处理模块502具体用于:
基于所述残差密集网络的浅层特征提取网络对所述第一图片进行卷积处理,得到所述第一图片对应的浅层特征图;
基于所述残差密集网络的残差密集网络对所述浅层特征卷积图进行卷积和线性修正处理,得到所述第一图片对应的多个残差密集特征图,所述残差密集网络包括多个残差密集块,所述多个残差密集特征图分别为所述多个残差密集块中的各个残差密集块对应的残差密集特征图;
基于所述残差密集网络的密集特征融合网络对多个局部特征图进行密集特征融合,得到所述第一图片对应的全局特征图,所述多个局部特征图包括所述浅层特征图和所述多个残差密集特征图;
基于所述残差密集网络的上采样网络对所述全局特征图进行上采样和卷积处理,得到第二图片。
在一种可能的设计中,所述图片处理模块502具体用于:
通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到所述第d残差密集块对应的第d残差密集特征图,d为1至D中的每一个正整数,D为所述多个残差密集块的个数,所述第(d-1)残差密集特征图中的第0残差密集特征图为所述浅层特征卷积图;
将所述第d残差密集特征图确定为所述第一图片对应的多个残差密集特征图。
在一种可能的设计中,所述图片检测模块503具体用于:
基于所述损伤检测模型中的卷积层对所述第二图片进行卷积处理,得到多个尺寸不同的卷积特征图,每个卷积特征图包括多个卷积特征子图;
分别确定所述每个卷积特征图对应的目标卷积特征信息,所述目标卷积特征信息包括所述多个卷积特征子图中各个卷积特征子图对应的卷积特征信息;
分别确定所述目标卷积特征信息中的各个卷积特征信息对应的位置坐标,将在所述第二图片中与所述位置坐标对应的区域确定为所述各个卷积特征信息对应的第一区域;
确定各个卷积特征信息对应的第一区域的置信度和所述第一区域对应的属性类别,并将置信度大于置信度阈值并且属性类别为损伤的第一区域确定为第二区域;
根据所述第二区域对应的位置坐标确定所述损伤部位在所述第二图片中的位置坐标。
在一种可能的设计中,所述图片检测模块503具体用于:
分别确定所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率,所述两种属性类别分别为背景和损伤;
在所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率中确定最大匹配概率,并将所述最大匹配概率确定为所述各个卷积特征信息对应的第一区域的置信度,以及,将所述最大匹配概率对应的属性类别确定为所述第一区域对应的属性类别。
在一种可能的设计中,所述图片检测模块503具体用于:
在所述第二区域的数量为多个的情况下,在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域;
计算第四区域与第三区域的区域交叉度IoU,所述第四区域为所述第二区域中排除所述第三区域之后的第二区域,所述IoU用于指示所述第四区域与所述第三区域在所述第二图片中的重合程度;
在所述第四区域中查找第五区域,所述第五区域与所述第三区域的IoU大于IoU阈值;
在查找到所述第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区 域中排除所述第三区域和所述第五区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;
在未查找到第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区域中排除所述第三区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;直到在所述第二区域中确定所有的目标区域;
在所述第二区域的数量为一个的情况下,将所述第二区域确定为目标区域;
将所述目标区域对应的位置坐标确定为所述损伤部位在所述第二图片中的位置坐标。
在一种可能的设计中,所述装置还包括:
图片截取模块505,根据所述损伤部位在第二图片中的位置坐标从所述第二图片中截取包含所述损伤部位的第三图片,所述第三图片的尺寸小于所述第二图片。
损伤类型识别模块506,用于通过预先训练得到的损伤类型识别模型对所述第三图片进行识别,得到所述损伤部位的损伤类型。
所述标记模块504,还用于在所述第二图片中标记出所述损伤部位的损伤类型。
需要说明的是,图12对应的实施例中未提及的内容可参见方法实施例的描述,这里不再赘述。
本申请实施例中,基于深度学习的识别车辆损伤的装置在获取到包含有车辆的损伤部位的图片后,首先通过残差密集网络对图片进行处理,利用残差密集网络对图片的局部细节和整体细节进行了恢复,提高了图片的分辨率,再通过基于SSD的损伤检测模型对提高分辨率后的图片进行识别,由于提高了图片的分辨率,因而可以提高识别的准确度,进而可以识别和定位出损伤类型较小的部位,提高了识别和定位的精度。
参见图13,图13是本申请实施例提供的另一种基于深度学习的识别车辆损伤的装置的组成结构示意图,该装置可以为前述提到的车辆定损装置或该车辆定损装置的一部分,该装置60包括处理器601、存储器602以及输入输出接口603。处理器601连接到存储器602和输入输出接口603,例如处理器601可以通过总线连接到存储器602和输入输出接口603。
处理器601被配置为支持所述基于深度学习的识别车辆损伤的装置执行图1-图7所述的基于深度学习的识别车辆损伤的方法中相应的功能。该处理器601可以是中央处理器(central processdng undt,CPU),网络处理器(network processor,NP),硬件芯片或者其任意组合。上述硬件芯片可以是专用集成电路(appldcatdon specdfdc dntegrated cdrcudt,ASDC),可编程逻辑器件(programmable logdc devdce,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logdc devdce,CPLD),现场可编程逻辑门阵列(fdeld-programmable gate array,FPGA),通用阵列逻辑(generdc array logdc,GAL)或其任意组合。
存储器602存储器用于存储程序代码等。存储器602可以包括易失性存储器(volatdle memory,VM),例如随机存取存储器(random access memory,RAM);存储器602也可以包括非易失性存储器(non-volatdle memory,NVM),例如只读存储器(read-only memory,ROM),快闪存储器(flash memory),硬盘(hard ddsk drdve,HDD)或固态硬盘(soldd-state drdve,SSD);存储器602还可以包括上述种类的存储器的组合。本申请实施例中,存储器602用于残差密集网络、基于SSD算法的损伤检测模型、样本图片等。
所述输入输出接口603用于输入或输出数据。
处理器601可以调用所述程序代码以执行以下操作:
获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率 高于所述第一图片的分辨率;
通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
需要说明的是,各个操作的实现还可以对应参照图1-图11所示的方法实施例的相应描述;所述处理器601还可以与输入输出接口603配合执行上述方法实施例中的其他操作。
本申请实施例还提供一种计算机非易失性可读存储介质,所述计算机非易失性可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被计算机执行时使所述计算机执行如前述实施例所述的方法,所述计算机可以为上述提到的基于深度学习的识别车辆损伤的装置的一部分。例如为上述的处理器601。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、ROM或RAM等。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (20)

  1. 一种基于深度学习的识别车辆损伤的方法,其特征在于,包括:
    获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
    通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
    通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
    根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
  2. 根据权利要求1所述的方法,其特征在于,所述通过残差密集网络对所述第一图片进行处理,得到第二图片,包括:
    基于所述残差密集网络的浅层特征提取网络对所述第一图片进行卷积处理,得到所述第一图片对应的浅层特征图;
    基于所述残差密集网络的残差密集网络对所述浅层特征卷积图进行卷积和线性修正处理,得到所述第一图片对应的多个残差密集特征图,所述残差密集网络包括多个残差密集块,所述多个残差密集特征图分别为所述多个残差密集块中的各个残差密集块对应的残差密集特征图;
    基于所述残差密集网络的密集特征融合网络对多个局部特征图进行密集特征融合,得到所述第一图片对应的全局特征图,所述多个局部特征图包括所述浅层特征图和所述多个残差密集特征图;
    基于所述残差密集网络的上采样网络对所述全局特征图进行上采样和卷积处理,得到第二图片。
  3. 根据权利要求2所述的方法,其特征在于,所述基于所述残差密集网络的残差密集网络对所述浅层特征卷积图进行卷积和线性修正处理,得到所述第一图片对应的多个残差密集特征图,包括:
    通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到所述第d残差密集块对应的第d残差密集特征图,d为1至D中的每一个正整数,D为所述多个残差密集块的个数,所述第(d-1)残差密集特征图中的第0残差密集特征图为所述浅层特征卷积图;
    将所述第d残差密集特征图确定为所述第一图片对应的多个残差密集特征图。
  4. 根据权利要求1-3任意一项所述的方法,其特征在于,所述通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,包括:
    基于所述损伤检测模型中的卷积层对所述第二图片进行卷积处理,得到多个尺寸不同的卷积特征图,每个卷积特征图包括多个卷积特征子图;
    分别确定所述每个卷积特征图对应的目标卷积特征信息,所述目标卷积特征信息包括所述多个卷积特征子图中各个卷积特征子图对应的卷积特征信息;
    分别确定所述目标卷积特征信息中的各个卷积特征信息对应的位置坐标,将在所述第二图片中与所述位置坐标对应的区域确定为所述各个卷积特征信息对应的第一区域;
    确定各个卷积特征信息对应的第一区域的置信度和所述第一区域对应的属性类别,并将置信度大于置信度阈值并且属性类别为损伤的第一区域确定为第二区域;
    根据所述第二区域对应的位置坐标确定所述损伤部位在所述第二图片中的位置坐标。
  5. 根据权利要求4所述的方法,其特征在于,所述确定各个卷积特征信息对应的第一区域的置信度和所述第一区域对应的属性类别,包括:
    分别确定所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率,所述两种属性类别分别为背景和损伤;
    在所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率中确定最大匹配概率,并将所述最大匹配概率确定为所述各个卷积特征信息对应的第一区域的置信度,以及,将所述最大匹配概率对应的属性类别确定为所述第一区域对应的属性类别。
  6. 根据权利要求4所述的方法,其特征在于,所述根据所述第二区域对应的位置坐标确定所述损伤部位在所述第二图片中的位置坐标,包括:
    在所述第二区域的数量为多个的情况下,在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域;
    计算第四区域与第三区域的区域交叉度IoU,所述第四区域为所述第二区域中排除所述第三区域之后的第二区域,所述IoU用于指示所述第四区域与所述第三区域在所述第二图片中的重合程度;
    在所述第四区域中查找第五区域,所述第五区域与所述第三区域的IoU大于IoU阈值;
    在查找到所述第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区域中排除所述第三区域和所述第五区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;
    在未查找到第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区域中排除所述第三区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;
    在所述第二区域的数量为一个的情况下,将所述第二区域确定为目标区域;
    将所述目标区域对应的位置坐标确定为所述损伤部位在所述第二图片中的位置坐标。
  7. 根据权利要求1-6任意一项所述的方法,其特征在于,所述通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息之后,还包括:
    根据所述损伤部位在所述第二图片中的位置坐标从所述第二图片中截取包含所述损伤部位的第三图片,所述第三图片的尺寸小于第二图片;
    通过预先训练得到的损伤类型识别模型对所述第三图片进行识别,得到所述损伤部位的损伤类型;
    所述据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域包括:
    根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域,并在所述第二图片标记出所述损伤部位的损伤类型。
  8. 根据权利要求1-7任意一项所述的方法,其特征在于,所述方法还包括:
    获取多个包含损伤部位的样本图片,以及所述样本图片各自的属性类别和对应的位置信息;
    分别根据各个所述样本图片的属性类别和对应的位置信息,对各个所述样本图片进行数据标注,得到所述样本图片各自对应的标注图像;
    将所述标注图像输入预设的基于单点多盒检测器算法的初始模型,训练得到所述基于单点多盒检测器算法的损伤检测模型。
  9. 一种基于深度学习的识别车辆损伤的装置,其特征在于,包括:
    图片获取模块,用于获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
    图片处理模块,用于通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
    图片检测模块,用于通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
    标记模块,用于根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
  10. 根据权利要求9所述的装置,其特征在于,所述图片处理模块具体用于:
    基于所述残差密集网络的浅层特征提取网络对所述第一图片进行卷积处理,得到所述 第一图片对应的浅层特征图;
    基于所述残差密集网络的残差密集网络对所述浅层特征卷积图进行卷积和线性修正处理,得到所述第一图片对应的多个残差密集特征图,所述残差密集网络包括多个残差密集块,所述多个残差密集特征图分别为所述多个残差密集块中的各个残差密集块对应的残差密集特征图;
    基于所述残差密集网络的密集特征融合网络对多个局部特征图进行密集特征融合,得到所述第一图片对应的全局特征图,所述多个局部特征图包括所述浅层特征图和所述多个残差密集特征图;
    基于所述残差密集网络的上采样网络对所述全局特征图进行上采样和卷积处理,得到第二图片。
  11. 根据权利要求10所述的装置,其特征在于,所述图片处理模块具体用于:
    通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到所述第d残差密集块对应的第d残差密集特征图,d为1至D中的每一个正整数,D为所述多个残差密集块的个数,所述第(d-1)残差密集特征图中的第0残差密集特征图为所述浅层特征卷积图;
    将所述第d残差密集特征图确定为所述第一图片对应的多个残差密集特征图。
  12. 根据权利要求9-11任意一项所述的装置,其特征在于,所述图片检测模块具体用于:
    基于所述损伤检测模型中的卷积层对所述第二图片进行卷积处理,得到多个尺寸不同的卷积特征图,每个卷积特征图包括多个卷积特征子图;
    分别确定所述每个卷积特征图对应的目标卷积特征信息,所述目标卷积特征信息包括所述多个卷积特征子图中各个卷积特征子图对应的卷积特征信息;
    分别确定所述目标卷积特征信息中的各个卷积特征信息对应的位置坐标,将在所述第二图片中与所述位置坐标对应的区域确定为所述各个卷积特征信息对应的第一区域;
    确定各个卷积特征信息对应的第一区域的置信度和所述第一区域对应的属性类别,并将置信度大于置信度阈值并且属性类别为损伤的第一区域确定为第二区域;
    根据所述第二区域对应的位置坐标确定所述损伤部位在所述第二图片中的位置坐标。
  13. 根据权利要求12所述的装置,其特征在于,所述图片检测模块具体用于:
    分别确定所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率,所述两种属性类别分别为背景和损伤;
    在所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率中确定最大匹配概率,并将所述最大匹配概率确定为所述各个卷积特征信息对应的第一区域的置信度,以及,将所述最大匹配概率对应的属性类别确定为所述第一区域对应的属性类别。
  14. 根据权利要求12所述的装置,其特征在于,所述图片检测模块具体用于:
    在所述第二区域的数量为多个的情况下,在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域;
    计算第四区域与第三区域的区域交叉度IoU,所述第四区域为所述第二区域中排除所述第三区域之后的第二区域,所述IoU用于指示所述第四区域与所述第三区域在所述第二图片中的重合程度;
    在所述第四区域中查找第五区域,所述第五区域与所述第三区域的IoU大于IoU阈值;
    在查找到所述第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区域中排除所述第三区域和所述第五区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;
    在未查找到第五区域的情况下,将所述第三区域确定为目标区域,并在所述第二区域中排除所述第三区域之后,如果所述第二区域的数量仍为多个,则执行所述在所述第二区 域中确定置信度最大的第二区域,将所述置信度最大的区域确定为第三区域的步骤;直到在所述第二区域中确定所有的目标区域;
    在所述第二区域的数量为一个的情况下,将所述第二区域确定为目标区域;
    将所述目标区域对应的位置坐标确定为所述损伤部位在所述第二图片中的位置坐标。
  15. 根据权利要求9-14任意一项所述的装置,其特征在于,所述装置还包括:
    图片截取模块,根据所述损伤部位在第二图片中的位置坐标从所述第二图片中截取包含所述损伤部位的第三图片,所述第三图片的尺寸小于所述第二图片。
    损伤类型识别模块,用于通过预先训练得到的损伤类型识别模型对所述第三图片进行识别,得到所述损伤部位的损伤类型;
    所述标记模块,还用于在所述第二图片中标记出所述损伤部位的损伤类型。
  16. 一种基于深度学习的识别车辆损伤的装置,其特征在于,包括处理器、存储器以及通信接口,所述处理器、存储器和通信接口相互连接,其中,所述通信接口用于接收和发送数据,所述存储器用于存储程序代码,所述处理器用于调用所述程序代码,执行:
    获取目标车辆对应的第一图片,所述目标车辆为待识别损伤的车辆,所述第一图片为包含所述目标车辆的损伤部位的图片;
    通过残差密集网络对所述第一图片进行处理,得到第二图片,所述第二图片的分辨率高于所述第一图片的分辨率;
    通过基于单点多盒检测器算法的损伤检测模型对所述第二图片进行检测,得到第一信息,所述第一信息包括所述损伤部位在所述第二图片中的位置坐标;
    根据所述位置坐标在所述第二图片中标记出所述损伤部位所在的区域。
  17. 根据权利要求16所述的装置,其特征在于,所述处理器具体用于:
    通过第d残差密集块内的卷积层对第(d-1)残差密集特征图进行卷积和线性修正处理,得到所述第d残差密集块对应的第d残差密集特征图,d为1至D中的每一个正整数,D为所述多个残差密集块的个数,所述第(d-1)残差密集特征图中的第0残差密集特征图为所述浅层特征卷积图;
    将所述第d残差密集特征图确定为所述第一图片对应的多个残差密集特征图。
  18. 根据权利要求16-17任意一项所述的装置,其特征在于,所述处理器具体用于:
    基于所述损伤检测模型中的卷积层对所述第二图片进行卷积处理,得到多个尺寸不同的卷积特征图,每个卷积特征图包括多个卷积特征子图;
    分别确定所述每个卷积特征图对应的目标卷积特征信息,所述目标卷积特征信息包括所述多个卷积特征子图中各个卷积特征子图对应的卷积特征信息;
    分别确定所述目标卷积特征信息中的各个卷积特征信息对应的位置坐标,将在所述第二图片中与所述位置坐标对应的区域确定为所述各个卷积特征信息对应的第一区域;
    确定各个卷积特征信息对应的第一区域的置信度和所述第一区域对应的属性类别,并将置信度大于置信度阈值并且属性类别为损伤的第一区域确定为第二区域;
    根据所述第二区域对应的位置坐标确定所述损伤部位在所述第二图片中的位置坐标。
  19. 根据权利要求18所述的装置,其特征在于,所述处理器具体用于:
    分别确定所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率,所述两种属性类别分别为背景和损伤;
    在所述各个卷积特征信息与所述损伤检测模型中的两种属性类别之间的匹配概率中确定最大匹配概率,并将所述最大匹配概率确定为所述各个卷积特征信息对应的第一区域的置信度,以及,将所述最大匹配概率对应的属性类别确定为所述第一区域对应的属性类别。
  20. 一种计算机非易失性可读存储介质,其特征在于,所述计算机非易失性可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使所述处理器执行如权利要求1-8任一项所述的方法。
PCT/CN2019/088801 2019-01-04 2019-05-28 基于深度学习的识别车辆损伤的方法和相关装置 WO2020140371A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910015378.1 2019-01-04
CN201910015378.1A CN109815997A (zh) 2019-01-04 2019-01-04 基于深度学习的识别车辆损伤的方法和相关装置

Publications (1)

Publication Number Publication Date
WO2020140371A1 true WO2020140371A1 (zh) 2020-07-09

Family

ID=66604083

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/088801 WO2020140371A1 (zh) 2019-01-04 2019-05-28 基于深度学习的识别车辆损伤的方法和相关装置

Country Status (2)

Country Link
CN (1) CN109815997A (zh)
WO (1) WO2020140371A1 (zh)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112215796A (zh) * 2020-09-11 2021-01-12 中国铁道科学研究院集团有限公司 一种适用于铁路货运检查的铁路货车车辆图像切割方法
CN112712036A (zh) * 2020-12-31 2021-04-27 广西综合交通大数据研究院 交通标志识别方法、装置、电子设备及计算机存储介质
CN113076898A (zh) * 2021-04-09 2021-07-06 长安大学 一种交通车辆目标检测方法、装置、设备及可读存储介质
CN113111708A (zh) * 2021-03-10 2021-07-13 北京爱笔科技有限公司 车辆匹配样本生成方法、装置、计算机设备和存储介质
CN113177937A (zh) * 2021-05-24 2021-07-27 河南大学 基于改进YOLOv4-tiny的布匹缺陷检测模型及方法
CN113627240A (zh) * 2021-06-29 2021-11-09 南京邮电大学 一种基于改进ssd学习模型的无人机树木种类识别方法
CN116416504A (zh) * 2023-03-16 2023-07-11 北京瑞拓电子技术发展有限公司 基于车辆协同的高速公路异物检测系统和方法
CN116434047A (zh) * 2023-03-29 2023-07-14 邦邦汽车销售服务(北京)有限公司 基于数据处理的车辆损伤范围确定方法及系统
CN116469132A (zh) * 2023-06-20 2023-07-21 济南瑞泉电子有限公司 基于双流特征提取的跌倒检测方法、系统、设备及介质

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110363238A (zh) * 2019-07-03 2019-10-22 中科软科技股份有限公司 智能车辆定损方法、系统、电子设备及存储介质
CN110427367B (zh) * 2019-07-05 2023-02-14 中国平安财产保险股份有限公司 基于评残参数的定损方法、装置、设备及存储介质
CN110555907B (zh) * 2019-07-16 2023-10-17 深圳进化动力数码科技有限公司 一种非标准化图片三维重构方法
CN110378321A (zh) * 2019-08-12 2019-10-25 乌鲁木齐明华智能电子科技有限公司 一种基础深度神经网络的车辆识别与抓拍技术
CN110969183B (zh) * 2019-09-20 2023-11-21 北京方位捷讯科技有限公司 一种根据图像数据确定目标对象受损程度的方法及系统
CN111368909B (zh) * 2020-03-03 2021-05-11 温州大学 一种基于卷积神经网络深度特征的车标识别方法
CN111652054B (zh) * 2020-04-21 2023-11-03 北京迈格威科技有限公司 关节点检测方法、姿态识别方法及装置
CN111666973B (zh) * 2020-04-29 2024-04-09 平安科技(深圳)有限公司 车辆损伤图片处理方法、装置、计算机设备及存储介质
CN112446870A (zh) * 2020-12-02 2021-03-05 平安科技(深圳)有限公司 管道损伤检测方法、装置、设备及存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102405638A (zh) * 2009-04-20 2012-04-04 富士胶片株式会社 图像处理装置、图像处理方法以及计算机可读介质
CN107358596A (zh) * 2017-04-11 2017-11-17 阿里巴巴集团控股有限公司 一种基于图像的车辆定损方法、装置、电子设备及系统
CN107665353A (zh) * 2017-09-15 2018-02-06 平安科技(深圳)有限公司 基于卷积神经网络的车型识别方法、装置、设备及计算机可读存储介质
US20180082379A1 (en) * 2016-09-21 2018-03-22 Allstate Insurance Company Enhanced Image Capture and Analysis of Damaged Tangible Objects
CN108961157A (zh) * 2018-06-19 2018-12-07 Oppo广东移动通信有限公司 图片处理方法、图片处理装置及终端设备

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108446618A (zh) * 2018-03-09 2018-08-24 平安科技(深圳)有限公司 车辆定损方法、装置、电子设备及存储介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102405638A (zh) * 2009-04-20 2012-04-04 富士胶片株式会社 图像处理装置、图像处理方法以及计算机可读介质
US20180082379A1 (en) * 2016-09-21 2018-03-22 Allstate Insurance Company Enhanced Image Capture and Analysis of Damaged Tangible Objects
CN107358596A (zh) * 2017-04-11 2017-11-17 阿里巴巴集团控股有限公司 一种基于图像的车辆定损方法、装置、电子设备及系统
CN107665353A (zh) * 2017-09-15 2018-02-06 平安科技(深圳)有限公司 基于卷积神经网络的车型识别方法、装置、设备及计算机可读存储介质
CN108961157A (zh) * 2018-06-19 2018-12-07 Oppo广东移动通信有限公司 图片处理方法、图片处理装置及终端设备

Cited By (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112215796A (zh) * 2020-09-11 2021-01-12 中国铁道科学研究院集团有限公司 一种适用于铁路货运检查的铁路货车车辆图像切割方法
CN112215796B (zh) * 2020-09-11 2022-12-23 中国铁道科学研究院集团有限公司 一种适用于铁路货运检查的铁路货车车辆图像切割方法
CN112712036A (zh) * 2020-12-31 2021-04-27 广西综合交通大数据研究院 交通标志识别方法、装置、电子设备及计算机存储介质
CN113111708A (zh) * 2021-03-10 2021-07-13 北京爱笔科技有限公司 车辆匹配样本生成方法、装置、计算机设备和存储介质
CN113111708B (zh) * 2021-03-10 2023-12-29 北京爱笔科技有限公司 车辆匹配样本生成方法、装置、计算机设备和存储介质
CN113076898B (zh) * 2021-04-09 2023-09-15 长安大学 一种交通车辆目标检测方法、装置、设备及可读存储介质
CN113076898A (zh) * 2021-04-09 2021-07-06 长安大学 一种交通车辆目标检测方法、装置、设备及可读存储介质
CN113177937A (zh) * 2021-05-24 2021-07-27 河南大学 基于改进YOLOv4-tiny的布匹缺陷检测模型及方法
CN113627240B (zh) * 2021-06-29 2023-07-25 南京邮电大学 一种基于改进ssd学习模型的无人机树木种类识别方法
CN113627240A (zh) * 2021-06-29 2021-11-09 南京邮电大学 一种基于改进ssd学习模型的无人机树木种类识别方法
CN116416504A (zh) * 2023-03-16 2023-07-11 北京瑞拓电子技术发展有限公司 基于车辆协同的高速公路异物检测系统和方法
CN116416504B (zh) * 2023-03-16 2024-02-06 北京瑞拓电子技术发展有限公司 基于车辆协同的高速公路异物检测系统和方法
CN116434047A (zh) * 2023-03-29 2023-07-14 邦邦汽车销售服务(北京)有限公司 基于数据处理的车辆损伤范围确定方法及系统
CN116434047B (zh) * 2023-03-29 2024-01-09 邦邦汽车销售服务(北京)有限公司 基于数据处理的车辆损伤范围确定方法及系统
CN116469132A (zh) * 2023-06-20 2023-07-21 济南瑞泉电子有限公司 基于双流特征提取的跌倒检测方法、系统、设备及介质
CN116469132B (zh) * 2023-06-20 2023-09-05 济南瑞泉电子有限公司 基于双流特征提取的跌倒检测方法、系统、设备及介质

Also Published As

Publication number Publication date
CN109815997A (zh) 2019-05-28

Similar Documents

Publication Publication Date Title
WO2020140371A1 (zh) 基于深度学习的识别车辆损伤的方法和相关装置
US10817956B2 (en) Image-based vehicle damage determining method and apparatus, and electronic device
CN108009543B (zh) 一种车牌识别方法及装置
EP3520045B1 (en) Image-based vehicle loss assessment method, apparatus, and system, and electronic device
US11144786B2 (en) Information processing apparatus, method for controlling information processing apparatus, and storage medium
Pereira et al. A deep learning-based approach for road pothole detection in timor leste
CN107944450B (zh) 一种车牌识别方法及装置
WO2018108129A1 (zh) 用于识别物体类别的方法及装置、电子设备
WO2021143063A1 (zh) 车辆定损方法、装置、计算机设备和存储介质
WO2018191421A1 (en) Image-based vehicle damage determining method, apparatus, and electronic device
CN110264444B (zh) 基于弱分割的损伤检测方法及装置
TWI716012B (zh) 樣本標註方法、裝置、儲存媒體和計算設備、損傷類別的識別方法及裝置
CN112329881B (zh) 车牌识别模型训练方法、车牌识别方法及装置
WO2021027157A1 (zh) 基于图片识别的车险理赔识别方法、装置、计算机设备及存储介质
CN115239644B (zh) 混凝土缺陷识别方法、装置、计算机设备和存储介质
CN111008576A (zh) 行人检测及其模型训练、更新方法、设备及可读存储介质
CN114820679B (zh) 图像标注方法、装置、电子设备和存储介质
CN113490947A (zh) 检测模型训练方法、装置、检测模型使用方法及存储介质
CN116596875B (zh) 晶圆缺陷检测方法、装置、电子设备及存储介质
WO2023178930A1 (zh) 图像识别方法、训练方法、装置、系统及存储介质
CN114429636B (zh) 图像扫描识别方法、装置及电子设备
CN113743163A (zh) 交通目标识别模型训练方法、交通目标定位方法、装置
CN116266406A (zh) 字符的坐标提取方法、装置、设备和存储介质
CN110738225B (zh) 图像识别方法及装置
CN113780076A (zh) 建筑垃圾的图像识别方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19906943

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS (EPO FORM 1205A DATED 25.08.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 19906943

Country of ref document: EP

Kind code of ref document: A1