Domain adaptive detection aims to improve the generalization of detectors on target domain. To reduce discrepancy in feature distributions between two domains, recent approaches achieve domain adaption through feature alignment in different granularities via adversarial learning. However, they neglect the relationship between multiple granularities and different features in alignment, degrading detection. Addressing this, we introduce a unified multi-granularity alignment (MGA)-based detection framework for domain-invariant feature learning. The key is to encode the dependencies across different granularities including pixel-, instance-, and category-levels simultaneously to align two domains. Specifically, based on pixel-level features, we first develop an omni-scale gated fusion (OSGF) module to aggregate discriminative representations of instances with scale-aware convolutions, leading to robust multi-scale detection. Besides, we introduce multi-granularity discriminators to identify where, either source or target domains, different granularities of samples come from. Note that, MGA not only leverages instance discriminability in different categories but also exploits category consistency between two domains for detection. Furthermore, we present an adaptive exponential moving average (AEMA) strategy that explores model assessments for model update to improve pseudo labels and alleviate local misalignment problem, boosting detection robustness. Extensive experiments on multiple domain adaption scenarios validate the superiority of MGA over other approaches on FCOS and Faster R-CNN detectors. Code will be released at https://github.com/tiankongzhang/MGA.
翻译:域自适应检测旨在提升检测器在目标域上的泛化能力。为降低两域特征分布差异,现有方法通过对抗学习在不同粒度上进行特征对齐以实现域自适应。然而,这些方法忽视了多粒度与不同特征之间的对齐关系,导致检测性能下降。针对这一问题,我们提出基于统一多粒度对齐(MGA)的检测框架,用于学习域不变特征。其核心在于同时编码像素级、实例级和类别级等不同粒度间的依赖性以对齐两域。具体而言,基于像素级特征,我们首先开发全尺度门控融合(OSGF)模块,通过尺度感知卷积聚合实例的判别性表征,从而实现鲁棒的多尺度检测。此外,我们引入多粒度判别器,用于识别不同粒度的样本来自源域还是目标域。值得注意的是,MGA不仅利用不同类别中的实例判别性,还利用两域间的类别一致性进行检测。进一步,我们提出自适应指数移动平均(AEMA)策略,通过探索模型评估来更新模型,以改进伪标签并缓解局部不对齐问题,从而增强检测鲁棒性。在多个域自适应场景上的大量实验验证了MGA在FCOS和Faster R-CNN检测器上相较其他方法的优越性。代码将发布至https://github.com/tiankongzhang/MGA。