A multimodal deep learning model vulnerability analysis method and system

By generating multi-modal adversarial samples and analyzing the robustness of multi-modal deep learning models, the problem of inability to effectively detect the vulnerability of multi-modal models in the existing technology is solved, and a more efficient attack effect is achieved.

CN114722812BActive Publication Date: 2024-10-29SHANGCHAN (ZHEJIANG) TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210367723.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-02
Publication Date
2024-10-29
Estimated Expiration
2042-04-02

AI Technical Summary

Technical Problem

Existing technologies cannot effectively analyze and detect the robustness of multi-modal deep learning models, and adversarial attack methods mainly target a single modality and cannot act on multiple modalities at the same time, resulting in unreliable attack effects on multi-modal models.

Method used

By acquiring multi-modal data sets, training single-modal local models, generating adversarial samples of different modalities, and using gradient descent methods and gradient approximation sampling methods to generate multi-modal adversarial samples, testing their attack success rates to analyze the vulnerability of the model sex.

Benefits of technology

It realizes the analysis of the overall vulnerability of multi-modal deep learning models, makes up for the continuity difference between natural language text modalities and other modalities, improves the performance of adversarial sample generation, and achieves better results under the same adversarial perturbation intensity. attack effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114722812B_ABST
    Figure CN114722812B_ABST
Patent Text Reader

Abstract

The present invention proposes a method and system for analyzing the vulnerability of a multimodal deep learning model, which belongs to the field of adversarial attacks and model robustness analysis. The method tests the robustness of a target model by generating a series of white-box adversarial samples, and the main steps include: first obtaining a target multimodal deep learning model and a training data set used by it; extracting visual modal features, text modal features, and audio modal features in the data set respectively; using the extracted data set features to train a single-modal local model respectively; obtaining adversarial sample generation weights of different modalities by testing the training effect of the single-modal local model; iteratively generating adversarial samples: using a PGD-based gradient descent method to generate perturbations for visual and audio modalities, and using a gradient approximation optimized synonym replacement method to generate perturbations for natural language text modalities; verifying the attack success rate of the model through a series of generated multimodal adversarial samples, and obtaining the vulnerability analysis results of the target model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of anti-attack and model robustness analysis, and in particular to a method and system for analyzing the vulnerability of a multimodal deep learning model. Background Art

[0002] With the continuous development of deep learning related technologies and the increasing number of its application scenarios in academia and industry in recent years, the demand for simultaneous analysis of multiple modal data has begun to emerge, which has promoted the development of multimodal machine learning. Multimodal machine learning is mainly used to find the relationship between multiple modalities and use the information of multiple modalities to make decisions at the same time. The most common ones are natural language modalities, sound signal modalities, and visual signal modalities. In the past decade, multimodal machine learning has fully entered the era of deep learning and has been widely used in tasks and scenarios such as multimedia file processing, sentiment analysis, and recommendation systems. At the same time, related research on the analysis of neural network robustness shows that any existing network model, including multimodal deep learning models, can be deceived. Adversarial attacks can effectively affect the output of the model by applying imperceptible perturbations to the input data, thereby achieving the attacker's attack goal. At present, this attack mode has been well studied in fields such as computer vision and natural language processing. In the image modality, existing research results can add noise to the input image to make the image classification model make wrong decisions; in the text modality, by inserting and replacing words and characters in the text, the natural language translation model or question-answering system can be induced to output wrong results. In real-life mission scenarios, this attack allows attackers to bypass the review system to post malicious comments on social media, or use real adversarial samples to interfere with the normal operation of the autonomous driving system. This adversarial attack not only reflects the vulnerability of deep learning models, but also hinders the application and development of artificial intelligence to a certain extent.

[0003] Although existing attack methods targeting individual modalities have become increasingly mature, single-modal attack methods cannot act on all input information of multiple modalities at the same time, and their attack effects on multimodal deep learning models are unreliable. Compared with single-modal models, multimodal models are more difficult to experiment with, and the connections between different modalities lack explainability, few researchers have paid attention to the robustness analysis and adversarial attack methods for multimodal models, resulting in a research gap in related fields. Some existing methods only use single-modal adversarial sample generation methods to test multimodal deep learning models, ignoring the associations and robustness differences between different modalities, which has great limitations. Therefore, a detection and analysis method that can generate multi-modal adversarial samples at the same time and detect the overall robustness of multimodal models is needed.

