Paper commentary
Learning Transferable Features with Deep Adaptation Networks
Deep adaptation networks match several task-specific layers to transfer features across domains
- Problem Deep features lose transferability in higher layers as the gap between domains grows. Earlier methods matched only one layer, and single-kernel MMD scales poorly and matches weakly.
- Method DAN adds a multi-kernel MMD penalty to the classification loss in each task-specific layer. It embeds hidden features in a kernel space, so source and target features are pulled together.
- Results DAN averages 72.9 on Office-31, compared to 70.6 for DDC. The gap is largest on A to W, at 68.5 against 61.6 for CNN.
Why transfer stalls in the higher layers
A network trained on one labeled domain often generalizes poorly to another, and deep features are part of the reason. Deep networks learn more transferable features than shallow ones, but their features shift from general to specific as one moves up the network. In the higher layers transferability drops sharply as the domain gap widens, so those layers can't be reused safely.
Making the features more discriminative can also widen the gap between domains, which hurts adaptation.
Earlier work mostly reduced the discrepancy in shallow feature spaces, and the deep methods that followed touched only one layer. DDC, for instance, adds an adaptation layer and penalizes a single-kernel MMD, but only at one place in the network. Single-kernel MMD also matches distributions with limited power, and its quadratic cost restricts scalability.
That leaves open how to match several task-specific layers with a statistic that scales and matches better.
Adapting every task-specific layer with MK-MMD
The key idea is to keep the labeled-domain loss and add a penalty that pulls source and target hidden features together in each task-specific layer. The authors expected this to work because kernel mean embeddings can be matched explicitly in a reproducing kernel Hilbert space. They use a multi-kernel version of MMD, since the choice of kernel strongly affects how well the match works.
For distributions p and q, the squared MK-MMD is the squared RKHS distance between their mean embeddings, written \(d_k^2(p,q)=\|E_p[\phi(x_s)]-E_q[\phi(x_t)]\|^2_{\mathcal H_k}\). The kernel k is a convex combination of m Gaussian kernels, with non-negative weights β_u that sum to one. A characteristic kernel is what makes this distance vanish only when the two distributions are equal.
AlexNet is the backbone, with conv1 to conv3 frozen and conv4 and conv5 fine-tuned. The adaptation term is summed over layers 6 to 8, with the authors setting l1 = 6 and l2 = 8.
Computing MK-MMD from all pairs of samples costs O(n^2), which clashes with mini-batch SGD. The authors instead use an unbiased estimate that averages a statistic g_k over quad-tuples of source and target examples, which costs O(n). For each quad-tuple, g_k adds the kernel values within the source pair and within the target pair, then subtracts the two cross-domain pairs.
Because the estimate is a sum, each mini-batch gives a gradient that Caffe can compute with the chain rule.
This β step maximizes test power relative to estimation variance, which corresponds to minimizing the Type II error. The network parameters and β are updated alternately, with mini-batch SGD for the network and the quadratic program for β. The authors call the overall objective a minimax problem, in which the network minimizes the discrepancy while β is tuned against it.
What the bound says about target risk
The authors bound the expected target risk by the source risk plus 2 times the MK-MMD plus a constant C. The proof starts from a known H-divergence bound and replaces the divergence with an empirical two-sample classifier estimate. Through that step, the MK-MMD term links to the error of a Parzen-window classifier, which the authors use to read adaptation quality.
The bound is used as motivation, while the experiments test accuracy and the A-distance instead.
Benchmark accuracy against CNN and DDC
On the six Office-31 transfer tasks under the unsupervised protocol, DAN averages 72.9, compared to 70.6 for DDC and 70.1 for CNN. The largest gap appears on A→W, where DAN reaches 68.5 compared to 61.6 for CNN. All these methods share the AlexNet backbone, so the difference isolates the adaptation term rather than the network choice. On D→W and W→D DAN is comparable to the baselines, which the authors attribute to those pairs already being similar.
On Office-10 + Caltech-10, DAN averages 87.3, compared to 84.6 for DDC and 84.0 for CNN. LapCNN averages 69.5 on Office-31, below the 70.1 of CNN, so semi-supervised regularization gave no gain there.
With three labeled target examples per category, DAN averages 93.1 on three Office-31 tasks, compared to 91.9 for DDC. The source examples are randomly down-sampled in this classic protocol, which differs from the full-data setting above. This is the most direct comparison with DDC, since it uses the same tasks that DDC used.
Which parts of DAN carry the gain
Restricting adaptation to fc7 (DAN7) or to fc8 (DAN8) gives 71.1 and 71.3 on Office-31, compared to 72.9 for full DAN. The single-kernel variant DANSK reaches 71.5, which is also below full DAN. On Office-10 + Caltech-10 the same ordering holds, with DAN7 at 85.4, DANSK at 85.5, DAN8 at 86.4 and full DAN at 87.3. On both averages each reduced variant scores below full DAN.
DANSK is multi-layer but single-kernel, and it still beats DDC, which is single-layer and single-kernel, at 71.5 compared to 70.6. The authors read the near-tie among DANSK and the single-layer variants as showing that multi-layer adaptation and kernel choice both matter.
Feature diagnostics: A-distance, t-SNE and λ
The A-distance is approximated as 2(1 − 2ε), where ε is the error of a kernel SVM that separates source from target. On A→W and C→W, the A-distance of both CNN and DAN features is larger than that of raw features. The authors read this as deep features becoming more discriminative for both classes and domains, which can enlarge the domain gap.
They state that a smaller A-distance for DAN than for CNN would be desirable, since it signals more transferable features.
The t-SNE plots for C→W compare DDC and DAN features on source and target points. With DAN features the target points separate better, and the categories line up more closely across domains, by visual reading. This is a qualitative reading, so it illustrates the accuracy gain rather than measuring it.
Varying λ over {0.1, 0.4, 0.7, 1, 1.4, 1.7, 2} on A→W and C→W gives accuracy that first rises and then falls. The authors read this bell-shaped curve as a trade-off between fitting the labeled source and aligning the two distributions.
Limitations
Convolutional layers conv1 to conv3 stay frozen, and the paper does not adapt the convolutional layers with distribution matching. The λ sweep covers only A→W and C→W. The semi-supervised comparison covers three Office-31 tasks, while the Office-10 + Caltech-10 results are unsupervised only. The bound's constant C is left unspecified, so the theorem gives a relation rather than a numerical guarantee.
Paper info
- Authors
- Mingsheng Long, Yue Cao, Jianmin Wang, Michael I. Jordan
- Venue
- arXiv · Preprint
- First published
- 2015-2-10
- Added
- 2026-11-12
- Updated
- 2015-5-27
- Version
- v2
- arXiv
- 1502.02791
- Category
- cs.LG
- Original paper terms
- arXiv non-exclusive 1.0
- What we show
- Paper info and commentary
AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.
Quote from the paper
Mingsheng Long, Yue Cao, Jianmin Wang, Michael I. Jordan (2015). Learning Transferable Features with Deep Adaptation Networks. arXiv:1502.02791v2. https://arxiv.org/abs/1502.02791v2
BibTeX
@misc{long2015learning,
title = {{Learning Transferable Features with Deep Adaptation Networks}},
author = {Mingsheng Long and Yue Cao and Jianmin Wang and Michael I. Jordan},
year = {2015},
eprint = {1502.02791},
archivePrefix = {arXiv},
url = {https://arxiv.org/abs/1502.02791v2}
}