A model backdoor attack vulnerability analysis method and system for segmentation learning

By segmenting the learning model and utilizing the iterative training of the middle layer representation and the auxiliary data set, the backdoor attack vulnerability of the model in the segmentation learning framework is detected, which solves the problem of the inability to effectively analyze the vulnerability of the segmentation learning model in the existing technology, and realizes the The security detection of non-label sharing framework promotes the development of defense technology.

CN118366010BActive Publication Date: 2024-09-20ZHEJIANG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410781553.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-18
Publication Date
2024-09-20
Estimated Expiration
2044-06-18

AI Technical Summary

Technical Problem

Existing technologies fail to effectively analyze model backdoor attack vulnerabilities in segmentation learning, especially for non-label sharing segmentation learning frameworks. Existing model vulnerability testing methods are not applicable and cannot be used as a universal backdoor security detection method.

Method used

A segmentation learning-oriented model backdoor attack vulnerability analysis method is proposed. By dividing the image classification model into a bottom model, an intermediate model and a top model, the middle layer representation and the auxiliary data set are used to iteratively train the bottom alternative model to obtain the clustering categories. Mapping relationships of real categories, obtaining intermediate layer representation triggers based on statistical ideas, injecting backdoors into the server-side intermediate model and training, detecting the success rate of backdoor attacks, and judging the vulnerability of the model.

Benefits of technology

Without affecting the normal performance of the model, it realizes the detection of model vulnerability analysis in the segmentation learning framework, provides guidance for model defense, can more comprehensively expose model vulnerabilities, and is suitable for non-label sharing segmentation learning frameworks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118366010B
    Figure CN118366010B
Patent Text Reader

Abstract

The present invention discloses a model backdoor attack vulnerability analysis method and system for segmentation learning, which belongs to the field of artificial intelligence security. The first intermediate layer representation sent by the client bottom model to the server intermediate model during the segmentation learning process of the image classification model is collected, and the bottom replacement model is iteratively trained in combination with the auxiliary data set; the clusterer is trained using the first intermediate layer representation to obtain the mapping relationship from the clustering category to the real category, and the anchor point is obtained; the intermediate layer representation trigger corresponding to the image trigger is obtained based on the statistical idea; the backdoor attack method based on the anchor point of the intermediate layer expression form replaces the target class sample, injects the backdoor into the intermediate model and trains; the test sample is used to detect the backdoor attack success rate of the image classification model, and the model backdoor attack vulnerability is obtained. The present invention comprehensively considers the success rate and concealment of the attack test method, which can more comprehensively expose the vulnerabilities of the model under the segmentation learning framework and promote the development of defense technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence security, and in particular to a model backdoor attack vulnerability analysis method and system for segmentation learning. Background Art

[0002] With the rapid development of the Internet of Things and big data technology, data has exploded. However, due to the consideration of user privacy data, the efficient circulation of data is greatly restricted. As one of the typical paradigms of distributed learning, segmentation learning can transfer a large amount of computing overhead to the server without leaking the original data, greatly reducing the computing power resource requirements of the data owner.

[0003] Although segmentation learning brings many conveniences to mining data value, it still has many security and privacy risks. Existing work has shown that even with a segmentation learning architecture with label protection, label inference attacks can still be implemented. At the same time, several data and model stealing attacks against segmentation learning have also been proposed, such as the model inversion-based method and the pseudo-client-based method. This type of attack method is proposed to further test the model vulnerability.

[0004] Currently, there is no backdoor attack vulnerability analysis method for segmentation learning, especially for non-label shared segmentation learning. The existing model vulnerability testing methods are completely inapplicable and cannot be used as a universal backdoor security detection method. Summary of the invention

[0005] In view of the above problems, the present invention proposes a model backdoor attack vulnerability analysis method and system for segmentation learning, which adopts a covert attack testing method to inject the backdoor into the intermediate model on the server side, and adopts a trigger embedding selection method and a target embedding anchor point selection method to implant the backdoor. There is no need to modify the training data, and the attack test can be implemented without affecting the normal performance of the model. Further, the vulnerability analysis results of the model are obtained to provide guidance for model defense.

[0006] In order to achieve the above object, the technical solution adopted by the present invention is as follows:

[0007] In a first aspect, the present invention proposes a model backdoor attack vulnerability analysis method for segmentation learning, comprising the following steps:

[0008] (1) Split the image classification model to be analyzed for backdoor attack vulnerability into a bottom model, an intermediate model, and a top model, wherein the intermediate model is deployed on the server side, and the bottom model and the top model are deployed on the local client side;

[0009] (2) Collect the first intermediate layer representations sent by the client-side underlying model to the server-side intermediate model during the segmentation learning and training process of the image classification model, and iteratively train the underlying alternative model using the collected first intermediate layer representations and the auxiliary dataset;