[0004] Multimodal deep learning models are bound to receive more research and application in the future. Therefore, it is necessary to study the vulnerability and adversarial attacks of multimodal models, which will help future research on methods to enhance the robustness of multimodal deep learning models and defend against adversarial attacks, and promote the application and development of related technologies. Summary of the invention

[0005] In view of the lack of adversarial sample generation and robustness analysis methods for multimodal deep learning models in existing research, this paper proposes an analysis method and system for the vulnerability of multimodal machine learning models. The specific technical solution is:

[0006] A method for analyzing the vulnerability of a multimodal deep learning model includes the following steps:

[0007] (1) Obtain the target model M and its training datasets of three modalities: vision, audio, and text;

[0008] (2) Preprocess and extract features of the multimodal datasets to obtain visual modal features, acoustic modal features, and text modal features;

[0009] (3) According to the visual modal features, acoustic modal features, and text modal features obtained in step (2), the corresponding unimodal local models are trained respectively, and the adversarial sample generation weights under different modalities are determined according to the learning effect of the unimodal local model;

[0010] (4) Generate a series of adversarial samples in different modalities based on the adversarial sample generation weights of each modality and the gradient information of the target model loss function relative to the input of each modality;

[0011] (5) Test the attack success rate of adversarial samples and obtain the vulnerability analysis results of the target model.

[0012] Furthermore, in the process of analyzing the robustness of the model, it is necessary to obtain the complete model information and data set of the target model, that is, the target model M in step (1) and the training data set D of the three modalities. V ,D A ,D T The target model M is generally a multimodal classification model, such as a sentiment analysis model or a video classification model. V ,D A ,D T They respectively contain images, audio, and extracted natural language text data from the same video.

[0013] Furthermore, in step (2), in order to facilitate the subsequent training of the single-modal local model, the data sets are preprocessed in the three modalities respectively, including the following steps:

[0014] For the visual modality dataset, we first extract key frames from the video, resize them to a uniform size, and then extract visual features using a pre-trained model;

[0015] For the text modality dataset, the text is first segmented, and the token sequence obtained after segmentation is converted into word vectors. The word vector features are extracted through the pre-trained BERT model as text modality features.

[0016] For the audio modal dataset, we first perform denoising and then obtain a series of frame signals containing stable audio signals through framing and windowing operations. Then, we convert the frame signals from time domain to frequency domain through fast Fourier transform and constant Q transform respectively, and extract the MFCC features and CQCC features of the frame signals, which are then concatenated as acoustic modal features.

[0017] Furthermore, step (3) tests the importance of a single modality relative to the task decision of the target model. Its goal is to estimate the robustness of the target model in the corresponding modality through the learning effect of the single modality model and determine the weight in the subsequent adversarial sample generation process, including:

[0018] (3-1) The visual modal features, acoustic modal features and text modal features obtained in step (2) are divided into training set, validation set and test set. The local model of the corresponding modality is trained according to the training set and validation set under different modalities, which is recorded as the visual modal local model C. V , audio modality local model C A 、Text modal local model C T ;

[0019] (3-2) Test C on the test set separately V ,C A ,C T The accuracy rate;

[0020] (3-3) Determine the adversarial sample generation weights for different modalities based on the local model accuracy under each modality.

[0021] Furthermore, step (4) iteratively generates a series of multimodal adversarial samples, whose optimization goal is:

[0022]

[0023] Among them, S t is the adversarial sample generated after t iterations, α is the strength of the perturbation at each iteration, sign is the sign function, θ is the target model, and L is the loss function of the target model.

[0024] Step (4) comprises:

[0025] (4-1) Select the input video S to generate the adversarial sample, and obtain the three modal sample data of video S, including visual modality Audio Mode and text modal Initial time t = 0;

[0026] (4-2) Visual modality samples Obtain the perturbed visual modality samples through the gradient descent method

[0027] Text Modal Sample Randomly select a word, obtain its synonyms through gradient approximate sampling, and replace it to obtain the perturbed text modal sample

[0028] Audio modality samples Obtain the perturbed audio modal sample by gradient descent method

[0029] (4-3) Repeat step (4-2) until the maximum number of iterations is reached to obtain a series of adversarial samples.

