Skip to main content

Decoupled Contrastive Learning for Long-Tailed Distribution

  • Conference paper
  • First Online:
Pattern Recognition and Computer Vision (PRCV 2023)

Abstract

Self-supervised contrastive learning is popularly used to obtain powerful representation models. However, unlabeled data in the real world naturally exhibits a long-tailed distribution, making the traditional instance-wise contrastive learning unfair to tail samples. Recently, some improvements have been made from the perspective of model, loss, and data to make tail samples highly evaluated during training, but most of them explicitly or implicitly assume that the sample with a large loss is the tail. We argue that due to the lack of hard negatives, tail samples usually occupy a small loss at the initial stage of training, which will make them eliminated at the beginning of training. To address this issue, we propose a simple but effective two-stage learning scheme that decouples traditional contrastive learning to discover and enhance tail samples. Specifically, we identify the sample with a small loss in Stage I while a large loss in Stage II as the tail. With the discovered tail samples, we generate hard negatives for them based on their neighbors, which will balance the distribution of the hard negatives in training and help learn better representation. Additionally, we design the weight inversely proportional or proportional to the loss in each stage to achieve fairer training by reweighting. Extensive experiments on multiple unlabeled long-tailed datasets demonstrate the superiority of our DCL compared with the state-of-the-art methods. The code will be released soon.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 59.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 79.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

  1. Cao, K., Wei, C., Gaidon, A., Arechiga, N., Ma, T.: Learning imbalanced datasets with label-distribution-aware margin loss. In: NeurIPS (2019)

    Google Scholar 

  2. Chen, T., Kornblith, S., Norouzi, M., Hinton, G.: A simple framework for contrastive learning of visual representations. In: ICML, pp. 1597–1607 (2020)

    Google Scholar 

  3. Chen, X., et al.: Area: adaptive reweighting via effective area for long-tailed classification. In: ICCV (2023)

    Google Scholar 

  4. Chen, X., et al.: Imagine by reasoning: a reasoning-based implicit semantic data augmentation for long-tailed classification. In: AAAI, pp. 356–364 (2022)

    Google Scholar 

  5. Cubuk, E.D., Zoph, B., Shlens, J., Le, Q.V.: Randaugment: practical automated data augmentation with a reduced search space. In: CVPR, pp. 702–703 (2020)

    Google Scholar 

  6. Cui, J., Zhong, Z., Liu, S., Yu, B., Jia, J.: Parametric contrastive learning. In: ICCV, pp. 715–724 (2021)

    Google Scholar 

  7. Cui, Y., Jia, M., Lin, T.Y., Song, Y., Belongie, S.: Class-balanced loss based on effective number of samples. In: CVPR, pp. 9268–9277 (2019)

    Google Scholar 

  8. Deng, J., Dong, W., Socher, R., Li, L.J., Li, K., Fei-Fei, L.: Imagenet: a large-scale hierarchical image database. In: CVPR, pp. 248–255 (2009)

    Google Scholar 

  9. Doersch, C., Gupta, A., Efros, A.A.: Unsupervised visual representation learning by context prediction. In: ICCV, pp. 1422–1430 (2015)

    Google Scholar 

  10. Hao, X., Zhang, W., Wu, D., Zhu, F., Li, B.: Dual alignment unsupervised domain adaptation for video-text retrieval. In: CVPR, pp. 18962–18972 (2023)

    Google Scholar 

  11. He, K., Fan, H., Wu, Y., Xie, S., Girshick, R.: Momentum contrast for unsupervised visual representation learning. In: CVPR, pp. 9729–9738 (2020)

    Google Scholar 

  12. He, K., Zhang, X., Ren, S., Sun, J.: Deep residual learning for image recognition. In: CVPR, pp. 770–778 (2016)

    Google Scholar 

  13. Jiang, Z., Chen, T., Mortazavi, B.J., Wang, Z.: Self-damaging contrastive learning. In: ICML, pp. 4927–4939 (2021)

    Google Scholar 

  14. Kalantidis, Y., Sariyildiz, M.B., Pion, N., Weinzaepfel, P., Larlus, D.: Hard negative mixing for contrastive learning. In: NeurIPS, pp. 21798–21809 (2020)

    Google Scholar 

  15. Kang, B., Li, Y., Xie, S., Yuan, Z., Feng, J.: Exploring balanced feature spaces for representation learning. In: ICLR (2020)

    Google Scholar 

  16. Kang, B., et al.: Decoupling representation and classifier for long-tailed recognition. In: ICLR (2020)

    Google Scholar 

  17. Khosla, P., et al.: Supervised contrastive learning. In: NeurIPS (2020)

    Google Scholar 

  18. Li, T., et al.: Targeted supervised contrastive learning for long-tailed recognition. In: CVPR, pp. 6918–6928 (2022)

    Google Scholar 

  19. Lin, T.Y., Goyal, P., Girshick, R., He, K., Dollár, P.: Focal loss for dense object detection. In: Proceedings of the IEEEICCV, pp. 2980–2988 (2017)

    Google Scholar 

  20. Lin, T.-Y., et al.: Microsoft COCO: common objects in context. In: Fleet, D., Pajdla, T., Schiele, B., Tuytelaars, T. (eds.) ECCV 2014. LNCS, vol. 8693, pp. 740–755. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-10602-1_48

    Chapter  Google Scholar 

  21. Liu, H., HaoChen, J.Z., Gaidon, A., Ma, T.: Self-supervised learning is more robust to dataset imbalance. In: ICLR (2022)

    Google Scholar 

  22. Liu, Z., Miao, Z., Zhan, X., Wang, J., Gong, B., Yu, S.X.: Large-scale long-tailed recognition in an open world. In: CVPR, pp. 2537–2546 (2019)

    Google Scholar 

  23. Sinha, S., Ohashi, H.: Difficulty-net: learning to predict difficulty for long-tailed recognition. In: WACV, pp. 6433–6442 (2023)

    Google Scholar 

  24. Tian, Y., Henaff, O.J., van den Oord, A.: Divide and contrast: self-supervised learning from uncurated data. In: ICCV, pp. 10063–10074 (2021)

    Google Scholar 

  25. Wang, P., Han, K., Wei, X., Zhang, L., Wang, L.: Contrastive learning based hybrid networks for long-tailed image classification. In: CVPR, pp. 943–952 (2021)

    Google Scholar 

  26. Wu, D., Dai, Q., Liu, J., Li, B., Wang, W.: Deep incremental hashing network for efficient image retrieval. In: CVPR, pp. 9069–9077 (2019)

    Google Scholar 

  27. Xie, S., Girshick, R.B., Dollár, P., Tu, Z., He, K.: Aggregated residual transformations for deep neural networks. In: CVPR, pp. 5987–5995 (2017)

    Google Scholar 

  28. Yang, Z., Wu, D., Zhang, W., Li, B., Wang, W.: Handling label uncertainty for camera incremental person re-identification. In: MM (2023)

    Google Scholar 

  29. You, Y., Chen, T., Sui, Y., Chen, T., Wang, Z., Shen, Y.: Graph contrastive learning with augmentations. In: NeurIPS, pp. 5812–5823 (2020)

    Google Scholar 

  30. Zhang, H., Cisse, M., Dauphin, Y.N., Lopez-Paz, D.: mixup: beyond empirical risk minimization. In: ICLR (2018)

    Google Scholar 

  31. Zhang, W., Wu, D., Zhou, Y., Li, B., Wang, W., Meng, D.: Binary neural network hashing for image retrieval. In: SIGIR, pp. 317–326 (2021)

    Google Scholar 

  32. Zhao, S., Wu, D., Zhang, W., Zhou, Y., Li, B., Wang, W.: Asymmetric deep hashing for efficient hash code compression. In: MM, pp. 763–771 (2020)

    Google Scholar 

  33. Zhao, S., Wu, D., Zhou, Y., Li, B., Wang, W.: Rescuing deep hashing from dead bits problem. In: IJCAI, pp. 1338–1344 (2021)

    Google Scholar 

  34. Zhou, Z., Yao, J., Wang, Y.F., Han, B., Zhang, Y.: Contrastive learning with boosted memorization. In: ICML, pp. 27367–27377 (2022)

    Google Scholar 

  35. Zhu, J., Wang, Z., Chen, J., Chen, Y.P., Jiang, Y.: Balanced contrastive learning for long-tailed visual recognition. In: CVPR, pp. 6898–6907 (2022)

    Google Scholar 

Download references

Acknowledgements

This work was supported by the National Natural Science Foundation of China under Grants 62006221, 62106258, 62006242, 62202459 and 61925602, the National Key R&D Program of China under Grant 2022YFB31 03500, the Grant No. XDC02050200, the China Postdoctoral Science Foundation under Grant 2022M713348 and 2022TQ0363, and Young Elite Scientists Sponsorship Program by BAST (No. BYESS2023304).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Yucan Zhou .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2024 The Author(s), under exclusive license to Springer Nature Singapore Pte Ltd.

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Chen, X. et al. (2024). Decoupled Contrastive Learning for Long-Tailed Distribution. In: Liu, Q., et al. Pattern Recognition and Computer Vision. PRCV 2023. Lecture Notes in Computer Science, vol 14433. Springer, Singapore. https://doi.org/10.1007/978-981-99-8546-3_1

Download citation

  • DOI: https://doi.org/10.1007/978-981-99-8546-3_1

  • Published:

  • Publisher Name: Springer, Singapore

  • Print ISBN: 978-981-99-8545-6

  • Online ISBN: 978-981-99-8546-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics