Knowledge-guided social affective computing label distribution correction method

CN117453947BActive Publication Date: 2026-10-27TIANJIN UNIVERSITY OF TECHNOLOGY +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311224760.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-09-21
Publication Date
2026-10-27
Estimated Expiration
2043-09-21

AI Technical Summary

Benefits of technology

[0057]1、本申请提出了一致性感知的情感先验损失和重要性感知的模型重加权方法,其中,前者通过对客户端情感特征的分布进行全局归一化,提高了联邦情感计算的性能,后者则通过将隐私不可知信息传递到服务器以保留客户端侧模型的更重要参数来提高全局模型的性能。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117453947B_ABST
    Figure CN117453947B_ABST
Patent Text Reader

Abstract

The application relates to a knowledge guidance-based association emotion computing label distribution correction method, steps of which are as follows: step 1, global shared layer model initialization; step 2, the server sends the shared layer model to multiple clients; step 3, the local model is trained by the client, and a sentiment hemisphere and a consistency perception sentiment prior loss are introduced; step 4, the server obtains model aggregation, and an importance perception model weight adjustment strategy is used for model aggregation to accelerate the convergence of the global model; step 5, if the model convergence result is no, returning to step 2; if the model convergence result is yes, completing model training. The application proposes a consistency perception sentiment prior loss and an importance perception model reweighting method, wherein the former globally normalizes the distribution of the emotion features of the client, and the latter improves the performance of the global model by transferring privacy-agnostic information to the server to retain more important parameters of the client-side model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer technology, to affective computing and federated learning, and specifically to a knowledge-guided federated affective computing label distribution correction method. Background Technology

[0002] 1. Affective computing

[0003] Most methods for recognizing human emotions focus on facial expression analysis. Compared to earlier methods that relied on handcrafted features and shallow classifiers, methods based on deep convolutional neural networks (CNNs) have made significant progress in recent years. Several techniques for capturing temporal dynamics in videos, such as recurrent neural networks (RNNs) or deep 3D-CNNs, have also been proposed recently. Various attention mechanisms have been proposed to detect different features to highlight the most helpful information in facial images. Recent research combines attention networks and encoder-decoder architectures with learning better facial expression features. An attention-based discriminative CNN has been proposed, which uses attention mechanisms to highlight the uneven contributions of different expression features.

[0004] However, the aforementioned neural network-based methods cannot be directly applied to the Federated Learning (FL) framework because they cannot address the heterogeneity of label distribution and privacy issues faced by federated sentiment computing tasks. A previous study on sentiment distribution learning inspired us to address the inconsistency in the global feature space caused by imbalanced label distributions in federated sentiment computing tasks. In this work, we leverage prior sentiment knowledge to map sentiment distributions to sentiment models in psychology and use relationships between sentiments to learn the visual sentiment distribution. However, this method is limited to datasets with a space of eight sentiment categories and cannot represent neutral sentiment categories. To address this, we propose a hemispherical structured sentiment representation that can adapt to various psychological sentiment models and unify the sentiment distribution across different clients in the global space.

[0005] 2. Federated Learning

[0006] Federated learning, as a distributed learning paradigm, has gained widespread adoption. It trains a global model using data distributed across multiple devices while ensuring the protection of sensitive data privacy. The concept of federated learning was first introduced in 2016, along with the Federated Average Algorithm (FedAvg). Each client simultaneously trains its model iteratively using its own data, then uploads it to a central server for model aggregation and updates. Some academic research has shown that local models can face severe model divergence in federated learning due to data heterogeneity, particularly imbalanced label distribution. The FedAvg algorithm needs modification to address the model divergence problem caused by non-independent and identically distributed data, especially in the context of federated learning involving complex models such as neural networks.

[0007] Currently, methods for solving the non-independent and identically distributed problem in FL can be divided into three different approaches: data-based, system-based, and algorithm-based.

[0008] A. Data-based approach