[0010] (3) Use the collected first intermediate layer representation to train the clusterer, obtain the mapping relationship between cluster categories and real categories through the clustering results of the auxiliary dataset and the real labels, and use the cluster center of the backdoor attack target category as the anchor point;

[0011] (4) Obtaining the intermediate layer representation trigger corresponding to the image trigger based on statistical thinking;

[0012] (5) A backdoor attack method based on the anchor point replacement of the target class sample in the intermediate layer expression form, injecting the backdoor into the server-side intermediate model and training it to modify the server-side intermediate model;

[0013] (6) Use test samples to detect the backdoor attack success rate of the image classification model and determine the backdoor vulnerability of the image classification model. The higher the backdoor attack success rate, the higher the backdoor vulnerability of the image classification model in segmentation learning.

[0014] Furthermore, the underlying replacement model adopts a two-stage training method, including:

[0015] Select a training batch of auxiliary dataset samples and the same number of first intermediate layer representations;

[0016] In the first stage of training, the auxiliary data set is input into the underlying substitution model, and the output of the underlying substitution model is used as the first substitution intermediate layer representation. Then, the first substitution intermediate layer representation is input into the discriminator, and the discriminator determines whether the input intermediate layer representation is the first substitution intermediate layer representation or the first intermediate layer representation. The loss of the auxiliary data set samples is calculated according to the judgment result of the first stage discriminator, and the gradient of the underlying substitution model is calculated according to the loss result and the underlying substitution model is updated.

[0017] During the second stage training process, the first intermediate layer representation is input into the discriminator, and the discriminator determines whether the input intermediate layer representation is the first alternative intermediate layer representation or the first intermediate layer representation. According to the judgment result of the second stage discriminator and the judgment result of the first stage discriminator, the joint loss of the auxiliary data set sample and the first intermediate layer representation is calculated, and the gradient of the discriminator is calculated and updated according to the joint loss result.

[0018] Iterate multiple training batches to complete a round of training, and obtain the underlying replacement model after several rounds of training.

[0019] Furthermore, the underlying replacement model is a backbone network part that is consistent with the image classification model task.

[0020] Furthermore, the step of obtaining a mapping relationship between cluster categories and real categories includes:

[0021] Input the collected first intermediate layer representation into the server-side intermediate model, obtain the second intermediate layer representation of the server-side intermediate model, use the second intermediate layer representation to train a clusterer, the trained clusterer can classify the second intermediate layer representation, and the classification result is the category to which the original image sample corresponding to the second intermediate layer representation belongs;

[0022] The auxiliary dataset is input into the trained underlying substitution model to obtain the first substitution intermediate layer representation, and then the intermediate model is used to generate the second substitution intermediate layer with the first substitution intermediate layer representation as input. The trained clusterer is used to obtain the clustering label of the second substitution intermediate layer representation as the clustering label of the corresponding auxiliary dataset sample.

[0023] The maximum match is calculated based on the Hungarian algorithm to obtain the mapping relationship between the clustering labels of the auxiliary dataset samples and the true labels.

[0024] Furthermore, taking the cluster center of the backdoor attack target category as an anchor point includes:

[0025] Obtain the cluster label corresponding to the backdoor attack target category label according to the mapping relationship;

[0026] The cluster center within the cluster corresponding to the cluster label is used as the anchor point.

[0027] Furthermore, the method of obtaining the intermediate layer representation trigger corresponding to the image trigger based on the statistical idea includes:

[0028] Image triggers are added to all auxiliary dataset samples to obtain auxiliary datasets with triggers.

[0029] Inputting the auxiliary dataset with the trigger into the trained underlying alternative model to obtain a first alternative intermediate layer representation with the trigger; and inputting the auxiliary dataset without the trigger into the trained underlying alternative model to obtain a first alternative intermediate layer representation without the trigger;

[0030] Calculate the difference between the first alternative intermediate layer representation with trigger and the first alternative intermediate layer representation without trigger corresponding to the same auxiliary data set sample at each intermediate layer representation bit, accumulate the differences of all samples at the same bit, and take the bits with the largest difference accumulation value as the trigger position;

[0031] Calculate the mean of the first alternative intermediate layer representation of the auxiliary data set samples at each intermediate layer representation position, and take the mean of the trigger position as the trigger value;

[0032] The trigger position and the trigger value are combined to obtain the middle layer representing the trigger.

[0033] Furthermore, a two-stage training method is used to inject a backdoor into the server-side intermediate model and train it, including:

[0034] Select the first intermediate layer representation of the collection of a training batch;