[0030] The present invention also proposes a multimodal deep learning model vulnerability analysis system for implementing the above analysis method. The analysis system comprises the following modules:

[0031] Multimodal dataset preprocessing module: used to obtain the training dataset of the target model M and its three modalities of vision, audio and text, preprocess the training dataset and extract the corresponding features;

[0032] Single-modal local model module: used to train a single-modal local model through features extracted from the data set and test its learning effect; through the learning effect of local models of different modalities, the weights of different modalities in the process of generating adversarial samples are obtained;

[0033] Visual adversarial sample generation module: used to apply adversarial perturbations to visual samples through the projected gradient descent method;

[0034] Text adversarial sample generation module: used to apply adversarial perturbations to text samples through a gradient-optimized sampling method.

[0035] Audio adversarial sample generation module: used to apply adversarial perturbations to audio samples through projected gradient descent method;

[0036] Target model vulnerability verification module: used to obtain the vulnerability analysis results of the target model by testing the success rate of adversarial samples' attacks on the target model.

[0037] Compared with the prior art, the present invention has the following beneficial effects:

[0038] (1) The present invention comprehensively considers the robustness of the three modes of the multimodal deep learning model and can analyze the overall vulnerability of the model.

[0039] (2) The present invention realizes the simultaneous generation of adversarial samples in multiple modalities, which makes up for the continuity difference between the natural language text modality and other modalities and improves the performance of generating adversarial samples.

[0040] (3) The present invention realizes a more efficient attack through weight allocation. Compared with other adversarial sample generation methods, it can achieve better attack effects under the same adversarial perturbation intensity. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 This is the architecture diagram of the multimodal model vulnerability analysis system;

[0042] Figure 2 Flowchart of the preprocessing and feature extraction process for multimodal datasets;

[0043] Figure 3 Flowchart for generating white-box adversarial samples;

[0044] Figure 4 Flowchart of the multimodal model vulnerability analysis system. DETAILED DESCRIPTION

[0045] The present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be pointed out that the embodiments described below are intended to facilitate the understanding of the present invention and do not have any limiting effect on the present invention.

[0046] In one embodiment provided by the present invention, Figure 1 The figure shows the architecture diagram of the multimodal model vulnerability analysis system of the present invention, which mainly includes six modules: multimodal data set preprocessing module, unimodal local model module, visual adversarial sample generation module, audio adversarial sample generation module, text adversarial sample generation module and target model vulnerability verification module. The following are the six modules introduced respectively:

[0047] 1. Multimodal dataset preprocessing module

[0048] The main purpose of this module is to extract features from the dataset for local model training. Its main process is as follows: Figure 2 shown.

[0049] refer to Figure 2In (a), in the visual mode, since it is impossible to process all frames in the entire video, the key frames in the video are first extracted to basically ensure that important information about the image in the video can be obtained, and then only the key frames are processed. If there is no person-related content in the video dataset, the feature vector of the key frame is directly extracted through the Resnet pre-trained model as the visual data feature; if the target model mainly analyzes the person content in the video, the face feature can be extracted as the video feature. The main steps are:

[0050] (a1.1) Use face capture tools such as MTCNN or FaceNet to extract faces in each key frame;

[0051] (a1.2) cropping the facial part identified in step (a1.1) to a specified size;

[0052] (a1.3) Use the OpenFace tool to extract features such as facial landmarks, facial action units, head orientation, and eye gaze direction as visual modality features.

[0053] refer to Figure 2 In (b), in the audio mode, denoising is first performed according to the requirements to retain the key information in the audio data. In particular, for the target model of the sentiment analysis task, noise is prevented from interfering with the voice of the person. Then, the feature vector is obtained by calculating the acoustic features, where the acoustic features mainly include MFCC (Mel-frequency cepstral coefficients) and CQCC (Constant Q cepstral coefficients). The calculation process is as follows:

[0054] (b1.1) Pre-emphasis operation: A high-pass filter is used to process the audio signal to compensate for the loss of high-frequency signals in the audio signal caused by the medium. The formula is y(n)=x(n)-a·x(n-1), where x(n) is the audio signal at time n, a is the pre-emphasis coefficient, and y(n) is the audio signal after pre-emphasis processing at time n.

