Year: 2019

Abstract:
Domain shifts are frequently encountered in real-world scenarios. In this paper, we consider the problem of domain-invariant deep learning by explicitly modeling domain shifts with only a small amount of domain-specific parameters in a Convolutional Neural Network (CNN). By exploiting the observation that a convolutional filter can be well approximated as a linear combination of a small set of basis elements, we show for the first time, both empirically and theoretically, that domain shifts can be effectively handled by decomposing a regular convolutional layer into a domain-specific basis layer and a domain-shared basis coefficient layer, while both remain convolutional. An input channel will now first convolve spatially only with each respective domain-specific basis to “absorb” domain variations, and then output channels are linearly combined using common basis coefficients trained to promote shared semantics across domains. We use toy examples, rigorous analysis, and real-world examples to show the framework’s effectiveness in cross-domain performance and domain adaptation. With the proposed architecture, we need only a small set of basis elements to model each additional domain, which brings a negligible amount of additional parameters, typically a few hundred.

heading: 1 INTRODUCTION
text: Training supervised deep networks requires large amount of labeled training data; however, welltrained deep networks often degrade dramatically on testing data from a significantly different domain. In real-world scenarios, such domain shifts are introduced by many factors, such as different illumination, viewing angles, and resolutions. Research topics such as transfer learning and domain adaptation are studied to promote invariant representations across domains with different levels of availabilities of annotated data.
Recent efforts on learning cross-domain invariant representations using deep networks generally fall into two categories. The first one is to learn a common network with constraints encouraging invariant feature representations across different domains Long et al. (2015; 2016b); Tzeng et al. (2014). The feature invariance is usually measured by feature statistics like Maximum Mean Discrepancy (MMD), or feature discriminators using adversarial training Ganin et al. (2016). While these methods introduce no additional model parameters, the effectiveness largely depends on the degree of domain shifts. The other direction is to explicitly model domain specific characteristics with a multi-stream network structure where different domains are modeled by corresponding sub-networks at the cost of significant extra parameters and computations Rozantsev et al. (2018b). Regularizations are imposed among sub-networks to encourage common semantics across domains.
In this paper, we model domain shifts through domain-adaptive filter decomposition (DAFD) with layer branching. At a branched layer, we decompose each filter over a small set of domain-specific basis elements to model intrinsic domain characteristics, while enforcing shared cross-domain coefficients to align invariant semantics. A regular convolution is now decomposed into two steps. First, a domain-specific basis convolves spatially only each individual input channel for shift “correction.” Second, the “corrected” output channels are weighted summed using domain-shared basis coefficients (1×1 convolution) to promote common semantics. When domain shifts happen in space, we rigorously prove that such layer-wise “correction” by the same spatial transform applied to bases suffices to align the learned features.
Comparing to the existing subnetwork-based methods, the proposed method has several appealing properties: First, only a very small amount of additional trainable parameters are introduced to explicitly model each domain, i.e., domain-specific bases. The majority of the parameters in the
network remain shared across domains, and learned from abundant training data to effectively avoid overfitting. Furthermore, the decomposed filters reduce the overall computations significantly compared to previous works, where computation typically grows linearly with the number of domains.
We conduct extensive real-world face recognition, image classification, and segmentation experiments, and observe that, with the proposed method, invariant representations across domains are consistently achieved without compromising the performance of individual domain.
Our main contributions are summarized as follows: • We propose domain-invariant representation learning through bases decomposition with
layer branching, where domain-specific bases are learned to counter domain shifts, and semantic alignments are enforced with cross-domain common basis coefficients. • We both theoretically prove and empirically observe that by stacking the bases-decomposed branched layer, invariant representations across domains are achieved progressively. • The majority of network parameters remain shared across domains, which alleviates the demand for massive annotated data from every domain, and introduces only a small amount of additional computation and parameter overhead. Thus the proposed approach serves as an efficient way for domain invariant learning.

heading: 2 RELATED WORK
text: Recent achievements on domain-invariant learning generally follow two directions. The first direction is learning a single network, where parameters are shared across domains, while the network is encouraged to produce domain-invariant features by minimizing additional loss functions in the network training Ganin et al. (2016); Long et al. (2015; 2016a;b); Tzeng et al. (2014). The Maximum Mean Discrepancy (MMD) Gretton et al. (2007), and MK-MMD Gretton et al. (2012) in Long et al. (2015), are adopted as the discrepancy metric among domains. Beyond the first order statistic, second-order statistics are utilized in Hoffman et al. (2014). Besides the hand-crafted distribution distance metrics, Ganin et al. (2016); Tzeng et al. (2015); Long et al. (2018) resort to adversarial training and achieve superior performances. Various distribution alignment methods, e.g., Wu et al. (2019); Kumar et al. (2018), are proposed to improve the invariant feature learning. While effective in certain scenarios, the performance of learning invariant features using a shared network is largely constrained by the degree of domain shift as discussed in Rozantsev et al. (2018b). Meanwhile,
some recent works like Wu et al. (2019); Zhao et al. (2019) suggest important insights on whether it is sufficient to do domain adaptation by invariant representation and small empirical source risk, which shed light on exploring more effective alignment methods that are robust to common issues like different marginal label distributions.
Another popular direction is modeling each domain explicitly using auxiliary network structures. Based on the hypothesis that explicitly modeling what is unique to each domain can improve a model’s ability to extract domain-invariant features, e.g., Bousmalis et al. (2016) proposes feature representation by two components where domain similarities and shifts are modeled by a private component and a shared component separately. A completely two-stream network structure with no shared parameters is proposed in Rozantsev et al. (2018b), where auxiliary residual networks are trained to adapt the layer parameters of the source domain to the target domain. Chang et al. (2019) proposes attacking domain shifts by domain-specific batch normalization, which we believe is compatible with the proposed domain-specific filter decomposition for better performance. Another popular direction for domain adaptation is to remap the input data between the source and the target domain for domain adaptation Murez et al. (2017); Hu et al. (2018); Hoffman et al. (2018), which is not included in the discussion since we are focusing on learning invariant feature space. Finally, learning invariance is of relevance beyond domain adaptation, e.g., in the field of causal inference Bühlmann (2018).