[0035] During the first stage of training, a copy of the server-side intermediate model is retained, recorded as the copy model, and an intermediate layer representation trigger is added to the collected first intermediate layer representation to obtain the first intermediate layer representation with the trigger; the loss between the second intermediate layer representation generated after the first intermediate layer representation with the trigger is input into the server-side intermediate model and the anchor point is calculated, and the corresponding gradient is calculated according to the loss result to update the intermediate model;

[0036] During the second stage of training, the first intermediate layer representations collected without triggers are respectively input into the intermediate model and the replica model updated in the first stage to obtain two second intermediate layer representations, the loss between the two second intermediate layer representations is calculated, the corresponding gradient is calculated according to the loss result, and the intermediate model is updated;

[0037] Iterate multiple training batches to complete a round of training, and after several rounds of training, the final modified server-side intermediate model is obtained.

[0038] Furthermore, the backdoor attack success rate calculation method is:

[0039] The test sample is implanted into the image trigger corresponding to the trigger represented by the middle layer, and it is determined whether the test sample with the added image trigger is classified as the backdoor attack target category. If so, the backdoor attack is successful, otherwise the backdoor attack fails, and the backdoor attack success rate is obtained by statistics.

[0040] Furthermore, the image trigger is to inject a pixel block or add an image filter.

[0041] In a second aspect, the present invention proposes a model backdoor attack vulnerability analysis system for segmented learning, which is used to implement the above-mentioned model backdoor attack vulnerability analysis method for segmented learning.

[0042] Compared with the prior art, the present invention has the following beneficial effects: the present invention implements model vulnerability detection for the non-label-sharing segmentation learning framework, comprehensively considers the success rate and concealment of the attack test method, and only needs to modify the intermediate model on the server side, without changing the local underlying model and top-level model on the client side. The vulnerability detection method proposed in the present invention can more comprehensively expose the vulnerabilities of the model under the segmentation learning framework and promote the development of defense technology. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 Flowchart of the backdoor attack vulnerability analysis method for the segmentation learning framework.

[0044] Figure 2 Schematic diagram of the training of the underlying replacement model.

[0045] Figure 3 The diagram is a diagram of how to obtain triggers for the middle layer. DETAILED DESCRIPTION

[0046] The present invention is further described in detail below in conjunction with the accompanying drawings and embodiments.

[0047] The accompanying drawings are only schematic illustrations of the present invention and are not necessarily drawn to scale. Some of the block diagrams shown in the accompanying drawings are functional entities that do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.

[0048] The flowcharts shown in the accompanying drawings are only exemplary and do not necessarily include all the steps. For example, some steps may be decomposed, while some steps may be combined or partially combined, so the actual execution order may change according to the actual situation.

[0049] Segmented learning is a distributed learning method. In segmented learning, the training scenario involves multi-terminal collaborative training after model segmentation. The present invention is aimed at non-label shared segmented learning, and the model to be trained is divided into three parts: the bottom model, the intermediate model and the top model. Generally, the intermediate model has a large computational overhead and will be trained uniformly on the server side, while the bottom model and the top model will be retained on the local client. Segmented learning can be used to solve the problem of limited computing resources on the local client.

[0050] In one embodiment provided by the present invention, the overall process is as follows Figure 1 As shown, the specific implementation steps are as follows:

[0051] S1, after splitting the target model into a bottom model, an intermediate model and a top model, the intermediate model is deployed on the server side, and the bottom model and the top model are deployed on the local client. The split layer between the bottom model and the intermediate model is used as the first intermediate layer, that is, the first intermediate layer is located at the last layer of the bottom model; the split layer between the intermediate model and the top model is used as the second intermediate layer, that is, the second intermediate layer is located at the last layer of the intermediate model.

[0052] In this embodiment, the target model is an image classification model used to implement image classification tasks, which can be an image classification task implemented based on a model architecture such as ResNet, ResNeXt, or VGG.

[0053] During the segmentation learning training process, local training samples are input into the client's underlying model, and the client's underlying model generates a first intermediate layer representation, which is then sent to the server's intermediate model. The server's intermediate model uses the first intermediate layer representation of the client's underlying model as input to generate a second intermediate layer representation, and then returns the second intermediate layer representation to the client's top-level model. The client's top-level model uses the second intermediate layer representation as input to generate classification results, calculates losses and gradients based on the true labels of the training samples, and updates the target model parameters through gradient feedback.

[0054] S2, obtaining the first intermediate layer representation sent by the client underlying model during the segmentation learning training process, and iteratively training the underlying replacement model using the collected first intermediate layer representation of the client underlying model and the auxiliary data set.

[0055] In this step, the underlying replacement model is also the backbone network part of the model that can implement the image classification task. It does not need to achieve the final classification, nor does it need to be completely consistent with the client's underlying model, but it needs to have the same classification category as the target model.

[0056] In a specific implementation of the present invention, Figure 2 As shown, step S2 can be implemented as follows:

