Smoothness and Stability in GANs
Casey Chu, Kentaro Minami, Kenji Fukumizu
Introduction: taming instability with smoothness
Generative adversarial networks (Goodfellow et al., 2014), or GANs, are a powerful class of generative models defined through minimax game. GANs and their variants have shown impressive performance in synthesizing various types of datasets, especially natural images. Despite these successes, the training of GANs remains quite unstable in nature, and this instability remains difficult to understand theoretically.
Since the introduction of GANs, there have been many techniques proposed to stabilize GANs training, including studies of new generator/discriminator architectures, loss functions, and regularization techniques. Notably, Arjovsky et al. (2017) proposed Wasserstein GAN (WGAN), which in principle avoids instability caused by mismatched generator and data distribution supports. In practice, this is enforced by Lipschitz constraints, which in turn motivated developments like gradient penalties (Gulrajani et al., 2017) and spectral normalization (Miyato et al., 2018). Indeed, these stabilization techniques have proven essential to achieving the latest state-of-the-art results (Karras et al., 2018; Brock et al., 2019).
On the other hand, a solid theoretical understanding of training stability has not been established. Several empirical observations point to an incomplete understanding. For example, why does applying a gradient penalty together spectral norm seem to improve performance (Miyato et al., 2018), even though in principle they serve the same purpose? Why does applying only spectral normalization with the Wasserstein loss fail (Miyato, 2018), even though the analysis of Arjovsky et al. (2017) suggests it should be sufficient? Why is applying gradient penalties effective, even outside their original context of the Wasserstein GAN (Fedus et al., 2018)?
In this work, we develop a framework to analyze the stability of GAN training that resolves these apparent contradictions and clarifies the roles of these regularization techniques. Our approach considers the smoothness of the loss function used. In optimization, smoothness is a well-known condition that ensures that gradient descent and its variants become stable (see e.g., Bertsekas (1999)). For example, the following well-known proposition is the starting point of our stability analysis:
This proposition says that under a smoothness condition on the function, gradient descent with a constant step size approaches stationarity (i.e., the gradient norm approaches zero). This is a rather weak notion of convergence, as it does not guarantee that the iterates converge to a point, and even if the iterates do converge, the limit is a stationary point and not necessarily an minimizer.
Nevertheless, empirically, not even this stationarity is satisfied by GANs, which are known to frequently destabilize and diverge during training. To diagnose this instability, we consider the smoothness of the GAN’s loss function. GANs are typically framed as minimax problems of the form
In the remainder of this paper, we investigate whether the smoothness assumption is satisfied for various GAN losses. Our analysis answers two questions:
Which existing GAN losses, if any, satisfy the smoothness condition in Proposition 1?
Are there choices of loss, regularization, or architecture that enforce smoothness in GANs?
As results of our analysis, our contributions are as follows:
We derive sufficient conditions for the GAN algorithm to be stationary under certain assumptions (Theorem 1). Our conditions relate to the smoothness of GAN loss used as well as the parameterization of the generator.
We show that most common GAN losses do not satisfy the all of the smoothness conditions, thereby corroborating their empirical instability.
We develop regularization techniques that enforce the smoothness conditions. These regularizers recover common GAN stabilization techniques such as gradient penalties and spectral normalization, thereby placing their use on a firmer theoretical foundation.
Our analysis provides several practical insights, suggesting for example the use of smooth activation functions, simultaneous spectral normalization and gradient penalties, and a particular learning rate for the generator.
Our analysis regards the GAN algorithm as minimizing a divergence between the current generator distribution and the desired data distribution, under the assumption of an optimal discriminator at every training step. This perspective originates from the earliest GAN paper, in which Goodfellow et al. (2014) show that the original minimax GAN implicitly minimizes the Jensen–Shannon divergence. Since then, the community has introduced a large number of GAN or GAN-like variants that learn generative models by implicitly minimizing various divergences, including -divergences (Nowozin et al., 2016), Wasserstein distance (Arjovsky et al., 2017), and maximum-mean discrepancy (Li et al., 2015; Unterthiner et al., 2018). Meanwhile, the non-saturating GAN (Goodfellow et al., 2014) has been shown to minimize a certain Kullback–Leibler divergence (Arjovsky & Bottou, 2017). Several more theoretical works consider the topological, geometric, and convexity properties of divergence minimization (Arjovsky & Bottou, 2017; Liu et al., 2017; Bottou et al., 2018; Farnia & Tse, 2018; Chu et al., 2019), perspectives that we draw heavily upon. Sanjabi et al. (2018) also prove smoothness of GAN losses in the specific case of the regularized optimal transport loss. Their assumption for smoothness is entangled in that it involves a composite condition on generators and discriminators, while our analysis addresses them separately.
Even though many analyses, including ours, operate under the assumption of an optimal discriminator, this assumption is unrealistic in practice. Li et al. (2017b) contrast this optimal discriminator dynamics with first-order dynamics, which assumes that the generator and discriminator use alternating gradient updates and is what is used computationally. As this is a differing approach from ours, we only briefly mention some results in this area, which typically rely on game-theoretic notions (Kodali et al., 2017; Grnarova et al., 2018; Oliehoek et al., 2018) or local analysis (Nagarajan & Kolter, 2017; Mescheder et al., 2018). Some of these results rely on continuous dynamics approximations of gradient updates; in contrast, our work focuses on discrete dynamics.
2 Notation
Smoothness of GAN losses
This section presents Theorem 1, which provides concise criteria for the smoothness of GAN losses.
Based on this duality, minimizing can be framed as the minimax problem
recovering the well-known adversarial formulation of GANs. We now define the notion of an optimal discriminator for an arbitrary loss function , based on this convex duality:
This definition recovers the optimal discriminators of many existing GAN and GAN-like algorithms (Farnia & Tse, 2018; Chu et al., 2019), most notably those in Table 1. Our analysis will apply to any algorithm in this family of algorithms. See Appendix B for more details on this perspective.
We also formalize the notion of a family of generators:
Now, in light of Proposition 1, we are interested in the smoothness of the mapping , which would guarantee the stationarity of gradient descent on this objective, which in turn implies stationarity of the GAN algorithm under the assumption of an optimal discriminator. The following theorem is our central result, which decomposes the smoothness of into conditions on optimal discriminators and the family of generators.
is -Lipschitz,
is -Lipschitz,
is -Lipschitz w.r.t. the -Wasserstein distance.
Also, let be a family of generators that satisfies:
Then is -smooth, with .
Theorem 1 connects the smoothness properties of the loss function with the smoothness properties of the optimal discriminator , and once paired with Proposition 1, it suggests a quantitative value for a stable generator learning rate. In order to obtain claims of stability for practically sized learning rates, it is important to tightly bound the relevant constants.
In Sections 4, 5 and 6, we carefully analyze which GAN losses satisfy (D1), (D2), and (D3), and with what constants. We summarize our results in Table 2: it turns out that none of the listed losses, except for one, satisfy (D1), (D2), and (D3) simultaneously with a finite constant. The MMD-based loss satisfies the three conditions, but its constant for (D1) grows as , which is an unfavorable dependence on the data dimension that forces an unacceptably small learning rate. See for complete details of each condition. This failure of existing GANs to satisfy the stationarity conditions corroborates the observed instability of GANs.
Theorem 1 decomposes smoothness into conditions on the generator and conditions on the discriminator, allowing a clean separation of concerns. In this paper, we focus on the discriminator conditions (D1), (D2), and (D3) and only provide an extremely simple example of a generator that satisfies (G1) and (G2), in Section 7. Because analysis of the generator conditions may become quite complicated and will vary with the choice of architecture considered (feedforward, convolutional, ResNet, etc.), we leave a detailed analysis of the generator conditions (G1) and (G2) as a promising avenue for future work. Indeed, such analyses may lead to new generator architectures or generator regularization techniques that stabilize GAN training.
Enforcing smoothness with inf-convolutions
In this section, we present a generic regularization technique that imposes the three conditions sufficient for stable learning on an arbitrary loss function , thereby stabilizing training. In Section 2, we observe that the Wasserstein, IPM, and MMD losses respectively satisfy (D1), (D2), and (D3) individually, but not all of of them at the same time. Using techniques from convex analysis, we convert these three GAN losses into three regularizers that, when applied simultaneously, causes the resulting loss to satisfy all the three conditions. Here, we only outline the technique; the specifics of each case are deferred to Sections 4, 5 and 6.
The duality formulation (4) provides a practical method for minimizing this composite function. We leverage the duality relation and apply (4):
This minimax problem can be seen as a GAN whose discriminator objective has three added regularization terms.
The concrete form of these regularizers are summarized in Table 3. Notably, we observe that we recover standard techniques for stabilizing GANs:
(D1) is enforced by Lipschitz constraints (i.e., spectral normalization) on the discriminator.
(D2) is enforced by spectral normalization and a choice of Lipschitz, smooth activation functions for the discriminator.
(D3) is enforced by gradient penalties on the discriminator.
Our analysis therefore puts these regularization techniques on a firm theoretical foundation (Proposition 1 and Theorem 1) and provides insight into their function.
Enforcing (D1) with Lipschitz constraints
In this section, we show that enforcing (D1) leads to techniques and notions commonly used to stabilize GANs, including the Wasserstein distance, Lipschitz constraints and spectral normalization. Recall that (D1) demands that the optimal discriminator is Lipschitz:
(D1) is -Lipschitz for all , i.e., .
If is differentiable, this is equivalent to that the optimal discriminator has a gradient with bounded norm. This is a sensible criterion, since a discriminator whose gradient norm is too large may push the generator too hard and destabilize its training.
To check (D1), the following proposition shows that it suffices to check whether for all distributions :
(D1) holds if and only if is -Lipschitz w.r.t. the Wasserstein-1 distance.
Arjovsky et al. (2017) show that this property does not hold for common divergences based on the Kullback–Leibler or Jensen–Shannon divergence, while it does hold for the Wasserstein-1 distance. Indeed, it is this desirable property that motivates their introduction of the Wasserstein GAN. Framed in our context, their result is summarized as follows:
The minimax and non-saturating GAN losses do not satisfy (D1) for some .
The Wasserstein GAN loss satisfies (D1) with for any .
Our stability analysis therefore deepens the analysis of Arjovsky et al. (2017) and provides an alternative reason that the Wasserstein distance is desirable as a metric: it is part of a sufficient condition that ensures stationarity of gradient descent.
Our analysis therefore justifies the use of Lipschitz constraints, such as spectral normalization (Miyato et al., 2018) and weight clipping (Arjovsky & Bottou, 2017), for general GAN losses. However, Theorem 1 also suggests that applying only Lipschitz constraints may not be enough to stabilize GANs, as (D1) alone does not ensure that the GAN objective is smooth.
Enforcing (D2) with discriminator smoothness
(D2) demands that the optimal discriminator is smooth:
(D2) is -Lipschitz for all , i.e., .
Intuitively, this says that for a fixed generator , the optimal discriminator should not provide gradients that change too much spatially.
Although the Wasserstein GAN loss (D1), we see that it, along with the minimax GAN and the non-saturating GAN, do not satisfy (D2):
The Wasserstein, minimax, and non-saturating GAN losses do not satisfy (D2) for some .
We now construct a loss that by definition satisfies (D2). Let be the class of -smooth functions, that is, for which , and consider the integral probability metric (IPM) (Müller, 1997) w.r.t. , defined by
The norm is the dual norm to , which extends the IPM to signed measures; it holds that for . Similar to the situation in the previous section, inf-convolution preserves the smoothness property of :
Applying (4) and (12), we see that we can minimize this transformed loss function by restricting the family of discriminators to only -smooth discriminators:
In practice, we can enforce this by applying spectral normalization (Miyato et al., 2018) and using a Lipschitz, smooth activation function such as ELU (Clevert et al., 2016) or sigmoid.
Enforcing (D3) with gradient penalties
(D3) is the following smoothness condition:
(D3) is -Lipschitz for any , i.e., .
where is the optimal discriminator for at . Then, (D3) is characterized in terms of the Bregman divergence and the KR norm as follows:
It is straightforward to compute the Bregman divergence corresponding to several popular GANs:
The minimax and non-saturating GAN losses do not satisfy (D3) for some .
Even so, the Bregman divergence for the non-saturating loss is always less than that of the minimax GAN, suggesting that the non-saturating loss should be stable in more situations than the minimax GAN. On the other hand, the MMD-based loss (Li et al., 2015) does satisfy (D3) when its kernel is the Gaussian kernel :
The MMD loss with Gaussian kernel satisfies (D3) with for all .
The norm is the norm of a reproducing kernel Hilbert space norm (RKHS) with Gaussian kernel; this norm extends the MMD to signed measures, as it holds that for . Here, denotes the mean embedding of a signed measure ; we also adopt the convention that if . Similar to the situation in the previous sections, inf-convolution preserves the smoothness property of :
Applying (4) and (19), we see that the transformed loss function can be minimized as a GAN by implementing an RKHS squared norm penalty on the discriminator:
Computationally, the RKHS norm is difficult to evaluate. We propose taking advantage of the following infinite series representation of in terms of the derivatives of (Fasshauer & Ye, 2011; Novak et al., 2018):
Let be an RKHS with the Gaussian kernel . Then for ,
In an ideal world, we would use this expression as a penalty on the discriminator to enforce (D3). Of course, as an infinite series, this formulation is computationally impractical. However, the first two terms are very close to common GAN techniques like gradient penalties (Gulrajani et al., 2017) and penalizing the output of the discriminator (Karras et al., 2018). We therefore interpret these common practices as partially applying the penalty given by the RKHS norm squared, approximately enforcing (D3). We view the choice of only using the leading terms as a disadvantageous but practical necessity.
Interestingly, according to our analysis, gradient penalties and spectral normalization are not interchangeable, even though both techniques were designed to constrain the Lipschitz constant of the discriminator. Instead, our analysis suggests that they serve different purposes: gradient penalties enforce the variational smoothness (D3), while spectral normalization enforces Lipschitz continuity (D1). This demystifies the puzzling observation of Miyato (2018) that GANs using only spectral normalization with a WGAN loss do not seem to train well; it also explains why using both spectral normalization and a gradient penalty is a reasonable strategy. It also motivates the use of gradient penalties applied to losses other than the Wasserstein loss (Fedus et al., 2018).
Verifying the theoretical learning rate
In this section, we empirically test the theoretical learning rate given by Theorems 1 and 1 as well as our regularization scheme (7) based on inf-convolutions. We approximately implement our composite regularization scheme (7) on a trivial base loss of by alternating stochastic gradient steps on
and it satisfies (G2) with , since is constant w.r.t. . With this setup, Theorem 1 suggests a theoretical learning rate of
We randomly generated hyperparameter settings for the Lipschitz constant , the smoothness constant , the number of particles , and the learning rate . We trained each model for 100,000 steps on CIFAR-10 and evaluate each model using the Fréchet Inception Distance (FID) of Heusel et al. (2017). We hypothesize that stability is correlated with image quality; Figure 1 plots the FID for each hyperparameter setting in terms of the ratio of the true learning rate and the theoretically motivated learning rate . We find that the best FID scores are obtained in the region where is between 1 and 1000. For small learning rates , we observe that the convergence is too slow to make a reasonable progress on the objective, whereas as the learning rate gets larger , we observe a steady increase in FID, signalling unstable behavior. It also makes sense that learning rates slightly above the optimal rate produce good results, since our theoretical learning rate is a conservative lower bound. Note that our intention is to test our theory, not to generate good images, which is difficult due to our weak choice of generator. Overall, this experiment shows that our theory and regularization scheme are sensible.
Future work
In this paper, we employed several assumptions in order to regard the GAN algorithm as gradient descent. However, real-world GAN algorithms must be treated as “inexact” descent algorithms. As such, future work includes: (i) relaxing the optimal discriminator assumption (cf. Sanjabi et al. (2018)) or providing a stability result for discrete simultaneous gradient descent (cf. continuous time analysis in Nagarajan & Kolter (2017); Mescheder et al. (2018)), (ii) addressing stochastic approximations of gradients (i.e., SGD), and (iii) providing error bounds for the truncated gradient penalty used in (23).
Another important direction of research is to seek more powerful generator architectures that satisfy our smoothness assumptions (G1) and (G2). In practice, generators are often implemented as deep neural networks, and involve some specific architectures such as deconvolution layers (Radford et al., 2015) and residual blocks (e.g., Gulrajani et al. (2017); Miyato et al. (2018)). In this paper, we did not provide results on the smoothness of general classes of generators, since our focus is to analyze stability properties influenced by the choice of loss function (and therefore optimal discriminators). However, our conditions (G1) and (G2) shed light on how to obtain smoothly parameterized neural networks, which is left for future work.
Acknowledgments
We would like to thank Kohei Hayashi, Katsuhiko Ishiguro, Masanori Koyama, Shin-ichi Maeda, Takeru Miyato, Masaki Watanabe, and Shoichiro Yamaguchi for helpful discussions.
References
To gain intuition on the inf-convolution, we present a finite-dimensional analogue of the techniques in Section 3. For simplicity of presentation, we will omit any regularity conditions (e.g., lower semicontinuity). We refer readers to Chapter 12 of Bauschke & Combettes (2011) for a detailed introduction.
The inf-convolution is often called the epigraphic sum since the epigraph of coincides with the Minkowski sum of epigraphs of and , as Figure 2 illustrates. The inf-convolution is associative and commutative operation; that is, it is always true that and .
There are two important special cases of inf-convolutions: The first one is the Pasch–Hausdorff envelope , which is the inf-convolution between and (). It is known that becomes -Lipschitz. The second important example is the Moreau envelope , i.e., the inf-convolution with the quadratic regularizer . The Moreau envelope is always differentiable, and the gradient of is -Lipschitz (thus is -smooth).
It is worth noting that the set of minimizers does not change after these two operations. More generally, we have the following result:
To sum up, given a function , we can always construct a regularized alternative that is -Lipschitz and -smooth and has the same minimizers as .
This property can be useful for implementing the regularized objective as follows. First, we can check that the convex conjugates of the norm and the squared norm are given as and . Hence, we have
Appendix B Common GAN losses
For completeness and clarity, we explicitly write out the expressions for the losses listed in Table 1. For more detailed computations of optimal discriminators, see Chu et al. (2019); for more details on the convex duality interpretation, see Farnia & Tse (2018).
Goodfellow et al. (2014) originally proposed the minimax GAN and showed that the corresponding loss function for the minimax GAN is the Jensen–Shannon divergence, defined as
where is the Radon–Nikodym derivative. If and have densities and , then
so our optimal discriminator matches that of Goodfellow et al. (2014) up to a constant factor and logarithm. To recover the minimax formulation, the convex duality (4) yields:
using the substitution .
Goodfellow et al. (2014) also proposed the heuristic non-saturating GAN. Theorem 2.5 of Arjovsky & Bottou (2017) shows that the loss function minimized is
Arjovsky et al. (2017) proposed the Wasserstein GAN, which minimizes the Wasserstein-1 distance between the input and a fixed measure :
where the infimum is taken over all couplings , probability distributions over whose marginals are and respectively. The optimal discriminator is called the Kantorovich potential in the optimal transport literature (Villani, 2009). The convex duality recover the Wasserstein GAN:
an expression of Kantorovich–Rubinstein duality. The Lipschitz constraint on the discriminator is typically enforced by spectral normalization (Miyato et al., 2018), less frequently by weight clipping (Arjovsky et al., 2017), or heuristically by gradient penalties (Gulrajani et al., 2017) (although this work shows that gradient penalties may serve a different purpose altogether).
where is the reproducing kernel Hilbert space (RKHS) for . The generative moment-matching network (GMMN, Li et al. (2015)) and the Coulomb GAN (Unterthiner et al., 2018) use the squared MMD as the loss function. The optimal discriminator in this case is
which in constrast to other GANs, may be approximated by simple Monte Carlo, rather than an auxiliary optimization problem.
Note that MMD-GANs (Li et al., 2017a; Arbel et al., 2018) minimize a modified version of the MMD, the Optimized MMD (Sriperumbudur et al., 2009; Arbel et al., 2018). These MMD-GANs are adversarial in a way that does not arise from convex duality, so our theory currently does not apply to these GANs.
An integral probability metric (Müller, 1997) is defined by
where is a class of functions. The optimal discriminator is the function that maximizes the supremum in the definition. The Wasserstein distance may be thought of as an IPM with containing all -Lipschitz functions. The MMD may be thought of as an IPM with all functions with RKHS norm at most , but no GANs based on MMD are actually trained this way, as it is difficult to constrain the discriminator to such functions.
Appendix C Optimal discriminators are functional derivatives
We introduce the functional derivative, also known as the von Mises influence function:
holds for any with .
Under this definition, optimal discriminators are actually functional derivatives.
The following result relates the derivative of the loss function with the derivative of the optimal discriminator:
We use this important computational tool in many of our proofs. For the case of the generator model , an important consequence of Proposition 17 is that
We use this fact in the proof of Theorem 1.
Appendix D Proofs for Sections 1 and 2
The following result is well known in the dynamical systems and the optimization literature. For the sake of completeness, we provide its proof.
It is known that if is -smooth, then
Summing this inequality over , we have
Next, we move on to prove Theorem 1, which we restate here for readability.
First, using the functional gradient interpretation of the optimal discriminator, we have
By assumption, there are bounded non-negative numbers , , , , and such that
Here, we wrote for the essential supremum of w.r.t. . From (D1′) and (G2′), the first term (a) is bounded as
From (D3′), (G1′), and the Cauchy-Schwarz inequality, the second term (b) is bounded as
where the second inequality holds from the following optimal transport interpretation of :
Lastly, from (D2′), (G1′) and the Cauchy-Schwarz inequality, the term (c) is bounded as
Combining the above upper bounds for (a)–(c), we conclude that
Appendix E Proofs for Section 3
In the finite-dimensional case, Proposition 15 says that taking inf-convolution with a “coercive” regularizer does not change the set of minimizers of the original objective. A similar invariance holds for GAN objectives, which are defined on infinite-dimensional space of signed measures, for the regularizers , and introduced in Sections 4, 5 and 6:
In order to apply the lemma, it suffices to show that is uniformly continuous on bounded sets and coercive, and that there exist constants and such that and . is uniformly continuous on bounded sets: suppose and ; then by the Cauchy–Schwarz and triangle inequality. is also coercive, as when . satisfies by Lemma 7. satisfies by Lemma 5. ∎
Recall that a function is said to be coercive if when .
From Theorem 2.3 of Strömberg (1996), , and . To show that is the unique minimizer, let . From the definition of inf-convolution, for every there exists an that satisfies
Since and are non-negative, and . By our assumption that , the latter limit implies that , which implies that by continuity of . Comparing our two expressions for the limit of , we find that , which implies that , since has a unique minimizer at . Hence .
Because and are non-negative, we have that
Using the fact that is coercive and hence its sublevel sets are bounded, let be such that if , then . By the triangle inequality and our assumption that ,
Because this constant is independent of , this shows that is coercive.
Appendix F Proofs for Section 4
From the duality between - and -norms, we have
In particular, the right-hand side of (26) is bounded from above as
which proves the first half of the statement.
For the converse, we borrow some techniques from the optimal transport theory. Let , and let denote the Wasserstein- distance between and . Suppose that is an -absolutely continuous curve, that is, every has a finite -moment and there exists such that holds for any . Then, the limit exists for almost all (see Ambrosio et al. (2008), Theorem 1.1.2). Such is called the metric derivative of .
holds for any cylindrical function .
Given , let be a -absolutely continuous curve such that and . Then
where is the metric derivative. The existence of and the bound is due to Lemma 2. Taking the infimum over all possible such curves, we find that
To conclude, we consider the limit . Using the fact that is increasing in , we have
Next, we verify Proposition 5. For , we have by the triangle inequality (see e.g., Section 6 in Villani (2009)). Reversing the roles of and , we can conclude that . The result follows from Proposition 3. ∎
Interchanging the roles of and completes the proof. ∎
where Sion’s minimax theorem ensures that we can swap the inf and the sup. ∎
Appendix G Proofs for Section 5
First, we prove the statement for the Wasserstein GAN. Consider evaluated at , a mixture of spikes at . The optimal discriminator of at this mixture is the Kantorovich potential that transfers to , which is . The gradient of this Kantorovich potential is discontinuous at , and hence not Lipschitz.
Then by the envelope theorem, is the that maximizes the right-hand side, and hence . ∎
The convex conjugate of is .
The proof of Lemma 4 is nearly identical to the proof of Lemma 3. ∎
We apply the inequality (27) recursively for all layers to obtain that the entire network is -smooth. ∎
Let be an RKHS with the Gaussian kernel. Then .
It follows from that, for ,
From (30), we find that for a Gaussian kernel,
Appendix H Proofs for Section 6
This proof is generalized from the finite-dimensional case (Boyd & Vandenberghe, 2004). We can bound the convex conjugate from above by
If is constant, then we may choose to see that
Otherwise, for , let be the signed measure given by
Recall the definition of the Bregman divergence:
Proposition 10 claims that the optimal discriminator is -smooth as a function of if and only if
Since the choice of and is arbitrary, we have proved (28) by assuming (D2).
Next, we move on to prove the converse. Before proceeding, note that the Bregman divergence is always non-negative. In fact, for any , we have
which implies .
Since the above inequality holds for all , the last expression is still non-negative if we take the infimum over all . In particular,
Swapping the roles of and , we obtain a similar inequality. Adding both sides of thus obtained two inequalities, we obtain
Because is differentiable, it suffices to check that the operator norm of is bounded. To see this, note that
where we obtained by the last equality by applying the vector-valued mean value theorem (Rudin, 1964) to , thereby obtaining
By inspection, we see that is an eigenvector with eigenvalue , and the other eigenvectors are orthogonal to with eigenvalues .
Setting and taking the absolute value of the eigenvalues, we see the maximum operator norm over all is equal to
It is not strictly necessary for the proof to show equality. However, to show equality, let be a unit vector, and set , and . Then
where we used l’Hôpital’s rule to evaluate the limit. ∎
For the minimax loss, the Bregman divergence is:
and for the non-saturating loss, the Bregman divergence is
We work with the Gaussian kernel and use Proposition 10:
where the last line is from Lemma 7. The result follows with .
The result actually applies more generally for the MMD loss with a differentiable kernel that satisfies . ∎
We work on the more general case of , and define
for .
Let be the unique minimizer of the infimum, which exists because the function is a strongly convex. By the envelope theorem, we compute that
where we used Lemma 7 for the second-to-last line. The proposition follows for .
Regarding this choice of , it will turn out that in the general case, the dual penalty includes a numerically unfavorable factor of , dependent on the dimension of the problem. In practical applications, such as image generation, can be quite large, making the accurate computation of completely infeasible. For numerical stability, we propose choosing the critical parameter , which corresponds to the dimension-free kernel . ∎
Let be an RKHS with a continuous kernel on a compact domain . The convex conjugate of is .
First we show an upper bound for :
To derive a lower bound for general , we use the Mercer decomposition of the positive definite kernel ,
where are eigenvalues and is a complete orthonormal sequence of . It is well-known that the corresponding RKHS is given by
Let be an arbitrary function. We replace the supremum of the conjugate function
by that has a square-integrable Radon–Nykodim derivative with respect to the Lebesgue measure , and then we have a lower bound. We use for the Radon–Nykodim derivative with slight abuse of notation.
Suppose and are the expansion. Note that, since the kernel embedding is given by
This is maximized when , and the maximum value is
If , this value is finite, and the lower bound of the conjugate given by is , which is the same as the upper bound. If , the value (32) is infinite, and the conjugate function takes . ∎
We consider the more general case of , where we have
Novak et al. (2018) prove this result for . We sketch the proof for the general case here. We use the Fourier transform convention that
defined for functions . Expanding the exponential in Taylor series, this inner product gives the equation for the norm in the proposition. By use of the Fourier inversion formula, it can be shown that , where
so this is an RKHS with the Gaussian kernel. ∎