heading: 3 DOMAIN-ADAPTIVE FILTER DECOMPOSITION
text: A straightforward way to address domain shifts is to learn from multi-domain training data a single network as in Figure 1(a). However, the lack of explicitly modelling of individual domains often results in unnecessary information loss and performance degradation as discussed in Rozantsev et al. (2018b). Thus, we often simultaneously observe underfitting for domains with abundant training data, and overfitting for domains with limited training. In this section, we start with a simplistic pedagogical formulation, domain-adaptive layer branching as in Figure 1(b), where domain shifts are modeled by a respective branch of filters in a layer, one branch per domain. Each branch is learned only from domain-specific data, while non-branched layers are learned from data from all domains. We then propose to extend basic branching to bases-decomposed branching as in Figure 1(c), where domain characteristics are modeled by domain-specific bases, and shared decomposition coefficients are enforced to align cross-domain semantics.

heading: 3.1 PEDAGOGICAL BRANCHING FORMULATION
text: We start with the simple-minded branching formulation in Figure 1(b). To model the domainspecific characteristics, at the first several convolutional layers, we dedicate a separate branch to each domain. Domain shifts are modeled by an independent set of convolutional filters in the branch, trained respectively with errors propagated back from the loss functions of source and target domains. For supervised learning, the loss function is the cross-entropy for each domain. For unsupervised learning, the loss function for the target domain can be either the feature statistics loss or the adversarial loss. The remaining layers are shared across domains. We assume one target domain and one source domain in our discussion, while multiple domains are supported. Note that, though we adopt the source vs. target naming convention in the domain adaptation literature, we address here a general domain-invariant learning problem.
Domain-adaptive branching is simple and straightforward, however, it has the following drawbacks: First, both the number of model parameters and computation are multiplied with the number of domains. Second, with limited target domain training data, we can experience overfitting in determining a large amount of parameters dedicated to that domain. Third, no constraints are enforced to encourage cross-domain shared semantics. We address these issues through layer branching with the proposed bases decomposition.

heading: 3.2 BASES-DECOMPOSED BRANCHING
text: To simultaneously counter domain shifts and enforce cross-domain shared semantics, we decompose each convolutional filter in a branched layer into domain-specific bases, and cross-domain shared coefficients, as illustrated in Figure 1(c).
Filter Decomposition. A convolutional filter can be well approximated as a linear combination of a small set of basis elements Qiu et al. (2018). In Figure 2(a), a convolutional filter W with a size of L×L×C ′×C is decomposed into a truncated expansion with pre-fixed bases in the spatial domain. The truncated bases ψ with a size L×L×K are predefined and remain fixed in training, whereK is a hyperparameter, usually a small number, e.g.,K = 5, indicating the number of basis elements used in each layer. The trainable parameters are thus reduced to the decomposition coefficients a with a size of K × C ′ × C. With bases decomposition, a reduction rate of KL2 is achieved in both model complexity and computation. This parameter saving is not the only virtue of basis decomposition, such decomposition is natural to extract both invariance across domains and adaptation to specific domains as detailed next.
In our approach, as shown in Figure 2(b), we decompose source and target domain filters over domain-specific bases, with decomposition coefficients shared across domains. Specifically, at each branched layer, the source domain filter Ws and target domain filter Wt of size L×L×C ′×C, are decomposed into ψs × a and ψt × a, where ψs and ψt with a size of L × L ×K are the domainadaptive bases for source and target domains, respectively; and a ∈ RK×C′×C denotes the common decomposed coefficients shared across domains. Different from Qiu et al. (2018), the domainadaptive bases are independently learned from the corresponding domain data to model domain shifts, and the shared decomposed coefficients are learned from the massive data from multiple domains. Note that thanks to this proposed structure, only a small amount of additional parameters is required here to model each additional domain, typically a few hundred.
With the above domain-adaptive filter decomposition, at each branched layer, a regular convolution is now decomposed into two: First, a domain-specific basis convolves each individual input channel for domain shift “correction.” Second, the “corrected” output channels are weighted summed using domain-shared basis coefficients (1×1 convolution) to promote common semantics. A toy example is presented in Figure A.1 for illustrating the intuition behind the reason why manipulating bases alone can address domain shifts. We generate target domain data by applying two trivial operations to source domain images: First, every 3×3 non-overlapping patch in each image is locally rotated by 90o. Then, images are negated by multiplying with −1. Domain-invariant features are observed by manipulating bases alone. We will rigorously prove in Section 4 why such layer-wise “correction” aligns features across domains, and present real-world examples in the experiments.
Parameters and Computation Reduction. Suppose that both input and output features have the same spatial resolution of W × W , in each forward pass in a regular convolutional layer, there are totally W 2 × C ′ × C × (2L2 + 1) flops for each domain. While in our model, each domain only introduces W 2 × C ′ × 2K(L2 + C) flops, where K is the number of basis elements. For parameters, there are totally D × C ′ × C × L2 parameters in a regular convolutional layer where D is the number of domains which is typically 2 in our case. In our model, each layer has only K× (C ′×C+D×L2) parameters. Taking VGG-16 Simonyan & Zisserman (2014) as an example with an input size of 224 × 224, a regular VGG-16 with branching, Fig 1(b) and Rozantsev et al. (2018a;b), requires adding 14.71M parameters and 15.38G flops in convolutional layers to handle each additional domain. With the here proposed method (Fig 1(c)), a VGG-16 only requires adding 702 parameters and 10.75G flops to handle one additional domain (K=6).