[0057] (2-1) Set the number of training rounds for the underlying surrogate model and the number of training batches contained in each training round.

[0058] (2-2) In each training batch, select the same number of auxiliary dataset samples and the first intermediate layer representation of the client underlying model collected in step S2, and use the auxiliary dataset samples and the first intermediate layer representation of the client underlying model to update the underlying replacement model. Specifically, the training process includes two stages:

[0059] In the first stage of training, the auxiliary data set is input into the underlying substitution model, and the output of the underlying substitution model is used as the first substitution intermediate layer representation of the underlying substitution model. Then, the first substitution intermediate layer representation is input into the discriminator, and the discriminator determines whether the input intermediate layer representation is the first substitution intermediate layer representation or the first intermediate layer representation of the client underlying model. The loss of the auxiliary data set samples is calculated according to the judgment result of the first stage discriminator, and the calculation formula is:

[0060]

[0061] in, Indicates Auxiliary dataset samples for batches of loss, represents the discriminator, represents the underlying alternative model, Indicates Batches of auxiliary dataset samples.

[0062] The gradient of the underlying surrogate model is calculated based on the above loss results and the underlying surrogate model is updated.

[0063] In the second stage of training, the first intermediate layer representation of the client bottom model is input into the discriminator, which determines whether the input intermediate layer representation is the first alternative intermediate layer representation or the first intermediate layer representation of the client bottom model. According to the judgment result of the second stage discriminator and the judgment result of the first stage discriminator, the joint loss of the auxiliary dataset sample and the first intermediate layer representation of the client bottom model is calculated, and the calculation formula is:

[0064]

[0065] in, Indicates Batch auxiliary dataset sample Pass The first intermediate layer representation of the underlying model of the client collected in batches The combined loss represents the discriminator, Indicates The first intermediate layer representation of the underlying model of the client side of the batch collection, represents the underlying alternative model, Indicates Batch of auxiliary dataset samples.

[0066] The gradient of the discriminator is calculated based on the above loss results and the discriminator is updated.

[0067] (2-3) Repeat step (2-2) until the first intermediate layer representation of all client underlying models is traversed, completing one round of training.

[0068] (2-4) Continue to repeat steps (2-2) to (2-3) for several rounds and retain the final underlying substitution model.

[0069] S3, uses the first intermediate layer representation of the collected client underlying model to train the clusterer, obtains the mapping from clustering categories to true categories through the clustering results and true labels of the auxiliary dataset, and uses the cluster center of the target attack class as the anchor point.

[0070] In a specific implementation of the present invention, step S3 may be implemented as follows:

[0071] (3-1) Input the first intermediate layer representation of the client bottom model collected in step S2 into the server intermediate model, obtain the second intermediate layer representation of the server intermediate model, and use the second intermediate layer representation to train a clusterer. The trained clusterer can classify the second intermediate layer representation. The classification result is the category to which the original image sample corresponding to the second intermediate layer representation belongs.

[0072] (3-2) The auxiliary dataset is input into the trained underlying substitute model to obtain the first substitute intermediate layer representation of the underlying substitute model, and then the intermediate model is used to generate the second substitute intermediate layer with the first substitute intermediate layer representation as input, and the trained clusterer is used to obtain the clustering label of the second substitute intermediate layer representation, which is the clustering label corresponding to the auxiliary dataset sample.

[0073] (3-3) Based on the Hungarian algorithm, the maximum match is calculated to obtain the mapping relationship between the clustering labels of the auxiliary dataset samples and the true labels.

[0074] (3-4) Based on the mapping relationship obtained in step (3-3), determine the cluster center of the cluster corresponding to the backdoor attack target category and retain it as an anchor point for subsequent use.

[0075] Assuming that the backdoor attack target category is A, the cluster label A' corresponding to the real label A is obtained according to the mapping relationship, and the cluster center of the cluster label A' is taken as the anchor point. The backdoor attack target category A means that the attacker expects to implant an image trigger into a certain input image so that the original model classifies the image implanted with the backdoor into category A. The image trigger is to inject a pixel block or add an image filter, or other forms that can be thought of by those skilled in the art.

[0076] S4, based on statistical ideas, obtain the intermediate layer representation trigger corresponding to the image trigger.

[0077] In a specific implementation of the present invention, Figure 3 As shown, step S4 can be implemented as follows:

[0078] (4-1) Add image triggers to all auxiliary dataset samples to obtain auxiliary datasets with triggers.

[0079] (4-2) Input the auxiliary dataset with triggers in step (4-1) into the trained underlying alternative model to obtain its first alternative intermediate layer representation.

[0080] (4-3) Calculate the difference between the first alternative intermediate layer representation obtained in step (3-2) and the first alternative intermediate layer representation obtained in step (4-2) corresponding to the same auxiliary data set sample at each intermediate layer representation bit, and add up the differences of all samples at the same bit. The calculation formula is:

