Douzas, G., & Bacao, F. (2019). Geometric SMOTE a geometrically enhanced drop-in replacement for SMOTE. Information Sciences, 501, 118-135.
In Short
SMOTE์ data generation ํํธ๋ฅผ geometrically ํ์ฅํ oversampling ์๊ณ ๋ฆฌ์ฆ
1. Introduction
๋ฐ์ดํฐ๋ถ๊ท ํ ๋ฌธ์ ๋ ์ธ์ ๋ ์ค์ํ ๋ฌธ์ ์ด๋ค.
2. Related Work
2-1. Modifications of the selection phase
๋ฐ์ดํฐ ๋ถ๊ท ํ ๋ฌธ์ ๋ ๊ฒ ๋ ๊ฐ์ง๋ก ๋๋ ์ ์๊ฐํด๋ณผ ์ ์๋ค. ํ๋๋ between-class ๋ถ๊ท ํ, ๋๋จธ์ง ํ๋๋ within-class ๋ถ๊ท ํ์ด๋ค. ์ฌ๊ธฐ์ between-class ๋ถ๊ท ํ์ ๊ธฐ์กด์ ์ฐ๋ฆฌ๊ฐ ์๊ณ ์๋ majority์ minority์ ๊ทน๋ช ํ ๋น๋์ ์ฐจ์ด๋ฅผ ๋ปํ๋ฉฐ, within-class ๋ถ๊ท ํ์ ๊ฐ์ ํด๋์ค ์์์๋ ์ธ๋ถ ํด๋์ค๋ก ๋๋ ์ ์๋ค๋ ๊ฐ๋ฅ์ฑ์ ๋ํด ์ด์ ์ ๋ง์ถ๊ณ ์๋ค.
-
between-class ๋ถ๊ท ํ
SMOTE์ ENN(Edited Nearest Neighbor)์ ๊ฒฐํฉํSMOTE+ENN๋ชจ๋ธ์ between-class ๋ถ๊ท ํ ๋ฌธ์ ์ ์ฃผ๋ชฉํ ๋ํ์ ์ธ ๋ฐฉ๋ฒ๋ก ์ค์์ selection phase์ ๋ณํํ ๋ฐฉ๋ฒ๋ก ์ค ํ๋์ด๋ค. ์ด๋ SMOTE๋ฅผ ์ฐ์ ์งํํ ํ์, ENN์ ํตํด์ ์๋ชป ๋ถ๋ฅ๋ ์ํ๋ค์ ์ ๊ฑฐํด๋ฒ๋ฆฌ๋ ๋ฐฉ์์ด๋ค. ์ด์ธ์๋Borderline-SMOTE,MWMOTE(Majority Weighted Minority Oversampling Technique for Imbalanced Data Set Learning),ADASYN,KernelADASYN์๋ชจ๋ majority์ minority์ borderline instance๋ฅผ ๊ธฐ์ค์ผ๋ก, noisyํ ์ํ๋ค์ด ๋ง๋ค์ด์ง๋ ๊ฒ์ ์๋ฐฉํ๋ ๋ฐฉ์์ด๋ค. -
within-class ๋ถ๊ท ํ
within-class ๋ถ๊ท ํ์ ๋ค๋ฃจ๋ ์ผ๋ฐ์ ์ธ ๋ฐฉ๋ฒ์ ํด๋ฌ์คํฐ๋ง๊ณผ ์ฐ๊ด์ด ์๋ค.Cluster-SMOTE์ k-means ์๊ณ ๋ฆฌ์ฆ์ ์ ์ฉํ ๋ค์ SMOTE๋ฅผ ํ๋ค. ๊ทธ๋ฆฌ๊ณDBSMOTE์ DBSCAN์ ํ์ฉํ์ฌ ํด๋ฌ์คํฐ๋ฅผ ๋ถ๋ฅํ ๋ค, ํด๋ฌ์คํฐ ์ค์๊ฐ๊ณผ ๊ทธ๋ก๋ถํฐ ๊ฐ์ฅ ๊ฐ๊น์ด minority ์ํ์ ํ์ฉํ์ฌ ์๋ก์ด ์ํ๋ค์ ๋ง๋ค์ด๋ธ๋ค.A-SUWO์ cross validation์ ํตํด ํ์ธํ ํน์ ํ ์ฌ์ด์ฆ๋ก minority ํด๋์ค์ ํด๋ฌ์คํฐ๋ฅผ ๋ง๋ค๊ณ ๋์ ์๋ก์ด ์ํ๋ค์ ๋ง๋ค์ด๋ธ๋ค.SOMO๋ input space์ 2์ฐจ์ representation(U-matrix)๋ฅผ ๋ง๋ค๊ณ , SMOTE๋ฅผ ํตํด์ intra-cluster์ inter-cluster ์ํ๋ค์ ๋ง๋ค์ด๋ด๋ ๋ฐฉ์์ ํตํด์ manifold structure์ ๋ณด์กดํ๋ค. SOMO์ ์ ์ฌํ๊ฒ, Kmeans์ SMOTE๋ฅผ ๊ฒฐํฉํ์ฌ(SMOTE+KMeans), ํ์ธ๋ ํด๋ฌ์คํฐ์ ๋ฐ๋๋ฅผ ํ ๋๋ก ํด๋์ค ๋ถํฌ๋ฅผ re-balanceํ๋ ๋ฐฉ์๋ ์๋ค. ๋ง์ง๋ง์ผ๋ก, oversampling๋ฐฉ์๊ณผ ensemble ๋ฐฉ๋ฒ์ ๊ฒฐํฉํSMOTEBoost์DataBoost-IM๋ฑ๋ ์๋ค.
2-2. Modifications of the data generation mechanism
์์ Selection ํํธ์ ๋นํด, Data generation ํํธ๋ ์๋์ ์ผ๋ก ๋ ์ฐ๊ตฌ๊ฐ ๋ ๋ถ๋ถ์ด๋ค. Safe-Level SMOTE๋ weight degree๋ผ๋ safe level์ด๋ผ๋ ๊ฐ๋
์ ์ ์ํ์๋ค. safe level์ ํตํด์ safe level ratio๊ฐ ๊ณ์ฐ๋๋๋ฐ, line segment๋ฅผ truncateํ๋ ํจ๊ณผ๋ฅผ ์ง๋๋ค. Data Generation์์ ์์ SMOTE๊ฐ ์๋ ๋ฐฉ๋ฒ๋ ์๋๋ฐ, ๋ํ์ ์ผ๋ก๋ CGAN(Conditional GAN)์ด ์๋ค. CGAN์ input space์ local information๋ณด๋ค๋ true data distribution์ ์ง์ ์ ์ผ๋ก ๊ทผ์ฌํ๋ ๋ฐ์ ์ด์ ์ ๋ ๋ฐฉ๋ฒ์ด๋ค.
3. Motivation
-
Generation of noisy instances due to the selection of k-nearest neighbors
-
Generation of noisy examples due to the selection of an initial observation
-
Generation of nearly duplicated instances
-
Generation of noisy instances due to the use of observations from two different minority class clusters.
4. Proposed Method
G-SMOTE๋ SMOTE์์ data generation phase๋ฅผ ์์ ํ ์๊ณ ๋ฆฌ์ฆ์ด๋ค.
- To define a safe area around each selected minority class instance such that the generated artificial minority instances inside the are are not noisy.
- To increase the variety of generated samples by expanding the minority class area.
- To parameterize the above characteristics based on a small number of transformations with a geometrical interpretation.
4-1. G-SMOTE Algorithm
4-2. Functions
-
Surface
i) if\(\alpha_{sel} = \text{minority}\),\(\boldsymbol{x}_{surface} \in S_{min,k}\)
ii) if\(\alpha_{sel} = \text{majority}\),\(\boldsymbol{x}_{surface} \in S_{maj,1}\)
iii) if\(\alpha_{sel} = \text{combined}\),\(\boldsymbol{x}_{surface} = \arg\min_{\boldsymbol{x} \in (\boldsymbol{x}_{min}, \boldsymbol{x}_{maj})}(||\boldsymbol{x}_{center} - \boldsymbol{x}||)\)where\(\boldsymbol{x}_{min} \in S_{min,k}\)and\(\boldsymbol{x}_{maj} \in S_{maj,1}\)
-
Hyperball
$$\boldsymbol{x}_{gen} \leftarrow r^{1/p} \boldsymbol{e}_{sphere} \\ \text{where } \boldsymbol{e}_{sphere} \leftarrow \frac{\boldsymbol{v}_{normal}}{||\boldsymbol{v}_{normal}||} \\ \boldsymbol{v}_{normal} \leftarrow (v_1, ..., v_p) \sim N(0,1) \\ r \sim (0,1)$$
-
Vectors
$$\boldsymbol{x}_{//} \leftarrow x_{//}\boldsymbol{e}_{//} \\ \boldsymbol{x}_{\perp} \leftarrow \boldsymbol{x}_{gen} - \boldsymbol{x}_{//} \\ \text{where } \boldsymbol{e}_{//} \leftarrow \frac{\boldsymbol{x}_{surface} - \boldsymbol{x}_{center}}{||\boldsymbol{x}_{surface} - \boldsymbol{x}_{center}||} \\ x_{//} \leftarrow \boldsymbol{x}_{gen} \cdot \boldsymbol{e}_{//}$$ -
Truncate
$$\boldsymbol{x}_{gen} \leftarrow \boldsymbol{x}_{gen} - 2\boldsymbol{x}_{//} \\ \text{if } |\alpha_{trunc} - x_{//}| > 1$$
-
Deform
$$\boldsymbol{x}_{gen} \leftarrow \boldsymbol{x}_{gen} - \alpha_{def}\boldsymbol{x}_{\perp}$$
-
Translate
$$\boldsymbol{x}_{gen} \leftarrow \boldsymbol{x}_{center} + R\boldsymbol{x}_{gen}$$
4-3. Justification of the Algorithm
G-SMOTE extends the linear interpolation mechanism by introducing a geometric region where the data generation process occurs.
\(S_{gen}\)is initialized with empty.\(S_{min}\)are shuffled.\(\boldsymbol{x}_{center}\)is selected.- SMOTE์ selection ๊ณผ์ ์ ์ผ๋ฐํํ ํํธ์ด๋ค.
Surface์์\(\alpha_{sel}\)์ ๋ฐ๋ผ ์ธ ๊ฐ์ง ๊ฒฝ์ฐ์ ์๊ฐ ๋์จ๋ค. ์์ธํ ๊ฑฐ๋ ์๋ฅผ ์ฐธ๊ณ ํ๊ธธ ๋ฐ๋๋ค. Vectors์ ํด๋นํ๋ ๋ถ๋ถ์ด๋ค.
\(\boldsymbol{x}_{//}\): projection of\(\boldsymbol{x}_{gen}\)to unit vector\(\boldsymbol{e}_{//}\)
\(\boldsymbol{x}_{\perp}\): perpendicular to the same vector belonging also to the hyperplane dinfed by\(\boldsymbol{x}_{gen}\)and\(\boldsymbol{e}_{//}\)- ์ฌ๊ธฐ์๋ถํฐ data generation ๋ถ๋ถ์ด๋ค.
Hyperball์ ๋ฐ๋ผ\(\boldsymbol{e}_{sphere}\)์\(\boldsymbol{x}_{gen}\)๋ฅผ ๋ง๋ ๋ค. TruncateDeformTranslate
5. Research Methodology
5-1. Experimental Data
์ด 69๊ฐ datasets
- UCI Machine Learning Repository: 13 datasets
- KEEL repository: 13 datasets
- Simulated data based on variations of the “MANDELION” dataset: 2 datasets
- additional datasets with higher imbalance ratios
5-2. Evaluation Measures
i) Accuracy
ii) AUC
iii) F-score
iv) G-mean
5-3. Machine Learning Algorithms
๋น๊ต๋์: SMOTE, Random Oversampling, NO oversampling
๋ถ๋ฅ๊ธฐ: Logistic Regression, K-Nearest Neighbors, Decision Tree, Gradient Boosting Classifier
5-4. Experimental Procedure
5-fold cross validation
\(k \in {3,5}\)
\(\alpha_{trunc} = \{-1.0, -0.5, 0.0, 0.25, 0.5, 0.75, 1.0\}\)
\(\alpha_{def} = \{0.0, 0.2, 0.4, 0.5, 0.6, 0.8, 1.0\}\)
ํต๊ณ์ ์ผ๋ก ์ ์ํ ์ฐจ์ด๊ฐ ์๋์ง ๋ณด๊ธฐ ์ํด์ Friedman Test์ Holms Test๋ฅผ ์งํํ์๋ค. ์์ธํ ๋ด์ฉ์ ์๋ 6-2. Statistical Analysis๋ฅผ ์ฐธ๊ณ ํ๋ฉด ๋๋ค.
5-5. Software Implementation
python์์ ํด๋น ํจํค์ง๊ฐ ๊ตฌ์ถ๋์ด์๋ค.
6. Results and Discussion
6-1. Comparative Presentation
6-2. Statistical Analysis
[Table 5] Friedman Test: oversampling ๋ฐฉ์์ ๋ฐ๋ผ์ ํต๊ณ์ ์ผ๋ก ์ ์ํ ์ฐจ์ด๊ฐ ์๋์ง ํ์ธ
- ๊ฒฐ๋ก : ๋ชจ๋ ๋ถ๋ฅ๊ธฐ๋ค์ oversampling ๋ฐฉ์์ ๋ฐ๋ผ ๋ชจ๋ evaluation metric์์ ํ๊ท rank๊ฐ ๋ค๋ฅด๋ค.
[Table 6] Holms Test: G-SMOTE๋ฅผ ๊ธฐ์ค์ผ๋ก ๋ค๋ฅธ ๋ฐฉ๋ฒ๋ก ๋ค๋ณด๋ค ์ข์๋์ง ํ์ธ
- ๊ฒฐ๋ก : G-SMOTE๊ฐ ๋ค๋ฅธ oversampling ๋ฐฉ๋ฒ๋ค๋ณด๋ค ์ฑ๋ฅ์ด ์ข๋ค.
6-3. G-SMOTE taxonomy
G-SMOTE์ geometric hyperparameter: \(\alpha_{trunc}, \alpha_{def}, \alpha_{sel}\)
-
SMOTE
\(\alpha_{trunc}=1.0, \alpha_{def}=1.0, \alpha_{sel}=\text{minority}\)๋ฅผ ํ๋ฉด, ์ผ๋ฐ์ ์ธ SMOTE์ ๊ฐ๋ค. -
Modified SMOTE
\(\alpha_{def}=1.0\)์ผ๋ก ๊ณ ์ ํ๋๋ผ๋, ๋๋จธ์ง\(\alpha_{trunc}, \alpha_{sel}\)์ ๋ฐ๋ผ SMOTE๋ฅผ ์กฐ๊ธ ๋ ๋ณํ๋ ํํ๋ก ํ์ฉํ ์ ์๋ค. line segment ์์์ ์๋ก์ด synthetic example์ ๋ง๋ค์ด๋ด๋ ๊ฒ์ SMOTE์ ๊ฐ์ง๋ง,\(\alpha_{trunc}\)์\(\alpha_{sel}\)์ ์กฐํฉ์ ๋ฐ๋ผ truncated, expanded, rotated๋ฅผ ๋ง๋ค์ด๋ผ ์ ์๋ค. -
Pure G-SMOTE
\(\alpha_{trunc}\)์\(\alpha_{sel}\)์ ๋๋ถ์ด์\(\alpha_{def}\)์ ์์ ๋กญ๊ฒ ์ค์ ํ๊ฒ ๋๋ฉด, data generation area๊ฐ ์ง์ (line segment)์์ ์ด-ํ์ ํ์์ฒด(hyper-spheroid)๊ฐ ๋๋ค.
Table 7์ ํตํด์ ์ ์ ์๋ฏ์ด, ์ด 26,391๋ฒ์ ์คํ์์ Pure G-SMOTE๊ฐ ์๋์ ์ผ๋ก ๋ง์ ๋น๋์๋ก ์ฑ๋ฅ์ด ์ข์๋ค.
6-4. Analysis and Tuning of optimal hyper-parameters
-
\(\alpha_{trunc}, \alpha_{def}, \alpha_{sel}\)์ ์๋ฏธ
\(\alpha_{trunc}, \alpha_{def}, \alpha_{sel}\)์ data generation process์์ ์ํฅ์ ๋ฏธ์น๋ค. ํนํ\(\alpha_{sel}=\text{majority}\)์ ๊ฒฝ์ฐ, minority class area๋ฅผ ๊ณต๊ฒฉ์ ์ผ๋ก ํ์ฅํ๊ฒ ๋๋ฉฐ,\(\alpha_{trunc}\)์\(\alpha_{def}\)์ ์ ๋๊ฐ์ ๋ฎ์ ์ซ์๋ก ์ค์ ํ ์๋ก ๋๋์ฑ ๊ทธ๋ฌํ ํจ๊ณผ๋ฅผ ํฌ๊ฒ ๋ณผ ์ ์๋ค. -
IR ๋๋ R๊ณผ geometric hyperparameter ๊ฐ์ ๊ด๊ณ
์ฌ๊ธฐ์ IR์ Imbalance Ratio, R์ ๋ณ์ ์ ๋๋น ์ํ ์๋ฅผ ์๋ฏธํ๋ค.
i) High IR or Low R
majority ๋๋ combined, ๊ทธ๋ฆฌ๊ณ ๋ฎ์ ์ ๋๊ฐ์ truncation, deformation hyperparameter๊ฐ ๋ ์ข์ ์ฑ๋ฅ์ ๋ณด์๋ค. ๋ถ๊ท ํ๋๊ฐ ๋์ ๊ฒฝ์ฐ์๋ ์ผ๋ฐ SMOTE๋ ๊ธฐ์กด์ ๋ฐ์ดํฐ์ ๊ฑฐ์ ์ ์ฌํ ๋๋ noisy ์ํ๋ค์ ๋ง๋ค์ด๋ธ ๊ฒ์ผ๋ก ๋ณด์ธ๋ค. ๋ํ, R์ด ๋ฎ์ ๊ฒฝ์ฐ(sparse input space)์๋ ์ผ๋ฐ SMOTE์ ๊ธฐ๋ณธ linear interpolation ๊ณผ์ ์ด ํน์ ๋ฐฉํฅ์ input space์์๋ง ์ํ๋ค ๋ง๋ค์ด๋ด์ด ๊ธฐ์กด ๋ฐ์ดํฐ์ ์ ์ฌํ๊ฑฐ๋ noisyํ ์ํ๋ค์ ๋ง๋ค์ด๋ธ ๊ฒ์ผ๋ก ํด์ํ ์ ์๋ค.
ii) Low IR or High R
minority, ๊ทธ๋ฆฌ๊ณ ๋์ ์ ๋๊ฐ์ truncation, deformation hyperparameter๊ฐ ์๋์ ์ผ๋ก ์ฐ์ํ ์ฑ๋ฅ์ ๋ณด์๋ค. ๋ถ๊ท ํ๋๊ฐ ๋ฎ๊ฑฐ๋ R์ด ํฐ ๊ฒฝ์ฐ์๋ input space๊ฐ ์ด๋ฏธ ์ถฉ๋ถํ ์ ๋ณด๋ฅผ ๊ฐ์ง๊ณ ์์ด์ SMOTE์ ๋จ์ ์ ๊ทน๋ณตํ ์ ์์๋ ๊ฒ์ผ๋ก ํด์ํด๋ณผ ์ ์๋ค.
7. Conclusions
์ ๋ฆฌํ์๋ฉด, G-SMOTE๋ minority class area ๊ทผ์ฒ์์ safe radius๋ฅผ ์ ํ๊ณ ์์ ํ ์ด-ํ์ ํ์์ฒด ๋ด์์ ์ถ๊ฐ์ ์ธ ์ํ๋ค์ ๋ง๋ค์ด๋ด๋ ๋ฐฉ์์ด๋ค. ์ ์ ์์ hyperparameter๋ฅผ ์กฐ์ ํด์ฃผ๊ธฐ๋ง ํด๋ ํ๋ฆฌํฐ ์ข์ ์ํ๋ค์ ๋ง๋ค์ด๋ผ ์ ์๋ค๋ ์ธก๋ฉด์์ G-SMOTE๋ ์ด์ ๋ณด๋ค ๋ฐ์ ํ๋ค๊ณ ํ ์ ์๋ค.
—
MY OWN OPINION
-
Oversampling ๊ณผ์ ์ ์์ด์ Selection phase์ ๋นํด ์๋์ ์ผ๋ก ๋ ์ฐ๊ตฌ๊ฐ ๋ Data Generation phase์์ ์ ์ ํ ๋ ผ๋ฌธ์ธ ๊ฒ ๊ฐ๋ค.
-
๊ฐ์ ์ฐ๊ตฌ์ค์ ๊ณ์ ๋ฐ์ฌ๋๊ป์๋ AR-SMOTE(Angle-Rotated SMOTE) ์ฐ๊ตฌ๋ ํ์๊ณ ํ๋ ๊ฒ์ผ๋ก ๋ฏธ๋ฃจ์ด๋ณด์, ๊ต์ฅํ ๊ด์ฐฎ์ ์ฐ๊ตฌ๋ฐฉํฅ์ด๋ผ๊ณ ์๊ฐ๋๋ค.
-
Geometric SMOTE for Regression ๋ ผ๋ฌธ๋ ์๋๋ฐ, ์ผ๋ฅธ ์ฝ์ด๋ด์ผ๊ฒ ๋ค. Classification๊ณผ ๋ฌ๋ฆฌ Regression์์๋ y๋ฅผ ๋ง๋ค์ด๋ด๋ ๊ณผ์ ๋ ๊ต์ฅํ ์ค์ํ ๊ฒ ๊ฐ์๋ฐ, ์ด๋ฌํ ๋ถ๋ถ์ ํนํ ๋ ์ฃผ๋ชฉํด์ ๋ณด์์ผ๊ฒ ๋ค.
-
IR(๋ถ๊ท ํ๋)๋ง ๋ณด๋ ๊ฒ์ด ์๋๋ผ R(๋ณ์์ ๋๋น ์ํ์)๋ฅผ ๊ธฐ์ค์ผ๋ก๋ ์ฌํ๋ถ์์ ํด๋ณผ ํ์๊ฐ ์๋ค๋ ๊ฒ์ ๋ฐฐ์ ๋ค.
-
G-SMOTE์ ๋ณ๊ฐ๋ก, Related Works๋ฅผ ์ฝ๋ค๋ณด๋ within-class ๋ถ๊ท ํ์ ์ฃผ๋ชฉํ๊ณ manifold structure๋ฅผ ๋ณด์กดํ๊ณ ์ ํ๋
SOMO๋ผ๋ ๋ ผ๋ฌธ์ ์๊ฒ ๋์๋ค.