Map acquisition method, intelligent driving identification method, electronic equipment and vehicle
By generating natural attack images based on the visual attention area and style transfer model in the autonomous driving system, the problem of low accuracy of adversarial attacks caused by unnatural textures in the existing technology is solved, and the security of the autonomous driving recognition system is improved.
Patent Information
- Application Number
- CN202410703931.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-31
- Publication Date
- 2024-09-27
AI Technical Summary
In the existing technology, the textures of the image physical attack method are too obvious, abrupt and unnatural, and are easy to be seen through, resulting in a low accuracy of adversarial attacks and affecting the security of the automatic driving recognition system.
By determining the visual attention area based on the original image, combining the style transfer model and the texture generation model, an attack image with the target style is generated, and the confidence is obtained through the texture discrimination model and the image recognition model, the target texture is determined, and the naturalness and confrontation of the texture are improved. Attack accuracy.
The generated textures are more natural, improve the accuracy and robustness against attacks, and enhance the security of the automatic driving recognition system.
Smart Images

Figure CN118710772A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of anti-attack technology, and in particular to a map acquisition method, an intelligent driving recognition method, an electronic device, a computer-readable storage medium, a computer program product and a vehicle. Background Art
[0002] Image physical attack technology mainly uses target maps to deceive and attack image recognition models. In the scenario of autonomous driving, all attack images are data obtained by on-board cameras, and most of the images obtained by on-board cameras are non-HD data of mobile driving. Therefore, when constructing and generating image recognition models, the generated target maps are likely to produce images that are inconsistent with human vision, making the maps very abrupt and unnatural, resulting in low accuracy of adversarial attacks, poor robustness and anti-interference of adversarial attack methods, and affecting the safety of autonomous driving recognition systems. Summary of the invention
[0003] A series of simplified concepts are introduced in the Summary of the Invention, which will be further described in detail in the Detailed Description of the Invention. The Summary of the Invention does not mean to attempt to define the key features and essential technical features of the claimed technical solution, nor does it mean to attempt to determine the scope of protection of the claimed technical solution.
[0004] The present invention provides a method for obtaining a map, comprising:
[0005] determining a visual attention region based on the original image;
[0006] Obtaining an attack image based on the target style data and the visual attention region;
[0007] Obtaining a first confidence level based on the attack image and the original image;
[0008] Performing image recognition on the attack image to obtain a second confidence level;
[0009] Based on the first confidence level and the second confidence level, the attack image is determined to be a target map.
[0010] Exemplarily, the determining, based on the first confidence level and the second confidence level, that the attack image is a target map includes:
[0011] The first confidence level and the second confidence level of a plurality of groups of the attack images are determined, and when the calculated values of the first confidence level and the second confidence level meet a preset condition, the attack image is determined to be a target map.
[0012] Exemplarily, obtaining an attack image based on the target style data and the visual attention area includes:
[0013] Get the target style image;
[0014] Processing the target style image through a style transfer model to obtain the target style data;
[0015] Processing the target style data through a map generation model to generate a style map;
[0016] The style map is synthesized with the visual attention area to generate an attack image.
[0017] Exemplarily, the style transfer model includes a target feature extractor and a deep feature extractor, the target feature extractor is used to extract style features of the target style image, the deep feature extractor is used to generate deep style features of the style features, and the deep style features are used to generate the target style data.
[0018] The map generation model includes a content feature extractor, which is used to extract content features of the target style data, and the content features are used to generate the style map.
[0019] Exemplarily, obtaining a first confidence level based on the attack image and the original image includes:
[0020] The attack image and the original image are distinguished as true or false by using a texture discrimination model, and the first confidence level is obtained when the discrimination result is that the original image is judged as the attack image, or the attack image is judged as the original image.
[0021] Exemplarily, the performing true and false discrimination on the attack image and the original image by using a texture discrimination model includes:
[0022] The style map of the attack image and the visual attention area of the original image are discriminated to generate a first adversarial loss function, wherein the first adversarial loss function is used to characterize the difference between the style map and the visual attention area.
[0023] Exemplarily, performing image recognition on the attack image to obtain a second confidence level includes:
[0024] Identify the right or wrong information of the first feature data and the second feature data by using an image recognition model, and obtain the second confidence level according to the right or wrong information;
[0025] The first feature data includes the category to which the attack image belongs; and the second feature data includes the category of the original image.
[0026] Exemplarily, determining a visual attention area based on an original image includes:
[0027] The region with visual recognition features in the original image is used as a visual attention region through a visual attention model.
[0028] Exemplarily, the visual attention model includes a gradient-weighted class activation map, which is used to obtain the visual attention weight, and the area with the visual recognition feature includes the area with the largest visual attention weight.
[0029] The present invention also provides an intelligent driving recognition method, comprising any of the map acquisition methods described above, and transmitting the map to an automatic driving recognition model to control the intelligent driving of a vehicle.
[0030] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements any of the above-mentioned methods for obtaining a map when executing the computer program.
[0031] The present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed, any of the above-mentioned methods for obtaining a map is implemented.
[0032] The present invention also provides a computer program product, including a computer program, wherein when the computer program is executed by a processor, the method for obtaining a texture image described in any one of the above items is implemented.
[0033] The present invention also provides a vehicle, comprising the electronic device as described above.
[0034] According to the map acquisition method, intelligent driving recognition method, electronic device, computer-readable storage medium, computer program product and vehicle provided by the present invention, the method generates a style map with a target style by combining a visual attention area determined in an original image and a target style image to synthesize an attack image, and obtains the confidence of the attack image to determine the target map. The target map obtained in this way combines a style transfer network, a generative adversarial network and a visual attention model, and trains the image generation model through different images, different scenes and different styles to make the target image more natural and the accuracy of the adversarial attack higher, thereby improving the robustness and anti-interference of the adversarial attack, and further improving the safety of the autonomous driving recognition system. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] The following drawings of the present invention are used to understand the present invention as part of the present invention. The embodiments of the present invention are shown in the drawings and the description thereof is used to explain the principle of the present invention.
[0036] In the attached figure:
[0037] Figure 1 is a flowchart of a method for obtaining a texture according to an embodiment of the present invention;
[0038] Figure 2 is a schematic block diagram of a method for obtaining a texture according to an embodiment of the present invention;
[0039] Figure 3 FIG. 4 is a structural block diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0040] In the following description, a large number of specific details are provided to provide a more thorough understanding of the present invention. However, it is apparent to those skilled in the art that the present invention can be implemented without one or more of these details. In other examples, in order to avoid confusion with the present invention, some technical features well known in the art are not described.
[0041] It should be understood that the present invention can be implemented in different forms and should not be construed as being limited to the embodiments presented herein. On the contrary, providing these embodiments will make the disclosure thorough and complete and fully convey the scope of the present invention to those skilled in the art. In the accompanying drawings, the sizes and relative sizes of layers and regions may be exaggerated for clarity. The same reference numerals throughout represent the same elements.
[0042] The purpose of the terms used herein is only to describe specific embodiments and is not intended to be limiting of the present invention. When used herein, the singular forms "one", "an" and "said / the" are also intended to include plural forms, unless the context clearly indicates otherwise. It should also be understood that the terms "consisting of" and / or "comprising", when used in this specification, determine the presence of the features, integers, steps, operations, elements and / or parts, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, parts and / or groups. When used herein, the term "and / or" includes any and all combinations of the relevant listed items.
[0043] In order to fully understand the present invention, detailed steps and detailed structures will be presented in the following description to illustrate the technical solution proposed by the present invention. The preferred embodiments of the present invention are described in detail below, but in addition to these detailed descriptions, the present invention may also have other implementations.
[0044] The current neural network models and image recognition models lack interpretability. When recognizing the same image, the factors that affect computer recognition of the image are completely different from the factors that affect human recognition of the image. For example, when recognizing an image of a dog, humans can determine whether the image is a dog by the global features of the dog, and the obvious features are the overall facial features and hair, while the computer determines whether the image is a dog by cutting the features. All features are cut into disordered fragments, and humans can no longer recognize the specific features. In this way, when constructing and generating maps to deceive and attack image recognition models, the maps can easily produce images that do not match human vision, making the maps very abrupt and unnatural, making it easy to detect deception and attack methods. This technology cannot further improve the safety of autonomous driving recognition systems.
[0045] Aiming at the problem that the existing image physics attack method has too obvious and unnatural stickers, which can be easily recognized by human eyes and lead to deception and failure of attack model, the present invention provides a sticker acquisition method, such as Figure 1 As shown, the following steps are included:
[0046] Step S110: determining a visual attention area based on the original image;
[0047] Step S120: obtaining an attack image based on the target style data and the visual attention area;
[0048] Step S130: obtaining a first confidence level based on the attack image and the original image;
[0049] Step S140: performing image recognition on the attack image to obtain a second confidence level;
[0050] Step S150: Based on the first confidence level and the second confidence level, determine that the attack image is a target map.
[0051] First, step S110 is executed to determine a visual attention area based on the original image.
[0052] Exemplarily, determining the visual attention region based on the original image includes: determining, by a visual attention model, a region in the original image having visually recognizable features as the visual attention region.
[0053] In one embodiment, referring to Figure 1 and Figure 2As shown, the original image obtains a visual attention area with common identification features with humans through a visual attention model, and the visual attention area is used to set the map so that the map produces a visual disappearance. The area with visual identification features includes but is not limited to the human eye attention area, the main feature area of the object, and the key feature area of the object. The area used for mapping in the original image is determined by visual attention, and only the place with the largest visual attention weight is mapped, that is, the human visual attention is used to stick the map on an invisible part so that the map produces a visual disappearance.
[0054] In one embodiment, the visual attention model is a gradient-weighted class activation mapping (Grad-CAM), which is used to obtain visual attention weights, and the area with visual recognition features includes the area with the largest visual attention weight. Specifically, Grad-CAM is used to obtain a localized mapping of class distinction to obtain the weights of different classes and the weight of each pixel in the image that affects the image classification. The weight calculation method of Grad-CAM is to calculate the inverse gradient value of the penultimate layer of the convolutional neural network, which is the output value y of the previous layer of the last fully connected layer network. c The inverse gradient value, where y c is the output value before softmax, and the calculation formula of the inverse gradient is Among them A k is the feature map activation value in the convolution layer. For the visual attention weight with width u and height v for:
[0055]
[0056] Then, the attention map of the input image is calculated and obtained through these feature maps. Specifically, this weight represents a partial linearization of the deep network downstream of A and captures the importance of feature map k for target class c. The attention map is a weighted combination of feature maps. Finally, the ReLU function is used to generate the attention map:
[0057]
[0058] The visual attention feature map m is generated through the above steps. The output visual attention region can highlight the important areas in the original image corresponding to any decision of interest. Therefore, key areas are provided, and the modification of these areas is more sensitive to the final prediction, thereby obtaining a stronger attack capability.
[0059] Next, step S120 is executed to obtain an attack image based on the target style data and the visual attention area.
[0060] Exemplarily, obtaining an attack image based on target style data and a visual attention area includes: obtaining a target style image; processing the target style image through a style transfer model to obtain the target style data; processing the target style data through a map generation model to generate a style map; and synthesizing the style map with the visual attention area to generate an attack image.
[0061] In one embodiment, images of different styles are transferred through a style transfer model and a texture generation model to obtain a texture with the same style as the specified image, wherein the style includes but is not limited to scene, color, and content.
[0062] In one embodiment, the style transfer model includes a target feature extractor and a deep feature extractor, the target feature extractor is used to process the target style image to extract style features, the deep feature extractor is used to process the style features to generate deep style features, and the deep style features are used to generate the target style data.
[0063] The target style data includes a style loss function, and the style loss function Ds is used to characterize the style difference between the map and the target style image:
[0064]
[0065] in, is a feature extractor that can be different from the target model. G is in The Gram matrix of deep features extracted from a set of style layers.
[0066] The style transfer model uses a convolutional neural network, different layers can learn different styles, and all convolutional layers of the network serve as style layers.
[0067] In one embodiment, the map generation model includes a content feature extractor, which is used to extract content features of the target style data, and the content features are used to generate the style map. A content preservation loss function is further generated based on the content features. Since the content in the generated style map may be very different from the target style image, the loss content of the target style image relative to the style map is preserved by the content preservation loss function:
[0068]
[0069] Among them, C ldenotes the set of content layers used to extract content representation, which ensures that the attack image has similar content to the target style image in the deep representation space.
[0070] In one embodiment, the map generation model adopts a convolutional neural network. Specifically, the map generation model adopts a U-net network, Ck represents a Convolution-LayerNorm-LeakyReLU layer with k filters, all convolutions are (4×4) spatial filters applied to stride 2, and in its encoder-decoder architecture, the structure of the encoder can be C16-C32-C64-C128, and the structure of the decoder can be C64-C32-C16-C3, which is not limited in this application.
[0071] In one embodiment, the style map is synthesized with the visual attention area to generate an attack image. The attack image consists of two parts: the style map and the original image. The visual attention area used to set the style map is determined by the visual attention. Only the area with the largest visual attention weight is mapped. The content of the style map is determined by the style transfer model. The style map is generated as close to the target style image as possible, so that the human eye cannot easily identify it. The style map and the visual attention area are processed together to synthesize the attack image to produce the effect of the attack.
[0072] Next, step S130 is executed to obtain a first confidence level based on the attack image and the original image.
[0073] Exemplarily, obtaining a first confidence level based on the attack image and the original image includes:
[0074] The attack image and the original image are discriminated as true or false by a texture discrimination model. When the discrimination result is that the original image is discriminated as the attack image, or the attack image is discriminated as the original image, the first confidence is obtained. The true or false discrimination result of the attack image and the original image is obtained by a texture discrimination model, and the first confidence is obtained according to the true or false discrimination result. When the discrimination result is that the original image is discriminated as the attack image, or the attack image is discriminated as the original image, the attack image is discriminated as "true", and when the attack image is discriminated as "true", its confidence of "true" is retained.
[0075] In one embodiment, when the original image is judged as the original image, or the attack image is judged as the attack image, the attack image is judged as "false", and the image with the judgment result of "false" is directly discarded.
[0076] In one embodiment, the structure of the discriminator model may be C64-C128-C256-C512, which is not limited in this application.
[0077] In one embodiment, the true or false discrimination of the attack image and the original image by a texture discrimination model includes: discriminating the texture part of the attack image and the visual attention area of the original image to generate a first adversarial loss function, wherein the first adversarial loss function is used to characterize the difference between the style map and the visual attention area in the attack image.
[0078] Specifically, the last layer of the discriminator network is fed into a linear layer to generate a one-dimensional output, which is then passed through a Sigmoid function as the final output result, generating the first generation adversarial loss function L GAN for:
[0079] L GAN (G,D)=Ε x [logD(x)]+Ε x [log(1-D(M(G(δ))))] (Equation 5)
[0080] Among them, x,δ are the input original image and the specified style image, D is the discriminator, m is the map area generated by visual attention, and G is the map generator.
[0081] In one embodiment, the generated image G(δ) of the texture is obtained by using the texture generation model U-net, and then the generated image G(δ) is synthesized with the visual attention feature map m obtained in the first step to obtain the attack image Fixed generative model G to train discriminator D, the optimization function is to maximize the generation of adversarial loss function L GAN ,
[0082] Next, step S140 is executed to perform image recognition on the attack image to obtain a second confidence level.
[0083] Exemplarily, performing image recognition on the attack image to obtain the second confidence level includes: identifying right or wrong information of first feature data and second feature data through an image recognition model, and obtaining the second confidence level based on the right or wrong information; wherein the first feature data includes the category to which the attack image belongs; and the second feature data includes the category of the original image.
[0084] In one embodiment, the right or wrong information of the feature data of the attack image and the feature data of the original image is determined, and the second confidence is determined by the right or wrong information; for example, the feature data of "dog" has the feature information of "dog", and the feature data of "cat" has the feature information of "cat"; wherein "right" means that the attack image is identified as the category to which the target map belongs, such as identifying "dog" as "dog", and "wrong" means that the attack image is identified as other categories, such as identifying "dog" as "cat".
[0085] In one embodiment, the color of the generated map needs to be controlled within the printable range so that it can be tested and applied in real scenes. nps To show the difference between the color in the texture and the color printed by a normal printer:
[0086]
[0087] where p patch is a pixel in the texture P, c print is a color in a set of printable colors C. By reducing the color loss function L nps The colors in an image can be made closer to printable colors.
[0088] In addition to making the generated map printable, the generated map also needs to be as smooth as possible to make it look more natural and prevent noise, through the noise loss function L tv To characterize the difference between adjacent pixels of the map:
[0089]
[0090] If the adjacent pixels are similar, the noise loss is low, and if the adjacent pixels are different, the noise loss is high. By reducing the noise loss function L tv Make adjacent pixels in an image closer.
[0091] The generated sticker attack image needs to reduce the accuracy of the image recognition model, and its adversarial loss function L adv for:
[0092] L adv = -log(p y (x')) (Equation 8)
[0093] The overall loss function L of the image recognition model is:
[0094]
[0095] In one embodiment, the discriminator D is fixed to train the generative model G, and the optimization function is to minimize L:
[0096]
[0097] Among them, Lc represents the content loss function, L GAN represents the generated adversarial loss function, L nps represents the color loss function, L tv represents the noise loss function, L adv Represents the anti-loss function.
[0098] The overall loss function L of the image recognition model is actually a cross entropy. The identification result of the fixed discriminator D is a probability value, so the identification result is used to represent the second confidence. The purpose of fixing the discriminator D is to make the fixed discriminator result D(x) as close to 1 as possible and the result D(G(z)) of the generative model G as close to 0. Therefore, D mainly maximizes the above loss function, while G is just the opposite. It mainly minimizes the above loss function. In the process of fixing the discriminator D to train the generative model G, the second confidence is getting closer and closer to the true value.
[0099] Next, step S150 is performed: based on the first confidence level and the second confidence level, determining that the attack image is a target map.
[0100] Exemplarily, determining the attack image as a target map based on the first confidence and the second confidence includes: determining the first confidence and the second confidence of multiple groups of the attack images, and when the calculated values of the first confidence and the second confidence meet preset conditions, determining the attack image as a target map.
[0101] In one embodiment, the calculated values of the first confidence level and the second confidence level are calculated in the following manner, specifically including one or more of the maximum value, average value, product value, variance, median, fitted value, standard deviation, and mode obtained by the first confidence level and the second confidence level. The preset condition can take the maximum value of multiple sets of calculated values.
[0102] In one embodiment, the attack image has only one set of images, and the first confidence level is used to indicate the percentage of "true" discrimination results of the texture discrimination model in the attack image, and the second confidence level is used to indicate the percentage of "correct" recognition results of the image recognition model in the attack image. When the first confidence level or the second confidence level both have values, the attack image is used as the target image.
[0103] In one embodiment, there are multiple groups of attack images, and the first confidence is used to indicate the percentage of "true" discrimination results of the texture discrimination model in the multiple attack images. For example, the first group of attack images generated includes 10 attack images, of which 3 images are "true" discrimination results of the texture discrimination model, so the first confidence of the first group of attack images is 30%; the second group of attack images generated includes 10 attack images, of which 4 images are "true" discrimination results of the texture discrimination model, so the first confidence of the second group of attack images is 40%. The second confidence is used to indicate the percentage of "correct" recognition results of the image recognition model in the multiple attack images. For example, the first group of attack images generated includes 10 attack images, of which 8 images are "correct" recognition results of the image recognition model, so the second confidence of the first group of attack images is 80%; the second group of attack images generated includes 10 attack images, of which 6 images are "correct" recognition results of the image recognition model, so the second confidence of the second group of attack images is 60%.
[0104] In one embodiment, the first confidence and the second confidence satisfy the preset condition including: the group with the highest average value of the first confidence and the second confidence is the target map. For example, the average value of the first confidence and the second confidence of the first group of attack images is 55%, which is higher than the average value of the first confidence and the second confidence of the second group of attack images by 50%, so the first group of attack images is the target map.
[0105] It should be noted that the preset conditions can be set as needed, for example, the first confidence level and the second confidence level are multiplied by their respective weight coefficients, and then summed or averaged, etc. This application does not impose any restrictions on this.
[0106] The present invention also provides an intelligent driving recognition method, including the map acquisition method as described above, transmitting the map to an automatic driving recognition model to control the intelligent driving of a vehicle.
[0107] According to the map acquisition method and intelligent driving recognition method provided by the present invention, the original image is passed through the visual attention model to obtain the area with common recognition features with humans, and the style transfer model and the map generation model are used to obtain the map with the same style as the specified image, and the original image and the generated attack image are passed through the map discrimination model to obtain the true and false information of the image, and the generated attack image is passed through the image recognition model to obtain the right and wrong information of the image recognition, thereby providing a map acquisition method based on style transfer and visual attention. Compared with the existing image physical attack method, the map acquisition method provided by the present invention can make the generated map more natural and not produce obvious recognition to the human eye, improve the efficiency of counterattack, and have higher transferability, so as to further improve the safety of the automatic driving recognition system.
[0108] Figure 3 A schematic block diagram of an electronic device 300 according to an embodiment of the present invention is shown. The electronic device 300 includes a memory 310 and a processor 320 .
[0109] The memory 310 stores program codes for implementing corresponding steps in the texture acquisition method 100 according to the embodiment of the present invention.
[0110] The processor 320 is used to run the program code stored in the memory 310 to execute the corresponding steps of the texture acquisition method 100 according to the embodiment of the present invention.
[0111] In addition, the present invention also provides a computer-readable storage medium, on which program instructions are stored, and when the program instructions are executed by a computer or a processor, they are used to execute the corresponding steps of the method 100 for obtaining a map according to the embodiment of the present invention. The computer-readable storage medium may include, for example, a storage component of a tablet computer, a hard disk of a personal computer, a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a portable compact disk read-only memory (CD-ROM), a USB memory, or any combination of the above storage media.
[0112] In addition, the present invention also provides a computer program product, including a computer program, and when the computer program is executed by a processor, the corresponding steps of the texture acquisition method 100 of the embodiment of the present invention are implemented.
[0113] In addition, the present invention also provides a vehicle, wherein the vehicle is equipped with the electronic device 300 described above.
[0114] According to the map acquisition method, electronic device, computer-readable storage medium, electronic device and vehicle provided by the present invention, an attack image is generated by generating content with a target style in a visual attention area determined in an original image, and the confidence of the attack image is obtained to determine a target map. The target map obtained in this way is more natural and has a higher accuracy rate in countering attacks, thereby improving the robustness and anti-interference ability of countering attacks and further improving the safety of the autonomous driving recognition system.
[0115] Although example embodiments have been described herein with reference to the accompanying drawings, it should be understood that the above example embodiments are merely exemplary and are not intended to limit the scope of the present application to this. Those of ordinary skill in the art may make various changes and modifications therein without departing from the scope and spirit of the present application. All these changes and modifications are intended to be included within the scope of the present application as required by the appended claims.
[0116] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0117] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed.
[0118] In the description provided herein, a large number of specific details are described. However, it is understood that the embodiments of the present application can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.
[0119] Similarly, it should be understood that in order to streamline the present application and help understand one or more of the various inventive aspects, in the description of the exemplary embodiments of the present application, the various features of the present application are sometimes grouped together into a single embodiment, figure, or description thereof. However, the method of the present application should not be interpreted as reflecting the following intention: the claimed application requires more features than the features clearly stated in each claim. More specifically, as reflected in the corresponding claims, the inventive point is that the corresponding technical problem can be solved with features less than all the features of a single disclosed embodiment. Therefore, the claims following the specific embodiment are hereby explicitly incorporated into the specific embodiment, wherein each claim itself serves as a separate embodiment of the present application.
[0120] It will be understood by those skilled in the art that, except for mutually exclusive features, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this specification may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature that provides the same, equivalent or similar purpose.
[0121] In addition, those skilled in the art will appreciate that, although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features of different embodiments is meant to be within the scope of the present application and form different embodiments. For example, in the claims, any one of the claimed embodiments can be used in any combination.
[0122] The various component embodiments of the present application can be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that a microprocessor or digital signal processor (DSP) can be used in practice to implement some or all of the functions of some modules in the article analysis device according to the embodiment of the present application. The present application can also be implemented as a device program (e.g., computer program and computer program product) for executing part or all of the methods described herein. Such a program implementing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
[0123] It should be noted that the above embodiments illustrate the present application rather than limit the present application, and that those skilled in the art may design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets should not be constructed as a limitation to the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of multiple such elements. The present application may be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In a unit claim that lists several devices, several of these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names.
[0124] The above is only a specific implementation or description of a specific implementation of the present application, and the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. The protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A method for obtaining a map, characterized in that: include: determining a visual attention region based on the original image; Obtaining an attack image based on the target style data and the visual attention region; Obtaining a first confidence level based on the attack image and the original image; Performing image recognition on the attack image to obtain a second confidence level; Based on the first confidence level and the second confidence level, the attack image is determined to be a target map.
2. The method according to claim 1, characterized in that The step of determining the attack image as a target map based on the first confidence level and the second confidence level includes: The first confidence level and the second confidence level of a plurality of groups of the attack images are determined, and when the calculated values of the first confidence level and the second confidence level meet a preset condition, the attack image is determined to be a target map.
3. The method according to claim 1, characterized in that The method of obtaining an attack image based on the target style data and the visual attention area includes: Get the target style image; Processing the target style image through a style transfer model to obtain the target style data; Processing the target style data through a map generation model to generate a style map; The style map is synthesized with the visual attention area to generate an attack image.
4. The method according to claim 3, characterized in that The style transfer model includes a target feature extractor and a deep feature extractor, wherein the target feature extractor is used to extract style features of the target style image, and the deep feature extractor is used to generate deep style features of the style features, and the deep style features are used to generate the target style data; The map generation model includes a content feature extractor, which is used to extract content features of the target style data, and the content features are used to generate the style map.
5. The method according to claim 3, characterized in that The obtaining a first confidence level based on the attack image and the original image includes: The attack image and the original image are distinguished as true or false by using a texture discrimination model, and the first confidence level is obtained when the discrimination result is that the original image is judged as the attack image, or the attack image is judged as the original image.
6. The method according to claim 5, characterized in that The step of distinguishing the attack image and the original image by using a texture discrimination model includes: The style map of the attack image and the visual attention area of the original image are discriminated to generate a first adversarial loss function, wherein the first adversarial loss function is used to characterize the difference between the style map and the visual attention area.
7. The method according to claim 2, characterized in that The performing image recognition on the attack image to obtain a second confidence level includes: Identify the right or wrong information of the first feature data and the second feature data by using an image recognition model, and obtain the second confidence level according to the right or wrong information; The first feature data includes the category to which the attack image belongs; and the second feature data includes the category of the original image.
8. The method according to claim 1, characterized in that Determine the visual attention area based on the original image, including: The region with visual recognition features in the original image is used as a visual attention region through a visual attention model.
9. The method according to claim 8, characterized in that The visual attention model includes a gradient-weighted class activation map, which is used to obtain the visual attention weight, and the area with visual recognition features includes the area with the largest visual attention weight.
10. An intelligent driving recognition method, characterized in that: The method for acquiring a map comprising the steps of transmitting the target map to an autonomous driving recognition model to control intelligent driving of a vehicle.
11. An electronic device, characterized in that: The invention comprises a memory, a processor and a computer program stored in the memory and running on the processor, wherein the processor implements the map acquisition method according to any one of claims 1 to 9 when executing the computer program.
12. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed, the map acquisition method according to any one of claims 1 to 9 is implemented.
13. A computer program product, characterized in that The invention comprises a computer program, which, when executed by a processor, implements the texture acquisition method according to any one of claims 1 to 9.
14. A vehicle comprising the electronic device according to claim 11.