[0081]

[0082] in, Represents auxiliary dataset The middle layer before and after adding the image trigger shows the difference in each bit. Represents auxiliary dataset The size of represents the underlying alternative model, Indicates Auxiliary dataset samples, Indicates A sample of an auxiliary dataset with triggers.

[0083] (4-4) Calculate the mean of the first alternative intermediate layer representation of the auxiliary dataset sample obtained in step (4-2) at each intermediate layer representation position. The calculation formula is:

[0084]

[0085] in, Represents auxiliary dataset After adding the trigger, the middle layer represents the mean value of each bit. represents the size of the auxiliary dataset X, represents the underlying alternative model, Indicates A sample of an auxiliary dataset with triggers.

[0086] (4-5) Select the bits with the largest difference in step (4-3) and mark them as the positions of the intermediate layer representation triggers. Mark the mean of the corresponding positions in step (4-4) as the value of the intermediate layer representation trigger. Combine the position and value information to obtain the intermediate layer representation trigger.

[0087] S5, based on the backdoor attack method of replacing target class samples with anchors expressed in the form of intermediate layers, injects backdoors into the server-side intermediate model and trains it to modify the server-side intermediate model.

[0088] In a specific implementation of the present invention, step S5 may be implemented as follows:

[0089] (5-1) Set the number of backdoor injection rounds for the server-side intermediate model and the number of backdoor injection batches included in each round.

[0090] (5-2) In each training batch, a certain number of first intermediate layer representations of the client bottom model collected in step S2 are selected, and the server-side intermediate model is trained for backdoor injection in combination with the intermediate layer representation trigger to update the intermediate model. The backdoor injection training specifically includes a two-stage training process:

[0091] During the first stage of training, a copy of the server-side intermediate model is retained, recorded as the copy model, and an intermediate layer representation trigger is added to the first intermediate layer representation of the client-side underlying model collected in step S2, that is, the first intermediate layer representation of the client-side underlying model collected in step S2 is modified using the intermediate layer representation trigger. When modifying, the corresponding position in the first intermediate layer representation is modified to the corresponding value in the intermediate layer representation trigger to obtain the first intermediate layer representation with the trigger; the loss between the second intermediate layer representation generated after the first intermediate layer representation with the trigger is input into the server-side intermediate model and the anchor point is calculated. , calculate the corresponding gradient according to the loss result and update the intermediate model.

[0092] In this embodiment, the loss The calculation formula is:

[0093]

[0094] in, The first intermediate layer with triggers represents the loss of the anchor point after inputting the server-side intermediate model. represents the mean square error, Represents the server-side intermediate model, Represents the first intermediate layer representation with triggers, Indicates an anchor point.

[0095] During the second stage of training, the first intermediate layer representation of the client bottom model collected in step S2 without triggers is input into the updated intermediate model and the replica model in the first stage respectively, and two second intermediate layer representations are obtained, and the loss between the two second intermediate layer representations is calculated. , calculate the corresponding gradient according to the loss result and update the intermediate model.

[0096] In this embodiment, the loss The calculation formula is:

[0097]

[0098] in, The first intermediate layer without triggers represents the loss between the output of the server-side intermediate model and the output of the replica model. represents the mean square error, Represents the server-side intermediate model, represents the first intermediate layer representation without triggers, Represents a copy of the intermediate model on the server side, Represents the first intermediate layer representation with triggers.

[0099] (5-3) Repeat step (5-2) until the first intermediate layer representation of all client underlying models is traversed, completing one round of training.

[0100] (5-4) Continue to repeat steps (5-2) to (5-3) for several rounds and retain the final server-side intermediate model.

[0101] S6, using the test samples to detect the backdoor attack success rate of the target model, and determine the backdoor vulnerability of the target model. The higher the backdoor attack success rate, the higher the backdoor vulnerability of the target model.

[0102] During the test, the test sample is implanted with the image trigger corresponding to the trigger represented by the middle layer to determine whether the test sample with the added image trigger is classified as the backdoor attack target category. If so, the backdoor attack is successful, otherwise the backdoor attack fails. The success rate is counted to obtain the backdoor vulnerability analysis results.

[0103] In order to verify the test effect of the present invention, this embodiment conducts experiments on three image datasets: MNIST, F-MNIST and CIFAR-10. The following is an introduction to the above three datasets.

[0104] MNIST: The MNIST database is a handwritten digit database containing 60,000 training images and 10,000 test images in 10 categories.

[0105] F-MNIST: The F-MNIST dataset is a fashion image database containing 60,000 training images and 10,000 test images in 10 categories.

[0106] CIFAR-10: The CIFAR-10 dataset is a small image database containing 50,000 training images and 10,000 test images in 10 categories.

