# An Ensemble Model for Multi-Level Speech Emotion Recognition
## 3 Proposed Method
### Design of Ensemble Learning Model  
For the speech emotion recognition task, 3 experts were designed from different angles. Each expert has a different emphasis. Designing an ensemble learning model is equivalent to completing an emotional vote by multiple experts. Using the existing training modules and 5-fold cross-validation, each time the training data are randomly divided into 5 groups, and one group of data is extracted for testing and the remaining samples are used for training; a total of m times are extracted, and a plurality of sampling sets for training are obtained. Since the verification result for the training set can be obtained for each training, the values of WA and UA can be obtained each time, and the following formula is obtained:  
\[UA_{j}=\frac{1}{n}\sum_{i=0}^{\exp}\sum_{j=0}^{m}UA_{ii} \tag{4}\]  
\[UA_{-}\exp_{i}=\frac{1}{\exp}i\sum_{j=0}^{i}UA_{j} \tag{5}\]  
\[1=\sum_{i=i}^{\exp}W_{\exp i}UA_{-}\exp_{i} \tag{6}\]  
where \(\exp_{i}\) (\(i=1\), 2, \(\exp\)) is the number of experts in each category, \(\exp\) is the number of expert categories, \(n\) is the number of emotion classes, \(UA_{ii}\) is the UA of each expert under each category, \(UA_{j}\) represents the average UA of each expert, \(UA_{-}\exp_{i}\) is the average UA of each type of expert, and \(W_{\exp i}\) is calculated by normalizing the UA, which represents the confidence of each category of experts. For 3 experts to re-rank, \(W_{\exp i}\) is sorted by numerical value, \(W_{\exp 1}\) has the highest accuracy, and \(W_{\exp 3}\) has the lowest accuracy. Since the spectrogram of expert 1 is susceptible to the surrounding environment and noise during application, its effect is usually the worst. To improve the overall efficiency, it is necessary to carry out multiple binary classifications. \(W_{\exp 31}\) and \(W_{\exp 32}\) represent the results of the second binary classification of the expert where \(W_{\exp 3}\) belonged. The overall ensemble learning program is as follows:  
1. In the 4-category task, if the opinions of the experts to which \(W_{\exp 1}\) and \(W_{\exp 2}\) belong are the same, the result of the expert to which \(W_{\exp 1}\) belongs is the final result. 2. In the 2-category task, the opinions of the experts to which \(W_{\exp 1}\) and \(W_{\exp 2}\) belong are consistent. In the 4-category task, the expert opinions of \(W_{\exp 1}\) and \(W_{\exp 2}\) belong to the opposite, and the classification of the value of \(\max(W_{\exp 1i}+W_{\exp 3i},W_{\exp 2j}+W_{\exp 3j})\) is the final result, where \(i\) and \(j\) represent the views of the experts to which \(W_{\exp 1}\) and \(W_{\exp 2}\) belong, respectively. 3. In the 2-category task, the opinions of the experts to which \(W_{\exp 1}\) and \(W_{\exp 2}\) belong are inconsistent. At this point, it is necessary to observe the expert opinion of \(W_{\exp 3}\), judge the first 2 experts to find the expert with the same result as the first classification of the \(W_{\exp 3}\) expert, and use its result as the final result. By traversing the results of each expert for each piece of data, the above-mentioned schemes are used to judge, and the results predicted by the integration experts are obtained. For the more balanced samples of each type of collection, the above method can quickly obtain the ensemble learning results of the experts. If the sample data distribution is skewed or the recognition rate of a certain category is too high or too low, there will be some errors in the results obtained. At this point, the emotional classification of the expert to which \(W_{\exp 3}\) belongs can be further refined, by performing the second classification to eliminate the negative impact of certain emotional accuracy when it is not credible. The above is the first scheme of the ensemble learning.