[0009] This class of methods attempts to overcome this problem by adjusting the data distribution. Two optimal solutions are data sharing and data augmentation. Data sharing addresses the data heterogeneity problem in FL by deploying a uniformly distributed global shared dataset to the server and using the shared dataset to pre-train a global model. Data augmentation, on the other hand, uses the server to average the local data uploaded by clients and return it, reducing the heterogeneity of the local data. Compared to the previous two methods, the data augmentation method in FL based on Generative Adversarial Networks (GANs) aims to train a capable global generator on the server. First, each client sends its local seed data sample to the server. The server can then use the seed sample to instruct the generator and discriminator. Using the global generator from the server, each client can balance its local dataset by generating rare class samples.

[0010] B. Systems-based approach

[0011] These methods are typically implemented through client-side clustering, with most flint and graph (FL) methods assuming a single global model within the system. However, effective learning using a single global model in environments with heterogeneous client-side data is challenging. Client-side clustering overcomes this challenge by assigning clients with similar local training data to the same cluster, thereby enhancing the effectiveness of the global model for learning local data. For example, existing work has addressed the heterogeneity of client-side data from the perspective of cross-cultural expressive differences, proposing grouped clustering methods for federated video sentiment computation. However, larger models require significantly higher computational and communication costs.

[0012] C. Algorithm-based methods

[0013] Algorithm-based methods aim to tailor models to specific local tasks. Several common personalization methods exist, such as local fine-tuning, personalization layers, knowledge distillation, and continuous learning. A common fine-tuning approach is to build a high-quality initial global model using meta-learning methods. Model-agnostic meta-learning (MAML) is used to build the initial global model, enabling local clients to achieve better performance results with minimal computational cost. The LG-FEDAVG method, which uses shallow layers of a neural network as personalization layers and deep layers as shared layers, is another approach. Knowledge distillation aims to transfer information from the server or other clients to a specific local model to improve its performance on heterogeneous data. Furthermore, continuous learning methods can be used to maintain the accuracy of the global model while retaining knowledge gained from different clients. Current work references the EWC algorithm in continuous learning to better maintain local model performance by transferring model gradients and parameter importance information between clients. However, frequent information transfer between clients increases the risk of privacy breaches. In recent years, methods based on logits calibration have emerged to address the heterogeneity of label distribution in FL. Since traditional cross-entropy is not suitable for scenarios with heterogeneous data, FedLC was further developed. This method corrects the logits before the softmax cross-entropy based on the probability of each category.

[0014] To address the model divergence problem caused by non-independent and identically distributed (i.i.d.) data, the FedAvg algorithm needs modification, especially in the context of flirting (FL) involving complex models such as neural networks. Current methods for addressing the non-independent and identically distributed (i.i.d.) problem in flirting can be categorized into three distinct approaches: data-based, system-based, and algorithm-based. Data-based algorithms can directly reduce data heterogeneity and improve model performance by applying data augmentation to heterogeneous data across clients. However, most of these methods require data sharing, which does not meet the privacy requirements of flirting. System-based algorithms reconsider architectural design and directly apply Transformers to serial and parallel flirting methods, demonstrating their effectiveness in mitigating data heterogeneity. However, larger models require significantly higher computational and communication costs. Algorithm-based methods are not directly applicable to the field of affective computing. For example, methods based on fine-tuning and knowledge distillation risk privacy breaches, methods based on continuous learning incur additional communication costs, and methods based on personalization layers limit the broadcasting of the entire model between the client and server, leading to conflicts in the global feature space. Summary of the Invention

[0015] To address the aforementioned technical problems, this invention provides a knowledge-guided federated sentiment computing label distribution correction method.

[0016] A knowledge-guided federated sentiment computing label distribution correction method is characterized by the following steps to achieve the overall goal of this method:

[0017] Step 1: The client initializes the global shared layer model and the personalized layer model simultaneously.

[0018] Step 2: The server sends the shared layer model to multiple clients;