[0107] Experiments were conducted on three different networks, including ResNet50, ResNext50, and VGG16. The following is a description of the three networks:

[0108] ResNet50: A 50-layer convolutional neural network with residual blocks.

[0109] ResNext50: A derivative of ResNet50, except that it divides the channels into multiple groups.

[0110] VGG16: It is a convolutional neural network model designed based on the visual geometry group model. It has a depth of 16 layers and a simpler structure than the previous two.

[0111] Table 1 Experimental results

[0112]

[0113] As shown in Table 1, Baseline is the accuracy of the model under normal conditions, ACC is the accuracy of the unattacked samples when the model is attacked by the backdoor, and ASR is the target category accuracy of the attacked samples. It can be seen that the vulnerability detection method proposed in the present invention can more comprehensively expose the vulnerabilities of the model under the segmentation learning framework, and can implement attack testing without affecting the normal performance of the model.

[0114] In this embodiment, a model backdoor attack vulnerability analysis system for segmentation learning is also provided, which is used to implement the above embodiment. The terms "module", "unit", etc. used below can implement a combination of software and / or hardware for predetermined functions. Although the system described in the following embodiments is preferably implemented in software, it is also possible to implement hardware, or a combination of software and hardware.

[0115] This embodiment provides a model backdoor attack vulnerability analysis system for segmentation learning, including:

[0116] A segmentation learning module is used to segment the image classification model to be subjected to backdoor attack vulnerability analysis into a bottom model, an intermediate model and a top model, wherein the intermediate model is deployed on the server side, and the bottom model and the top model are deployed on the local client side;

[0117] A bottom-layer substitute model training module is used to collect the first intermediate layer representations sent by the client bottom-layer model to the server-side intermediate model during the segmentation learning and training process of the image classification model, and iteratively train the bottom-layer substitute model using the collected first intermediate layer representations and the auxiliary data set;

[0118] An anchor construction module, which is used to train the clusterer using the collected first intermediate layer representation, obtain the mapping relationship from clustering category to real category through the clustering results of the auxiliary data set and the real label, and use the cluster center of the backdoor attack target category as the anchor;

[0119] A trigger setting module, which is used to obtain an intermediate layer representation trigger corresponding to an image trigger based on a statistical idea;

[0120] The image classification model backdoor implantation module is used to replace the target class sample with a backdoor attack method based on the anchor point of the intermediate layer expression form, inject the backdoor into the server-side intermediate model and train it to modify the server-side intermediate model;

[0121] The vulnerability statistics module is used to detect the backdoor attack success rate of the image classification model using test samples and determine the backdoor vulnerability of the image classification model. The higher the backdoor attack success rate, the higher the backdoor vulnerability of the image classification model in segmentation learning.

[0122] For the system embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment, and the implementation methods of the remaining modules will not be repeated here. The system embodiment described above is only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of the present invention. Ordinary technicians in this field can understand and implement it without paying creative work.

[0123] The embodiments of the system of the present invention can be applied to any device with data processing capabilities, and the device with data processing capabilities can be a device or apparatus such as a computer. The system embodiments can be implemented by software, or by hardware or a combination of software and hardware. Taking software implementation as an example, as a device in a logical sense, the corresponding computer program instructions in the non-volatile memory are read into the memory by the processor of any device with data processing capabilities and run.

[0124] Obviously, the above-described embodiments and drawings are only some examples of the present application. For those of ordinary skill in the art, the present application can also be applied to other similar situations based on these drawings without creative work. In addition, it is understandable that, although the work done in this development process may be complicated and lengthy, for those of ordinary skill in the art, certain changes in design, manufacturing or production based on the technical content disclosed in this application are only conventional technical means and should not be regarded as insufficient content disclosed in this application. Without departing from the concept of the present application, several variations and improvements can also be made, which all belong to the scope of protection of the present application. Therefore, the scope of protection of the present application shall be subject to the attached claims.

Claims

1. A model backdoor attack vulnerability analysis method for segmentation learning, characterized in that: The following steps are involved: (1) Split the image classification model to be analyzed for backdoor attack vulnerability into a bottom model, an intermediate model, and a top model, wherein the intermediate model is deployed on the server side, and the bottom model and the top model are deployed on the local client side; (2) Collect the first intermediate layer representations sent by the client-side underlying model to the server-side intermediate model during the segmentation learning and training process of the image classification model, and iteratively train the underlying alternative model using the collected first intermediate layer representations and the auxiliary dataset; (3) Use the collected first intermediate layer representation to train the clusterer, obtain the mapping relationship between cluster categories and real categories through the clustering results of the auxiliary dataset and the real labels, and use the cluster center of the backdoor attack target category as the anchor point; (4) Obtaining the intermediate layer representation trigger corresponding to the image trigger based on statistical thinking; including: (4-1) Add image triggers to all auxiliary dataset samples to obtain auxiliary datasets with triggers; (4-2) inputting the auxiliary dataset with the trigger into the trained bottom-level substitution model to obtain a first substitution intermediate layer representation with the trigger; and, inputting the auxiliary dataset without the trigger into the trained bottom-level substitution model to obtain a first substitution intermediate layer representation without the trigger; (4-3) Calculate the difference between the first alternative intermediate layer representation with trigger and the first alternative intermediate layer representation without trigger corresponding to the same auxiliary data set sample at each intermediate layer representation bit, accumulate the differences of all samples at the same bit, and take the bits with the largest difference accumulation value as the trigger position; (4-4) Calculate the mean of the first alternative intermediate layer representation of the auxiliary data set sample at each intermediate layer representation position, and take the mean of the trigger position as the trigger value; (4-5) Combining the trigger position and the trigger value to obtain the middle layer representation trigger; (5) A backdoor attack method based on the anchor point replacement of the target class sample in the intermediate layer expression form, injecting a backdoor into the server-side intermediate model and training it, and modifying the server-side intermediate model; including: (5-1) Set the number of backdoor injection rounds of the server-side intermediate model and the number of backdoor injection batches included in each round; (5-2) In each training batch, a certain number of first intermediate layer representations collected in step (2) are selected, and combined with the intermediate layer representation triggers, backdoor injection training is performed on the server-side intermediate model to update the intermediate model. The backdoor injection training specifically includes a two-stage training process: Select the first intermediate layer representation of the collection of a training batch; During the first stage of training, a copy of the server-side intermediate model is retained, recorded as the copy model, and an intermediate layer representation trigger is added to the collected first intermediate layer representation to obtain the first intermediate layer representation with the trigger; the loss between the second intermediate layer representation generated after the first intermediate layer representation with the trigger is input into the server-side intermediate model and the anchor point is calculated, and the corresponding gradient is calculated according to the loss result to update the intermediate model; During the second stage of training, the first intermediate layer representations collected without triggers are respectively input into the intermediate model and the replica model updated in the first stage to obtain two second intermediate layer representations, the loss between the two second intermediate layer representations is calculated, the corresponding gradient is calculated according to the loss result, and the intermediate model is updated; (5-3) Iterate multiple training batches to complete a round of training; (5-4) After several rounds of training, the final modified server-side intermediate model is obtained; (6) The test samples are used to detect the backdoor attack success rate of the image classification model and determine the backdoor vulnerability of the image classification model. The higher the backdoor attack success rate, the higher the backdoor vulnerability of the image classification model in segmentation learning.

2. According to claim 1, the model backdoor attack vulnerability analysis method for segmentation learning is characterized in that: The underlying surrogate model is trained in two stages, including: Select a training batch of auxiliary dataset samples and the same number of first intermediate layer representations; In the first stage of training, the auxiliary data set is input into the underlying substitution model, and the output of the underlying substitution model is used as the first substitution intermediate layer representation. Then, the first substitution intermediate layer representation is input into the discriminator, and the discriminator determines whether the input intermediate layer representation is the first substitution intermediate layer representation or the first intermediate layer representation. The loss of the auxiliary data set samples is calculated according to the judgment result of the first stage discriminator, and the gradient of the underlying substitution model is calculated according to the loss result and the underlying substitution model is updated. During the second stage training process, the first intermediate layer representation is input into the discriminator, and the discriminator determines whether the input intermediate layer representation is the first alternative intermediate layer representation or the first intermediate layer representation. According to the judgment result of the second stage discriminator and the judgment result of the first stage discriminator, the joint loss of the auxiliary data set sample and the first intermediate layer representation is calculated, and the gradient of the discriminator is calculated and updated according to the joint loss result. Iterate multiple training batches to complete a round of training, and obtain the underlying replacement model after several rounds of training.

3. The model backdoor attack vulnerability analysis method for segmentation learning according to claim 1 is characterized in that: The underlying replacement model is a backbone network part that is consistent with the image classification model task.

4. The model backdoor attack vulnerability analysis method for segmentation learning according to claim 1 is characterized in that: The obtaining of the mapping relationship between clustering categories and real categories includes: Input the collected first intermediate layer representation into the server-side intermediate model, obtain the second intermediate layer representation of the server-side intermediate model, use the second intermediate layer representation to train a clusterer, the trained clusterer can classify the second intermediate layer representation, and the classification result is the category to which the original image sample corresponding to the second intermediate layer representation belongs; Input the auxiliary data set into the trained underlying surrogate model to obtain the first surrogate intermediate layer representation, then use the intermediate model to take the first surrogate intermediate layer representation as input to generate the second surrogate intermediate layer, and use the trained clusterer to obtain the clustering label of the second surrogate intermediate layer representation as the clustering label of the corresponding auxiliary data set sample; The maximum match is calculated based on the Hungarian algorithm to obtain the mapping relationship between the clustering labels of the auxiliary dataset samples and the true labels.