heading: 4 PROVABLE INVARIANCE WITH ADAPTIVE BASES
text: In this section, we theoretically prove that the features produced by the source and target networks from domain-transferred inputs can be aligned by the proposed framework of only adjusting multi-
layer bases, assuming a generative model of the source and target domain images via CNN. Since convolutional generative networks are a rich class of models for domain transfer Hu et al. (2018); Murez et al. (2017), our analysis provides a theoretical justification of the proposed approach. Diverse examples in the experiment section shows the applicability of the proposed approach is potentially larger than what is proved here. All proofs are in the supplementary material.
Filter Transform via Basis Transform. Let ws and wt be the filters in the branched convolutional layer for the source and target domains respectively, and similarly denote the source and target bases by ψk,s and ψk,t. In the proposed bases decomposition DA architecture, the source and target domain filters are linear combinations of the domain-specific basis elements with shared decomposition coefficients, namely
ws(u) = ∑ k akψk,s(u), wt(u) = ∑ k akψk,t(u).
Certain transforms of the filter can be implemented by only transforming the bases, including (1) A linear correspondence of filter values. Let λ : R→ R be a linear mapping, by linearity,
ψk,s(u)→ ψk,t(u) = λ(ψk,s(u)) applies ws(u)→ wt(u) = λ(ws(u)). E.g. the negation λ(ξ) = −λ(ξ), as shown in Figure A.1.
(2) The transformation induced by a displacement of spatial variable, i.e., “spatial transform” of filters, defined as Dτw(u) = w(u − τ(u)), where τ : R2 → R2 is a differentiable displacement field. Note that the dependence on spatial variable u in a filter is via the bases, thus ψk,s → ψk,t = Dτψk,s applies ws → wt = Dτws.
If such filter adaptations are desired in the branching network, then it suffices to branch the bases while keeping the coefficients ak shared, as implemented in the proposed architecture shown in Figure 1(c). A fundamental question is thus how large is the class of possible domain shifts that can be corrected by these “allowable” filter transforms. In the rest of the section, we show that if the domain shifts in the images are induced from a generative CNN where the filters for source and target differ by a sequence of allowable transforms, then the domain shift can be provably eliminated by another sequence of filter transforms which can be implemented by bases branching only.
Correction of a Single Filter Transform. We first analyze the “symmetric” correction of one filter spatial transform Dτ in one layer. The inclusion of linear correspondence transform is more direct (see comments after Theorem 1). For technical reasons, we assume that the displacement field τ is a small distortion, namely ‖∇τ‖∞ 1, and then Dτ is invertible. Example includes rotation by a small angle and a small factor rescaling (dilation).
For simplicity we only consider one input and output channel in each of the multiple convolutional layers. The argument extends to multiple channels by modifying the boundedness condition of the filters. Then the forward mapping in one convolutional layer can be written as y = σ(x ∗ w + b), where x is the input activation, y is the output, w is the filter, b is the constant bias, and σ is the nonlinear activation function, e.g., ReLU. As we take a continuous formulation in the analysis, the activations x and y are assumed to be smooth functions supported on domain Ω ⊂ R2, typically Ω = [−1, 1]2. The filter w is a function supported on 2jB, B being the unit disk, and 2j is layer scale (diameter of filter patches) . The 1-norm of a function is defined to be ‖x‖1 = ∫ R2 |x(u)|du. Lemma 1. Suppose that the two filters w, f are supported on 2jwB and 2jfB respectively. σ : R → R is non-expansive, Dτ is a spatial transform where τ is odd, i.e., τ(−u) = −τ(u), and |∇τ |∞ < 15 . Then
‖σb(x ∗Dτw) ∗ f − σb(x ∗ w) ∗D−1τ f‖1 ≤ 2|∇τ |∞‖w‖1‖f‖1 { (2jw + 2jf )‖∇x‖1 + 4‖x‖1 } ,
where σb denotes the nonlinear function with the bias. The second term vanishes if (Id − τ) is a rigid motion, e.g., rotation.
Provable Invariance under a Generative Model of Images. Stacking the approximate commuting relation, Lemma 1, in multiple layers allows to correct a sequence of filter transforms in previous convolutional layers by another sequence of “symmetric” ones. This means that if we impose a convolutional generative model on the source and target input images, and assume that the domain transfer results from a sequence of spatial transforms of filters in the generative net, then by correcting these filter transforms in the subsequent convolutional layers we can guarantee the recovery of
the same feature mapping. The key observation is that the filter transfers can be implemented by bases transfer only.
We summarize the theoretical assumptions as follows: (A1) The σ in any layer is non-expansive, (A2) In the generative net (where layer is indexed by negative integers), w(−l)t = Dlw (−l) s ,
where Dl = Dτl , τl is odd and |∇τl|∞ ≤ ε < 15 for all l = 1, · · · , L. The biases in the target generative net are mildly adjusted accordingly due to technical reasons (to preserve the “baseline output” from zero-input, c.f. the proof).
(A3) In the generative net, ‖w(−l)s ‖1 ≤ 1 for all l, and so is w(−l)t = Dlw (−l) s . Same for the
feed-forward convolutional net taking the generated images as input, called “feature net”: The source net filters have ‖w(l)s ‖1 ≤ 1 for l = 1, 2 · · · , and same with Dlw(l)s which will be set to be w(l)t . Also, w (−l) s and w (l) s are both supported on 2jlB for l = 1, · · · , L.
One can show that ‖Dτw‖1 = ‖w‖1 when (Id − ρ) is a rigid motion, and generally |‖Dτw‖1 − ‖w‖1| ≤ c|∇τ |∞‖w‖1 which is negligible when ε is small. Thus in (A3) the boundedness of the 1- norm of the source and target filters imply one another exactly or approximately. The boundedness of 1-norm of the filters preserves the non-expansiveness of the mapping from input to output in a convolutional layer, and in practice is qualitatively preserved by normalization layers. Also, as a typical setting, (A3) assumes that the scales jl in the generative net (the (−l)-th layer) and the feature net (the l-th layer) are matched, which simplifies the analysis and can be relaxed. Theorem 1. Suppose thatXs andXt are source and target images generated by L-layer generative CNN nets with source and target filters w(−l)s , w (−l) t respectively from the common representation h. Under (A1)-(A3), the output at the L-th layer of the target feature CNN from Xt, by setting w
(l) t = Dlw (l) s in all layers which can be implemented by bases branching, approximates that of the
source feature CNN from Xs up to an error which is bounded in 1-norm by
4ε { (
L∑ l=1 2jl)‖∇h‖1 + 2L‖h‖1
} ,
and the second term vanishes if (Id − τl) are rigid motions, e.g., rotation. Note that typically j1 ≤ · · · ≤ jL and 2JL ≤ 1, and ∑ l 2 jl is proportional to the diameter of Ω and thus an O(1) constant. The result can be extended to allow a linear transform of the filter values, namely Dw(u) = λ(Dτw(u)), and correct the target filters ft to be λ−1(Dτfs). In Lemma 1, λ commutes with the convolution by linearity, and also with σ by adjusting the bias parameter if needed. Unlike Dτ which becomes D−1τ when applying to f , λ remains as λ, thus λ
−1 is needed in the symmetric basis transfers to correct the domain shift. Proofs are in the supplementary material.

heading: 5 EXPERIMENTS
text: In this section, we perform extensive experiments to evaluate the performance of the proposed domain-adaptive filter decomposition. We start with the comparisons among the 3 architectures listed in Figure 1 on two supervised tasks. To demonstrate the proposed framework as one principled way for domain-invariant learning, we then conduct a set of domain adaptation experiments. There we show, by simply plugging the proposed domain filter decomposition into regular CNNs used in existing domain adaptation methods, we consistently observe performance improvements, which illustrates that the framework can be successfully applied with multiple leading deep network architectures and very different datasets and applications.

heading: 5.1 ARCHITECTURE COMPARISONS
text: We start with two supervised tasks performed on the three architectures listed in Figure 1, regular CNN (A1), basic branching (A2), and branching with domain-adaptive filter decomposition (A3). In each layer of the network with the proposed domain-adaptive filter decomposition, the different domain features convolve spatially with the corresponding domain-specific bases first, then the output features are linearly combined by the cross-domain basis coefficients simultaneously. For both tasks, the networks are trained end-to-end with a summed loss for domains, and the domain-specific bases are only updated by the error from the corresponding domain, while the basis coefficients are updated by the joint error across domains.
Supervised Domain Adaptation on Digits. The first task is supervised domain adaptation, where we adopt a challenging setting by using MNIST handwritten digit dataset as the source domain, and SVHN as the target domain. We perform a series of experiments by progressively reducing the annotated training data for the target domain. We start the comparisons at 10% of the target domain labeled samples, and end at 0.5% where only 366 labeled samples are available for the target domain. The results on test set for both domains are presented in Table 3(a). It is clearly shown that when training the target domain with small amount of data, a network with basic branching suffers from overfitting to the target domain because of the large amount of domain specific parameters. While regular CNN generates well on target domain, the performance on source domain degrades when the number of target domain data is comparable. A network with the proposed domain-adaptive filter decomposition significantly balances the learning of both the source and the target domain, and achieves best accuracies on both domains regardless of the amount of annotated training data for the target domain. The feature space of the three candidate architectures are visualized in Figure 1.
Supervised Simultaneous Cross-domain Face Recognition. To show the generality of the proposed domain-adaptive filter decomposition for various tasks, we further perform a supervised crossdomain (RGB and near infrared) simultaneous face recognition experiment in the supplementary material Section B, and the quantitative comparisons are in Table 3(b), where we can clearly observe that DAFD performs superiorly even with a missing input domain. Note that A2 requires additional 14.71M parameters over A1, while our method requires only 0.0007M as shown in Table A.1.

