Rethinking Representation Geometry in Supervised Contrastive Learning under Long-Tailed Data
Organizations: Department of Statistics and Data Science, Yonsei University
Abstract
Supervised contrastive learning and its balanced variants have demonstrated their effectiveness for representation learning under long-tailed distributions. However, although prior analyses suggest that their optimal representations may exhibit a regular simplex geometry, whether such a geometry is indeed exhibited remains insufficiently understood. In this work, we present a theoretical framework for these objectives that characterizes whether a regular simplex is formed at the optimum. By applying this to representative objectives, we show that these objectives fail to form a regular simplex at the optimum because they remain dependent on the number of samples per class. Motivated by this analysis, we introduce structural balancing that can be applied to contrastive objectives, and propose a fully balanced contrastive objective that provably forms a regular simplex geometry at its optimum. Both theoretical and empirical results demonstrate that the proposed method yields a more balanced representation space and improves performance on long-tailed recognition and transfer learning tasks.
Figures & tables
| Method | ImageNet-LT | iNaturalist | ||||||
|---|---|---|---|---|---|---|---|---|
| Many | Medium | Few | All | Many | Medium | Few | All | |
| OLTR ( Liu et al., 2019 ) | 43.2 | 35.1 | 18.5 | 35.6 | 59.0 | 64.1 | 64.9 | 63.9 |
| -norm ( Kang et al., 2020 ) | 56.6 | 44.2 | 27.4 | 46.7 | 65.6 | 65.3 | 65.9 | 65.6 |
| cRT ( Kang et al., 2020 ) | 58.8 | 44.0 | 26.1 | 47.3 | 69.0 | 71.1 | 70.2 | 70.6 |
| PaCo ∗ ( Cui et al., 2021 ) | 55.3 | 50.2 | 26.7 | 48.9 | 60.2 | 67.7 | 68.5 | 67.2 |
| GPaCo ∗ ( Cui et al., 2023 ) | 59.4 | 53.4 | 30.5 | 52.6 | 65.6 | 72.2 | 72.0 | 71.4 |
| Method | ImageNet-LT | |||
|---|---|---|---|---|
| Many | Medium | Few | All | |
| SimCLR ( Chen et al., 2020 ) | 65.0 | 52.6 | 36.2 | 55.2 0.2 |
| SCL ( Khosla et al., 2020 ) | 65.8 | 53.3 | 36.1 | 55.8 0.4 |
| BCL ( Zhu et al., 2022 ) | 65.8 | 53.7 | 36.2 | 56.0 0.1 |
| FBCL (Ours) | 66.4 | 54.1 | 37.5 | 56.6 0.1 |
Appendix figures & tables13 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | # of classes | Training | Validation | Test | Metric |
|---|---|---|---|---|---|
| CIFAR-10 | 10 | 45000 | 5000 | 10000 | Top-1 accuracy |
| CIFAR-100 | 100 | 45000 | 5000 | 10000 | Top-1 accuracy |
| MIT67 | 67 | 4690 | 670 | 1340 | Top-1 accuracy |
| DTD (split1) | 47 | 1880 | 1880 | 1880 | Top-1 accuracy |
| CUB200 | 200 | 4994 | 1000 | 5794 | Top-1 accuracy |
| Food | 101 | 68175 | 7575 | 25250 | Top-1 accuracy |
| Method | ImageNet-LT | iNaturalist | ||||||
|---|---|---|---|---|---|---|---|---|
| Many | Medium | Few | All | Many | Medium | Few | All | |
| SimCLR ( Chen et al., 2020 ) | 65.0 0.1 | 52.6 0.2 | 36.2 0.1 | 55.2 0.2 | 68.1 0.3 | 70.7 0.2 | 69.9 0.3 | 70.1 0.2 |
| SCL ( Khosla et al., 2020 ) | 65.8 0.4 | 53.3 0.4 | 36.1 0.5 | 55.8 0.4 | 68.4 0.3 | 71.1 0.4 | 70.2 0.5 | 70.4 0.3 |
| BCL ( Zhu et al., 2022 ) | 65.8 0.2 | 53.7 0.2 | 36.2 0.1 | 56.0 0.1 | 70.0 0.7 | 72.0 0.4 | 71.1 0.2 | 71.3 0.6 |
| FBCL (Ours) | 66.4 0.2 | 54.1 0.2 | 37.5 0.4 | 56.6 0.1 | 70.4 0.3 | 72.8 0.2 | 71.9 0.3 | 72.2 0.1 |
| Method | Many | Medium | Few | Acc |
|---|---|---|---|---|
| CE | 0.02 | 0.03 | 0.03 | 0.16 |
| SCL | 0.01 | 0.02 | 0.05 | 2.74 |
| BCL | 0.02 | 0.03 | 0.07 | 2.36 |
| FBCL (Ours) | 0.02 | 0.02 | 0.03 | 3.10 |
| Method | PB | NB | SB | Intra-class variance | Acc. | ||
| Many | Medium | Few | |||||
| PB (SCL) | ✓ | ✗ | ✗ | 0.211 0.001 | 0.342 0.003 | 0.420 0.001 | 51.5 0.18 |
| PB+NB (BCL) | ✓ | ✓ | ✗ | 0.210 0.005 | 0.382 0.004 | 0.465 0.011 | 51.7 0.45 |
| PB+SB | ✓ | ✗ | ✓ | 0.340 0.004 | 0.387 0.002 | 0.467 0.003 | 51.5 0.25 |
| NB+SB | ✗ | ✓ | ✓ | 0.660 0.009 | 0.620 0.006 | 0.601 0.009 | 51.4 0.16 |
| PB+NB+SB (Ours) | ✓ | ✓ | ✓ | 0.267 0.003 | 0.320 0.006 | 0.379 0.003 | 52.1 0.15 |
| Method | PB | NB | SB | Intra-class variance | Acc. | |||||
| Many | Medium | Few | Many | Medium | Few | All | ||||
| PB (SCL) | ✓ | ✗ | ✗ | 0.189 0.001 | 0.298 0.003 | 0.357 0.001 | 65.76 0.38 | 53.33 0.40 | 36.13 0.46 | 55.78 0.41 |
| PB+NB (BCL) | ✓ | ✓ | ✗ | 0.167 0.021 | 0.293 0.003 | 0.362 0.006 | 65.83 0.15 | 53.74 0.17 | 36.23 0.06 | 56.03 0.07 |
| PB+SB | ✓ | ✗ | ✓ | 0.368 0.004 | 0.502 0.003 | 0.509 0.003 | 66.07 0.12 | 53.40 0.30 | 36.22 0.36 | 55.92 0.19 |
| NB+SB | ✗ | ✓ | ✓ | 0.597 0.002 | 0.623 0.002 | 0.602 0.001 | 65.20 0.20 | 53.03 0.29 | 35.47 0.32 | 55.35 0.17 |
| PB+NB+SB (Ours) | ✓ | ✓ | ✓ | 0.196 0.008 | 0.281 0.010 | 0.339 0.008 | 66.44 0.15 | 54.12 0.21 | 37.50 0.40 | 56.64 0.12 |
| Method | ImageNet-LT | iNaturalist | ||||||
|---|---|---|---|---|---|---|---|---|
| Many | Medium | Few | All | Many | Medium | Few | All | |
| DBM+BCL | 64.4 0.1 | 54.3 0.2 | 41.4 0.3 | 56.5 0.2 | 66.3 0.3 | 71.8 0.5 | 73.3 0.3 | 71.8 0.1 |
| DBM+FBCL (Ours) | 64.9 0.2 | 54.5 0.2 | 42.3 0.3 | 56.9 0.2 | 66.5 0.2 | 72.4 0.4 | 73.8 0.2 | 72.3 0.2 |
| Method | ImageNet-LT | iNaturalist | ||||||
|---|---|---|---|---|---|---|---|---|
| Many | Medium | Few | All | Many | Medium | Few | All | |
| ProCo | 66.5 0.1 | 54.8 0.5 | 38.1 0.4 | 57.1 0.2 | 70.4 0.4 | 73.1 0.1 | 71.9 0.6 | 72.3 0.2 |
| ProCo + SB (Ours) | 66.8 0.2 | 55.2 0.1 | 38.8 0.2 | 57.4 0.1 | 70.7 0.6 | 73.4 0.4 | 72.3 0.4 | 72.7 0.5 |
| Method | CIFAR-100-LT | ||
|---|---|---|---|
| IR=100 | IR=50 | IR=10 | |
| BCL | |||
| FBCL | (+0.4) | (+0.3) | (+0.3) |
| DBM + BCL | |||
| DBM + FBCL | (+0.8) | (+0.3) | (+0.1) |
| LLM-AutoDA + BCL | |||
| CIFAR-100-LT | |||
| Imbalance Factor | 100 | 50 | 10 |
| Top-1 accuracy | |||
| ProCo | |||
| ProCo + SB | |||
| Few-class accuracy | |||
| ProCo | 32.1 0.6 | 43.2 0.7 | - |
| Method | ImageNet-LT | |||
|---|---|---|---|---|
| Many ( ) | Medium ( ) | Few ( ) | All ( ) | |
| BCL | 0.154 0.003 | 0.106 0.004 | 0.104 0.005 | 0.124 0.004 |
| FBCL | 0.137 0.001 | 0.088 0.002 | 0.079 0.005 | 0.103 0.002 |
| Method | CIFAR-100-LT (IR=100) | |||
|---|---|---|---|---|
| Many | Medium | Few | Overall | |
| BCL | 66.04 0.55 | 52.57 0.49 | 33.78 1.04 | 51.65 0.45 |
| BCL + CB Sampling | 51.32 0.25 | 56.63 0.38 | 30.17 1.60 | 46.84 0.39 |
| BCL + Re-weighting | 65.51 1.01 | 52.69 0.54 | 33.56 0.98 | 51.45 0.45 |
| SCL + CB-weighting | 64.84 0.80 | 51.44 0.52 | 33.14 0.64 | 50.65 0.27 |
| BCL + CB-weighting | 64.77 0.59 | 51.46 0.85 | 33.02 0.03 | 50.59 0.49 |
Contrastive Learning
Contrastive learning trains representations by bringing related examples together and separating unrelated ones for recognition, retrieval, and transfer.
See all 318 papers