A multimodal fake news detection method and system based on domain adaptation
Through a multi-modal false news detection method based on domain adaptation, combined with soft attention and multi-head mechanisms, it solves the heterogeneity, semantic fusion and cross-domain problems in multi-modal false news detection, and achieves detection in different fields and types. Efficient detection performance in news improves the accuracy and generalization ability of false news detection.
Patent Information
- Application Number
- CN202411103543.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-13
- Publication Date
- 2024-10-22
- Estimated Expiration
- 2044-08-13
AI Technical Summary
Existing multi-modal fake news detection faces heterogeneity, semantic fusion and cross-domain problems, making it difficult to maintain efficient detection performance in different fields and types of news.
A multi-modal fake news detection method based on domain adaptation is adopted to fuse text and image features through a single-modal feature extraction module, multi-head feature fusion, domain adaptor and fake news classifier, combined with soft attention mechanism and multi-head mechanism. , generate multi-dimensional and multi-modal feature vectors, and adjust weights through domain vectors to achieve cross-domain generalization capabilities.
It improves the accuracy and generalization ability of false news detection, maintains efficient detection performance in different fields and types of news, reduces the spread of false information, and protects the public's right to know and social stability.
Smart Images

Figure CN118626996B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the cross-technical field of natural language processing and computer vision, and in particular to a multimodal false news detection method and system based on domain adaptation. Background Art
[0002] Multimodal fake news contains information in multiple forms, such as text and pictures. These information can verify each other, increase the credibility of the information, and are more likely to attract people's attention, making it easier to spread. At the same time, the rich multimodal information also brings challenges to the detection of fake news. The current multimodal fake news faces the following challenges:
[0003] 1) The heterogeneity of multimodal information. Different types of data have different representations, structures, and semantics, so they need to be unified into a common representation.
[0004] 2) Fusion of multimodal data. Different modal information has differences in semantics and data volume. For example, text and images have different semantic expressions, and the amount of data contained in images is much larger than that of text. How to solve the semantic gap between different modal data and fuse them into a common semantic space while retaining their original semantic information is a difficult problem.
[0005] 3) The cross-domain problem of multimodal data. Traditional fake news detection usually focuses on one field, such as medicine and finance. Detectors trained in such a single field usually perform poorly when encountering a variety of fake news in real life. How to improve the generalization ability of detectors under multi-domain data is a problem.
[0006] Therefore, in response to the above problems, a multimodal fake news detection method based on adaptive fusion is proposed to solve the above problems. Summary of the invention
[0007] The purpose of the present invention is to address the deficiencies of the prior art and provide a multimodal false news detection method and system based on domain adaptation; the method improves the accuracy and generalization ability of false news detection, especially the ability to process cross-domain data, by fusing multimodal information such as text and images; the system maintains efficient detection performance in different fields and different types of news by designing an efficient, real-time, and user-friendly false news detection platform, thereby reducing the spread of false information and protecting the public's right to know and social stability.
[0008] The present invention is implemented by the following technical solution: a multimodal false news detection method based on domain adaptation is implemented based on a multimodal false news detection system consisting of a single-modal feature extraction module, a multi-head feature fusion device, a domain adapter and a false news classifier, and includes the following steps:
[0009] 1) Input the news text and image into different unimodal feature extraction modules to extract their respective feature vectors;
[0010] 2) The extracted text feature vector and image feature vector are input into the multi-head feature fusion device for feature fusion, and a multi-dimensional and multi-modal feature vector is extracted using a multi-head mechanism;
[0011] 3) The extracted text features are used to extract domain vectors through the soft attention mechanism. The domain vectors are used as guidance to adjust the weights of various multimodal feature representations, and the multi-dimensional multimodal feature vectors are fused through the domain adapter according to the weights to obtain the final multimodal feature fusion vector; the correlation between images and texts is revealed through the weight allocation in the feature fusion process, thereby reflecting the consistency or inconsistency between images and texts.
[0012] 4) The final multimodal feature fusion vector is classified using a fake news classifier, and the multimodal feature fusion vector is mapped into a probability distribution, indicating the possibility that the news belongs to the true or false classification; finally, the classification loss is calculated using cross entropy, and the entire multimodal fake news detection system is trained by minimizing the classification loss.
[0013] In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: the step 1) includes the following steps:
[0014] 1.1) For text, the pre-trained model RoBERTa is used as a single-modal feature extraction module. The feature vector of the text is extracted through 24 hidden layers, and the following formula is used for feature extraction: ,in, S Represents the news text content, t represents the vector representation of each word after 24 hidden layers, m Indicates the number of words in the text, T Represents the text feature vector;
[0015] 1.2) For images, the pre-trained ResNet50 model is used as a single-modal feature extraction module to extract the feature vector of the image, and the following formula is used when performing feature extraction: ,in, I Indicates the image content corresponding to the news, vrepresents the image vector representation extracted from the pre-trained ResNet50 model, n represents the embedding dimension of the image, V Represents the image feature vector.
[0016] In order to better realize the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: when performing image feature extraction, the feature vector of the image is obtained by the fourth residual block of the pre-trained ResNet50 model, and the obtained image feature vector is adjusted to 3 dimensions so as to be consistent with the dimension of the text feature vector.
[0017] In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: in the step 2), when performing feature fusion, a soft attention mechanism is used for feature fusion; when a multi-head mechanism is used for multi-dimensional multimodal feature vector extraction, the following formula is used to complete it: , where x represents the extracted multi-dimensional multi-modal feature vector, T represents the text feature vector, V represents the image feature vector, and Both are learnable parameters, which respectively represent the proportion of the image feature vector and the text feature vector in the extracted multi-dimensional multimodal feature vector.
[0018] In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: the step 3) includes the following steps:
[0019] 3.1) Using text feature vectors T Each vector in t i , the weight distribution is obtained through the attention mechanism g i ,and ,in, v represents the image vector representation extracted from the pre-trained ResNet50 model, W represents a learnable parameter matrix used to map text feature vectors to a new feature space. b Represents a bias vector used to adjust the linear transformation of the feature vector during feature conversion;
[0020] 3.2) Weight distribution g i Do normalization: ,in, α iis the weight distribution obtained after normalization. M Indicates the total number of samples involved in weight calculation, Represents the normalization factor, which is used to standardize the weight distribution to ensure that the weight sum is 1. j Represents the index of a specific weight distribution, which is used to identify different weight distribution items. g j Indicates a specific index j The weight distribution value under is used to represent the weight of a specific feature vector;
[0021] 3.3) Take the weighted sum of the text feature vectors to obtain the domain feature vector: ,in, d is the domain feature vector, N represents the total number of training samples, i It represents the index variable for summation, which traverses from 1 to N All integers of ;
[0022] 3.4) Using Domain Feature Vectors d As a guide, adjust the weights of the multi-dimensional multimodal feature vector: , where γ represents the weight distribution of the normalized multi-dimensional multi-modal feature vector, f ( d ) represents a nonlinear activation function that transforms the domain feature vector d Transform into a new feature representation to better guide the weight adjustment of multi-dimensional multi-modal feature vectors;
[0023] 3.5) According to the weights, the multi-dimensional multi-modal feature vectors are fused to obtain the final multi-modal feature fusion vector: ,in, r represents the final multimodal feature fusion vector, H Represents a fused multimodal feature vector set for further feature fusion and classification. γ i Indicates i The normalized weights of the feature vectors are used to assign different weights to different feature vectors during feature fusion; x i Indicates i A feature vector is a feature representation in a specific modality (text or image).
[0024] In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: in the step 4), the multimodal feature fusion vector is mapped into a probability distribution, which is implemented by the following formula: ,in, Represents the predicted label, which is obtained by inputting the final multimodal feature fusion vector into the multilayer perceptron MLP. r Represents the final multimodal feature fusion vector; when the cross entropy is used to calculate the classification loss, it is implemented by the following formula: ,in, y i represents the true label, L represents the prediction loss, N Represents the total number of training samples.
[0025] A multimodal false news detection system based on domain adaptation, used to implement the multimodal false news detection method based on domain adaptation, comprising:
[0026] A unimodal feature extraction module for extracting text feature vectors from news and image feature vectors from images;
[0027] The multi-head feature fuser uses a soft attention mechanism to fuse text feature vectors and image feature vectors and extract multi-dimensional and multi-modal feature vectors.
[0028] The domain adapter extracts the domain feature vector from the text feature vector and uses it to guide the fusion of multi-dimensional and multi-modal feature vectors. The domain adapter uses the domain vector to adjust the weights of various multi-modal feature representations, so that the detection system can perform feature fusion according to the characteristics of different domains. The domain adapter can effectively enhance the generalization ability of the detection system when processing cross-domain data, so that the system can maintain efficient detection performance in different domains and different types of news.
[0029] The fake news classifier uses the multimodal feature fusion vector after the domain adapter as the final classification feature vector to obtain the classification result of the news.
[0030] In order to better realize the multimodal fake news detection system based on domain adaptation described in the present invention, the following setting method is particularly adopted: according to the classification results of the news, the classification loss is calculated using the cross entropy function, and the model parameters of the entire multimodal fake news detection system are adjusted through back propagation.
[0031] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0032] (1) The present invention uses the Chinese feature extraction model RoBERTa to learn a text feature vector with more comprehensive semantic information through Chinese word masking and 24 hidden layers.
[0033] (2) The present invention adopts a multi-head feature fuser to fuse text and image feature vectors from multiple perspectives to obtain a multi-dimensional and multi-modal feature vector with richer representation information.
[0034] (3) The present invention adopts a domain adapter to guide the fusion of multi-dimensional and multi-modal feature vectors from multiple perspectives through the extracted domain vectors to solve the cross-domain problem in fake news detection.
[0035] (4) The present invention has the ability to improve domain labels and can be applied to data sets with missing domain labels. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 It is a flow chart of the present invention.
[0037] Figure 2 This is a framework diagram of the multimodal fake news detection system based on domain adaptation described in the present invention. DETAILED DESCRIPTION
[0038] The present invention is further described in detail below in conjunction with examples, but the embodiments of the present invention are not limited thereto.
[0039] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the invention claimed for protection, but merely represents the selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0040] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise" and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present invention.
[0041] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0042] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0043] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may include that the first and second features are in direct contact, or may include that the first and second features are not in direct contact but are in contact through another feature between them. Moreover, a first feature being "above", "above" and "above" a second feature includes that the first feature is directly above and obliquely above the second feature, or simply indicates that the first feature is higher in level than the second feature. A first feature being "below", "below" and "below" a second feature includes that the first feature is directly below and obliquely below the second feature, or simply indicates that the first feature is lower in level than the second feature.
[0044] Glossary:
[0045] RoBERTa: An improved pre-trained language model based on BERT, which improves the effect of text feature extraction through larger data and longer training.
[0046] ResNet50: A deep residual network model with 50 layers for image feature extraction, which can effectively capture the high-level features of the image.
[0047] Embodiment 1:
[0048] The present invention designs a multimodal fake news detection method based on domain adaptation, which improves the accuracy and generalization ability of fake news detection by fusing multimodal information such as text and images, especially the ability to process cross-domain data. The method is implemented based on a multimodal fake news detection system consisting of a single-modal feature extraction module, a multi-head feature fuser, a domain adapter and a fake news classifier, and includes the following steps:
[0049] 1) Input the news text and image into different unimodal feature extraction modules to extract their respective feature vectors;
[0050] 2) The extracted text feature vector and image feature vector are input into the multi-head feature fusion device for feature fusion, and a multi-dimensional and multi-modal feature vector is extracted using a multi-head mechanism;
[0051] 3) The extracted text features are used to extract domain vectors through the soft attention mechanism. The domain vectors are used as guidance to adjust the weights of various multimodal feature representations, and the multi-dimensional multimodal feature vectors are fused through the domain adapter according to the weights to obtain the final multimodal feature fusion vector; the correlation between images and texts is revealed through the weight allocation in the feature fusion process, thereby reflecting the consistency or inconsistency between images and texts.
[0052] 4) The final multimodal feature fusion vector is classified using a fake news classifier, and the multimodal feature fusion vector is mapped into a probability distribution, indicating the possibility that the news belongs to the true or false classification; finally, the classification loss is calculated using cross entropy, and the entire multimodal fake news detection system is trained by minimizing the classification loss.
[0053] Embodiment 2:
[0054] This embodiment is further optimized on the basis of the above embodiment, and the same points as the above technical solution are not repeated here. In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: the step 1) includes the following steps:
[0055] 1.1) For text, the pre-trained model RoBERTa is used as a single-modal feature extraction module. The feature vector of the text is extracted through 24 hidden layers, and the following formula is used for feature extraction: ,in, S Represents the news text content, t represents the vector representation of each word after 24 hidden layers, m Indicates the number of words in the text, T Represents the text feature vector;
[0056] 1.2) For images, the pre-trained ResNet50 model is used as a single-modal feature extraction module to extract the feature vector of the image, and the following formula is used when performing feature extraction: ,in, I Indicates the image content corresponding to the news, v represents the image vector representation extracted from the pre-trained ResNet50 model, n represents the embedding dimension of the image, V Represents the image feature vector.
[0057] Embodiment 3:
[0058] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. In order to better realize the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: when performing image feature extraction, the feature vector of the image is obtained by the fourth residual block of the pre-trained ResNet50 model, and the obtained feature vector of the image is adjusted to 3 dimensions so as to be consistent with the dimension of the text feature vector.
[0059] Embodiment 4:
[0060] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. In order to better realize the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: in the step 2), when performing feature fusion, a soft attention mechanism is used for feature fusion; when a multi-head mechanism is used for multi-dimensional multimodal feature vector extraction, the following formula is used to complete it: , where x represents the extracted multi-dimensional multi-modal feature vector, T represents the text feature vector, V represents the image feature vector, and Both are learnable parameters, which respectively represent the proportion of the image feature vector and the text feature vector in the extracted multi-dimensional multimodal feature vector.
[0061] Embodiment 5:
[0062] This embodiment is further optimized on the basis of any of the above embodiments, and the same points as the above technical solutions are not repeated here. In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: the step 3) includes the following steps:
[0063] 3.1) Using text feature vectors T Each vector in t i , the weight distribution is obtained through the attention mechanism g i ,and ,in, v represents the image vector representation extracted from the pre-trained ResNet50 model, W represents a learnable parameter matrix used to map text feature vectors to a new feature space. bRepresents a bias vector used to adjust the linear transformation of the feature vector during feature conversion;
[0064] 3.2) Weight distribution g i Do normalization: ,in, α i is the weight distribution obtained after normalization. M Indicates the total number of samples involved in weight calculation, Represents the normalization factor, which is used to standardize the weight distribution to ensure that the weight sum is 1. j Represents the index of a specific weight distribution, which is used to identify different weight distribution items. g j Indicates a specific index j The weight distribution value under is used to represent the weight of a specific feature vector;
[0065] 3.3) Take the weighted sum of the text feature vectors to obtain the domain feature vector: ,in, d is the domain feature vector, N represents the total number of training samples, i It represents the index variable for summation, which traverses from 1 to N All integers of ;
[0066] 3.4) Using Domain Feature Vectors d As a guide, adjust the weights of the multi-dimensional multimodal feature vector: , where γ represents the weight distribution of the normalized multi-dimensional multi-modal feature vector, f ( d ) represents a nonlinear activation function that transforms the domain feature vector d Transform into a new feature representation to better guide the weight adjustment of multi-dimensional multi-modal feature vectors;
[0067] 3.5) According to the weights, the multi-dimensional multi-modal feature vectors are fused to obtain the final multi-modal feature fusion vector: ,in, r represents the final multimodal feature fusion vector, H Represents a fused multimodal feature vector set for further feature fusion and classification. γ i Indicates i The normalized weights of feature vectors are used to assign different weights to different feature vectors during feature fusion. x i Indicates iA feature vector is a feature representation in a specific modality (text or image).
[0068] Embodiment 6:
[0069] This embodiment is further optimized on the basis of any of the above embodiments, and the similarities with the above technical solutions are not repeated here. In order to better implement the multimodal fake news detection method based on domain adaptation described in the present invention, the following setting is particularly adopted: In the step 4), the multimodal feature fusion vector is mapped into a probability distribution, which is implemented by the following formula: ,in, Represents the predicted label, which is obtained by inputting the final multimodal feature fusion vector into the multilayer perceptron MLP. r Represents the final multimodal feature fusion vector; when the cross entropy is used to calculate the classification loss, it is implemented by the following formula: ,in, y i represents the true label, L represents the prediction loss, N Represents the total number of training samples.
[0070] Embodiment 7:
[0071] A multimodal false news detection system based on domain adaptation, used to implement the multimodal false news detection method based on domain adaptation, comprising:
[0072] A unimodal feature extraction module for extracting text feature vectors from news and image feature vectors from images;
[0073] The multi-head feature fuser uses a soft attention mechanism to fuse text feature vectors and image feature vectors and extract multi-dimensional and multi-modal feature vectors.
[0074] The domain adapter extracts the domain feature vector from the text feature vector and uses it to guide the fusion of multi-dimensional and multi-modal feature vectors. The domain adapter uses the domain vector to adjust the weights of various multi-modal feature representations, so that the detection system can perform feature fusion according to the characteristics of different domains. The domain adapter can effectively enhance the generalization ability of the detection system when processing cross-domain data, so that the system can maintain efficient detection performance in different domains and different types of news.
[0075] The fake news classifier uses the multimodal feature fusion vector after the domain adapter as the final classification feature vector to obtain the classification result of the news.
[0076] Embodiment 8:
[0077] This embodiment is further optimized on the basis of the above embodiment, and the similarities with the above technical solution are not repeated here. In order to better realize the multimodal fake news detection system based on domain adaptation described in the present invention, the following setting method is particularly adopted: according to the classification results of the news, the classification loss is calculated using the cross entropy function, and the model parameters of the entire multimodal fake news detection system are adjusted through back propagation.
[0078] Embodiment 9:
[0079] A multimodal fake news detection method based on domain adaptation, combined with Figure 1 As shown, a multimodal fake news detection system consisting of a single-modal feature extraction module, a multi-head feature fusion device, a domain adapter and a fake news classifier is implemented, including the following steps:
[0080] S1 uses text and visual encoders to extract unimodal feature vectors:
[0081] S1.1 For news text, the pre-trained model RoBERTa (text encoder) is used to extract the feature vector of the text through 24 hidden layers, and the following formula is used for feature extraction: ,in, S Represents the news text content, t represents the vector representation of each word after 24 hidden layers, m Indicates the number of words in the text, T Represents the text feature vector;
[0082] S1.2 For news images, the pre-trained ResNet50 model (visual encoder) is used to extract the feature vector of the image, and the following formula is used when extracting features: ,in, I Indicates the image content corresponding to the news, v represents the image vector representation extracted from the pre-trained ResNet50 model, n represents the embedding dimension of the image, V Represents the image feature vector; when performing image feature extraction, the feature vector of the image is obtained through the fourth residual block of the pre-trained ResNet50 model, and the obtained image feature vector is adjusted to 3 dimensions to keep consistent with the dimension of the text feature vector.
[0083] S2 uses a multi-head attention feature fuser to extract multi-dimensional multimodal feature vectors:
[0084] The extracted text feature vector and image feature vector are input into the multi-head feature fusion device to perform feature fusion using the soft attention mechanism, and a multi-head mechanism is used to extract a multi-dimensional multimodal feature vector:
[0085] , where x represents the extracted multi-dimensional multi-modal feature vector, T represents the text feature vector, V represents the image feature vector, and Both are learnable parameters, which respectively represent the proportion of the image feature vector and the text feature vector in the extracted multi-dimensional multimodal feature vector.
[0086] S3 extracts the domain feature vector of news from text features:
[0087] S3.1 Using text feature vectors T Each vector in t i , the weight distribution is obtained through the attention mechanism g i ,and ,in, v represents the image vector representation extracted from the pre-trained ResNet50 model, W represents a learnable parameter matrix used to map text feature vectors to a new feature space. b Represents a bias vector used to adjust the linear transformation of the feature vector during feature conversion;
[0088] S3.2 Weight distribution g i Do normalization: ,in, α i is the weight distribution obtained after normalization. M Indicates the total number of samples involved in weight calculation, Represents the normalization factor, which is used to standardize the weight distribution to ensure that the weight sum is 1. j Represents the index of a specific weight distribution, which is used to identify different weight distribution items. g j Indicates a specific index j The weight distribution value under is used to represent the weight of a specific feature vector;
[0089] S3.3 performs weighted summation of text feature vectors to obtain the domain feature vector: ,in, d is the domain feature vector, N represents the total number of training samples, i It represents the index variable for summation, which traverses from 1 to N All integers of .
[0090] S4 uses a domain adapter to guide the fusion of multi-dimensional and multi-modal feature vectors using domain feature vectors:
[0091] S4.1 Using domain feature vectors d As a guide, adjust the weights of the multi-dimensional multimodal feature vector: , where γ represents the weight distribution of the normalized multi-dimensional multi-modal feature vector, f ( d ) represents a nonlinear activation function that transforms the domain feature vector d Transform into a new feature representation to better guide the weight adjustment of multi-dimensional multi-modal feature vectors;
[0092] S4.2 fuses the multi-dimensional multi-modal feature vectors according to the weights to obtain the final multi-modal feature fusion vector: ,in, r represents the final multimodal feature fusion vector, H Represents a fused multimodal feature vector set for further feature fusion and classification. γ i Indicates i The normalized weights of the feature vectors are used to assign different weights to different feature vectors during feature fusion; x i Indicates i A feature vector is a feature representation in a specific modality (text or image).
[0093] S5 uses the final multimodal feature fusion vector to predict the classification result:
[0094] The final multimodal feature fusion vector is classified using a fake news classifier, and the multimodal feature fusion vector is mapped into a probability distribution, indicating the possibility that the news belongs to the true or false classification. When the multimodal feature fusion vector is mapped into a probability distribution, it is realized by the following formula: ,in, Represents the predicted label, which is obtained by inputting the final multimodal feature fusion vector into the multilayer perceptron MLP. r Represents the final multimodal feature fusion vector.
[0095] S6 calculates the loss based on the predicted classification results and adjusts the model parameters of the entire network through back propagation:
[0096] Using cross entropy: Calculate the classification loss and train the entire multimodal fake news detection system by minimizing the classification loss. y i represents the true label, L represents the prediction loss,N Represents the total number of training samples.
[0097] Embodiment 10:
[0098] A multimodal fake news detection system based on domain adaptation, such as Figure 2 As shown, the method for implementing the multimodal false news detection method based on domain adaptation includes:
[0099] Unimodal feature extraction modules (visual encoder, text encoder) for extracting text feature vectors from news and image feature vectors from images;
[0100] The multi-head feature fuser uses a soft attention mechanism to fuse text feature vectors and image feature vectors and extract multi-dimensional and multi-modal feature vectors.
[0101] The domain adapter extracts the domain feature vector from the text feature vector and uses it to guide the fusion of multi-dimensional and multi-modal feature vectors. The domain adapter uses the domain vector to adjust the weights of various multi-modal feature representations, so that the detection system can perform feature fusion according to the characteristics of different domains. The domain adapter can effectively enhance the generalization ability of the detection system when processing cross-domain data, so that the system can maintain efficient detection performance in different domains and different types of news.
[0102] The fake news classifier uses the multimodal feature fusion vector after the domain adapter as the final classification feature vector to obtain the classification result of the news.
[0103] When adjusting global parameters, the cross-entropy function is used to calculate the classification loss based on the classification results of the news, and the model parameters of the entire multimodal fake news detection system are adjusted through back propagation.
[0104] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Any simple modification or equivalent change made to the above embodiment based on the technical essence of the present invention shall fall within the protection scope of the present invention.
Claims
1. A multimodal fake news detection method based on domain adaptation, Features: The implementation of a multimodal fake news detection system based on a single-modal feature extraction module, a multi-head feature fuser, a domain adapter and a fake news classifier includes the following steps: 1) Inputting the news text and image into different single-modal feature extraction modules respectively to extract their respective feature vectors; including the following specific steps: 1.1) For text, the pre-trained model RoBERTa is used as a single-modal feature extraction module. The feature vector of the text is extracted through 24 hidden layers, and the following formula is used for feature extraction: T = {t 1 , ..., t m }=RoBERTa(S), where S represents the content of the news text, t represents the vector representation of each word after 24 hidden layers, m represents the number of words in the text, and T represents the text feature vector; 1.2) For images, the pre-trained ResNet50 model is used as a single-modal feature extraction module to extract the feature vector of the image, and the following formula is used when extracting features: V = {v 1 ,...v n }=ResNet50(I), where I represents the image content corresponding to the news, v represents the image vector representation extracted from the pre-trained ResNet50 model, n represents the embedding dimension of the image, and V represents the image feature vector; when performing image feature extraction, the feature vector of the image is obtained through the fourth residual block of the pre-trained ResNet50 model, and the obtained feature vector of the image is adjusted to 3 dimensions; 2) The extracted text feature vector and image feature vector are input into the multi-head feature fusion device for feature fusion, and a multi-head mechanism is used to extract a multi-dimensional multi-modal feature vector; when performing feature fusion, a soft attention mechanism is used for feature fusion; when using a multi-head mechanism for multi-dimensional multi-modal feature vector extraction, the following formula is used: x = exp[a text ln T+a image ln V], where x represents the extracted multi-dimensional multimodal feature vector, T represents the text feature vector, V represents the image feature vector, and a text and a image are all learnable parameters, representing the proportion of the image feature vector and the text feature vector in the extracted multi-dimensional multimodal feature vector; 3) Extracting domain vectors from the extracted text features through a soft attention mechanism, using the domain vectors as a guide, adjusting the weights of multiple multimodal feature representations, and fusing the multi-dimensional multimodal feature vectors through a domain adapter according to the weights to obtain the final multimodal feature fusion vector; including the following steps: 3.1) Use each vector t in the text feature vector T i , the weight distribution g is obtained through the attention mechanism i , and g i =vtanh(Wt i +b), where v represents the image vector representation extracted from the pre-trained ResNet50 model, W represents a learnable parameter matrix used to map the text feature vector to a new feature space, and b represents a bias vector used to adjust the linear transformation of the feature vector during the feature conversion process; 3.2) Weight distribution g i Do normalization: Among them, α i is the weight distribution obtained after normalization, M represents the total number of samples involved in the weight calculation, represents the normalization factor, which is used to standardize the weight distribution to ensure that the weight sum is 1, j represents the index of the weight distribution, which is used to identify different weight distribution items, and g j Represents the weight distribution value under index j, which is used to represent the weight of a certain feature vector; 3.3) Take the weighted sum of the text feature vectors to obtain the domain feature vector: Where d is the domain feature vector, N is the total number of training samples, and i is the index variable for summation, which traverses all integers from 1 to N; 3.4) Using the domain feature vector d as a guide, adjust the weight of the multidimensional multimodal feature vector: γ = softmax(f(d)), where γ represents the weight distribution of the normalized multidimensional multimodal feature vector, and f(d) represents a nonlinear activation function, which transforms the domain feature vector d into a new feature representation to better guide the weight adjustment of the multidimensional multimodal feature vector; 3.5) According to the weights, the multi-dimensional multi-modal feature vectors are fused to obtain the final multi-modal feature fusion vector: Among them, r represents the final multimodal feature fusion vector, H represents a fused multimodal feature vector set for further feature fusion and classification, and γ i represents the normalized weight of the i-th feature vector, which is used to assign different weights to different feature vectors during feature fusion. i represents the i-th eigenvector; 4) The final multimodal feature fusion vector is classified using a fake news classifier, and the multimodal feature fusion vector is mapped into a probability distribution, indicating the possibility that the news belongs to the true or false classification; finally, the classification loss is calculated using cross entropy, and the entire multimodal fake news detection system is trained by minimizing the classification loss; wherein, the multimodal feature fusion vector is mapped into a probability distribution, which is achieved by the following formula: in, Represents the predicted label, which is obtained by inputting the final multimodal feature fusion vector into the multilayer perceptron MLP, and r represents the final multimodal feature fusion vector; when the cross entropy is used to calculate the classification loss, it is implemented by the following formula: Among them, y i represents the true label, L represents the predicted loss, and N represents the total number of training samples.
2. A multimodal fake news detection system based on domain adaptation, Features: Used to implement a multimodal false news detection method based on domain adaptation as claimed in claim 1, comprising A unimodal feature extraction module for extracting text feature vectors from news and image feature vectors from images; The multi-head feature fuser uses a soft attention mechanism to fuse text feature vectors and image feature vectors and extract multi-dimensional and multi-modal feature vectors. The domain adapter extracts the domain feature vector from the text feature vector and uses it to guide the fusion of multi-dimensional and multi-modal feature vectors; The fake news classifier uses the multimodal feature fusion vector after the domain adapter as the final classification feature vector to obtain the classification result of the news.
3. According to claim 2, a multimodal fake news detection system based on domain adaptation, Features: According to the classification results of the news, the classification loss is calculated using the cross entropy function, and the model parameters of the entire multimodal fake news detection system are adjusted through back propagation.
