BackMix: Regularizing Open Set Recognition by Removing Underlying Fore-Background Priors

Yu Wang, Junxian Mu, Hongzhi Huang, Qilong Wang, Pengfei Zhu +1 more
3/22/2025
cs.CV

Official code: Vanixxz/BackMix (16 stars, last commit 2025-04-23).

Abstract

Open set recognition (OSR) requires models to classify known samples while detecting unknown samples for real-world applications. Existing studies show impressive progress using unknown samples from auxiliary datasets to regularize OSR models, but they have proved to be sensitive to selecting such known outliers. In this paper, we discuss the aforementioned problem from a new perspective: Can we regularize OSR models without elaborately selecting auxiliary known outliers? We first empirically and theoretically explore the role of foregrounds and backgrounds in open set recognition and disclose that: 1) backgrounds that correlate with foregrounds would mislead the model and cause failures when encounters 'partially' known images; 2) Backgrounds unrelated to foregrounds can serve as auxiliary known outliers and provide regularization via global average pooling. Based on the above insights, we propose a new method, Background Mix (BackMix), that mixes the foreground of an image with different backgrounds to remove the underlying fore-background priors. Specifically, BackMix first estimates the foreground with class activation maps (CAMs), then randomly replaces image patches with backgrounds from other images to obtain mixed images for training. With backgrounds de-correlated from foregrounds, the open set recognition performance is significantly improved. The proposed method is quite simple to implement, requires no extra operation for inferences, and can be seamlessly integrated into almost all of the existing frameworks. The code is released on https://github.com/Vanixxz/BackMix.

View on arXivView PDF

Code Implementations(1)

Vanixxz/BackMixOfficial100%

[TPAMI2025] BackMix: Regularizing Open Set Recognition by Removing Underlying Fore-Background Priors

160PythonFeb 27, 20251 years ago
classificationdata-augmentationopen-set-recognition

Similar Papers

Cite this paper

@article{wang2025backmix,
  title  = {BackMix: Regularizing Open Set Recognition by Removing Underlying Fore-Background Priors},
  author = {Yu Wang and Junxian Mu and Hongzhi Huang and Qilong Wang and Pengfei Zhu and Qinghua Hu},
  year   = {2025},
  eprint = {2503.17717},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2503.17717v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2503.17717.svg)](https://codeofpaper.com/paper/2503.17717)

Discussion