Joint Contrastive-Adversarial Representation Learning for Unsupervised Domain Adaptation
Abstract
Effective unsupervised domain adaptation (UDA) requires a representation that captures transferable structure from both the labeled source domain and the unlabeled target domain. We introduce Joint Contrastive-Adversarial Representation Learning (JCAR), a two-stage framework that learns a common representation from the union of unlabeled source and target samples by combining contrastive learning with adversarial domain alignment, and then freezes the representation to fit a source-supervised predictor. We establish a non-asymptotic excess-risk bound for this procedure that couples representation and domain-discriminator estimation while separating downstream prediction, with explicit neural-network approximation errors. Under the stated assumptions and common Hölder smoothness , the bound identifies a sufficiently large unlabeled-sample regime in which the downstream rate is , where counts labeled source samples and logarithmic factors are suppressed. The labeled-sample exponent is governed by the latent dimension rather than the ambient dimension , which enters the pretraining cost. Experiments on Office-31, Office-Home, and DomainNet demonstrate clear transfer gains across diverse domain shifts, with particularly strong performance when representations are learned from scratch.
Figures & tables
| Methods | A W | D W | W D | A D | D A | W A |
|---|---|---|---|---|---|---|
| ERM | 10.1 | 28.9 | 31.3 | 9.2 | 6.1 | 6.0 |
| CDAN | 12.1 | 29.1 | 28.3 | 7.8 | 5.9 | 4.7 |
| DANN | 16.4 | 63.4 | 67.5 | 10.2 | 7.2 | 9.6 |
| Ours (ResNet) | 16.7 | 44.6 | 51.4 | 12.1 | 10.5 | 13.0 |
| ViT-B | 14.8 | 37.5 | 47.8 | 12.5 | 5.9 | 9.9 |
| Ours (ViT) | 17.9 | 39.2 | 42.9 | 11.0 | 7.1 | 11.2 |
| Methods | Ar Rw | Pr Rw | Cl Pr | Ar Cl | Pr Ar | Cl Rw |
|---|---|---|---|---|---|---|
| ERM | 10.0 | 16.4 | 10.9 | 4.4 | 7.1 | 9.5 |
| CDAN | 9.4 | 16.0 | 12.5 | 3.9 | 5.0 | 8.4 |
| DANN | 9.6 | 16.4 | 10.3 | 4.9 | 4.4 | 10.2 |
| Ours (ResNet) | 7.6 | 10.4 | 10.0 | 4.3 | 5.0 | 7.2 |
| ViT-B | 9.2 | 14.3 | 3.1 | 5.8 | 7.0 | 9.1 |
| Ours (ViT) | 9.4 | 14.5 | 8.2 | 4.5 | 7.8 | 10.5 |
Appendix figures & tables11 assets
Supplementary material from the paper’s appendix.
Appendix
| Data | Domain | Class | Total sample |
|---|---|---|---|
| Office-31 | 3 | 31 | 4,625 |
| Office-Home | 4 | 65 | 15,588 |
| DomainNet | 6 | 345 | 586,753 |
| Data | Epoch | Batch Size | Learning rate | Feature dimension | |
|---|---|---|---|---|---|
| Office-31 | 800 | 16(8) | 0.01, 0.1, 0.1(1.0) | 256 | |
| Office-Home | 800 | 16(8) | 0.01, 0.1, 0.1(1.0) | 512 | |
| DomainNet | 800 | 16(8) | 0.01, 0.1, 0.1(1.0) | 512 |
| Methods | A W | D W | W D | A D | D A | W A |
|---|---|---|---|---|---|---|
| ERM | 74.8 | 95.0 | 93.9 | 69.7 | 43.2 | 55.4 |
| CDAN | 61.6 | 95.0 | 97.0 | 66.7 | 53.3 | 52.8 |
| DANN | 71.7 | 95.0 | 97.0 | 70.7 | 52.8 | 53.5 |
| ViT-B | 95.0 | 99.2 | 99.9 | 93.9 | 81.8 | 81.4 |
| Ours (ViT) | 92.0 | 98.9 | 99.5 | 82.0 | 79.1 | 79.8 |
| Methods | {D,W} A | {A, D } W | {A, W} D |
|---|---|---|---|
| ERM | 56.5 | 91.8 | 93.9 |
| CDAN | 56.7 | 92.5 | 89.9 |
| DANN | 56.5 | 81.1 | 90.9 |
| ViT-B | 81.4 | 99.2 | 100.0 |
| Ours (ViT) | 78.5 | 98.4 | 98.9 |
| Methods | Ar Rw | Pr Rw | Cl Pr | Ar Cl | Pr Ar | Cl Rw |
|---|---|---|---|---|---|---|
| ERM | 66.5 | 63.5 | 56.6 | 39.5 | 41.2 | 55.3 |
| CDAN | 64.3 | 65.4 | 54.3 | 36.4 | 41.6 | 50.2 |
| DANN | 65.0 | 67.3 | 57.4 | 39.1 | 41.2 | 51.7 |
| ViT-B | 86.8 | 87.8 | 82.8 | 62.3 | 78.2 | 85.6 |
| Ours (ViT) | 84.5 | 82.9 | 76.2 | 58.5 | 67.0 | 78.9 |
| Methods | {Cl,Pr, Rw} | {Ar, Rw, Pr } | {Ar, Cl, Pr } | {Ar, Cl, Rw} |
|---|---|---|---|---|
| Ar | Cl | Rw | Pr | |
| ERM | 63.3 | 46.8 | 77.7 | 76.1 |
| CDAN | 67.4 | 51.5 | 77.2 | 73.8 |
| DANN | 62.7 | 48.3 | 75.5 | 73.3 |
| ViT-B | 83.7 | 64.4 | 90.0 | 89.6 |
| Methods | r c | r p | p c | c s | s p | r s |
|---|---|---|---|---|---|---|
| ERM | 36.5 | 40.7 | 29.4 | 32.1 | 27.5 | 26.2 |
| CDAN | 51.4 | 50.1 | 41.1 | 40.1 | 41.0 | 40.7 |
| DANN | 48.9 | 48.8 | 35.9 | 41.1 | 40.2 | 39.8 |
| ViT-B | 47.4 | 53.5 | 37.8 | 44.7 | 47.1 | 34.8 |
| Ours (ViT) | 44.2 | 47.8 | 30.9 | 31.2 | 33.7 | 34.7 |
Unsupervised Domain Adaptation
Unsupervised domain adaptation transfers models from labeled source data to unlabeled target domains with different data distributions.
See all 183 papers