Modeling Uncertain Feature Representation for Domain Generalization

Xiaotong Li, Zixuan Hu, Jun Liu, Yixiao Ge, Yongxing Dai +1 more
1/16/2023
cs.CVcs.LG

Official code: lixiaotong97/DSU (165 stars, last commit 2022-03-27).

Abstract

Though deep neural networks have achieved impressive success on various vision tasks, obvious performance degradation still exists when models are tested in out-of-distribution scenarios. In addressing this limitation, we ponder that the feature statistics (mean and standard deviation), which carry the domain characteristics of the training data, can be properly manipulated to improve the generalization ability of deep learning models. Existing methods commonly consider feature statistics as deterministic values measured from the learned features and do not explicitly model the uncertain statistics discrepancy caused by potential domain shifts during testing. In this paper, we improve the network generalization ability by modeling domain shifts with uncertainty (DSU), i.e., characterizing the feature statistics as uncertain distributions during training. Specifically, we hypothesize that the feature statistic, after considering the potential uncertainties, follows a multivariate Gaussian distribution. During inference, we propose an instance-wise adaptation strategy that can adaptively deal with the unforeseeable shift and further enhance the generalization ability of the trained model with negligible additional cost. We also conduct theoretical analysis on the aspects of generalization error bound and the implicit regularization effect, showing the efficacy of our method. Extensive experiments demonstrate that our method consistently improves the network generalization ability on multiple vision tasks, including image classification, semantic segmentation, instance retrieval, and pose estimation. Our methods are simple yet effective and can be readily integrated into networks without additional trainable parameters or loss constraints. Code will be released in https://github.com/lixiaotong97/DSU.

View on arXivView PDF

Code Implementations(1)

lixiaotong97/DSUOfficial100%

[ICLR 2022] Official pytorch implementation of "Uncertainty Modeling for Out-of-Distribution Generalization" in International Conference on Learning Representations (ICLR) 2022.

16517Shell, PythonFeb 8, 20224 years ago
domain-generalizationiclr2022out-of-distribution

Similar Papers

Cite this paper

@article{li2023modeling,
  title  = {Modeling Uncertain Feature Representation for Domain Generalization},
  author = {Xiaotong Li and Zixuan Hu and Jun Liu and Yixiao Ge and Yongxing Dai and Ling-Yu Duan},
  year   = {2023},
  eprint = {2301.06442},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2301.06442v1}
}

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/2301.06442.svg)](https://codeofpaper.com/paper/2301.06442)

Discussion