[0019] Step 3: The client receives the shared layer model, trains the local model, calculates the importance matrix of the shared layer parameters, and uploads the shared layer parameters and importance matrix to the server;

[0020] During the training of the local model, an emotion prior loss for consistency perception was introduced by the emotion hemisphere to normalize the consistency of emotion features in the global space.

[0021] Step 4: The server uses the parameter importance matrix as weights to aggregate the shared layer parameters sent by all clients to obtain the model aggregation.

[0022] In this process, the importance-aware model weight adjustment strategy is used for model aggregation to accelerate the convergence of the global model;

[0023] Step 5: If the model converges but not, return to step 2; if the convergence result is yes, the test model is complete.

[0024] Furthermore, in step 1, a global model is represented as S. G K local models are represented as C = {C1, C2, ..., C...} k Assume each local client C k A local dataset D with different label distributions k The set of all datasets is represented as Learn the model parameters for each client based on their respective datasets.

[0025] Furthermore, in step 2, the overall objective of the method is described by the following formula:

[0026]

[0027] Model ω k It is divided into two distinct parts: a shared layer ω that outputs general and low-sensitivity features. s,k A personalized layer ω that outputs highly sensitive information p,k The client k has been granted permission to upload the parameters of the shared layer to the server, while the parameters of the personalized layer are kept private.

[0028] Furthermore, in step 3, each emotion category in the emotion hemisphere is represented by an emotion vector e. i express:

[0029] e i =(θ i ,p i ,Φ i ,r i (2)

[0030] Where, θ i p i Φ i and r i These represent emotion type, emotion polarity, emotion polarity intensity, and emotion type intensity, respectively.

[0031] Emotional Type θ i Using polar angle θ i The basic sentiment type is defined using the range [0, 2π], and is represented as follows:

[0032]

[0033] Where C basic This indicates the number of basic sentiment types, with θ = 0 used to define a neutral sentiment type;

[0034] Emotional polarity pi According to the polar angle θ i Define positive and negative emotional polarities as follows:

[0035]

[0036] Emotional polarity intensity Φ i Use azimuth The intensity of the polarity of emotion is defined as follows:

[0037]

[0038] Where C all This represents the number of all emotion types, including basic emotions and emotions similar to each basic emotion but with different polarities; in some emotion models involving neutral emotion types, Φ is used. i To represent the intensity of polarity in neutral sentiment types;

[0039] Emotion type intensity r i The intensity of a specific type of emotion is determined by the radial distance r. i ∈[0,1] represents, where r i =1 indicates the highest intensity level, r i =0 indicates the lowest intensity level. The intensity of each emotion type is set to:

[0040] r c =1, c∈[1,C all (6)

[0041] Indicates the intensity of a given individual emotion by describing its emotion type using its total weight.

[0042] Furthermore, in step 3, the consistent perception of the emotion prior loss utilizes the emotion hemisphere to globally unify the distribution of each emotion category, aiming to penalize the difference between two emotion vectors, setting e... i =(θ i ,p i ,Φ i ,r i ) is the true emotional vector. This is the sentiment vector predicted by the model. The mean squared error (MSE) loss is used to measure the differences between sentiment type, sentiment polarity, and sentiment polarity intensity, respectively, with sentiment type intensity used as the confidence score. The formula is as follows:

[0043]

[0044] Where |D k | represents the number of samples in the local dataset of client k. This enables the model to accurately predict sentiment polarity.

[0045] Further, the predicted intensity of sentiment type As a confidence level, it is incorporated into the detailed constraints of the proposed loss function and sentiment distribution learning.

[0046] Finally, the weighted combination of cross-entropy (CE) loss and consistent perceived sentiment prior (EP) loss is used as the final loss function:

[0047] L=(1-λ)L CE +λL EP (8)

[0048] Where λ is a hyperparameter that balances the relative importance of the two losses.

[0049] Furthermore, in step 4, the importance matrix of the model parameters is calculated, and the importance matrix is ​​expressed as:

[0050]

[0051] Where ω k This represents the local model parameters of client k. The model is evaluated and gradients are calculated using a single sample. For each parameter, the gradients of all samples are summed, and finally divided by the number of samples to obtain the Fisher information matrix item for the corresponding parameter.

[0052] At the end of each round of communication, each client uploads the updated shared layer parameters and the corresponding importance matrix to the server; on the server side, the importance matrix undergoes two normalization steps: self-normalization and element-wise normalization.

[0053] The resulting normalized importance matrix is ​​used as the weight for each parameter:

[0054]

[0055] in Represents the normalized parameter importance matrix. This represents the globally shared layer parameters aggregated on the server side, which will be resent to each client for the next round of training.

[0056] The present invention has the following beneficial effects:

[0057] 1. This application proposes a consistency-aware sentiment prior loss and an importance-aware model reweighting method. The former improves the performance of federated sentiment computing by globally normalizing the distribution of client sentiment features, while the latter improves the performance of the global model by passing privacy-agnostic information to the server to retain more important parameters of the client-side model.

[0058] 2. This application addresses the problem of inconsistent distribution of customer feature space across a global region. To solve this problem, we propose a hemispherical structural representation for visual sentiment computation. Our method aims to leverage the interrelationships of global sentiment to promote consistency in sentiment feature distribution among clients. Specifically, we create an sentiment hemisphere that integrates different sentiment states within a unified framework. The proposed sentiment hemisphere model assumes that each sentiment can be effectively represented as a sentiment vector composed of four distinct attributes: sentiment type, sentiment type intensity, sentiment polarity, and sentiment polarity intensity. Basic sentiments are defined by a set of unit vectors uniformly distributed across the proposed sentiment hemisphere, corresponding to sentiments in psychological sentiment models (e.g., the 24 sentiments in the Plutchik sentiment wheel). We propose a systematic method to map real and predicted sentiment distributions to the sentiment hemisphere to create a unified sentiment representation. In this way, we can globally normalize the feature space distribution among clients. Furthermore, leveraging the inherent similarity and opposition between sentiments, we propose a consistent perception sentiment prior loss that compensates for the differences between real and predicted sentiments across four attributes, further improving the effectiveness of sentiment computation.

[0059] 3. This application addresses the model divergence problem caused by non-independent and identically distributed data. It proposes an importance-aware model reweighting method. Due to the imbalanced distribution of labels, each local model has different and obvious sentiment biases. Direct parameter aggregation of local models can negatively impact their performance because, during aggregation, more important model parameters may be weakened by other local models. Therefore, increasing the weight of more important parameters for individual clients during aggregation can promote the local and global models to reach a common optimal solution. Based on this intuition, we reference the EWC algorithm in continuous learning, which approximates the diagonal of the Fisher information matrix as the importance scores of model parameters. After updating the local models, we calculate the parameter importance matrix of the current model using local data and send it to the server along with the local models. On the server side, we first normalize the importance matrices of all parameters, and then use the normalized importance matrix as the weight for aggregation of each local model, enabling the global model to reach the optimal solution more quickly. Attached Figure Description

[0060] Figure 1 This is a flowchart illustrating the method. Detailed Implementation

[0061] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments. The embodiments of the present invention are given for illustrative and descriptive purposes only, and are not intended to be exhaustive or to limit the invention to the forms disclosed. Many modifications and variations will be apparent to those skilled in the art. The embodiments were chosen and described to better illustrate the principles and practical application of the invention, and to enable those skilled in the art to understand the invention and design various embodiments with various modifications suitable for a particular purpose.

[0062] See appendix Figure 1 As shown, a knowledge-guided federated sentiment computing label distribution correction method is proposed. First, the client-side global shared layer model is initialized, and at the same time, the personalized layer model is initialized.

[0063] A server is represented as S G K clients are represented as C = {C1, C2, ..., C...} k Assume each local client C k A local dataset D with different label distributions k The set of all datasets is represented as D = Learn the model parameters for each client based on their respective datasets.

[0064] To protect privacy in sentiment data, model ω k It is divided into two distinct parts: a shared layer ω that outputs general and low-sensitivity features. s,k A personalized layer ω that outputs highly sensitive features. p,k The client k has been granted permission to upload parameters of the shared layer to the server, while parameters of the personalized layer are kept private. The overall goal of this method can be described as follows:

[0065]

[0066] The server sends the shared layer model to the selected client, the selected client trains the local model, calculates the importance matrix of the shared layer parameters, and uploads the shared layer parameters and importance matrix to the server.

[0067] Emotional Hemisphere

[0068] Unlike other classification tasks, sentiment labels are closely related to each other and possess unique features based on mental models. Motivated by this, we propose a sentiment hemisphere structure to address the problem of overlapping embeddings of different sentiment categories in the global feature space caused by heterogeneous label distributions among clients. Our goal is to ensure the consistency of the embedding space of sentiment features across multiple clients. In the proposed sentiment hemisphere, each sentiment category is represented by a sentiment vector e. iIt is stated that it is described as:

[0069] e i =(θ i ,p i ,Φ i ,r i (2)

[0070] Where, θ i p i Φ i and r i These represent emotion type, emotion polarity, emotion polarity intensity, and emotion type intensity, respectively. The following is a detailed description of these four emotion attributes.

[0071] Sentiment type (θ) i ):

[0072] Taking the Plutchik Wheel of Emotions as an example, this psychological model of emotion includes eight basic emotion types: joy, trust, fear, surprise, sadness, disgust, anger, and anticipation. Referring to the emotion arrangement in the Plutchik Wheel of Emotions, we use the polar angle θ. i The eight basic emotion types are defined in the range [0, 2π], and are represented as follows:

[0073]

[0074] Where C basic This indicates the number of basic emotion types in Plutchik's Wheel of Emotions. It is worth noting that the applicability of our emotion hemisphere is not limited to Plutchik's Wheel of Emotions, but covers a variety of psychological emotion models, including those that include neutral emotion types. In particular, we use θ = 0 to define neutral emotion types.

[0075] Emotional polarity (p) i ):

[0076] In addition to the given fine-grained emotional labels, such as joy, anger, and sadness, each emotion can also be naturally categorized into coarse-grained emotional polarities (i.e., positive and negative). Specifically, joy, trust, anticipation, and surprise are considered positive emotions, while anger, disgust, fear, and sadness are considered negative emotions. This is based on the polar angle θ. i We can define positive and negative emotional polarities as follows:

[0077]

[0078] Emotional polarity intensity (Φ) i )