[0055] (b1.2) Framing operation: Every N sampling points in the audio are combined into a frame. To ensure the stability of the signal within the frame, the length of a frame cannot exceed the length of a phoneme, that is, 50 milliseconds to 200 milliseconds; at the same time, in order to include enough vibration cycles, the length of a frame should be greater than 20 milliseconds. The purpose of framing is to intercept a small section of relatively stable signal to facilitate conversion to spectrum for processing.

[0056] (b1.3) Windowing operation: Multiply each frame of the signal obtained in the previous step by the window function, generally using a Hamming window for windowing operation. The purpose of the windowing operation is to prevent spectrum leakage caused by non-periodic truncation of the signal.

[0057] (b1.4) FFT (Fast Fourier Transform): For the extraction of MFCC features, FFT is used to transfer the signal to the frequency domain, and the formula for its amplitude spectrum is:

[0058]

[0059] The formula for the power spectrum is:

[0060]

[0061] Among them, s i (n) is the time domain signal of the i-th frame, S i (k) is the amplitude spectrum of the i-th frame signal, N is the number of fast Fourier transform points; P i (k) is the power spectrum of the i-th frame signal.

[0062] (b1.5) CQT (Constant Q Transform): For the extraction of CQCC features, CQT transform is used, and the formula of its amplitude spectrum is:

[0063]

[0064] The formula for the power spectrum is:

[0065]

[0066] Among them, s i (n) is the time domain signal of the i-th frame, is the CQT transform amplitude spectrum of the i-th frame signal, Q is the constant factor in the CQT transform, N k is the window length that varies with frequency k; is the power spectrum of CQT transformation. The advantage of CQT transformation is that it avoids the disadvantage of uniform time-frequency resolution and has different bandwidths for high-frequency and low-frequency signals.

[0067] (b1.6) Mel filter: The spectrum signal obtained by fast Fourier transform is filtered using a Mel scale filter, the purpose of which is to simplify the amplitude of the frequency domain so that each frequency band is represented by one value and to highlight the resonance peaks of the original audio.

[0068] (b1.7) Logarithmic power operation: The spectrum signal after constant Q transformation and the spectrum signal after FFT transformation through Mel filtering need to undergo logarithmic power operation, that is, taking the logarithm of their power.

[0069] (b1.8) Uniform resampling: The signal obtained by constant Q transformation after logarithmic power operation is uniformly sampled.

[0070] (b1.9) DCT (Discrete Cosine Transform): The power signals of the two frequency domain signals are subjected to discrete cosine transform. The MFCC features are obtained through fast Fourier transform and discrete cosine function, while the CQCC features are obtained through constant Q transform and discrete cosine transform.

[0071] In order to improve the temporal continuity between frames from which features are extracted, the feature dimension of the previous and next frame information can be increased by difference. Commonly used methods include first-order difference and second-order difference. The final acoustic modal feature can be obtained by concatenating the two extracted features.

[0072] refer to Figure 2 In (c), in the natural text modality, the input text is first segmented into token sequences using the corresponding token segmenter according to the language of the text; secondly, the text data is converted to the feature space based on the pre-trained token embedding; a maximum sequence length is defined to facilitate padding all samples to the same sequence length; finally, the token embedding sequence is added to the position embedding and segment embedding, and input into the pre-trained BERT model to obtain the final text modality features.

[0073] 2. Single-modal local model module

[0074] The main purpose of this module is to train the unimodal local model using the features extracted from the training set and test the impact of different modal datasets on the decision-making of the multimodal model, so as to determine the weight of each iteration in the subsequent module to generate adversarial samples. Since the data of the three modalities are preprocessed and features are extracted in the multimodal dataset preprocessing module, the local model can use a neural network based on a fully connected layer.

[0075] Use a 6:2:2 ratio to divide the training set, validation set, and test set, and train the local model C on the training set and validation set of the multimodal dataset respectively. V ,C A ,C T , and test the accuracy of the results on the test set. Because the target model learns more noise and has poor robustness in the modality with lower accuracy, a lower adversarial perturbation weight is assigned to the model with higher accuracy. The specific weight allocation formula is as follows:

[0076] w i =softmax(1-acc i )

[0077] Among them, acc i is the prediction accuracy of the local model corresponding to modality i, w i is the disturbance intensity weight corresponding to modality i, and i=V represents visual modality, i=T represents text modality, and i=A represents audio modality.

