## 3 MWMOTE-FRIS-INFFC
### Preliminaries  
#### 3.1.1 Majority Weighted Minority Oversampling Technique (MWMOTE)  
To solve the problem of unbalanced samples, [PERSON] et al. [13] designed a new minority oversampling algorithm (MWMOTE), which improved the way of selecting minority samples and generating samples, mainly in the following three stages: the first stage is to first identify the data in the original data set, build a new subset after finding a few class samples, continue to find samples that are difficult to learn in the new subset, and complete the construction of the set Si (min). The second stage is to assign weight Sw based on data importance in the new subset. The third stage is to use synthetic oversampling technology to synthesize new samples in Si (min) and add them to get a new output sample set Sout (min). The specific algorithm steps are shown as Algorithm 1.  
```
Input: Minority sample and majority sample (S\({}_{\text{min}}\) and S\({}_{\text{maj}}\)) Procedure:
```  
(1) The total number of samples of a few classes is recorded as S\({}_{\text{min}}\); Calculate k\({}_{1}\) neighbors of each sample belonging to minority class S\({}_{\text{min}}\) based on Euclidean distance, where the minority class is denoted as NN (x\({}_{i}\)).  
(2) If NN (x\({}_{i}\)) = 0 means that k\({}_{1}\) neighbors near the i minority sample have no minority sample, the sample is a noise sample; S\({}_{\text{minf}}\) is used to represent the number of S\({}_{\text{min}}\) samples left after removing the noise sample.  
(3) For each sample belonging to the minority class S\({}_{\text{minf}}\), calculate its k\({}_{2}\) neighbors belonging to the majority class according to the Euclidean distance, denoted as N\({}_{\text{maj}}\) (x\({}_{i}\)).  
(4) Combine the results of (3) to get most class boundary data sets, denoted as S\({}_{\text{bmaj}}\);  
(5) For each sample belonging to S\({}_{\text{bmaj}}\), calculate its k3 neighbors belonging to the minority class according to Euclidean distance, which are denoted as N\({}_{\text{min}}\) (y\({}_{i}\)).  
(6) Combine the results of (5) to get a few class information sets, which are denoted as S\({}_{\text{min}}\).  
(7) For each sample belonging to S\({}_{\text{imin}}\), the information weight Iw (y\({}_{i}\), x\({}_{i}\)) is calculated according to the location distance and density factors of the sample. The closer the sample is to most types of samples, the lower the density will be, making it easier to draw.  
(8) The step is equivalent to the normalization step, dividing the current information weight by the total information weight to get the selection weight of each xi, that is, the probability of being selected to synthesize new samples.  
Cluster S\({}_{\text{min}}\) into M clusters, draw samples from S\({}_{\text{imin}}\) according to probability, and then randomly select samples from M clusters for interpolation of the SMOTE formula; repeat (9) until the desired number is satisfied.  
end Output: The oversampled minority sets.  
The primary advantage of this algorithm lies in its capacity to precisely select a limited set of class samples suitable for learning. Additionally, its proficiency in allocating weights to samples and clusters is noteworthy. The newly created minority class samples, by virtue of this algorithm, largely ensure that the synthesized samples mitigate both inter-class and intra-class imbalances. Notably, the algorithm does not broaden the range of certain class samples during the weight computation process, thus preserving the convergence speed and preventing overfitting. However, a significant limitation of this algorithm is its struggle with data noise, particularly weak and false noise. During the generation of class samples, there is a propensity to interpolate more of these undesirable noise types, necessitating the adjustment of various algorithm parameters for different data types, which introduces a considerable workload. Consequently, optimization efforts may be directed towards both noise processing and the noise introduced in newly generated samples.