[0079] Emotional polarity also varies in intensity. For example, ecstasy has a higher positive polarity than joy, while tranquility has a lower positive polarity, approaching neutral intensity. Therefore, we use azimuth angles. The intensity of the polarity of emotion is defined as follows:

[0080]

[0081] Where C all This represents the number of all emotion types in the Plutchik Emotion Wheel. These include eight basic emotions and emotions similar to each basic emotion but with varying polarity intensities. In some emotion models involving neutral emotion types, we use Φ. i This is used to represent the intensity of the polarity of neutral emotional types.

[0082] Emotion type intensity (r) i )

[0083] The intensity of a specific type of emotion is determined by radial distance r i ∈[0,1] represents, where r i =1 indicates the highest intensity level, r i =0 indicates the lowest intensity level. Specifically, the intensity of each emotion type is set to:

[0084] r c =1, c∈[1,C all (6)

[0085] Indicates the intensity of a given single emotion type, described by its full weights.

[0086] Consistent perceived emotion prior loss

[0087] In traditional FL update processes, each client only acquires knowledge of its local feature distribution. However, without a unified standard, the feature distributions of different clients within a specific class may exhibit bias. This problem can be exacerbated in the case of non-independent and identically distributed data, further impacting the convergence of the global model.

[0088] Therefore, we utilize the sentiment hemisphere to globally unify the distribution of each sentiment category, aiming to penalize the difference between two sentiment vectors, such as e. i =(θ i ,p i ,Φ i ,r i ) is an emotional tag. These are the labels predicted by the model. Specifically, we use the mean squared error (MSE) loss to measure the differences between sentiment type, sentiment polarity, and sentiment polarity intensity, respectively, and use sentiment type intensity as the confidence score, as shown in the following formula:

[0089]

[0090] Where |D k | represents the number of samples in the local dataset of client k. Enabling the model to correctly predict sentiment polarity is the primary goal of achieving accurate sentiment prediction. The distance between polar and azimuth angles measures the similarity between different sentiments. However, considering only sentiment type, sentiment polarity, and sentiment polarity intensity is insufficient, as sentiment type intensity is also considered a key factor for a specific sentiment. In cases where two samples share the same sentiment type but have substantially different sentiment intensities, for example... and Assigning them to a single sentiment state is not advisable. Therefore, we further analyze the predicted sentiment type intensity. We incorporate the confidence level into the proposed loss function. Finally, we add the cross entropy...

[0091] The final loss function is a weighted combination of the loss from the consistent perceived emotion prior and the loss from the consistent emotion prior.

[0092] L=(1-λ)L CE +λL EP (8)

[0093] Where λ is a hyperparameter that balances the relative importance of the two losses.

[0094] We introduce an emotional hemisphere and a consistent perception of emotional prior loss, and update the parameters to normalize the consistency of emotional features in the global space.

[0095] The server aggregates the shared layer parameters sent by all selected clients to obtain a new global model; an importance-aware model weighting strategy is used for model aggregation to accelerate the convergence of the global model.

[0096] Importance-aware model reweighting method

[0097] In cases of imbalanced label distribution, each local model learns different knowledge priorities. Directly averaging all local models may eliminate some key information, leading to problems such as scattered model parameters or slow convergence.

[0098] Due to the imbalanced distribution of customer tags, each local model has a different knowledge bias. To preserve the knowledge bias of each client, we aim to retain more parameters that are more important to the local models during global model aggregation. Inspired by the continuous learning EWC algorithm, we compute an importance matrix for the model parameters that does not contain privacy-related information and does not excessively increase communication costs. An approximation of the Fisher information matrix is ​​used as the importance matrix for the model parameters:

[0099]

[0100] Where ω k This represents the local model parameters for client k. Specifically, after the local model is updated, we evaluate the model and compute gradients for each sample. For each parameter, we sum the gradients of all samples and divide by the number of samples to obtain the Fisher information matrix item for the corresponding parameter.

[0101] At the end of each round of communication, each client uploads the updated shared layer parameters and the corresponding importance matrix to the server. On the server side, the importance matrix undergoes two normalization steps: self-normalization followed by element-wise normalization. The resulting normalized importance matrix is ​​used as the weight for each parameter, as expressed in the following equation:

[0102]

[0103] in Represents the normalized parameter importance matrix. This represents the globally shared layer parameters aggregated on the server side, which will be resent to each client for the next round of training.

[0104] Obviously, the embodiments described in this application are merely some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art or related fields based on the embodiments of the present invention without inventive effort should fall within the scope of protection of the present invention. Structures, devices, and operating methods not specifically described and explained in the present invention, unless otherwise specified or limited, are implemented according to conventional means in the art.

Claims

1. A knowledge-guided federated sentiment computing label distribution correction method, characterized in that: The steps to achieve the overall goal of this method are as follows: Step 1: The client initializes the global shared layer model and the personalized layer model simultaneously. Step 2: The server sends the shared layer model to multiple clients; Step 3: The client receives the shared layer model, trains the local model, calculates the importance matrix of the shared layer parameters, and uploads the shared layer parameters and importance matrix to the server; During the training of the local model, an emotion prior loss for consistency perception was introduced by the emotion hemisphere to normalize the consistency of emotion features in the global space. Each emotion category in the emotion hemisphere is represented by an emotion vector. express: =( ) in, , , and These represent emotion type, emotion polarity, emotion polarity intensity, and emotion type intensity, respectively. Emotional type Using polar angle The basic sentiment type is defined using the range [0, 2π], and is represented as follows: = ,c ] in This represents the number of basic sentiment types, with θ = 0 used to define a neutral sentiment type; Emotional polarity According to polar angle Define positive and negative emotional polarities as follows: Emotional polarity intensity Use azimuth ∈ [0, The polarity intensity of emotion is defined as follows: = in This represents the number of all emotion types, including basic emotions and emotions similar to each basic emotion but differing in polarity; in emotion models involving neutral emotion types, the term used is... To represent the intensity of polarity in neutral sentiment types; The intensity of a specific type of emotion is determined by radial distance. ∈[0,1] represents, where =1 indicates the highest level of intensity. = 0 represents the lowest intensity level. The intensity of each emotion type is set to: =1, c ] Indicates that a given individual emotion is described by its total weight to represent the intensity of its emotion type; The consistent perception of emotion prior loss utilizes the emotion hemisphere to globally unify the distribution of each emotion category, aiming to penalize the difference between two emotion vectors, and sets... =( ) is the true emotional vector. =( The model predicts the sentiment vector, and uses mean squared error loss to measure the differences between sentiment type, sentiment polarity, and sentiment polarity intensity, with sentiment type intensity used as the confidence level. The formula is as follows: = in This represents the number of samples in the local dataset of client k. This enables the model to accurately predict sentiment polarity; Predict the intensity of the sentiment type The confidence level is incorporated into the detailed constraints of the proposed loss function and sentiment distribution learning. Finally, the cross-entropy loss Consistency perception of emotion prior loss The weighted combination is used as the final loss function: L=(1-λ) +λ Where λ is a hyperparameter that balances the relative importance of the two losses; Step 4: The server uses the parameter importance matrix as weights to aggregate the shared layer parameters sent by all clients to obtain the model aggregation. In this process, the importance-aware model weight adjustment strategy is used for model aggregation to accelerate the convergence of the global model; Step 5: If the model converges but not, return to step 2; if the convergence result is yes, the test model is complete.

2. The knowledge-guided federated sentiment computing label distribution correction method according to claim 1, characterized in that: In step 1, a global model is represented as follows: K local models are represented as C={ Assuming each local client Local datasets with different label distributions The set of all datasets is represented as D = Learn the model parameters for each client based on their respective datasets. .

3. The knowledge-guided federated sentiment computing label distribution correction method according to claim 2, characterized in that: In step 2, the overall objective of the method is described by the formula: Model It is divided into two distinct parts: a shared layer that outputs general and low-sensitivity features. Personalized layer that outputs highly sensitive information The client k has been granted permission to upload the parameters of the shared layer to the server, while the parameters of the personalized layer are kept private.

4. The knowledge-guided federated sentiment computing label distribution correction method according to claim 1, characterized in that: In step 4, the importance matrix of the model parameters is calculated. The importance matrix is ​​represented as follows: L( = in This represents the local model parameters of client k. The model is evaluated and the gradient is calculated using a single sample. For each parameter, the gradients of all samples are summed and finally divided by the number of samples to obtain the Fisher information matrix item for the corresponding parameter. At the end of each round of communication, each client uploads the updated shared layer parameters and the corresponding importance matrix to the server; On the server side, the importance matrix undergoes two normalization steps: self-normalization and element-wise normalization. The resulting normalized importance matrix is ​​used as the weight for each parameter: = ( · in ( Represents the normalized parameter importance matrix. This represents the globally shared layer parameters aggregated on the server side, which will be resent to each client for the next round of training.