heading: 5.2 EXPERIMENTS ON STANDARD DOMAIN ADAPTATIONS
text: In this section, we perform extensive experiments on unsupervised domain adaptation. Note that the objective of the experiments in this section is not to validate the proposed domain-adaptive filter decomposition as just another new method for domain adaptation. Instead, since most of the state-ofthe-art domain adaptation methods adopt the regular CNN (A1) with completely shared parameters for domains, we show the compatibility and the generality of the proposed domain-adapting filter decomposition by plugging it into underlying domain adaptation methods, and evaluate the effectiveness by retraining the networks using exactly the same setting and observing the performance improvement over the underlying methods. Diverse real-world domain shifts including different sensors, different image sources, and synthetic images, and applications on both classification and segmentation are examined in these experiments. Together with the experiments in the previous section, this further stresses the plug-and-play virtue of the proposed framework.
In practise, instead of learning independent source and target domain bases, we learn the residual between the source and the target domain bases. The residual is initialized by full zeros, and trained by loss for encouraging invariant features in the underlying methods, e.g., the adversarial loss in ADDA Tzeng et al. (2017). We consistently observe that this stabilizes the training and promotes faster convergence.
Digit Classification. We perform experiments on three public digits datasets: MNIST, USPS, and Street View House Numbers (SVHN), with three transfer tasks: USPS to MNIST (U→ M), MNIST to USPS (M→ U), and SVHN to MNIST (S→ M). Classification accuracy on the target domain test set samples is adopted as the metric for measuring the per-
formance. We perform domain-adaptive domain decomposition on state-of-the-art methods DANN
Ganin et al. (2016), ADDA Tzeng et al. (2017), and CDAN+E Long et al. (2018). Quantitative comparisons are presented in Table 2.
Office-31. Office-31 is one of the most widely used datasets for visual domain adaptation, which has 4,652 images and 31 categories collected from three distinct domains: Amazon (A), Webcam (W), and DSLR (D). We evaluate all methods on six transfer tasks A → W, D → W, W → D, A → D, D→ A, and W→ A. Two feature extractors, AlexNet Krizhevsky et al. (2012) and ResNet He et al. (2016) are adopted for fair comparisons with underlying methods. Specifically, ImageNet initialization are widely used for ResNet in the experiments with Office-31, and we consistently observe that initialization is important for the training on Office-31. Therefore, when training ResNet based networks with domain-adaptive filter decomposition, we initialize the feature extractor using parameters decomposed from ImageNet initialization. The quantitative comparisons are in Table 3.
Image Segmentation. Beyond image classification tasks, we perform a challenging experiment on image segmentation to demonstrate the generality of the proposed domain-adaptive filter decomposition. We perform unsupervised adaptation from the GTA dataset Richter et al. (2016) (images generated from video games) to the Cityscapes dataset Cordts et al. (2016) (real-world images), which has a significant practical value considering the expensive cost on collecting annotations for image segmentation in real-world scenarios. Two underlying methods FCNs in the wild Hoffman et al. (2016) and AdaptSegNet Tsai et al. (2018) are adopted for comprehensive comparisons. Based on the underlying methods, all the convolutional layers are decomposed using domain-adaptive filter decomposition, and all the transpose-convolutional layers are kept sharing by both domains. For quantitative results in Table 4, we use intersection-over-union, i.e., IoU = TPTP+FP+FN , where TP, FP, and FN are the numbers of true positive, false positive, and false negative pixels, respectively, as the evaluation metric. As with the previous examples, our method improves all state-of-the-art architectures. Qualitative results are shown in Figure A.2, and data samples are in Section C.1.

heading: 6 CONCLUSION
text: We proposed to perform domain-invariant learning through domain-adaptive filter decomposition. To model domain shifts, convolutional filters in a deep convolutional network are decomposed over domain-adaptive bases to counter domain shifts, and cross-domain basis coefficients are constrained to unify common semantics. We present the intuitions of countering domain shifts by adapting bases through toy examples, and further provide theoretical analysis. Extensive experiments on multiple tasks validate that, by stacking domain-adaptive branched layers with filter decomposition, complex domain shifts in real-world scenarios can be bridged to produce domain-invariant representation, which are reflected by both experimental results and feature space visualizations, all this at virtual no additional memory or computational cost when adding domains.

heading: A TOY EXPERIMENT

heading: B SUPERVISED CROSS-DOMAIN FACE RECOGNITION
text: Besides standard domain adaptation, the proposed domain-adaptive filter decomposition can be extended to general tasks that involves more than one visual domain. Here we demonstrate this by performing experiments on supervised cross-domain face recognition. We adopt the NIR-VIS 2.0, which consists of 17,580 NIR (near infrared) and VIS (visible light) face images of 725 subjects, and perform cross-domain face recognition. We adopt VGG16 as the base network structure, branch all the convolutional layers with the proposed domain-adaptive filter decomposition, and train the network from scratch. In each convolutional layer, two bases are trained for modeling the NIR and the VIS domain, respectively. Specifically, one VIS image and one NIR image are fed simultaneously to the network, and the feature vectors of both domains are averaged to produce the final cross-domain feature, which is further fed into a linear classifier for classifying the identity. While the training is conducted using both domains simultaneously, we test the network under three settings including feeding single domain inputs only (VIS Acc and NIR Acc in Table 3(b)) and both domain inputs (VIS+NIR Acc in Table 3(b)). Quantitative comparisons demonstrate that branching with the proposed DAFD performs superiorly even with a missing input domain.

heading: C DATASET SAMPLES AND QUALITATIVE RESULTS
text: C.1 UNSUPERVISED DA FOR IMAGE SEGMENTATION
For the segmentation experiments in Section 5.5, we provide more qualitative results in Figure A.2, and some dataset samples in Figure A.3.

heading: D COMPUTATION AND PARAMETERS
text: In Table A.1, we provide comparisons on additional parameters and computation introduced by one extra domain with and without the proposed domain-adaptive filter decomposition. The comparison reveals that domain-adaptive filter decomposition not only delivers superior performances but also saves both parameters and computation significantly.

heading: E PROOFS IN SECTION 4
text: Proof of Lemma 1. We establish a few facts:
Fact 1. |∇τ |∞ < 15 guarantees that, ρ := Id − τ ,
||Jρ| − 1|, ||Jρ−1| − 1| ≤ 4|∇τ |∞, (A.1) where Jf = det(∇f) denotes the determinate of the Jacobian matrix of the mapping f : R2 → R2. The inequality can be verified by elementary calculation. When ρ is a rigid motion then the r.h.s of equation A.1 is zero.
Fact 2. ρ is invertible, and odd symmetry of τ implies that ρ and thus ρ−1 are odd, namely −ρ−1(−u) = ρ−1(u). Define
y1(u) := σb(x ∗Dτw) ∗ f(u)
= ∫ R2 σb (∫ R2 x(u+ v − z)w(ρ(z))dz ) f(−v)dv
= ∫ R2 σb (∫ R2 x(u+ v − ρ−1(z̃))w(z̃)|Jρ−1(z̃)|dz̃ ) f(−v)dv
and
ŷ1(u) := ∫ R2 σb (∫ R2 x(u+ v − ρ−1(z̃))w(z̃)dz̃ ) f(−v)dv.
We have that |y1(u)− ŷ1(u)| ≤ ∫ R2 ∫ R2 |x(u+ v − ρ−1(z̃))||w(z̃)| ∣∣|Jρ−1| − 1∣∣ |f(−v)|dz̃dv (by σb non-expansive) ≤ 4|∇τ |∞ ∫ R2 ∫ R2 |x(u+ v − ρ−1(z̃))||w(z̃)||f(−v)|dz̃dv (by Fact 1)
and thus ‖y1 − ŷ1‖1 ≤ 4|∇τ |∞‖x‖1‖w‖1‖f‖1. (A.2)
When ρ is a rigid motion, y1 = ŷ1.
Also, let y2(u) := σb(x ∗ w) ∗D−1τ f(u)
= ∫ R2 σb (∫ R2 x(u+ v − z)w(z)dz ) f(−ρ−1(v))dv (by Fact 2)
= ∫ R2 σb (∫ R2 x(u+ ρ(ṽ)− z)w(z)dz ) f(−ṽ)|Jρ(ṽ)|dṽ
and
ŷ2(u) := ∫ R2 σb (∫ R2 x(u+ ρ(ṽ)− z)w(z)dz ) f(−ṽ)dṽ.
Similar to the proof of equation A.2, one can verify that ‖y2 − ŷ2‖1 ≤ 4|∇τ |∞‖x‖1‖w‖1‖f‖1, (A.3)
and the bound is zero when ρ is a rigid motion.
It remains to bound ‖ŷ1 − ŷ2‖1. Note that by σb being non-expansive again |ŷ1(u)− ŷ2(u)| ≤ ∫ R2 ∫ R2 |x(u+ v − ρ−1(z))− x(u+ ρ(v)− z)||w(z)|dz|f(−v)|dv. (A.4) We claim that∫ R2 |x(u+ v − ρ−1(z))− x(u+ ρ(v)− z)|du ≤ |∇τ |∞2(2jw + 2jf )‖∇x‖1 (A.5) uniformly for v and z. If true, with equation A.4 it gives that∫ R2 |ŷ1(u)− ŷ2(u)|du ≤ |∇τ |∞2(2jw + 2jf )‖∇x‖1‖w‖1‖f‖1
which proves the lemma together with equation A.2 and equation A.3.
Proof of equation A.5: We verify that for any fixed v, z,∫ R2 |x(u+ v − ρ−1(z))− x(u+ ρ(v)− z)|du ≤ ‖∇x‖1|∇τ |∞|v − ρ−1(z)|, (A.6) by a direct calculation: (l.h.s) ≤ ‖∇x‖1|(v − ρ−1(z))− (ρ(v)− z)|
= ‖∇x‖1|τ(v)− τ(ρ−1(z))| ≤ ‖∇x‖1|∇τ |∞|v − ρ−1(z)|.
Then, combined with that v ∈ 2jfB thus |v| ≤ 2jf , and z ∈ 2jwB and thus |ρ−1(z)| ≤ 1
1−|∇τ |∞ 2 jw ≤ 22jw (τ(0) = 0 by that τ is odd, and then |τ(ρ−1(z))| ≤ |∇τ |∞|ρ−1(z)|), the r.h.s of equation A.6 ≤ 2(2jw + 2jf )|∇τ |∞‖∇x‖1, which proves equation A.5.
Proof of Theorem 1. We need a slightly generalized form of Lemma 1, which inserts multiple plain convolutional layers between ∗w and ∗f , presented in Lemma 2. Under the setting of the theorem, in the generative CNNs,
Xs = σ(· · ·σ(h ∗ w(−L)s + b(−L)s ) · · · ∗ w(−1)s + b(−1)s ) (A.7)
Xt = σ(· · ·σ(h ∗ w(−L)t + b (−L) t ) · · · ∗ w (−1) t + b (−1) t ) (A.8)
where w(l)t and b (l) t are defined by, l = −L, · · · ,−1,
w (l) t = Dlw (l) s , x̃ (l) 0 ∗ w (l) t + b (l) t = x̃ (l) 0 ∗ w(l)s + b(l)s . (A.9)
The notation x̃(l) stands for the l-th layer output in the target net from the input in the bottom ((−L)th) layer as x̃(−L) = h, x̃(0) = Xt, and x̃ (l) 0 for that from zero input in the bottom. In the feature CNNs, the L-th layer outputs are Fs = σ(· · ·σ(Xs ∗ w(1)s + b(1)s ) · · · ∗ w(L)s + b(L)s ) (A.10)
Ft = σ(· · ·σ(Xt ∗ w(1)t + b (1) t ) · · · ∗ w (L) t + b (L) t ) (A.11)
where for l = 1, · · · , L, w
(l) t = Dlw (l) s , b (l) t = b (l) s .
The proof is by applying Lemma 2 recursively to the pair of layers indexed by l and −l, from l = 1 to L. Denote w(l)s by w(l), then w (l) t = Dlw
(l), where D−l = Dl = Dτl , l = 1, · · · , L. We also denote b(l)s by b(l) and keep notation b (l) t for negative l.
First, l = 1, in the target net, x̃(1) := σ(σ(x̃(−1) ∗D1w(−1) + b(−1)t ) ∗D1w(1) + b(1)) Use the centering x̃(−1)c := x̃(−1) − x̃(−1)0 , it can be written as x̃(1) = σ(σ(x̃(−1)c ∗D1w(−1) + x̃ (−1) 0 ∗D1w(−1) + b (−1) t ) ∗D1w(1) + b(1)) (A.12)
= σ(σ(x̃(−1)c ∗D1w(−1) + (x̃ (−1) 0 ∗ w(−1) + b(−1))) ∗D1w(1) + b(1)) (by equation A.9)
(A.13)
Applying Lemma 2 (or Lemma 1 for this case), taking x̃(−1)0 ∗ w(−1) + b(−1) as the effective “b”, we have that (using the non-expansiveness of σ to take r outside the last σ)
x̃(1) = σ(σ(x̃(−1)c ∗ w(−1) + x̃ (−1) 0 ∗ w(−1) + b(−1)) ∗ w(1) + b(1)) + r(1) (A.14)
= σ(σ(x̃(−1) ∗ w(−1) + b(−1)) ∗ w(1) + b(1)) + r(1) (A.15) := x̂(1) + r(1) (A.16)
where, since w(−1), w(1) are supported on 2j1B, ‖r(1)‖1 ≤ 4ε { 2j1‖∇x̃(−1)c ‖1 + 2‖x̃(−1)c ‖1 } . (A.17)
Next, x̃(2) := σ(x̃(1) ∗D2w(2) + b(2)) (A.18)
= σ((x̂(1) + r(1)) ∗D2w(2) + b(2)) (by equation A.16) (A.19) = σ(x̂(1) ∗D2w(2) + b(2)) + r(1) ′ (A.20)
where ‖r(1)′‖1 ≤ ‖r(1)‖1 and observe the same bound as equation A.17, since neither ∗w(2)t (Lemma 3(i)) nor applying σ with bias expands the 1-norm. Using the brief notation σl to denote the non-linear mapping with biases b(l), consider
σ2(x̂ (1) ∗D2w(2)) = σ2(σ1(σ−1(x̃(−1) ∗ w(−1)) ∗ w(1)) ∗D2w(2))
= σ2(σ1(σ−1(σ(x̃ (−2) ∗D2w(−2) + b(−2)t ) ∗ w(−1)) ∗ w(1)) ∗D2w(2))
= σ2(σ1(σ−1(σ(x̃ (−2) c ∗D2w(−2) + x̃ (−2) 0 ∗ w(−2) + b(−2))
∗ w(−1)) ∗ w(1)) ∗D2w(2)), (by equation A.9) by Lemma 2, it equals (using the non-expansiveness of σ2 to take r(2) outside)
σ2(σ1(σ−1(σ(x̃ (−2) c ∗ w(−2) + x̃ (−2) 0 ∗ w(−2) + b(−2)) ∗ w(−1)) ∗ w(1)) ∗ w(2)) + r(2)
= σ2(σ1(σ−1(σ(x̃ (−2) ∗ w(−2) + b(−2)) ∗ w(−1)) ∗ w(1)) ∗ w(2)) + r(2)
:= x̂(2) + r(2)
where ‖r(2)‖1 ≤ 4ε { 2j2‖∇x̃(−2)c ‖1 + 2‖x̃(−2)c ‖1 } . (A.21)
Inserting back to equation A.20,
x̃(2) = x̂(2) + r(1) ′ + r(2)
thus ‖x̃(2) − x̂(2)‖1 is bounded by the sum of equation A.17 and equation A.21. Continue the process, x̂(l) denotes the l-th layer output in the source CNN (after l times correction in the target CNN) by feeding x̃(−l−1) from the (−l)-th layer, where x̃(−l−1) is the output in the (un-corrected) generative target CNN after the first (L− l) layers. By that x̃(−L) = x(−L) = h, and that Ft = x̃(L), Fs = x(L), repeating the argument L times gives that
‖Fs − Ft‖1 ≤ 4ε L∑ l=1 (2jl‖∇x̃(−l)c ‖1 + 2‖x̃(−l)c ‖1),
and when (Id − ρl) are rigid motions, the 2nd term for each l vanishes. We claim that
Claim 3. For l = −L, · · · ,−1, ‖∇x̃(l)c ‖1 ≤ ‖∇h‖1, and ‖x̃(l)c ‖1 ≤ ‖h‖1. which suffices to prove the theorem.
Proof of Claim 3: No that in the bottom layer x̃(−L)c = x̃(−L) = h. For l = −L+ 1, · · · ,−1, ‖x̃(l)c ‖1 = ‖x̃(l) − x̃ (l) 0 ‖1
= ‖σl(x̃(l−1) ∗ w(l−1)t )− σl(x̃ (l) 0 ∗ w (l−1) t )‖1 ≤ ‖x̃(l−1) ∗ w(l−1)t − x̃ (l) 0 ∗ w (l−1) t ‖1 (by that σl non-expansive) ≤ ‖x̃(l−1) − x̃(l)0 ‖1 (by that ‖w (l−1) t ‖1 ≤ 1 and Lemma 3(i)) = ‖x̃(l−1)c ‖1.
Recursing the inequality gives that ‖x̃(l)c ‖1 ≤ ‖h‖1. Similarly, ‖∇x̃(l)c ‖1 = ‖∇x̃(l)‖1 = TV[σl(x̃(l−1) ∗ w (l−1) t )]
≤ TV[x̃(l−1) ∗ w(l−1)t ] (by that σl does not increase total variation)
= ‖∇(x̃(l−1) ∗ w(l−1)t )‖1 ≤ ‖∇x̃(l−1)‖1 = ‖∇x̃(l−1)c ‖1, (by that ‖w (l−1) t ‖1 ≤ 1 and Lemma 3(ii))
and thus ‖∇x̃(l)c ‖1 ≤ ‖∇h‖1. This proves Claim 3. Lemma 2. Suppose filters w, f1, · · · , fm, f satisfy that the 1-norm are all bounded by 1, and w and f are supported on 2jB. The sequence of σl, denoting non-linear function with bias, for l = 0, · · · ,m are non-expansive. Dτ is a spatial transform where τ is odd and |∇τ |∞ ≤ ε < 15 . Then
σm(· · ·σ1(σ0(x ∗Dτw) ∗ f1) · · · ∗ fm) ∗ f
approximates σm(· · ·σ1(σ0(x ∗ w) ∗ f1) · · · ∗ fm) ∗D−1τ f
up to an error whose 1-norm is bounded by 4ε { 2j‖∇x‖1 + 2‖x‖1 } , and the second term vanishes if (Id − τ) is a rigid motion.
Proof of Lemma 2. The proof uses the same technique as in the proof of Lemma 1. Omitting subscript R2 in the integral, let
y1(u) = ∫ σm( ∫ · · ·σ1( ∫ σ0( ∫ x(u+ v1 + · · ·+ vm + v − ρ−1(z))w(z)|Jρ−1|dz)
f(−v1)dv1) · · · fm(−vm)dvm)f(−v)dv,
ŷ1(u) = ∫ σm( ∫ · · ·σ1( ∫ σ0( ∫ x(u+ v1 + · · ·+ vm + v − ρ−1(z))w(z)dz)
f(−v1)dv1) · · · fm(−vm)dvm)f(−v)dv. By Fact 1, that σj are all non-expansive and that the 1-norm of all the filters are bounded by 1,∫
|y1(u)− ŷ1(u)|du ≤ 4ε‖x‖1. Also,
y2(u) = ∫ σm( ∫ · · ·σ1( ∫ σ0( ∫ x(u+ v1 + · · ·+ vm + ρ(v)− z)w(z)dz)
f(−v1)dv1) · · · fm(−vm)dvm)f(−v)|Jρ|dv,
ŷ2(u) = ∫ σm( ∫ · · ·σ1( ∫ σ0( ∫ x(u+ v1 + · · ·+ vm + ρ(v)− z)w(z)dz)
f(−v1)dv1) · · · fm(−vm)dvm)f(−v)dv. Similarly, ∫
|y2(u)− ŷ2(u)|du ≤ 4ε‖x‖1.
Same as before, with ρ being a rigid motion, ‖y1 − ŷ1‖ and ‖y2 − ŷ2‖ are both zero. It remains to bound ‖ŷ1 − ŷ2‖1. Observe that∫
|ŷ1(u)− ŷ2(u)|du ≤ ∫ · · · ∫ dv|f(−v)|dvm|f(−vm)| · · · dv1|f(−v1)|dz|w(z)|∫
du|x(u+ v1 + · · ·+ vm + v − ρ−1(z))− x(u+ v1 + · · ·+ vm + ρ(v)− z)|, (A.22) and similarly as in proving Lemma 1, one can verify that for any fixed v1, · · · , vm, v, z,∫
|x(u+ v1 + · · ·+ vm + v − ρ−1(z))− x(u+ v1 + · · ·+ vm + ρ(v)− z)|du
≤ ‖∇x‖1|∇τ |∞|v − ρ−1(z)| ≤ ε2(2j + 2j)‖∇x‖1. Inserting back to equation A.22, and again by that the 1-norm of all the filters are bounded by 1, we have that ‖ŷ1 − ŷ2‖1 ≤ 4ε2j‖∇x‖1. Lemma 3. Let x and w be smooth and compactly supported on R2, then (i) ‖x ∗ w‖1 ≤ ‖x‖1‖w‖1. (ii) ‖∇(x ∗ w)‖1 ≤ ‖∇x‖1‖w‖1.
Proof of Lemma 3. For (i), ‖x ∗ w‖1 = ∫ R2 | ∫ R2 x(u− v)w(v)dv|du ≤ ∫ R2 ∫ R2 |x(u− v)||w(v)|dudv = ‖x‖1‖w‖1. For (ii),
‖∇(x ∗ w)‖1 = ∫ R2 |∇u( ∫ R2 x(u− v)w(v)dv)|du
= ∫ R2 | ∫ R2 ∇ux(u− v)w(v)dv|du
≤ ∫ R2 ∫ R2 |∇ux(u− v)||w(v)|dudv = ‖∇x‖1‖w‖1.

Review summaries:
This paper introduces a way to decompose features for better domain adaptation via learning domain-invariant representations. The main advantage of the proposed approach is that by only introducing a few model parameters, the proposed approach could quickly adapt to new domains. Similar idea has been proposed in [1], where the authors propose to use domain-specific encoders to extract domain-invariant features. Compared with [1], the main novelty of this paper lies in a new feature decomposition of the traditional convolution layer.