[0078] 3. Visual adversarial sample generation module

[0079] like Figure 3 Shown is a schematic diagram of the adversarial sample generation process of three modalities.

[0080] The main function of the visual adversarial sample generation module is to generate visual adversarial samples using the gradient information of the target model. It is mainly based on the adversarial sample generation method PGD (projected gradient descent) and generates multiple adversarial samples through several iterations. The main steps in each iteration are as follows:

[0081] (1) Input into the target model, obtain the model output, and calculate the loss function Among them, θ is the parameter of the target model, are the visual modality samples, audio modality samples, and text modality samples corresponding to the video S to be generated as adversarial samples; (2) back-propagating the target model loss to obtain the gradient of the target model loss function relative to the visual modality input

[0082] (3) Based on Get adversarial samples, where w V is the perturbation intensity weight of the visual modality, a is the strength of the perturbation at each iteration, and sign is the sign function;

[0083] (4) Limit the overall disturbance amplitude, Among them, P V is the global maximum perturbation amplitude of the visual modality.

[0084] 4. Text adversarial sample generation module

[0085] Compared with the continuous visual and audio modalities, the text modality has a certain degree of difficulty in generating adversarial samples due to its discontinuity and non-differentiability. In order to cooperate with the generation of adversarial samples of the other two modalities, this module uses the gradient approximate sampling method to generate text adversarial samples by synonym replacement. The main steps of each iteration are as follows:

[0086] (1) Input into the target model, obtain the model output, and calculate the loss function Among them, θ is the parameter of the target model, are respectively the visual modality samples, audio modality samples, and text modality samples corresponding to the video S for which the adversarial sample is to be generated;

[0087] (2) Back-propagate the model loss to obtain the gradient of the target model loss function relative to the text modal input

[0088] (3) Randomly select some words in the input text sequence and First, use the language model to select the top n synonym candidate sets of the word to be replaced Where x belongs to the source vocabulary V.

[0089] (4) For the selected word Its replacement synonyms are Among them, csim is the cosine similarity, e is the word embedding function, and w T is the perturbation intensity weight of the text modality.

[0090] (5) Perturb all selected words to obtain text adversarial samples.

[0091] 5. Audio adversarial sample generation module

[0092] The generation of audio adversarial samples is similar to that of visual modalities, but the adversarial perturbations need to be applied to spectral features rather than raw data. The main steps of each iteration are as follows:

[0093] (1) Input into the target model, obtain the model output, and calculate the loss function Among them, θ is the parameter of the target model, are respectively the visual modality samples, audio modality samples, and text modality samples corresponding to the video S for which the adversarial sample is to be generated;

[0094] (2) Back-propagate the model loss to obtain the gradient of the target model loss function relative to the audio modal spectral characteristics

[0095] (3) Based on Apply disturbance to the frequency domain signal, where w A is the disturbance intensity weight of the audio mode, yes The frequency domain form of

[0096] (4) Limit the overall disturbance amplitude, Among them, P A is the global maximum disturbance amplitude of the audio mode.

[0097] (5) Convert the spectral features back to the time domain to obtain audio adversarial samples.

[0098] 6. Target model vulnerability detection module

[0099] This module uses a series of adversarial sample data sets generated by the adversarial sample generation module of the three modalities mentioned above to test the accuracy of the target model. By comparing the accuracy of the target model with the accuracy in the clean data set as the perturbation degree gradually increases, the vulnerability of the target model and its robustness against noise attacks are analyzed.

[0100] like Figure 4 The flowchart of vulnerability analysis is shown below. When using the vulnerability analysis system of the present invention, the following steps are mainly performed:

[0101] (1) The user must first input the target model M and the multimodal dataset D used to train M. V ,D A ,D T , including three modalities: visual, audio and text;

[0102] (2) Extract dataset features from the three modalities, including calculating acoustic modality features such as MFCC and CQCC in the audio modality, and extracting visual modality features and text modality features using pre-trained models of computer vision and natural language processing.

[0103] (3) Split the dataset and use the extracted features to train a unimodal local model C V ,C A ,C T ;

[0104] (4) By testing the training effect of the single-modal model, the weight of each modality in the subsequent generation of adversarial samples is obtained;