5. The method for analyzing model backdoor attacks vulnerability for segmentation learning according to claim 4 is characterized in that: The cluster center of the backdoor attack target category is used as an anchor point, including: Obtain the cluster label corresponding to the backdoor attack target category label according to the mapping relationship; The cluster center within the cluster corresponding to the cluster label is used as the anchor point.

6. The method for analyzing model backdoor attack vulnerability for segmentation learning according to claim 1, characterized in that: The backdoor attack success rate calculation method is: The test sample is implanted into the image trigger corresponding to the trigger represented by the middle layer, and it is determined whether the test sample with the added image trigger is classified as the backdoor attack target category. If so, the backdoor attack is successful, otherwise the backdoor attack fails, and the backdoor attack success rate is obtained by statistics.

7. The method for analyzing model backdoor attack vulnerability for segmentation learning according to claim 1, characterized in that: The image trigger is injecting a pixel block or adding an image filter.

8. A model backdoor attack vulnerability analysis system for segmentation learning, characterized in that: include: A segmentation learning module is used to segment the image classification model to be subjected to backdoor attack vulnerability analysis into a bottom model, an intermediate model and a top model, wherein the intermediate model is deployed on the server side, and the bottom model and the top model are deployed on the local client side; A bottom-layer substitute model training module is used to collect the first intermediate layer representations sent by the client bottom-layer model to the server-side intermediate model during the segmentation learning and training process of the image classification model, and iteratively train the bottom-layer substitute model using the collected first intermediate layer representations and the auxiliary data set; An anchor construction module, which is used to train the clusterer using the collected first intermediate layer representation, obtain the mapping relationship from clustering category to real category through the clustering results of the auxiliary data set and the real label, and use the cluster center of the backdoor attack target category as the anchor; A trigger setting module, which is used to obtain an intermediate layer representation trigger corresponding to an image trigger based on a statistical idea; comprising: Based on statistical thinking, the intermediate layer representation trigger corresponding to the image trigger is obtained; including: Add image triggers to all auxiliary dataset samples to obtain auxiliary datasets with triggers; Inputting the auxiliary dataset with the trigger into the trained underlying alternative model to obtain a first alternative intermediate layer representation with the trigger; and inputting the auxiliary dataset without the trigger into the trained underlying alternative model to obtain a first alternative intermediate layer representation without the trigger; Calculate the difference between the first alternative intermediate layer representation with trigger and the first alternative intermediate layer representation without trigger corresponding to the same auxiliary data set sample at each intermediate layer representation bit, accumulate the differences of all samples at the same bit, and take the bits with the largest difference accumulation value as the trigger position; Calculate the mean of the first alternative intermediate layer representation of the auxiliary data set samples at each intermediate layer representation position, and take the mean of the trigger position as the trigger value; The trigger position and the trigger value are combined to obtain the middle layer representing the trigger; The image classification model backdoor implantation module is used to replace the target class sample with a backdoor attack method based on the anchor point of the intermediate layer expression form, inject the backdoor into the server-side intermediate model and train it, and modify the server-side intermediate model; including: Set the number of backdoor injection rounds for the server-side intermediate model and the number of backdoor injection batches included in each round; In each training batch, a certain number of collected first intermediate layer representations are selected, combined with the intermediate layer representation triggers, and backdoor injection training is performed on the server-side intermediate model to update the intermediate model. The backdoor injection training specifically includes a two-stage training process: Select the first intermediate layer representation of the collection of a training batch; During the first stage of training, a copy of the server-side intermediate model is retained, recorded as the copy model, and an intermediate layer representation trigger is added to the collected first intermediate layer representation to obtain the first intermediate layer representation with the trigger; the loss between the second intermediate layer representation generated after the first intermediate layer representation with the trigger is input into the server-side intermediate model and the anchor point is calculated, and the corresponding gradient is calculated according to the loss result to update the intermediate model; During the second stage of training, the first intermediate layer representations collected without triggers are respectively input into the intermediate model and the replica model updated in the first stage to obtain two second intermediate layer representations, the loss between the two second intermediate layer representations is calculated, the corresponding gradient is calculated according to the loss result, and the intermediate model is updated; Iterate multiple training batches to complete a round of training, and after several rounds of training, the final modified server-side intermediate model is obtained; The vulnerability statistics module is used to detect the backdoor attack success rate of the image classification model using test samples and determine the backdoor vulnerability of the image classification model. The higher the backdoor attack success rate, the higher the backdoor vulnerability of the image classification model in segmentation learning.