[0105] (4) Generate a series of white-box adversarial samples based on the gradient of the target model loss function relative to the input sample. In the visual and audio modalities, PGD-based adversarial samples are used to generate adversarial samples. In the natural language modality, several positions are randomly selected and replaced with synonyms that best match the model gradient in the word vector space.

[0106] (5) Finally, the accuracy of the target model on the adversarial samples generated above is tested to analyze the vulnerability of the target model. For example, those skilled in the art may classify the vulnerability levels according to the accuracy, or adopt other reasonable evaluation criteria.

[0107] The above examples are only specific embodiments of the present invention. Obviously, the present invention is not limited to the above examples, and many variations are possible. All variations that can be directly derived or associated with the contents disclosed by a person skilled in the art should be considered as the protection scope of the present invention.

Claims

1. A method for analyzing the vulnerability of a multimodal deep learning model, characterized in that: The following steps are involved: (1) Obtain the target model M and its training datasets of three modalities: vision, audio, and text; (2) Preprocess and extract features of the multimodal datasets to obtain visual modal features, acoustic modal features, and text modal features; (3) According to the visual modal features, acoustic modal features, and text modal features obtained in step (2), the corresponding unimodal local models are trained respectively, and the adversarial sample generation weights under different modalities are determined according to the learning effect of the unimodal local model; The step (3) comprises: (3-1) The visual modal features, acoustic modal features and text modal features obtained in step (2) are divided into training set, validation set and test set. The local model of the corresponding modality is trained according to the training set and validation set under different modalities, which is recorded as the visual modal local model C. V , audio modality local model C A 、Text modal local model C T ; (3-2) Test C on the test set separately V ,C A ,C T The accuracy rate; (3-3) Determine the weights for generating adversarial samples of different modalities based on the accuracy of the local model under each modality; (4) Generate a series of adversarial samples in different modalities based on the adversarial sample generation weights of each modality and the gradient information of the target model loss function relative to the input of each modality; The step (4) comprises: (4-1) Select the input video S to generate the adversarial sample, and obtain the three modal sample data of video S, including visual modality Audio Mode and text modal Initial time t = 0; (4-2) Visual modality samples Obtain the perturbed visual modality samples through the gradient descent method Text Modal Sample Randomly select a word, obtain its synonyms through gradient approximate sampling, and replace it to obtain the perturbed text modal sample Audio modality samples Obtain the perturbed audio modal sample by gradient descent method The step (4-2) is specifically: (4-2-1) Input into the target model, obtain the model output, and calculate the loss function Among them, θ is the parameter of the target model; (4-2-2) Back-propagate the target model loss to obtain the gradient of the target model loss function relative to the visual modality input The gradient of the target model loss function with respect to the audio modality spectral features and the gradient of the target model loss function with respect to the text modality input For the visual and audio modalities, update the samples according to the gradient: Among them, w V is the perturbation intensity weight of the visual modality, w A is the disturbance intensity weight of the audio mode, α is the intensity of each iterative disturbance, sign is the sign function, yes The frequency domain form of Convert back to the time domain to get the audio adversarial sample For the text mode, randomly select some words in the input text sequence, and for the i-th word selected First, use the language model to select the top n synonym candidate sets of the word to be replaced Where x belongs to the source word table V; update the sample according to the gradient and synonym candidate set: Among them, csim is the cosine similarity, e is the word embedding function, and w T is the perturbation intensity weight of the text modality; all selected words are perturbed to obtain text adversarial samples; (4-3) Repeat step (4-2) until the maximum number of iterations is reached to obtain a series of adversarial samples; (5) Test the attack success rate of adversarial samples and obtain the vulnerability analysis results of the target model.

2. The method for analyzing the vulnerability of a multimodal deep learning model according to claim 1, characterized in that: The step (2) comprises: For the visual modality dataset, we first extract key frames from the video, resize them to a uniform size, and then extract visual features using a pre-trained model; For the text modality dataset, we first perform word segmentation on the text and convert the token sequence obtained after word segmentation into word vectors. We then use the pre-trained BERT model to extract word vector features as text modality features. For the audio modal dataset, we first perform denoising and then obtain a series of frame signals containing stable audio signals through framing and windowing operations. Then, we convert the frame signals from time domain to frequency domain through fast Fourier transform and constant Q transform respectively, and extract the MFCC features and CQCC features of the frame signals, which are then concatenated as acoustic modal features.

3. The method for analyzing the vulnerability of a multimodal deep learning model according to claim 2, characterized in that: If the main content of the visual modality dataset is people, the key frames are extracted and adjusted to a uniform size, and then the face recognition system is used to capture the face, which is cropped to obtain the face image, and the facial landmarks, facial action units and facial orientation features are used as visual modality features. If the main content of the visual modality dataset is not people, the key frames are extracted and adjusted to a uniform size, and then the ResNet pre-trained model is directly used to extract the visual modality features.

4. The method for analyzing the vulnerability of a multimodal deep learning model according to claim 2, characterized in that: The method for obtaining acoustic modal features is: Preprocessing: pre-emphasize the audio data, and divide the processed audio into frames and add windows to obtain preprocessed audio data; Branch processing: Perform fast Fourier transform on the preprocessed audio data, filter and perform logarithmic power operation on the data after fast Fourier transform; at the same time of fast Fourier transform, perform constant Q transform on the preprocessed audio data, perform logarithmic power operation on the data after constant Q transform and uniformly resample; The power signals of the two frequency domain signals obtained after branch processing are discrete cosine transformed to obtain MFCC features and CQCC features respectively, which are concatenated as acoustic modal features.

5. A multimodal deep learning model vulnerability analysis system, used to implement the analysis method described in claim 1, characterized in that: The analysis system comprises the following modules: Multimodal dataset preprocessing module: used to obtain the training dataset of the target model M and its three modalities of vision, audio and text, preprocess the training dataset and extract the corresponding features; Single-modal local model module: used to train a single-modal local model through the features extracted from the data set and test its learning effect; the weights of different modalities in the process of generating adversarial samples are obtained through the learning effects of local models of different modalities; specifically: the visual modal features, acoustic modal features and text modal features extracted from the data set are divided into training sets, validation sets and test sets, and the local models of the corresponding modalities are trained according to the training sets and validation sets under different modalities, which are recorded as visual modal local models C V , audio modality local model C A 、Text modal local model C T ; Test C on the test set V ,C A ,C T According to the accuracy of the local model under each modality, the weights of adversarial sample generation of different modalities are determined; Visual adversarial sample generation module: used to apply adversarial perturbations to visual samples through the projected gradient descent method; specifically: Input into the target model, obtain the model output, and calculate the loss function Among them, θ is the parameter of the target model, are the visual modality samples, audio modality samples, and text modality samples corresponding to the video S to generate the adversarial sample; the target model loss is back-propagated to obtain the gradient of the target model loss function relative to the visual modality input according to Get visual adversarial samples, where w V is the perturbation intensity weight of the visual modality, α is the strength of the perturbation at each iteration, and sign is the sign function; Text adversarial sample generation module: used to apply adversarial perturbations to text samples through a sampling method based on gradient optimization; specifically: Input into the target model, obtain the model output, and calculate the loss function Back-propagate the target model loss to obtain the gradient of the target model loss function relative to the text modal input Randomly select some words in the input text sequence, and for the i-th word selected First, use the language model to select the top n synonym candidate sets of the word to be replaced Where x belongs to the source word list V; for the selected word Its replacement synonyms are Among them, csim is the cosine similarity, e is the word embedding function, and w T is the perturbation intensity weight of the text modality; all selected words are perturbed to obtain text adversarial samples; Audio adversarial sample generation module: used to apply adversarial perturbations to audio samples through the projected gradient descent method; specifically: Input into the target model, obtain the model output, and calculate the loss function Back-propagate the model loss to obtain the gradient of the target model loss function relative to the audio modality spectrum characteristics according to Apply disturbance to the frequency domain signal, where w A is the disturbance intensity weight of the audio mode, yes The frequency domain form of Convert back to time domain to get audio adversarial samples Target model vulnerability verification module: used to obtain the vulnerability analysis results of the target model by testing the success rate of adversarial samples' attacks on the target model.

Citation Information

Patent Citations

  • Emotion distribution learning method based on multi-modal information

    CN112418166A

  • Method and device for evaluating target detection model

    CN113222074A

  • Multimodal false information detection model based on confrontation

    CN113239926A